Compfiles/Usa2025P1.lean
Explanation legend Lean4 Domain Explanation Language (L4DEL)
L4DEL explanations are a separate layer. They do not change the Lean source. Intuition is explanatory prose; numbered items are a reading path; sources link the wording back to evidence.
- L4DEL
- Lean4 Domain Explanation Language
Credit: The upstream authors and contributors retain credit for the project and mathematics. lean4-explainer only renders their pinned source and adds the separately disclosed explanation layer.
Project sources: Pinned compfiles documentation, Pinned compfiles corpus index
3 declarations, 0 contain sorry, 0 declared as axioms
USA Mathematical Olympiad 2025, Problem 1
Fix positive integers k and d. Prove that for all sufficiently large odd positive integers n, the digits of the base-2n representation of n ^ k are all greater than d.
Imported by 1 file
- lemma
Usa2025P1.residue_modFor oddnand1 ≤ ℓ ≤ k, the residue ofn ^ kmodulo(2 * n) ^ ℓhas the formc * n ^ ℓfor an oddc(so in particular1 ≤ c) line 33 sourceSource documentation
For odd
nand1 ≤ ℓ ≤ k, the residue ofn ^ kmodulo(2 * n) ^ ℓhas the formc * n ^ ℓfor an oddc(so in particular1 ≤ c). In other words, theℓrightmost base-(2 * n)digits ofn ^ kare the base-(2 * n)digits ofc * n ^ ℓ.standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,Odd,LE.le,OfNat.ofNat,Exists,And,Eq,HMod.hMod,HPow.hPow,HMul.hMulProof uses:
LT.lt,Odd.pos,HSub.hSub,Eq.mpr,id,congrArg,propext,Nat.odd_iff,Nat.mod_mod_of_dvd,dvd_pow_self,Iff.mp,Odd.pow,Exists.intro,And.intro,Dvd.dvd,mul_pow,mul_dvd_mul_right,Nat.dvd_sub_mod,Nat.sub_mul,HAdd.hAddand 15 more45 instances, coercions and auxiliary constants left out.
Tactic trace: 24 steps
Open to load the checked before-and-after goal states.
lemma residue_mod {n k ℓ : ℕ} (hodd : Odd n) (hℓ1 : 1 ≤ ℓ) (hℓk : ℓ ≤ k) : ∃ c : ℕ, Odd c ∧ 1 ≤ c ∧ n ^ k % (2 * n) ^ ℓ = c * n ^ ℓ := by … - lemma
Usa2025P1.digit_of_modThei-th base-bdigit ofm(counting from the right, starting at0) equalsE / b ^ i, whereE = m % b ^ (i + 1)is the residue ofmmodulo the next power ofbline 65 sourceSource documentation
The
i-th base-bdigit ofm(counting from the right, starting at0) equalsE / b ^ i, whereE = m % b ^ (i + 1)is the residue ofmmodulo the next power ofb.standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,LT.lt,OfNat.ofNat,Eq,HMod.hMod,HPow.hPow,HAdd.hAdd,HDiv.hDivProof uses:
Eq.mpr,id,congrArg,Eq.symm,Nat.mod_lt,Nat.pow_pos,HMul.hMul,pow_succ,Eq.mp,Nat.div_add_mod,rfl,Mathlib.Tactic.Ring.of_eq,Nat.rawCast,Mathlib.Tactic.Ring.Common.add_congr,Mathlib.Tactic.Ring.Common.mul_congr,Mathlib.Tactic.Ring.Common.pow_congr,Mathlib.Tactic.Ring.Common.atom_pf,Eq.refl,Mathlib.Tactic.Ring.Common.pow_add,Mathlib.Tactic.Ring.Common.single_powand 21 more39 instances, coercions and auxiliary constants left out.
Tactic trace: 19 steps
Open to load the checked before-and-after goal states.
lemma digit_of_mod {m b E i : ℕ} (hb : 1 < b) (hm : m % b ^ (i + 1) = E) : m / b ^ i % b = E / b ^ i := by … - problem
Usa2025P1.usa2025_p1line 88 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,LT.lt,OfNat.ofNat,Exists,LE.le,Odd,Membership.mem,List,Nat.digits,HMul.hMul,HPow.hPowProof uses:
Exists.intro,HAdd.hAdd,HSub.hSub,Odd.pos,List.length,Eq,GetElem.getElem,Iff.mp,List.mem_iff_getElem,Eq.mpr,id,congrArg,propext,Nat.digits_length_le_iff,Nat.pow_lt_pow_left,HMod.hMod,HDiv.hDiv,List.getD,Nat.getD_digits,Eq.transand 48 more66 instances, coercions and auxiliary constants left out.
Tactic trace: 44 steps
Open to load the checked before-and-after goal states.