AFTD Auto-Formalizing Theoretical Domains

mondrian_dvd_prime_pow_eq

theoremverified

A divisor x of a power of a prime p is p to its own p-adic exponent.

Statement

theorem mondrian_dvd_prime_pow_eq (p e x : ℕ) (hp : Nat.Prime p)
    (hx : x ∣ p ^ e) : x = p ^ (x.factorization p)
Source
Helper for OP-280 and mondrian_perfect_partition_large_prime_iff. Related work: arXiv:2610.19193, Section 1 (perfect partitions and scaling); arXiv:2007.09639, Theorem 4.1 (available shapes and prime-power exclusions).
Verified
26 Oct 2026
Axioms
Classical.choiceQuot.soundpropext
Used by 3

The proof, explained

Since $p$ is prime, any divisor $x$ of $p^e$ must be an integer power of $p$, say $x = p^u$ for some $u \\le e$. Substituting this expression for $x$, the multiplicity of $p$ in the prime factorization of $p^u$ is precisely $u$. Therefore, $x = p^u = p^{x\\text{.factorization } p}$.

  1. $x$ is of the form $p^u$ for some exponent $u \\le e$

    Since $p$ is prime and $x$ divides $p^e$, the classification of divisors of prime powers (Nat.dvd_prime_pow) shows that $x = p^u$ for some $u \\le e$. Substituting $x$ with $p^u$ updates the goal to $p^u = p^{(p^u\\text{.factorization } p)}$.

    line 3

    uses Nat.dvd_prime_pow

      obtain ⟨u, hu, rfl⟩ := (Nat.dvd_prime_pow hp).mp hx
  2. The identity $p^u = p^{(p^u\\text{.factorization } p)}$ holds

    For a prime $p$, the exponent of $p$ in the prime factorization of $p^u$ is simply $u$ (Nat.factorization_pow_self). Rewriting the exponent with this evaluation simplifies the right-hand side to $p^u$, closing the goal by reflexivity.

    line 4

    uses Nat.factorization_pow_self

      rw [Nat.factorization_pow_self hp]
Nat.dvd_prime_pow
A natural number divides a power of a prime $p^m$ if and only if it equals $p^k$ for some $k \\le m$.
Nat.factorization_pow_self
For a prime $p$, the multiplicity of $p$ in the prime factorization of $p^n$ is $n$.

Written by a model (gemini-3.8-flash) from the Lean proof and the goal states Lean reported at each step. Lean verified the proof; this explanation is a reading aid and is not itself machine-checked.

Lean source view module on GitHub

theorem mondrian_dvd_prime_pow_eq (p e x : ℕ) (hp : Nat.Prime p)    (hx : x ∣ p ^ e) : x = p ^ (x.factorization p) := by  obtain ⟨u, hu, rfl⟩ := (Nat.dvd_prime_pow hp).mp hx  rw [Nat.factorization_pow_self hp]
See it in the graphDiscuss this resultChallenge it