Compfiles/Bulgaria1998P11.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
4 declarations, 0 contain sorry, 0 declared as axioms
Bulgarian Mathematical Olympiad 1998, Problem 11
Let m,n be natural numbers such that
A = ((m + 3)ⁿ + 1) / (3m)
is an integer. Prove that A is odd.
Imports (2)
Imported by 1 file
- lemma
Bulgaria1998P11.exists_prime_fac_mod_three_eq_twoA natural number that is 2 mod 3 has a prime factor that is 2 mod 3 line 32 sourceSource documentation
A natural number that is 2 mod 3 has a prime factor that is 2 mod 3.
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,Eq,HMod.hMod,OfNat.ofNat,Exists,And,Nat.Prime,Dvd.dvdProof uses:
Nat.strong_induction_on,LT.lt,Nat.exists_prime_and_dvd,Ne,HMul.hMul,Or,False.elim,Eq.mp,False,Eq.trans,congrFun',congrArg,MulZeroClass.zero_mul,Nat.mul_mod,lt_of_not_ge,LE.le,Mathlib.Tactic.Linarith.lt_irrefl,Int,HAdd.hAdd,Neg.negand 72 more116 instances, coercions and auxiliary constants left out.
Tactic trace: 20 steps
Open to load the checked before-and-after goal states.
lemma exists_prime_fac_mod_three_eq_two (m : ℕ) (hm : m % 3 = 2) : ∃ p, p.Prime ∧ p ∣ m ∧ p % 3 = 2 := by … - lemma
Bulgaria1998P11.mod_three_ne_two_of_sq_eq_neg_threeDocumented declaration: mod_three_ne_two_of_sq_eq_neg_three line 50 sourceSource documentation
If
-3is a square mod an odd primep, thenpis not 2 mod 3: the elementωwith2 * ω = a - 1satisfiesω² + ω + 1 = 0, hence has order three, so that3 ∣ p - 1by Fermat's little theorem.standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,Nat.Prime,Ne,OfNat.ofNat,ZMod,Eq,HPow.hPow,Neg.neg,HMod.hModProof uses:
Fact,Fact.mk,Eq.mp,Dvd.dvd,congrArg,propext,Nat.prime_dvd_prime_iff_eq,Nat.prime_two,ZMod.natCast_eq_zero_iff,id,Eq.refl,HMul.hMul,HSub.hSub,Exists,False,Exists.intro,HDiv.hDiv,of_eq_true,Eq.trans,inferInstanceand 120 more120 instances, coercions and auxiliary constants left out.
Tactic trace: 29 steps
Open to load the checked before-and-after goal states.
lemma mod_three_ne_two_of_sq_eq_neg_three {p : ℕ} (hp : p.Prime) (hp2 : p ≠ 2) {a : ZMod p} (ha : a ^ 2 = -3) : p % 3 ≠ 2 := by … - lemma
Bulgaria1998P11.n_odd_and_m_mod_threeline 80 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,Eq,HMul.hMul,OfNat.ofNat,HAdd.hAdd,HPow.hPow,And,Odd,HMod.hModProof uses:
Ne,False,Eq.mp,congrArg,congrFun',pow_zero,Eq.symm,ZMod,Eq.mpr,id,Eq.refl,Mathlib.Tactic.LinearCombination.eq_of_eq,MulZeroClass.zero_mul,add_zero,of_decide_eq_true,Bool,Decidable.decide,Bool.true,congr,Eq.transand 67 more103 instances, coercions and auxiliary constants left out.
Tactic trace: 35 steps
Open to load the checked before-and-after goal states.
- problem
Bulgaria1998P11.bulgaria1998_p11line 107 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,Eq,HMul.hMul,OfNat.ofNat,HAdd.hAdd,HPow.hPow,OddProof uses:
HMod.hMod,And, Bulgaria1998P11.n_odd_and_m_mod_three,Decidable.byContradiction,Not,Eq.mpr,id,congrArg,Eq.symm,Nat.mul_mod,Eq.mp,Even,propext,Nat.even_iff,Nat.not_odd_iff_even,MulZeroClass.mul_zero,Nat.zero_mod,Eq.refl,Nat.pow_mod,Nat.zero_powand 115 more105 instances, coercions and auxiliary constants left out.
Tactic trace: 68 steps
Open to load the checked before-and-after goal states.