Context
stringlengths
57
6.04k
file_name
stringlengths
21
79
start
int64
14
1.49k
end
int64
18
1.5k
theorem
stringlengths
25
1.55k
proof
stringlengths
5
7.36k
goals
listlengths
0
224
goals_before
listlengths
0
220
import Mathlib.SetTheory.Cardinal.Finite #align_import data.set.ncard from "leanprover-community/mathlib"@"74c2af38a828107941029b03839882c5c6f87a04" namespace Set variable {Ξ± Ξ² : Type*} {s t : Set Ξ±} noncomputable def encard (s : Set Ξ±) : β„•βˆž := PartENat.withTopEquiv (PartENat.card s) @[simp] theorem encard_uni...
Mathlib/Data/Set/Card.lean
140
141
theorem finite_of_encard_le_coe {k : β„•} (h : s.encard ≀ k) : s.Finite := by
rw [← encard_lt_top_iff]; exact h.trans_lt (WithTop.coe_lt_top _)
[ " univ.encard = s.encard", " univ.encard = PartENat.withTopEquiv (PartENat.card Ξ±)", " s.encard = ↑h.toFinset.card", " s.encard = ↑s.toFinset.card", " (↑s).encard = ↑s.card", " ↑⋯.toFinset.card = ↑s.card", " s.encard = ⊀", " s.encard = 0 ↔ s = βˆ…", " βˆ….encard = 0", " s.Nonempty", " s.encard β‰  0 ↔...
[ " univ.encard = s.encard", " univ.encard = PartENat.withTopEquiv (PartENat.card Ξ±)", " s.encard = ↑h.toFinset.card", " s.encard = ↑s.toFinset.card", " (↑s).encard = ↑s.card", " ↑⋯.toFinset.card = ↑s.card", " s.encard = ⊀", " s.encard = 0 ↔ s = βˆ…", " βˆ….encard = 0", " s.Nonempty", " s.encard β‰  0 ↔...
import Mathlib.Topology.Homeomorph import Mathlib.Topology.StoneCech #align_import topology.extremally_disconnected from "leanprover-community/mathlib"@"7e281deff072232a3c5b3e90034bd65dde396312" noncomputable section open scoped Classical open Function Set universe u section variable (X : Type u) [TopologicalS...
Mathlib/Topology/ExtremallyDisconnected.lean
83
92
theorem StoneCech.projective [DiscreteTopology X] : CompactT2.Projective (StoneCech X) := by
intro Y Z _tsY _tsZ _csY _t2Y _csZ _csZ f g hf hg g_sur let s : Z β†’ Y := fun z => Classical.choose <| g_sur z have hs : g ∘ s = id := funext fun z => Classical.choose_spec (g_sur z) let t := s ∘ f ∘ stoneCechUnit have ht : Continuous t := continuous_of_discreteTopology let h : StoneCech X β†’ Y := stoneCechE...
[ " CompactT2.Projective (StoneCech X)", " βˆƒ h, Continuous h ∧ g ∘ h = f", " (g ∘ h) ∘ stoneCechUnit = f ∘ stoneCechUnit" ]
[]
import Mathlib.MeasureTheory.Measure.FiniteMeasure import Mathlib.MeasureTheory.Integral.Average #align_import measure_theory.measure.probability_measure from "leanprover-community/mathlib"@"f0c8bf9245297a541f468be517f1bde6195105e9" noncomputable section open MeasureTheory open Set open Filter open BoundedCon...
Mathlib/MeasureTheory/Measure/ProbabilityMeasure.lean
199
201
theorem apply_mono (ΞΌ : ProbabilityMeasure Ξ©) {s₁ sβ‚‚ : Set Ξ©} (h : s₁ βŠ† sβ‚‚) : ΞΌ s₁ ≀ ΞΌ sβ‚‚ := by
rw [← coeFn_comp_toFiniteMeasure_eq_coeFn] exact MeasureTheory.FiniteMeasure.apply_mono _ h
[ " ↑μ s = ↑ν s", " Ξ½ univ β‰  0", " ↑(Ξ½ s) = ↑ν s", " ΞΌ s₁ ≀ ΞΌ sβ‚‚", " ΞΌ.toFiniteMeasure s₁ ≀ ΞΌ.toFiniteMeasure sβ‚‚" ]
[ " ↑μ s = ↑ν s", " Ξ½ univ β‰  0", " ↑(Ξ½ s) = ↑ν s" ]
import Mathlib.SetTheory.Game.Short #align_import set_theory.game.state from "leanprover-community/mathlib"@"b134b2f5cf6dd25d4bbfd3c498b6e36c11a17225" universe u namespace SetTheory namespace PGame class State (S : Type u) where turnBound : S β†’ β„• l : S β†’ Finset S r : S β†’ Finset S left_bound : βˆ€ {s t : S...
Mathlib/SetTheory/Game/State.lean
57
61
theorem turnBound_ne_zero_of_right_move {s t : S} (m : t ∈ r s) : turnBound s β‰  0 := by
intro h have t := right_bound m rw [h] at t exact Nat.not_succ_le_zero _ t
[ " turnBound s β‰  0", " False" ]
[ " turnBound s β‰  0", " False" ]
import Mathlib.Topology.Algebra.GroupWithZero import Mathlib.Topology.Order.OrderClosed #align_import topology.algebra.with_zero_topology from "leanprover-community/mathlib"@"3e0c4d76b6ebe9dfafb67d16f7286d2731ed6064" open Topology Filter TopologicalSpace Filter Set Function namespace WithZeroTopology variable {Ξ±...
Mathlib/Topology/Algebra/WithZeroTopology.lean
136
139
theorem isOpen_iff {s : Set Ξ“β‚€} : IsOpen s ↔ (0 : Ξ“β‚€) βˆ‰ s ∨ βˆƒ Ξ³, Ξ³ β‰  0 ∧ Iio Ξ³ βŠ† s := by
rw [isOpen_iff_mem_nhds, ← and_forall_ne (0 : Ξ“β‚€)] simp (config := { contextual := true }) [nhds_of_ne_zero, imp_iff_not_or, hasBasis_nhds_zero.mem_iff]
[ " 𝓝 = update pure 0 (β¨… Ξ³, β¨… (_ : Ξ³ β‰  0), π“Ÿ (Iio Ξ³))", " pure 0 ≀ β¨… Ξ³, β¨… (_ : Ξ³ β‰  0), π“Ÿ (Iio Ξ³)", " 𝓝 0 = β¨… Ξ³, β¨… (_ : Ξ³ β‰  0), π“Ÿ (Iio Ξ³)", " (𝓝 0).HasBasis (fun Ξ³ => Ξ³ β‰  0) Iio", " (β¨… Ξ³, β¨… (_ : Ξ³ β‰  0), π“Ÿ (Iio Ξ³)).HasBasis (fun Ξ³ => Ξ³ β‰  0) Iio", " DirectedOn ((fun Ξ³ => Iio Ξ³) ⁻¹'o fun x x_1 => x β‰₯ x_1...
[ " 𝓝 = update pure 0 (β¨… Ξ³, β¨… (_ : Ξ³ β‰  0), π“Ÿ (Iio Ξ³))", " pure 0 ≀ β¨… Ξ³, β¨… (_ : Ξ³ β‰  0), π“Ÿ (Iio Ξ³)", " 𝓝 0 = β¨… Ξ³, β¨… (_ : Ξ³ β‰  0), π“Ÿ (Iio Ξ³)", " (𝓝 0).HasBasis (fun Ξ³ => Ξ³ β‰  0) Iio", " (β¨… Ξ³, β¨… (_ : Ξ³ β‰  0), π“Ÿ (Iio Ξ³)).HasBasis (fun Ξ³ => Ξ³ β‰  0) Iio", " DirectedOn ((fun Ξ³ => Iio Ξ³) ⁻¹'o fun x x_1 => x β‰₯ x_1...
import Mathlib.AlgebraicTopology.DoldKan.Faces import Mathlib.CategoryTheory.Idempotents.Basic #align_import algebraic_topology.dold_kan.projections from "leanprover-community/mathlib"@"32a7e535287f9c73f2e4d2aef306a39190f0b504" open CategoryTheory CategoryTheory.Category CategoryTheory.Limits CategoryTheory.Pread...
Mathlib/AlgebraicTopology/DoldKan/Projections.lean
61
65
theorem P_f_0_eq (q : β„•) : ((P q).f 0 : X _[0] ⟢ X _[0]) = πŸ™ _ := by
induction' q with q hq · rfl · simp only [P_succ, HomologicalComplex.add_f_apply, HomologicalComplex.comp_f, HomologicalComplex.id_f, id_comp, hq, Hσ_eq_zero, add_zero]
[ " (P q).f 0 = πŸ™ (K[X].X 0)", " (P 0).f 0 = πŸ™ (K[X].X 0)", " (P (q + 1)).f 0 = πŸ™ (K[X].X 0)" ]
[]
import Mathlib.Algebra.Module.BigOperators import Mathlib.Data.Fintype.BigOperators import Mathlib.LinearAlgebra.AffineSpace.AffineMap import Mathlib.LinearAlgebra.AffineSpace.AffineSubspace import Mathlib.LinearAlgebra.Finsupp import Mathlib.Tactic.FinCases #align_import linear_algebra.affine_space.combination from ...
Mathlib/LinearAlgebra/AffineSpace/Combination.lean
96
104
theorem weightedVSubOfPoint_eq_of_weights_eq (p : ΞΉ β†’ P) (j : ΞΉ) (w₁ wβ‚‚ : ΞΉ β†’ k) (hw : βˆ€ i, i β‰  j β†’ w₁ i = wβ‚‚ i) : s.weightedVSubOfPoint p (p j) w₁ = s.weightedVSubOfPoint p (p j) wβ‚‚ := by
simp only [Finset.weightedVSubOfPoint_apply] congr ext i rcases eq_or_ne i j with h | h Β· simp [h] Β· simp [hw i h]
[ " univ = {0, 1}", " x ∈ univ ↔ x ∈ {0, 1}", " ⟨0, β‹―βŸ© ∈ univ ↔ ⟨0, β‹―βŸ© ∈ {0, 1}", " ⟨1, β‹―βŸ© ∈ univ ↔ ⟨1, β‹―βŸ© ∈ {0, 1}", " (s.weightedVSubOfPoint p b) w = βˆ‘ i ∈ s, w i β€’ (p i -α΅₯ b)", " (s.weightedVSubOfPoint (fun x => p) b) w = (βˆ‘ i ∈ s, w i) β€’ (p -α΅₯ b)", " (s.weightedVSubOfPoint p₁ b) w₁ = (s.weightedVSubOf...
[ " univ = {0, 1}", " x ∈ univ ↔ x ∈ {0, 1}", " ⟨0, β‹―βŸ© ∈ univ ↔ ⟨0, β‹―βŸ© ∈ {0, 1}", " ⟨1, β‹―βŸ© ∈ univ ↔ ⟨1, β‹―βŸ© ∈ {0, 1}", " (s.weightedVSubOfPoint p b) w = βˆ‘ i ∈ s, w i β€’ (p i -α΅₯ b)", " (s.weightedVSubOfPoint (fun x => p) b) w = (βˆ‘ i ∈ s, w i) β€’ (p -α΅₯ b)", " (s.weightedVSubOfPoint p₁ b) w₁ = (s.weightedVSubOf...
import Batteries.Data.UInt @[ext] theorem Char.ext : {a b : Char} β†’ a.val = b.val β†’ a = b | ⟨_,_⟩, ⟨_,_⟩, rfl => rfl theorem Char.ext_iff {x y : Char} : x = y ↔ x.val = y.val := ⟨congrArg _, Char.ext⟩ theorem Char.le_antisymm_iff {x y : Char} : x = y ↔ x ≀ y ∧ y ≀ x := Char.ext_iff.trans UInt32.le_antisymm_iff ...
.lake/packages/batteries/Batteries/Data/Char.lean
30
31
theorem csize_pos (c) : 0 < csize c := by
rcases csize_eq c with _|_|_|_ <;> simp_all (config := {decide := true})
[]
[]
import Mathlib.Data.ENNReal.Inv #align_import data.real.ennreal from "leanprover-community/mathlib"@"c14c8fcde993801fca8946b0d80131a1a81d1520" open Set NNReal ENNReal namespace ENNReal section iInf variable {ΞΉ : Sort*} {f g : ΞΉ β†’ ℝβ‰₯0∞} variable {a b c d : ℝβ‰₯0∞} {r p q : ℝβ‰₯0} theorem toNNReal_iInf (hf : βˆ€ i, f ...
Mathlib/Data/ENNReal/Real.lean
609
610
theorem add_iInf {a : ℝβ‰₯0∞} : a + iInf f = β¨… b, a + f b := by
rw [add_comm, iInf_add]; simp [add_comm]
[ " (iInf f).toNNReal = β¨… i, (f i).toNNReal", " (β¨… i, ↑(f i)).toNNReal = β¨… i, ((fun i => ↑(f i)) i).toNNReal", " (sInf s).toNNReal = sInf (ENNReal.toNNReal '' s)", " (iSup f).toNNReal = ⨆ i, (f i).toNNReal", " (⨆ i, ↑(f i)).toNNReal = ⨆ i, ((fun i => ↑(f i)) i).toNNReal", " (⨆ i, ↑(f i)).toNNReal = ⨆ i, f i...
[ " (iInf f).toNNReal = β¨… i, (f i).toNNReal", " (β¨… i, ↑(f i)).toNNReal = β¨… i, ((fun i => ↑(f i)) i).toNNReal", " (sInf s).toNNReal = sInf (ENNReal.toNNReal '' s)", " (iSup f).toNNReal = ⨆ i, (f i).toNNReal", " (⨆ i, ↑(f i)).toNNReal = ⨆ i, ((fun i => ↑(f i)) i).toNNReal", " (⨆ i, ↑(f i)).toNNReal = ⨆ i, f i...
import Mathlib.Analysis.Convex.Topology import Mathlib.Analysis.NormedSpace.Pointwise import Mathlib.Analysis.Seminorm import Mathlib.Analysis.LocallyConvex.Bounded import Mathlib.Analysis.RCLike.Basic #align_import analysis.convex.gauge from "leanprover-community/mathlib"@"373b03b5b9d0486534edbe94747f23cb3712f93d" ...
Mathlib/Analysis/Convex/Gauge.lean
66
68
theorem gauge_def' : gauge s x = sInf {r ∈ Set.Ioi (0 : ℝ) | r⁻¹ β€’ x ∈ s} := by
congrm sInf {r | ?_} exact and_congr_right fun hr => mem_smul_set_iff_inv_smul_memβ‚€ hr.ne' _ _
[ " gauge s x = sInf {r | r ∈ Ioi 0 ∧ r⁻¹ β€’ x ∈ s}", " 0 < r ∧ x ∈ r β€’ s ↔ r ∈ Ioi 0 ∧ r⁻¹ β€’ x ∈ s" ]
[]
import Mathlib.Algebra.Group.Fin import Mathlib.Algebra.NeZero import Mathlib.Data.Nat.ModEq import Mathlib.Data.Fintype.Card #align_import data.zmod.defs from "leanprover-community/mathlib"@"3a2b5524a138b5d0b818b858b516d4ac8a484b03" def ZMod : β„• β†’ Type | 0 => β„€ | n + 1 => Fin (n + 1) #align zmod ZMod insta...
Mathlib/Data/ZMod/Defs.lean
124
127
theorem card (n : β„•) [Fintype (ZMod n)] : Fintype.card (ZMod n) = n := by
cases n with | zero => exact (not_finite (ZMod 0)).elim | succ n => convert Fintype.card_fin (n + 1) using 2
[ " Repr (ZMod 0)", " Repr β„€", " Repr (ZMod (n + 1))", " Repr (Fin (n + 1))", " Fintype.card (ZMod n) = n", " Fintype.card (ZMod 0) = 0", " Fintype.card (ZMod (n + 1)) = n + 1" ]
[ " Repr (ZMod 0)", " Repr β„€", " Repr (ZMod (n + 1))", " Repr (Fin (n + 1))" ]
import Mathlib.Algebra.Ring.Prod import Mathlib.GroupTheory.OrderOfElement import Mathlib.Tactic.FinCases #align_import data.zmod.basic from "leanprover-community/mathlib"@"74ad1c88c77e799d2fea62801d1dbbd698cff1b7" assert_not_exists Submodule open Function namespace ZMod instance charZero : CharZero (ZMod 0) :=...
Mathlib/Data/ZMod/Basic.lean
183
186
theorem cast_eq_val [NeZero n] (a : ZMod n) : (cast a : R) = a.val := by
cases n Β· cases NeZero.ne 0 rfl rfl
[ " a.val < n", " a.val < 0", " a.val < n✝ + 1", " (↑a).val = a % n", " (↑a).val = a % 0", " (↑a).val = a", " (↑a).val = a % (n✝ + 1)", " IsUnit n ↔ n.val = 1", " IsUnit n ↔ Int.natAbs n = 1", " n = 1", " βˆ€ (x : β„•), ↑x = 0 ↔ n ∣ x", " ↑k = 0 ↔ n ∣ k", " ↑k = 0 ↔ 0 ∣ k", " ↑k = 0 ↔ n + 1 ∣ k"...
[ " a.val < n", " a.val < 0", " a.val < n✝ + 1", " (↑a).val = a % n", " (↑a).val = a % 0", " (↑a).val = a", " (↑a).val = a % (n✝ + 1)", " IsUnit n ↔ n.val = 1", " IsUnit n ↔ Int.natAbs n = 1", " n = 1", " βˆ€ (x : β„•), ↑x = 0 ↔ n ∣ x", " ↑k = 0 ↔ n ∣ k", " ↑k = 0 ↔ 0 ∣ k", " ↑k = 0 ↔ n + 1 ∣ k"...
import Mathlib.Algebra.Group.Units import Mathlib.Algebra.GroupWithZero.Basic import Mathlib.Logic.Equiv.Defs import Mathlib.Tactic.Contrapose import Mathlib.Tactic.Nontriviality import Mathlib.Tactic.Spread import Mathlib.Util.AssertExists #align_import algebra.group_with_zero.units.basic from "leanprover-community/...
Mathlib/Algebra/GroupWithZero/Units/Basic.lean
118
119
theorem mul_inverse_cancel_right (x y : Mβ‚€) (h : IsUnit x) : y * x * inverse x = y := by
rw [mul_assoc, mul_inverse_cancel x h, mul_one]
[ " 0 = 1", " inverse ↑u = ↑u⁻¹", " x * inverse x = 1", " ↑u * inverse ↑u = 1", " inverse x * x = 1", " inverse ↑u * ↑u = 1", " y * x * inverse x = y" ]
[ " 0 = 1", " inverse ↑u = ↑u⁻¹", " x * inverse x = 1", " ↑u * inverse ↑u = 1", " inverse x * x = 1", " inverse ↑u * ↑u = 1" ]
import Mathlib.CategoryTheory.Limits.Shapes.CommSq import Mathlib.CategoryTheory.Limits.Shapes.StrictInitial import Mathlib.CategoryTheory.Limits.Shapes.Types import Mathlib.Topology.Category.TopCat.Limits.Pullbacks import Mathlib.CategoryTheory.Limits.FunctorCategory import Mathlib.CategoryTheory.Limits.Constructions...
Mathlib/CategoryTheory/Extensive.lean
102
112
theorem FinitaryExtensive.vanKampen [FinitaryExtensive C] {F : Discrete WalkingPair β₯€ C} (c : Cocone F) (hc : IsColimit c) : IsVanKampenColimit c := by
let X := F.obj ⟨WalkingPair.left⟩ let Y := F.obj ⟨WalkingPair.right⟩ have : F = pair X Y := by apply Functor.hext · rintro ⟨⟨⟩⟩ <;> rfl · rintro ⟨⟨⟩⟩ ⟨j⟩ ⟨⟨rfl : _ = j⟩⟩ <;> simp clear_value X Y subst this exact FinitaryExtensive.van_kampen' c hc
[ " IsVanKampenColimit c", " F = pair X Y", " βˆ€ (X_1 : Discrete WalkingPair), F.obj X_1 = (pair X Y).obj X_1", " F.obj { as := WalkingPair.left } = (pair X Y).obj { as := WalkingPair.left }", " F.obj { as := WalkingPair.right } = (pair X Y).obj { as := WalkingPair.right }", " βˆ€ (X_1 Y_1 : Discrete WalkingPa...
[]
import Mathlib.Analysis.Analytic.Composition #align_import analysis.analytic.inverse from "leanprover-community/mathlib"@"284fdd2962e67d2932fa3a79ce19fcf92d38e228" open scoped Classical Topology open Finset Filter namespace FormalMultilinearSeries variable {π•œ : Type*} [NontriviallyNormedField π•œ] {E : Type*} ...
Mathlib/Analysis/Analytic/Inverse.lean
97
148
theorem leftInv_comp (p : FormalMultilinearSeries π•œ E F) (i : E ≃L[π•œ] F) (h : p 1 = (continuousMultilinearCurryFin1 π•œ E F).symm i) : (leftInv p i).comp p = id π•œ E := by
ext (n v) match n with | 0 => simp only [leftInv_coeff_zero, ContinuousMultilinearMap.zero_apply, id_apply_ne_one, Ne, not_false_iff, zero_ne_one, comp_coeff_zero'] | 1 => simp only [leftInv_coeff_one, comp_coeff_one, h, id_apply_one, ContinuousLinearEquiv.coe_apply, ContinuousLinearEquiv.s...
[ " p.leftInv i 0 = 0", " p.leftInv i 1 = (continuousMultilinearCurryFin1 π•œ F E).symm ↑i.symm", " p.removeZero.leftInv i = p.leftInv i", " p.removeZero.leftInv i n = p.leftInv i n", " p.removeZero.leftInv i 0 = p.leftInv i 0", " p.removeZero.leftInv i 1 = p.leftInv i 1", " p.removeZero.leftInv i (n + 2) ...
[ " p.leftInv i 0 = 0", " p.leftInv i 1 = (continuousMultilinearCurryFin1 π•œ F E).symm ↑i.symm", " p.removeZero.leftInv i = p.leftInv i", " p.removeZero.leftInv i n = p.leftInv i n", " p.removeZero.leftInv i 0 = p.leftInv i 0", " p.removeZero.leftInv i 1 = p.leftInv i 1", " p.removeZero.leftInv i (n + 2) ...
import Mathlib.Analysis.SpecialFunctions.Pow.Real import Mathlib.Data.Int.Log #align_import analysis.special_functions.log.base from "leanprover-community/mathlib"@"f23a09ce6d3f367220dc3cecad6b7eb69eb01690" open Set Filter Function open Topology noncomputable section namespace Real variable {b x y : ℝ} -- @...
Mathlib/Analysis/SpecialFunctions/Log/Base.lean
119
120
theorem logb_pow {k : β„•} (hx : 0 < x) : logb b (x ^ k) = k * logb b x := by
rw [← rpow_natCast, logb_rpow_eq_mul_logb_of_pos hx]
[ " b.logb 0 = 0", " b.logb 1 = 0", " False", " b.logb |x| = b.logb x", " b.logb (-x) = b.logb x", " b.logb (x * y) = b.logb x + b.logb y", " b.logb (x / y) = b.logb x - b.logb y", " b.logb x⁻¹ = -b.logb x", " (a.logb b)⁻¹ = b.logb a", " ((a * b).logb c)⁻¹ = (a.logb c)⁻¹ + (b.logb c)⁻¹", " c.logb ...
[ " b.logb 0 = 0", " b.logb 1 = 0", " False", " b.logb |x| = b.logb x", " b.logb (-x) = b.logb x", " b.logb (x * y) = b.logb x + b.logb y", " b.logb (x / y) = b.logb x - b.logb y", " b.logb x⁻¹ = -b.logb x", " (a.logb b)⁻¹ = b.logb a", " ((a * b).logb c)⁻¹ = (a.logb c)⁻¹ + (b.logb c)⁻¹", " c.logb ...
import Mathlib.Data.Set.Image import Mathlib.Data.SProd #align_import data.set.prod from "leanprover-community/mathlib"@"48fb5b5280e7c81672afc9524185ae994553ebf4" open Function namespace Set section Prod variable {Ξ± Ξ² Ξ³ Ξ΄ : Type*} {s s₁ sβ‚‚ : Set Ξ±} {t t₁ tβ‚‚ : Set Ξ²} {a : Ξ±} {b : Ξ²} theorem Subsingleton.pro...
Mathlib/Data/Set/Prod.lean
137
139
theorem inter_prod : (s₁ ∩ sβ‚‚) Γ—Λ’ t = s₁ Γ—Λ’ t ∩ sβ‚‚ Γ—Λ’ t := by
ext ⟨x, y⟩ simp only [← and_and_right, mem_inter_iff, mem_prod]
[ " (βˆƒ x ∈ s Γ—Λ’ t, p x) ↔ βˆƒ x ∈ s, βˆƒ y ∈ t, p (x, y)", " s Γ—Λ’ βˆ… = βˆ…", " x✝ ∈ s Γ—Λ’ βˆ… ↔ x✝ ∈ βˆ…", " βˆ… Γ—Λ’ t = βˆ…", " x✝ ∈ βˆ… Γ—Λ’ t ↔ x✝ ∈ βˆ…", " univ Γ—Λ’ univ = univ", " x✝ ∈ univ Γ—Λ’ univ ↔ x✝ ∈ univ", " univ Γ—Λ’ t = Prod.snd ⁻¹' t", " s Γ—Λ’ univ = Prod.fst ⁻¹' s", " s Γ—Λ’ t = univ ↔ s = univ ∧ t = univ", " {...
[ " (βˆƒ x ∈ s Γ—Λ’ t, p x) ↔ βˆƒ x ∈ s, βˆƒ y ∈ t, p (x, y)", " s Γ—Λ’ βˆ… = βˆ…", " x✝ ∈ s Γ—Λ’ βˆ… ↔ x✝ ∈ βˆ…", " βˆ… Γ—Λ’ t = βˆ…", " x✝ ∈ βˆ… Γ—Λ’ t ↔ x✝ ∈ βˆ…", " univ Γ—Λ’ univ = univ", " x✝ ∈ univ Γ—Λ’ univ ↔ x✝ ∈ univ", " univ Γ—Λ’ t = Prod.snd ⁻¹' t", " s Γ—Λ’ univ = Prod.fst ⁻¹' s", " s Γ—Λ’ t = univ ↔ s = univ ∧ t = univ", " {...
import Mathlib.NumberTheory.ModularForms.SlashInvariantForms import Mathlib.NumberTheory.ModularForms.CongruenceSubgroups noncomputable section open ModularForm UpperHalfPlane Matrix namespace SlashInvariantForm theorem vAdd_width_periodic (N : β„•) (k n : β„€) (f : SlashInvariantForm (Gamma N) k) (z : ℍ) : f ...
Mathlib/NumberTheory/ModularForms/Identities.lean
34
37
theorem T_zpow_width_invariant (N : β„•) (k n : β„€) (f : SlashInvariantForm (Gamma N) k) (z : ℍ) : f (((ModularGroup.T ^ (N * n))) β€’ z) = f z := by
rw [modular_T_zpow_smul z (N * n)] simpa only [Int.cast_mul, Int.cast_natCast] using vAdd_width_periodic N k n f z
[ " f (↑N * ↑n +α΅₯ z) = f z", " f (↑(↑N * n) +α΅₯ z) = f z", " f (ModularGroup.T ^ (↑N * n) β€’ z) = f z", " ↑N ∣ ↑N * n", " f z = (↑(β†‘β†‘β†‘βŸ¨ModularGroup.T ^ (↑N * n), Hn⟩ 1 0) * ↑z + ↑(β†‘β†‘β†‘βŸ¨ModularGroup.T ^ (↑N * n), Hn⟩ 1 1)) ^ k * f z", " f z =\n (↑(↑{ val := β†‘β†‘βŸ¨ModularGroup.T ^ (↑N * n), Hn⟩, inv := ↑(β†‘βŸ¨Modul...
[ " f (↑N * ↑n +α΅₯ z) = f z", " f (↑(↑N * n) +α΅₯ z) = f z", " f (ModularGroup.T ^ (↑N * n) β€’ z) = f z", " ↑N ∣ ↑N * n", " f z = (↑(β†‘β†‘β†‘βŸ¨ModularGroup.T ^ (↑N * n), Hn⟩ 1 0) * ↑z + ↑(β†‘β†‘β†‘βŸ¨ModularGroup.T ^ (↑N * n), Hn⟩ 1 1)) ^ k * f z", " f z =\n (↑(↑{ val := β†‘β†‘βŸ¨ModularGroup.T ^ (↑N * n), Hn⟩, inv := ↑(β†‘βŸ¨Modul...
import Mathlib.Analysis.InnerProductSpace.PiL2 import Mathlib.Analysis.SpecialFunctions.Sqrt import Mathlib.Analysis.NormedSpace.HomeomorphBall #align_import analysis.inner_product_space.calculus from "leanprover-community/mathlib"@"f9dd3204df14a0749cd456fac1e6849dfe7d2b88" noncomputable section open RCLike Real ...
Mathlib/Analysis/InnerProductSpace/Calculus.lean
333
337
theorem hasStrictFDerivAt_euclidean : HasStrictFDerivAt f f' y ↔ βˆ€ i, HasStrictFDerivAt (fun x => f x i) (EuclideanSpace.proj i ∘L f') y := by
rw [← (EuclideanSpace.equiv ΞΉ π•œ).comp_hasStrictFDerivAt_iff, hasStrictFDerivAt_pi'] rfl
[ " DifferentiableWithinAt π•œ f t y ↔ βˆ€ (i : ΞΉ), DifferentiableWithinAt π•œ (fun x => f x i) t y", " (βˆ€ (i : ΞΉ), DifferentiableWithinAt π•œ (fun x => (⇑(EuclideanSpace.equiv ΞΉ π•œ) ∘ f) x i) t y) ↔\n βˆ€ (i : ΞΉ), DifferentiableWithinAt π•œ (fun x => f x i) t y", " DifferentiableAt π•œ f y ↔ βˆ€ (i : ΞΉ), DifferentiableA...
[ " DifferentiableWithinAt π•œ f t y ↔ βˆ€ (i : ΞΉ), DifferentiableWithinAt π•œ (fun x => f x i) t y", " (βˆ€ (i : ΞΉ), DifferentiableWithinAt π•œ (fun x => (⇑(EuclideanSpace.equiv ΞΉ π•œ) ∘ f) x i) t y) ↔\n βˆ€ (i : ΞΉ), DifferentiableWithinAt π•œ (fun x => f x i) t y", " DifferentiableAt π•œ f y ↔ βˆ€ (i : ΞΉ), DifferentiableA...
import Mathlib.Algebra.Module.Submodule.Basic import Mathlib.Topology.Algebra.Monoid import Mathlib.Analysis.Asymptotics.Asymptotics import Mathlib.Algebra.Algebra.Pi #align_import order.filter.zero_and_bounded_at_filter from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" namespace Filt...
Mathlib/Order/Filter/ZeroAndBoundedAtFilter.lean
84
87
theorem ZeroAtFilter.boundedAtFilter [NormedAddCommGroup Ξ²] {l : Filter Ξ±} {f : Ξ± β†’ Ξ²} (hf : ZeroAtFilter l f) : BoundedAtFilter l f := by
rw [ZeroAtFilter, ← Asymptotics.isLittleO_const_iff (one_ne_zero' ℝ)] at hf exact hf.isBigO
[ " l.ZeroAtFilter (f + g)", " l.ZeroAtFilter (-f)", " l.ZeroAtFilter (c β€’ f)", " l.BoundedAtFilter f" ]
[ " l.ZeroAtFilter (f + g)", " l.ZeroAtFilter (-f)", " l.ZeroAtFilter (c β€’ f)" ]
import Mathlib.ModelTheory.Syntax import Mathlib.ModelTheory.Semantics import Mathlib.ModelTheory.Algebra.Ring.Basic import Mathlib.Algebra.Field.MinimalAxioms variable {K : Type*} namespace FirstOrder namespace Field open Language Ring Structure BoundedFormula inductive FieldAxiom : Type | addAssoc : Field...
Mathlib/ModelTheory/Algebra/Field/Basic.lean
81
86
theorem FieldAxiom.realize_toSentence_iff_toProp {K : Type*} [Add K] [Mul K] [Neg K] [Zero K] [One K] [CompatibleRing K] (ax : FieldAxiom) : (K ⊨ (ax.toSentence : Sentence Language.ring)) ↔ ax.toProp K := by
cases ax <;> simp [Sentence.Realize, Formula.Realize, Fin.snoc]
[ " K ⊨ ax.toSentence ↔ toProp K ax", " K ⊨ addAssoc.toSentence ↔ toProp K addAssoc", " K ⊨ zeroAdd.toSentence ↔ toProp K zeroAdd", " K ⊨ addLeftNeg.toSentence ↔ toProp K addLeftNeg", " K ⊨ mulAssoc.toSentence ↔ toProp K mulAssoc", " K ⊨ mulComm.toSentence ↔ toProp K mulComm", " K ⊨ oneMul.toSentence ↔ to...
[]
import Mathlib.Topology.Order.Basic #align_import topology.algebra.order.monotone_convergence from "leanprover-community/mathlib"@"4c19a16e4b705bf135cf9a80ac18fcc99c438514" open Filter Set Function open scoped Classical open Filter Topology variable {Ξ± Ξ² : Type*} class SupConvergenceClass (Ξ± : Type*) [Preorde...
Mathlib/Topology/Order/MonotoneConvergence.lean
96
100
theorem tendsto_atTop_isLUB (h_mono : Monotone f) (ha : IsLUB (Set.range f) a) : Tendsto f atTop (𝓝 a) := by
suffices Tendsto (rangeFactorization f) atTop atTop from (SupConvergenceClass.tendsto_coe_atTop_isLUB _ _ ha).comp this exact h_mono.rangeFactorization.tendsto_atTop_atTop fun b => b.2.imp fun a ha => ha.ge
[ " SupConvergenceClass Ξ±", " βˆ€αΆ  (b_1 : ↑s) in atTop, b < CoeTC.coe b_1", " βˆ€αΆ  (b_1 : ↑s) in atTop, CoeTC.coe b_1 < b", " Tendsto f atTop (𝓝 a)", " Tendsto (rangeFactorization f) atTop atTop" ]
[ " SupConvergenceClass Ξ±", " βˆ€αΆ  (b_1 : ↑s) in atTop, b < CoeTC.coe b_1", " βˆ€αΆ  (b_1 : ↑s) in atTop, CoeTC.coe b_1 < b" ]
import Mathlib.CategoryTheory.Subobject.MonoOver import Mathlib.CategoryTheory.Skeletal import Mathlib.CategoryTheory.ConcreteCategory.Basic import Mathlib.Tactic.ApplyFun import Mathlib.Tactic.CategoryTheory.Elementwise #align_import category_theory.subobject.basic from "leanprover-community/mathlib"@"70fd9563a21e7b...
Mathlib/CategoryTheory/Subobject/Basic.lean
210
213
theorem arrow_congr {A : C} (X Y : Subobject A) (h : X = Y) : eqToHom (congr_arg (fun X : Subobject A => (X : C)) h) ≫ Y.arrow = X.arrow := by
induction h simp
[ " PartialOrder (Subobject X)", " PartialOrder (ThinSkeleton (MonoOver X))", " p P", " βˆ€ (a : MonoOver X), p (Quotient.mk'' a)", " p (Quotient.mk'' a)", " p P Q", " βˆ€ (a₁ aβ‚‚ : MonoOver X), p (Quotient.mk'' a₁) (Quotient.mk'' aβ‚‚)", " p (Quotient.mk'' a) (Quotient.mk'' b)", " eqToHom β‹― ≫ Y.arrow = X.ar...
[ " PartialOrder (Subobject X)", " PartialOrder (ThinSkeleton (MonoOver X))", " p P", " βˆ€ (a : MonoOver X), p (Quotient.mk'' a)", " p (Quotient.mk'' a)", " p P Q", " βˆ€ (a₁ aβ‚‚ : MonoOver X), p (Quotient.mk'' a₁) (Quotient.mk'' aβ‚‚)", " p (Quotient.mk'' a) (Quotient.mk'' b)" ]
import Mathlib.Algebra.Order.Hom.Monoid import Mathlib.SetTheory.Game.Ordinal #align_import set_theory.surreal.basic from "leanprover-community/mathlib"@"8900d545017cd21961daa2a1734bb658ef52c618" universe u namespace SetTheory open scoped PGame namespace PGame def Numeric : PGame β†’ Prop | ⟨_, _, L, R⟩ => (...
Mathlib/SetTheory/Surreal/Basic.lean
71
75
theorem numeric_def {x : PGame} : Numeric x ↔ (βˆ€ i j, x.moveLeft i < x.moveRight j) ∧ (βˆ€ i, Numeric (x.moveLeft i)) ∧ βˆ€ j, Numeric (x.moveRight j) := by
cases x; rfl
[ " x.Numeric ↔\n (βˆ€ (i : x.LeftMoves) (j : x.RightMoves), x.moveLeft i < x.moveRight j) ∧\n (βˆ€ (i : x.LeftMoves), (x.moveLeft i).Numeric) ∧ βˆ€ (j : x.RightMoves), (x.moveRight j).Numeric", " (mk α✝ β✝ a✝¹ a✝).Numeric ↔\n (βˆ€ (i : (mk α✝ β✝ a✝¹ a✝).LeftMoves) (j : (mk α✝ β✝ a✝¹ a✝).RightMoves),\n (m...
[]
import Mathlib.Data.Int.Range import Mathlib.Data.ZMod.Basic import Mathlib.NumberTheory.MulChar.Basic #align_import number_theory.legendre_symbol.zmod_char from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a" namespace ZMod section QuadCharModP @[simps] def Ο‡β‚„ : MulChar (ZMod 4) β„€...
Mathlib/NumberTheory/LegendreSymbol/ZModChar.lean
142
146
theorem isQuadratic_Ο‡β‚ˆ : Ο‡β‚ˆ.IsQuadratic := by
intro a -- Porting note: was `decide!` fin_cases a all_goals decide
[ " βˆ€ (x y : ZMod 4),\n { toFun := ![0, 1, 0, -1], map_one' := β‹― }.toFun (x * y) =\n { toFun := ![0, 1, 0, -1], map_one' := β‹― }.toFun x * { toFun := ![0, 1, 0, -1], map_one' := β‹― }.toFun y", " βˆ€ (a : ZMod 4), Β¬IsUnit a β†’ (↑{ toFun := ![0, 1, 0, -1], map_one' := β‹―, map_mul' := β‹― }).toFun a = 0", " Ο‡β‚„.IsQua...
[ " βˆ€ (x y : ZMod 4),\n { toFun := ![0, 1, 0, -1], map_one' := β‹― }.toFun (x * y) =\n { toFun := ![0, 1, 0, -1], map_one' := β‹― }.toFun x * { toFun := ![0, 1, 0, -1], map_one' := β‹― }.toFun y", " βˆ€ (a : ZMod 4), Β¬IsUnit a β†’ (↑{ toFun := ![0, 1, 0, -1], map_one' := β‹―, map_mul' := β‹― }).toFun a = 0", " Ο‡β‚„.IsQua...
import Mathlib.Algebra.BigOperators.GroupWithZero.Finset import Mathlib.Algebra.Group.Submonoid.Membership import Mathlib.Algebra.Module.LinearMap.Basic import Mathlib.Data.Finset.Preimage import Mathlib.Data.Set.Finite import Mathlib.GroupTheory.GroupAction.BigOperators #align_import data.dfinsupp.basic from "leanpr...
Mathlib/Data/DFinsupp/Basic.lean
144
147
theorem mapRange_id (h : βˆ€ i, id (0 : β₁ i) = 0 := fun i => rfl) (g : Ξ β‚€ i : ΞΉ, β₁ i) : mapRange (fun i => (id : β₁ i β†’ β₁ i)) h g = g := by
ext rfl
[ " { toFun := f₁, support' := sβ‚βœ } = { toFun := fβ‚‚, support' := s₁ }", " { toFun := f₁, support' := sβ‚βœ } = { toFun := f₁, support' := s₁ }", " sβ‚βœ = s₁", " (fun i => f i (x i)) i = 0", " mapRange (fun i => id) h g = g", " (mapRange (fun i => id) h g) i✝ = g i✝" ]
[ " { toFun := f₁, support' := sβ‚βœ } = { toFun := fβ‚‚, support' := s₁ }", " { toFun := f₁, support' := sβ‚βœ } = { toFun := f₁, support' := s₁ }", " sβ‚βœ = s₁", " (fun i => f i (x i)) i = 0" ]
import Mathlib.CategoryTheory.Abelian.Basic #align_import category_theory.idempotents.basic from "leanprover-community/mathlib"@"3a061790136d13594ec10c7c90d202335ac5d854" open CategoryTheory open CategoryTheory.Category open CategoryTheory.Limits open CategoryTheory.Preadditive open Opposite namespace Catego...
Mathlib/CategoryTheory/Idempotents/Basic.lean
143
154
theorem split_iff_of_iso {X X' : C} (Ο† : X β‰… X') (p : X ⟢ X) (p' : X' ⟢ X') (hpp' : p ≫ Ο†.hom = Ο†.hom ≫ p') : (βˆƒ (Y : C) (i : Y ⟢ X) (e : X ⟢ Y), i ≫ e = πŸ™ Y ∧ e ≫ i = p) ↔ βˆƒ (Y' : C) (i' : Y' ⟢ X') (e' : X' ⟢ Y'), i' ≫ e' = πŸ™ Y' ∧ e' ≫ i' = p' := by
constructor Β· exact split_imp_of_iso Ο† p p' hpp' Β· apply split_imp_of_iso Ο†.symm p' p rw [← comp_id p, ← Ο†.hom_inv_id] slice_rhs 2 3 => rw [hpp'] slice_rhs 1 2 => erw [Ο†.inv_hom_id] simp only [id_comp] rfl
[ " IsIdempotentComplete C ↔ βˆ€ (X : C) (p : X ⟢ X), p ≫ p = p β†’ HasEqualizer (πŸ™ X) p", " IsIdempotentComplete C β†’ βˆ€ (X : C) (p : X ⟢ X), p ≫ p = p β†’ HasEqualizer (πŸ™ X) p", " βˆ€ (X : C) (p : X ⟢ X), p ≫ p = p β†’ HasEqualizer (πŸ™ X) p", " HasEqualizer (πŸ™ X) p", " i ≫ πŸ™ X = i ≫ p", " IsLimit (Fork.ofΞΉ i β‹―)",...
[ " IsIdempotentComplete C ↔ βˆ€ (X : C) (p : X ⟢ X), p ≫ p = p β†’ HasEqualizer (πŸ™ X) p", " IsIdempotentComplete C β†’ βˆ€ (X : C) (p : X ⟢ X), p ≫ p = p β†’ HasEqualizer (πŸ™ X) p", " βˆ€ (X : C) (p : X ⟢ X), p ≫ p = p β†’ HasEqualizer (πŸ™ X) p", " HasEqualizer (πŸ™ X) p", " i ≫ πŸ™ X = i ≫ p", " IsLimit (Fork.ofΞΉ i β‹―)",...
import Mathlib.Data.Finset.Fold import Mathlib.Algebra.GCDMonoid.Multiset #align_import algebra.gcd_monoid.finset from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" #align_import algebra.gcd_monoid.div from "leanprover-community/mathlib"@"b537794f8409bc9598febb79cd510b1df5f4539d" variab...
Mathlib/Algebra/GCDMonoid/Finset.lean
181
181
theorem normalize_gcd : normalize (s.gcd f) = s.gcd f := by
simp [gcd_def]
[ " a ∣ s.gcd f ↔ βˆ€ b ∈ s, a ∣ f b", " (βˆ€ b ∈ Multiset.map f s.val, a ∣ b) ↔ βˆ€ b ∈ s, a ∣ f b", " (βˆ€ (b : Ξ±), βˆ€ x ∈ s.val, f x = b β†’ a ∣ b) ↔ βˆ€ b ∈ s, a ∣ f b", " (insert b s).gcd f = GCDMonoid.gcd (f b) (s.gcd f)", " normalize (s.gcd f) = s.gcd f" ]
[ " a ∣ s.gcd f ↔ βˆ€ b ∈ s, a ∣ f b", " (βˆ€ b ∈ Multiset.map f s.val, a ∣ b) ↔ βˆ€ b ∈ s, a ∣ f b", " (βˆ€ (b : Ξ±), βˆ€ x ∈ s.val, f x = b β†’ a ∣ b) ↔ βˆ€ b ∈ s, a ∣ f b", " (insert b s).gcd f = GCDMonoid.gcd (f b) (s.gcd f)" ]
import Mathlib.Topology.Compactness.Compact open Set Filter Topology TopologicalSpace Classical variable {X : Type*} {Y : Type*} {ΞΉ : Type*} variable [TopologicalSpace X] [TopologicalSpace Y] {s t : Set X} instance [WeaklyLocallyCompactSpace X] [WeaklyLocallyCompactSpace Y] : WeaklyLocallyCompactSpace (X Γ— Y) ...
Mathlib/Topology/Compactness/LocallyCompact.lean
40
45
theorem exists_compact_superset [WeaklyLocallyCompactSpace X] {K : Set X} (hK : IsCompact K) : βˆƒ K', IsCompact K' ∧ K βŠ† interior K' := by
choose s hc hmem using fun x : X ↦ exists_compact_mem_nhds x rcases hK.elim_nhds_subcover _ fun x _ ↦ interior_mem_nhds.2 (hmem x) with ⟨I, -, hIK⟩ refine βŸ¨β‹ƒ x ∈ I, s x, I.isCompact_biUnion fun _ _ ↦ hc _, hIK.trans ?_⟩ exact iUnionβ‚‚_subset fun x hx ↦ interior_mono <| subset_iUnionβ‚‚ (s := fun x _ ↦ s x) x hx
[ " βˆƒ s, IsCompact s ∧ s ∈ 𝓝 f", " βˆƒ K', IsCompact K' ∧ K βŠ† interior K'", " ⋃ x ∈ I, interior (s x) βŠ† interior (⋃ x ∈ I, s x)" ]
[ " βˆƒ s, IsCompact s ∧ s ∈ 𝓝 f" ]
import Mathlib.Data.Matrix.Basic import Mathlib.Data.PEquiv #align_import data.matrix.pequiv from "leanprover-community/mathlib"@"3e068ece210655b7b9a9477c3aff38a492400aa1" namespace PEquiv open Matrix universe u v variable {k l m n : Type*} variable {Ξ± : Type v} open Matrix def toMatrix [DecidableEq n] [Zer...
Mathlib/Data/Matrix/PEquiv.lean
142
148
theorem toMatrix_swap [DecidableEq n] [Ring Ξ±] (i j : n) : (Equiv.swap i j).toPEquiv.toMatrix = (1 : Matrix n n Ξ±) - (single i i).toMatrix - (single j j).toMatrix + (single i j).toMatrix + (single j i).toMatrix := by
ext dsimp [toMatrix, single, Equiv.swap_apply_def, Equiv.toPEquiv, one_apply] split_ifs <;> simp_all
[ " (f.toMatrix * M) i j = Option.casesOn (f i) 0 fun fi => M fi j", " βˆ‘ j_1 : m, (if j_1 ∈ f i then 1 else 0) * M j_1 j = Option.rec 0 (fun val => M val j) (f i)", " βˆ‘ j_1 : m, (if j_1 ∈ none then 1 else 0) * M j_1 j = Option.rec 0 (fun val => M val j) none", " βˆ‘ j_1 : m, (if j_1 ∈ some fi then 1 else 0) * M j...
[ " (f.toMatrix * M) i j = Option.casesOn (f i) 0 fun fi => M fi j", " βˆ‘ j_1 : m, (if j_1 ∈ f i then 1 else 0) * M j_1 j = Option.rec 0 (fun val => M val j) (f i)", " βˆ‘ j_1 : m, (if j_1 ∈ none then 1 else 0) * M j_1 j = Option.rec 0 (fun val => M val j) none", " βˆ‘ j_1 : m, (if j_1 ∈ some fi then 1 else 0) * M j...
import Mathlib.Data.List.Join #align_import data.list.permutation from "leanprover-community/mathlib"@"dd71334db81d0bd444af1ee339a29298bef40734" -- Make sure we don't import algebra assert_not_exists Monoid open Nat variable {Ξ± Ξ² : Type*} namespace List theorem permutationsAux2_fst (t : Ξ±) (ts : List Ξ±) (r : L...
Mathlib/Data/List/Permutation.lean
149
164
theorem mem_permutationsAux2 {t : Ξ±} {ts : List Ξ±} {ys : List Ξ±} {l l' : List Ξ±} : l' ∈ (permutationsAux2 t ts [] ys (l ++ Β·)).2 ↔ βˆƒ l₁ lβ‚‚, lβ‚‚ β‰  [] ∧ ys = l₁ ++ lβ‚‚ ∧ l' = l ++ l₁ ++ t :: lβ‚‚ ++ ts := by
induction' ys with y ys ih generalizing l Β· simp (config := { contextual := true }) rw [permutationsAux2_snd_cons, show (fun x : List Ξ± => l ++ y :: x) = (l ++ [y] ++ Β·) by funext _; simp, mem_cons, ih] constructor Β· rintro (rfl | ⟨l₁, lβ‚‚, l0, rfl, rfl⟩) Β· exact ⟨[], y :: ys, by simp⟩ Β· exact ⟨y ...
[ " (permutationsAux2 t ts r (y :: ys) f).1 = y :: ys ++ ts", " (permutationsAux2 t ts r (y :: ys) f).2 = f (t :: y :: ys ++ ts) :: (permutationsAux2 t ts r ys fun x => f (y :: x)).2", " (permutationsAux2 t ts [] ys f).2 ++ r = (permutationsAux2 t ts r ys f).2", " (permutationsAux2 t ts [] [] f).2 ++ r = (permu...
[ " (permutationsAux2 t ts r (y :: ys) f).1 = y :: ys ++ ts", " (permutationsAux2 t ts r (y :: ys) f).2 = f (t :: y :: ys ++ ts) :: (permutationsAux2 t ts r ys fun x => f (y :: x)).2", " (permutationsAux2 t ts [] ys f).2 ++ r = (permutationsAux2 t ts r ys f).2", " (permutationsAux2 t ts [] [] f).2 ++ r = (permu...
import Mathlib.Init.Function import Mathlib.Logic.Function.Basic #align_import data.sigma.basic from "leanprover-community/mathlib"@"a148d797a1094ab554ad4183a4ad6f130358ef64" open Function section Sigma variable {Ξ± α₁ Ξ±β‚‚ : Type*} {Ξ² : Ξ± β†’ Type*} {β₁ : α₁ β†’ Type*} {Ξ²β‚‚ : Ξ±β‚‚ β†’ Type*} namespace Sigma instance inst...
Mathlib/Data/Sigma/Basic.lean
70
71
theorem ext_iff {xβ‚€ x₁ : Sigma Ξ²} : xβ‚€ = x₁ ↔ xβ‚€.1 = x₁.1 ∧ HEq xβ‚€.2 x₁.2 := by
cases xβ‚€; cases x₁; exact Sigma.mk.inj_iff
[ " a₁ = aβ‚‚ ∧ HEq b₁ bβ‚‚", " a₁ = a₁ ∧ HEq b₁ b₁", " ⟨a₁, bβ‚βŸ© = ⟨aβ‚‚, bβ‚‚βŸ©", " ⟨a₁, bβ‚βŸ© = ⟨a₁, bβ‚‚βŸ©", " xβ‚€ = x₁ ↔ xβ‚€.fst = x₁.fst ∧ HEq xβ‚€.snd x₁.snd", " ⟨fst✝, snd✝⟩ = x₁ ↔ ⟨fst✝, snd✝⟩.fst = x₁.fst ∧ HEq ⟨fst✝, snd✝⟩.snd x₁.snd", " ⟨fst✝¹, snd✝¹⟩ = ⟨fst✝, snd✝⟩ ↔ ⟨fst✝¹, snd✝¹⟩.fst = ⟨fst✝, snd✝⟩.fst ∧ HEq ...
[ " a₁ = aβ‚‚ ∧ HEq b₁ bβ‚‚", " a₁ = a₁ ∧ HEq b₁ b₁", " ⟨a₁, bβ‚βŸ© = ⟨aβ‚‚, bβ‚‚βŸ©", " ⟨a₁, bβ‚βŸ© = ⟨a₁, bβ‚‚βŸ©" ]
import Mathlib.Analysis.SpecialFunctions.Pow.Complex import Qq #align_import analysis.special_functions.pow.real from "leanprover-community/mathlib"@"4fa54b337f7d52805480306db1b1439c741848c8" noncomputable section open scoped Classical open Real ComplexConjugate open Finset Set namespace Real variable {x y z...
Mathlib/Analysis/SpecialFunctions/Pow/Real.lean
115
117
theorem rpow_def_of_nonpos {x : ℝ} (hx : x ≀ 0) (y : ℝ) : x ^ y = if x = 0 then if y = 0 then 1 else 0 else exp (log x * y) * cos (y * Ο€) := by
split_ifs with h <;> simp [rpow_def, *]; exact rpow_def_of_neg (lt_of_le_of_ne hx h) _
[ " x ^ y = if x = 0 then if y = 0 then 1 else 0 else rexp (x.log * y)", " (if ↑x = 0 then if ↑y = 0 then 1 else 0 else ((↑x).log * ↑y).exp).re =\n if x = 0 then if y = 0 then 1 else 0 else rexp (x.log * y)", " Complex.re 1 = 1", " Complex.re 1 = 0", " Complex.re 1 = rexp (x.log * y)", " Complex.re 0 = 1...
[ " x ^ y = if x = 0 then if y = 0 then 1 else 0 else rexp (x.log * y)", " (if ↑x = 0 then if ↑y = 0 then 1 else 0 else ((↑x).log * ↑y).exp).re =\n if x = 0 then if y = 0 then 1 else 0 else rexp (x.log * y)", " Complex.re 1 = 1", " Complex.re 1 = 0", " Complex.re 1 = rexp (x.log * y)", " Complex.re 0 = 1...
import Mathlib.MeasureTheory.Measure.Haar.InnerProductSpace import Mathlib.MeasureTheory.Measure.Lebesgue.EqHaar import Mathlib.MeasureTheory.Integral.SetIntegral #align_import measure_theory.measure.haar.normed_space from "leanprover-community/mathlib"@"b84aee748341da06a6d78491367e2c0e9f15e8a5" noncomputable sect...
Mathlib/MeasureTheory/Measure/Haar/NormedSpace.lean
105
107
theorem integral_comp_inv_smul_of_nonneg (f : E β†’ F) {R : ℝ} (hR : 0 ≀ R) : ∫ x, f (R⁻¹ β€’ x) βˆ‚ΞΌ = R ^ finrank ℝ E β€’ ∫ x, f x βˆ‚ΞΌ := by
rw [integral_comp_inv_smul ΞΌ f R, abs_of_nonneg (pow_nonneg hR _)]
[ " NoAtoms ΞΌ", " ∫ (x : E), f (R β€’ x) βˆ‚ΞΌ = |(R ^ finrank ℝ E)⁻¹| β€’ ∫ (x : E), f x βˆ‚ΞΌ", " ∫ (x : E), f (0 β€’ x) βˆ‚ΞΌ = |(0 ^ finrank ℝ E)⁻¹| β€’ ∫ (x : E), f x βˆ‚ΞΌ", " (ΞΌ univ).toReal β€’ f 0 = |(0 ^ finrank ℝ E)⁻¹| β€’ ∫ (x : E), f x βˆ‚ΞΌ", " f = fun x => f 0", " f x = f 0", "E : Type u_1\ninst✝⁷ : NormedAddCommGrou...
[ " NoAtoms ΞΌ", " ∫ (x : E), f (R β€’ x) βˆ‚ΞΌ = |(R ^ finrank ℝ E)⁻¹| β€’ ∫ (x : E), f x βˆ‚ΞΌ", " ∫ (x : E), f (0 β€’ x) βˆ‚ΞΌ = |(0 ^ finrank ℝ E)⁻¹| β€’ ∫ (x : E), f x βˆ‚ΞΌ", " (ΞΌ univ).toReal β€’ f 0 = |(0 ^ finrank ℝ E)⁻¹| β€’ ∫ (x : E), f x βˆ‚ΞΌ", " f = fun x => f 0", " f x = f 0", "E : Type u_1\ninst✝⁷ : NormedAddCommGrou...
import Mathlib.CategoryTheory.Adjunction.FullyFaithful import Mathlib.CategoryTheory.Adjunction.Limits import Mathlib.CategoryTheory.Limits.Shapes.CommSq import Mathlib.CategoryTheory.Limits.Shapes.StrictInitial import Mathlib.CategoryTheory.Limits.FunctorCategory import Mathlib.CategoryTheory.Limits.Constructions.Fin...
Mathlib/CategoryTheory/Limits/VanKampen.lean
75
80
theorem mapPair_equifibered {F F' : Discrete WalkingPair β₯€ C} (Ξ± : F ⟢ F') : NatTrans.Equifibered Ξ± := by
rintro ⟨⟨⟩⟩ ⟨j⟩ ⟨⟨rfl : _ = j⟩⟩ all_goals dsimp; simp only [Discrete.functor_map_id] exact IsPullback.of_horiz_isIso ⟨by simp only [Category.comp_id, Category.id_comp]⟩
[ " NatTrans.Equifibered Ξ±", " IsPullback (F.map { down := { down := β‹― } }) (Ξ±.app { as := WalkingPair.right })\n (Ξ±.app { as := { as := WalkingPair.right }.as }) (F'.map { down := { down := β‹― } })", " IsPullback (F.map { down := { down := β‹― } }) (Ξ±.app { as := WalkingPair.left })\n (Ξ±.app { as := { as := W...
[]
import Mathlib.LinearAlgebra.FiniteDimensional #align_import linear_algebra.projective_space.basic from "leanprover-community/mathlib"@"c4658a649d216f57e99621708b09dcb3dcccbd23" variable (K V : Type*) [DivisionRing K] [AddCommGroup V] [Module K V] def projectivizationSetoid : Setoid { v : V // v β‰  0 } := (MulA...
Mathlib/LinearAlgebra/Projectivization/Basic.lean
137
139
theorem submodule_eq (v : β„™ K V) : v.submodule = K βˆ™ v.rep := by
conv_lhs => rw [← v.mk_rep] rfl
[ " βˆ€ (a b : { v // v β‰  0 }), Setoid.r a b β†’ Submodule.span K {↑a} = Submodule.span K {↑b}", " Submodule.span K {β†‘βŸ¨x β€’ b, ha⟩} = Submodule.span K {β†‘βŸ¨b, hb⟩}", " mk K v hv = mk K w hw ↔ βˆƒ a, a β€’ w = v", " (βˆƒ a, a β€’ w = v) ↔ βˆƒ a, a β€’ w = v", " (βˆƒ a, a β€’ w = v) β†’ βˆƒ a, a β€’ w = v", " βˆƒ a, a β€’ w = v", " 0 = v",...
[ " βˆ€ (a b : { v // v β‰  0 }), Setoid.r a b β†’ Submodule.span K {↑a} = Submodule.span K {↑b}", " Submodule.span K {β†‘βŸ¨x β€’ b, ha⟩} = Submodule.span K {β†‘βŸ¨b, hb⟩}", " mk K v hv = mk K w hw ↔ βˆƒ a, a β€’ w = v", " (βˆƒ a, a β€’ w = v) ↔ βˆƒ a, a β€’ w = v", " (βˆƒ a, a β€’ w = v) β†’ βˆƒ a, a β€’ w = v", " βˆƒ a, a β€’ w = v", " 0 = v" ...
import Mathlib.Algebra.Group.Submonoid.Pointwise #align_import group_theory.submonoid.inverses from "leanprover-community/mathlib"@"59694bd07f0a39c5beccba34bd9f413a160782bf" variable {M : Type*} namespace Submonoid @[to_additive] noncomputable instance [Monoid M] : Group (IsUnit.submonoid M) := { inferInstanc...
Mathlib/GroupTheory/Submonoid/Inverses.lean
73
76
theorem leftInv_leftInv_le : S.leftInv.leftInv ≀ S := by
rintro x ⟨⟨y, z, hβ‚βŸ©, hβ‚‚ : x * y = 1⟩ convert z.prop rw [← mul_one x, ← h₁, ← mul_assoc, hβ‚‚, one_mul]
[ " a * b = b * a", " a * _b * ↑(b' * a') = 1", " S.leftInv.leftInv ≀ S", " x ∈ S", " x = ↑z" ]
[ " a * b = b * a", " a * _b * ↑(b' * a') = 1" ]
import Mathlib.CategoryTheory.Idempotents.Basic import Mathlib.CategoryTheory.Preadditive.AdditiveFunctor import Mathlib.CategoryTheory.Equivalence #align_import category_theory.idempotents.karoubi from "leanprover-community/mathlib"@"200eda15d8ff5669854ff6bcc10aaf37cb70498f" noncomputable section open CategoryT...
Mathlib/CategoryTheory/Idempotents/Karoubi.lean
94
94
theorem p_comm {P Q : Karoubi C} (f : Hom P Q) : P.p ≫ f.f = f.f ≫ Q.p := by
rw [p_comp, comp_p]
[ " P = Q", " { X := X✝, p := p✝, idem := idem✝ } = Q", " { X := X✝¹, p := p✝¹, idem := idem✝¹ } = { X := X✝, p := p✝, idem := idem✝ }", " { X := X✝, p := p✝¹, idem := idem✝¹ } = { X := X✝, p := p✝, idem := idem✝ }", " 0 = P.p ≫ 0 ≫ Q.p", " P.p ≫ f.f = f.f", " f.f ≫ Q.p = f.f", " P.p ≫ f.f = f.f ≫ Q.p" ...
[ " P = Q", " { X := X✝, p := p✝, idem := idem✝ } = Q", " { X := X✝¹, p := p✝¹, idem := idem✝¹ } = { X := X✝, p := p✝, idem := idem✝ }", " { X := X✝, p := p✝¹, idem := idem✝¹ } = { X := X✝, p := p✝, idem := idem✝ }", " 0 = P.p ≫ 0 ≫ Q.p", " P.p ≫ f.f = f.f", " f.f ≫ Q.p = f.f" ]
import Mathlib.LinearAlgebra.Matrix.Spectrum import Mathlib.LinearAlgebra.QuadraticForm.Basic #align_import linear_algebra.matrix.pos_def from "leanprover-community/mathlib"@"07992a1d1f7a4176c6d3f160209608be4e198566" open scoped ComplexOrder namespace Matrix variable {m n R π•œ : Type*} variable [Fintype m] [Fint...
Mathlib/LinearAlgebra/Matrix/PosDef.lean
81
87
theorem submatrix {M : Matrix n n R} (hM : M.PosSemidef) (e : m β†’ n) : (M.submatrix e e).PosSemidef := by
classical rw [(by simp : M = 1 * M * 1), submatrix_mul (heβ‚‚ := Function.bijective_id), submatrix_mul (heβ‚‚ := Function.bijective_id), submatrix_id_id] simpa only [conjTranspose_submatrix, conjTranspose_one] using conjTranspose_mul_mul_same hM (Matrix.submatrix 1 id e)
[ " (diagonal d).PosSemidef ↔ βˆ€ (i : n), 0 ≀ d i", " 0 ≀ d i", " (βˆ€ (i : n), 0 ≀ d i) β†’ (diagonal d).PosSemidef", " βˆ€ (x : n β†’ R), 0 ≀ star x ⬝α΅₯ diagonal d *α΅₯ x", " 0 ≀ star x i * (diagonal d *α΅₯ x) i", " (Bα΄΄ * A * B).PosSemidef", " (Bα΄΄ * A * B).IsHermitian", " βˆ€ (x : m β†’ R), 0 ≀ star x ⬝α΅₯ (Bα΄΄ * A * B) *...
[ " (diagonal d).PosSemidef ↔ βˆ€ (i : n), 0 ≀ d i", " 0 ≀ d i", " (βˆ€ (i : n), 0 ≀ d i) β†’ (diagonal d).PosSemidef", " βˆ€ (x : n β†’ R), 0 ≀ star x ⬝α΅₯ diagonal d *α΅₯ x", " 0 ≀ star x i * (diagonal d *α΅₯ x) i", " (Bα΄΄ * A * B).PosSemidef", " (Bα΄΄ * A * B).IsHermitian", " βˆ€ (x : m β†’ R), 0 ≀ star x ⬝α΅₯ (Bα΄΄ * A * B) *...
import Mathlib.Control.EquivFunctor import Mathlib.CategoryTheory.Groupoid import Mathlib.CategoryTheory.Whiskering import Mathlib.CategoryTheory.Types #align_import category_theory.core from "leanprover-community/mathlib"@"369525b73f229ccd76a6ec0e0e0bf2be57599768" namespace CategoryTheory universe v₁ vβ‚‚ u₁ uβ‚‚ -...
Mathlib/CategoryTheory/Core.lean
52
53
theorem id_hom (X : C) : Iso.hom (coreCategory.id X) = @CategoryStruct.id C _ X := by
rfl
[ " (πŸ™ X).hom = πŸ™ X" ]
[]
import Mathlib.ModelTheory.Syntax import Mathlib.ModelTheory.Semantics import Mathlib.Algebra.Ring.Equiv variable {Ξ± : Type*} namespace FirstOrder open FirstOrder inductive ringFunc : β„• β†’ Type | add : ringFunc 2 | mul : ringFunc 2 | neg : ringFunc 1 | zero : ringFunc 0 | one : ringFunc 0 deriving D...
Mathlib/ModelTheory/Algebra/Ring/Basic.lean
195
196
theorem realize_zero (v : Ξ± β†’ R) : Term.realize v (0 : ring.Term Ξ±) = 0 := by
simp [zero_def, funMap_zero, constantMap]
[ " DecidableEq (ring.Functions n)", " DecidableEq (ringFunc n)", " DecidableEq (ring.Relations n)", " DecidableEq Empty", " (↑[Sum.inl ⟨2, add⟩, Sum.inl ⟨2, mul⟩, Sum.inl ⟨1, neg⟩, Sum.inl ⟨0, zero⟩, Sum.inl ⟨0, one⟩]).Nodup", " βˆ€ (x : ring.Symbols),\n x ∈\n { val := ↑[Sum.inl ⟨2, add⟩, Sum.inl ⟨2,...
[ " DecidableEq (ring.Functions n)", " DecidableEq (ringFunc n)", " DecidableEq (ring.Relations n)", " DecidableEq Empty", " (↑[Sum.inl ⟨2, add⟩, Sum.inl ⟨2, mul⟩, Sum.inl ⟨1, neg⟩, Sum.inl ⟨0, zero⟩, Sum.inl ⟨0, one⟩]).Nodup", " βˆ€ (x : ring.Symbols),\n x ∈\n { val := ↑[Sum.inl ⟨2, add⟩, Sum.inl ⟨2,...
import Mathlib.Analysis.Calculus.FDeriv.Add import Mathlib.Analysis.Calculus.FDeriv.Equiv import Mathlib.Analysis.Calculus.FDeriv.Prod import Mathlib.Analysis.Calculus.Monotone import Mathlib.Data.Set.Function import Mathlib.Algebra.Group.Basic import Mathlib.Tactic.WLOG #align_import analysis.bounded_variation from ...
Mathlib/Analysis/BoundedVariation.lean
127
130
theorem sum_le_of_monotoneOn_Iic (f : Ξ± β†’ E) {s : Set Ξ±} {n : β„•} {u : β„• β†’ Ξ±} (hu : MonotoneOn u (Iic n)) (us : βˆ€ i ≀ n, u i ∈ s) : (βˆ‘ i ∈ Finset.range n, edist (f (u (i + 1))) (f (u i))) ≀ eVariationOn f s := by
simpa using sum_le_of_monotoneOn_Icc f (m := 0) (hu.mono Icc_subset_Iic_self) fun i hi ↦ us i hi.2
[ " Nonempty { u // Monotone u ∧ βˆ€ (i : β„•), u i ∈ s }", " eVariationOn f s = eVariationOn f' s", " ⨆ p, βˆ‘ i ∈ Finset.range p.1, edist (f (↑p.2 (i + 1))) (f (↑p.2 i)) =\n ⨆ p, βˆ‘ i ∈ Finset.range p.1, edist (f' (↑p.2 (i + 1))) (f' (↑p.2 i))", " βˆ‘ i ∈ Finset.range p.1, edist (f (↑p.2 (i + 1))) (f (↑p.2 i)) =\n ...
[ " Nonempty { u // Monotone u ∧ βˆ€ (i : β„•), u i ∈ s }", " eVariationOn f s = eVariationOn f' s", " ⨆ p, βˆ‘ i ∈ Finset.range p.1, edist (f (↑p.2 (i + 1))) (f (↑p.2 i)) =\n ⨆ p, βˆ‘ i ∈ Finset.range p.1, edist (f' (↑p.2 (i + 1))) (f' (↑p.2 i))", " βˆ‘ i ∈ Finset.range p.1, edist (f (↑p.2 (i + 1))) (f (↑p.2 i)) =\n ...
import Mathlib.Algebra.Group.Equiv.TypeTags import Mathlib.GroupTheory.FreeAbelianGroup import Mathlib.GroupTheory.FreeGroup.IsFreeGroup import Mathlib.LinearAlgebra.Dimension.StrongRankCondition #align_import group_theory.free_abelian_group_finsupp from "leanprover-community/mathlib"@"47b51515e69f59bca5cf34ef456e600...
Mathlib/GroupTheory/FreeAbelianGroupFinsupp.lean
87
89
theorem toFinsupp_toFreeAbelianGroup (f : X β†’β‚€ β„€) : FreeAbelianGroup.toFinsupp (Finsupp.toFreeAbelianGroup f) = f := by
rw [← AddMonoidHom.comp_apply, toFinsupp_comp_toFreeAbelianGroup, AddMonoidHom.id_apply]
[ " toFreeAbelianGroup.comp (singleAddHom x) = (smulAddHom β„€ (FreeAbelianGroup X)).flip (of x)", " (toFreeAbelianGroup.comp (singleAddHom x)) 1 = ((smulAddHom β„€ (FreeAbelianGroup X)).flip (of x)) 1", " toFinsupp.comp toFreeAbelianGroup = AddMonoidHom.id (X β†’β‚€ β„€)", " (((toFinsupp.comp toFreeAbelianGroup).comp (s...
[ " toFreeAbelianGroup.comp (singleAddHom x) = (smulAddHom β„€ (FreeAbelianGroup X)).flip (of x)", " (toFreeAbelianGroup.comp (singleAddHom x)) 1 = ((smulAddHom β„€ (FreeAbelianGroup X)).flip (of x)) 1", " toFinsupp.comp toFreeAbelianGroup = AddMonoidHom.id (X β†’β‚€ β„€)", " (((toFinsupp.comp toFreeAbelianGroup).comp (s...
import Mathlib.Topology.Constructions import Mathlib.Topology.Algebra.Monoid import Mathlib.Order.Filter.ListTraverse import Mathlib.Tactic.AdaptationNote #align_import topology.list from "leanprover-community/mathlib"@"48085f140e684306f9e7da907cd5932056d1aded" open TopologicalSpace Set Filter open Topology Filt...
Mathlib/Topology/List.lean
28
66
theorem nhds_list (as : List Ξ±) : 𝓝 as = traverse 𝓝 as := by
refine nhds_mkOfNhds _ _ ?_ ?_ Β· intro l induction l with | nil => exact le_rfl | cons a l ih => suffices List.cons <$> pure a <*> pure l ≀ List.cons <$> 𝓝 a <*> traverse 𝓝 l by simpa only [functor_norm] using this exact Filter.seq_mono (Filter.map_mono <| pure_le_nhds a) ih Β· i...
[ " 𝓝 as = traverse 𝓝 as", " pure ≀ traverse 𝓝", " pure l ≀ traverse 𝓝 l", " pure [] ≀ traverse 𝓝 []", " pure (a :: l) ≀ traverse 𝓝 (a :: l)", " (Seq.seq (List.cons <$> pure a) fun x => pure l) ≀ Seq.seq (List.cons <$> 𝓝 a) fun x => traverse 𝓝 l", " βˆ€ (a : List Ξ±), βˆ€ s ∈ traverse 𝓝 a, βˆ€αΆ  (y : Lis...
[]
import Mathlib.Probability.Martingale.BorelCantelli import Mathlib.Probability.ConditionalExpectation import Mathlib.Probability.Independence.Basic #align_import probability.borel_cantelli from "leanprover-community/mathlib"@"2f8347015b12b0864dfaf366ec4909eb70c78740" open scoped MeasureTheory ProbabilityTheory EN...
Mathlib/Probability/BorelCantelli.lean
74
105
theorem measure_limsup_eq_one {s : β„• β†’ Set Ξ©} (hsm : βˆ€ n, MeasurableSet (s n)) (hs : iIndepSet s ΞΌ) (hs' : (βˆ‘' n, ΞΌ (s n)) = ∞) : ΞΌ (limsup s atTop) = 1 := by
rw [measure_congr (eventuallyEq_set.2 (ae_mem_limsup_atTop_iff ΞΌ <| measurableSet_filtrationOfSet' hsm) : (limsup s atTop : Set Ξ©) =ᡐ[ΞΌ] {Ο‰ | Tendsto (fun n => βˆ‘ k ∈ Finset.range n, (ΞΌ[(s (k + 1)).indicator (1 : Ξ© β†’ ℝ)|filtrationOfSet hsm k]) Ο‰) atTop atTop})] suffices {Ο‰ | Tendsto (fun n => βˆ‘ k ...
[ " Indep (MeasurableSpace.comap (f j) mΞ²) (↑(Filtration.natural f hf) i) ΞΌ", " Indep (⨆ k ∈ {j}, MeasurableSpace.comap (f k) mΞ²) (⨆ k ∈ {k | k ≀ i}, MeasurableSpace.comap (f k) mΞ²) ΞΌ", " Disjoint {j} {k | k ≀ i}", " ΞΌ[(s j).indicator fun x => 1|↑(filtrationOfSet hsm) i] =αΆ [ae ΞΌ] fun x => (ΞΌ (s j)).toReal", "...
[ " Indep (MeasurableSpace.comap (f j) mΞ²) (↑(Filtration.natural f hf) i) ΞΌ", " Indep (⨆ k ∈ {j}, MeasurableSpace.comap (f k) mΞ²) (⨆ k ∈ {k | k ≀ i}, MeasurableSpace.comap (f k) mΞ²) ΞΌ", " Disjoint {j} {k | k ≀ i}", " ΞΌ[(s j).indicator fun x => 1|↑(filtrationOfSet hsm) i] =αΆ [ae ΞΌ] fun x => (ΞΌ (s j)).toReal", "...
import Mathlib.Data.Set.Pairwise.Basic import Mathlib.Order.Bounds.Basic import Mathlib.Order.Directed import Mathlib.Order.Hom.Set #align_import order.antichain from "leanprover-community/mathlib"@"c227d107bbada5d0d9d20287e3282c0a7f1651a0" open Function Set section General variable {Ξ± Ξ² : Type*} {r r₁ rβ‚‚ : Ξ± β†’...
Mathlib/Order/Antichain.lean
120
124
theorem image_relEmbedding (hs : IsAntichain r s) (Ο† : r β†ͺr r') : IsAntichain r' (Ο† '' s) := by
intro b hb b' hb' h₁ hβ‚‚ rw [Set.mem_image] at hb hb' obtain ⟨⟨a, has, rfl⟩, ⟨a', has', rfl⟩⟩ := hb, hb' exact hs has has' (fun haa' => h₁ (by rw [haa'])) (Ο†.map_rel_iff.mp hβ‚‚)
[ " s.Subsingleton", " a = b", " IsAntichain r' (f '' s)", " False", " IsAntichain r' (⇑φ '' s)", " Ο† a = Ο† a'" ]
[ " s.Subsingleton", " a = b", " IsAntichain r' (f '' s)", " False" ]
import Mathlib.RingTheory.AdjoinRoot import Mathlib.FieldTheory.Minpoly.Field import Mathlib.RingTheory.Polynomial.GaussLemma #align_import field_theory.minpoly.is_integrally_closed from "leanprover-community/mathlib"@"f0c8bf9245297a541f468be517f1bde6195105e9" open scoped Classical Polynomial open Polynomial Set...
Mathlib/FieldTheory/Minpoly/IsIntegrallyClosed.lean
61
64
theorem isIntegrallyClosed_eq_field_fractions' [IsDomain S] [Algebra K S] [IsScalarTower R K S] {s : S} (hs : IsIntegral R s) : minpoly K s = (minpoly R s).map (algebraMap R K) := by
let L := FractionRing S rw [← isIntegrallyClosed_eq_field_fractions K L hs, algebraMap_eq (IsFractionRing.injective S L)]
[ " minpoly K ((algebraMap S L) s) = map (algebraMap R K) (minpoly R s)", " Irreducible (map (algebraMap R K) (minpoly R s))", " (Polynomial.aeval ((algebraMap S L) s)) (map (algebraMap R K) (minpoly R s)) = 0", " (map (algebraMap R K) (minpoly R s)).Monic", " minpoly K s = map (algebraMap R K) (minpoly R s)"...
[ " minpoly K ((algebraMap S L) s) = map (algebraMap R K) (minpoly R s)", " Irreducible (map (algebraMap R K) (minpoly R s))", " (Polynomial.aeval ((algebraMap S L) s)) (map (algebraMap R K) (minpoly R s)) = 0", " (map (algebraMap R K) (minpoly R s)).Monic" ]
import Mathlib.Analysis.Asymptotics.AsymptoticEquivalent import Mathlib.Analysis.Calculus.FDeriv.Linear import Mathlib.Analysis.Calculus.FDeriv.Comp #align_import analysis.calculus.fderiv.equiv from "leanprover-community/mathlib"@"e3fb84046afd187b710170887195d50bada934ee" open Filter Asymptotics ContinuousLinearMa...
Mathlib/Analysis/Calculus/FDeriv/Equiv.lean
104
107
theorem comp_differentiableAt_iff {f : G β†’ E} {x : G} : DifferentiableAt π•œ (iso ∘ f) x ↔ DifferentiableAt π•œ f x := by
rw [← differentiableWithinAt_univ, ← differentiableWithinAt_univ, iso.comp_differentiableWithinAt_iff]
[ " DifferentiableWithinAt π•œ (⇑iso ∘ f) s x ↔ DifferentiableWithinAt π•œ f s x", " DifferentiableWithinAt π•œ f s x", " DifferentiableAt π•œ (⇑iso ∘ f) x ↔ DifferentiableAt π•œ f x" ]
[ " DifferentiableWithinAt π•œ (⇑iso ∘ f) s x ↔ DifferentiableWithinAt π•œ f s x", " DifferentiableWithinAt π•œ f s x" ]
import Mathlib.Data.Finset.Lattice #align_import combinatorics.set_family.compression.down from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" variable {Ξ± : Type*} [DecidableEq Ξ±] {π’œ ℬ : Finset (Finset Ξ±)} {s : Finset Ξ±} {a : Ξ±} namespace Finset def nonMemberSubfamily (a : Ξ±) (π’œ : ...
Mathlib/Combinatorics/SetFamily/Compression/Down.lean
86
88
theorem memberSubfamily_union (a : Ξ±) (π’œ ℬ : Finset (Finset Ξ±)) : (π’œ βˆͺ ℬ).memberSubfamily a = π’œ.memberSubfamily a βˆͺ ℬ.memberSubfamily a := by
simp_rw [memberSubfamily, filter_union, image_union]
[ " s ∈ nonMemberSubfamily a π’œ ↔ s ∈ π’œ ∧ a βˆ‰ s", " s ∈ memberSubfamily a π’œ ↔ insert a s ∈ π’œ ∧ a βˆ‰ s", " (βˆƒ a_1, (a_1 ∈ π’œ ∧ a ∈ a_1) ∧ a_1.erase a = s) ↔ insert a s ∈ π’œ ∧ a βˆ‰ s", " a ∈ insert a s", " (βˆƒ a_1, (a_1 ∈ π’œ ∧ a ∈ a_1) ∧ a_1.erase a = s) β†’ insert a s ∈ π’œ ∧ a βˆ‰ s", " insert a (s.erase a) ∈ π’œ...
[ " s ∈ nonMemberSubfamily a π’œ ↔ s ∈ π’œ ∧ a βˆ‰ s", " s ∈ memberSubfamily a π’œ ↔ insert a s ∈ π’œ ∧ a βˆ‰ s", " (βˆƒ a_1, (a_1 ∈ π’œ ∧ a ∈ a_1) ∧ a_1.erase a = s) ↔ insert a s ∈ π’œ ∧ a βˆ‰ s", " a ∈ insert a s", " (βˆƒ a_1, (a_1 ∈ π’œ ∧ a ∈ a_1) ∧ a_1.erase a = s) β†’ insert a s ∈ π’œ ∧ a βˆ‰ s", " insert a (s.erase a) ∈ π’œ...
import Mathlib.CategoryTheory.Category.Grpd import Mathlib.CategoryTheory.Groupoid import Mathlib.Topology.Category.TopCat.Basic import Mathlib.Topology.Homotopy.Path import Mathlib.Data.Set.Subsingleton #align_import algebraic_topology.fundamental_groupoid.basic from "leanprover-community/mathlib"@"3d7987cda72abc473...
Mathlib/AlgebraicTopology/FundamentalGroupoid/Basic.lean
200
202
theorem transAssocReparamAux_mem_I (t : I) : transAssocReparamAux t ∈ I := by
unfold transAssocReparamAux split_ifs <;> constructor <;> linarith [unitInterval.le_one t, unitInterval.nonneg t]
[ " Continuous reflTransSymmAux", " Continuous fun x => ↑x.2", " Continuous fun x => 1 / 2", " Continuous fun x => ↑x.1 * 2 * ↑x.2", " Continuous fun x => ↑x.1 * (2 - 2 * ↑x.2)", " βˆ€ (x : ↑I Γ— ↑I), ↑x.2 = 1 / 2 β†’ ↑x.1 * 2 * ↑x.2 = ↑x.1 * (2 - 2 * ↑x.2)", " ↑x.1 * 2 * ↑x.2 = ↑x.1 * (2 - 2 * ↑x.2)", " ref...
[ " Continuous reflTransSymmAux", " Continuous fun x => ↑x.2", " Continuous fun x => 1 / 2", " Continuous fun x => ↑x.1 * 2 * ↑x.2", " Continuous fun x => ↑x.1 * (2 - 2 * ↑x.2)", " βˆ€ (x : ↑I Γ— ↑I), ↑x.2 = 1 / 2 β†’ ↑x.1 * 2 * ↑x.2 = ↑x.1 * (2 - 2 * ↑x.2)", " ↑x.1 * 2 * ↑x.2 = ↑x.1 * (2 - 2 * ↑x.2)", " ref...
import Mathlib.Order.Interval.Finset.Nat import Mathlib.Data.PNat.Defs #align_import data.pnat.interval from "leanprover-community/mathlib"@"1d29de43a5ba4662dd33b5cfeecfc2a27a5a8a29" open Finset Function PNat namespace PNat variable (a b : β„•+) instance instLocallyFiniteOrder : LocallyFiniteOrder β„•+ := Subtype....
Mathlib/Data/PNat/Interval.lean
113
114
theorem card_fintype_Ico : Fintype.card (Set.Ico a b) = b - a := by
rw [← card_Ico, Fintype.card_ofFinset]
[ " (Icc a b).card = ↑b + 1 - ↑a", " (Icc a b).card = (Icc ↑a ↑b).card", " (Icc a b).card = (map (Embedding.subtype fun n => 0 < n) (Icc a b)).card", " (Ico a b).card = ↑b - ↑a", " (Ico a b).card = (Ico ↑a ↑b).card", " (Ico a b).card = (map (Embedding.subtype fun n => 0 < n) (Ico a b)).card", " (Ioc a b)....
[ " (Icc a b).card = ↑b + 1 - ↑a", " (Icc a b).card = (Icc ↑a ↑b).card", " (Icc a b).card = (map (Embedding.subtype fun n => 0 < n) (Icc a b)).card", " (Ico a b).card = ↑b - ↑a", " (Ico a b).card = (Ico ↑a ↑b).card", " (Ico a b).card = (map (Embedding.subtype fun n => 0 < n) (Ico a b)).card", " (Ioc a b)....
import Mathlib.Algebra.Polynomial.AlgebraMap import Mathlib.Algebra.Polynomial.BigOperators import Mathlib.Algebra.Polynomial.Degree.Lemmas import Mathlib.Algebra.Polynomial.Div #align_import data.polynomial.ring_division from "leanprover-community/mathlib"@"8efcf8022aac8e01df8d302dcebdbc25d6a886c8" noncomputable ...
Mathlib/Algebra/Polynomial/RingDivision.lean
427
436
theorem le_rootMultiplicity_iff {p : R[X]} (p0 : p β‰  0) {a : R} {n : β„•} : n ≀ rootMultiplicity a p ↔ (X - C a) ^ n ∣ p := by
classical rw [rootMultiplicity_eq_nat_find_of_nonzero p0, @Nat.le_find_iff _ (_)] simp_rw [Classical.not_not] refine ⟨fun h => ?_, fun h m hm => (pow_dvd_pow _ hm).trans h⟩ cases' n with n; · rw [pow_zero] apply one_dvd; · exact h n n.lt_succ_self
[ " n ≀ rootMultiplicity a p ↔ (X - C a) ^ n ∣ p", " (βˆ€ m < n, ¬¬(X - C a) ^ (m + 1) ∣ p) ↔ (X - C a) ^ n ∣ p", " (βˆ€ m < n, (X - C a) ^ (m + 1) ∣ p) ↔ (X - C a) ^ n ∣ p", " (X - C a) ^ n ∣ p", " (X - C a) ^ 0 ∣ p", " 1 ∣ p", " (X - C a) ^ (n + 1) ∣ p" ]
[]
import Mathlib.AlgebraicGeometry.Spec import Mathlib.Algebra.Category.Ring.Constructions import Mathlib.CategoryTheory.Elementwise #align_import algebraic_geometry.Scheme from "leanprover-community/mathlib"@"88474d1b5af6d37c2ab728b757771bced7f5194c" -- Explicit universe annotations were used in this file to improv...
Mathlib/AlgebraicGeometry/Scheme.lean
155
157
theorem congr_app {X Y : Scheme} {f g : X ⟢ Y} (e : f = g) (U) : f.val.c.app U = g.val.c.app U ≫ X.presheaf.map (eqToHom (by subst e; rfl)) := by
subst e; dsimp; simp
[ " U = U", " { unop := U } = { unop := U }", " { unop := { carrier := carrier✝, is_open' := is_open'✝ } } =\n { unop := { carrier := carrier✝, is_open' := is_open'✝ } }", " (f ≫ g).val.base x = g.val.base (f.val.base x)", " (Opens.map g.val.base).op.obj U = (Opens.map f.val.base).op.obj U", " (Opens.map...
[ " U = U", " { unop := U } = { unop := U }", " { unop := { carrier := carrier✝, is_open' := is_open'✝ } } =\n { unop := { carrier := carrier✝, is_open' := is_open'✝ } }", " (f ≫ g).val.base x = g.val.base (f.val.base x)" ]
import Mathlib.Algebra.Homology.Single #align_import algebra.homology.augment from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a" noncomputable section open CategoryTheory Limits HomologicalComplex universe v u variable {V : Type u} [Category.{v} V] namespace ChainComplex @[simps]...
Mathlib/Algebra/Homology/Augment.lean
92
94
theorem augment_d_succ_succ (C : ChainComplex V β„•) {X : V} (f : C.X 0 ⟢ X) (w : C.d 1 0 ≫ f = 0) (i j : β„•) : (augment C f w).d (i + 1) (j + 1) = C.d i j := by
cases i <;> rfl
[ " Β¬(ComplexShape.down β„•).Rel (i + 1) (j + 1)", " (truncate.obj C).d 1 0 ≫ C.d 1 0 = 0", " (fun x x_1 =>\n match x, x_1 with\n | 1, 0 => f\n | i.succ, j.succ => C.d i j\n | x, x_2 => 0)\n (i + 1) (j + 1) =\n 0", " C.d i j = 0", " (C.augment f w).d (i + 1) (j + 1) = C.d i j...
[ " Β¬(ComplexShape.down β„•).Rel (i + 1) (j + 1)", " (truncate.obj C).d 1 0 ≫ C.d 1 0 = 0", " (fun x x_1 =>\n match x, x_1 with\n | 1, 0 => f\n | i.succ, j.succ => C.d i j\n | x, x_2 => 0)\n (i + 1) (j + 1) =\n 0", " C.d i j = 0" ]
import Mathlib.Data.Int.GCD import Mathlib.Tactic.NormNum namespace Tactic namespace NormNum
Mathlib/Tactic/NormNum/GCD.lean
22
28
theorem int_gcd_helper' {d : β„•} {x y : β„€} (a b : β„€) (h₁ : (d : β„€) ∣ x) (hβ‚‚ : (d : β„€) ∣ y) (h₃ : x * a + y * b = d) : Int.gcd x y = d := by
refine Nat.dvd_antisymm ?_ (Int.natCast_dvd_natCast.1 (Int.dvd_gcd h₁ hβ‚‚)) rw [← Int.natCast_dvd_natCast, ← h₃] apply dvd_add Β· exact Int.gcd_dvd_left.mul_right _ Β· exact Int.gcd_dvd_right.mul_right _
[ " x.gcd y = d", " x.gcd y ∣ d", " ↑(x.gcd y) ∣ x * a + y * b", " ↑(x.gcd y) ∣ x * a", " ↑(x.gcd y) ∣ y * b" ]
[]
import Mathlib.Algebra.EuclideanDomain.Instances import Mathlib.RingTheory.Ideal.Colon import Mathlib.RingTheory.UniqueFactorizationDomain #align_import ring_theory.principal_ideal_domain from "leanprover-community/mathlib"@"6010cf523816335f7bae7f8584cb2edaace73940" universe u v variable {R : Type u} {M : Type v...
Mathlib/RingTheory/PrincipalIdealDomain.lean
109
111
theorem mem_iff_eq_smul_generator (S : Submodule R M) [S.IsPrincipal] {x : M} : x ∈ S ↔ βˆƒ s : R, x = s β€’ generator S := by
simp_rw [@eq_comm _ x, ← mem_span_singleton, span_singleton_generator]
[ " βŠ₯ = span R {0}", " IsPrincipal S", " IsPrincipal βŠ₯", " IsPrincipal ⊀", " generator S ∈ S", "R : Type u\nM : Type v\ninst✝³ : AddCommGroup M\ninst✝² : Ring R\ninst✝¹ : Module R M\nS : Submodule R M\ninst✝ : S.IsPrincipal\n| S", " generator S ∈ span R {generator S}", " x ∈ S ↔ βˆƒ s, x = s β€’ generator S...
[ " βŠ₯ = span R {0}", " IsPrincipal S", " IsPrincipal βŠ₯", " IsPrincipal ⊀", " generator S ∈ S", "R : Type u\nM : Type v\ninst✝³ : AddCommGroup M\ninst✝² : Ring R\ninst✝¹ : Module R M\nS : Submodule R M\ninst✝ : S.IsPrincipal\n| S", " generator S ∈ span R {generator S}" ]
import Mathlib.Probability.Kernel.Composition #align_import probability.kernel.invariance from "leanprover-community/mathlib"@"3b92d54a05ee592aa2c6181a4e76b1bb7cc45d0b" open MeasureTheory open scoped MeasureTheory ENNReal ProbabilityTheory namespace ProbabilityTheory variable {Ξ± Ξ² Ξ³ : Type*} {mΞ± : MeasurableSp...
Mathlib/Probability/Kernel/Invariance.lean
57
60
theorem const_bind_eq_comp_const (ΞΊ : kernel Ξ± Ξ²) (ΞΌ : Measure Ξ±) : const Ξ± (ΞΌ.bind ΞΊ) = ΞΊ βˆ˜β‚– const Ξ± ΞΌ := by
ext a s hs simp_rw [comp_apply' _ _ _ hs, const_apply, Measure.bind_apply hs (kernel.measurable _)]
[ " (ΞΌ + Ξ½).bind ⇑κ = ΞΌ.bind ⇑κ + Ξ½.bind ⇑κ", " ((ΞΌ + Ξ½).bind ⇑κ) s = (ΞΌ.bind ⇑κ + Ξ½.bind ⇑κ) s", " (r β€’ ΞΌ).bind ⇑κ = r β€’ ΞΌ.bind ⇑κ", " ((r β€’ ΞΌ).bind ⇑κ) s = (r β€’ ΞΌ.bind ⇑κ) s", " const Ξ± (ΞΌ.bind ⇑κ) = ΞΊ βˆ˜β‚– const Ξ± ΞΌ", " ((const Ξ± (ΞΌ.bind ⇑κ)) a) s = ((ΞΊ βˆ˜β‚– const Ξ± ΞΌ) a) s" ]
[ " (ΞΌ + Ξ½).bind ⇑κ = ΞΌ.bind ⇑κ + Ξ½.bind ⇑κ", " ((ΞΌ + Ξ½).bind ⇑κ) s = (ΞΌ.bind ⇑κ + Ξ½.bind ⇑κ) s", " (r β€’ ΞΌ).bind ⇑κ = r β€’ ΞΌ.bind ⇑κ", " ((r β€’ ΞΌ).bind ⇑κ) s = (r β€’ ΞΌ.bind ⇑κ) s" ]
import Mathlib.MeasureTheory.Measure.Haar.Basic import Mathlib.Analysis.InnerProductSpace.PiL2 #align_import measure_theory.measure.haar.of_basis from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" open Set TopologicalSpace MeasureTheory MeasureTheory.Measure FiniteDimensional open sco...
Mathlib/MeasureTheory/Measure/Haar/OfBasis.lean
57
65
theorem parallelepiped_basis_eq (b : Basis ΞΉ ℝ E) : parallelepiped b = {x | βˆ€ i, b.repr x i ∈ Set.Icc 0 1} := by
classical ext x simp_rw [mem_parallelepiped_iff, mem_setOf_eq, b.ext_elem_iff, _root_.map_sum, _root_.map_smul, Finset.sum_apply', Basis.repr_self, Finsupp.smul_single, smul_eq_mul, mul_one, Finsupp.single_apply, Finset.sum_ite_eq', Finset.mem_univ, ite_true, mem_Icc, Pi.le_def, Pi.zero_apply, Pi.one...
[ " x ∈ parallelepiped v ↔ βˆƒ t ∈ Icc 0 1, x = βˆ‘ i : ΞΉ, t i β€’ v i", " parallelepiped ⇑b = {x | βˆ€ (i : ΞΉ), (b.repr x) i ∈ Icc 0 1}", " x ∈ parallelepiped ⇑b ↔ x ∈ {x | βˆ€ (i : ΞΉ), (b.repr x) i ∈ Icc 0 1}", " (βˆƒ t, βˆ€ (x_1 : ΞΉ), (0 ≀ t x_1 ∧ t x_1 ≀ 1) ∧ (b.repr x) x_1 = t x_1) ↔ βˆ€ (i : ΞΉ), 0 ≀ (b.repr x) i ∧ (b.rep...
[ " x ∈ parallelepiped v ↔ βˆƒ t ∈ Icc 0 1, x = βˆ‘ i : ΞΉ, t i β€’ v i" ]
import Mathlib.Algebra.BigOperators.Group.Finset import Mathlib.Data.Fintype.Card #align_import data.multiset.fintype from "leanprover-community/mathlib"@"e3d9ab8faa9dea8f78155c6c27d62a621f4c152d" variable {Ξ± : Type*} [DecidableEq Ξ±] {m : Multiset Ξ±} def Multiset.ToType (m : Multiset Ξ±) : Type _ := (x : Ξ±) Γ— Fi...
Mathlib/Data/Multiset/Fintype.lean
122
126
theorem Multiset.toEnumFinset_mono {m₁ mβ‚‚ : Multiset Ξ±} (h : m₁ ≀ mβ‚‚) : m₁.toEnumFinset βŠ† mβ‚‚.toEnumFinset := by
intro p simp only [Multiset.mem_toEnumFinset] exact gt_of_ge_of_gt (Multiset.le_iff_count.mp h p.1)
[ " 0 < count x.fst m", " βˆ€ (x : Ξ± Γ— β„•),\n (x ∈ m.toFinset.biUnion fun x => Finset.map { toFun := Prod.mk x, inj' := β‹― } (Finset.range (Multiset.count x m))) ↔\n x ∈ {p | p.2 < Multiset.count p.1 m}", " ((x, i) ∈\n m.toFinset.biUnion fun x => Finset.map { toFun := Prod.mk x, inj' := β‹― } (Finset.range...
[ " 0 < count x.fst m", " βˆ€ (x : Ξ± Γ— β„•),\n (x ∈ m.toFinset.biUnion fun x => Finset.map { toFun := Prod.mk x, inj' := β‹― } (Finset.range (Multiset.count x m))) ↔\n x ∈ {p | p.2 < Multiset.count p.1 m}", " ((x, i) ∈\n m.toFinset.biUnion fun x => Finset.map { toFun := Prod.mk x, inj' := β‹― } (Finset.range...
import Mathlib.Algebra.MvPolynomial.Supported import Mathlib.RingTheory.WittVector.Truncated #align_import ring_theory.witt_vector.mul_coeff from "leanprover-community/mathlib"@"2f5b500a507264de86d666a5f87ddb976e2d8de4" noncomputable section namespace WittVector variable (p : β„•) [hp : Fact p.Prime] variable {k ...
Mathlib/RingTheory/WittVector/MulCoeff.lean
145
176
theorem mul_polyOfInterest_aux3 (n : β„•) : wittPolyProd p (n + 1) = -((p : 𝕄) ^ (n + 1) * X (0, n + 1)) * ((p : 𝕄) ^ (n + 1) * X (1, n + 1)) + (p : 𝕄) ^ (n + 1) * X (0, n + 1) * rename (Prod.mk (1 : Fin 2)) (wittPolynomial p β„€ (n + 1)) + (p : 𝕄) ^ (n + 1) * X (1, n + 1) * rename (Prod.mk (0 : Fin 2)) (wi...
-- a useful auxiliary fact have mvpz : (p : 𝕄) ^ (n + 1) = MvPolynomial.C ((p : β„€) ^ (n + 1)) := by norm_cast -- Porting note: the original proof applies `sum_range_succ` through a non-`conv` rewrite, -- but this does not work in Lean 4; the whole proof also times out very badly. The proof has been -- nearl...
[ " (wittPolyProd p n).vars βŠ† univ Γ—Λ’ range (n + 1)", " ((rename (Prod.mk 0)) (wittPolynomial p β„€ n) * (rename (Prod.mk 1)) (wittPolynomial p β„€ n)).vars βŠ†\n univ Γ—Λ’ range (n + 1)", " ((rename (Prod.mk 0)) (wittPolynomial p β„€ n)).vars βˆͺ ((rename (Prod.mk 1)) (wittPolynomial p β„€ n)).vars βŠ†\n univ Γ—Λ’ range (n ...
[ " (wittPolyProd p n).vars βŠ† univ Γ—Λ’ range (n + 1)", " ((rename (Prod.mk 0)) (wittPolynomial p β„€ n) * (rename (Prod.mk 1)) (wittPolynomial p β„€ n)).vars βŠ†\n univ Γ—Λ’ range (n + 1)", " ((rename (Prod.mk 0)) (wittPolynomial p β„€ n)).vars βˆͺ ((rename (Prod.mk 1)) (wittPolynomial p β„€ n)).vars βŠ†\n univ Γ—Λ’ range (n ...
import Mathlib.Data.Set.Lattice import Mathlib.Data.Set.Pairwise.Basic #align_import data.set.pairwise.lattice from "leanprover-community/mathlib"@"c4c2ed622f43768eff32608d4a0f8a6cec1c047d" open Function Set Order variable {Ξ± Ξ² Ξ³ ΞΉ ΞΉ' : Type*} {ΞΊ : Sort*} {r p q : Ξ± β†’ Ξ± β†’ Prop} section Pairwise variable {f g : ...
Mathlib/Data/Set/Pairwise/Lattice.lean
89
101
theorem PairwiseDisjoint.prod_left {f : ΞΉ Γ— ΞΉ' β†’ Ξ±} (hs : s.PairwiseDisjoint fun i => ⨆ i' ∈ t, f (i, i')) (ht : t.PairwiseDisjoint fun i' => ⨆ i ∈ s, f (i, i')) : (s Γ—Λ’ t : Set (ΞΉ Γ— ΞΉ')).PairwiseDisjoint f := by
rintro ⟨i, i'⟩ hi ⟨j, j'⟩ hj h rw [mem_prod] at hi hj obtain rfl | hij := eq_or_ne i j Β· refine (ht hi.2 hj.2 <| (Prod.mk.inj_left _).ne_iff.1 h).mono ?_ ?_ Β· convert le_iSupβ‚‚ (Ξ± := Ξ±) i hi.1; rfl Β· convert le_iSupβ‚‚ (Ξ± := Ξ±) i hj.1; rfl Β· refine (hs hi.1 hj.1 hij).mono ?_ ?_ Β· convert le_iSupβ‚‚ (Ξ±...
[ " (⋃ i ∈ s, g i).PairwiseDisjoint f", " (Disjoint on f) a b", " (s Γ—Λ’ t).PairwiseDisjoint f", " (Disjoint on f) (i, i') (j, j')", " (Disjoint on f) (i, i') (i, j')", " f (i, i') ≀ (fun i' => ⨆ i ∈ s, f (i, i')) (i, i').2", " f (i, i') = f (i, (i, i').2)", " f (i, j') ≀ (fun i' => ⨆ i ∈ s, f (i, i')) (...
[ " (⋃ i ∈ s, g i).PairwiseDisjoint f", " (Disjoint on f) a b" ]
import Mathlib.Algebra.CharP.ExpChar import Mathlib.Algebra.GeomSum import Mathlib.Algebra.MvPolynomial.CommRing import Mathlib.Algebra.MvPolynomial.Equiv import Mathlib.RingTheory.Polynomial.Content import Mathlib.RingTheory.UniqueFactorizationDomain #align_import ring_theory.polynomial.basic from "leanprover-commun...
Mathlib/RingTheory/Polynomial/Basic.lean
117
133
theorem degreeLT_eq_span_X_pow [DecidableEq R] {n : β„•} : degreeLT R n = Submodule.span R ↑((Finset.range n).image fun n => X ^ n : Finset R[X]) := by
apply le_antisymm Β· intro p hp replace hp := mem_degreeLT.1 hp rw [← Polynomial.sum_monomial_eq p, Polynomial.sum] refine Submodule.sum_mem _ fun k hk => ?_ have := WithBot.coe_lt_coe.1 ((Finset.sup_lt_iff <| WithBot.bot_lt_coe n).1 hp k hk) rw [← C_mul_X_pow_eq_monomial, C_mul'] refine ...
[ " ↑n = 0 ↔ p ∣ n", " ExpChar R[X] p", " f ∈ degreeLE R n ↔ f.degree ≀ n", " (βˆ€ (i : β„•), ↑i > n β†’ (lcoeff R i) f = 0) ↔ βˆ€ (m : β„•), n < ↑m β†’ f.coeff m = 0", " degreeLE R ↑n = Submodule.span R ↑(image (fun n => X ^ n) (range (n + 1)))", " degreeLE R ↑n ≀ Submodule.span R ↑(image (fun n => X ^ n) (range (n + ...
[ " ↑n = 0 ↔ p ∣ n", " ExpChar R[X] p", " f ∈ degreeLE R n ↔ f.degree ≀ n", " (βˆ€ (i : β„•), ↑i > n β†’ (lcoeff R i) f = 0) ↔ βˆ€ (m : β„•), n < ↑m β†’ f.coeff m = 0", " degreeLE R ↑n = Submodule.span R ↑(image (fun n => X ^ n) (range (n + 1)))", " degreeLE R ↑n ≀ Submodule.span R ↑(image (fun n => X ^ n) (range (n + ...
import Mathlib.Algebra.Group.Defs #align_import group_theory.eckmann_hilton from "leanprover-community/mathlib"@"41cf0cc2f528dd40a8f2db167ea4fb37b8fde7f3" universe u namespace EckmannHilton variable {X : Type u} local notation a " <" m:51 "> " b => m a b structure IsUnital (m : X β†’ X β†’ X) (e : X) extends Std...
Mathlib/GroupTheory/EckmannHilton.lean
64
69
theorem mul : m₁ = mβ‚‚ := by
funext a b calc m₁ a b = m₁ (mβ‚‚ a e₁) (mβ‚‚ e₁ b) := by { simp only [one h₁ hβ‚‚ distrib, h₁.left_id, h₁.right_id, hβ‚‚.left_id, hβ‚‚.right_id] } _ = mβ‚‚ a b := by simp only [distrib, h₁.left_id, h₁.right_id, hβ‚‚.left_id, hβ‚‚.right_id]
[ " e₁ = eβ‚‚", " m₁ = mβ‚‚", " m₁ a b = mβ‚‚ a b", " m₁ a b = m₁ (mβ‚‚ a e₁) (mβ‚‚ e₁ b)", " m₁ (mβ‚‚ a e₁) (mβ‚‚ e₁ b) = mβ‚‚ a b" ]
[ " e₁ = eβ‚‚" ]
import Mathlib.Init.Function #align_import data.option.n_ary from "leanprover-community/mathlib"@"995b47e555f1b6297c7cf16855f1023e355219fb" universe u open Function namespace Option variable {Ξ± Ξ² Ξ³ Ξ΄ : Type*} {f : Ξ± β†’ Ξ² β†’ Ξ³} {a : Option Ξ±} {b : Option Ξ²} {c : Option Ξ³} def mapβ‚‚ (f : Ξ± β†’ Ξ² β†’ Ξ³) (a : Option Ξ±) ...
Mathlib/Data/Option/NAry.lean
109
110
theorem map_uncurry (f : Ξ± β†’ Ξ² β†’ Ξ³) (x : Option (Ξ± Γ— Ξ²)) : x.map (uncurry f) = mapβ‚‚ f (x.map Prod.fst) (x.map Prod.snd) := by
cases x <;> rfl
[ " mapβ‚‚ f a b = Seq.seq (f <$> a) fun x => b", " mapβ‚‚ f none b = Seq.seq (f <$> none) fun x => b", " mapβ‚‚ f (some val✝) b = Seq.seq (f <$> some val✝) fun x => b", " mapβ‚‚ f a none = none", " mapβ‚‚ f none none = none", " mapβ‚‚ f (some val✝) none = none", " mapβ‚‚ f a (some b) = Option.map (fun a => f a b) a", ...
[ " mapβ‚‚ f a b = Seq.seq (f <$> a) fun x => b", " mapβ‚‚ f none b = Seq.seq (f <$> none) fun x => b", " mapβ‚‚ f (some val✝) b = Seq.seq (f <$> some val✝) fun x => b", " mapβ‚‚ f a none = none", " mapβ‚‚ f none none = none", " mapβ‚‚ f (some val✝) none = none", " mapβ‚‚ f a (some b) = Option.map (fun a => f a b) a", ...
import Mathlib.Analysis.SpecialFunctions.Complex.Log import Mathlib.RingTheory.RootsOfUnity.Basic #align_import ring_theory.roots_of_unity.complex from "leanprover-community/mathlib"@"7fdeecc0d03cd40f7a165e6cf00a4d2286db599f" namespace Complex open Polynomial Real open scoped Nat Real
Mathlib/RingTheory/RootsOfUnity/Complex.lean
33
50
theorem isPrimitiveRoot_exp_of_coprime (i n : β„•) (h0 : n β‰  0) (hi : i.Coprime n) : IsPrimitiveRoot (exp (2 * Ο€ * I * (i / n))) n := by
rw [IsPrimitiveRoot.iff_def] simp only [← exp_nat_mul, exp_eq_one_iff] have hn0 : (n : β„‚) β‰  0 := mod_cast h0 constructor Β· use i field_simp [hn0, mul_comm (i : β„‚), mul_comm (n : β„‚)] Β· simp only [hn0, mul_right_comm _ _ ↑n, mul_left_inj' two_pi_I_ne_zero, Ne, not_false_iff, mul_comm _ (i : β„‚), ← m...
[ " IsPrimitiveRoot (cexp (2 * ↑π * I * (↑i / ↑n))) n", " cexp (2 * ↑π * I * (↑i / ↑n)) ^ n = 1 ∧ βˆ€ (l : β„•), cexp (2 * ↑π * I * (↑i / ↑n)) ^ l = 1 β†’ n ∣ l", " (βˆƒ n_1, ↑n * (2 * ↑π * I * (↑i / ↑n)) = ↑n_1 * (2 * ↑π * I)) ∧\n βˆ€ (l : β„•), (βˆƒ n_1, ↑l * (2 * ↑π * I * (↑i / ↑n)) = ↑n_1 * (2 * ↑π * I)) β†’ n ∣ l", " βˆƒ...
[]
import Mathlib.Topology.Order.LeftRightNhds open Set Filter TopologicalSpace Topology Function open OrderDual (toDual ofDual) variable {Ξ± Ξ² Ξ³ : Type*} section OrderTopology variable [TopologicalSpace Ξ±] [TopologicalSpace Ξ²] [LinearOrder Ξ±] [LinearOrder Ξ²] [OrderTopology Ξ±] [OrderTopology Ξ²] theorem IsLUB.fr...
Mathlib/Topology/Order/IsLUB.lean
77
80
theorem isLUB_of_mem_closure {s : Set α} {a : α} (hsa : a ∈ upperBounds s) (hsf : a ∈ closure s) : IsLUB s a := by
rw [mem_closure_iff_clusterPt, ClusterPt, inf_comm] at hsf exact isLUB_of_mem_nhds hsa (mem_principal_self s)
[ " βˆƒαΆ  (x : Ξ±) in 𝓝[≀] a, x ∈ s", " False", " IsLUB s a" ]
[ " βˆƒαΆ  (x : Ξ±) in 𝓝[≀] a, x ∈ s", " False" ]
import Mathlib.Algebra.Homology.ShortComplex.ModuleCat import Mathlib.RepresentationTheory.GroupCohomology.Basic import Mathlib.RepresentationTheory.Invariants universe v u noncomputable section open CategoryTheory Limits Representation variable {k G : Type u} [CommRing k] [Group G] (A : Rep k G) namespace grou...
Mathlib/RepresentationTheory/GroupCohomology/LowDegree.lean
401
403
theorem map_one_of_isOneCocycle {f : G β†’ A} (hf : IsOneCocycle f) : f 1 = 0 := by
simpa only [mul_one, one_smul, self_eq_add_right] using hf 1 1
[ " f 1 = 0" ]
[]
import Mathlib.Analysis.Calculus.Deriv.Basic import Mathlib.Analysis.Calculus.FDeriv.Mul import Mathlib.Analysis.Calculus.FDeriv.Add #align_import analysis.calculus.deriv.mul from "leanprover-community/mathlib"@"3bce8d800a6f2b8f63fe1e588fd76a9ff4adcebe" universe u v w noncomputable section open scoped Classical...
Mathlib/Analysis/Calculus/Deriv/Mul.lean
480
484
theorem HasStrictDerivAt.clm_apply (hc : HasStrictDerivAt c c' x) (hu : HasStrictDerivAt u u' x) : HasStrictDerivAt (fun y => (c y) (u y)) (c' (u x) + c x u') x := by
have := (hc.hasStrictFDerivAt.clm_apply hu.hasStrictFDerivAt).hasStrictDerivAt rwa [add_apply, comp_apply, flip_apply, smulRight_apply, smulRight_apply, one_apply, one_smul, one_smul, add_comm] at this
[ " HasStrictDerivAt (fun y => (c y).comp (d y)) (c'.comp (d x) + (c x).comp d') x", " HasDerivWithinAt (fun y => (c y).comp (d y)) (c'.comp (d x) + (c x).comp d') s x", " HasDerivAt (fun y => (c y).comp (d y)) (c'.comp (d x) + (c x).comp d') x", " HasDerivWithinAt (fun y => (c y).comp (d y)) (c'.comp (d x) + (...
[ " HasStrictDerivAt (fun y => (c y).comp (d y)) (c'.comp (d x) + (c x).comp d') x", " HasDerivWithinAt (fun y => (c y).comp (d y)) (c'.comp (d x) + (c x).comp d') s x", " HasDerivAt (fun y => (c y).comp (d y)) (c'.comp (d x) + (c x).comp d') x", " HasDerivWithinAt (fun y => (c y).comp (d y)) (c'.comp (d x) + (...
import Mathlib.CategoryTheory.Limits.Shapes.SplitCoequalizer import Mathlib.CategoryTheory.Limits.Preserves.Basic #align_import category_theory.limits.preserves.shapes.equalizers from "leanprover-community/mathlib"@"4698e35ca56a0d4fa53aa5639c3364e0a77f4eba" noncomputable section universe w v₁ vβ‚‚ u₁ uβ‚‚ open Cate...
Mathlib/CategoryTheory/Limits/Preserves/Shapes/Equalizers.lean
104
108
theorem PreservesEqualizer.iso_inv_ΞΉ : (PreservesEqualizer.iso G f g).inv ≫ G.map (equalizer.ΞΉ f g) = equalizer.ΞΉ (G.map f) (G.map g) := by
rw [← Iso.cancel_iso_hom_left (PreservesEqualizer.iso G f g), ← Category.assoc, Iso.hom_inv_id] simp
[ " G.map h ≫ G.map f = G.map h ≫ G.map g", " (Iso.refl\n ((Cones.postcompose (diagramIsoParallelPair (parallelPair f g β‹™ G)).hom).obj\n (G.mapCone (Fork.ofΞΉ h w))).pt).hom ≫\n (Fork.ofΞΉ (G.map h) β‹―).ΞΉ =\n Fork.ΞΉ ((Cones.postcompose (diagramIsoParallelPair (parallelPair f g β‹™ G)).hom)....
[ " G.map h ≫ G.map f = G.map h ≫ G.map g", " (Iso.refl\n ((Cones.postcompose (diagramIsoParallelPair (parallelPair f g β‹™ G)).hom).obj\n (G.mapCone (Fork.ofΞΉ h w))).pt).hom ≫\n (Fork.ofΞΉ (G.map h) β‹―).ΞΉ =\n Fork.ΞΉ ((Cones.postcompose (diagramIsoParallelPair (parallelPair f g β‹™ G)).hom)....
import Batteries.Data.List.Lemmas import Batteries.Tactic.Classical import Mathlib.Tactic.TypeStar import Mathlib.Mathport.Rename #align_import data.list.tfae from "leanprover-community/mathlib"@"5a3e819569b0f12cbec59d740a2613018e7b8eec" namespace List def TFAE (l : List Prop) : Prop := βˆ€ x ∈ l, βˆ€ y ∈ l, x ↔ ...
Mathlib/Data/List/TFAE.lean
117
120
theorem tfae_not_iff {l : List Prop} : TFAE (l.map Not) ↔ TFAE l := by
classical simp only [TFAE, mem_map, forall_exists_index, and_imp, forall_apply_eq_imp_iffβ‚‚, Decidable.not_iff_not]
[ " [p].TFAE", " a ∈ a :: l", " (a ↔ b) ∧ l.TFAE β†’ (a :: l).TFAE", " a ↔ a", " a ↔ q", " p ↔ a", " p ↔ q", " (a :: a :: l).TFAE ↔ (a :: l).TFAE", " (a :: b :: l).TFAE", " [a, b].TFAE", " (a :: b :: c :: l).TFAE", " (a ↔ b) ∧ (b ↔ c) ∧ (c :: l).TFAE", " (map (fun p => βˆ€ (a : Ξ±), p a) l).TFAE", ...
[ " [p].TFAE", " a ∈ a :: l", " (a ↔ b) ∧ l.TFAE β†’ (a :: l).TFAE", " a ↔ a", " a ↔ q", " p ↔ a", " p ↔ q", " (a :: a :: l).TFAE ↔ (a :: l).TFAE", " (a :: b :: l).TFAE", " [a, b].TFAE", " (a :: b :: c :: l).TFAE", " (a ↔ b) ∧ (b ↔ c) ∧ (c :: l).TFAE", " (map (fun p => βˆ€ (a : Ξ±), p a) l).TFAE", ...
import Mathlib.Data.Finset.Sigma import Mathlib.Data.Fintype.Card #align_import data.finset.pi_induction from "leanprover-community/mathlib"@"f93c11933efbc3c2f0299e47b8ff83e9b539cbf6" open Function variable {ΞΉ : Type*} {Ξ± : ΞΉ β†’ Type*} [Finite ΞΉ] [DecidableEq ΞΉ] [βˆ€ i, DecidableEq (Ξ± i)] namespace Finset
Mathlib/Data/Finset/PiInduction.lean
37
63
theorem induction_on_pi_of_choice (r : βˆ€ i, Ξ± i β†’ Finset (Ξ± i) β†’ Prop) (H_ex : βˆ€ (i) (s : Finset (Ξ± i)), s.Nonempty β†’ βˆƒ x ∈ s, r i x (s.erase x)) {p : (βˆ€ i, Finset (Ξ± i)) β†’ Prop} (f : βˆ€ i, Finset (Ξ± i)) (h0 : p fun _ ↦ βˆ…) (step : βˆ€ (g : βˆ€ i, Finset (Ξ± i)) (i : ΞΉ) (x : Ξ± i), r i x (g i) β†’ p g β†’...
cases nonempty_fintype ι induction' hs : univ.sigma f using Finset.strongInductionOn with s ihs generalizing f; subst s rcases eq_empty_or_nonempty (univ.sigma f) with he | hne · convert h0 using 1 simpa [funext_iff] using he · rcases sigma_nonempty.1 hne with ⟨i, -, hi⟩ rcases H_ex i (f i) hi with ⟨...
[ " p f", " f = fun x => βˆ…", " x βˆ‰ g i", " x βˆ‰ (f i).erase x", " f = update g i (insert x (g i))", " p (update g i (insert x (g i)))", " univ.sigma g βŠ‚ univ.sigma (update g i (insert x (g i)))", " βˆ€ (i_1 : ΞΉ), g i_1 βŠ† update g i (insert x (g i)) i_1", " ⟨i, x⟩.snd ∈ update g i (insert x (g i)) ⟨i, x⟩....
[]
import Mathlib.RingTheory.FinitePresentation import Mathlib.RingTheory.Localization.Away.Basic import Mathlib.RingTheory.Localization.Away.AdjoinRoot import Mathlib.RingTheory.QuotientNilpotent import Mathlib.RingTheory.TensorProduct.Basic -- Porting note: added to make the syntax work below. open scoped TensorProd...
Mathlib/RingTheory/Unramified/Basic.lean
201
207
theorem of_isLocalization : FormallyUnramified R Rβ‚˜ := by
constructor intro Q _ _ I _ f₁ fβ‚‚ _ apply AlgHom.coe_ringHom_injective refine IsLocalization.ringHom_ext M ?_ ext simp
[ " g₁ = gβ‚‚", " βˆ€ (g₁ gβ‚‚ : A →ₐ[R] B), (Ideal.Quotient.mkₐ R I).comp g₁ = (Ideal.Quotient.mkₐ R I).comp gβ‚‚ β†’ g₁ = gβ‚‚", " Function.Injective (Ideal.Quotient.mkₐ R I).comp", " βˆ€ [_RB : Algebra R B], Function.Injective (Ideal.Quotient.mkₐ R I).comp", " βˆ€ ⦃S : Type u⦄ [inst : CommRing S] (I : Ideal S),\n I ^ 2...
[ " g₁ = gβ‚‚", " βˆ€ (g₁ gβ‚‚ : A →ₐ[R] B), (Ideal.Quotient.mkₐ R I).comp g₁ = (Ideal.Quotient.mkₐ R I).comp gβ‚‚ β†’ g₁ = gβ‚‚", " Function.Injective (Ideal.Quotient.mkₐ R I).comp", " βˆ€ [_RB : Algebra R B], Function.Injective (Ideal.Quotient.mkₐ R I).comp", " βˆ€ ⦃S : Type u⦄ [inst : CommRing S] (I : Ideal S),\n I ^ 2...
import Mathlib.Algebra.PUnitInstances import Mathlib.Tactic.Abel import Mathlib.Tactic.Ring import Mathlib.Order.Hom.Lattice #align_import algebra.ring.boolean_ring from "leanprover-community/mathlib"@"e8638a0fcaf73e4500469f368ef9494e495099b3" open scoped symmDiff variable {Ξ± Ξ² Ξ³ : Type*} class BooleanRing (Ξ±) ...
Mathlib/Algebra/Ring/BooleanRing.lean
101
101
theorem sub_eq_add : a - b = a + b := by
rw [sub_eq_add_neg, add_right_inj, neg_eq]
[ " a + a = 0", " a + a = (a + a) * (a + a)", " (a + a) * (a + a) = a * a + a * a + (a * a + a * a)", " a * a + a * a + (a * a + a * a) = a + a + (a + a)", " -a = -a + 0", " -a + 0 = -a + -a + a", " -a + -a + a = a", " a = -b ↔ a = b", " a * b + b * a = 0", " a + b = (a + b) * (a + b)", " (a + b) ...
[ " a + a = 0", " a + a = (a + a) * (a + a)", " (a + a) * (a + a) = a * a + a * a + (a * a + a * a)", " a * a + a * a + (a * a + a * a) = a + a + (a + a)", " -a = -a + 0", " -a + 0 = -a + -a + a", " -a + -a + a = a", " a = -b ↔ a = b", " a * b + b * a = 0", " a + b = (a + b) * (a + b)", " (a + b) ...
import Mathlib.Order.Interval.Finset.Nat #align_import data.fin.interval from "leanprover-community/mathlib"@"1d29de43a5ba4662dd33b5cfeecfc2a27a5a8a29" assert_not_exists MonoidWithZero open Finset Fin Function namespace Fin variable (n : β„•) instance instLocallyFiniteOrder : LocallyFiniteOrder (Fin n) := Orde...
Mathlib/Order/Interval/Finset/Fin.lean
114
115
theorem card_Ioc : (Ioc a b).card = b - a := by
rw [← Nat.card_Ioc, ← map_valEmbedding_Ioc, card_map]
[ " map valEmbedding (Icc a b) = Icc ↑a ↑b", " map valEmbedding (Ico a b) = Ico ↑a ↑b", " map valEmbedding (Ioc a b) = Ioc ↑a ↑b", " map valEmbedding (Ioo a b) = Ioo ↑a ↑b", " (Icc a b).card = ↑b + 1 - ↑a", " (Ico a b).card = ↑b - ↑a", " (Ioc a b).card = ↑b - ↑a" ]
[ " map valEmbedding (Icc a b) = Icc ↑a ↑b", " map valEmbedding (Ico a b) = Ico ↑a ↑b", " map valEmbedding (Ioc a b) = Ioc ↑a ↑b", " map valEmbedding (Ioo a b) = Ioo ↑a ↑b", " (Icc a b).card = ↑b + 1 - ↑a", " (Ico a b).card = ↑b - ↑a" ]
import Mathlib.CategoryTheory.EqToHom #align_import category_theory.sums.basic from "leanprover-community/mathlib"@"dc6c365e751e34d100e80fe6e314c3c3e0fd2988" namespace CategoryTheory universe v₁ u₁ -- morphism levels before object levels. See note [category_theory universes]. open Sum section variable (C : Ty...
Mathlib/CategoryTheory/Sums/Basic.lean
62
63
theorem hom_inl_inr_false {X : C} {Y : D} (f : Sum.inl X ⟢ Sum.inr Y) : False := by
cases f
[ " False" ]
[]
import Mathlib.CategoryTheory.NatTrans import Mathlib.CategoryTheory.Iso #align_import category_theory.functor.category from "leanprover-community/mathlib"@"63721b2c3eba6c325ecf8ae8cca27155a4f6306f" namespace CategoryTheory -- declare the `v`'s first; see note [CategoryTheory universes]. universe v₁ vβ‚‚ v₃ u₁ uβ‚‚ u...
Mathlib/CategoryTheory/Functor/Category.lean
125
125
theorem id_hcomp_app {H : E β₯€ C} (Ξ± : F ⟢ G) (X : E) : (πŸ™ H β—« Ξ±).app X = Ξ±.app _ := by
simp
[ " Ξ±.app X = Ξ².app X", " g = h", " g.app X = h.app X", " (F β‹™ H).map f ≫ (fun X => Ξ².app (F.obj X) ≫ I.map (Ξ±.app X)) Y =\n (fun X => Ξ².app (F.obj X) ≫ I.map (Ξ±.app X)) X ≫ (G β‹™ I).map f", " (Ξ± β—« πŸ™ H).app X = H.map (Ξ±.app X)", " (πŸ™ H β—« Ξ±).app X = Ξ±.app (H.obj X)" ]
[ " Ξ±.app X = Ξ².app X", " g = h", " g.app X = h.app X", " (F β‹™ H).map f ≫ (fun X => Ξ².app (F.obj X) ≫ I.map (Ξ±.app X)) Y =\n (fun X => Ξ².app (F.obj X) ≫ I.map (Ξ±.app X)) X ≫ (G β‹™ I).map f", " (Ξ± β—« πŸ™ H).app X = H.map (Ξ±.app X)" ]
import Mathlib.Order.Interval.Finset.Fin #align_import data.fintype.fin from "leanprover-community/mathlib"@"759575657f189ccb424b990164c8b1fa9f55cdfe" open Finset open Fintype namespace Fin variable {Ξ± Ξ² : Type*} {n : β„•} theorem map_valEmbedding_univ : (Finset.univ : Finset (Fin n)).map Fin.valEmbedding = Iio ...
Mathlib/Data/Fintype/Fin.lean
61
64
theorem card_filter_univ_succ' (p : Fin (n + 1) β†’ Prop) [DecidablePred p] : (univ.filter p).card = ite (p 0) 1 0 + (univ.filter (p ∘ Fin.succ)).card := by
rw [Fin.univ_succ, filter_cons, card_disjUnion, filter_map, card_map] split_ifs <;> simp
[ " map valEmbedding univ = Iio n", " a✝ ∈ map valEmbedding univ ↔ a✝ ∈ Iio n", " ↑(Ioi 0) = ↑(map (succEmb n) univ)", " x✝ ∈ ↑(Ioi 0) ↔ x✝ ∈ ↑(map (succEmb n) univ)", " ↑(Iio (last n)) = ↑(map castSuccEmb univ)", " x✝ ∈ ↑(Iio (last n)) ↔ x✝ ∈ ↑(map castSuccEmb univ)", " Ioi i.succ = map (succEmb n) (Ioi ...
[ " map valEmbedding univ = Iio n", " a✝ ∈ map valEmbedding univ ↔ a✝ ∈ Iio n", " ↑(Ioi 0) = ↑(map (succEmb n) univ)", " x✝ ∈ ↑(Ioi 0) ↔ x✝ ∈ ↑(map (succEmb n) univ)", " ↑(Iio (last n)) = ↑(map castSuccEmb univ)", " x✝ ∈ ↑(Iio (last n)) ↔ x✝ ∈ ↑(map castSuccEmb univ)", " Ioi i.succ = map (succEmb n) (Ioi ...
import Mathlib.Logic.Function.Basic import Mathlib.Tactic.MkIffOfInductiveProp #align_import data.sum.basic from "leanprover-community/mathlib"@"bd9851ca476957ea4549eb19b40e7b5ade9428cc" universe u v w x variable {Ξ± : Type u} {Ξ±' : Type w} {Ξ² : Type v} {Ξ²' : Type x} {Ξ³ Ξ΄ : Type*} namespace Sum #align sum.foral...
Mathlib/Data/Sum/Basic.lean
54
55
theorem eq_left_iff_getLeft_eq {a : Ξ±} : x = inl a ↔ βˆƒ h, x.getLeft h = a := by
cases x <;> simp
[ " (βˆƒ fab, p fab) ↔ βˆƒ fa fb, p fun t => rec fa fb t", " (Β¬βˆ€ (fa : (val : Ξ±) β†’ Ξ³ (inl val)) (fb : (val : Ξ²) β†’ Ξ³ (inr val)), Β¬p fun t => rec fa fb t) ↔\n βˆƒ fa fb, p fun t => rec fa fb t", " rec f g x = cast β‹― (rec f g y)", " rec f g x = cast β‹― (rec f g x)", " x = inl a ↔ βˆƒ h, x.getLeft h = a", " inl val✝ ...
[ " (βˆƒ fab, p fab) ↔ βˆƒ fa fb, p fun t => rec fa fb t", " (Β¬βˆ€ (fa : (val : Ξ±) β†’ Ξ³ (inl val)) (fb : (val : Ξ²) β†’ Ξ³ (inr val)), Β¬p fun t => rec fa fb t) ↔\n βˆƒ fa fb, p fun t => rec fa fb t", " rec f g x = cast β‹― (rec f g y)", " rec f g x = cast β‹― (rec f g x)" ]
import Mathlib.Analysis.NormedSpace.Exponential import Mathlib.Analysis.Calculus.FDeriv.Analytic import Mathlib.Topology.MetricSpace.CauSeqFilter #align_import analysis.special_functions.exponential from "leanprover-community/mathlib"@"e1a18cad9cd462973d760af7de36b05776b8811c" open Filter RCLike ContinuousMultili...
Mathlib/Analysis/SpecialFunctions/Exponential.lean
67
72
theorem hasStrictFDerivAt_exp_zero_of_radius_pos (h : 0 < (expSeries 𝕂 𝔸).radius) : HasStrictFDerivAt (exp 𝕂) (1 : 𝔸 β†’L[𝕂] 𝔸) 0 := by
convert (hasFPowerSeriesAt_exp_zero_of_radius_pos h).hasStrictFDerivAt ext x change x = expSeries 𝕂 𝔸 1 fun _ => x simp [expSeries_apply_eq, Nat.factorial]
[ " HasStrictFDerivAt (exp 𝕂) 1 0", " 1 = (continuousMultilinearCurryFin1 𝕂 𝔸 𝔸) (expSeries 𝕂 𝔸 1)", " 1 x = ((continuousMultilinearCurryFin1 𝕂 𝔸 𝔸) (expSeries 𝕂 𝔸 1)) x", " x = (expSeries 𝕂 𝔸 1) fun x_1 => x" ]
[]
import Mathlib.CategoryTheory.Limits.Shapes.Images import Mathlib.CategoryTheory.Limits.Constructions.EpiMono #align_import category_theory.limits.preserves.shapes.images from "leanprover-community/mathlib"@"fc78e3c190c72a109699385da6be2725e88df841" noncomputable section namespace CategoryTheory namespace Prese...
Mathlib/CategoryTheory/Limits/Preserves/Shapes/Images.lean
62
63
theorem inv_comp_image_ΞΉ_map {X Y : A} (f : X ⟢ Y) : (iso L f).inv ≫ image.ΞΉ (L.map f) = L.map (image.ΞΉ f) := by
simp
[ " L.map (factorThruImage f) ≫ L.map (image.ΞΉ f) = L.map f", " factorThruImage (L.map f) ≫ (iso L f).hom = L.map (factorThruImage f)", " (iso L f).hom ≫ L.map (image.ΞΉ f) = image.ΞΉ (L.map f)", " (iso L f).inv ≫ image.ΞΉ (L.map f) = L.map (image.ΞΉ f)" ]
[ " L.map (factorThruImage f) ≫ L.map (image.ΞΉ f) = L.map f", " factorThruImage (L.map f) ≫ (iso L f).hom = L.map (factorThruImage f)", " (iso L f).hom ≫ L.map (image.ΞΉ f) = image.ΞΉ (L.map f)" ]
import Mathlib.RingTheory.FiniteType import Mathlib.RingTheory.Localization.AtPrime import Mathlib.RingTheory.Localization.Away.Basic import Mathlib.RingTheory.Localization.Integer import Mathlib.RingTheory.Localization.Submodule import Mathlib.RingTheory.Nilpotent.Lemmas import Mathlib.RingTheory.RingHomProperties im...
Mathlib/RingTheory/LocalProperties.lean
181
189
theorem RingHom.PropertyIsLocal.respectsIso (hP : RingHom.PropertyIsLocal @P) : RingHom.RespectsIso @P := by
apply hP.StableUnderComposition.respectsIso introv letI := e.toRingHom.toAlgebra -- Porting note: was `apply_with hP.holds_for_localization_away { instances := ff }` have : IsLocalization.Away (1 : R) S := by apply IsLocalization.away_of_isUnit_of_bijective _ isUnit_one e.bijective exact RingHom.Proper...
[ " OfLocalizationSpan P ↔ OfLocalizationFiniteSpan P", " (βˆ€ ⦃R S : Type u⦄ [inst : CommRing R] [inst_1 : CommRing S] (f : R β†’+* S) (s : Set R),\n Ideal.span s = ⊀ β†’ (βˆ€ (r : ↑s), P (Localization.awayMap f ↑r)) β†’ P f) ↔\n βˆ€ ⦃R S : Type u⦄ [inst : CommRing R] [inst_1 : CommRing S] (f : R β†’+* S) (s : Finset R)...
[ " OfLocalizationSpan P ↔ OfLocalizationFiniteSpan P", " (βˆ€ ⦃R S : Type u⦄ [inst : CommRing R] [inst_1 : CommRing S] (f : R β†’+* S) (s : Set R),\n Ideal.span s = ⊀ β†’ (βˆ€ (r : ↑s), P (Localization.awayMap f ↑r)) β†’ P f) ↔\n βˆ€ ⦃R S : Type u⦄ [inst : CommRing R] [inst_1 : CommRing S] (f : R β†’+* S) (s : Finset R)...
import Mathlib.Data.Part import Mathlib.Data.Rel #align_import data.pfun from "leanprover-community/mathlib"@"207cfac9fcd06138865b5d04f7091e46d9320432" open Function def PFun (Ξ± Ξ² : Type*) := Ξ± β†’ Part Ξ² #align pfun PFun infixr:25 " β†’. " => PFun namespace PFun variable {Ξ± Ξ² Ξ³ Ξ΄ Ξ΅ ΞΉ : Type*} instance inhab...
Mathlib/Data/PFun.lean
189
190
theorem mem_res (f : Ξ± β†’ Ξ²) (s : Set Ξ±) (a : Ξ±) (b : Ξ²) : b ∈ res f s a ↔ a ∈ s ∧ f a = b := by
simp [res, @eq_comm _ b]
[ " x ∈ f.Dom ↔ βˆƒ y, y ∈ f x", " (fun f => ⟨fun a => (f a).Dom, f.asSubtype⟩) ((fun f x => { Dom := f.fst x, get := fun h => f.snd ⟨x, h⟩ }) ⟨p, f⟩) =\n ⟨p, f⟩", " ⟨fun a => p a, asSubtype fun x => { Dom := p x, get := fun h => f ⟨x, h⟩ }⟩ = ⟨p, f⟩", " b ∈ f.restrict h a ↔ a ∈ s ∧ b ∈ f a", " b ∈ res f s a...
[ " x ∈ f.Dom ↔ βˆƒ y, y ∈ f x", " (fun f => ⟨fun a => (f a).Dom, f.asSubtype⟩) ((fun f x => { Dom := f.fst x, get := fun h => f.snd ⟨x, h⟩ }) ⟨p, f⟩) =\n ⟨p, f⟩", " ⟨fun a => p a, asSubtype fun x => { Dom := p x, get := fun h => f ⟨x, h⟩ }⟩ = ⟨p, f⟩", " b ∈ f.restrict h a ↔ a ∈ s ∧ b ∈ f a" ]
import Mathlib.Analysis.Calculus.Deriv.Basic import Mathlib.Analysis.Calculus.FDeriv.Comp import Mathlib.Analysis.Calculus.FDeriv.RestrictScalars #align_import analysis.calculus.deriv.comp from "leanprover-community/mathlib"@"3bce8d800a6f2b8f63fe1e588fd76a9ff4adcebe" universe u v w open scoped Classical open Top...
Mathlib/Analysis/Calculus/Deriv/Comp.lean
415
418
theorem fderiv.comp_deriv_of_eq (hl : DifferentiableAt π•œ l y) (hf : DifferentiableAt π•œ f x) (hy : y = f x) : deriv (l ∘ f) x = (fderiv π•œ l (f x) : F β†’ E) (deriv f x) := by
rw [hy] at hl; exact fderiv.comp_deriv x hl hf
[ " HasDerivWithinAt (l ∘ f) (l' f') s x", " HasDerivAt (l ∘ f) (l' f') x", " HasStrictDerivAt (l ∘ f) (l' f') x", " derivWithin (l ∘ f) s x = (fderivWithin π•œ l t (f x)) (derivWithin f s x)", " deriv (l ∘ f) x = (fderiv π•œ l (f x)) (deriv f x)" ]
[ " HasDerivWithinAt (l ∘ f) (l' f') s x", " HasDerivAt (l ∘ f) (l' f') x", " HasStrictDerivAt (l ∘ f) (l' f') x", " derivWithin (l ∘ f) s x = (fderivWithin π•œ l t (f x)) (derivWithin f s x)" ]
import Mathlib.RingTheory.Localization.Basic #align_import ring_theory.localization.integer from "leanprover-community/mathlib"@"9556784a5b84697562e9c6acb40500d4a82e675a" variable {R : Type*} [CommSemiring R] {M : Submonoid R} {S : Type*} [CommSemiring S] variable [Algebra R S] {P : Type*} [CommSemiring P] open ...
Mathlib/RingTheory/Localization/Integer.lean
91
103
theorem exist_integer_multiples {ΞΉ : Type*} (s : Finset ΞΉ) (f : ΞΉ β†’ S) : βˆƒ b : M, βˆ€ i ∈ s, IsLocalization.IsInteger R ((b : R) β€’ f i) := by
haveI := Classical.propDecidable refine ⟨∏ i ∈ s, (sec M (f i)).2, fun i hi => ⟨?_, ?_⟩⟩ Β· exact (∏ j ∈ s.erase i, (sec M (f j)).2) * (sec M (f i)).1 rw [RingHom.map_mul, sec_spec', ← mul_assoc, ← (algebraMap R S).map_mul, ← Algebra.smul_def] congr 2 refine _root_.trans ?_ (map_prod (Submonoid.subtype M) _...
[ " IsInteger R (a β€’ b)", " (algebraMap R S) (a * b') = a β€’ b", " βˆƒ b, IsInteger R (↑b β€’ a)", " βˆƒ b, IsInteger R (a * (algebraMap R S) ↑b)", " βˆƒ b, βˆ€ i ∈ s, IsInteger R (↑b β€’ f i)", " R", " (algebraMap R S) (↑(∏ j ∈ s.erase i, (sec M (f j)).2) * (sec M (f i)).1) = ↑(∏ i ∈ s, (sec M (f i)).2) β€’ f i", " (...
[ " IsInteger R (a β€’ b)", " (algebraMap R S) (a * b') = a β€’ b", " βˆƒ b, IsInteger R (↑b β€’ a)", " βˆƒ b, IsInteger R (a * (algebraMap R S) ↑b)" ]
import Mathlib.CategoryTheory.Sites.Sheaf import Mathlib.CategoryTheory.Sites.CoverLifting import Mathlib.CategoryTheory.Adjunction.FullyFaithful #align_import category_theory.sites.dense_subsite from "leanprover-community/mathlib"@"1d650c2e131f500f3c17f33b4d19d2ea15987f2c" universe w v u namespace CategoryTheory...
Mathlib/CategoryTheory/Sites/DenseSubsite.lean
124
128
theorem ext (β„± : SheafOfTypes K) (X : D) {s t : β„±.val.obj (op X)} (h : βˆ€ ⦃Y : C⦄ (f : G.obj Y ⟢ X), β„±.val.map f.op s = β„±.val.map f.op t) : s = t := by
apply (β„±.cond (Sieve.coverByImage G X) (G.is_cover_of_isCoverDense K X)).isSeparatedFor.ext rintro Y _ ⟨Z, f₁, fβ‚‚, ⟨rfl⟩⟩ simp [h fβ‚‚]
[ " (g ≫ f₁) ≫ fβ‚‚ = g ≫ f✝", " πŸ™ (G.obj Y) ≫ f = f", " Sieve.coverByImage G U ∈ K.sieves U", " Sieve.coverByImage G B ∈ K.sieves B", " Sieve.generate (Presieve.singleton f) ≀ Sieve.coverByImage G B", " (Sieve.coverByImage G B).arrows f", " s = t", " βˆ€ ⦃Y : D⦄ ⦃f : Y ⟢ X⦄, (Sieve.coverByImage G X).arrow...
[ " (g ≫ f₁) ≫ fβ‚‚ = g ≫ f✝", " πŸ™ (G.obj Y) ≫ f = f", " Sieve.coverByImage G U ∈ K.sieves U", " Sieve.coverByImage G B ∈ K.sieves B", " Sieve.generate (Presieve.singleton f) ≀ Sieve.coverByImage G B", " (Sieve.coverByImage G B).arrows f" ]
import Mathlib.Algebra.Order.Group.Abs import Mathlib.Algebra.Order.Monoid.Unbundled.MinMax #align_import algebra.order.group.min_max from "leanprover-community/mathlib"@"10b4e499f43088dd3bb7b5796184ad5216648ab1" section variable {Ξ± : Type*} [Group Ξ±] [LinearOrder Ξ±] [CovariantClass Ξ± Ξ± (Β· * Β·) (Β· ≀ Β·)] -- TODO...
Mathlib/Algebra/Order/Group/MinMax.lean
69
70
theorem min_div_div_left' (a b c : Ξ±) : min (a / b) (a / c) = a / max b c := by
simp only [div_eq_mul_inv, min_mul_mul_left, min_inv_inv']
[ " max a 1 / max a⁻¹ 1 = a", " max a⁻¹ 1 = a⁻¹ * max a 1", " min (a / c) (b / c) = min a b / c", " max (a / c) (b / c) = max a b / c", " min (a / b) (a / c) = a / max b c" ]
[ " max a 1 / max a⁻¹ 1 = a", " max a⁻¹ 1 = a⁻¹ * max a 1", " min (a / c) (b / c) = min a b / c", " max (a / c) (b / c) = max a b / c" ]
import Mathlib.Algebra.Group.Prod import Mathlib.Data.Set.Lattice #align_import data.nat.pairing from "leanprover-community/mathlib"@"207cfac9fcd06138865b5d04f7091e46d9320432" assert_not_exists MonoidWithZero open Prod Decidable Function namespace Nat -- Porting note: no pp_nodot --@[pp_nodot] def pair (a b : ...
Mathlib/Data/Nat/Pairing.lean
93
100
theorem unpair_lt {n : β„•} (n1 : 1 ≀ n) : (unpair n).1 < n := by
let s := sqrt n simp only [unpair, ge_iff_le, Nat.sub_le_iff_le_add] by_cases h : n - s * s < s <;> simp [h] Β· exact lt_of_lt_of_le h (sqrt_le_self _) Β· simp at h have s0 : 0 < s := sqrt_pos.2 n1 exact lt_of_le_of_lt h (Nat.sub_lt n1 (Nat.mul_pos s0 s0))
[ " n.unpair.1.pair n.unpair.2 = n", " (if n - n.sqrt * n.sqrt < n.sqrt then (n - n.sqrt * n.sqrt, n.sqrt)\n else (n.sqrt, n - n.sqrt * n.sqrt - n.sqrt)).1.pair\n (if n - n.sqrt * n.sqrt < n.sqrt then (n - n.sqrt * n.sqrt, n.sqrt)\n else (n.sqrt, n - n.sqrt * n.sqrt - n.sqrt)).2 =\n n", " ...
[ " n.unpair.1.pair n.unpair.2 = n", " (if n - n.sqrt * n.sqrt < n.sqrt then (n - n.sqrt * n.sqrt, n.sqrt)\n else (n.sqrt, n - n.sqrt * n.sqrt - n.sqrt)).1.pair\n (if n - n.sqrt * n.sqrt < n.sqrt then (n - n.sqrt * n.sqrt, n.sqrt)\n else (n.sqrt, n - n.sqrt * n.sqrt - n.sqrt)).2 =\n n", " ...
import Mathlib.Analysis.SpecialFunctions.Trigonometric.Arctan import Mathlib.Geometry.Euclidean.Angle.Unoriented.Affine #align_import geometry.euclidean.angle.unoriented.right_angle from "leanprover-community/mathlib"@"46b633fd842bef9469441c0209906f6dddd2b4f5" noncomputable section open scoped EuclideanGeometry ...
Mathlib/Geometry/Euclidean/Angle/Unoriented/RightAngle.lean
56
59
theorem norm_sub_sq_eq_norm_sq_add_norm_sq_iff_angle_eq_pi_div_two (x y : V) : β€–x - yβ€– * β€–x - yβ€– = β€–xβ€– * β€–xβ€– + β€–yβ€– * β€–yβ€– ↔ angle x y = Ο€ / 2 := by
rw [norm_sub_sq_eq_norm_sq_add_norm_sq_iff_real_inner_eq_zero] exact inner_eq_zero_iff_angle_eq_pi_div_two x y
[ " β€–x + yβ€– * β€–x + yβ€– = β€–xβ€– * β€–xβ€– + β€–yβ€– * β€–yβ€– ↔ angle x y = Ο€ / 2", " βŸͺx, y⟫_ℝ = 0 ↔ angle x y = Ο€ / 2", " β€–x - yβ€– * β€–x - yβ€– = β€–xβ€– * β€–xβ€– + β€–yβ€– * β€–yβ€– ↔ angle x y = Ο€ / 2" ]
[ " β€–x + yβ€– * β€–x + yβ€– = β€–xβ€– * β€–xβ€– + β€–yβ€– * β€–yβ€– ↔ angle x y = Ο€ / 2", " βŸͺx, y⟫_ℝ = 0 ↔ angle x y = Ο€ / 2" ]
import Mathlib.Topology.Separation #align_import topology.sober from "leanprover-community/mathlib"@"0a0ec35061ed9960bf0e7ffb0335f44447b58977" open Set variable {Ξ± Ξ² : Type*} [TopologicalSpace Ξ±] [TopologicalSpace Ξ²] section genericPoint def IsGenericPoint (x : Ξ±) (S : Set Ξ±) : Prop := closure ({x} : Set Ξ±)...
Mathlib/Topology/Sober.lean
107
111
theorem isGenericPoint_iff_forall_closed (hS : IsClosed S) (hxS : x ∈ S) : IsGenericPoint x S ↔ βˆ€ Z : Set Ξ±, IsClosed Z β†’ x ∈ Z β†’ S βŠ† Z := by
have : closure {x} βŠ† S := closure_minimal (singleton_subset_iff.2 hxS) hS simp_rw [IsGenericPoint, subset_antisymm_iff, this, true_and_iff, closure, subset_sInter_iff, mem_setOf_eq, and_imp, singleton_subset_iff]
[ " IsGenericPoint x S ↔ βˆ€ (y : Ξ±), x β€³ y ↔ y ∈ S", " IsGenericPoint x S ↔ βˆ€ (Z : Set Ξ±), IsClosed Z β†’ x ∈ Z β†’ S βŠ† Z" ]
[ " IsGenericPoint x S ↔ βˆ€ (y : Ξ±), x β€³ y ↔ y ∈ S" ]
import Mathlib.Data.Nat.Factorial.Basic import Mathlib.Order.Monotone.Basic #align_import data.nat.choose.basic from "leanprover-community/mathlib"@"2f3994e1b117b1e1da49bcfb67334f33460c3ce4" open Nat namespace Nat def choose : β„• β†’ β„• β†’ β„• | _, 0 => 1 | 0, _ + 1 => 0 | n + 1, k + 1 => choose n k + choose n ...
Mathlib/Data/Nat/Choose/Basic.lean
125
142
theorem choose_mul_factorial_mul_factorial : βˆ€ {n k}, k ≀ n β†’ choose n k * k ! * (n - k)! = n ! | 0, _, hk => by simp [Nat.eq_zero_of_le_zero hk] | n + 1, 0, _ => by simp | n + 1, succ k, hk => by rcases lt_or_eq_of_le hk with hk₁ | hk₁ Β· have h : choose n k * k.succ ! * (n - k)! = (k + 1) * n ! := by
rw [← choose_mul_factorial_mul_factorial (le_of_succ_le_succ hk)] simp [factorial_succ, Nat.mul_comm, Nat.mul_left_comm, Nat.mul_assoc] have h₁ : (n - k)! = (n - k) * (n - k.succ)! := by rw [← succ_sub_succ, succ_sub (le_of_lt_succ hk₁), factorial_succ] have hβ‚‚ : choose n (succ k) *...
[ " n.choose 0 = 1", " choose 0 0 = 1", " (n✝ + 1).choose 0 = 1", " (n + 1).choose (k + 1) = 0", " n.choose n = 1", " (n✝ + 1).choose (n✝ + 1) = 1", " n.choose 1 = n", " choose 0 1 = 0", " (n✝ + 1).choose 1 = n✝ + 1", " (n + 1) * (n + 1 - 1) / 2 = n * (n - 1) / 2 + n", " n * (n + 1) / 2 = n * (n -...
[ " n.choose 0 = 1", " choose 0 0 = 1", " (n✝ + 1).choose 0 = 1", " (n + 1).choose (k + 1) = 0", " n.choose n = 1", " (n✝ + 1).choose (n✝ + 1) = 1", " n.choose 1 = n", " choose 0 1 = 0", " (n✝ + 1).choose 1 = n✝ + 1", " (n + 1) * (n + 1 - 1) / 2 = n * (n - 1) / 2 + n", " n * (n + 1) / 2 = n * (n -...
import Mathlib.Algebra.Polynomial.Eval import Mathlib.RingTheory.Ideal.Quotient #align_import linear_algebra.smodeq from "leanprover-community/mathlib"@"146d3d1fa59c091fedaad8a4afa09d6802886d24" open Submodule open Polynomial variable {R : Type*} [Ring R] variable {A : Type*} [CommRing A] variable {M : Type*} [...
Mathlib/LinearAlgebra/SModEq.lean
53
54
theorem bot : x ≑ y [SMOD (βŠ₯ : Submodule R M)] ↔ x = y := by
rw [SModEq.def, Submodule.Quotient.eq, mem_bot, sub_eq_zero]
[ " x ≑ y [SMOD U] ↔ x - y ∈ U", " x ≑ y [SMOD βŠ₯] ↔ x = y" ]
[ " x ≑ y [SMOD U] ↔ x - y ∈ U" ]
import Mathlib.Algebra.Group.Basic import Mathlib.Order.Basic import Mathlib.Order.Monotone.Basic #align_import algebra.covariant_and_contravariant from "leanprover-community/mathlib"@"2258b40dacd2942571c8ce136215350c702dc78f" -- TODO: convert `ExistsMulOfLE`, `ExistsAddOfLE`? -- TODO: relationship with `Con/AddC...
Mathlib/Algebra/Order/Monoid/Unbundled/Defs.lean
281
286
theorem covariant_le_of_covariant_lt [PartialOrder N] : Covariant M N ΞΌ (Β· < Β·) β†’ Covariant M N ΞΌ (Β· ≀ Β·) := by
intro h a b c bc rcases bc.eq_or_lt with (rfl | bc) Β· exact le_rfl Β· exact (h _ bc).le
[ " Covariant N N (fun x x_1 => x * x_1) r ↔ Contravariant N N (fun x x_1 => x * x_1) r", " r b c", " r (a⁻¹ * (a * b)) (a⁻¹ * (a * c))", " r ((fun x x_1 => x * x_1) a b) ((fun x x_1 => x * x_1) a c)", " Covariant N N (swap fun x x_1 => x * x_1) r ↔ Contravariant N N (swap fun x x_1 => x * x_1) r", " r (b *...
[ " Covariant N N (fun x x_1 => x * x_1) r ↔ Contravariant N N (fun x x_1 => x * x_1) r", " r b c", " r (a⁻¹ * (a * b)) (a⁻¹ * (a * c))", " r ((fun x x_1 => x * x_1) a b) ((fun x x_1 => x * x_1) a c)", " Covariant N N (swap fun x x_1 => x * x_1) r ↔ Contravariant N N (swap fun x x_1 => x * x_1) r", " r (b *...
import Mathlib.Topology.Constructions #align_import topology.continuous_on from "leanprover-community/mathlib"@"d4f691b9e5f94cfc64639973f3544c95f8d5d494" open Set Filter Function Topology Filter variable {Ξ± : Type*} {Ξ² : Type*} {Ξ³ : Type*} {Ξ΄ : Type*} variable [TopologicalSpace Ξ±] @[simp] theorem nhds_bind_nhdsW...
Mathlib/Topology/ContinuousOn.lean
57
59
theorem mem_closure_ne_iff_frequently_within {z : Ξ±} {s : Set Ξ±} : z ∈ closure (s \ {z}) ↔ βˆƒαΆ  x in 𝓝[β‰ ] z, x ∈ s := by
simp [mem_closure_iff_frequently, frequently_nhdsWithin_iff]
[ " (βˆƒαΆ  (x : Ξ±) in 𝓝 z, x ∈ s ∧ p x) ↔ βˆƒαΆ  (x : Ξ±) in 𝓝 z, p x ∧ x ∈ s", " z ∈ closure (s \\ {z}) ↔ βˆƒαΆ  (x : Ξ±) in 𝓝[β‰ ] z, x ∈ s" ]
[ " (βˆƒαΆ  (x : Ξ±) in 𝓝 z, x ∈ s ∧ p x) ↔ βˆƒαΆ  (x : Ξ±) in 𝓝 z, p x ∧ x ∈ s" ]
import Mathlib.Analysis.Convex.Normed import Mathlib.Analysis.Convex.Strict import Mathlib.Analysis.Normed.Order.Basic import Mathlib.Analysis.NormedSpace.AddTorsor import Mathlib.Analysis.NormedSpace.Pointwise import Mathlib.Analysis.NormedSpace.Ray #align_import analysis.convex.strict_convex_space from "leanprover-...
Mathlib/Analysis/Convex/StrictConvexSpace.lean
76
81
theorem strictConvex_closedBall [StrictConvexSpace π•œ E] (x : E) (r : ℝ) : StrictConvex π•œ (closedBall x r) := by
rcases le_or_lt r 0 with hr | hr Β· exact (subsingleton_closedBall x hr).strictConvex rw [← vadd_closedBall_zero] exact (StrictConvexSpace.strictConvex_closedBall r hr).vadd _
[ " StrictConvex π•œ (closedBall x r)", " StrictConvex π•œ (x +α΅₯ closedBall 0 r)" ]
[]
import Mathlib.Order.Filter.CountableInter set_option autoImplicit true open Function Set Filter class HasCountableSeparatingOn (Ξ± : Type*) (p : Set Ξ± β†’ Prop) (t : Set Ξ±) : Prop where exists_countable_separating : βˆƒ S : Set (Set Ξ±), S.Countable ∧ (βˆ€ s ∈ S, p s) ∧ βˆ€ x ∈ t, βˆ€ y ∈ t, (βˆ€ s ∈ S, x ∈ s ↔ y ∈ s) ...
Mathlib/Order/Filter/CountableSeparatingOn.lean
158
172
theorem exists_subset_subsingleton_mem_of_forall_separating (p : Set Ξ± β†’ Prop) {s : Set Ξ±} [h : HasCountableSeparatingOn Ξ± p s] (hs : s ∈ l) (hl : βˆ€ U, p U β†’ U ∈ l ∨ Uᢜ ∈ l) : βˆƒ t, t βŠ† s ∧ t.Subsingleton ∧ t ∈ l := by
rcases h.1 with ⟨S, hSc, hSp, hS⟩ refine ⟨s ∩ β‹‚β‚€ (S ∩ l.sets) ∩ β‹‚ (U ∈ S) (_ : Uᢜ ∈ l), Uᢜ, ?_, ?_, ?_⟩ Β· exact fun _ h ↦ h.1.1 Β· intro x hx y hy simp only [mem_sInter, mem_inter_iff, mem_iInter, mem_compl_iff] at hx hy refine hS x hx.1.1 y hy.1.1 (fun s hsS ↦ ?_) cases hl s (hSp s hsS) with | ...
[ " βˆƒ S, (βˆ€ (n : β„•), p (S n)) ∧ βˆ€ x ∈ t, βˆ€ y ∈ t, (βˆ€ (n : β„•), x ∈ S n ↔ y ∈ S n) β†’ x = y", " (βˆ€ (n : β„•), p (S n)) ∧ βˆ€ x ∈ t, βˆ€ y ∈ t, (βˆ€ (n : β„•), x ∈ S n ↔ y ∈ S n) β†’ x = y", " HasCountableSeparatingOn Ξ± p t", " x = y", " ⟨x, hx⟩ ∈ U ↔ ⟨y, hy⟩ ∈ U", " ⟨x, hx⟩ ∈ Subtype.val ⁻¹' V U ↔ ⟨y, hy⟩ ∈ Subtype.val ⁻¹...
[ " βˆƒ S, (βˆ€ (n : β„•), p (S n)) ∧ βˆ€ x ∈ t, βˆ€ y ∈ t, (βˆ€ (n : β„•), x ∈ S n ↔ y ∈ S n) β†’ x = y", " (βˆ€ (n : β„•), p (S n)) ∧ βˆ€ x ∈ t, βˆ€ y ∈ t, (βˆ€ (n : β„•), x ∈ S n ↔ y ∈ S n) β†’ x = y", " HasCountableSeparatingOn Ξ± p t", " x = y", " ⟨x, hx⟩ ∈ U ↔ ⟨y, hy⟩ ∈ U", " ⟨x, hx⟩ ∈ Subtype.val ⁻¹' V U ↔ ⟨y, hy⟩ ∈ Subtype.val ⁻¹...
import Mathlib.Algebra.Lie.Submodule #align_import algebra.lie.ideal_operations from "leanprover-community/mathlib"@"8983bec7cdf6cb2dd1f21315c8a34ab00d7b2f6d" universe u v w w₁ wβ‚‚ namespace LieSubmodule variable {R : Type u} {L : Type v} {M : Type w} {Mβ‚‚ : Type w₁} variable [CommRing R] [LieRing L] [LieAlgebra ...
Mathlib/Algebra/Lie/IdealOperations.lean
96
100
theorem lie_le_iff : ⁅I, N⁆ ≀ N' ↔ βˆ€ x ∈ I, βˆ€ m ∈ N, ⁅x, m⁆ ∈ N' := by
rw [lieIdeal_oper_eq_span, LieSubmodule.lieSpan_le] refine ⟨fun h x hx m hm => h ⟨⟨x, hx⟩, ⟨m, hm⟩, rfl⟩, ?_⟩ rintro h _ ⟨⟨x, hx⟩, ⟨m, hm⟩, rfl⟩ exact h x hx m hm
[ " ↑⁅I, N⁆ = Submodule.span R {m | βˆƒ x n, ⁅↑x, ↑n⁆ = m}", " ↑⁅I, N⁆ ≀ Submodule.span R {m | βˆƒ x n, ⁅↑x, ↑n⁆ = m}", " βˆ€ (y : L), βˆ€ m' ∈ Submodule.span R s, ⁅y, m'⁆ ∈ Submodule.span R s", " ⁅y, m'⁆ ∈ Submodule.span R s", " βˆ€ x ∈ s, (fun m' => ⁅y, m'⁆ ∈ Submodule.span R s) x", " ⁅y, m''⁆ ∈ Submodule.span R s"...
[ " ↑⁅I, N⁆ = Submodule.span R {m | βˆƒ x n, ⁅↑x, ↑n⁆ = m}", " ↑⁅I, N⁆ ≀ Submodule.span R {m | βˆƒ x n, ⁅↑x, ↑n⁆ = m}", " βˆ€ (y : L), βˆ€ m' ∈ Submodule.span R s, ⁅y, m'⁆ ∈ Submodule.span R s", " ⁅y, m'⁆ ∈ Submodule.span R s", " βˆ€ x ∈ s, (fun m' => ⁅y, m'⁆ ∈ Submodule.span R s) x", " ⁅y, m''⁆ ∈ Submodule.span R s"...
import Mathlib.Data.Nat.Defs import Mathlib.Order.Interval.Set.Basic import Mathlib.Tactic.Monotonicity.Attr #align_import data.nat.log from "leanprover-community/mathlib"@"3e00d81bdcbf77c8188bbd18f5524ddc3ed8cac6" namespace Nat --@[pp_nodot] porting note: unknown attribute def log (b : β„•) : β„• β†’ β„• | n => i...
Mathlib/Data/Nat/Log.lean
108
111
theorem pow_le_of_le_log {b x y : β„•} (hy : y β‰  0) (h : x ≀ log b y) : b ^ x ≀ y := by
refine (le_or_lt b 1).elim (fun hb => ?_) fun hb => (pow_le_iff_le_log hb hy).2 h rw [log_of_left_le_one hb, Nat.le_zero] at h rwa [h, Nat.pow_zero, one_le_iff_ne_zero]
[ " (invImage (fun x => x) instWellFoundedRelationOfSizeOf).1 (n / b) a✝", " b.log n = 0 ↔ n < b ∨ b ≀ 1", " (βˆ€ (h : b ≀ n ∧ 1 < b), b.log (n / b) + 1 = 0) ↔ n < b ∨ b ≀ 1", " 0 < b.log n ↔ b ≀ n ∧ 1 < b", " b.log n = b.log (n / b) + 1", " (if h : b ≀ n ∧ 1 < b then b.log (n / b) + 1 else 0) = b.log (n / b)...
[ " (invImage (fun x => x) instWellFoundedRelationOfSizeOf).1 (n / b) a✝", " b.log n = 0 ↔ n < b ∨ b ≀ 1", " (βˆ€ (h : b ≀ n ∧ 1 < b), b.log (n / b) + 1 = 0) ↔ n < b ∨ b ≀ 1", " 0 < b.log n ↔ b ≀ n ∧ 1 < b", " b.log n = b.log (n / b) + 1", " (if h : b ≀ n ∧ 1 < b then b.log (n / b) + 1 else 0) = b.log (n / b)...
import Mathlib.Analysis.Normed.Group.InfiniteSum import Mathlib.Topology.Instances.ENNReal #align_import analysis.calculus.series from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" open Set Metric TopologicalSpace Function Filter open scoped Topology NNReal variable {Ξ± Ξ² F : Type*} [N...
Mathlib/Analysis/NormedSpace/FunctionSeries.lean
53
56
theorem tendstoUniformly_tsum {f : Ξ± β†’ Ξ² β†’ F} (hu : Summable u) (hfu : βˆ€ n x, β€–f n xβ€– ≀ u n) : TendstoUniformly (fun t : Finset Ξ± => fun x => βˆ‘ n ∈ t, f n x) (fun x => βˆ‘' n, f n x) atTop := by
rw [← tendstoUniformlyOn_univ]; exact tendstoUniformlyOn_tsum hu fun n x _ => hfu n x
[ " TendstoUniformlyOn (fun t x => βˆ‘ n ∈ t, f n x) (fun x => βˆ‘' (n : Ξ±), f n x) atTop s", " βˆ€αΆ  (n : Finset Ξ±) in atTop, βˆ€ x ∈ s, dist (βˆ‘' (n : Ξ±), f n x) (βˆ‘ n ∈ n, f n x) < Ξ΅", " dist (βˆ‘' (n : Ξ±), f n x) (βˆ‘ n ∈ t, f n x) < Ξ΅", " β€–βˆ‘' (x_1 : { x // x βˆ‰ t }), f (↑x_1) xβ€– < Ξ΅", " β€–βˆ‘' (x_1 : { x // x βˆ‰ t }), f (↑x...
[ " TendstoUniformlyOn (fun t x => βˆ‘ n ∈ t, f n x) (fun x => βˆ‘' (n : Ξ±), f n x) atTop s", " βˆ€αΆ  (n : Finset Ξ±) in atTop, βˆ€ x ∈ s, dist (βˆ‘' (n : Ξ±), f n x) (βˆ‘ n ∈ n, f n x) < Ξ΅", " dist (βˆ‘' (n : Ξ±), f n x) (βˆ‘ n ∈ t, f n x) < Ξ΅", " β€–βˆ‘' (x_1 : { x // x βˆ‰ t }), f (↑x_1) xβ€– < Ξ΅", " β€–βˆ‘' (x_1 : { x // x βˆ‰ t }), f (↑x...
import Mathlib.Algebra.BigOperators.Module import Mathlib.Algebra.Order.Field.Basic import Mathlib.Order.Filter.ModEq import Mathlib.Analysis.Asymptotics.Asymptotics import Mathlib.Analysis.SpecificLimits.Basic import Mathlib.Data.List.TFAE import Mathlib.Analysis.NormedSpace.Basic #align_import analysis.specific_lim...
Mathlib/Analysis/SpecificLimits/Normed.lean
132
189
theorem TFAE_exists_lt_isLittleO_pow (f : β„• β†’ ℝ) (R : ℝ) : TFAE [βˆƒ a ∈ Ioo (-R) R, f =o[atTop] (a ^ Β·), βˆƒ a ∈ Ioo 0 R, f =o[atTop] (a ^ Β·), βˆƒ a ∈ Ioo (-R) R, f =O[atTop] (a ^ Β·), βˆƒ a ∈ Ioo 0 R, f =O[atTop] (a ^ Β·), βˆƒ a < R, βˆƒ C : ℝ, (0 < C ∨ 0 < R) ∧ βˆ€ n, |f n| ≀ C * a ^ n, βˆƒ a ∈ Ioo 0...
have A : Ico 0 R βŠ† Ioo (-R) R := fun x hx ↦ ⟨(neg_lt_zero.2 (hx.1.trans_lt hx.2)).trans_le hx.1, hx.2⟩ have B : Ioo 0 R βŠ† Ioo (-R) R := Subset.trans Ioo_subset_Ico_self A -- First we prove that 1-4 are equivalent using 2 β†’ 3 β†’ 4, 1 β†’ 3, and 2 β†’ 1 tfae_have 1 β†’ 3 Β· exact fun ⟨a, ha, H⟩ ↦ ⟨a, ha, H.isBigO⟩...
[ " Summable f", " βˆ€ (i : β„•), 0 ≀ β€–f iβ€–", " Tendsto (fun n => βˆ‘ i ∈ Finset.range n, β€–f iβ€–) atTop (𝓝 r)", " (fun n => r₁ ^ n) =o[atTop] fun n => rβ‚‚ ^ n", " (fun x => β€–r₁ ^ xβ€–) =o[atTop] fun x => β€–rβ‚‚ ^ xβ€–", " [βˆƒ a ∈ Set.Ioo (-R) R, f =o[atTop] fun x => a ^ x, βˆƒ a ∈ Set.Ioo 0 R, f =o[atTop] fun x => a ^ x,\n ...
[ " Summable f", " βˆ€ (i : β„•), 0 ≀ β€–f iβ€–", " Tendsto (fun n => βˆ‘ i ∈ Finset.range n, β€–f iβ€–) atTop (𝓝 r)", " (fun n => r₁ ^ n) =o[atTop] fun n => rβ‚‚ ^ n", " (fun x => β€–r₁ ^ xβ€–) =o[atTop] fun x => β€–rβ‚‚ ^ xβ€–" ]
import Mathlib.MeasureTheory.Measure.Haar.Basic import Mathlib.Analysis.InnerProductSpace.PiL2 #align_import measure_theory.measure.haar.of_basis from "leanprover-community/mathlib"@"92bd7b1ffeb306a89f450bee126ddd8a284c259d" open Set TopologicalSpace MeasureTheory MeasureTheory.Measure FiniteDimensional open sco...
Mathlib/MeasureTheory/Measure/Haar/OfBasis.lean
67
71
theorem image_parallelepiped (f : E β†’β‚—[ℝ] F) (v : ΞΉ β†’ E) : f '' parallelepiped v = parallelepiped (f ∘ v) := by
simp only [parallelepiped, ← image_comp] congr 1 with t simp only [Function.comp_apply, _root_.map_sum, LinearMap.map_smulβ‚›β‚—, RingHom.id_apply]
[ " x ∈ parallelepiped v ↔ βˆƒ t ∈ Icc 0 1, x = βˆ‘ i : ΞΉ, t i β€’ v i", " parallelepiped ⇑b = {x | βˆ€ (i : ΞΉ), (b.repr x) i ∈ Icc 0 1}", " x ∈ parallelepiped ⇑b ↔ x ∈ {x | βˆ€ (i : ΞΉ), (b.repr x) i ∈ Icc 0 1}", " (βˆƒ t, βˆ€ (x_1 : ΞΉ), (0 ≀ t x_1 ∧ t x_1 ≀ 1) ∧ (b.repr x) x_1 = t x_1) ↔ βˆ€ (i : ΞΉ), 0 ≀ (b.repr x) i ∧ (b.rep...
[ " x ∈ parallelepiped v ↔ βˆƒ t ∈ Icc 0 1, x = βˆ‘ i : ΞΉ, t i β€’ v i", " parallelepiped ⇑b = {x | βˆ€ (i : ΞΉ), (b.repr x) i ∈ Icc 0 1}", " x ∈ parallelepiped ⇑b ↔ x ∈ {x | βˆ€ (i : ΞΉ), (b.repr x) i ∈ Icc 0 1}", " (βˆƒ t, βˆ€ (x_1 : ΞΉ), (0 ≀ t x_1 ∧ t x_1 ≀ 1) ∧ (b.repr x) x_1 = t x_1) ↔ βˆ€ (i : ΞΉ), 0 ≀ (b.repr x) i ∧ (b.rep...