Compfiles/Imo2017P2.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
22 declarations, 0 contain sorry, 0 declared as axioms
International Mathematical Olympiad 2017, Problem 2
Find all functions f : ℝ → ℝ that satisfy
∀ x,y ∈ ℝ, f(f(x)f(y)) + f(x + y) = f(xy).
Imports (2)
Imported by 1 file
- def
Imo2017P2.goodline 46 sourceno axioms what this means
Statement uses:
RingProof uses:
Eq,HAdd.hAdd,HMul.hMul6 instances, coercions and auxiliary constants left out.
- theorem
Imo2017P2.good_zeroline 51 sourceno axioms what this means
Statement uses:
Ring, Imo2017P2.good,OfNat.ofNatProof uses:
add_zero13 instances, coercions and auxiliary constants left out.
- theorem
Imo2017P2.good_one_subline 54 sourcestandard axioms: propext what this means
Statement uses:
Ring, Imo2017P2.good,HSub.hSub,OfNat.ofNatProof uses:
Eq.mpr,Eq,HAdd.hAdd,HMul.hMul,Neg.neg,id,congr,congrArg,Eq.trans,sub_eq_add_neg,mul_add,mul_one,mul_neg,add_mul,one_mul,neg_mul39 instances, coercions and auxiliary constants left out.
Tactic trace: 1 steps
Open to load the checked before-and-after goal states.
- theorem
Imo2017P2.good_negline 65 sourcestandard axioms: propext what this means
Statement uses:
Ring, Imo2017P2.good,Neg.negProof uses:
Eq.mpr,Eq,HAdd.hAdd,HMul.hMul,id,congrArg,Pi.neg_apply,neg_mul_neg,Eq.symm,neg_add,Eq.refl32 instances, coercions and auxiliary constants left out.
Tactic trace: 3 steps
Open to load the checked before-and-after goal states.
- theorem
Imo2017P2.good_special_equality(1) line 70 sourceSource documentation
(1)
standard axioms: propext what this means
Statement uses:
Ring, Imo2017P2.good,Eq,HMul.hMul,OfNat.ofNat,HAdd.hAddProof uses:
Eq.mpr,id,congrArg,Eq.symm,propext,add_eq_right,add_one_mul,mul_add_one,add_comm,Eq.refl50 instances, coercions and auxiliary constants left out.
Tactic trace: 1 steps
Open to load the checked before-and-after goal states.
theorem good_special_equality {x y : R} (h0 : x * y = 1) : f (f (x + 1) * f (y + 1)) = 0 := by …Mentions: f
- theorem
Imo2017P2.good_map_map_zero_sqline 74 sourcestandard axioms: propext what this means
Statement uses:
Ring, Imo2017P2.good,Eq,HPow.hPow,Nat,OfNat.ofNatProof uses:
HMul.hMul,Neg.neg,Eq.mpr,id,congrArg,neg_mul_neg,mul_one,Eq.refl,HAdd.hAdd, Imo2017P2.good_special_equality,Eq.mp,Eq.symm,sq,neg_add_cancel54 instances, coercions and auxiliary constants left out.
Tactic trace: 4 steps
Open to load the checked before-and-after goal states.
- theorem
Imo2017P2.good_eq_of_injline 79 sourcestandard axioms: Quot.sound, propext what this means
Statement uses:
Ring, Imo2017P2.good,Eq,OfNat.ofNat,Function.Injective,HSub.hSubProof uses:
HAdd.hAdd,Eq.mpr,id,congrArg,Eq.symm,HMul.hMul,MulZeroClass.mul_zero,add_zero,mul_one,Eq.refl,funext,propext,eq_sub_iff_add_eq',add_left_inj,add_comm51 instances, coercions and auxiliary constants left out.
Tactic trace: 4 steps
Open to load the checked before-and-after goal states.
- theorem
Imo2017P2.good_map_eq_zeroline 94 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Ne,OfNat.ofNat,EqProof uses:
Not.imp_symm,Not,HMul.hMul,HAdd.hAdd,HSub.hSub,Inv.inv, Imo2017P2.good_special_equality,mul_inv_cancel₀,sub_ne_zero_of_ne,funext,Eq.mpr,id,congrArg,Pi.zero_apply,Eq.symm,Eq.mp,MulZeroClass.zero_mul,sub_add_cancel,MulZeroClass.mul_zero,zero_addand 2 more44 instances, coercions and auxiliary constants left out.
Tactic trace: 4 steps
Open to load the checked before-and-after goal states.
- theorem
Imo2017P2.good_map_zero_sqline 105 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Ne,OfNat.ofNat,Eq,HPow.hPow,NatProof uses: Imo2017P2.good_map_eq_zero, Imo2017P2.good_map_map_zero_sq
26 instances, coercions and auxiliary constants left out.
- theorem
Imo2017P2.good_map_zeroline 109 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Ne,OfNat.ofNat,Or,Eq,Neg.negProof uses:
Iff.mp,HPow.hPow,Nat,sq_eq_one_iff, Imo2017P2.good_map_zero_sq39 instances, coercions and auxiliary constants left out.
- theorem
Imo2017P2.good_map_oneline 113 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Eq,OfNat.ofNatProof uses:
Or.elim,Ne,eq_or_ne,congr_fun,Eq.rec,HPow.hPow,Nat, Imo2017P2.good_map_map_zero_sq, Imo2017P2.good_map_zero_sq24 instances, coercions and auxiliary constants left out.
- theorem
Imo2017P2.good_map_eq_zero_iff(2) line 119 sourceSource documentation
(2)
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Eq,OfNat.ofNat,IffProof uses:
Iff.intro, Imo2017P2.good_map_eq_zero,zero_ne_one,Eq.mp,congrArg,Eq.rec,congr_arg, Imo2017P2.good_map_one22 instances, coercions and auxiliary constants left out.
Tactic trace: 1 steps
Open to load the checked before-and-after goal states.
theorem good_map_eq_zero_iff (h0 : f 0 = 1) (c : D) : f c = 0 ↔ c = 1 := …
Mentions: f
- theorem
Imo2017P2.good_shift(3) line 125 sourceSource documentation
(3)
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Eq,OfNat.ofNat,HAdd.hAddProof uses:
HMul.hMul,Eq.mp,congrArg,mul_one,add_comm,MulZeroClass.mul_zero, Imo2017P2.good_map_one36 instances, coercions and auxiliary constants left out.
Tactic trace: 2 steps
Open to load the checked before-and-after goal states.
theorem good_shift (h0 : f 0 = 1) (x : D) : f (x + 1) + 1 = f x := by …
Mentions: f
- theorem
Imo2017P2.good_shift2line 130 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Eq,OfNat.ofNat,HSub.hSub,HAdd.hAddProof uses:
Eq.mpr,id,congrArg,Eq.symm, Imo2017P2.good_shift,sub_add_cancel,Eq.refl36 instances, coercions and auxiliary constants left out.
Tactic trace: 1 steps
Open to load the checked before-and-after goal states.
- theorem
Imo2017P2.good_map_add_one_eq_zero_iffline 134 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Eq,OfNat.ofNat,Iff,HAdd.hAddProof uses:
Eq.mpr,id,congrArg,propext, Imo2017P2.good_map_eq_zero_iff,add_eq_right,Iff.rfl37 instances, coercions and auxiliary constants left out.
Tactic trace: 1 steps
Open to load the checked before-and-after goal states.
- theorem
Imo2017P2.solution_of_map_zero_eq_one_imp_injectiveThe general framework; reducing to injectivity line 139 sourceSource documentation
The general framework; reducing to injectivity.
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing, Imo2017P2.good,Eq,OfNat.ofNat,Function.Injective,Iff,Or,HSub.hSub,Neg.negProof uses:
Iff.intro,Eq.mpr,Not,id,congrArg,propext,Classical.or_iff_not_imp_left,Or.imp, Imo2017P2.good_map_zero, Imo2017P2.good_eq_of_inj,Eq.symm,neg_eq_iff_eq_neg, Imo2017P2.good_neg,Eq.mp, Imo2017P2.good_zero, Imo2017P2.good_one_sub53 instances, coercions and auxiliary constants left out.
Tactic trace: 16 steps
Open to load the checked before-and-after goal states.
theorem solution_of_map_zero_eq_one_imp_injective (h : ∀ f : D → D, good f → f 0 = 1 → Injective f) {f : D → D} : good f ↔ f = 0 ∨ f = (1 - ·) ∨ f = -(1 - ·) := by …Mentions: h, f, Imo2017P2.good
- theorem
Imo2017P2.case1_injectiveInjectivity forchar(D) ≠ 2,Da division ring line 155 sourceSource documentation
Injectivity for
char(D) ≠ 2,Da division ringstandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
DivisionRing,Ne,OfNat.ofNat,Nat, Imo2017P2.good,Eq,Function.InjectiveProof uses:
HSub.hSub,HAdd.hAdd, Imo2017P2.good_shift2,HMul.hMul,Neg.neg,Eq.mpr,id,congrArg,add_assoc,Eq.symm,neg_one_mul,congr_arg₂,zero_sub,one_add_one_eq_two,Eq.refl,add_comm,neg_add_eq_sub,Eq.mp,propext, Imo2017P2.good_map_add_one_eq_zero_iff and 13 more86 instances, coercions and auxiliary constants left out.
Tactic trace: 18 steps
Open to load the checked before-and-after goal states.
theorem case1_injective (h : (2 : D) ≠ 0) {f : D → D} (h0 : good f) (h1 : f 0 = 1) : Injective f := by …Mentions: h, f, Imo2017P2.good
- theorem
Imo2017P2.case2_injectiveInjectivity forchar(F) = 2line 185 sourceSource documentation
Injectivity for
char(F) = 2standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Field,Eq,OfNat.ofNat,Nat, Imo2017P2.good,Function.InjectiveProof uses:
HAdd.hAdd, Imo2017P2.good_shift,Ne,HSub.hSub,HMul.hMul,Inv.inv,Eq.mpr,id,congrArg, Imo2017P2.good_shift2,Eq.symm,add_assoc, Imo2017P2.good_special_equality,mul_inv_cancel₀,zero_add,add_right_comm,Eq.refl,Iff, Imo2017P2.good_map_add_one_eq_zero_iff,Orand 69 more113 instances, coercions and auxiliary constants left out.
Tactic trace: 30 steps
Open to load the checked before-and-after goal states.
theorem case2_injective [Field F] (h : (2 : F) = 0) {f : F → F} (h0 : good f) (h1 : f 0 = 1) : Injective f := by …Mentions: h, f, Imo2017P2.good
- theorem
Imo2017P2.map_zero_eq_one_imp_injectiveInjectivity line 224 sourceSource documentation
Injectivity
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Field, Imo2017P2.good,Eq,OfNat.ofNat,Function.InjectiveProof uses:
Or.elim,Ne,Nat,ne_or_eq, Imo2017P2.case1_injective, Imo2017P2.case2_injective29 instances, coercions and auxiliary constants left out.
theorem map_zero_eq_one_imp_injective [Field F] : ∀ f : F → F, good f → f 0 = 1 → Injective f := …Mentions: f, Imo2017P2.good
- theorem
Imo2017P2.final_solutionFinal solution line 229 sourceSource documentation
Final solution
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Field,Iff, Imo2017P2.good,Or,Eq,OfNat.ofNat,Sub.sub,Neg.neg,HSub.hSubProof uses: Imo2017P2.solution_of_map_zero_eq_one_imp_injective, Imo2017P2.map_zero_eq_one_imp_injective
24 instances, coercions and auxiliary constants left out.
theorem final_solution [Field F] {f : F → F} : good f ↔ f = 0 ∨ f = Sub.sub 1 ∨ f = fun x ↦ -(1 - x) := …Mentions: f, Imo2017P2.good
- determine
Imo2017P2.solution_setline 235 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Set,RealProof uses:
Insert.insert,OfNat.ofNat,HSub.hSub,Singleton.singleton8 instances, coercions and auxiliary constants left out.
- problem
Imo2017P2.imo2017_p2line 238 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Real,Iff,Membership.mem,Set, Imo2017P2.solution_set,Eq,HAdd.hAdd,HMul.hMulProof uses: Imo2017P2.good,
Or,OfNat.ofNat,Sub.sub,Neg.neg,HSub.hSub, Imo2017P2.final_solution,Iff.intro,Eq.mp,Eq.trans,Insert.insert,Singleton.singleton,congrArg,Mathlib.Tactic.Ring.of_eq,Mathlib.Tactic.Ring.Common.add_congr,Mathlib.Tactic.Ring.cast_zero,Mathlib.Meta.NormNum.isNat_ofNat,Nat.cast_zero,Mathlib.Tactic.Ring.Common.add_pf_zero_add,Eq.symmand 55 more64 instances, coercions and auxiliary constants left out.
Tactic trace: 11 steps
Open to load the checked before-and-after goal states.