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.LinearAlgebra.Dimension.Finrank import Mathlib.LinearAlgebra.InvariantBasisNumber #align_import linear_algebra.dimension from "leanprover-community/mathlib"@"47a5f8186becdbc826190ced4312f8199f9db6a5" noncomputable section universe u v w w' variable {R : Type u} {M : Type v} [Ring R] [AddCommGroup...
Mathlib/LinearAlgebra/Dimension/StrongRankCondition.lean
266
276
theorem linearIndependent_le_basis {ΞΉ : Type w} (b : Basis ΞΉ R M) {ΞΊ : Type w} (v : ΞΊ β†’ M) (i : LinearIndependent R v) : #ΞΊ ≀ #ΞΉ := by
classical -- We split into cases depending on whether `ΞΉ` is infinite. cases fintypeOrInfinite ΞΉ Β· rw [Cardinal.mk_fintype ΞΉ] -- When `ΞΉ` is finite, we have `linearIndependent_le_span`, haveI : Nontrivial R := nontrivial_of_invariantBasisNumber R rw [Fintype.card_congr (Equiv.ofInjective b b.injective)...
[ " Fintype.card ΞΉ ≀ Fintype.card ↑w", " (ΞΉ β†’β‚€ R) β†’β‚—[R] ↑w β†’β‚€ R", " ΞΉ β†’ ↑w β†’β‚€ R", " Injective ⇑(Finsupp.total ΞΉ (↑w β†’β‚€ R) R fun i => Span.repr R w ⟨v i, β‹―βŸ©)", " f = g", " t.card ≀ Fintype.card ↑w", " #ΞΉ ≀ ↑(Fintype.card ↑w)", " ↑(Fintype.card ΞΉ) ≀ ↑(Fintype.card ↑w)", " range v ≀ ↑(span R w)", " ran...
[ " Fintype.card ΞΉ ≀ Fintype.card ↑w", " (ΞΉ β†’β‚€ R) β†’β‚—[R] ↑w β†’β‚€ R", " ΞΉ β†’ ↑w β†’β‚€ R", " Injective ⇑(Finsupp.total ΞΉ (↑w β†’β‚€ R) R fun i => Span.repr R w ⟨v i, β‹―βŸ©)", " f = g", " t.card ≀ Fintype.card ↑w", " #ΞΉ ≀ ↑(Fintype.card ↑w)", " ↑(Fintype.card ΞΉ) ≀ ↑(Fintype.card ↑w)", " range v ≀ ↑(span R w)", " ran...
import Mathlib.Algebra.Order.Group.Basic import Mathlib.Algebra.Order.Ring.Abs import Mathlib.Algebra.Order.Ring.Basic import Mathlib.Algebra.Ring.Nat import Mathlib.Data.ZMod.Basic import Mathlib.GroupTheory.OrderOfElement import Mathlib.RingTheory.Fintype import Mathlib.Tactic.IntervalCases #align_import number_the...
Mathlib/NumberTheory/LucasLehmer.lean
173
174
theorem sZMod_eq_sMod (p : β„•) (i : β„•) : sZMod p i = (sMod p i : ZMod (2 ^ p - 1)) := by
induction i <;> push_cast [← Int.coe_nat_two_pow_pred p, sMod, sZMod, *] <;> rfl
[ " 2 ^ m < 2 ^ n", " 1 < 2", " mersenne k + 1 = 2 ^ k", " 1 ≀ 2 ^ k", " 1 ≀ 2", " 0 ≀ sMod p i", " 0 ≀ sMod p 0", " 0 ≀ sMod p (n✝ + 1)", " 0 ≀ 4 % (2 ^ p - 1)", " 0 ≀ (sMod p n✝ ^ 2 - 2) % (2 ^ p - 1)", " 2 ^ p - 1 β‰  0", " sMod p i % (2 ^ p - 1) = sMod p i", " sMod p 0 % (2 ^ p - 1) = sMod p...
[ " 2 ^ m < 2 ^ n", " 1 < 2", " mersenne k + 1 = 2 ^ k", " 1 ≀ 2 ^ k", " 1 ≀ 2", " 0 ≀ sMod p i", " 0 ≀ sMod p 0", " 0 ≀ sMod p (n✝ + 1)", " 0 ≀ 4 % (2 ^ p - 1)", " 0 ≀ (sMod p n✝ ^ 2 - 2) % (2 ^ p - 1)", " 2 ^ p - 1 β‰  0", " sMod p i % (2 ^ p - 1) = sMod p i", " sMod p 0 % (2 ^ p - 1) = sMod p...
import Mathlib.Algebra.Field.Defs import Mathlib.Tactic.Common #align_import algebra.field.defs from "leanprover-community/mathlib"@"2651125b48fc5c170ab1111afd0817c903b1fc6c" universe u section IsField structure IsField (R : Type u) [Semiring R] : Prop where exists_pair_ne : βˆƒ x y : R, x β‰  y mul_comm ...
Mathlib/Algebra/Field/IsField.lean
84
93
theorem uniq_inv_of_isField (R : Type u) [Ring R] (hf : IsField R) : βˆ€ x : R, x β‰  0 β†’ βˆƒ! y : R, x * y = 1 := by
intro x hx apply exists_unique_of_exists_of_unique Β· exact hf.mul_inv_cancel hx Β· intro y z hxy hxz calc y = y * (x * z) := by rw [hxz, mul_one] _ = x * y * z := by rw [← mul_assoc, hf.mul_comm y x] _ = z := by rw [hxy, one_mul]
[ " a * a⁻¹ = 1", " a⁻¹ = Classical.choose β‹―", " βˆ€ (x : R), x β‰  0 β†’ βˆƒ! y, x * y = 1", " βˆƒ! y, x * y = 1", " βˆƒ x_1, x * x_1 = 1", " βˆ€ (y₁ yβ‚‚ : R), x * y₁ = 1 β†’ x * yβ‚‚ = 1 β†’ y₁ = yβ‚‚", " y = z", " y = y * (x * z)", " y * (x * z) = x * y * z", " x * y * z = z" ]
[ " a * a⁻¹ = 1", " a⁻¹ = Classical.choose β‹―" ]
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
207
211
theorem map_Ο€_preserves_coequalizer_inv : G.map (coequalizer.Ο€ f g) ≫ (PreservesCoequalizer.iso G f g).inv = coequalizer.Ο€ (G.map f) (G.map g) := by
rw [← ΞΉ_comp_coequalizerComparison_assoc, ← PreservesCoequalizer.iso_hom, Iso.hom_inv_id, comp_id]
[ " G.map f ≫ G.map h = G.map g ≫ G.map h", " Cofork.Ο€\n ((Cocones.precompose (diagramIsoParallelPair (parallelPair f g β‹™ G)).inv).obj (G.mapCocone (Cofork.ofΟ€ h w))) ≫\n (Iso.refl\n ((Cocones.precompose (diagramIsoParallelPair (parallelPair f g β‹™ G)).inv).obj\n (G.mapCocone (Cofor...
[ " G.map f ≫ G.map h = G.map g ≫ G.map h", " Cofork.Ο€\n ((Cocones.precompose (diagramIsoParallelPair (parallelPair f g β‹™ G)).inv).obj (G.mapCocone (Cofork.ofΟ€ h w))) ≫\n (Iso.refl\n ((Cocones.precompose (diagramIsoParallelPair (parallelPair f g β‹™ G)).inv).obj\n (G.mapCocone (Cofor...
import Mathlib.Analysis.PSeries import Mathlib.Data.Real.Pi.Wallis import Mathlib.Tactic.AdaptationNote #align_import analysis.special_functions.stirling from "leanprover-community/mathlib"@"2c1d8ca2812b64f88992a5294ea3dba144755cd1" open scoped Topology Real Nat Asymptotics open Finset Filter Nat Real namespace...
Mathlib/Analysis/SpecialFunctions/Stirling.lean
104
120
theorem log_stirlingSeq_diff_le_geo_sum (n : β„•) : log (stirlingSeq (n + 1)) - log (stirlingSeq (n + 2)) ≀ ((1 : ℝ) / (2 * ↑(n + 1) + 1)) ^ 2 / (1 - ((1 : ℝ) / (2 * ↑(n + 1) + 1)) ^ 2) := by
have h_nonneg : (0 : ℝ) ≀ ((1 : ℝ) / (2 * ↑(n + 1) + 1)) ^ 2 := sq_nonneg _ have g : HasSum (fun k : β„• => (((1 : ℝ) / (2 * ↑(n + 1) + 1)) ^ 2) ^ ↑(k + 1)) (((1 : ℝ) / (2 * ↑(n + 1) + 1)) ^ 2 / (1 - ((1 : ℝ) / (2 * ↑(n + 1) + 1)) ^ 2)) := by have := (hasSum_geometric_of_lt_one h_nonneg ?_).mul_left (((1 :...
[ " stirlingSeq 0 = 0", " stirlingSeq 1 = rexp 1 / √2", " (stirlingSeq n).log = (↑n !).log - 1 / 2 * (2 * ↑n).log - ↑n * (↑n / rexp 1).log", " (stirlingSeq 0).log = (↑0!).log - 1 / 2 * (2 * ↑0).log - ↑0 * (↑0 / rexp 1).log", " (stirlingSeq (n✝ + 1)).log = (↑(n✝ + 1)!).log - 1 / 2 * (2 * ↑(n✝ + 1)).log - ↑(n✝ ...
[ " stirlingSeq 0 = 0", " stirlingSeq 1 = rexp 1 / √2", " (stirlingSeq n).log = (↑n !).log - 1 / 2 * (2 * ↑n).log - ↑n * (↑n / rexp 1).log", " (stirlingSeq 0).log = (↑0!).log - 1 / 2 * (2 * ↑0).log - ↑0 * (↑0 / rexp 1).log", " (stirlingSeq (n✝ + 1)).log = (↑(n✝ + 1)!).log - 1 / 2 * (2 * ↑(n✝ + 1)).log - ↑(n✝ ...
import Mathlib.MeasureTheory.OuterMeasure.Caratheodory #align_import measure_theory.measure.outer_measure from "leanprover-community/mathlib"@"343e80208d29d2d15f8050b929aa50fe4ce71b55" noncomputable section open Set Function Filter open scoped Classical NNReal Topology ENNReal namespace MeasureTheory open Outer...
Mathlib/MeasureTheory/OuterMeasure/Induced.lean
65
68
theorem le_extend {s : Ξ±} (h : P s) : m s h ≀ extend m s := by
simp only [extend, le_iInf_iff] intro rfl
[ " extend m s = m s h", " extend m s = ⊀", " c β€’ extend m = extend fun s h => c β€’ m s h", " (c β€’ extend m) s = extend (fun s h => c β€’ m s h) s", " c β€’ β¨… (h : P s), m s h = β¨… (h : P s), c β€’ m s h", " m s h ≀ extend m s", " βˆ€ (i : P s), m s h ≀ m s i", " m s h ≀ m s i✝" ]
[ " extend m s = m s h", " extend m s = ⊀", " c β€’ extend m = extend fun s h => c β€’ m s h", " (c β€’ extend m) s = extend (fun s h => c β€’ m s h) s", " c β€’ β¨… (h : P s), m s h = β¨… (h : P s), c β€’ m s h" ]
import Mathlib.LinearAlgebra.BilinearForm.TensorProduct import Mathlib.LinearAlgebra.QuadraticForm.Basic universe uR uA uM₁ uMβ‚‚ variable {R : Type uR} {A : Type uA} {M₁ : Type uM₁} {Mβ‚‚ : Type uMβ‚‚} open TensorProduct open LinearMap (BilinForm) namespace QuadraticForm section CommRing variable [CommRing R] [CommR...
Mathlib/LinearAlgebra/QuadraticForm/TensorProduct.lean
95
99
theorem associated_baseChange [Invertible (2 : A)] (Q : QuadraticForm R Mβ‚‚) : associated (R := A) (Q.baseChange A) = (associated (R := R) Q).baseChange A := by
dsimp only [QuadraticForm.baseChange, LinearMap.baseChange] rw [associated_tmul (QuadraticForm.sq (R := A)) Q, associated_sq] exact rfl
[ " associated (Q₁.tmul Qβ‚‚) = (associated Q₁).tmul (associated Qβ‚‚)", " associated\n ((let toQ := BilinForm.toQuadraticFormLinearMap A A (M₁ βŠ—[R] Mβ‚‚);\n let tmulB := BilinForm.tensorDistrib R A;\n let toB := AlgebraTensorModule.map associated associated;\n toQ βˆ˜β‚— tmulB βˆ˜β‚— toB)\n (Q₁ ...
[ " associated (Q₁.tmul Qβ‚‚) = (associated Q₁).tmul (associated Qβ‚‚)", " associated\n ((let toQ := BilinForm.toQuadraticFormLinearMap A A (M₁ βŠ—[R] Mβ‚‚);\n let tmulB := BilinForm.tensorDistrib R A;\n let toB := AlgebraTensorModule.map associated associated;\n toQ βˆ˜β‚— tmulB βˆ˜β‚— toB)\n (Q₁ ...
import Mathlib.Algebra.Group.Submonoid.Operations import Mathlib.Data.DFinsupp.Basic #align_import algebra.direct_sum.basic from "leanprover-community/mathlib"@"f7fc89d5d5ff1db2d1242c7bb0e9062ce47ef47c" open Function universe u v w u₁ variable (ΞΉ : Type v) [dec_ΞΉ : DecidableEq ΞΉ] (Ξ² : ΞΉ β†’ Type w) def DirectSum...
Mathlib/Algebra/DirectSum/Basic.lean
155
159
theorem sum_univ_of [Fintype ΞΉ] (x : ⨁ i, Ξ² i) : βˆ‘ i ∈ Finset.univ, of Ξ² i (x i) = x := by
apply DFinsupp.ext (fun i ↦ ?_) rw [DFinsupp.finset_sum_apply] simp [of_apply]
[ " βˆ‘ i : ΞΉ, (of Ξ² i) (x i) = x", " (βˆ‘ i : ΞΉ, (of Ξ² i) (x i)) i = x i", " βˆ‘ a : ΞΉ, ((of Ξ² a) (x a)) i = x i" ]
[]
import Mathlib.Algebra.Polynomial.Module.AEval #align_import data.polynomial.module from "leanprover-community/mathlib"@"63417e01fbc711beaf25fa73b6edb395c0cfddd0" universe u v open Polynomial BigOperators @[nolint unusedArguments] def PolynomialModule (R M : Type*) [CommRing R] [AddCommGroup M] [Module R M] := β„• ...
Mathlib/Algebra/Polynomial/Module/Basic.lean
123
135
theorem monomial_smul_single (i : β„•) (r : R) (j : β„•) (m : M) : monomial i r β€’ single R j m = single R (i + j) (r β€’ m) := by
simp only [LinearMap.mul_apply, Polynomial.aeval_monomial, LinearMap.pow_apply, Module.algebraMap_end_apply, smul_def] induction i generalizing r j m with | zero => rw [Function.iterate_zero, zero_add] exact Finsupp.smul_single r j m | succ n hn => rw [Function.iterate_succ, Function.comp_apply...
[ " f β€’ m = ((aeval (Finsupp.lmapDomain M R Nat.succ)) f) m", " IsScalarTower S R[X] (PolynomialModule R M)", " βˆ€ (x : S) (y : R[X]) (z : PolynomialModule R M), (x β€’ y) β€’ z = x β€’ y β€’ z", " (x β€’ y) β€’ z = x β€’ y β€’ z", " (monomial i) r β€’ (single R j) m = (single R (i + j)) (r β€’ m)", " r β€’ (⇑(Finsupp.lmapDomain ...
[ " f β€’ m = ((aeval (Finsupp.lmapDomain M R Nat.succ)) f) m", " IsScalarTower S R[X] (PolynomialModule R M)", " βˆ€ (x : S) (y : R[X]) (z : PolynomialModule R M), (x β€’ y) β€’ z = x β€’ y β€’ z", " (x β€’ y) β€’ z = x β€’ y β€’ z" ]
import Mathlib.Analysis.Analytic.IsolatedZeros import Mathlib.Analysis.Complex.CauchyIntegral import Mathlib.Analysis.Complex.AbsMax #align_import analysis.complex.open_mapping from "leanprover-community/mathlib"@"f9dd3204df14a0749cd456fac1e6849dfe7d2b88" open Set Filter Metric Complex open scoped Topology vari...
Mathlib/Analysis/Complex/OpenMapping.lean
77
106
theorem AnalyticAt.eventually_constant_or_nhds_le_map_nhds_aux (hf : AnalyticAt β„‚ f zβ‚€) : (βˆ€αΆ  z in 𝓝 zβ‚€, f z = f zβ‚€) ∨ 𝓝 (f zβ‚€) ≀ map f (𝓝 zβ‚€) := by
/- The function `f` is analytic in a neighborhood of `zβ‚€`; by the isolated zeros principle, if `f` is not constant in a neighborhood of `zβ‚€`, then it is nonzero, and therefore bounded below, on every small enough circle around `zβ‚€` and then `DiffContOnCl.ball_subset_image_closedBall` provides an explicit...
[ " ball (f zβ‚€) (Ξ΅ / 2) βŠ† f '' closedBall zβ‚€ r", " v ∈ f '' closedBall zβ‚€ r", " Ξ΅ / 2 ≀ β€–f z - vβ€–", " β€–f zβ‚€ - vβ€– < Ξ΅ / 2", " f z - v = 0", " False", " βˆ€αΆ  (w : β„‚) in 𝓝 z, f w = f z", " f h - v = f z - v β†’ f h = f z", " (βˆ€αΆ  (z : β„‚) in 𝓝 zβ‚€, f z = f zβ‚€) ∨ 𝓝 (f zβ‚€) ≀ map f (𝓝 zβ‚€)", " 𝓝 (f zβ‚€) ≀ map...
[ " ball (f zβ‚€) (Ξ΅ / 2) βŠ† f '' closedBall zβ‚€ r", " v ∈ f '' closedBall zβ‚€ r", " Ξ΅ / 2 ≀ β€–f z - vβ€–", " β€–f zβ‚€ - vβ€– < Ξ΅ / 2", " f z - v = 0", " False", " βˆ€αΆ  (w : β„‚) in 𝓝 z, f w = f z", " f h - v = f z - v β†’ f h = f z" ]
import Mathlib.MeasureTheory.Function.AEEqFun.DomAct import Mathlib.MeasureTheory.Function.LpSpace set_option autoImplicit true open MeasureTheory Filter open scoped ENNReal namespace DomMulAct variable {M N Ξ± E : Type*} [MeasurableSpace M] [MeasurableSpace N] [MeasurableSpace Ξ±] [NormedAddCommGroup E] {ΞΌ : Me...
Mathlib/MeasureTheory/Function/LpSpace/DomAct/Basic.lean
82
83
theorem smul_Lp_sub (c : Mα΅ˆα΅α΅ƒ) : βˆ€ f g : Lp E p ΞΌ, c β€’ (f - g) = c β€’ f - c β€’ g := by
rintro ⟨⟨⟩, _⟩ ⟨⟨⟩, _⟩; rfl
[ " βˆ€ (f g : β†₯(Lp E p ΞΌ)), c β€’ (f + g) = c β€’ f + c β€’ g", " c β€’ (⟨Quot.mk Setoid.r a✝¹, property✝¹⟩ + ⟨Quot.mk Setoid.r a✝, property✝⟩) =\n c β€’ ⟨Quot.mk Setoid.r a✝¹, property✝¹⟩ + c β€’ ⟨Quot.mk Setoid.r a✝, property✝⟩", " c β€’ -f = -(c β€’ f)", " c β€’ -⟨Quot.mk Setoid.r a✝, property✝⟩ = -(c β€’ ⟨Quot.mk Setoid.r a✝...
[ " βˆ€ (f g : β†₯(Lp E p ΞΌ)), c β€’ (f + g) = c β€’ f + c β€’ g", " c β€’ (⟨Quot.mk Setoid.r a✝¹, property✝¹⟩ + ⟨Quot.mk Setoid.r a✝, property✝⟩) =\n c β€’ ⟨Quot.mk Setoid.r a✝¹, property✝¹⟩ + c β€’ ⟨Quot.mk Setoid.r a✝, property✝⟩", " c β€’ -f = -(c β€’ f)", " c β€’ -⟨Quot.mk Setoid.r a✝, property✝⟩ = -(c β€’ ⟨Quot.mk Setoid.r a✝...
import Mathlib.GroupTheory.OrderOfElement import Mathlib.Data.Finset.NoncommProd import Mathlib.Data.Fintype.BigOperators import Mathlib.Data.Nat.GCD.BigOperators import Mathlib.Order.SupIndep #align_import group_theory.noncomm_pi_coprod from "leanprover-community/mathlib"@"6f9f36364eae3f42368b04858fd66d6d9ae730d8" ...
Mathlib/GroupTheory/NoncommPiCoprod.lean
55
78
theorem eq_one_of_noncommProd_eq_one_of_independent {ΞΉ : Type*} (s : Finset ΞΉ) (f : ΞΉ β†’ G) (comm) (K : ΞΉ β†’ Subgroup G) (hind : CompleteLattice.Independent K) (hmem : βˆ€ x ∈ s, f x ∈ K x) (heq1 : s.noncommProd f comm = 1) : βˆ€ i ∈ s, f i = 1 := by
classical revert heq1 induction' s using Finset.induction_on with i s hnmem ih Β· simp Β· have hcomm := comm.mono (Finset.coe_subset.2 <| Finset.subset_insert _ _) simp only [Finset.forall_mem_insert] at hmem have hmem_bsupr : s.noncommProd f hcomm ∈ ⨆ i ∈ (s : Set ΞΉ), K i := by ref...
[ " βˆ€ i ∈ s, f i = 1", " s.noncommProd f comm = 1 β†’ βˆ€ i ∈ s, f i = 1", " βˆ….noncommProd f comm = 1 β†’ βˆ€ i ∈ βˆ…, f i = 1", " (insert i s).noncommProd f comm = 1 β†’ βˆ€ i_1 ∈ insert i s, f i_1 = 1", " s.noncommProd f hcomm ∈ ⨆ i ∈ ↑s, K i", " βˆ€ c ∈ s, f c ∈ ⨆ i ∈ ↑s, K i", " f x ∈ ⨆ i ∈ ↑s, K i", " βˆ€ i_1 ∈ inse...
[]
import Mathlib.Order.ConditionallyCompleteLattice.Finset import Mathlib.Order.Interval.Finset.Nat #align_import data.nat.lattice from "leanprover-community/mathlib"@"52fa514ec337dd970d71d8de8d0fd68b455a1e54" assert_not_exists MonoidWithZero open Set namespace Nat open scoped Classical noncomputable instance : ...
Mathlib/Data/Nat/Lattice.lean
110
120
theorem sInf_upward_closed_eq_succ_iff {s : Set β„•} (hs : βˆ€ k₁ kβ‚‚ : β„•, k₁ ≀ kβ‚‚ β†’ k₁ ∈ s β†’ kβ‚‚ ∈ s) (k : β„•) : sInf s = k + 1 ↔ k + 1 ∈ s ∧ k βˆ‰ s := by
constructor Β· intro H rw [eq_Ici_of_nonempty_of_upward_closed (nonempty_of_sInf_eq_succ _) hs, H, mem_Ici, mem_Ici] Β· exact ⟨le_rfl, k.not_succ_le_self⟩; Β· exact k Β· assumption Β· rintro ⟨H, H'⟩ rw [sInf_def (⟨_, H⟩ : s.Nonempty), find_eq_iff] exact ⟨H, fun n hnk hns ↦ H' <| hs n k (Nat.lt...
[ " sInf s = 0 ↔ 0 ∈ s ∨ s = βˆ…", " sInf βˆ… = 0 ↔ 0 ∈ βˆ… ∨ βˆ… = βˆ…", " sInf βˆ… = 0", " 0 ∈ βˆ… ∨ βˆ… = βˆ…", " βˆ… = βˆ…", " iInf f = 0", " β¨… i, 0 = 0", " (0 ∈ range fun i => 0) ∨ (range fun i => 0) = βˆ…", " sInf s ∈ s", " Nat.find h ∈ s", " m βˆ‰ s", " m βˆ‰ βˆ…", " sInf s ≀ m", " Nat.find β‹― ≀ m", " s.Nonempty"...
[ " sInf s = 0 ↔ 0 ∈ s ∨ s = βˆ…", " sInf βˆ… = 0 ↔ 0 ∈ βˆ… ∨ βˆ… = βˆ…", " sInf βˆ… = 0", " 0 ∈ βˆ… ∨ βˆ… = βˆ…", " βˆ… = βˆ…", " iInf f = 0", " β¨… i, 0 = 0", " (0 ∈ range fun i => 0) ∨ (range fun i => 0) = βˆ…", " sInf s ∈ s", " Nat.find h ∈ s", " m βˆ‰ s", " m βˆ‰ βˆ…", " sInf s ≀ m", " Nat.find β‹― ≀ m", " s.Nonempty"...
import Mathlib.Algebra.Order.BigOperators.Ring.Finset import Mathlib.Data.NNRat.Defs variable {ΞΉ Ξ± : Type*} namespace NNRat @[norm_cast] theorem coe_list_sum (l : List β„šβ‰₯0) : (l.sum : β„š) = (l.map (↑)).sum := map_list_sum coeHom _ #align nnrat.coe_list_sum NNRat.coe_list_sum @[norm_cast] theorem coe_list_prod (...
Mathlib/Data/NNRat/BigOperators.lean
52
55
theorem toNNRat_prod_of_nonneg {s : Finset Ξ±} {f : Ξ± β†’ β„š} (hf : βˆ€ a ∈ s, 0 ≀ f a) : (∏ a ∈ s, f a).toNNRat = ∏ a ∈ s, (f a).toNNRat := by
rw [← coe_inj, coe_prod, Rat.coe_toNNRat _ (Finset.prod_nonneg hf)] exact Finset.prod_congr rfl fun x hxs ↦ by rw [Rat.coe_toNNRat _ (hf x hxs)]
[ " (βˆ‘ a ∈ s, f a).toNNRat = βˆ‘ a ∈ s, (f a).toNNRat", " βˆ‘ i ∈ s, f i = βˆ‘ a ∈ s, ↑(f a).toNNRat", " f x = ↑(f x).toNNRat", " (∏ a ∈ s, f a).toNNRat = ∏ a ∈ s, (f a).toNNRat", " ∏ i ∈ s, f i = ∏ a ∈ s, ↑(f a).toNNRat" ]
[ " (βˆ‘ a ∈ s, f a).toNNRat = βˆ‘ a ∈ s, (f a).toNNRat", " βˆ‘ i ∈ s, f i = βˆ‘ a ∈ s, ↑(f a).toNNRat", " f x = ↑(f x).toNNRat" ]
import Mathlib.Topology.MetricSpace.HausdorffDistance #align_import topology.metric_space.hausdorff_distance from "leanprover-community/mathlib"@"bc91ed7093bf098d253401e69df601fc33dde156" noncomputable section open NNReal ENNReal Topology Set Filter Bornology universe u v w variable {ΞΉ : Sort*} {Ξ± : Type u} {Ξ² :...
Mathlib/Topology/MetricSpace/Thickening.lean
238
239
theorem cthickening_empty (Ξ΄ : ℝ) : cthickening Ξ΄ (βˆ… : Set Ξ±) = βˆ… := by
simp only [cthickening, ENNReal.ofReal_ne_top, setOf_false, infEdist_empty, top_le_iff]
[ " βˆ€αΆ  (Ξ΄ : ℝ) in 𝓝 0, x βˆ‰ cthickening Ξ΄ E", " x βˆ‰ cthickening Ξ΄ E", " ENNReal.ofReal Ξ΄ < infEdist x E", " x ∈ cthickening Ξ΄ E", " edist x y ≀ ENNReal.ofReal Ξ΄", " ENNReal.ofReal (dist x y) ≀ ENNReal.ofReal Ξ΄", " cthickening Ξ΄ βˆ… = βˆ…" ]
[ " βˆ€αΆ  (Ξ΄ : ℝ) in 𝓝 0, x βˆ‰ cthickening Ξ΄ E", " x βˆ‰ cthickening Ξ΄ E", " ENNReal.ofReal Ξ΄ < infEdist x E", " x ∈ cthickening Ξ΄ E", " edist x y ≀ ENNReal.ofReal Ξ΄", " ENNReal.ofReal (dist x y) ≀ ENNReal.ofReal Ξ΄" ]
import Mathlib.Analysis.InnerProductSpace.PiL2 import Mathlib.Combinatorics.Additive.AP.Three.Defs import Mathlib.Combinatorics.Pigeonhole import Mathlib.Data.Complex.ExponentialBounds #align_import combinatorics.additive.behrend from "leanprover-community/mathlib"@"4fa54b337f7d52805480306db1b1439c741848c8" open N...
Mathlib/Combinatorics/Additive/AP/Three/Behrend.lean
118
118
theorem sphere_zero_right (n k : β„•) : sphere (n + 1) 0 k = βˆ… := by
simp [sphere]
[ " ThreeAPFree (frontier s)", " a = b", " (1 / 2) β€’ a + (1 / 2) β€’ c = b", " 2 β‰  0", " a = (1 / 2) β€’ a + (1 / 2) β€’ c", " c = (2⁻¹ + 2⁻¹) β€’ c", " c = 1 β€’ c", " ThreeAPFree (sphere x r)", " ThreeAPFree (sphere x 0)", " ThreeAPFree {x}", " sphere x r = frontier (closedBall x r)", " x ∈ box n d ↔ βˆ€ ...
[ " ThreeAPFree (frontier s)", " a = b", " (1 / 2) β€’ a + (1 / 2) β€’ c = b", " 2 β‰  0", " a = (1 / 2) β€’ a + (1 / 2) β€’ c", " c = (2⁻¹ + 2⁻¹) β€’ c", " c = 1 β€’ c", " ThreeAPFree (sphere x r)", " ThreeAPFree (sphere x 0)", " ThreeAPFree {x}", " sphere x r = frontier (closedBall x r)", " x ∈ box n d ↔ βˆ€ ...
import Mathlib.Algebra.Group.Pi.Lemmas import Mathlib.Topology.Algebra.Monoid import Mathlib.Topology.Homeomorph #align_import topology.algebra.group_with_zero from "leanprover-community/mathlib"@"c10e724be91096453ee3db13862b9fb9a992fef2" open Topology Filter Function variable {Ξ± Ξ² Gβ‚€ : Type*} section DivConst...
Mathlib/Topology/Algebra/GroupWithZero.lean
69
71
theorem ContinuousOn.div_const (hf : ContinuousOn f s) (y : Gβ‚€) : ContinuousOn (fun x => f x / y) s := by
simpa only [div_eq_mul_inv] using hf.mul continuousOn_const
[ " Tendsto (fun a => f a / y) l (𝓝 (x / y))", " ContinuousOn (fun x => f x / y) s" ]
[ " Tendsto (fun a => f a / y) l (𝓝 (x / y))" ]
import Mathlib.Algebra.Order.Group.Nat import Mathlib.Data.Finset.Antidiagonal import Mathlib.Data.Finset.Card import Mathlib.Data.Multiset.NatAntidiagonal #align_import data.finset.nat_antidiagonal from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" open Function namespace Finset name...
Mathlib/Data/Finset/NatAntidiagonal.lean
89
99
theorem antidiagonal_succ_succ' {n : β„•} : antidiagonal (n + 2) = cons (0, n + 2) (cons (n + 2, 0) ((antidiagonal n).map (Embedding.prodMap ⟨Nat.succ, Nat.succ_injective⟩ ⟨Nat.succ, Nat.succ_injective⟩)) <| by simp) (by simp) := by
simp_rw [antidiagonal_succ (n + 1), antidiagonal_succ', Finset.map_cons, map_map] rfl
[ " xy ∈ (fun n => { val := Multiset.Nat.antidiagonal n, nodup := β‹― }) n ↔ xy.1 + xy.2 = n", " antidiagonal n = map { toFun := fun i => (n - i, i), inj' := β‹― } (range (n + 1))", " map ({ toFun := fun i => (i, n - i), inj' := β‹― }.trans { toFun := Prod.swap, inj' := β‹― }) (range (n + 1)) =\n map { toFun := fun i ...
[ " xy ∈ (fun n => { val := Multiset.Nat.antidiagonal n, nodup := β‹― }) n ↔ xy.1 + xy.2 = n", " antidiagonal n = map { toFun := fun i => (n - i, i), inj' := β‹― } (range (n + 1))", " map ({ toFun := fun i => (i, n - i), inj' := β‹― }.trans { toFun := Prod.swap, inj' := β‹― }) (range (n + 1)) =\n map { toFun := fun i ...
import Mathlib.Algebra.Homology.Additive import Mathlib.AlgebraicTopology.MooreComplex import Mathlib.Algebra.BigOperators.Fin import Mathlib.CategoryTheory.Preadditive.Opposite import Mathlib.CategoryTheory.Idempotents.FunctorCategories #align_import algebraic_topology.alternating_face_map_complex from "leanprover-c...
Mathlib/AlgebraicTopology/AlternatingFaceMapComplex.lean
70
112
theorem d_squared (n : β„•) : objD X (n + 1) ≫ objD X n = 0 := by
-- we start by expanding d ≫ d as a double sum dsimp simp only [comp_sum, sum_comp, ← Finset.sum_product'] -- then, we decompose the index set P into a subset S and its complement Sᢜ let P := Fin (n + 2) Γ— Fin (n + 3) let S := Finset.univ.filter fun ij : P => (ij.2 : β„•) ≀ (ij.1 : β„•) erw [← Finset.sum_add...
[ " objD X (n + 1) ≫ objD X n = 0", " (βˆ‘ i : Fin (n + 1 + 2), (-1) ^ ↑i β€’ X.Ξ΄ i) ≫ βˆ‘ i : Fin (n + 2), (-1) ^ ↑i β€’ X.Ξ΄ i = 0", " βˆ‘ x ∈ Finset.univ Γ—Λ’ Finset.univ, ((-1) ^ ↑x.2 β€’ X.Ξ΄ x.2) ≫ ((-1) ^ ↑x.1 β€’ X.Ξ΄ x.1) = 0", " βˆ‘ i ∈ S, ((-1) ^ ↑i.2 β€’ X.Ξ΄ i.2) ≫ ((-1) ^ ↑i.1 β€’ X.Ξ΄ i.1) =\n βˆ‘ x ∈ Sᢜ, -((-1) ^ ↑x.2 β€’ ...
[]
import Mathlib.Analysis.SpecialFunctions.Log.Base import Mathlib.MeasureTheory.Measure.MeasureSpaceDef #align_import measure_theory.measure.doubling from "leanprover-community/mathlib"@"5f6e827d81dfbeb6151d7016586ceeb0099b9655" noncomputable section open Set Filter Metric MeasureTheory TopologicalSpace ENNReal NN...
Mathlib/MeasureTheory/Measure/Doubling.lean
113
129
theorem eventually_measure_mul_le_scalingConstantOf_mul (K : ℝ) : βˆƒ R : ℝ, 0 < R ∧ βˆ€ x t r, t ∈ Ioc 0 K β†’ r ≀ R β†’ ΞΌ (closedBall x (t * r)) ≀ scalingConstantOf ΞΌ K * ΞΌ (closedBall x r) := by
have h := Classical.choose_spec (exists_eventually_forall_measure_closedBall_le_mul μ K) rcases mem_nhdsWithin_Ioi_iff_exists_Ioc_subset.1 h with ⟨R, Rpos, hR⟩ refine ⟨R, Rpos, fun x t r ht hr => ?_⟩ rcases lt_trichotomy r 0 with (rneg | rfl | rpos) · have : t * r < 0 := mul_neg_of_pos_of_neg ht.1 rneg s...
[ " βˆƒ C, βˆ€αΆ  (Ξ΅ : ℝ) in 𝓝[>] 0, βˆ€ (x : Ξ±), βˆ€ t ≀ K, ΞΌ (closedBall x (t * Ξ΅)) ≀ ↑C * ΞΌ (closedBall x Ξ΅)", " βˆ€ (n : β„•), βˆ€αΆ  (Ξ΅ : ℝ) in 𝓝[>] 0, βˆ€ (x : Ξ±), ΞΌ (closedBall x (2 ^ n * Ξ΅)) ≀ ↑(C ^ n) * ΞΌ (closedBall x Ξ΅)", " βˆ€αΆ  (Ξ΅ : ℝ) in 𝓝[>] 0, βˆ€ (x : Ξ±), ΞΌ (closedBall x (2 ^ n * Ξ΅)) ≀ ↑(C ^ n) * ΞΌ (closedBall x Ξ΅)", ...
[ " βˆƒ C, βˆ€αΆ  (Ξ΅ : ℝ) in 𝓝[>] 0, βˆ€ (x : Ξ±), βˆ€ t ≀ K, ΞΌ (closedBall x (t * Ξ΅)) ≀ ↑C * ΞΌ (closedBall x Ξ΅)", " βˆ€ (n : β„•), βˆ€αΆ  (Ξ΅ : ℝ) in 𝓝[>] 0, βˆ€ (x : Ξ±), ΞΌ (closedBall x (2 ^ n * Ξ΅)) ≀ ↑(C ^ n) * ΞΌ (closedBall x Ξ΅)", " βˆ€αΆ  (Ξ΅ : ℝ) in 𝓝[>] 0, βˆ€ (x : Ξ±), ΞΌ (closedBall x (2 ^ n * Ξ΅)) ≀ ↑(C ^ n) * ΞΌ (closedBall x Ξ΅)", ...
import Mathlib.Topology.Sets.Opens #align_import topology.sets.closeds from "leanprover-community/mathlib"@"dc6c365e751e34d100e80fe6e314c3c3e0fd2988" open Order OrderDual Set variable {ΞΉ Ξ± Ξ² : Type*} [TopologicalSpace Ξ±] [TopologicalSpace Ξ²] namespace TopologicalSpace structure Closeds (Ξ± : Type*) [Topolog...
Mathlib/Topology/Sets/Closeds.lean
110
111
theorem coe_sup (s t : Closeds Ξ±) : (↑(s βŠ” t) : Set Ξ±) = ↑s βˆͺ ↑t := by
rfl
[ " s = t", " { carrier := carrier✝, closed' := closed'✝ } = t", " { carrier := carrier✝¹, closed' := closed'✝¹ } = { carrier := carrier✝, closed' := closed'✝ }", " ↑(s βŠ” t) = ↑s βˆͺ ↑t" ]
[ " s = t", " { carrier := carrier✝, closed' := closed'✝ } = t", " { carrier := carrier✝¹, closed' := closed'✝¹ } = { carrier := carrier✝, closed' := closed'✝ }" ]
import Mathlib.Algebra.GeomSum import Mathlib.Algebra.Order.Ring.Basic import Mathlib.Algebra.Ring.Int import Mathlib.NumberTheory.Padics.PadicVal import Mathlib.RingTheory.Ideal.Quotient #align_import number_theory.multiplicity from "leanprover-community/mathlib"@"e8638a0fcaf73e4500469f368ef9494e495099b3" open I...
Mathlib/NumberTheory/Multiplicity.lean
56
71
theorem sq_dvd_add_pow_sub_sub (p x : R) (n : β„•) : p ^ 2 ∣ (x + p) ^ n - x ^ (n - 1) * p * n - x ^ n := by
cases' n with n n Β· simp only [pow_zero, Nat.cast_zero, sub_zero, sub_self, dvd_zero, Nat.zero_eq, mul_zero] Β· simp only [Nat.succ_sub_succ_eq_sub, tsub_zero, Nat.cast_succ, add_pow, Finset.sum_range_succ, Nat.choose_self, Nat.succ_sub _, tsub_self, pow_one, Nat.choose_succ_self_right, pow_zero, mul_...
[ " p ∣ βˆ‘ i ∈ range n, x ^ i * y ^ (n - 1 - i) ↔ p ∣ ↑n * y ^ (n - 1)", " p ∣ βˆ‘ i ∈ range n, x ^ i * y ^ (n - 1 - i) ↔ p ∣ ↑n * x ^ (n - 1)", " p ∣ y - x", " p ^ 2 ∣ (x + p) ^ n - x ^ (n - 1) * p * ↑n - x ^ n", " p ^ 2 ∣ (x + p) ^ 0 - x ^ (0 - 1) * p * ↑0 - x ^ 0", " p ^ 2 ∣ (x + p) ^ (n + 1) - x ^ (n + 1 -...
[ " p ∣ βˆ‘ i ∈ range n, x ^ i * y ^ (n - 1 - i) ↔ p ∣ ↑n * y ^ (n - 1)", " p ∣ βˆ‘ i ∈ range n, x ^ i * y ^ (n - 1 - i) ↔ p ∣ ↑n * x ^ (n - 1)", " p ∣ y - x" ]
import Mathlib.Algebra.Polynomial.RingDivision import Mathlib.RingTheory.Polynomial.Nilpotent open scoped Classical Polynomial open Polynomial noncomputable section
Mathlib/RingTheory/Polynomial/IrreducibleRing.lean
37
61
theorem Polynomial.Monic.irreducible_of_irreducible_map_of_isPrime_nilradical {R S : Type*} [CommRing R] [(nilradical R).IsPrime] [CommRing S] [IsDomain S] (Ο† : R β†’+* S) (f : R[X]) (hm : f.Monic) (hi : Irreducible (f.map Ο†)) : Irreducible f := by
let R' := R β§Έ nilradical R let ψ : R' β†’+* S := Ideal.Quotient.lift (nilradical R) Ο† (haveI := RingHom.ker_isPrime Ο†; nilradical_le_prime (RingHom.ker Ο†)) let ΞΉ := algebraMap R R' rw [show Ο† = ψ.comp ΞΉ from rfl, ← map_map] at hi replace hi := hm.map ΞΉ |>.irreducible_of_irreducible_map _ _ hi refine ⟨fun...
[ " Irreducible f", " IsUnit a ∨ IsUnit b", " Polynomial.map ΞΉ f = Polynomial.map ΞΉ a * Polynomial.map ΞΉ b", " IsNilpotent (b.coeff i)", " IsUnit (-(a.coeff f.natDegree * b.coeff 0))", " IsUnit (βˆ‘ x ∈ Finset.range f.natDegree, a.coeff x * b.coeff (f.natDegree - x) - 1)" ]
[]
import Mathlib.CategoryTheory.Limits.Shapes.Pullbacks import Mathlib.CategoryTheory.Limits.Preserves.Basic #align_import category_theory.limits.preserves.shapes.pullbacks from "leanprover-community/mathlib"@"f11e306adb9f2a393539d2bb4293bf1b42caa7ac" noncomputable section universe v₁ vβ‚‚ u₁ uβ‚‚ -- Porting note: ne...
Mathlib/CategoryTheory/Limits/Preserves/Shapes/Pullbacks.lean
225
228
theorem PreservesPushout.inl_iso_hom : pushout.inl ≫ (PreservesPushout.iso G f g).hom = G.map pushout.inl := by
delta PreservesPushout.iso simp
[ " G.map f ≫ G.map h = G.map g ≫ G.map k", " βˆ€ (j : WalkingSpan),\n ((Cocones.precompose (diagramIsoSpan (span f g β‹™ G)).symm.hom).obj (G.mapCocone (PushoutCocone.mk h k comm))).ΞΉ.app\n j ≫\n (Iso.refl\n ((Cocones.precompose (diagramIsoSpan (span f g β‹™ G)).symm.hom).obj\n ...
[ " G.map f ≫ G.map h = G.map g ≫ G.map k", " βˆ€ (j : WalkingSpan),\n ((Cocones.precompose (diagramIsoSpan (span f g β‹™ G)).symm.hom).obj (G.mapCocone (PushoutCocone.mk h k comm))).ΞΉ.app\n j ≫\n (Iso.refl\n ((Cocones.precompose (diagramIsoSpan (span f g β‹™ G)).symm.hom).obj\n ...
import Mathlib.Algebra.Bounds import Mathlib.Algebra.Order.Field.Basic -- Porting note: `LinearOrderedField`, etc import Mathlib.Data.Set.Pointwise.SMul #align_import algebra.order.pointwise from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" open Function Set open Pointwise variable ...
Mathlib/Algebra/Order/Pointwise.lean
160
162
theorem csSup_div (hsβ‚€ : s.Nonempty) (hs₁ : BddAbove s) (htβ‚€ : t.Nonempty) (ht₁ : BddBelow t) : sSup (s / t) = sSup s / sInf t := by
rw [div_eq_mul_inv, csSup_mul hsβ‚€ hs₁ htβ‚€.inv ht₁.inv, csSup_inv htβ‚€ ht₁, div_eq_mul_inv]
[ " sSup s⁻¹ = (sInf s)⁻¹", " sSup (Inv.inv '' s) = (sInf s)⁻¹", " sInf s⁻¹ = (sSup s)⁻¹", " sInf (Inv.inv '' s) = (sSup s)⁻¹", " sSup (s / t) = sSup s / sInf t" ]
[ " sSup s⁻¹ = (sInf s)⁻¹", " sSup (Inv.inv '' s) = (sInf s)⁻¹", " sInf s⁻¹ = (sSup s)⁻¹", " sInf (Inv.inv '' s) = (sSup s)⁻¹" ]
import Mathlib.MeasureTheory.Measure.Restrict open scoped ENNReal NNReal Topology open Set MeasureTheory Measure Filter Function MeasurableSpace ENNReal variable {Ξ± Ξ² Ξ΄ ΞΉ : Type*} namespace MeasureTheory variable {m0 : MeasurableSpace Ξ±} [MeasurableSpace Ξ²] {ΞΌ Ξ½ ν₁ Ξ½β‚‚: Measure Ξ±} {s t : Set Ξ±} section IsFinit...
Mathlib/MeasureTheory/Measure/Typeclasses.lean
41
44
theorem not_isFiniteMeasure_iff : Β¬IsFiniteMeasure ΞΌ ↔ ΞΌ Set.univ = ∞ := by
refine ⟨fun h => ?_, fun h => fun h' => h'.measure_univ_lt_top.ne h⟩ by_contra h' exact h ⟨lt_top_iff_ne_top.mpr h'⟩
[ " Β¬IsFiniteMeasure ΞΌ ↔ ΞΌ univ = ⊀", " ΞΌ univ = ⊀", " False" ]
[]
import Mathlib.Algebra.GeomSum import Mathlib.Algebra.Order.Ring.Basic import Mathlib.Algebra.Ring.Int import Mathlib.NumberTheory.Padics.PadicVal import Mathlib.RingTheory.Ideal.Quotient #align_import number_theory.multiplicity from "leanprover-community/mathlib"@"e8638a0fcaf73e4500469f368ef9494e495099b3" open I...
Mathlib/NumberTheory/Multiplicity.lean
39
43
theorem dvd_geom_sumβ‚‚_iff_of_dvd_sub {x y p : R} (h : p ∣ x - y) : (p ∣ βˆ‘ i ∈ range n, x ^ i * y ^ (n - 1 - i)) ↔ p ∣ n * y ^ (n - 1) := by
rw [← mem_span_singleton, ← Ideal.Quotient.eq] at h simp only [← mem_span_singleton, ← eq_zero_iff_mem, RingHom.map_geom_sumβ‚‚, h, geom_sumβ‚‚_self, _root_.map_mul, map_pow, map_natCast]
[ " p ∣ βˆ‘ i ∈ range n, x ^ i * y ^ (n - 1 - i) ↔ p ∣ ↑n * y ^ (n - 1)" ]
[]
import Mathlib.Order.Interval.Set.UnorderedInterval import Mathlib.Algebra.Order.Interval.Set.Monoid import Mathlib.Data.Set.Pointwise.Basic import Mathlib.Algebra.Order.Field.Basic import Mathlib.Algebra.Order.Group.MinMax #align_import data.set.pointwise.interval from "leanprover-community/mathlib"@"2196ab363eb097c...
Mathlib/Data/Set/Pointwise/Interval.lean
634
635
theorem preimage_mul_const_Icc (a b : α) {c : α} (h : 0 < c) : (fun x => x * c) ⁻¹' Icc a b = Icc (a / c) (b / c) := by
simp [← Ici_inter_Iic, h]
[ " (fun x => x * c) ⁻¹' Ioo a b = Ioo (a / c) (b / c)", " (fun x => x * c) ⁻¹' Ioc a b = Ioc (a / c) (b / c)", " (fun x => x * c) ⁻¹' Ico a b = Ico (a / c) (b / c)", " (fun x => x * c) ⁻¹' Icc a b = Icc (a / c) (b / c)" ]
[ " (fun x => x * c) ⁻¹' Ioo a b = Ioo (a / c) (b / c)", " (fun x => x * c) ⁻¹' Ioc a b = Ioc (a / c) (b / c)", " (fun x => x * c) ⁻¹' Ico a b = Ico (a / c) (b / c)" ]
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
172
175
theorem eq_zero_of_dvd_of_natDegree_lt {p q : R[X]} (h₁ : p ∣ q) (hβ‚‚ : natDegree q < natDegree p) : q = 0 := by
by_contra hc exact (lt_iff_not_ge _ _).mp hβ‚‚ (natDegree_le_of_dvd h₁ hc)
[ " a✝ = 0 ∨ b✝ = 0", " a✝.leadingCoeff = 0 ∨ b✝.leadingCoeff = 0", " a✝.leadingCoeff * b✝.leadingCoeff = 0", " (p * q).natDegree = p.natDegree + q.natDegree", " (p * q).trailingDegree = p.trailingDegree + q.trailingDegree", " ↑(p.natTrailingDegree + q.natTrailingDegree) = ↑p.natTrailingDegree + ↑q.natTrail...
[ " a✝ = 0 ∨ b✝ = 0", " a✝.leadingCoeff = 0 ∨ b✝.leadingCoeff = 0", " a✝.leadingCoeff * b✝.leadingCoeff = 0", " (p * q).natDegree = p.natDegree + q.natDegree", " (p * q).trailingDegree = p.trailingDegree + q.trailingDegree", " ↑(p.natTrailingDegree + q.natTrailingDegree) = ↑p.natTrailingDegree + ↑q.natTrail...
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
64
73
theorem unpair_pair (a b : β„•) : unpair (pair a b) = (a, b) := by
dsimp only [pair]; split_ifs with h Β· show unpair (b * b + a) = (a, b) have be : sqrt (b * b + a) = b := sqrt_add_eq _ (le_trans (le_of_lt h) (Nat.le_add_left _ _)) simp [unpair, be, Nat.add_sub_cancel_left, h] Β· show unpair (a * a + a + b) = (a, b) have ae : sqrt (a * a + (a + b)) = a := by rw...
[ " 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.Topology.Order.ProjIcc import Mathlib.Topology.ContinuousFunction.Ordered import Mathlib.Topology.CompactOpen import Mathlib.Topology.UnitInterval #align_import topology.homotopy.basic from "leanprover-community/mathlib"@"11c53f174270aa43140c0b26dabce5fc4a253e80" noncomputable section universe u v ...
Mathlib/Topology/Homotopy/Basic.lean
172
175
theorem extend_apply_of_one_le (F : Homotopy fβ‚€ f₁) {t : ℝ} (ht : 1 ≀ t) (x : X) : F.extend t x = f₁ x := by
rw [← F.apply_one] exact ContinuousMap.congr_fun (Set.IccExtend_of_right_le (zero_le_one' ℝ) F.curry ht) x
[ " f = g", " { toFun := toFun✝, continuous_toFun := continuous_toFun✝, map_zero_left := map_zero_left✝,\n map_one_left := map_one_left✝ } =\n g", " { toFun := toFun✝¹, continuous_toFun := continuous_toFun✝¹, map_zero_left := map_zero_left✝¹,\n map_one_left := map_one_left✝¹ } =\n { toFun := toFun...
[ " f = g", " { toFun := toFun✝, continuous_toFun := continuous_toFun✝, map_zero_left := map_zero_left✝,\n map_one_left := map_one_left✝ } =\n g", " { toFun := toFun✝¹, continuous_toFun := continuous_toFun✝¹, map_zero_left := map_zero_left✝¹,\n map_one_left := map_one_left✝¹ } =\n { toFun := toFun...
import Mathlib.Algebra.BigOperators.NatAntidiagonal import Mathlib.Topology.Algebra.InfiniteSum.Constructions import Mathlib.Topology.Algebra.Ring.Basic #align_import topology.algebra.infinite_sum.ring from "leanprover-community/mathlib"@"9a59dcb7a2d06bf55da57b9030169219980660cd" open Filter Finset Function open...
Mathlib/Topology/Algebra/InfiniteSum/Ring.lean
38
39
theorem HasSum.mul_right (aβ‚‚) (hf : HasSum f a₁) : HasSum (fun i ↦ f i * aβ‚‚) (a₁ * aβ‚‚) := by
simpa only using hf.map (AddMonoidHom.mulRight aβ‚‚) (continuous_id.mul continuous_const)
[ " HasSum (fun i => aβ‚‚ * f i) (aβ‚‚ * a₁)", " HasSum (fun i => f i * aβ‚‚) (a₁ * aβ‚‚)" ]
[ " HasSum (fun i => aβ‚‚ * f i) (aβ‚‚ * a₁)" ]
import Mathlib.Algebra.QuadraticDiscriminant import Mathlib.Analysis.Convex.SpecificFunctions.Deriv import Mathlib.Analysis.SpecialFunctions.Pow.Complex #align_import analysis.special_functions.trigonometric.complex from "leanprover-community/mathlib"@"8f9fea08977f7e450770933ee6abb20733b47c92" noncomputable secti...
Mathlib/Analysis/SpecialFunctions/Trigonometric/Complex.lean
114
116
theorem cos_eq_neg_one_iff {x : β„‚} : cos x = -1 ↔ βˆƒ k : β„€, Ο€ + k * (2 * Ο€) = x := by
rw [← neg_eq_iff_eq_neg, ← cos_sub_pi, cos_eq_one_iff] simp only [eq_sub_iff_add_eq']
[ " ΞΈ.cos = 0 ↔ βˆƒ k, ΞΈ = (2 * ↑k + 1) * ↑π / 2", " (cexp (ΞΈ * I) + cexp (-ΞΈ * I)) / 2 = 0 ↔ cexp (2 * ΞΈ * I) = -1", " cexp (ΞΈ * I - -ΞΈ * I) = -1 ↔ cexp (2 * ΞΈ * I) = -1", " (βˆƒ n, 2 * I * ΞΈ = ↑π * I + ↑n * (2 * ↑π * I)) ↔ βˆƒ k, ΞΈ = (2 * ↑k + 1) * ↑π / 2", " 2 * I * ΞΈ = ↑π * I + ↑x * (2 * ↑π * I) ↔ ΞΈ = (2 * ↑x +...
[ " ΞΈ.cos = 0 ↔ βˆƒ k, ΞΈ = (2 * ↑k + 1) * ↑π / 2", " (cexp (ΞΈ * I) + cexp (-ΞΈ * I)) / 2 = 0 ↔ cexp (2 * ΞΈ * I) = -1", " cexp (ΞΈ * I - -ΞΈ * I) = -1 ↔ cexp (2 * ΞΈ * I) = -1", " (βˆƒ n, 2 * I * ΞΈ = ↑π * I + ↑n * (2 * ↑π * I)) ↔ βˆƒ k, ΞΈ = (2 * ↑k + 1) * ↑π / 2", " 2 * I * ΞΈ = ↑π * I + ↑x * (2 * ↑π * I) ↔ ΞΈ = (2 * ↑x +...
import Mathlib.Analysis.InnerProductSpace.Basic import Mathlib.Analysis.NormedSpace.Banach import Mathlib.LinearAlgebra.SesquilinearForm #align_import analysis.inner_product_space.symmetric from "leanprover-community/mathlib"@"3f655f5297b030a87d641ad4e825af8d9679eb0b" open RCLike open ComplexConjugate variable ...
Mathlib/Analysis/InnerProductSpace/Symmetric.lean
97
110
theorem IsSymmetric.continuous [CompleteSpace E] {T : E β†’β‚—[π•œ] E} (hT : IsSymmetric T) : Continuous T := by
-- We prove it by using the closed graph theorem refine T.continuous_of_seq_closed_graph fun u x y hu hTu => ?_ rw [← sub_eq_zero, ← @inner_self_eq_zero π•œ] have hlhs : βˆ€ k : β„•, βŸͺT (u k) - T x, y - T x⟫ = βŸͺu k - x, T (y - T x)⟫ := by intro k rw [← T.map_sub, hT] refine tendsto_nhds_unique ((hTu.sub_c...
[ " (starRingEnd π•œ) βŸͺT x, y⟫_π•œ = βŸͺT y, x⟫_π•œ", " (T + S).IsSymmetric", " βŸͺ(T + S) x, y⟫_π•œ = βŸͺx, (T + S) y⟫_π•œ", " βŸͺx, T y + S y⟫_π•œ = βŸͺx, (T + S) y⟫_π•œ", " Continuous ⇑T", " y = T x", " βŸͺy - T x, y - T x⟫_π•œ = 0", " βˆ€ (k : β„•), βŸͺT (u k) - T x, y - T x⟫_π•œ = βŸͺu k - x, T (y - T x)⟫_π•œ", " βŸͺT (u k) - T...
[ " (starRingEnd π•œ) βŸͺT x, y⟫_π•œ = βŸͺT y, x⟫_π•œ", " (T + S).IsSymmetric", " βŸͺ(T + S) x, y⟫_π•œ = βŸͺx, (T + S) y⟫_π•œ", " βŸͺx, T y + S y⟫_π•œ = βŸͺx, (T + S) y⟫_π•œ" ]
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
123
139
theorem toMatrix_injective [DecidableEq n] [MonoidWithZero Ξ±] [Nontrivial Ξ±] : Function.Injective (@toMatrix m n Ξ± _ _ _) := by
classical intro f g refine not_imp_not.1 ?_ simp only [Matrix.ext_iff.symm, toMatrix_apply, PEquiv.ext_iff, not_forall, exists_imp] intro i hi use i cases' hf : f i with fi Β· cases' hg : g i with gi -- Porting note: was `cc` Β· rw [hf, hg] at hi exact (hi rfl).elim ...
[ " (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.Algebra.Lie.Subalgebra import Mathlib.RingTheory.Noetherian import Mathlib.RingTheory.Artinian #align_import algebra.lie.submodule from "leanprover-community/mathlib"@"9822b65bfc4ac74537d77ae318d27df1df662471" universe u v w w₁ wβ‚‚ section LieSubmodule variable (R : Type u) (L : Type v) (M : Type ...
Mathlib/Algebra/Lie/Submodule.lean
132
133
theorem coe_toSubmodule_mk (p : Submodule R M) (h) : (({ p with lie_mem := h } : LieSubmodule R L M) : Submodule R M) = p := by
cases p; rfl
[ " N = O", " { toSubmodule := toSubmodule✝, lie_mem := lie_mem✝ } = O", " { toSubmodule := toSubmodule✝¹, lie_mem := lie_mem✝¹ } = { toSubmodule := toSubmodule✝, lie_mem := lie_mem✝ }", " toSubmodule✝¹ = toSubmodule✝", " ⁅x, m⁆ ∈ __src✝.carrier", " ⁅x, 0⁆ ∈ __src✝.carrier", " ↑{ toSubmodule := p, lie_mem...
[ " N = O", " { toSubmodule := toSubmodule✝, lie_mem := lie_mem✝ } = O", " { toSubmodule := toSubmodule✝¹, lie_mem := lie_mem✝¹ } = { toSubmodule := toSubmodule✝, lie_mem := lie_mem✝ }", " toSubmodule✝¹ = toSubmodule✝", " ⁅x, m⁆ ∈ __src✝.carrier", " ⁅x, 0⁆ ∈ __src✝.carrier" ]
import Mathlib.ModelTheory.Substructures #align_import model_theory.finitely_generated from "leanprover-community/mathlib"@"0602c59878ff3d5f71dea69c2d32ccf2e93e5398" open FirstOrder Set namespace FirstOrder namespace Language open Structure variable {L : Language} {M : Type*} [L.Structure M] namespace Substru...
Mathlib/ModelTheory/FinitelyGenerated.lean
111
113
theorem FG.cg {N : L.Substructure M} (h : N.FG) : N.CG := by
obtain ⟨s, hf, rfl⟩ := fg_def.1 h exact ⟨s, hf.countable, rfl⟩
[ " (βˆƒ S, S.Finite ∧ (closure L).toFun S = N) β†’ N.FG", " ((closure L).toFun t').FG", " ((closure L).toFun ↑t).FG", " N.FG ↔ βˆƒ n s, (closure L).toFun (range s) = N", " (βˆƒ S, S.Finite ∧ (closure L).toFun S = N) ↔ βˆƒ n s, (closure L).toFun (range s) = N", " (βˆƒ S, S.Finite ∧ (closure L).toFun S = N) β†’ βˆƒ n s, (cl...
[ " (βˆƒ S, S.Finite ∧ (closure L).toFun S = N) β†’ N.FG", " ((closure L).toFun t').FG", " ((closure L).toFun ↑t).FG", " N.FG ↔ βˆƒ n s, (closure L).toFun (range s) = N", " (βˆƒ S, S.Finite ∧ (closure L).toFun S = N) ↔ βˆƒ n s, (closure L).toFun (range s) = N", " (βˆƒ S, S.Finite ∧ (closure L).toFun S = N) β†’ βˆƒ n s, (cl...
import Mathlib.NumberTheory.Cyclotomic.Discriminant import Mathlib.RingTheory.Polynomial.Eisenstein.IsIntegral import Mathlib.RingTheory.Ideal.Norm #align_import number_theory.cyclotomic.rat from "leanprover-community/mathlib"@"b353176c24d96c23f0ce1cc63efc3f55019702d9" universe u open Algebra IsCyclotomicExtensio...
Mathlib/NumberTheory/Cyclotomic/Rat.lean
55
59
theorem discr_prime_pow' [IsCyclotomicExtension {p ^ k} β„š K] (hΞΆ : IsPrimitiveRoot ΞΆ ↑(p ^ k)) : discr β„š (hΞΆ.subOnePowerBasis β„š).basis = (-1) ^ ((p ^ k : β„•).totient / 2) * p ^ ((p : β„•) ^ (k - 1) * ((p - 1) * k - 1)) := by
rw [← discr_prime_pow hΞΆ (cyclotomic.irreducible_rat (p ^ k).pos)] exact hΞΆ.discr_zeta_eq_discr_zeta_sub_one.symm
[ " Algebra.discr β„š ⇑(IsPrimitiveRoot.subOnePowerBasis β„š hΞΆ).basis =\n (-1) ^ (Ο† (↑p ^ (k + 1)) / 2) * ↑↑p ^ (↑p ^ k * ((↑p - 1) * (k + 1) - 1))", " Algebra.discr β„š ⇑(IsPrimitiveRoot.subOnePowerBasis β„š hΞΆ).basis =\n Algebra.discr β„š ⇑(IsPrimitiveRoot.powerBasis β„š hΞΆ).basis", " Algebra.discr β„š ⇑(IsPrimitiveRo...
[ " Algebra.discr β„š ⇑(IsPrimitiveRoot.subOnePowerBasis β„š hΞΆ).basis =\n (-1) ^ (Ο† (↑p ^ (k + 1)) / 2) * ↑↑p ^ (↑p ^ k * ((↑p - 1) * (k + 1) - 1))", " Algebra.discr β„š ⇑(IsPrimitiveRoot.subOnePowerBasis β„š hΞΆ).basis =\n Algebra.discr β„š ⇑(IsPrimitiveRoot.powerBasis β„š hΞΆ).basis", " Algebra.discr β„š ⇑(IsPrimitiveRo...
import Mathlib.Data.Countable.Basic import Mathlib.Data.Fin.VecNotation import Mathlib.Order.Disjointed import Mathlib.MeasureTheory.OuterMeasure.Defs #align_import measure_theory.measure.outer_measure from "leanprover-community/mathlib"@"343e80208d29d2d15f8050b929aa50fe4ce71b55" noncomputable section open Set F...
Mathlib/MeasureTheory/OuterMeasure/Basic.lean
63
69
theorem measure_iUnion_le [Countable ΞΉ] (s : ΞΉ β†’ Set Ξ±) : ΞΌ (⋃ i, s i) ≀ βˆ‘' i, ΞΌ (s i) := by
refine rel_iSup_tsum ΞΌ measure_empty (Β· ≀ Β·) (fun t ↦ ?_) _ calc ΞΌ (⋃ i, t i) = ΞΌ (⋃ i, disjointed t i) := by rw [iUnion_disjointed] _ ≀ βˆ‘' i, ΞΌ (disjointed t i) := OuterMeasureClass.measure_iUnion_nat_le _ _ (disjoint_disjointed _) _ ≀ βˆ‘' i, ΞΌ (t i) := by gcongr; apply disjointed_subset
[ " ΞΌ (⋃ i, s i) ≀ βˆ‘' (i : ΞΉ), ΞΌ (s i)", " (fun x x_1 => x ≀ x_1) (ΞΌ (⨆ i, t i)) (βˆ‘' (i : β„•), ΞΌ (t i))", " ΞΌ (⋃ i, t i) = ΞΌ (⋃ i, disjointed t i)", " βˆ‘' (i : β„•), ΞΌ (disjointed t i) ≀ βˆ‘' (i : β„•), ΞΌ (t i)", " disjointed t a✝ βŠ† t a✝" ]
[]
import Mathlib.Algebra.Category.GroupCat.EquivalenceGroupAddGroup import Mathlib.GroupTheory.QuotientGroup #align_import algebra.category.Group.epi_mono from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a" noncomputable section open scoped Pointwise universe u v namespace MonoidHom o...
Mathlib/Algebra/Category/GroupCat/EpiMono.lean
35
36
theorem ker_eq_bot_of_cancel {f : A β†’* B} (h : βˆ€ u v : f.ker β†’* A, f.comp u = f.comp v β†’ u = v) : f.ker = βŠ₯ := by
simpa using _root_.congr_arg range (h f.ker.subtype 1 (by aesop_cat))
[ " f.ker = βŠ₯", " f.comp f.ker.subtype = f.comp 1" ]
[]
import Mathlib.Analysis.NormedSpace.AddTorsorBases #align_import analysis.convex.intrinsic from "leanprover-community/mathlib"@"f0c8bf9245297a541f468be517f1bde6195105e9" open AffineSubspace Set open scoped Pointwise variable {π•œ V W Q P : Type*} section AddTorsor variable (π•œ) [Ring π•œ] [AddCommGroup V] [Modu...
Mathlib/Analysis/Convex/Intrinsic.lean
142
143
theorem intrinsicFrontier_singleton (x : P) : intrinsicFrontier π•œ ({x} : Set P) = βˆ… := by
rw [intrinsicFrontier, preimage_coe_affineSpan_singleton, frontier_univ, image_empty]
[ " intrinsicInterior π•œ βˆ… = βˆ…", " intrinsicFrontier π•œ βˆ… = βˆ…", " intrinsicClosure π•œ βˆ… = βˆ…", " (intrinsicClosure π•œ s).Nonempty β†’ s.Nonempty", " intrinsicClosure π•œ s β‰  βˆ… β†’ s β‰  βˆ…", " False", " intrinsicInterior π•œ {x} = {x}", " intrinsicFrontier π•œ {x} = βˆ…" ]
[ " intrinsicInterior π•œ βˆ… = βˆ…", " intrinsicFrontier π•œ βˆ… = βˆ…", " intrinsicClosure π•œ βˆ… = βˆ…", " (intrinsicClosure π•œ s).Nonempty β†’ s.Nonempty", " intrinsicClosure π•œ s β‰  βˆ… β†’ s β‰  βˆ…", " False", " intrinsicInterior π•œ {x} = {x}" ]
import Mathlib.Analysis.Calculus.Deriv.Basic import Mathlib.Analysis.Calculus.FDeriv.Add #align_import analysis.calculus.deriv.add from "leanprover-community/mathlib"@"3bce8d800a6f2b8f63fe1e588fd76a9ff4adcebe" universe u v w open scoped Classical open Topology Filter ENNReal open Filter Asymptotics Set variable...
Mathlib/Analysis/Calculus/Deriv/Add.lean
97
99
theorem derivWithin_add_const (hxs : UniqueDiffWithinAt π•œ s x) (c : F) : derivWithin (fun y => f y + c) s x = derivWithin f s x := by
simp only [derivWithin, fderivWithin_add_const hxs]
[ " HasDerivAtFilter (fun y => f y + g y) (f' + g') x L", " HasStrictDerivAt (fun y => f y + g y) (f' + g') x", " derivWithin (fun y => f y + c) s x = derivWithin f s x" ]
[ " HasDerivAtFilter (fun y => f y + g y) (f' + g') x L", " HasStrictDerivAt (fun y => f y + g y) (f' + g') x" ]
import Mathlib.Algebra.BigOperators.Pi import Mathlib.Algebra.BigOperators.Ring import Mathlib.Algebra.Order.BigOperators.Ring.Finset import Mathlib.Algebra.BigOperators.Fin import Mathlib.Algebra.Group.Submonoid.Membership import Mathlib.Data.Finsupp.Fin import Mathlib.Data.Finsupp.Indicator #align_import algebra.bi...
Mathlib/Algebra/BigOperators/Finsupp.lean
54
57
theorem prod_of_support_subset (f : Ξ± β†’β‚€ M) {s : Finset Ξ±} (hs : f.support βŠ† s) (g : Ξ± β†’ M β†’ N) (h : βˆ€ i ∈ s, g i 0 = 1) : f.prod g = ∏ x ∈ s, g x (f x) := by
refine Finset.prod_subset hs fun x hxs hx => h x hxs β–Έ (congr_arg (g x) ?_) exact not_mem_support_iff.1 hx
[ " f.prod g = ∏ x ∈ s, g x (f x)", " f x = 0" ]
[]
import Mathlib.Data.List.Sublists import Mathlib.Data.Multiset.Bind #align_import data.multiset.powerset from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853" namespace Multiset open List variable {Ξ± : Type*} -- Porting note (#11215): TODO: Write a more efficient version def powerset...
Mathlib/Data/Multiset/Powerset.lean
55
57
theorem powersetAux'_cons (a : Ξ±) (l : List Ξ±) : powersetAux' (a :: l) = powersetAux' l ++ List.map (cons a) (powersetAux' l) := by
simp only [powersetAux', sublists'_cons, map_append, List.map_map, append_cancel_left_eq]; rfl
[ " βˆ€ (a : List Ξ±), ⟦a⟧ ∈ powersetAux l ↔ ⟦a⟧ ≀ ↑l", " powersetAux l ~ powersetAux' l", " List.map ofList l.sublists ~ powersetAux' l", " powersetAux' (a :: l) = powersetAux' l ++ List.map (cons a) (powersetAux' l)", " List.map (ofList ∘ List.cons a) l.sublists' = List.map (cons a ∘ ofList) l.sublists'" ]
[ " βˆ€ (a : List Ξ±), ⟦a⟧ ∈ powersetAux l ↔ ⟦a⟧ ≀ ↑l", " powersetAux l ~ powersetAux' l", " List.map ofList l.sublists ~ powersetAux' l" ]
import Mathlib.Analysis.SpecialFunctions.Trigonometric.Bounds #align_import data.real.pi.bounds from "leanprover-community/mathlib"@"402f8982dddc1864bd703da2d6e2ee304a866973" -- Porting note: needed to add a lot of type ascriptions for lean to interpret numbers as reals. open scoped Real namespace Real theorem ...
Mathlib/Data/Real/Pi/Bounds.lean
128
136
theorem pi_upper_bound_start (n : β„•) {a} (h : (2 : ℝ) - ((a - 1 / (4 : ℝ) ^ n) / (2 : ℝ) ^ (n + 1)) ^ 2 ≀ sqrtTwoAddSeries ((0 : β„•) / (1 : β„•)) n) (hβ‚‚ : (1 : ℝ) / (4 : ℝ) ^ n ≀ a) : Ο€ < a := by
refine lt_of_lt_of_le (pi_lt_sqrtTwoAddSeries n) ?_ rw [← le_sub_iff_add_le, ← le_div_iff', sqrt_le_left, sub_le_comm] Β· rwa [Nat.cast_zero, zero_div] at h Β· exact div_nonneg (sub_nonneg.2 hβ‚‚) (pow_nonneg (le_of_lt zero_lt_two) _) Β· exact pow_pos zero_lt_two _
[ " 2 ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) < Ο€", " √(2 - sqrtTwoAddSeries 0 n) / 2 * 2 ^ (n + 2) < Ο€", " 0 < 2 ^ (n + 2)", " (Ο€ / 2 ^ (n + 2)).sin < Ο€ / 2 ^ (n + 2)", " 0 < Ο€ / 2 ^ (n + 2)", " 0 < 2", " 2 ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) = √(2 - sqrtTwoAddSeries 0 n) / 2 * 2 ^ (n + 2)", " 2 β‰  ...
[ " 2 ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) < Ο€", " √(2 - sqrtTwoAddSeries 0 n) / 2 * 2 ^ (n + 2) < Ο€", " 0 < 2 ^ (n + 2)", " (Ο€ / 2 ^ (n + 2)).sin < Ο€ / 2 ^ (n + 2)", " 0 < Ο€ / 2 ^ (n + 2)", " 0 < 2", " 2 ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) = √(2 - sqrtTwoAddSeries 0 n) / 2 * 2 ^ (n + 2)", " 2 β‰  ...
import Mathlib.LinearAlgebra.Dimension.Finrank import Mathlib.LinearAlgebra.InvariantBasisNumber #align_import linear_algebra.dimension from "leanprover-community/mathlib"@"47a5f8186becdbc826190ced4312f8199f9db6a5" noncomputable section universe u v w w' variable {R : Type u} {M : Type v} [Ring R] [AddCommGroup...
Mathlib/LinearAlgebra/Dimension/StrongRankCondition.lean
214
220
theorem linearIndependent_le_span' {ΞΉ : Type*} (v : ΞΉ β†’ M) (i : LinearIndependent R v) (w : Set M) [Fintype w] (s : range v ≀ span R w) : #ΞΉ ≀ Fintype.card w := by
haveI : Finite ΞΉ := i.finite_of_le_span_finite v w s letI := Fintype.ofFinite ΞΉ rw [Cardinal.mk_fintype] simp only [Cardinal.natCast_le] exact linearIndependent_le_span_aux' v i w s
[ " Fintype.card ΞΉ ≀ Fintype.card ↑w", " (ΞΉ β†’β‚€ R) β†’β‚—[R] ↑w β†’β‚€ R", " ΞΉ β†’ ↑w β†’β‚€ R", " Injective ⇑(Finsupp.total ΞΉ (↑w β†’β‚€ R) R fun i => Span.repr R w ⟨v i, β‹―βŸ©)", " f = g", " t.card ≀ Fintype.card ↑w", " #ΞΉ ≀ ↑(Fintype.card ↑w)", " ↑(Fintype.card ΞΉ) ≀ ↑(Fintype.card ↑w)" ]
[ " Fintype.card ΞΉ ≀ Fintype.card ↑w", " (ΞΉ β†’β‚€ R) β†’β‚—[R] ↑w β†’β‚€ R", " ΞΉ β†’ ↑w β†’β‚€ R", " Injective ⇑(Finsupp.total ΞΉ (↑w β†’β‚€ R) R fun i => Span.repr R w ⟨v i, β‹―βŸ©)", " f = g", " t.card ≀ Fintype.card ↑w" ]
import Mathlib.MeasureTheory.Function.SimpleFuncDenseLp #align_import measure_theory.integral.set_to_l1 from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" noncomputable section open scoped Classical Topology NNReal ENNReal MeasureTheory Pointwise open Set Filter TopologicalSpace ENNR...
Mathlib/MeasureTheory/Integral/SetToL1.lean
105
109
theorem add (hT : FinMeasAdditive ΞΌ T) (hT' : FinMeasAdditive ΞΌ T') : FinMeasAdditive ΞΌ (T + T') := by
intro s t hs ht hΞΌs hΞΌt hst simp only [hT s t hs ht hΞΌs hΞΌt hst, hT' s t hs ht hΞΌs hΞΌt hst, Pi.add_apply] abel
[ " 0 (s βˆͺ t) = 0 s + 0 t", " FinMeasAdditive ΞΌ (T + T')", " (T + T') (s βˆͺ t) = (T + T') s + (T + T') t", " T s + T t + (T' s + T' t) = T s + T' s + (T t + T' t)" ]
[ " 0 (s βˆͺ t) = 0 s + 0 t" ]
import Mathlib.Analysis.NormedSpace.Star.GelfandDuality import Mathlib.Topology.Algebra.StarSubalgebra #align_import analysis.normed_space.star.continuous_functional_calculus from "leanprover-community/mathlib"@"31c24aa72e7b3e5ed97a8412470e904f82b81004" open scoped Pointwise ENNReal NNReal ComplexOrder open Weak...
Mathlib/Analysis/NormedSpace/Star/ContinuousFunctionalCalculus.lean
81
94
theorem spectrum_star_mul_self_of_isStarNormal : spectrum β„‚ (star a * a) βŠ† Set.Icc (0 : β„‚) β€–star a * aβ€– := by
-- this instance should be found automatically, but without providing it Lean goes on a wild -- goose chase when trying to apply `spectrum.gelfandTransform_eq`. --letI := elementalStarAlgebra.Complex.normedAlgebra a rcases subsingleton_or_nontrivial A with ⟨⟩ · simp only [spectrum.of_subsingleton, Set.empty_...
[ " spectrum β„‚ (star a * a) βŠ† Set.Icc 0 ↑‖star a * aβ€–", " spectrum β„‚ (star a' * a') βŠ† Set.Icc 0 ↑‖star a * aβ€–", " Set.range ⇑((gelfandTransform β„‚ β†₯(elementalStarAlgebra β„‚ a)) (star a' * a')) βŠ† Set.Icc 0 ↑‖star a * aβ€–", " ((gelfandTransform β„‚ β†₯(elementalStarAlgebra β„‚ a)) (star a' * a')) Ο† ∈ Set.Icc 0 ↑‖star a * ...
[]
import Mathlib.Analysis.Analytic.Basic import Mathlib.Combinatorics.Enumerative.Composition #align_import analysis.analytic.composition from "leanprover-community/mathlib"@"ce11c3c2a285bbe6937e26d9792fda4e51f3fe1a" noncomputable section variable {π•œ : Type*} {E F G H : Type*} open Filter List open scoped Topol...
Mathlib/Analysis/Analytic/Composition.lean
166
169
theorem compContinuousLinearMap_applyComposition {n : β„•} (p : FormalMultilinearSeries π•œ F G) (f : E β†’L[π•œ] F) (c : Composition n) (v : Fin n β†’ E) : (p.compContinuousLinearMap f).applyComposition c v = p.applyComposition c (f ∘ v) := by
simp (config := {unfoldPartialApp := true}) [applyComposition]; rfl
[ " p.applyComposition (Composition.ones n) = fun v i => (p 1) fun x => v (Fin.castLE β‹― i)", " p.applyComposition (Composition.ones n) v i = (p 1) fun x => v (Fin.castLE β‹― i)", " βˆ€ (i_1 : β„•) (him : i_1 < (Composition.ones n).blocksFun i),\n i_1 < 1 β†’ (v ∘ ⇑((Composition.ones n).embedding i)) ⟨i_1, him⟩ = v (Fi...
[ " p.applyComposition (Composition.ones n) = fun v i => (p 1) fun x => v (Fin.castLE β‹― i)", " p.applyComposition (Composition.ones n) v i = (p 1) fun x => v (Fin.castLE β‹― i)", " βˆ€ (i_1 : β„•) (him : i_1 < (Composition.ones n).blocksFun i),\n i_1 < 1 β†’ (v ∘ ⇑((Composition.ones n).embedding i)) ⟨i_1, him⟩ = v (Fi...
import Mathlib.Algebra.Polynomial.Degree.Definitions import Mathlib.Algebra.Polynomial.Eval import Mathlib.Algebra.Polynomial.Monic import Mathlib.Algebra.Polynomial.RingDivision import Mathlib.Tactic.Abel #align_import ring_theory.polynomial.pochhammer from "leanprover-community/mathlib"@"53b216bcc1146df1c4a0a868778...
Mathlib/RingTheory/Polynomial/Pochhammer.lean
295
295
theorem descPochhammer_zero_eval_zero : (descPochhammer R 0).eval 0 = 1 := by
simp
[ " descPochhammer R 1 = X", " descPochhammer R (n + 1) = X * (descPochhammer R n).comp (X - 1)", " (descPochhammer R n).Monic", " (descPochhammer R 0).Monic", " (descPochhammer R (n + 1)).Monic", " map f (descPochhammer R n) = descPochhammer T n", " map f (descPochhammer R 0) = descPochhammer T 0", " m...
[ " descPochhammer R 1 = X", " descPochhammer R (n + 1) = X * (descPochhammer R n).comp (X - 1)", " (descPochhammer R n).Monic", " (descPochhammer R 0).Monic", " (descPochhammer R (n + 1)).Monic", " map f (descPochhammer R n) = descPochhammer T n", " map f (descPochhammer R 0) = descPochhammer T 0", " m...
import Mathlib.Algebra.BigOperators.Ring import Mathlib.Data.Fintype.Basic import Mathlib.Data.Int.GCD import Mathlib.RingTheory.Coprime.Basic #align_import ring_theory.coprime.lemmas from "leanprover-community/mathlib"@"509de852e1de55e1efa8eacfa11df0823f26f226" universe u v section IsCoprime variable {R : Type ...
Mathlib/RingTheory/Coprime/Lemmas.lean
79
80
theorem IsCoprime.prod_right_iff : IsCoprime x (∏ i ∈ t, s i) ↔ βˆ€ i ∈ t, IsCoprime x (s i) := by
simpa only [isCoprime_comm] using IsCoprime.prod_left_iff (R := R)
[ " IsCoprime m n ↔ m.gcd n = 1", " IsCoprime m n β†’ m.gcd n = 1", " m.gcd n = 1", " 1 = m * a + n * b", " m.gcd n = 1 β†’ IsCoprime m n", " m.gcdA n * m + m.gcdB n * n = 1 β†’ βˆƒ a b, a * m + b * n = 1", " βˆƒ a b, a * m + b * n = 1", " IsCoprime ↑m ↑n ↔ m.Coprime n", " IsCoprime ↑a ↑b", " IsCoprime ↑↑a ↑↑...
[ " IsCoprime m n ↔ m.gcd n = 1", " IsCoprime m n β†’ m.gcd n = 1", " m.gcd n = 1", " 1 = m * a + n * b", " m.gcd n = 1 β†’ IsCoprime m n", " m.gcdA n * m + m.gcdB n * n = 1 β†’ βˆƒ a b, a * m + b * n = 1", " βˆƒ a b, a * m + b * n = 1", " IsCoprime ↑m ↑n ↔ m.Coprime n", " IsCoprime ↑a ↑b", " IsCoprime ↑↑a ↑↑...
import Mathlib.FieldTheory.RatFunc.Defs import Mathlib.RingTheory.EuclideanDomain import Mathlib.RingTheory.Localization.FractionRing import Mathlib.RingTheory.Polynomial.Content #align_import field_theory.ratfunc from "leanprover-community/mathlib"@"bf9bbbcf0c1c1ead18280b0d010e417b10abb1b6" universe u v noncompu...
Mathlib/FieldTheory/RatFunc/Basic.lean
235
239
theorem mk_smul (c : R) (p q : K[X]) : RatFunc.mk (c β€’ p) q = c β€’ RatFunc.mk p q := by
by_cases hq : q = 0 Β· rw [hq, mk_zero, mk_zero, ← ofFractionRing_smul, smul_zero] Β· rw [mk_eq_localization_mk _ hq, mk_eq_localization_mk _ hq, ← Localization.smul_mk, ← ofFractionRing_smul]
[ " { toFractionRing := 0 } = 0", " { toFractionRing := p + q } = { toFractionRing := p } + { toFractionRing := q }", " { toFractionRing := p - q } = { toFractionRing := p } - { toFractionRing := q }", " { toFractionRing := -p } = -{ toFractionRing := p }", " { toFractionRing := 1 } = 1", " { toFractionRing...
[ " { toFractionRing := 0 } = 0", " { toFractionRing := p + q } = { toFractionRing := p } + { toFractionRing := q }", " { toFractionRing := p - q } = { toFractionRing := p } - { toFractionRing := q }", " { toFractionRing := -p } = -{ toFractionRing := p }", " { toFractionRing := 1 } = 1", " { toFractionRing...
import Mathlib.SetTheory.Game.Basic import Mathlib.SetTheory.Ordinal.NaturalOps #align_import set_theory.game.ordinal from "leanprover-community/mathlib"@"b90e72c7eebbe8de7c8293a80208ea2ba135c834" universe u open SetTheory PGame open scoped NaturalOps PGame namespace Ordinal noncomputable def toPGame : Ordin...
Mathlib/SetTheory/Game/Ordinal.lean
96
97
theorem toPGame_moveLeft {o : Ordinal} (i) : o.toPGame.moveLeft (toLeftMovesToPGame i) = i.val.toPGame := by
simp
[ " let_fun this := β‹―;\n o.toPGame = mk (Quotient.out o).Ξ± PEmpty.{u_1 + 1} (fun x => (typein (fun x x_1 => x < x_1) x).toPGame) PEmpty.elim", " o.toPGame.LeftMoves = (Quotient.out o).Ξ±", " o.toPGame.RightMoves = PEmpty.{u_1 + 1}", " IsEmpty (toPGame 0).LeftMoves", " IsEmpty (Quotient.out 0).Ξ±", " IsEmpty ...
[ " let_fun this := β‹―;\n o.toPGame = mk (Quotient.out o).Ξ± PEmpty.{u_1 + 1} (fun x => (typein (fun x x_1 => x < x_1) x).toPGame) PEmpty.elim", " o.toPGame.LeftMoves = (Quotient.out o).Ξ±", " o.toPGame.RightMoves = PEmpty.{u_1 + 1}", " IsEmpty (toPGame 0).LeftMoves", " IsEmpty (Quotient.out 0).Ξ±", " IsEmpty ...
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
121
130
theorem comp_hasFDerivWithinAt_iff {f : G β†’ E} {s : Set G} {x : G} {f' : G β†’L[π•œ] E} : HasFDerivWithinAt (iso ∘ f) ((iso : E β†’L[π•œ] F).comp f') s x ↔ HasFDerivWithinAt f f' s x := by
refine ⟨fun H => ?_, fun H => iso.hasFDerivAt.comp_hasFDerivWithinAt x H⟩ have A : f = iso.symm ∘ iso ∘ f := by rw [← Function.comp.assoc, iso.symm_comp_self] rfl have B : f' = (iso.symm : F β†’L[π•œ] E).comp ((iso : E β†’L[π•œ] F).comp f') := by rw [← ContinuousLinearMap.comp_assoc, iso.coe_symm_comp_coe,...
[ " DifferentiableWithinAt π•œ (⇑iso ∘ f) s x ↔ DifferentiableWithinAt π•œ f s x", " DifferentiableWithinAt π•œ f s x", " DifferentiableAt π•œ (⇑iso ∘ f) x ↔ DifferentiableAt π•œ f x", " DifferentiableOn π•œ (⇑iso ∘ f) s ↔ DifferentiableOn π•œ f s", " (βˆ€ x ∈ s, DifferentiableWithinAt π•œ (⇑iso ∘ f) s x) ↔ βˆ€ x ∈ s, Di...
[ " DifferentiableWithinAt π•œ (⇑iso ∘ f) s x ↔ DifferentiableWithinAt π•œ f s x", " DifferentiableWithinAt π•œ f s x", " DifferentiableAt π•œ (⇑iso ∘ f) x ↔ DifferentiableAt π•œ f x", " DifferentiableOn π•œ (⇑iso ∘ f) s ↔ DifferentiableOn π•œ f s", " (βˆ€ x ∈ s, DifferentiableWithinAt π•œ (⇑iso ∘ f) s x) ↔ βˆ€ x ∈ s, Di...
import Mathlib.Data.Set.Equitable import Mathlib.Logic.Equiv.Fin import Mathlib.Order.Partition.Finpartition #align_import order.partition.equipartition from "leanprover-community/mathlib"@"b363547b3113d350d053abdf2884e9850a56b205" open Finset Fintype namespace Finpartition variable {Ξ± : Type*} [DecidableEq Ξ±] ...
Mathlib/Order/Partition/Equipartition.lean
114
134
theorem IsEquipartition.exists_partsEquiv (hP : P.IsEquipartition) : βˆƒ f : P.parts ≃ Fin P.parts.card, βˆ€ t, t.1.card = s.card / P.parts.card + 1 ↔ f t < s.card % P.parts.card := by
let el := (P.parts.filter fun p ↦ p.card = s.card / P.parts.card + 1).equivFin let es := (P.parts.filter fun p ↦ p.card = s.card / P.parts.card).equivFin simp_rw [mem_filter, hP.card_large_parts_eq_mod] at el simp_rw [mem_filter, hP.card_small_parts_eq_mod] at es let sneg : { x // x ∈ P.parts ∧ Β¬x.card = s.c...
[ " P.IsEquipartition ↔ βˆ€ a ∈ P.parts, a.card = s.card / P.parts.card ∨ a.card = s.card / P.parts.card + 1", " t.card = s.card / P.parts.card ↔ t.card β‰  s.card / P.parts.card + 1", " Β¬(t.card = s.card / P.parts.card ∧ t.card = s.card / P.parts.card + 1)", " False", " s.card / P.parts.card ≀ t.card", " (βˆ‘ i ...
[ " P.IsEquipartition ↔ βˆ€ a ∈ P.parts, a.card = s.card / P.parts.card ∨ a.card = s.card / P.parts.card + 1", " t.card = s.card / P.parts.card ↔ t.card β‰  s.card / P.parts.card + 1", " Β¬(t.card = s.card / P.parts.card ∧ t.card = s.card / P.parts.card + 1)", " False", " s.card / P.parts.card ≀ t.card", " (βˆ‘ i ...
import Mathlib.Data.Set.Lattice import Mathlib.Order.Directed #align_import data.set.Union_lift from "leanprover-community/mathlib"@"5a4ea8453f128345f73cc656e80a49de2a54f481" variable {Ξ± : Type*} {ΞΉ Ξ² : Sort _} namespace Set section UnionLift @[nolint unusedArguments] noncomputable def iUnionLift (S : ΞΉ β†’ Set...
Mathlib/Data/Set/UnionLift.lean
107
120
theorem iUnionLift_unary (u : T β†’ T) (ui : βˆ€ i, S i β†’ S i) (hui : βˆ€ (i) (x : S i), u (Set.inclusion (show S i βŠ† T from hT'.symm β–Έ Set.subset_iUnion S i) x) = Set.inclusion (show S i βŠ† T from hT'.symm β–Έ Set.subset_iUnion S i) (ui i x)) (uΞ² : Ξ² β†’ Ξ²) (h : βˆ€ (i) (x : S i), f i (ui i x) = uΞ² ...
subst hT' cases' Set.mem_iUnion.1 x.prop with i hi rw [iUnionLift_of_mem x hi, ← h i] have : x = Set.inclusion (Set.subset_iUnion S i) ⟨x, hi⟩ := by cases x rfl conv_lhs => rw [this, hui, iUnionLift_inclusion]
[ " iUnionLift S f hf T hT x = f i βŸ¨β†‘x, hx⟩", " iUnionLift S f hf T hT ⟨x, hx✝⟩ = f i βŸ¨β†‘βŸ¨x, hx✝⟩, hx⟩", " iUnionLift S f hf T hT ⁻¹' t = inclusion hT ⁻¹' ⋃ i, inclusion β‹― '' (f i ⁻¹' t)", " x ∈ iUnionLift S f hf T hT ⁻¹' t ↔ x ∈ inclusion hT ⁻¹' ⋃ i, inclusion β‹― '' (f i ⁻¹' t)", " iUnionLift S f hf T hT x ∈ t...
[ " iUnionLift S f hf T hT x = f i βŸ¨β†‘x, hx⟩", " iUnionLift S f hf T hT ⟨x, hx✝⟩ = f i βŸ¨β†‘βŸ¨x, hx✝⟩, hx⟩", " iUnionLift S f hf T hT ⁻¹' t = inclusion hT ⁻¹' ⋃ i, inclusion β‹― '' (f i ⁻¹' t)", " x ∈ iUnionLift S f hf T hT ⁻¹' t ↔ x ∈ inclusion hT ⁻¹' ⋃ i, inclusion β‹― '' (f i ⁻¹' t)", " iUnionLift S f hf T hT x ∈ t...
import Mathlib.Algebra.Associated import Mathlib.Algebra.BigOperators.Group.Finset import Mathlib.Algebra.SMulWithZero import Mathlib.Data.Nat.PartENat import Mathlib.Tactic.Linarith #align_import ring_theory.multiplicity from "leanprover-community/mathlib"@"e8638a0fcaf73e4500469f368ef9494e495099b3" variable {Ξ± Ξ²...
Mathlib/RingTheory/Multiplicity.lean
99
107
theorem pow_dvd_of_le_multiplicity {a b : Ξ±} {k : β„•} : (k : PartENat) ≀ multiplicity a b β†’ a ^ k ∣ b := by
rw [← PartENat.some_eq_natCast] exact Nat.casesOn k (fun _ => by rw [_root_.pow_zero] exact one_dvd _) fun k ⟨_, hβ‚‚βŸ© => by_contradiction fun hk => Nat.find_min _ (lt_of_succ_le (hβ‚‚ ⟨k, hk⟩)) hk
[ " multiplicity ↑a ↑b = multiplicity a b", " (multiplicity ↑a ↑b).Dom ↔ (multiplicity a b).Dom", " (βˆƒ n, ¬↑a ^ (n + 1) ∣ ↑b) ↔ βˆƒ n, Β¬a ^ (n + 1) ∣ b", " βˆ€ (h₁ : (multiplicity ↑a ↑b).Dom) (hβ‚‚ : (multiplicity a b).Dom),\n (multiplicity ↑a ↑b).get h₁ = (multiplicity a b).get hβ‚‚", " (multiplicity ↑a ↑b).get h...
[ " multiplicity ↑a ↑b = multiplicity a b", " (multiplicity ↑a ↑b).Dom ↔ (multiplicity a b).Dom", " (βˆƒ n, ¬↑a ^ (n + 1) ∣ ↑b) ↔ βˆƒ n, Β¬a ^ (n + 1) ∣ b", " βˆ€ (h₁ : (multiplicity ↑a ↑b).Dom) (hβ‚‚ : (multiplicity a b).Dom),\n (multiplicity ↑a ↑b).get h₁ = (multiplicity a b).get hβ‚‚", " (multiplicity ↑a ↑b).get h...
import Mathlib.Algebra.CharP.Invertible import Mathlib.Algebra.MvPolynomial.Variables import Mathlib.Algebra.MvPolynomial.CommRing import Mathlib.Algebra.MvPolynomial.Expand import Mathlib.Data.Fintype.BigOperators import Mathlib.Data.ZMod.Basic #align_import ring_theory.witt_vector.witt_polynomial from "leanprover-c...
Mathlib/RingTheory/WittVector/WittPolynomial.lean
136
137
theorem wittPolynomial_zero : wittPolynomial p R 0 = X 0 := by
simp only [wittPolynomial, X, sum_singleton, range_one, pow_zero, zero_add, tsub_self]
[ " wittPolynomial p R n = βˆ‘ i ∈ range (n + 1), C (↑p ^ i) * X i ^ p ^ (n - i)", " βˆ€ x ∈ range (n + 1), (monomial (single x (p ^ (n - x)))) (↑p ^ x) = C (↑p ^ x) * X x ^ p ^ (n - x)", " (monomial (single i (p ^ (n - i)))) (↑p ^ i) = C (↑p ^ i) * X i ^ p ^ (n - i)", " X i ^ 0 = 1", " (map f) (W_ R n) = W_ S n"...
[ " wittPolynomial p R n = βˆ‘ i ∈ range (n + 1), C (↑p ^ i) * X i ^ p ^ (n - i)", " βˆ€ x ∈ range (n + 1), (monomial (single x (p ^ (n - x)))) (↑p ^ x) = C (↑p ^ x) * X x ^ p ^ (n - x)", " (monomial (single i (p ^ (n - i)))) (↑p ^ i) = C (↑p ^ i) * X i ^ p ^ (n - i)", " X i ^ 0 = 1", " (map f) (W_ R n) = W_ S n"...
import Mathlib.Algebra.BigOperators.Fin import Mathlib.Data.Nat.Choose.Sum import Mathlib.Data.Nat.Factorial.BigOperators import Mathlib.Data.Fin.VecNotation import Mathlib.Data.Finset.Sym import Mathlib.Data.Finsupp.Multiset #align_import data.nat.choose.multinomial from "leanprover-community/mathlib"@"2738d2ca56cbc...
Mathlib/Data/Nat/Choose/Multinomial.lean
145
148
theorem multinomial_univ_two (a b : β„•) : multinomial Finset.univ ![a, b] = (a + b)! / (a ! * b !) := by
rw [multinomial, Fin.sum_univ_two, Fin.prod_univ_two, Matrix.cons_val_zero, Matrix.cons_val_one, Matrix.head_cons]
[ " multinomial βˆ… f = 1", " multinomial (cons a s ha) f = (f a + βˆ‘ i ∈ s, f i).choose (f a) * multinomial s f", " 0 < ∏ i ∈ cons a s ha, (f i)!", " multinomial (insert a s) f = (f a + βˆ‘ i ∈ s, f i).choose (f a) * multinomial s f", " multinomial {a} f = 1", " (f a + βˆ‘ i ∈ βˆ…, f i).choose (f a) * multinomial βˆ…...
[ " multinomial βˆ… f = 1", " multinomial (cons a s ha) f = (f a + βˆ‘ i ∈ s, f i).choose (f a) * multinomial s f", " 0 < ∏ i ∈ cons a s ha, (f i)!", " multinomial (insert a s) f = (f a + βˆ‘ i ∈ s, f i).choose (f a) * multinomial s f", " multinomial {a} f = 1", " (f a + βˆ‘ i ∈ βˆ…, f i).choose (f a) * multinomial βˆ…...
import Mathlib.Algebra.MonoidAlgebra.Basic import Mathlib.Data.Finset.Pointwise #align_import algebra.monoid_algebra.support from "leanprover-community/mathlib"@"16749fc4661828cba18cd0f4e3c5eb66a8e80598" open scoped Pointwise universe u₁ uβ‚‚ u₃ namespace MonoidAlgebra open Finset Finsupp variable {k : Type u₁} ...
Mathlib/Algebra/MonoidAlgebra/Support.lean
45
52
theorem support_single_mul_eq_image [DecidableEq G] [Mul G] (f : MonoidAlgebra k G) {r : k} (hr : βˆ€ y, r * y = 0 ↔ y = 0) {x : G} (lx : IsLeftRegular x) : (single x r * f : MonoidAlgebra k G).support = Finset.image (x * Β·) f.support := by
refine subset_antisymm (support_single_mul_subset f _ _) fun y hy => ?_ obtain ⟨y, yf, rfl⟩ : βˆƒ a : G, a ∈ f.support ∧ x * a = y := by simpa only [Finset.mem_image, exists_prop] using hy simp only [mul_apply, mem_support_iff.mp yf, hr, mem_support_iff, sum_single_index, Finsupp.sum_ite_eq', Ne, not_false...
[ " (a * b).support βŠ† a.support * b.support", " (sum a fun a₁ b₁ => sum b fun aβ‚‚ bβ‚‚ => single (a₁ * aβ‚‚) (b₁ * bβ‚‚)).support βŠ† a.support * b.support", " imageβ‚‚ (fun x x_1 => x * x_1) {a} f.support βŠ† image (fun x => a * x) f.support", " imageβ‚‚ (fun x x_1 => x * x_1) f.support {a} βŠ† image (fun x => x * a) f.support...
[ " (a * b).support βŠ† a.support * b.support", " (sum a fun a₁ b₁ => sum b fun aβ‚‚ bβ‚‚ => single (a₁ * aβ‚‚) (b₁ * bβ‚‚)).support βŠ† a.support * b.support", " imageβ‚‚ (fun x x_1 => x * x_1) {a} f.support βŠ† image (fun x => a * x) f.support", " imageβ‚‚ (fun x x_1 => x * x_1) f.support {a} βŠ† image (fun x => x * a) f.support...
import Mathlib.Algebra.Ring.Defs import Mathlib.Algebra.Group.Ext local macro:max "local_hAdd[" type:term ", " inst:term "]" : term => `(term| (letI := $inst; HAdd.hAdd : $type β†’ $type β†’ $type)) local macro:max "local_hMul[" type:term ", " inst:term "]" : term => `(term| (letI := $inst; HMul.hMul : $type β†’ $typ...
Mathlib/Algebra/Ring/Ext.lean
427
429
theorem toNonUnitalSemiring_injective : Function.Injective (@toNonUnitalSemiring R) := by
rintro ⟨⟩ ⟨⟩ _; congr
[ " inst₁ = instβ‚‚", " toAddMonoid = toAddMonoid", " HAdd.hAdd = HAdd.hAdd", " NatCast.natCast = NatCast.natCast", " NatCast.natCast n = NatCast.natCast n", " NatCast.natCast 0 = NatCast.natCast 0", " 0 = 0", " NatCast.natCast (n + 1) = NatCast.natCast (n + 1)", " NatCast.natCast n + 1 = NatCast.natCas...
[ " inst₁ = instβ‚‚", " toAddMonoid = toAddMonoid", " HAdd.hAdd = HAdd.hAdd", " NatCast.natCast = NatCast.natCast", " NatCast.natCast n = NatCast.natCast n", " NatCast.natCast 0 = NatCast.natCast 0", " 0 = 0", " NatCast.natCast (n + 1) = NatCast.natCast (n + 1)", " NatCast.natCast n + 1 = NatCast.natCas...
import Mathlib.GroupTheory.Solvable import Mathlib.FieldTheory.PolynomialGaloisGroup import Mathlib.RingTheory.RootsOfUnity.Basic #align_import field_theory.abel_ruffini from "leanprover-community/mathlib"@"e3f4be1fcb5376c4948d7f095bec45350bfb9d1a" noncomputable section open scoped Classical Polynomial Intermedi...
Mathlib/FieldTheory/AbelRuffini.lean
66
72
theorem gal_prod_isSolvable {s : Multiset F[X]} (hs : βˆ€ p ∈ s, IsSolvable (Gal p)) : IsSolvable s.prod.Gal := by
apply Multiset.induction_on' s Β· exact gal_one_isSolvable Β· intro p t hps _ ht rw [Multiset.insert_eq_cons, Multiset.prod_cons] exact gal_mul_isSolvable (hs p hps) ht
[ " IsSolvable (Gal 0)", " IsSolvable (Gal 1)", " IsSolvable (C x).Gal", " IsSolvable X.Gal", " IsSolvable (X - C x).Gal", " IsSolvable (X ^ n).Gal", " IsSolvable s.prod.Gal", " IsSolvable (Multiset.prod 0).Gal", " βˆ€ {a : F[X]} {s_1 : Multiset F[X]}, a ∈ s β†’ s_1 βŠ† s β†’ IsSolvable s_1.prod.Gal β†’ IsSolva...
[ " IsSolvable (Gal 0)", " IsSolvable (Gal 1)", " IsSolvable (C x).Gal", " IsSolvable X.Gal", " IsSolvable (X - C x).Gal", " IsSolvable (X ^ n).Gal" ]
import Mathlib.Algebra.Group.Basic import Mathlib.Algebra.Order.Monoid.Canonical.Defs import Mathlib.Data.Set.Function import Mathlib.Order.Interval.Set.Basic #align_import data.set.intervals.monoid from "leanprover-community/mathlib"@"aba57d4d3dae35460225919dcd82fe91355162f9" namespace Set variable {M : Type*} ...
Mathlib/Algebra/Order/Interval/Set/Monoid.lean
133
134
theorem image_const_add_Ioc : (fun x => a + x) '' Ioc b c = Ioc (a + b) (a + c) := by
simp only [add_comm a, image_add_const_Ioc]
[ " BijOn (fun x => x + d) (Ici a) (Ici (a + d))", " x✝ ∈ (fun x => x + d) '' Ici a", " a + d + c ∈ (fun x => x + d) '' Ici a", " (fun x => x + d) (a + c) = a + d + c", " BijOn (fun x => x + d) (Ioi a) (Ioi (a + d))", " x✝ ∈ (fun x => x + d) '' Ioi a", " a + d + c ∈ (fun x => x + d) '' Ioi a", " BijOn (...
[ " BijOn (fun x => x + d) (Ici a) (Ici (a + d))", " x✝ ∈ (fun x => x + d) '' Ici a", " a + d + c ∈ (fun x => x + d) '' Ici a", " (fun x => x + d) (a + c) = a + d + c", " BijOn (fun x => x + d) (Ioi a) (Ioi (a + d))", " x✝ ∈ (fun x => x + d) '' Ioi a", " a + d + c ∈ (fun x => x + d) '' Ioi a", " BijOn (...
import Mathlib.Analysis.SpecialFunctions.Gaussian.GaussianIntegral import Mathlib.Analysis.Complex.CauchyIntegral import Mathlib.MeasureTheory.Integral.Pi import Mathlib.Analysis.Fourier.FourierTransform open Real Set MeasureTheory Filter Asymptotics intervalIntegral open scoped Real Topology FourierTransform Re...
Mathlib/Analysis/SpecialFunctions/Gaussian/FourierTransform.lean
132
145
theorem integrable_cexp_neg_mul_sq_add_real_mul_I (hb : 0 < b.re) (c : ℝ) : Integrable fun x : ℝ => cexp (-b * (x + c * I) ^ 2) := by
refine ⟨(Complex.continuous_exp.comp (continuous_const.mul ((continuous_ofReal.add continuous_const).pow 2))).aestronglyMeasurable, ?_⟩ rw [← hasFiniteIntegral_norm_iff] simp_rw [norm_cexp_neg_mul_sq_add_mul_I' hb.ne', neg_sub _ (c ^ 2 * _), sub_eq_add_neg _ (b.re * _), Real.e...
[ " β€–cexp (-b * (↑T + ↑c * I) ^ 2)β€– = rexp (-(b.re * T ^ 2 - 2 * b.im * c * T - b.re * c ^ 2))", " rexp (-((↑b.re + ↑b.im * I) * (↑T + ↑c * I) ^ 2).re) =\n rexp (-((↑b.re + ↑b.im * I).re * T ^ 2 - 2 * (↑b.re + ↑b.im * I).im * c * T - (↑b.re + ↑b.im * I).re * c ^ 2))", " rexp\n (-(b.re * ((T + (c * 0 - 0 *...
[ " β€–cexp (-b * (↑T + ↑c * I) ^ 2)β€– = rexp (-(b.re * T ^ 2 - 2 * b.im * c * T - b.re * c ^ 2))", " rexp (-((↑b.re + ↑b.im * I) * (↑T + ↑c * I) ^ 2).re) =\n rexp (-((↑b.re + ↑b.im * I).re * T ^ 2 - 2 * (↑b.re + ↑b.im * I).im * c * T - (↑b.re + ↑b.im * I).re * c ^ 2))", " rexp\n (-(b.re * ((T + (c * 0 - 0 *...
import Mathlib.Analysis.InnerProductSpace.Dual #align_import analysis.inner_product_space.lax_milgram from "leanprover-community/mathlib"@"46b633fd842bef9469441c0209906f6dddd2b4f5" noncomputable section open RCLike LinearMap ContinuousLinearMap InnerProductSpace open LinearMap (ker range) open RealInnerProduct...
Mathlib/Analysis/InnerProductSpace/LaxMilgram.lean
51
62
theorem bounded_below (coercive : IsCoercive B) : βˆƒ C, 0 < C ∧ βˆ€ v, C * β€–vβ€– ≀ β€–Bβ™― vβ€– := by
rcases coercive with ⟨C, C_ge_0, coercivity⟩ refine ⟨C, C_ge_0, ?_⟩ intro v by_cases h : 0 < β€–vβ€– Β· refine (mul_le_mul_right h).mp ?_ calc C * β€–vβ€– * β€–vβ€– ≀ B v v := coercivity v _ = βŸͺBβ™― v, v⟫_ℝ := (continuousLinearMapOfBilin_apply B v v).symm _ ≀ β€–Bβ™― vβ€– * β€–vβ€– := real_inner_le_norm (Bβ™― v) ...
[ " βˆƒ C, 0 < C ∧ βˆ€ (v : V), C * β€–vβ€– ≀ β€–(continuousLinearMapOfBilin B) vβ€–", " βˆ€ (v : V), C * β€–vβ€– ≀ β€–(continuousLinearMapOfBilin B) vβ€–", " C * β€–vβ€– ≀ β€–(continuousLinearMapOfBilin B) vβ€–", " C * β€–vβ€– * β€–vβ€– ≀ β€–(continuousLinearMapOfBilin B) vβ€– * β€–vβ€–", " v = 0" ]
[]
import Mathlib.Logic.Equiv.Option import Mathlib.Order.RelIso.Basic import Mathlib.Order.Disjoint import Mathlib.Order.WithBot import Mathlib.Tactic.Monotonicity.Attr import Mathlib.Util.AssertExists #align_import order.hom.basic from "leanprover-community/mathlib"@"62a5626868683c104774de8d85b9855234ac807c" open ...
Mathlib/Order/Hom/Basic.lean
1,235
1,239
theorem OrderIso.map_bot' [LE Ξ±] [PartialOrder Ξ²] (f : Ξ± ≃o Ξ²) {x : Ξ±} {y : Ξ²} (hx : βˆ€ x', x ≀ x') (hy : βˆ€ y', y ≀ y') : f x = y := by
refine le_antisymm ?_ (hy _) rw [← f.apply_symm_apply y, f.map_rel_iff] apply hx
[ " βˆ€ {a b : Ξ±}, f.toEmbedding a ≀ f.toEmbedding b ↔ a ≀ b", " f.toEmbedding a✝ ≀ f.toEmbedding b✝ ↔ a✝ ≀ b✝", " f x = y", " f x ≀ y", " x ≀ (RelIso.symm f) y" ]
[ " βˆ€ {a b : Ξ±}, f.toEmbedding a ≀ f.toEmbedding b ↔ a ≀ b", " f.toEmbedding a✝ ≀ f.toEmbedding b✝ ↔ a✝ ≀ b✝" ]
import Mathlib.Data.Finset.Sigma import Mathlib.Data.Finset.Pairwise import Mathlib.Data.Finset.Powerset import Mathlib.Data.Fintype.Basic import Mathlib.Order.CompleteLatticeIntervals #align_import order.sup_indep from "leanprover-community/mathlib"@"c4c2ed622f43768eff32608d4a0f8a6cec1c047d" variable {Ξ± Ξ² ΞΉ ΞΉ' :...
Mathlib/Order/SupIndep.lean
151
154
theorem supIndep_univ_bool (f : Bool β†’ Ξ±) : (Finset.univ : Finset Bool).SupIndep f ↔ Disjoint (f false) (f true) := haveI : true β‰  false := by
simp only [Ne, not_false_iff] (supIndep_pair this).trans disjoint_comm
[ " Decidable (s.SupIndep f)", " (t : Finset ΞΉ) β†’ t βŠ† s β†’ Decidable (βˆ€ ⦃i : ι⦄, i ∈ s β†’ i βˆ‰ t β†’ Disjoint (f i) (t.sup f))", " Decidable (βˆ€ ⦃i : ι⦄, i ∈ s β†’ i βˆ‰ t β†’ Disjoint (f i) (t.sup f))", " (a : ΞΉ) β†’ a ∈ s β†’ Decidable (a βˆ‰ t β†’ Disjoint (f a) (t.sup f))", " Decidable (i βˆ‰ t β†’ Disjoint (f i) (t.sup f))", ...
[ " Decidable (s.SupIndep f)", " (t : Finset ΞΉ) β†’ t βŠ† s β†’ Decidable (βˆ€ ⦃i : ι⦄, i ∈ s β†’ i βˆ‰ t β†’ Disjoint (f i) (t.sup f))", " Decidable (βˆ€ ⦃i : ι⦄, i ∈ s β†’ i βˆ‰ t β†’ Disjoint (f i) (t.sup f))", " (a : ΞΉ) β†’ a ∈ s β†’ Decidable (a βˆ‰ t β†’ Disjoint (f a) (t.sup f))", " Decidable (i βˆ‰ t β†’ Disjoint (f i) (t.sup f))", ...
import Mathlib.Analysis.BoxIntegral.Partition.Filter import Mathlib.Analysis.BoxIntegral.Partition.Measure import Mathlib.Topology.UniformSpace.Compact import Mathlib.Init.Data.Bool.Lemmas #align_import analysis.box_integral.basic from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" open...
Mathlib/Analysis/BoxIntegral/Basic.lean
127
133
theorem integralSum_disjUnion (f : ℝⁿ β†’ E) (vol : ΞΉ →ᡇᡃ E β†’L[ℝ] F) {π₁ Ο€β‚‚ : TaggedPrepartition I} (h : Disjoint π₁.iUnion Ο€β‚‚.iUnion) : integralSum f vol (π₁.disjUnion Ο€β‚‚ h) = integralSum f vol π₁ + integralSum f vol Ο€β‚‚ := by
refine (Prepartition.sum_disj_union_boxes h _).trans (congr_argβ‚‚ (Β· + Β·) (sum_congr rfl fun J hJ => ?_) (sum_congr rfl fun J hJ => ?_)) Β· rw [disjUnion_tag_of_mem_left _ hJ] Β· rw [disjUnion_tag_of_mem_right _ hJ]
[ " integralSum f vol (Ο€.biUnionTagged Ο€i) = βˆ‘ J ∈ Ο€.boxes, integralSum f vol (Ο€i J)", " (vol J') (f ((Ο€.biUnionTagged Ο€i).tag J')) = (vol J') (f ((Ο€i J).tag J'))", " integralSum f vol (Ο€.biUnionPrepartition Ο€i) = integralSum f vol Ο€", " βˆ‘ J' ∈ (Ο€i J).boxes, (vol J') (f ((Ο€.biUnionPrepartition Ο€i).tag J')) = (v...
[ " integralSum f vol (Ο€.biUnionTagged Ο€i) = βˆ‘ J ∈ Ο€.boxes, integralSum f vol (Ο€i J)", " (vol J') (f ((Ο€.biUnionTagged Ο€i).tag J')) = (vol J') (f ((Ο€i J).tag J'))", " integralSum f vol (Ο€.biUnionPrepartition Ο€i) = integralSum f vol Ο€", " βˆ‘ J' ∈ (Ο€i J).boxes, (vol J') (f ((Ο€.biUnionPrepartition Ο€i).tag J')) = (v...
import Mathlib.Data.Finsupp.Lex import Mathlib.Data.Finsupp.Multiset import Mathlib.Order.GameAdd #align_import logic.hydra from "leanprover-community/mathlib"@"48085f140e684306f9e7da907cd5932056d1aded" namespace Relation open Multiset Prod variable {Ξ± : Type*} def CutExpand (r : Ξ± β†’ Ξ± β†’ Prop) (s' s : Multise...
Mathlib/Logic/Hydra.lean
62
74
theorem cutExpand_le_invImage_lex [DecidableEq Ξ±] [IsIrrefl Ξ± r] : CutExpand r ≀ InvImage (Finsupp.Lex (rᢜ βŠ“ (Β· β‰  Β·)) (Β· < Β·)) toFinsupp := by
rintro s t ⟨u, a, hr, he⟩ replace hr := fun a' ↦ mt (hr a') classical refine ⟨a, fun b h ↦ ?_, ?_⟩ <;> simp_rw [toFinsupp_apply] Β· apply_fun count b at he simpa only [count_add, count_singleton, if_neg h.2, add_zero, count_eq_zero.2 (hr b h.1)] using he Β· apply_fun count a at he simp only [co...
[ " CutExpand r ≀ InvImage (Finsupp.Lex (rᢜ βŠ“ fun x x_1 => x β‰  x_1) fun x x_1 => x < x_1) ⇑toFinsupp", " InvImage (Finsupp.Lex (rᢜ βŠ“ fun x x_1 => x β‰  x_1) fun x x_1 => x < x_1) (⇑toFinsupp) s t", " (toFinsupp s) b = (toFinsupp t) b", " (fun {i} x x_1 => x < x_1) ((toFinsupp s) a) ((toFinsupp t) a)", " count b...
[]
import Mathlib.Analysis.SpecialFunctions.Complex.Arg import Mathlib.Analysis.SpecialFunctions.Log.Basic #align_import analysis.special_functions.complex.log from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982" noncomputable section namespace Complex open Set Filter Bornology open scop...
Mathlib/Analysis/SpecialFunctions/Complex/Log.lean
116
116
theorem log_I : log I = Ο€ / 2 * I := by
simp [log]
[ " x.log.re = (abs x).log", " x.log.im = x.arg", " -Ο€ < x.log.im", " x.log.im ≀ Ο€", " cexp x.log = x", " x ∈ Set.range cexp β†’ x ∈ {0}ᢜ", " cexp x ∈ {0}ᢜ", " (cexp x).log = x", " x = y", " (↑x.log).re = (↑x).log.re", " (↑x.log).im = (↑x).log.im", " (↑x).log.re = x.log", " (↑r * x).log = ↑r.log...
[ " x.log.re = (abs x).log", " x.log.im = x.arg", " -Ο€ < x.log.im", " x.log.im ≀ Ο€", " cexp x.log = x", " x ∈ Set.range cexp β†’ x ∈ {0}ᢜ", " cexp x ∈ {0}ᢜ", " (cexp x).log = x", " x = y", " (↑x.log).re = (↑x).log.re", " (↑x.log).im = (↑x).log.im", " (↑x).log.re = x.log", " (↑r * x).log = ↑r.log...
import Mathlib.Analysis.NormedSpace.PiLp import Mathlib.Analysis.InnerProductSpace.PiL2 #align_import analysis.matrix from "leanprover-community/mathlib"@"46b633fd842bef9469441c0209906f6dddd2b4f5" noncomputable section open scoped NNReal Matrix namespace Matrix variable {R l m n Ξ± Ξ² : Type*} [Fintype l] [Fintyp...
Mathlib/Analysis/Matrix.lean
574
575
theorem frobenius_nnnorm_map_eq (A : Matrix m n Ξ±) (f : Ξ± β†’ Ξ²) (hf : βˆ€ a, β€–f aβ€–β‚Š = β€–aβ€–β‚Š) : β€–A.map fβ€–β‚Š = β€–Aβ€–β‚Š := by
simp_rw [frobenius_nnnorm_def, Matrix.map_apply, hf]
[ " NormedAddCommGroup (PiLp 2 fun i => PiLp 2 fun j => Ξ±)", " BoundedSMul R (PiLp 2 fun i => PiLp 2 fun j => Ξ±)", " NormedSpace R (PiLp 2 fun i => PiLp 2 fun j => Ξ±)", " β€–Aβ€–β‚Š = (βˆ‘ i : m, βˆ‘ j : n, β€–A i jβ€–β‚Š ^ 2) ^ (1 / 2)", " β€–(WithLp.equiv 2 (m β†’ WithLp 2 (n β†’ Ξ±))).symm fun i => (WithLp.equiv 2 (n β†’ Ξ±)).symm ...
[ " NormedAddCommGroup (PiLp 2 fun i => PiLp 2 fun j => Ξ±)", " BoundedSMul R (PiLp 2 fun i => PiLp 2 fun j => Ξ±)", " NormedSpace R (PiLp 2 fun i => PiLp 2 fun j => Ξ±)", " β€–Aβ€–β‚Š = (βˆ‘ i : m, βˆ‘ j : n, β€–A i jβ€–β‚Š ^ 2) ^ (1 / 2)", " β€–(WithLp.equiv 2 (m β†’ WithLp 2 (n β†’ Ξ±))).symm fun i => (WithLp.equiv 2 (n β†’ Ξ±)).symm ...
import Mathlib.RingTheory.OrzechProperty import Mathlib.RingTheory.Ideal.Quotient import Mathlib.RingTheory.PrincipalIdealDomain #align_import linear_algebra.invariant_basis_number from "leanprover-community/mathlib"@"5fd3186f1ec30a75d5f65732e3ce5e623382556f" noncomputable section open Function universe u v w ...
Mathlib/LinearAlgebra/InvariantBasisNumber.lean
197
203
theorem card_le_of_surjective' [RankCondition R] {Ξ± Ξ² : Type*} [Fintype Ξ±] [Fintype Ξ²] (f : (Ξ± β†’β‚€ R) β†’β‚—[R] Ξ² β†’β‚€ R) (i : Surjective f) : Fintype.card Ξ² ≀ Fintype.card Ξ± := by
let P := Finsupp.linearEquivFunOnFinite R R Ξ² let Q := (Finsupp.linearEquivFunOnFinite R R Ξ±).symm exact card_le_of_surjective R ((P.toLinearMap.comp f).comp Q.toLinearMap) ((P.surjective.comp i).comp Q.surjective)
[ " StrongRankCondition R ↔ βˆ€ (n : β„•) (f : (Fin (n + 1) β†’ R) β†’β‚—[R] Fin n β†’ R), Β¬Injective ⇑f", " False", " n ≀ m", " StrongRankCondition R", " 0 = update 0 (Fin.last n) 1", " f 0 = f (update 0 (Fin.last n) 1)", " f 0 m = f (update 0 (Fin.last n) 1) m", " Fintype.card Ξ± ≀ Fintype.card Ξ²", " Fintype.car...
[ " StrongRankCondition R ↔ βˆ€ (n : β„•) (f : (Fin (n + 1) β†’ R) β†’β‚—[R] Fin n β†’ R), Β¬Injective ⇑f", " False", " n ≀ m", " StrongRankCondition R", " 0 = update 0 (Fin.last n) 1", " f 0 = f (update 0 (Fin.last n) 1)", " f 0 m = f (update 0 (Fin.last n) 1) m", " Fintype.card Ξ± ≀ Fintype.card Ξ²", " Fintype.car...
import Mathlib.Analysis.SpecialFunctions.Pow.Real import Mathlib.LinearAlgebra.FreeModule.PID import Mathlib.LinearAlgebra.Matrix.AbsoluteValue import Mathlib.NumberTheory.ClassNumber.AdmissibleAbsoluteValue import Mathlib.RingTheory.ClassGroup import Mathlib.RingTheory.DedekindDomain.IntegralClosure import Mathlib.Ri...
Mathlib/NumberTheory/ClassNumber/Finite.lean
119
135
theorem exists_min (I : (Ideal S)⁰) : βˆƒ b ∈ (I : Ideal S), b β‰  0 ∧ βˆ€ c ∈ (I : Ideal S), abv (Algebra.norm R c) < abv (Algebra.norm R b) β†’ c = (0 : S) := by
obtain ⟨_, ⟨b, b_mem, b_ne_zero, rfl⟩, min⟩ := @Int.exists_least_of_bdd (fun a => βˆƒ b ∈ (I : Ideal S), b β‰  (0 : S) ∧ abv (Algebra.norm R b) = a) (by use 0 rintro _ ⟨b, _, _, rfl⟩ apply abv.nonneg) (by obtain ⟨b, b_mem, b_ne_zero⟩ := (I : Ideal S).ne_bot_iff.mp (nonZeroDivisors.c...
[ " 0 < normBound abv bS", " βˆƒ i j k, (Algebra.leftMulMatrix bS) (bS i) j k β‰  0", " False", " bS i = 0", " (Algebra.leftMulMatrix bS) (bS i) = 0", " (Algebra.leftMulMatrix bS) (bS i) j k = 0 j k", " 0 <\n ↑(Fintype.card ΞΉ).factorial *\n (↑(Fintype.card ΞΉ) *\n (Finset.image (fun ijk => abv...
[ " 0 < normBound abv bS", " βˆƒ i j k, (Algebra.leftMulMatrix bS) (bS i) j k β‰  0", " False", " bS i = 0", " (Algebra.leftMulMatrix bS) (bS i) = 0", " (Algebra.leftMulMatrix bS) (bS i) j k = 0 j k", " 0 <\n ↑(Fintype.card ΞΉ).factorial *\n (↑(Fintype.card ΞΉ) *\n (Finset.image (fun ijk => abv...
import Mathlib.Probability.Martingale.Basic #align_import probability.martingale.centering from "leanprover-community/mathlib"@"bea6c853b6edbd15e9d0941825abd04d77933ed0" open TopologicalSpace Filter open scoped NNReal ENNReal MeasureTheory ProbabilityTheory namespace MeasureTheory variable {Ξ© E : Type*} {m0 : ...
Mathlib/Probability/Martingale/Centering.lean
50
51
theorem predictablePart_zero : predictablePart f β„± ΞΌ 0 = 0 := by
simp_rw [predictablePart, Finset.range_zero, Finset.sum_empty]
[ " predictablePart f β„± ΞΌ 0 = 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
151
155
theorem weightedVSubOfPoint_insert [DecidableEq ΞΉ] (w : ΞΉ β†’ k) (p : ΞΉ β†’ P) (i : ΞΉ) : (insert i s).weightedVSubOfPoint p (p i) w = s.weightedVSubOfPoint p (p i) w := by
rw [weightedVSubOfPoint_apply, weightedVSubOfPoint_apply] apply sum_insert_zero rw [vsub_self, smul_zero]
[ " 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 Mathlib.Data.Nat.Bits import Mathlib.Order.Lattice #align_import data.nat.size from "leanprover-community/mathlib"@"18a5306c091183ac90884daa9373fa3b178e8607" namespace Nat section set_option linter.deprecated false theorem shiftLeft_eq_mul_pow (m) : βˆ€ n, m <<< n = m * 2 ^ n := shiftLeft_eq _ #align nat....
Mathlib/Data/Nat/Size.lean
107
116
theorem lt_size_self (n : β„•) : n < 2 ^ size n := by
rw [← one_shiftLeft] have : βˆ€ {n}, n = 0 β†’ n < 1 <<< (size n) := by simp apply binaryRec _ _ n Β· apply this rfl intro b n IH by_cases h : bit b n = 0 Β· apply this h rw [size_bit h, shiftLeft_succ, shiftLeft_eq, one_mul, ← bit0_val] exact bit_lt_bit0 _ (by simpa [shiftLeft_eq, shiftRight_eq_div_pow] u...
[ " shiftLeft' true m 0 + 1 = (m + 1) * 2 ^ 0", " shiftLeft' true m (k + 1) + 1 = (m + 1) * 2 ^ (k + 1)", " bit1 (shiftLeft' true m k) + 1 = (m + 1) * (2 ^ k * 2)", " 2 * shiftLeft' true m k + 1 + 1 = (m + 1) * (2 ^ k * 2)", " 2 * (shiftLeft' true m k + 1) = (m + 1) * (2 ^ k * 2)", " shiftLeft' b m n β‰  0", ...
[ " shiftLeft' true m 0 + 1 = (m + 1) * 2 ^ 0", " shiftLeft' true m (k + 1) + 1 = (m + 1) * 2 ^ (k + 1)", " bit1 (shiftLeft' true m k) + 1 = (m + 1) * (2 ^ k * 2)", " 2 * shiftLeft' true m k + 1 + 1 = (m + 1) * (2 ^ k * 2)", " 2 * (shiftLeft' true m k + 1) = (m + 1) * (2 ^ k * 2)", " shiftLeft' b m n β‰  0", ...
import Mathlib.Topology.Separation import Mathlib.Topology.NoetherianSpace #align_import topology.quasi_separated from "leanprover-community/mathlib"@"5dc6092d09e5e489106865241986f7f2ad28d4c8" open TopologicalSpace variable {Ξ± Ξ² : Type*} [TopologicalSpace Ξ±] [TopologicalSpace Ξ²] {f : Ξ± β†’ Ξ²} def IsQuasiSeparate...
Mathlib/Topology/QuasiSeparated.lean
53
56
theorem isQuasiSeparated_univ_iff {Ξ± : Type*} [TopologicalSpace Ξ±] : IsQuasiSeparated (Set.univ : Set Ξ±) ↔ QuasiSeparatedSpace Ξ± := by
rw [quasiSeparatedSpace_iff] simp [IsQuasiSeparated]
[ " IsQuasiSeparated Set.univ ↔ QuasiSeparatedSpace Ξ±", " IsQuasiSeparated Set.univ ↔ βˆ€ (U V : Set Ξ±), IsOpen U β†’ IsCompact U β†’ IsOpen V β†’ IsCompact V β†’ IsCompact (U ∩ V)" ]
[]
import Mathlib.Algebra.GroupWithZero.Divisibility import Mathlib.Algebra.Order.Group.Int import Mathlib.Algebra.Order.Ring.Nat import Mathlib.Algebra.Ring.Rat import Mathlib.Data.PNat.Defs #align_import data.rat.lemmas from "leanprover-community/mathlib"@"550b58538991c8977703fdeb7c9d51a5aa27df11" namespace Rat o...
Mathlib/Data/Rat/Lemmas.lean
109
111
theorem mul_self_den (q : β„š) : (q * q).den = q.den * q.den := by
rw [Rat.mul_den, Int.natAbs_mul, Nat.Coprime.gcd_eq_one, Nat.div_one] exact (q.reduced.mul_right q.reduced).mul (q.reduced.mul_right q.reduced)
[ " (a /. b).num ∣ a", " { num := n, den := d, den_nz := h, reduced := c }.num ∣ a", " n.natAbs ∣ a.natAbs * d", " ↑(a /. b).den ∣ b", " ↑{ num := n, den := d, den_nz := h, reduced := c }.den ∣ b", " d ∣ n.natAbs * b.natAbs", " ↑d ∣ a * ↑d", " βˆƒ c, n = c * q.num ∧ d = c * ↑q.den", " βˆƒ c, 0 = c * q.num...
[ " (a /. b).num ∣ a", " { num := n, den := d, den_nz := h, reduced := c }.num ∣ a", " n.natAbs ∣ a.natAbs * d", " ↑(a /. b).den ∣ b", " ↑{ num := n, den := d, den_nz := h, reduced := c }.den ∣ b", " d ∣ n.natAbs * b.natAbs", " ↑d ∣ a * ↑d", " βˆƒ c, n = c * q.num ∧ d = c * ↑q.den", " βˆƒ c, 0 = c * q.num...
import Mathlib.CategoryTheory.Category.Cat import Mathlib.CategoryTheory.Elements #align_import category_theory.grothendieck from "leanprover-community/mathlib"@"14b69e9f3c16630440a2cbd46f1ddad0d561dee7" universe u namespace CategoryTheory variable {C D : Type*} [Category C] [Category D] variable (F : C β₯€ Cat) ...
Mathlib/CategoryTheory/Grothendieck.lean
78
83
theorem ext {X Y : Grothendieck F} (f g : Hom X Y) (w_base : f.base = g.base) (w_fiber : eqToHom (by rw [w_base]) ≫ f.fiber = g.fiber) : f = g := by
cases f; cases g congr dsimp at w_base aesop_cat
[ " (F.map g.base).obj X.fiber = (F.map f.base).obj X.fiber", " f = g", " { base := base✝, fiber := fiber✝ } = g", " { base := base✝¹, fiber := fiber✝¹ } = { base := base✝, fiber := fiber✝ }", " HEq fiber✝¹ fiber✝" ]
[]
import Mathlib.CategoryTheory.Adjunction.Basic import Mathlib.CategoryTheory.Category.Preorder import Mathlib.CategoryTheory.IsomorphismClasses import Mathlib.CategoryTheory.Thin #align_import category_theory.skeletal from "leanprover-community/mathlib"@"28aa996fc6fb4317f0083c4e6daf79878d81be33" universe v₁ vβ‚‚ v₃...
Mathlib/CategoryTheory/Skeletal.lean
108
111
theorem skeleton_skeletal : Skeletal (Skeleton C) := by
rintro X Y ⟨h⟩ have : X.out β‰ˆ Y.out := ⟨(fromSkeleton C).mapIso h⟩ simpa using Quotient.sound this
[ " Category.{?u.1478, u₁} (Skeleton C)", " (fromSkeleton C).Full", " (fromSkeleton C).Faithful", " Skeletal (Skeleton C)", " X = Y" ]
[ " Category.{?u.1478, u₁} (Skeleton C)", " (fromSkeleton C).Full", " (fromSkeleton C).Faithful" ]
import Mathlib.Algebra.BigOperators.Fin import Mathlib.Algebra.Polynomial.Degree.Lemmas #align_import data.polynomial.erase_lead from "leanprover-community/mathlib"@"fa256f00ce018e7b40e1dc756e403c86680bf448" noncomputable section open Polynomial open Polynomial Finset namespace Polynomial variable {R : Type*}...
Mathlib/Algebra/Polynomial/EraseLead.lean
55
56
theorem eraseLead_coeff_of_ne (i : β„•) (hi : i β‰  f.natDegree) : f.eraseLead.coeff i = f.coeff i := by
simp [eraseLead_coeff, hi]
[ " f.eraseLead.support = f.support.erase f.natDegree", " f.eraseLead.coeff i = if i = f.natDegree then 0 else f.coeff i", " f.eraseLead.coeff f.natDegree = 0", " f.eraseLead.coeff i = f.coeff i" ]
[ " f.eraseLead.support = f.support.erase f.natDegree", " f.eraseLead.coeff i = if i = f.natDegree then 0 else f.coeff i", " f.eraseLead.coeff f.natDegree = 0" ]
import Mathlib.Algebra.BigOperators.Ring.List import Mathlib.Data.Nat.ModEq import Mathlib.Data.Nat.GCD.BigOperators namespace Nat variable {ΞΉ : Type*} lemma modEq_list_prod_iff {a b} {l : List β„•} (co : l.Pairwise Coprime) : a ≑ b [MOD l.prod] ↔ βˆ€ i, a ≑ b [MOD l.get i] := by induction' l with m l ih Β· si...
Mathlib/Data/Nat/ChineseRemainder.lean
107
118
theorem chineseRemainderOfList_perm {l l' : List ΞΉ} (hl : l.Perm l') (hs : βˆ€ i ∈ l, s i β‰  0) (co : l.Pairwise (Coprime on s)) : (chineseRemainderOfList a s l co : β„•) = chineseRemainderOfList a s l' (co.perm hl coprime_comm.mpr) := by
let z := chineseRemainderOfList a s l' (co.perm hl coprime_comm.mpr) have hlp : (l.map s).prod = (l'.map s).prod := List.Perm.prod_eq (List.Perm.map s hl) exact (chineseRemainderOfList_modEq_unique a s l co (z := z) (fun i hi => z.prop i (hl.symm.mem_iff.mpr hi))).symm.eq_of_lt_of_lt (chineseRemainderO...
[ " a ≑ b [MOD l.prod] ↔ βˆ€ (i : Fin l.length), a ≑ b [MOD l.get i]", " a ≑ b [MOD [].prod] ↔ βˆ€ (i : Fin [].length), a ≑ b [MOD [].get i]", " a ≑ b [MOD (m :: l).prod] ↔ βˆ€ (i : Fin (m :: l).length), a ≑ b [MOD (m :: l).get i]", " (a ≑ b [MOD m] ∧ βˆ€ (i : Fin l.length), a ≑ b [MOD l.get i]) ↔ βˆ€ (i : Fin l.length.s...
[ " a ≑ b [MOD l.prod] ↔ βˆ€ (i : Fin l.length), a ≑ b [MOD l.get i]", " a ≑ b [MOD [].prod] ↔ βˆ€ (i : Fin [].length), a ≑ b [MOD [].get i]", " a ≑ b [MOD (m :: l).prod] ↔ βˆ€ (i : Fin (m :: l).length), a ≑ b [MOD (m :: l).get i]", " (a ≑ b [MOD m] ∧ βˆ€ (i : Fin l.length), a ≑ b [MOD l.get i]) ↔ βˆ€ (i : Fin l.length.s...
import Mathlib.LinearAlgebra.Matrix.Charpoly.Coeff import Mathlib.FieldTheory.Finite.Basic import Mathlib.Data.Matrix.CharP #align_import linear_algebra.matrix.charpoly.finite_field from "leanprover-community/mathlib"@"b95b8c7a484a298228805c72c142f6b062eb0d70" noncomputable section open Polynomial Matrix open s...
Mathlib/LinearAlgebra/Matrix/Charpoly/FiniteField.lean
53
58
theorem FiniteField.trace_pow_card {K : Type*} [Field K] [Fintype K] (M : Matrix n n K) : trace (M ^ Fintype.card K) = trace M ^ Fintype.card K := by
cases isEmpty_or_nonempty n Β· simp [Matrix.trace] rw [Matrix.trace_eq_neg_charpoly_coeff, Matrix.trace_eq_neg_charpoly_coeff, FiniteField.Matrix.charpoly_pow_card, FiniteField.pow_card]
[ " (M ^ Fintype.card K).charpoly = M.charpoly", " (M ^ p ^ k).charpoly = M.charpoly", " (⇑(frobenius K[X] p))^[k] (M ^ p ^ k).charpoly = (⇑(frobenius K[X] p))^[k] M.charpoly", " (M ^ p ^ k).charpoly ^ p ^ k = (⇑(frobenius K[X] p))^[k] M.charpoly", " (M ^ Fintype.card K).charpoly ^ Fintype.card K = (⇑(frobeni...
[ " (M ^ Fintype.card K).charpoly = M.charpoly", " (M ^ p ^ k).charpoly = M.charpoly", " (⇑(frobenius K[X] p))^[k] (M ^ p ^ k).charpoly = (⇑(frobenius K[X] p))^[k] M.charpoly", " (M ^ p ^ k).charpoly ^ p ^ k = (⇑(frobenius K[X] p))^[k] M.charpoly", " (M ^ Fintype.card K).charpoly ^ Fintype.card K = (⇑(frobeni...
import Mathlib.Analysis.Convex.StrictConvexBetween import Mathlib.Geometry.Euclidean.Basic #align_import geometry.euclidean.sphere.basic from "leanprover-community/mathlib"@"46b633fd842bef9469441c0209906f6dddd2b4f5" noncomputable section open RealInnerProductSpace namespace EuclideanGeometry variable {V : Type...
Mathlib/Geometry/Euclidean/Sphere/Basic.lean
74
75
theorem Sphere.mk_center_radius (s : Sphere P) : (⟨s.center, s.radius⟩ : Sphere P) = s := by
ext <;> rfl
[ " { center := s.center, radius := s.radius } = s", " { center := s.center, radius := s.radius }.center = s.center", " { center := s.center, radius := s.radius }.radius = s.radius" ]
[]
import Mathlib.Analysis.SpecialFunctions.Trigonometric.Bounds #align_import data.real.pi.bounds from "leanprover-community/mathlib"@"402f8982dddc1864bd703da2d6e2ee304a866973" -- Porting note: needed to add a lot of type ascriptions for lean to interpret numbers as reals. open scoped Real namespace Real theorem ...
Mathlib/Data/Real/Pi/Bounds.lean
40
71
theorem pi_lt_sqrtTwoAddSeries (n : β„•) : Ο€ < (2 : ℝ) ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) + 1 / (4 : ℝ) ^ n := by
have : Ο€ < (√(2 - sqrtTwoAddSeries 0 n) / (2 : ℝ) + (1 : ℝ) / ((2 : ℝ) ^ n) ^ 3 / 4) * (2 : ℝ) ^ (n + 2) := by rw [← div_lt_iff (by norm_num), ← sin_pi_over_two_pow_succ] refine lt_of_lt_of_le (lt_add_of_sub_right_lt (sin_gt_sub_cube ?_ ?_)) ?_ Β· apply div_pos pi_pos; apply pow_pos; norm_num ...
[ " 2 ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) < Ο€", " √(2 - sqrtTwoAddSeries 0 n) / 2 * 2 ^ (n + 2) < Ο€", " 0 < 2 ^ (n + 2)", " (Ο€ / 2 ^ (n + 2)).sin < Ο€ / 2 ^ (n + 2)", " 0 < Ο€ / 2 ^ (n + 2)", " 0 < 2", " 2 ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) = √(2 - sqrtTwoAddSeries 0 n) / 2 * 2 ^ (n + 2)", " 2 β‰  ...
[ " 2 ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) < Ο€", " √(2 - sqrtTwoAddSeries 0 n) / 2 * 2 ^ (n + 2) < Ο€", " 0 < 2 ^ (n + 2)", " (Ο€ / 2 ^ (n + 2)).sin < Ο€ / 2 ^ (n + 2)", " 0 < Ο€ / 2 ^ (n + 2)", " 0 < 2", " 2 ^ (n + 1) * √(2 - sqrtTwoAddSeries 0 n) = √(2 - sqrtTwoAddSeries 0 n) / 2 * 2 ^ (n + 2)", " 2 β‰  ...
import Mathlib.Algebra.Field.Defs import Mathlib.Algebra.Ring.Int #align_import algebra.field.power from "leanprover-community/mathlib"@"1e05171a5e8cf18d98d9cf7b207540acb044acae" variable {Ξ± : Type*} section DivisionRing variable [DivisionRing Ξ±] {n : β„€}
Mathlib/Algebra/Field/Power.lean
26
30
theorem Odd.neg_zpow (h : Odd n) (a : Ξ±) : (-a) ^ n = -a ^ n := by
have hn : n β‰  0 := by rintro rfl; exact Int.odd_iff_not_even.1 h even_zero obtain ⟨k, rfl⟩ := h simp_rw [zpow_add' (.inr (.inl hn)), zpow_one, zpow_mul, zpow_two, neg_mul_neg, neg_mul_eq_mul_neg]
[ " (-a) ^ n = -a ^ n", " n β‰  0", " False", " (-a) ^ (2 * k + 1) = -a ^ (2 * k + 1)" ]
[]
import Mathlib.CategoryTheory.Adjunction.Whiskering import Mathlib.CategoryTheory.Sites.PreservesSheafification #align_import category_theory.sites.adjunction from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a" namespace CategoryTheory open GrothendieckTopology CategoryTheory Limits Op...
Mathlib/CategoryTheory/Sites/Adjunction.lean
136
143
theorem adjunctionToTypes_unit_app_val {G : Type max v u β₯€ D} (adj : G ⊣ forget D) (Y : SheafOfTypes J) : ((adjunctionToTypes J adj).unit.app Y).val = (adj.whiskerRight _).unit.app ((sheafOfTypesToPresheaf J).obj Y) ≫ whiskerRight (toSheafify J _) (forget D) := by
dsimp [adjunctionToTypes, Adjunction.comp] simp rfl
[ " Function.LeftInverse\n (fun Ξ³ =>\n { val := sheafifyLift J ((A.homEquiv ((sheafToPresheaf J E).obj X) Y.val).symm ((sheafToPresheaf J E).map Ξ³)) β‹― })\n fun Ξ· => { val := (A.homEquiv X.val Y.val) (toSheafify J (((whiskeringRight Cα΅’α΅– E D).obj G).obj X.val) ≫ Ξ·.val) }", " (fun Ξ³ =>\n {\n ...
[ " Function.LeftInverse\n (fun Ξ³ =>\n { val := sheafifyLift J ((A.homEquiv ((sheafToPresheaf J E).obj X) Y.val).symm ((sheafToPresheaf J E).map Ξ³)) β‹― })\n fun Ξ· => { val := (A.homEquiv X.val Y.val) (toSheafify J (((whiskeringRight Cα΅’α΅– E D).obj G).obj X.val) ≫ Ξ·.val) }", " (fun Ξ³ =>\n {\n ...
import Mathlib.Logic.Encodable.Lattice import Mathlib.MeasureTheory.MeasurableSpace.Defs #align_import measure_theory.pi_system from "leanprover-community/mathlib"@"98e83c3d541c77cdb7da20d79611a780ff8e7d90" open MeasurableSpace Set open scoped Classical open MeasureTheory def IsPiSystem {Ξ±} (C : Set (Set Ξ±)) :...
Mathlib/MeasureTheory/PiSystem.lean
105
109
theorem IsPiSystem.comap {Ξ± Ξ²} {S : Set (Set Ξ²)} (h_pi : IsPiSystem S) (f : Ξ± β†’ Ξ²) : IsPiSystem { s : Set Ξ± | βˆƒ t ∈ S, f ⁻¹' t = s } := by
rintro _ ⟨s, hs_mem, rfl⟩ _ ⟨t, ht_mem, rfl⟩ hst rw [← Set.preimage_inter] at hst ⊒ exact ⟨s ∩ t, h_pi s hs_mem t ht_mem (nonempty_of_nonempty_preimage hst), rfl⟩
[ " IsPiSystem {S}", " s ∩ t ∈ {S}", " IsPiSystem (insert βˆ… S)", " s ∩ t ∈ insert βˆ… S", " IsPiSystem (insert univ S)", " s ∩ t ∈ insert univ S", " IsPiSystem {s | βˆƒ t ∈ S, f ⁻¹' t = s}", " f ⁻¹' s ∩ f ⁻¹' t ∈ {s | βˆƒ t ∈ S, f ⁻¹' t = s}", " f ⁻¹' (s ∩ t) ∈ {s | βˆƒ t ∈ S, f ⁻¹' t = s}" ]
[ " IsPiSystem {S}", " s ∩ t ∈ {S}", " IsPiSystem (insert βˆ… S)", " s ∩ t ∈ insert βˆ… S", " IsPiSystem (insert univ S)", " s ∩ t ∈ insert univ S" ]
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
72
80
theorem smul_modByMonic (c : R) (p : R[X]) : c β€’ p %β‚˜ q = c β€’ (p %β‚˜ q) := by
by_cases hq : q.Monic Β· cases' subsingleton_or_nontrivial R with hR hR Β· simp only [eq_iff_true_of_subsingleton] Β· exact (div_modByMonic_unique (c β€’ (p /β‚˜ q)) (c β€’ (p %β‚˜ q)) hq ⟨by rw [mul_smul_comm, ← smul_add, modByMonic_add_div p hq], (degree_smul_le _ _).trans_lt (degree_mod...
[ " p₁ %β‚˜ q = pβ‚‚ %β‚˜ q", " pβ‚‚ %β‚˜ q + q * (pβ‚‚ /β‚˜ q + f) = p₁", " (p₁ + pβ‚‚) %β‚˜ q = p₁ %β‚˜ q + pβ‚‚ %β‚˜ q", " p₁ %β‚˜ q + pβ‚‚ %β‚˜ q + q * (p₁ /β‚˜ q + pβ‚‚ /β‚˜ q) = p₁ + pβ‚‚", " c β€’ p %β‚˜ q = c β€’ (p %β‚˜ q)", " c β€’ (p %β‚˜ q) + q * c β€’ (p /β‚˜ q) = c β€’ p" ]
[ " p₁ %β‚˜ q = pβ‚‚ %β‚˜ q", " pβ‚‚ %β‚˜ q + q * (pβ‚‚ /β‚˜ q + f) = p₁", " (p₁ + pβ‚‚) %β‚˜ q = p₁ %β‚˜ q + pβ‚‚ %β‚˜ q", " p₁ %β‚˜ q + pβ‚‚ %β‚˜ q + q * (p₁ /β‚˜ q + pβ‚‚ /β‚˜ q) = p₁ + pβ‚‚" ]
import Mathlib.Analysis.SpecialFunctions.ImproperIntegrals import Mathlib.Analysis.Calculus.ParametricIntegral import Mathlib.MeasureTheory.Measure.Haar.NormedSpace #align_import analysis.mellin_transform from "leanprover-community/mathlib"@"917c3c072e487b3cccdbfeff17e75b40e45f66cb" open MeasureTheory Set Filter A...
Mathlib/Analysis/MellinTransform.lean
112
114
theorem mellin_const_smul (f : ℝ β†’ E) (s : β„‚) {π•œ : Type*} [NontriviallyNormedField π•œ] [NormedSpace π•œ E] [SMulCommClass β„‚ π•œ E] (c : π•œ) : mellin (fun t => c β€’ f t) s = c β€’ mellin f s := by
simp only [mellin, smul_comm, integral_smul]
[ " MellinConvergent (fun t => c β€’ f t) s", " MellinConvergent (fun t => ↑t ^ a β€’ f t) s ↔ MellinConvergent f (s + a)", " ↑t ^ (s - 1) β€’ (fun t => ↑t ^ a β€’ f t) t = ↑t ^ (s + a - 1) β€’ f t", " MellinConvergent (fun t => f t / a) s", " MellinConvergent (fun t => f (a * t)) s ↔ MellinConvergent f s", " (fun t ...
[ " MellinConvergent (fun t => c β€’ f t) s", " MellinConvergent (fun t => ↑t ^ a β€’ f t) s ↔ MellinConvergent f (s + a)", " ↑t ^ (s - 1) β€’ (fun t => ↑t ^ a β€’ f t) t = ↑t ^ (s + a - 1) β€’ f t", " MellinConvergent (fun t => f t / a) s", " MellinConvergent (fun t => f (a * t)) s ↔ MellinConvergent f s", " (fun t ...
import Mathlib.RingTheory.DedekindDomain.Ideal #align_import ring_theory.dedekind_domain.factorization from "leanprover-community/mathlib"@"2f588be38bb5bec02f218ba14f82fc82eb663f87" noncomputable section open scoped Classical nonZeroDivisors open Set Function UniqueFactorizationMonoid IsDedekindDomain IsDedekind...
Mathlib/RingTheory/DedekindDomain/Factorization.lean
131
144
theorem finprod_not_dvd (I : Ideal R) (hI : I β‰  0) : Β¬v.asIdeal ^ ((Associates.mk v.asIdeal).count (Associates.mk I).factors + 1) ∣ ∏ᢠ v : HeightOneSpectrum R, v.maxPowDividing I := by
have hf := finite_mulSupport hI have h_ne_zero : v.maxPowDividing I β‰  0 := pow_ne_zero _ v.ne_bot rw [← mul_finprod_cond_ne v hf, pow_add, pow_one, finprod_cond_ne _ _ hf] intro h_contr have hv_prime : Prime v.asIdeal := Ideal.prime_of_isPrime v.ne_bot v.isPrime obtain ⟨w, hw, hvw'⟩ := Prime.exists_mem...
[ " {v | v.asIdeal ∣ I}.Finite", " Finite { x // x.asIdeal ∣ I }", " Injective fun v => ⟨(↑v).asIdeal, β‹―βŸ©", " v = w", " βˆ€αΆ  (v : HeightOneSpectrum R) in Filter.cofinite, ↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) = 0", " {v | ¬↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) = 0...
[ " {v | v.asIdeal ∣ I}.Finite", " Finite { x // x.asIdeal ∣ I }", " Injective fun v => ⟨(↑v).asIdeal, β‹―βŸ©", " v = w", " βˆ€αΆ  (v : HeightOneSpectrum R) in Filter.cofinite, ↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) = 0", " {v | ¬↑((Associates.mk v.asIdeal).count (Associates.mk I).factors) = 0...
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
122
122
theorem singleton_prod_singleton : ({a} : Set Ξ±) Γ—Λ’ ({b} : Set Ξ²) = {(a, b)} := by
simp
[ " (βˆƒ 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.Algebra.Field.Defs import Mathlib.Algebra.GroupWithZero.Units.Lemmas import Mathlib.Algebra.Ring.Commute import Mathlib.Algebra.Ring.Invertible import Mathlib.Order.Synonym #align_import algebra.field.basic from "leanprover-community/mathlib"@"05101c3df9d9cfe9430edc205860c79b6d660102" open Function ...
Mathlib/Algebra/Field/Basic.lean
56
58
theorem one_div_mul_add_mul_one_div_eq_one_div_add_one_div (ha : a β‰  0) (hb : b β‰  0) : 1 / a * (a + b) * (1 / b) = 1 / a + 1 / b := by
simpa only [one_div] using (inv_add_inv' ha hb).symm
[ " (a + b) / c = a / c + b / c", " (b + a) / b = 1 + a / b", " (a + b) / b = a / b + 1", " 1 / a * (a + b) * (1 / b) = 1 / a + 1 / b" ]
[ " (a + b) / c = a / c + b / c", " (b + a) / b = 1 + a / b", " (a + b) / b = a / b + 1" ]
import Mathlib.Algebra.Order.Floor import Mathlib.Algebra.Order.Field.Power import Mathlib.Data.Nat.Log #align_import data.int.log from "leanprover-community/mathlib"@"1f0096e6caa61e9c849ec2adbd227e960e9dff58" variable {R : Type*} [LinearOrderedSemifield R] [FloorSemiring R] namespace Int def log (b : β„•) (r : ...
Mathlib/Data/Int/Log.lean
66
70
theorem log_of_right_le_one (b : β„•) {r : R} (hr : r ≀ 1) : log b r = -Nat.clog b ⌈rβ»ΒΉβŒ‰β‚Š := by
obtain rfl | hr := hr.eq_or_lt Β· rw [log, if_pos hr, inv_one, Nat.ceil_one, Nat.floor_one, Nat.log_one_right, Nat.clog_one_right, Int.ofNat_zero, neg_zero] Β· exact if_neg hr.not_le
[ " log b r = -↑(b.clog ⌈rβ»ΒΉβŒ‰β‚Š)", " log b 1 = -↑(b.clog ⌈1β»ΒΉβŒ‰β‚Š)" ]
[]
import Mathlib.Combinatorics.Enumerative.DoubleCounting import Mathlib.Combinatorics.SimpleGraph.AdjMatrix import Mathlib.Combinatorics.SimpleGraph.Basic import Mathlib.Data.Set.Finite #align_import combinatorics.simple_graph.strongly_regular from "leanprover-community/mathlib"@"2b35fc7bea4640cb75e477e83f32fbd5389208...
Mathlib/Combinatorics/SimpleGraph/StronglyRegular.lean
110
113
theorem IsSRGWith.card_neighborFinset_union_of_adj {v w : V} (h : G.IsSRGWith n k β„“ ΞΌ) (ha : G.Adj v w) : (G.neighborFinset v βˆͺ G.neighborFinset w).card = 2 * k - β„“ := by
rw [← h.of_adj v w ha] apply h.card_neighborFinset_union_eq
[ " (fun v w => Β¬βŠ₯.Adj v w β†’ Fintype.card ↑(βŠ₯.commonNeighbors v w) = 0) v w", " filter (fun x => x ∈ βŠ₯.commonNeighbors v w) univ = βˆ…", " a✝ ∈ filter (fun x => x ∈ βŠ₯.commonNeighbors v w) univ ↔ a✝ ∈ βˆ…", " Fintype.card ↑(⊀.commonNeighbors v w) = Fintype.card V - 2", " v β‰  w", " (G.neighborFinset v βˆͺ G.neighbo...
[ " (fun v w => Β¬βŠ₯.Adj v w β†’ Fintype.card ↑(βŠ₯.commonNeighbors v w) = 0) v w", " filter (fun x => x ∈ βŠ₯.commonNeighbors v w) univ = βˆ…", " a✝ ∈ filter (fun x => x ∈ βŠ₯.commonNeighbors v w) univ ↔ a✝ ∈ βˆ…", " Fintype.card ↑(⊀.commonNeighbors v w) = Fintype.card V - 2", " v β‰  w", " (G.neighborFinset v βˆͺ G.neighbo...
import Mathlib.LinearAlgebra.AffineSpace.Basis import Mathlib.LinearAlgebra.Matrix.NonsingularInverse #align_import linear_algebra.affine_space.matrix from "leanprover-community/mathlib"@"2de9c37fa71dde2f1c6feff19876dd6a7b1519f0" open Affine Matrix open Set universe u₁ uβ‚‚ u₃ uβ‚„ variable {ΞΉ : Type u₁} {k : Type...
Mathlib/LinearAlgebra/AffineSpace/Matrix.lean
114
119
theorem toMatrix_vecMul_coords (x : P) : bβ‚‚.coords x α΅₯* b.toMatrix bβ‚‚ = b.coords x := by
ext j change _ = b.coord j x conv_rhs => rw [← bβ‚‚.affineCombination_coord_eq_self x] rw [Finset.map_affineCombination _ _ _ (bβ‚‚.sum_coord_apply_eq_one x)] simp [Matrix.vecMul, Matrix.dotProduct, toMatrix_apply, coords]
[ " b.toMatrix ⇑b = 1", " b.toMatrix (⇑b) i j = 1 i j", " βˆ‘ j : ΞΉ, b.toMatrix q i j = 1", " AffineIndependent k p", " βˆ€ (w1 w2 : ΞΉ' β†’ k),\n βˆ‘ i : ΞΉ', w1 i = 1 β†’\n βˆ‘ i : ΞΉ', w2 i = 1 β†’\n (Finset.affineCombination k Finset.univ p) w1 = (Finset.affineCombination k Finset.univ p) w2 β†’ w1 = w2", "...
[ " b.toMatrix ⇑b = 1", " b.toMatrix (⇑b) i j = 1 i j", " βˆ‘ j : ΞΉ, b.toMatrix q i j = 1", " AffineIndependent k p", " βˆ€ (w1 w2 : ΞΉ' β†’ k),\n βˆ‘ i : ΞΉ', w1 i = 1 β†’\n βˆ‘ i : ΞΉ', w2 i = 1 β†’\n (Finset.affineCombination k Finset.univ p) w1 = (Finset.affineCombination k Finset.univ p) w2 β†’ w1 = w2", "...
import Mathlib.Algebra.CharP.Defs import Mathlib.RingTheory.Multiplicity import Mathlib.RingTheory.PowerSeries.Basic #align_import ring_theory.power_series.basic from "leanprover-community/mathlib"@"2d5739b61641ee4e7e53eca5688a08f66f2e6a60" noncomputable section open Polynomial open Finset (antidiagonal mem_anti...
Mathlib/RingTheory/PowerSeries/Order.lean
134
139
theorem order_eq_nat {Ο† : R⟦X⟧} {n : β„•} : order Ο† = n ↔ coeff R n Ο† β‰  0 ∧ βˆ€ i, i < n β†’ coeff R i Ο† = 0 := by
classical rcases eq_or_ne φ 0 with (rfl | hφ) · simpa [(coeff R _).map_zero] using (PartENat.natCast_ne_top _).symm simp [order, dif_neg hφ, Nat.find_eq_iff]
[ " (βˆƒ n, (coeff R n) Ο† β‰  0) ↔ Ο† β‰  0", " (Β¬βˆƒ n, (coeff R n) Ο† β‰  0) ↔ ¬φ β‰  0", " (βˆ€ (n : β„•), (coeff R n) Ο† = 0) ↔ Ο† = 0", " Ο†.order.Dom ↔ Ο† β‰  0", " (if h : Ο† = 0 then ⊀ else ↑(Nat.find β‹―)).Dom ↔ Ο† β‰  0", " (if h : Ο† = 0 then ⊀ else ↑(Nat.find β‹―)).Dom β†’ Ο† β‰  0", " ⊀.Dom β†’ Ο† β‰  0", " (↑(Nat.find β‹―)).Dom β†’ Ο† β‰ ...
[ " (βˆƒ n, (coeff R n) Ο† β‰  0) ↔ Ο† β‰  0", " (Β¬βˆƒ n, (coeff R n) Ο† β‰  0) ↔ ¬φ β‰  0", " (βˆ€ (n : β„•), (coeff R n) Ο† = 0) ↔ Ο† = 0", " Ο†.order.Dom ↔ Ο† β‰  0", " (if h : Ο† = 0 then ⊀ else ↑(Nat.find β‹―)).Dom ↔ Ο† β‰  0", " (if h : Ο† = 0 then ⊀ else ↑(Nat.find β‹―)).Dom β†’ Ο† β‰  0", " ⊀.Dom β†’ Ο† β‰  0", " (↑(Nat.find β‹―)).Dom β†’ Ο† β‰ ...
import Mathlib.Algebra.Polynomial.Eval import Mathlib.LinearAlgebra.Dimension.Constructions #align_import algebra.linear_recurrence from "leanprover-community/mathlib"@"039a089d2a4b93c761b234f3e5f5aeb752bac60f" noncomputable section open Finset open Polynomial structure LinearRecurrence (Ξ± : Type*) [CommSemir...
Mathlib/Algebra/LinearRecurrence.lean
92
95
theorem mkSol_eq_init (init : Fin E.order β†’ Ξ±) : βˆ€ n : Fin E.order, E.mkSol init n = init n := by
intro n rw [mkSol] simp only [n.is_lt, dif_pos, Fin.mk_val, Fin.eta]
[ " n - E.order + ↑k < n", " ↑k + n < E.order + n", " E.order ≀ ↑k + n", " E.order = 0 + E.order", " E.IsSolution (E.mkSol init)", " E.mkSol init (n + E.order) = βˆ‘ i : Fin E.order, E.coeffs i * E.mkSol init (n + ↑i)", " (if h : n + E.order < E.order then init ⟨n + E.order, h⟩\n else\n βˆ‘ k : Fin E....
[ " n - E.order + ↑k < n", " ↑k + n < E.order + n", " E.order ≀ ↑k + n", " E.order = 0 + E.order", " E.IsSolution (E.mkSol init)", " E.mkSol init (n + E.order) = βˆ‘ i : Fin E.order, E.coeffs i * E.mkSol init (n + ↑i)", " (if h : n + E.order < E.order then init ⟨n + E.order, h⟩\n else\n βˆ‘ k : Fin E....
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
166
169
theorem eq_zero_of_dvd_of_degree_lt {p q : R[X]} (h₁ : p ∣ q) (hβ‚‚ : degree q < degree p) : q = 0 := by
by_contra hc exact (lt_iff_not_ge _ _).mp hβ‚‚ (degree_le_of_dvd h₁ hc)
[ " a✝ = 0 ∨ b✝ = 0", " a✝.leadingCoeff = 0 ∨ b✝.leadingCoeff = 0", " a✝.leadingCoeff * b✝.leadingCoeff = 0", " (p * q).natDegree = p.natDegree + q.natDegree", " (p * q).trailingDegree = p.trailingDegree + q.trailingDegree", " ↑(p.natTrailingDegree + q.natTrailingDegree) = ↑p.natTrailingDegree + ↑q.natTrail...
[ " a✝ = 0 ∨ b✝ = 0", " a✝.leadingCoeff = 0 ∨ b✝.leadingCoeff = 0", " a✝.leadingCoeff * b✝.leadingCoeff = 0", " (p * q).natDegree = p.natDegree + q.natDegree", " (p * q).trailingDegree = p.trailingDegree + q.trailingDegree", " ↑(p.natTrailingDegree + q.natTrailingDegree) = ↑p.natTrailingDegree + ↑q.natTrail...
import Mathlib.Algebra.ContinuedFractions.Computation.Basic import Mathlib.Algebra.ContinuedFractions.Translations #align_import algebra.continued_fractions.computation.translations from "leanprover-community/mathlib"@"a7e36e48519ab281320c4d192da6a7b348ce40ad" namespace GeneralizedContinuedFraction open Generali...
Mathlib/Algebra/ContinuedFractions/Computation/Translations.lean
209
212
theorem of_terminatedAt_n_iff_succ_nth_intFractPair_stream_eq_none : (of v).TerminatedAt n ↔ IntFractPair.stream v (n + 1) = none := by
rw [of_terminatedAt_iff_intFractPair_seq1_terminatedAt, Stream'.Seq.TerminatedAt, IntFractPair.get?_seq1_eq_succ_get?_stream]
[ " (of v).TerminatedAt n ↔ IntFractPair.stream v (n + 1) = none" ]
[]