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 221 |
|---|---|---|---|---|---|---|---|
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 | 81 | 84 | theorem add_den_dvd (qβ qβ : β) : (qβ + qβ).den β£ qβ.den * qβ.den := by |
rw [add_def, normalize_eq]
apply Nat.div_dvd_of_dvd
apply Nat.gcd_dvd_right
| [
" (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.Algebra.BigOperators.Ring
import Mathlib.Data.Fintype.BigOperators
import Mathlib.Data.Fintype.Fin
import Mathlib.GroupTheory.GroupAction.Pi
import Mathlib.Logic.Equiv.Fin
#align_import algebra.big_operators.fin from "leanprover-community/mathlib"@"cc5dd6244981976cc9da7afc4eee5682b037a013"
open Fins... | Mathlib/Algebra/BigOperators/Fin.lean | 69 | 72 | theorem prod_univ_succAbove [CommMonoid Ξ²] {n : β} (f : Fin (n + 1) β Ξ²) (x : Fin (n + 1)) :
β i, f i = f x * β i : Fin n, f (x.succAbove i) := by |
rw [univ_succAbove, prod_cons, Finset.prod_map _ x.succAboveEmb]
rfl
| [
" (List.ofFn f).prod = β i : Fin n, f i",
" β i : Fin n, f i = (List.map f (List.finRange n)).prod",
" β i : Fin (n + 1), f i = f x * β i : Fin n, f (x.succAbove i)",
" f x * β x_1 : Fin n, f (x.succAboveEmb x_1) = f x * β i : Fin n, f (x.succAbove i)"
] | [
" (List.ofFn f).prod = β i : Fin n, f i",
" β i : Fin n, f i = (List.map f (List.finRange n)).prod",
" β i : Fin (n + 1), f i = f x * β i : Fin n, f (x.succAbove i)"
] |
import Mathlib.Algebra.FreeMonoid.Basic
import Mathlib.Algebra.Group.Submonoid.MulOpposite
import Mathlib.Algebra.Group.Submonoid.Operations
import Mathlib.Algebra.GroupWithZero.Divisibility
import Mathlib.Data.Finset.NoncommProd
import Mathlib.Data.Int.Order.Lemmas
#align_import group_theory.submonoid.membership fro... | Mathlib/Algebra/Group/Submonoid/Membership.lean | 332 | 333 | theorem mem_closure_singleton {x y : M} : y β closure ({x} : Set M) β β n : β, x ^ n = y := by |
rw [closure_singleton_eq, mem_mrange]; rfl
| [
" y β closure {x} β β n, x ^ n = y",
" (β x_1, ((powersHom M) x) x_1 = y) β β n, x ^ n = y"
] | [
" y β closure {x} β β n, x ^ n = y"
] |
import Mathlib.Algebra.MonoidAlgebra.Basic
import Mathlib.LinearAlgebra.Basis.VectorSpace
import Mathlib.RingTheory.SimpleModule
#align_import representation_theory.maschke from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a"
universe u v w
noncomputable section
open Module MonoidAlgeb... | Mathlib/RepresentationTheory/Maschke.lean | 125 | 127 | theorem equivariantProjection_apply (v : W) :
Ο.equivariantProjection G v = β
(Fintype.card G : k) β’ β g : G, Ο.conjugate g v := by |
simp only [equivariantProjection, smul_apply, sumOfConjugatesEquivariant_apply]
| [
" (Ο.conjugate g) (i v) = v",
" (sumOfConjugates G Ο) (MonoidAlgebra.single g 1 β’ v) = MonoidAlgebra.single g 1 β’ (sumOfConjugates G Ο) v",
" β x : G, MonoidAlgebra.single xβ»ΒΉ 1 β’ Ο (MonoidAlgebra.single x 1 β’ MonoidAlgebra.single g 1 β’ v) =\n β x : G, MonoidAlgebra.single g 1 β’ MonoidAlgebra.single xβ»ΒΉ 1 β’ ... | [
" (Ο.conjugate g) (i v) = v",
" (sumOfConjugates G Ο) (MonoidAlgebra.single g 1 β’ v) = MonoidAlgebra.single g 1 β’ (sumOfConjugates G Ο) v",
" β x : G, MonoidAlgebra.single xβ»ΒΉ 1 β’ Ο (MonoidAlgebra.single x 1 β’ MonoidAlgebra.single g 1 β’ v) =\n β x : G, MonoidAlgebra.single g 1 β’ MonoidAlgebra.single xβ»ΒΉ 1 β’ ... |
import Mathlib.Analysis.Complex.RealDeriv
import Mathlib.Analysis.Calculus.ContDiff.RCLike
import Mathlib.Analysis.Calculus.IteratedDeriv.Lemmas
#align_import analysis.special_functions.exp_deriv from "leanprover-community/mathlib"@"6a5c85000ab93fe5dcfdf620676f614ba8e18c26"
noncomputable section
open Filter Asym... | Mathlib/Analysis/SpecialFunctions/ExpDeriv.lean | 64 | 73 | theorem contDiff_exp : β {n}, ContDiff π n exp := by |
-- Porting note: added `@` due to `β {n}` weirdness above
refine @(contDiff_all_iff_nat.2 fun n => ?_)
have : ContDiff β (βn) exp := by
induction' n with n ihn
Β· exact contDiff_zero.2 continuous_exp
Β· rw [contDiff_succ_iff_deriv]
use differentiable_exp
rwa [deriv_exp]
exact this.restric... | [
" HasDerivAt cexp (cexp x) x",
" (fun h => cexp (x + h) - cexp x - h β’ cexp x) =o[π 0] fun h => h",
" 1 < 2",
" βαΆ (x_1 : β) in π 0, βcexp (x + x_1) - cexp x - x_1 β’ cexp xβ β€ βcexp xβ * βx_1 ^ 2β",
" β a β Metric.ball 0 1, βcexp (x + a) - cexp x - a β’ cexp xβ β€ βcexp xβ * βa ^ 2β",
" β (a : β), βaβ < 1... | [
" HasDerivAt cexp (cexp x) x",
" (fun h => cexp (x + h) - cexp x - h β’ cexp x) =o[π 0] fun h => h",
" 1 < 2",
" βαΆ (x_1 : β) in π 0, βcexp (x + x_1) - cexp x - x_1 β’ cexp xβ β€ βcexp xβ * βx_1 ^ 2β",
" β a β Metric.ball 0 1, βcexp (x + a) - cexp x - a β’ cexp xβ β€ βcexp xβ * βa ^ 2β",
" β (a : β), βaβ < 1... |
import Mathlib.Algebra.GCDMonoid.Finset
import Mathlib.Algebra.Polynomial.CancelLeads
import Mathlib.Algebra.Polynomial.EraseLead
import Mathlib.Algebra.Polynomial.FieldDivision
#align_import ring_theory.polynomial.content from "leanprover-community/mathlib"@"7a030ab8eb5d99f05a891dccc49c5b5b90c947d3"
namespace Po... | Mathlib/RingTheory/Polynomial/Content.lean | 109 | 129 | theorem content_X_mul {p : R[X]} : content (X * p) = content p := by |
rw [content, content, Finset.gcd_def, Finset.gcd_def]
refine congr rfl ?_
have h : (X * p).support = p.support.map β¨Nat.succ, Nat.succ_injectiveβ© := by
ext a
simp only [exists_prop, Finset.mem_map, Function.Embedding.coeFn_mk, Ne, mem_support_iff]
cases' a with a
Β· simp [coeff_X_mul_zero, Nat.suc... | [
" p.content β£ p.coeff n",
" p.content β£ 0",
" (C r).content = normalize r",
" (C r).support.gcd (C r).coeff = normalize r",
" content 0 = 0",
" content 1 = 1",
" (X * p).content = p.content",
" (Multiset.map (X * p).coeff (X * p).support.val).gcd = (Multiset.map p.coeff p.support.val).gcd",
" Multis... | [
" p.content β£ p.coeff n",
" p.content β£ 0",
" (C r).content = normalize r",
" (C r).support.gcd (C r).coeff = normalize r",
" content 0 = 0",
" content 1 = 1",
" (X * p).content = p.content"
] |
import Mathlib.Algebra.Category.GroupCat.Basic
import Mathlib.CategoryTheory.Limits.Shapes.ZeroObjects
#align_import algebra.category.Group.zero from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a"
open CategoryTheory
open CategoryTheory.Limits
universe u
namespace GroupCat
@[to_addi... | Mathlib/Algebra/Category/GroupCat/Zero.lean | 28 | 34 | theorem isZero_of_subsingleton (G : GroupCat) [Subsingleton G] : IsZero G := by |
refine β¨fun X => β¨β¨β¨1β©, fun f => ?_β©β©, fun X => β¨β¨β¨1β©, fun f => ?_β©β©β©
Β· ext x
have : x = 1 := Subsingleton.elim _ _
rw [this, map_one, map_one]
Β· ext
apply Subsingleton.elim
| [
" IsZero G",
" f = default",
" f x = default x",
" f xβ = default xβ"
] | [
" IsZero G"
] |
import Mathlib.Algebra.Quaternion
import Mathlib.Tactic.Ring
#align_import algebra.quaternion_basis from "leanprover-community/mathlib"@"3aa5b8a9ed7a7cabd36e6e1d022c9858ab8a8c2d"
open Quaternion
namespace QuaternionAlgebra
structure Basis {R : Type*} (A : Type*) [CommRing R] [Ring A] [Algebra R A] (cβ cβ : R) ... | Mathlib/Algebra/QuaternionBasis.lean | 104 | 106 | theorem k_mul_k : q.k * q.k = -((cβ * cβ) β’ (1 : A)) := by |
rw [β i_mul_j, mul_assoc, β mul_assoc q.j _ _, j_mul_i, β i_mul_j, β mul_assoc, mul_neg, β
mul_assoc, i_mul_i, smul_mul_assoc, one_mul, neg_mul, smul_mul_assoc, j_mul_j, smul_smul]
| [
" qβ = qβ",
" { i := iβ, j := jβ, k := kβ, i_mul_i := i_mul_iβ, j_mul_j := j_mul_jβ, i_mul_j := i_mul_jβ, j_mul_i := j_mul_iβ } = qβ",
" { i := iβ, j := jβ, k := kβ, i_mul_i := i_mul_iβ, j_mul_j := j_mul_jβ, i_mul_j := qβ_i_mul_j, j_mul_i := j_mul_iβ } =\n qβ",
" { i := iβΒΉ, j := jβΒΉ, k := kβΒΉ, i_mul_i := ... | [
" qβ = qβ",
" { i := iβ, j := jβ, k := kβ, i_mul_i := i_mul_iβ, j_mul_j := j_mul_jβ, i_mul_j := i_mul_jβ, j_mul_i := j_mul_iβ } = qβ",
" { i := iβ, j := jβ, k := kβ, i_mul_i := i_mul_iβ, j_mul_j := j_mul_jβ, i_mul_j := qβ_i_mul_j, j_mul_i := j_mul_iβ } =\n qβ",
" { i := iβΒΉ, j := jβΒΉ, k := kβΒΉ, i_mul_i := ... |
import Mathlib.SetTheory.Ordinal.FixedPoint
#align_import set_theory.ordinal.principal from "leanprover-community/mathlib"@"31b269b60935483943542d547a6dd83a66b37dc7"
universe u v w
noncomputable section
open Order
namespace Ordinal
-- Porting note: commented out, doesn't seem necessary
--local infixr:0 "^" => ... | Mathlib/SetTheory/Ordinal/Principal.lean | 62 | 66 | theorem principal_one_iff {op : Ordinal β Ordinal β Ordinal} : Principal op 1 β op 0 0 = 0 := by |
refine β¨fun h => ?_, fun h a b ha hb => ?_β©
Β· rw [β lt_one_iff_zero]
exact h zero_lt_one zero_lt_one
Β· rwa [lt_one_iff_zero, ha, hb] at *
| [
" Principal op o β Principal (Function.swap op) o",
" Principal op o β Principal (Function.swap op) o",
" Principal (Function.swap op) o β Principal op o",
" Principal op 1 β op 0 0 = 0",
" op 0 0 = 0",
" op 0 0 < 1",
" op a b < 1"
] | [
" Principal op o β Principal (Function.swap op) o",
" Principal op o β Principal (Function.swap op) o",
" Principal (Function.swap op) o β Principal op o",
" Principal op 1 β op 0 0 = 0"
] |
import Mathlib.Algebra.DualNumber
import Mathlib.Algebra.QuaternionBasis
import Mathlib.Data.Complex.Module
import Mathlib.LinearAlgebra.CliffordAlgebra.Conjugation
import Mathlib.LinearAlgebra.CliffordAlgebra.Star
import Mathlib.LinearAlgebra.QuadraticForm.Prod
#align_import linear_algebra.clifford_algebra.equivs fr... | Mathlib/LinearAlgebra/CliffordAlgebra/Equivs.lean | 223 | 228 | theorem reverse_apply (x : CliffordAlgebra Q) : reverse (R := β) x = x := by |
induction x using CliffordAlgebra.induction with
| algebraMap r => exact reverse.commutes _
| ΞΉ x => rw [reverse_ΞΉ]
| mul xβ xβ hxβ hxβ => rw [reverse.map_mul, mul_comm, hxβ, hxβ]
| add xβ xβ hxβ hxβ => rw [reverse.map_add, hxβ, hxβ]
| [
" (LinearMap.toSpanSingleton β β Complex.I) r * (LinearMap.toSpanSingleton β β Complex.I) r = (algebraMap β β) (Q r)",
" βr * Complex.I * (βr * Complex.I) = β(-(r * r))",
" βr * βr * (Complex.I * Complex.I) = β(-(r * r))",
" toComplex (involute c) = (starRingEnd β) (toComplex c)",
" toComplex (involute ((ΞΉ ... | [
" (LinearMap.toSpanSingleton β β Complex.I) r * (LinearMap.toSpanSingleton β β Complex.I) r = (algebraMap β β) (Q r)",
" βr * Complex.I * (βr * Complex.I) = β(-(r * r))",
" βr * βr * (Complex.I * Complex.I) = β(-(r * r))",
" toComplex (involute c) = (starRingEnd β) (toComplex c)",
" toComplex (involute ((ΞΉ ... |
import Mathlib.Algebra.Group.Subgroup.Basic
import Mathlib.Data.Fintype.Card
import Mathlib.Data.Set.Finite
import Mathlib.Data.Set.Pointwise.SMul
import Mathlib.Data.Setoid.Basic
import Mathlib.GroupTheory.GroupAction.Defs
import Mathlib.GroupTheory.GroupAction.Group
#align_import group_theory.group_action.basic fro... | Mathlib/GroupTheory/GroupAction/Basic.lean | 312 | 317 | theorem smul_cancel_of_non_zero_divisor {M R : Type*} [Monoid M] [NonUnitalNonAssocRing R]
[DistribMulAction M R] (k : M) (h : β x : R, k β’ x = 0 β x = 0) {a b : R} (h' : k β’ a = k β’ b) :
a = b := by |
rw [β sub_eq_zero]
refine h _ ?_
rw [smul_sub, h', sub_self]
| [
" a = b",
" a - b = 0",
" k β’ (a - b) = 0"
] | [
" a = b"
] |
import Mathlib.Data.Fintype.Basic
import Mathlib.Data.Finset.Card
import Mathlib.Data.List.NodupEquivFin
import Mathlib.Data.Set.Image
#align_import data.fintype.card from "leanprover-community/mathlib"@"bf2428c9486c407ca38b5b3fb10b87dad0bc99fa"
assert_not_exists MonoidWithZero
assert_not_exists MulAction
open Fu... | Mathlib/Data/Fintype/Card.lean | 139 | 140 | theorem card_of_finset' {p : Set Ξ±} (s : Finset Ξ±) (H : β x, x β s β x β p) [Fintype p] :
Fintype.card p = s.card := by | rw [β card_ofFinset s H]; congr; apply Subsingleton.elim
| [
" Trunc (Ξ± β Fin (card Ξ±))",
" Trunc (Ξ± β Fin (Multiset.card univ.val))",
" Trunc { f // Bijective f }",
" card { x // p x } = s.card",
" card { x // p x } = card { x // p x }",
" instβ = Fintype.subtype s H",
" card βp = s.card",
" card βp = card βp",
" instβ = ofFinset s H"
] | [
" Trunc (Ξ± β Fin (card Ξ±))",
" Trunc (Ξ± β Fin (Multiset.card univ.val))",
" Trunc { f // Bijective f }",
" card { x // p x } = s.card",
" card { x // p x } = card { x // p x }",
" instβ = Fintype.subtype s H",
" card βp = s.card"
] |
import Mathlib.Data.W.Basic
#align_import data.pfunctor.univariate.basic from "leanprover-community/mathlib"@"8631e2d5ea77f6c13054d9151d82b83069680cb1"
-- "W", "Idx"
set_option linter.uppercaseLean3 false
universe u v vβ vβ vβ
@[pp_with_univ]
structure PFunctor where
A : Type u
B : A β Type u
#align p... | Mathlib/Data/PFunctor/Univariate/Basic.lean | 158 | 162 | theorem iget_map [DecidableEq P.A] [Inhabited Ξ±] [Inhabited Ξ²] (x : P Ξ±)
(f : Ξ± β Ξ²) (i : P.Idx) (h : i.1 = x.1) : (P.map f x).iget i = f (x.iget i) := by |
simp only [Obj.iget, fst_map, *, dif_pos, eq_self_iff_true]
cases x
rfl
| [
" (mk p).dest = p",
" (mk β¨fstβ, sndββ©).dest = β¨fstβ, sndββ©",
" mk p.dest = p",
" mk (dest (WType.mk aβ fβ)) = WType.mk aβ fβ",
" (P.map f x).fst = x.fst",
" (P.map f β¨fstβ, sndββ©).fst = β¨fstβ, sndββ©.fst",
" (P.map f x).iget i = f (x.iget i)",
" (P.map f x).snd (cast β― i.snd) = f (x.snd (cast β― i.snd)... | [
" (mk p).dest = p",
" (mk β¨fstβ, sndββ©).dest = β¨fstβ, sndββ©",
" mk p.dest = p",
" mk (dest (WType.mk aβ fβ)) = WType.mk aβ fβ",
" (P.map f x).fst = x.fst",
" (P.map f β¨fstβ, sndββ©).fst = β¨fstβ, sndββ©.fst",
" (P.map f x).iget i = f (x.iget i)"
] |
import Mathlib.Probability.Martingale.Upcrossing
import Mathlib.MeasureTheory.Function.UniformIntegrable
import Mathlib.MeasureTheory.Constructions.Polish
#align_import probability.martingale.convergence from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982"
open TopologicalSpace Filter Me... | Mathlib/Probability/Martingale/Convergence.lean | 110 | 127 | theorem not_frequently_of_upcrossings_lt_top (hab : a < b) (hΟ : upcrossings a b f Ο β β) :
Β¬((βαΆ n in atTop, f n Ο < a) β§ βαΆ n in atTop, b < f n Ο) := by |
rw [β lt_top_iff_ne_top, upcrossings_lt_top_iff] at hΟ
replace hΟ : β k, β N, upcrossingsBefore a b f N Ο < k := by
obtain β¨k, hkβ© := hΟ
exact β¨k + 1, fun N => lt_of_le_of_lt (hk N) k.lt_succ_selfβ©
rintro β¨hβ, hββ©
rw [frequently_atTop] at hβ hβ
refine Classical.not_not.2 hΟ ?_
push_neg
intro k
... | [
" Β¬((βαΆ (n : β) in atTop, f n Ο < a) β§ βαΆ (n : β) in atTop, b < f n Ο)",
" β k, β (N : β), upcrossingsBefore a b f N Ο < k",
" False",
" Β¬β k, β (N : β), upcrossingsBefore a b f N Ο < k",
" β (k : β), β N, k β€ upcrossingsBefore a b f N Ο",
" β N, k β€ upcrossingsBefore a b f N Ο",
" β N, 0 β€ upcrossingsB... | [
" Β¬((βαΆ (n : β) in atTop, f n Ο < a) β§ βαΆ (n : β) in atTop, b < f n Ο)"
] |
import Mathlib.CategoryTheory.EqToHom
#align_import category_theory.sums.basic from "leanprover-community/mathlib"@"dc6c365e751e34d100e80fe6e314c3c3e0fd2988"
namespace CategoryTheory
universe vβ uβ
-- morphism levels before object levels. See note [category_theory universes].
open Sum
section
variable (C : Ty... | Mathlib/CategoryTheory/Sums/Basic.lean | 66 | 67 | theorem hom_inr_inl_false {X : C} {Y : D} (f : Sum.inr X βΆ Sum.inl Y) : False := by |
cases f
| [
" False"
] | [
" False"
] |
import Mathlib.Combinatorics.Quiver.Basic
#align_import combinatorics.quiver.push from "leanprover-community/mathlib"@"2258b40dacd2942571c8ce136215350c702dc78f"
namespace Quiver
universe v vβ vβ u uβ uβ
variable {V : Type*} [Quiver V] {W : Type*} (Ο : V β W)
@[nolint unusedArguments]
def Push (_ : V β W) :=
... | Mathlib/Combinatorics/Quiver/Push.lean | 73 | 89 | theorem lift_comp : (of Ο βq lift Ο Ο Ο h) = Ο := by |
fapply Prefunctor.ext
Β· rintro X
simp only [Prefunctor.comp_obj]
apply Eq.symm
exact h X
Β· rintro X Y f
simp only [Prefunctor.comp_map]
apply eq_of_heq
iterate 2 apply (cast_heq _ _).trans
apply HEq.symm
apply (eqRec_heq _ _).trans
have : β {Ξ± Ξ³} {Ξ² : Ξ± β Ξ³ β Sort _} {a a'} (p... | [
" (fun X Y x => Ο X βΆ Ο Y) (Ο X) (Ο Y) (PushQuiver.arrow f)",
" Ο (Ο X) βΆ Ο (Ο Y)",
" Ο.obj X βΆ Ο.obj Y",
" of Ο βq lift Ο Ο Ο h = Ο",
" β (X : V), (of Ο βq lift Ο Ο Ο h).obj X = Ο.obj X",
" (of Ο βq lift Ο Ο Ο h).obj X = Ο.obj X",
" (lift Ο Ο Ο h).obj ((of Ο).obj X) = Ο.obj X",
" Ο.obj X = (lift Ο Ο ... | [
" (fun X Y x => Ο X βΆ Ο Y) (Ο X) (Ο Y) (PushQuiver.arrow f)",
" Ο (Ο X) βΆ Ο (Ο Y)",
" Ο.obj X βΆ Ο.obj Y",
" of Ο βq lift Ο Ο Ο h = Ο"
] |
import Mathlib.Analysis.Calculus.ContDiff.Defs
import Mathlib.Analysis.Calculus.MeanValue
#align_import analysis.calculus.cont_diff from "leanprover-community/mathlib"@"3bce8d800a6f2b8f63fe1e588fd76a9ff4adcebe"
noncomputable section
open Set Fin Filter Function
open scoped NNReal Topology
section Real
variab... | Mathlib/Analysis/Calculus/ContDiff/RCLike.lean | 87 | 101 | theorem HasFTaylorSeriesUpToOn.exists_lipschitzOnWith_of_nnnorm_lt {E F : Type*}
[NormedAddCommGroup E] [NormedSpace β E] [NormedAddCommGroup F] [NormedSpace β F] {f : E β F}
{p : E β FormalMultilinearSeries β E F} {s : Set E} {x : E}
(hf : HasFTaylorSeriesUpToOn 1 f p (insert x s)) (hs : Convex β s) (K : β... |
set f' := fun y => continuousMultilinearCurryFin1 β E F (p y 1)
have hder : β y β s, HasFDerivWithinAt f (f' y) s y := fun y hy =>
(hf.hasFDerivWithinAt le_rfl (subset_insert x s hy)).mono (subset_insert x s)
have hcont : ContinuousWithinAt f' s x :=
(continuousMultilinearCurryFin1 β E F).continuousAt.co... | [
" HasStrictFDerivAt f f' x",
" β t β π[s] x, LipschitzOnWith K f t",
" βf' xββ < K"
] | [
" HasStrictFDerivAt f f' x",
" β t β π[s] x, LipschitzOnWith K f t"
] |
import Mathlib.Algebra.BigOperators.Group.Finset
import Mathlib.Data.List.MinMax
import Mathlib.Algebra.Tropical.Basic
import Mathlib.Order.ConditionallyCompleteLattice.Finset
#align_import algebra.tropical.big_operators from "leanprover-community/mathlib"@"d6fad0e5bf2d6f48da9175d25c3dc5706b3834ce"
variable {R S :... | Mathlib/Algebra/Tropical/BigOperators.lean | 106 | 108 | theorem trop_iInf [ConditionallyCompleteLinearOrder R] [Fintype S] (f : S β WithTop R) :
trop (β¨
i : S, f i) = β i : S, trop (f i) := by |
rw [iInf, β Set.image_univ, β coe_univ, trop_sInf_image]
| [
" trop l.sum = (map trop l).prod",
" trop [].sum = (map trop []).prod",
" trop (hd :: tl).sum = (map trop (hd :: tl)).prod",
" β (a : List R), trop (sum β¦aβ§) = (map trop β¦aβ§).prod",
" trop (β i β s, f i) = β i β s, trop (f i)",
" β i β s, trop (f i) = (Multiset.map trop (Multiset.map f s.val)).prod",
" ... | [
" trop l.sum = (map trop l).prod",
" trop [].sum = (map trop []).prod",
" trop (hd :: tl).sum = (map trop (hd :: tl)).prod",
" β (a : List R), trop (sum β¦aβ§) = (map trop β¦aβ§).prod",
" trop (β i β s, f i) = β i β s, trop (f i)",
" β i β s, trop (f i) = (Multiset.map trop (Multiset.map f s.val)).prod",
" ... |
import Mathlib.Analysis.Complex.Basic
import Mathlib.Topology.FiberBundle.IsHomeomorphicTrivialBundle
#align_import analysis.complex.re_im_topology from "leanprover-community/mathlib"@"468b141b14016d54b479eb7a0fff1e360b7e3cf6"
open Set
noncomputable section
namespace Complex
theorem isHomeomorphicTrivialFiber... | Mathlib/Analysis/Complex/ReImTopology.lean | 114 | 115 | theorem closure_setOf_re_lt (a : β) : closure { z : β | z.re < a } = { z | z.re β€ a } := by |
simpa only [closure_Iio] using closure_preimage_re (Iio a)
| [
" interior {z | z.re β€ a} = {z | z.re < a}",
" interior {z | z.im β€ a} = {z | z.im < a}",
" interior {z | a β€ z.re} = {z | a < z.re}",
" interior {z | a β€ z.im} = {z | a < z.im}",
" closure {z | z.re < a} = {z | z.re β€ a}"
] | [
" interior {z | z.re β€ a} = {z | z.re < a}",
" interior {z | z.im β€ a} = {z | z.im < a}",
" interior {z | a β€ z.re} = {z | a < z.re}",
" interior {z | a β€ z.im} = {z | a < z.im}",
" closure {z | z.re < a} = {z | z.re β€ a}"
] |
import Mathlib.RingTheory.Ideal.QuotientOperations
import Mathlib.RingTheory.Localization.Basic
#align_import ring_theory.localization.ideal from "leanprover-community/mathlib"@"e7f0ddbf65bd7181a85edb74b64bdc35ba4bdc74"
namespace IsLocalization
section CommRing
variable {R : Type*} [CommRing R] (M : Submonoid R... | Mathlib/RingTheory/Localization/Ideal.lean | 171 | 204 | theorem surjective_quotientMap_of_maximal_of_localization {I : Ideal S} [I.IsPrime] {J : Ideal R}
{H : J β€ I.comap (algebraMap R S)} (hI : (I.comap (algebraMap R S)).IsMaximal) :
Function.Surjective (Ideal.quotientMap I (algebraMap R S) H) := by |
intro s
obtain β¨s, rflβ© := Ideal.Quotient.mk_surjective s
obtain β¨r, β¨m, hmβ©, rflβ© := mk'_surjective M s
by_cases hM : (Ideal.Quotient.mk (I.comap (algebraMap R S))) m = 0
Β· have : I = β€ := by
rw [Ideal.eq_top_iff_one]
rw [Ideal.Quotient.eq_zero_iff_mem, Ideal.mem_comap] at hM
convert I.mul... | [
" Function.Surjective β(Ideal.quotientMap I (algebraMap R S) H)",
" β a, (Ideal.quotientMap I (algebraMap R S) H) a = s",
" β a, (Ideal.quotientMap I (algebraMap R S) H) a = (Ideal.Quotient.mk I) s",
" β a, (Ideal.quotientMap I (algebraMap R S) H) a = (Ideal.Quotient.mk I) (mk' S r β¨m, hmβ©)",
" I = β€",
" ... | [
" Function.Surjective β(Ideal.quotientMap I (algebraMap R S) H)"
] |
import Mathlib.Algebra.Polynomial.Eval
#align_import data.polynomial.degree.lemmas from "leanprover-community/mathlib"@"728baa2f54e6062c5879a3e397ac6bac323e506f"
noncomputable section
open Polynomial
open Finsupp Finset
namespace Polynomial
universe u v w
variable {R : Type u} {S : Type v} {ΞΉ : Type w} {a b ... | Mathlib/Algebra/Polynomial/Degree/Lemmas.lean | 426 | 431 | theorem irreducible_mul_leadingCoeff_inv {p : K[X]} :
Irreducible (p * C (leadingCoeff p)β»ΒΉ) β Irreducible p := by |
by_cases hp0 : p = 0
Β· simp [hp0]
exact irreducible_mul_isUnit
(isUnit_C.mpr (IsUnit.mk0 _ (inv_ne_zero (leadingCoeff_ne_zero.mpr hp0))))
| [
" Irreducible (p * C p.leadingCoeffβ»ΒΉ) β Irreducible p"
] | [
" Irreducible (p * C p.leadingCoeffβ»ΒΉ) β Irreducible p"
] |
import Mathlib.Algebra.GroupWithZero.NonZeroDivisors
import Mathlib.Algebra.Polynomial.Lifts
import Mathlib.GroupTheory.MonoidLocalization
import Mathlib.RingTheory.Algebraic
import Mathlib.RingTheory.Ideal.LocalRing
import Mathlib.RingTheory.IntegralClosure
import Mathlib.RingTheory.Localization.FractionRing
import M... | Mathlib/RingTheory/Localization/Integral.lean | 80 | 90 | theorem integerNormalization_spec (p : S[X]) :
β b : M, β i, algebraMap R S ((integerNormalization M p).coeff i) = (b : R) β’ p.coeff i := by |
use Classical.choose (exist_integer_multiples_of_finset M (p.support.image p.coeff))
intro i
rw [integerNormalization_coeff, coeffIntegerNormalization]
split_ifs with hi
Β· exact
Classical.choose_spec
(Classical.choose_spec (exist_integer_multiples_of_finset M (p.support.image p.coeff))
... | [
" coeffIntegerNormalization M p i = 0",
" i β p.support",
" Β¬coeffIntegerNormalization M p i β 0",
" (integerNormalization M p).coeff i = coeffIntegerNormalization M p i",
" β b, β (i : β), (algebraMap R S) ((integerNormalization M p).coeff i) = βb β’ p.coeff i",
" β (i : β), (algebraMap R S) ((integerNorm... | [
" coeffIntegerNormalization M p i = 0",
" i β p.support",
" Β¬coeffIntegerNormalization M p i β 0",
" (integerNormalization M p).coeff i = coeffIntegerNormalization M p i",
" β b, β (i : β), (algebraMap R S) ((integerNormalization M p).coeff i) = βb β’ p.coeff i"
] |
import Mathlib.Algebra.Order.Monoid.Defs
import Mathlib.Algebra.Order.Sub.Defs
import Mathlib.Util.AssertExists
#align_import algebra.order.group.defs from "leanprover-community/mathlib"@"b599f4e4e5cf1fbcb4194503671d3d9e569c1fce"
open Function
universe u
variable {Ξ± : Type u}
class OrderedAddCommGroup (Ξ± : Ty... | Mathlib/Algebra/Order/Group/Defs.lean | 389 | 389 | theorem inv_lt' : aβ»ΒΉ < b β bβ»ΒΉ < a := by | rw [β inv_lt_inv_iff, inv_inv]
| [
" b β€ c",
" aβ»ΒΉ < bβ»ΒΉ β b < a",
" a * aβ»ΒΉ * b < a * bβ»ΒΉ * b β b < a",
" aβ»ΒΉ < b β bβ»ΒΉ < a"
] | [
" b β€ c",
" aβ»ΒΉ < bβ»ΒΉ β b < a",
" a * aβ»ΒΉ * b < a * bβ»ΒΉ * b β b < a",
" aβ»ΒΉ < b β bβ»ΒΉ < a"
] |
import Mathlib.CategoryTheory.Opposites
#align_import category_theory.eq_to_hom from "leanprover-community/mathlib"@"dc6c365e751e34d100e80fe6e314c3c3e0fd2988"
universe vβ vβ vβ uβ uβ uβ
-- morphism levels before object levels. See note [CategoryTheory universes].
namespace CategoryTheory
open Opposite
variable ... | Mathlib/CategoryTheory/EqToHom.lean | 86 | 89 | theorem eqToHom_iso_hom_naturality {f g : Ξ² β C} (z : β b, f b β
g b) {j j' : Ξ²} (w : j = j') :
(z j).hom β« eqToHom (by simp [w]) = eqToHom (by simp [w]) β« (z j').hom := by |
cases w
simp
| [
" X βΆ Y",
" Y βΆ Y",
" eqToHom p β« eqToHom q = eqToHom β―",
" eqToHom β― β« eqToHom q = eqToHom β―",
" eqToHom β― β« eqToHom β― = eqToHom β―",
" f = (f β« eqToHom p) β« eqToHom β―",
" f β« eqToHom p = g",
" g = eqToHom β― β« eqToHom p β« g",
" eqToHom p β« eqToHom β― β« f = f",
" g j = g j'",
" f j = f j'",
" z ... | [
" X βΆ Y",
" Y βΆ Y",
" eqToHom p β« eqToHom q = eqToHom β―",
" eqToHom β― β« eqToHom q = eqToHom β―",
" eqToHom β― β« eqToHom β― = eqToHom β―",
" f = (f β« eqToHom p) β« eqToHom β―",
" f β« eqToHom p = g",
" g = eqToHom β― β« eqToHom p β« g",
" eqToHom p β« eqToHom β― β« f = f",
" g j = g j'",
" f j = f j'",
" z ... |
import Mathlib.Analysis.Normed.Group.Hom
import Mathlib.Analysis.NormedSpace.Basic
import Mathlib.Analysis.NormedSpace.LinearIsometry
import Mathlib.Algebra.Star.SelfAdjoint
import Mathlib.Algebra.Star.Subalgebra
import Mathlib.Algebra.Star.Unitary
import Mathlib.Topology.Algebra.Module.Star
#align_import analysis.no... | Mathlib/Analysis/NormedSpace/Star/Basic.lean | 149 | 150 | theorem mul_star_self_ne_zero_iff (x : E) : x * xβ β 0 β x β 0 := by |
simp only [Ne, mul_star_self_eq_zero_iff]
| [
" βxβ * xβ = βxβ * βxβ",
" β (x : E), βxββ = βxβ",
" βxββ = βxβ",
" βxββ * βxββ = βx * xββ",
" βx * xββ = βxβ * βxβ",
" βxββ * xββ = βxβ * βxβ",
" βxβ * xβ = βxββ * βxβ",
" xβ * x = 0 β x = 0",
" βxβ * βxβ = 0 β x = 0",
" xβ * x β 0 β x β 0",
" x * xβ = 0 β x = 0",
" x * xβ β 0 β x β 0"
] | [
" βxβ * xβ = βxβ * βxβ",
" β (x : E), βxββ = βxβ",
" βxββ = βxβ",
" βxββ * βxββ = βx * xββ",
" βx * xββ = βxβ * βxβ",
" βxββ * xββ = βxβ * βxβ",
" βxβ * xβ = βxββ * βxβ",
" xβ * x = 0 β x = 0",
" βxβ * βxβ = 0 β x = 0",
" xβ * x β 0 β x β 0",
" x * xβ = 0 β x = 0",
" x * xβ β 0 β x β 0"
] |
import Mathlib.Algebra.ContinuedFractions.Basic
import Mathlib.Algebra.GroupWithZero.Basic
#align_import algebra.continued_fractions.translations from "leanprover-community/mathlib"@"a7e36e48519ab281320c4d192da6a7b348ce40ad"
namespace GeneralizedContinuedFraction
section General
variable {Ξ± : Type*} {g : Gen... | Mathlib/Algebra/ContinuedFractions/Translations.lean | 53 | 55 | theorem terminatedAt_iff_part_denom_none :
g.TerminatedAt n β g.partialDenominators.get? n = none := by |
rw [terminatedAt_iff_s_none, part_denom_none_iff_s_none]
| [
" g.TerminatedAt n β g.s.TerminatedAt n",
" g.TerminatedAt n β g.s.get? n = none",
" g.partialNumerators.get? n = none β g.s.get? n = none",
" g.partialNumerators.get? n = none β none = none",
" g.partialNumerators.get? n = none β some valβ = none",
" g.TerminatedAt n β g.partialNumerators.get? n = none",... | [
" g.TerminatedAt n β g.s.TerminatedAt n",
" g.TerminatedAt n β g.s.get? n = none",
" g.partialNumerators.get? n = none β g.s.get? n = none",
" g.partialNumerators.get? n = none β none = none",
" g.partialNumerators.get? n = none β some valβ = none",
" g.TerminatedAt n β g.partialNumerators.get? n = none",... |
import Mathlib.Analysis.BoxIntegral.DivergenceTheorem
import Mathlib.Analysis.BoxIntegral.Integrability
import Mathlib.Analysis.Calculus.Deriv.Basic
import Mathlib.MeasureTheory.Constructions.Prod.Integral
import Mathlib.MeasureTheory.Integral.IntervalIntegral
import Mathlib.Analysis.Calculus.FDeriv.Equiv
#align_impo... | Mathlib/MeasureTheory/Integral/DivergenceTheorem.lean | 143 | 245 | theorem integral_divergence_of_hasFDerivWithinAt_off_countable_auxβ (I : Box (Fin (n + 1)))
(f : ββΏβΊΒΉ β EβΏβΊΒΉ)
(f' : ββΏβΊΒΉ β ββΏβΊΒΉ βL[β] EβΏβΊΒΉ)
(s : Set ββΏβΊΒΉ) (hs : s.Countable) (Hc : ContinuousOn f (Box.Icc I))
(Hd : β x β Box.Ioo I \ s, HasFDerivAt f (f' x) x)
(Hi : IntegrableOn (β i, f' Β· (e i) i) (B... |
/- Choose a monotone sequence `J k` of subboxes that cover the interior of `I` and prove that
these boxes satisfy the assumptions of the previous lemma. -/
rcases I.exists_seq_mono_tendsto with β¨J, hJ_sub, hJl, hJuβ©
have hJ_sub' : β k, Box.Icc (J k) β Box.Icc I := fun k => (hJ_sub k).trans I.Ioo_subset_Icc
... | [
" β« (x : Fin (n + 1) β β) in Box.Icc I, β i : Fin (n + 1), (f' x) (e i) i =\n β i : Fin (n + 1),\n ((β« (x : Fin n β β) in Box.Icc (I.face i), f (i.insertNth (I.upper i) x) i) -\n β« (x : Fin n β β) in Box.Icc (I.face i), f (i.insertNth (I.lower i) x) i)",
" β« (x : Fin (n + 1) β β) in βI, β i : Fin (... | [
" β« (x : Fin (n + 1) β β) in Box.Icc I, β i : Fin (n + 1), (f' x) (e i) i =\n β i : Fin (n + 1),\n ((β« (x : Fin n β β) in Box.Icc (I.face i), f (i.insertNth (I.upper i) x) i) -\n β« (x : Fin n β β) in Box.Icc (I.face i), f (i.insertNth (I.lower i) x) i)",
" β« (x : Fin (n + 1) β β) in βI, β i : Fin (... |
import Mathlib.Analysis.SpecialFunctions.Pow.Real
import Mathlib.Data.Int.Log
#align_import analysis.special_functions.log.base from "leanprover-community/mathlib"@"f23a09ce6d3f367220dc3cecad6b7eb69eb01690"
open Set Filter Function
open Topology
noncomputable section
namespace Real
variable {b x y : β}
-- @... | Mathlib/Analysis/SpecialFunctions/Log/Base.lean | 308 | 309 | theorem logb_le_logb_of_base_lt_one (h : 0 < x) (hβ : 0 < y) : logb b x β€ logb b y β y β€ x := by |
rw [logb, logb, div_le_div_right_of_neg (log_neg b_pos b_lt_one), log_le_log_iff hβ h]
| [
" b.logb 0 = 0",
" b.logb 1 = 0",
" False",
" b.logb |x| = b.logb x",
" b.logb (-x) = b.logb x",
" b.logb (x * y) = b.logb x + b.logb y",
" b.logb (x / y) = b.logb x - b.logb y",
" b.logb xβ»ΒΉ = -b.logb x",
" (a.logb b)β»ΒΉ = b.logb a",
" ((a * b).logb c)β»ΒΉ = (a.logb c)β»ΒΉ + (b.logb c)β»ΒΉ",
" c.logb ... | [
" b.logb 0 = 0",
" b.logb 1 = 0",
" False",
" b.logb |x| = b.logb x",
" b.logb (-x) = b.logb x",
" b.logb (x * y) = b.logb x + b.logb y",
" b.logb (x / y) = b.logb x - b.logb y",
" b.logb xβ»ΒΉ = -b.logb x",
" (a.logb b)β»ΒΉ = b.logb a",
" ((a * b).logb c)β»ΒΉ = (a.logb c)β»ΒΉ + (b.logb c)β»ΒΉ",
" c.logb ... |
import Mathlib.MeasureTheory.Integral.SetIntegral
import Mathlib.Probability.Independence.Basic
#align_import probability.integration from "leanprover-community/mathlib"@"2f8347015b12b0864dfaf366ec4909eb70c78740"
noncomputable section
open Set MeasureTheory
open scoped ENNReal MeasureTheory
variable {Ξ© : Type*... | Mathlib/Probability/Integration.lean | 45 | 73 | theorem lintegral_mul_indicator_eq_lintegral_mul_lintegral_indicator {Mf mΞ© : MeasurableSpace Ξ©}
{ΞΌ : Measure Ξ©} (hMf : Mf β€ mΞ©) (c : ββ₯0β) {T : Set Ξ©} (h_meas_T : MeasurableSet T)
(h_ind : IndepSets {s | MeasurableSet[Mf] s} {T} ΞΌ) (h_meas_f : Measurable[Mf] f) :
(β«β» Ο, f Ο * T.indicator (fun _ => c) Ο βΞΌ)... |
revert f
have h_mul_indicator : β g, Measurable g β Measurable fun a => g a * T.indicator (fun _ => c) a :=
fun g h_mg => h_mg.mul (measurable_const.indicator h_meas_T)
apply @Measurable.ennreal_induction _ Mf
Β· intro c' s' h_meas_s'
simp_rw [β inter_indicator_mul]
rw [lintegral_indicator _ (Measur... | [
" β«β» (Ο : Ξ©), f Ο * T.indicator (fun x => c) Ο βΞΌ = (β«β» (Ο : Ξ©), f Ο βΞΌ) * β«β» (Ο : Ξ©), T.indicator (fun x => c) Ο βΞΌ",
" β {f : Ξ© β ββ₯0β},\n Measurable f β\n β«β» (Ο : Ξ©), f Ο * T.indicator (fun x => c) Ο βΞΌ = (β«β» (Ο : Ξ©), f Ο βΞΌ) * β«β» (Ο : Ξ©), T.indicator (fun x => c) Ο βΞΌ",
" β (c_1 : ββ₯0β) β¦s : Set Ξ©β¦,... | [
" β«β» (Ο : Ξ©), f Ο * T.indicator (fun x => c) Ο βΞΌ = (β«β» (Ο : Ξ©), f Ο βΞΌ) * β«β» (Ο : Ξ©), T.indicator (fun x => c) Ο βΞΌ"
] |
import Mathlib.Algebra.Algebra.Subalgebra.Pointwise
import Mathlib.AlgebraicGeometry.PrimeSpectrum.Maximal
import Mathlib.AlgebraicGeometry.PrimeSpectrum.Noetherian
import Mathlib.RingTheory.ChainOfDivisors
import Mathlib.RingTheory.DedekindDomain.Basic
import Mathlib.RingTheory.FractionalIdeal.Operations
#align_impo... | Mathlib/RingTheory/DedekindDomain/Ideal.lean | 87 | 92 | theorem inv_anti_mono (hI : I β 0) (hJ : J β 0) (hIJ : I β€ J) : Jβ»ΒΉ β€ Iβ»ΒΉ := by |
-- Porting note: in Lean3, introducing `x` would just give `x β Jβ»ΒΉ β x β Iβ»ΒΉ`, but
-- in Lean4, it goes all the way down to the subtypes
intro x
simp only [val_eq_coe, mem_coe, mem_inv_iff hJ, mem_inv_iff hI]
exact fun h y hy => h y (hIJ hy)
| [
" βJβ»ΒΉ = IsLocalization.coeSubmodule K β€ / βJ",
" Jβ»ΒΉ β€ Iβ»ΒΉ",
" x β (fun a => βa) Jβ»ΒΉ β x β (fun a => βa) Iβ»ΒΉ",
" (β y β J, x * y β 1) β β y β I, x * y β 1"
] | [
" βJβ»ΒΉ = IsLocalization.coeSubmodule K β€ / βJ",
" Jβ»ΒΉ β€ Iβ»ΒΉ"
] |
import Mathlib.Combinatorics.SimpleGraph.Basic
namespace SimpleGraph
variable {V : Type*} (G : SimpleGraph V)
structure Dart extends V Γ V where
adj : G.Adj fst snd
deriving DecidableEq
#align simple_graph.dart SimpleGraph.Dart
initialize_simps_projections Dart (+toProd, -fst, -snd)
attribute [simp] Dart.a... | Mathlib/Combinatorics/SimpleGraph/Dart.lean | 33 | 34 | theorem Dart.ext_iff (dβ dβ : G.Dart) : dβ = dβ β dβ.toProd = dβ.toProd := by |
cases dβ; cases dβ; simp
| [
" dβ = dβ β dβ.toProd = dβ.toProd",
" { toProd := toProdβ, adj := adjβ } = dβ β { toProd := toProdβ, adj := adjβ }.toProd = dβ.toProd",
" { toProd := toProdβΒΉ, adj := adjβΒΉ } = { toProd := toProdβ, adj := adjβ } β\n { toProd := toProdβΒΉ, adj := adjβΒΉ }.toProd = { toProd := toProdβ, adj := adjβ }.toProd"
] | [
" dβ = dβ β dβ.toProd = dβ.toProd"
] |
import Mathlib.CategoryTheory.Sites.Plus
import Mathlib.CategoryTheory.Limits.Shapes.ConcreteCategory
#align_import category_theory.sites.sheafification from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a"
namespace CategoryTheory
open CategoryTheory.Limits Opposite
universe w v u
var... | Mathlib/CategoryTheory/Sites/ConcreteSheafification.lean | 477 | 479 | theorem sheafifyMap_id (P : Cα΅α΅ β₯€ D) : J.sheafifyMap (π P) = π (J.sheafify P) := by |
dsimp [sheafifyMap, sheafify]
simp
| [
" J.sheafifyMap (π P) = π (J.sheafify P)",
" J.plusMap (J.plusMap (π P)) = π (J.plusObj (J.plusObj P))"
] | [
" J.sheafifyMap (π P) = π (J.sheafify P)"
] |
import Mathlib.Data.Nat.Bitwise
import Mathlib.SetTheory.Game.Birthday
import Mathlib.SetTheory.Game.Impartial
#align_import set_theory.game.nim from "leanprover-community/mathlib"@"92ca63f0fb391a9ca5f22d2409a6080e786d99f7"
noncomputable section
universe u
namespace SetTheory
open scoped PGame
namespace PGame... | Mathlib/SetTheory/Game/Nim.lean | 73 | 75 | theorem moveLeft_nim_hEq (o : Ordinal) :
have : IsWellOrder (Quotient.out o).Ξ± (Β· < Β·) := inferInstance
HEq (nim o).moveLeft fun i : o.out.Ξ± => nim (typein (Β· < Β·) i) := by | rw [nim_def]; rfl
| [
" let_fun this := β―;\n nim o =\n mk (Quotient.out o).Ξ± (Quotient.out o).Ξ± (fun oβ => nim (typein (fun x x_1 => x < x_1) oβ)) fun oβ =>\n nim (typein (fun x x_1 => x < x_1) oβ)",
" let_fun this := β―;\n (mk (Quotient.out o).Ξ± (Quotient.out o).Ξ±\n (fun oβ =>\n let_fun x := β―;\n nim (type... | [
" let_fun this := β―;\n nim o =\n mk (Quotient.out o).Ξ± (Quotient.out o).Ξ± (fun oβ => nim (typein (fun x x_1 => x < x_1) oβ)) fun oβ =>\n nim (typein (fun x x_1 => x < x_1) oβ)",
" let_fun this := β―;\n (mk (Quotient.out o).Ξ± (Quotient.out o).Ξ±\n (fun oβ =>\n let_fun x := β―;\n nim (type... |
import Mathlib.Data.Nat.Cast.WithTop
import Mathlib.RingTheory.Prime
import Mathlib.RingTheory.Polynomial.Content
import Mathlib.RingTheory.Ideal.Quotient
#align_import ring_theory.eisenstein_criterion from "leanprover-community/mathlib"@"da420a8c6dd5bdfb85c4ced85c34388f633bc6ff"
open Polynomial Ideal.Quotient
v... | Mathlib/RingTheory/EisensteinCriterion.lean | 52 | 61 | theorem le_natDegree_of_map_eq_mul_X_pow {n : β} {P : Ideal R} (hP : P.IsPrime) {q : R[X]}
{c : Polynomial (R β§Έ P)} (hq : map (mk P) q = c * X ^ n) (hc0 : c.degree = 0) :
n β€ q.natDegree :=
Nat.cast_le.1
(calc
βn = degree (q.map (mk P)) := by |
rw [hq, degree_mul, hc0, zero_add, degree_pow, degree_X, nsmul_one]
_ β€ degree q := degree_map_le _ _
_ β€ natDegree q := degree_le_natDegree
)
| [
" (map (mk P) f).coeff n = (C ((mk P) f.leadingCoeff) * X ^ f.natDegree).coeff n",
" Β¬n = f.natDegree",
" False",
" (C ((mk P) f.leadingCoeff) * X ^ f.natDegree).degree < βn",
" βf.natDegree < βn",
" (map (mk P) f).degree < βn",
" βn = (map (mk P) q).degree"
] | [
" (map (mk P) f).coeff n = (C ((mk P) f.leadingCoeff) * X ^ f.natDegree).coeff n",
" Β¬n = f.natDegree",
" False",
" (C ((mk P) f.leadingCoeff) * X ^ f.natDegree).degree < βn",
" βf.natDegree < βn",
" (map (mk P) f).degree < βn",
" βn = (map (mk P) q).degree"
] |
import Mathlib.Topology.Separation
import Mathlib.Topology.Bases
#align_import topology.dense_embedding from "leanprover-community/mathlib"@"148aefbd371a25f1cff33c85f20c661ce3155def"
noncomputable section
open Set Filter
open scoped Topology
variable {Ξ± : Type*} {Ξ² : Type*} {Ξ³ : Type*} {Ξ΄ : Type*}
structure D... | Mathlib/Topology/DenseEmbedding.lean | 117 | 124 | theorem tendsto_comap_nhds_nhds {d : Ξ΄} {a : Ξ±} (di : DenseInducing i)
(H : Tendsto h (π d) (π (i a))) (comm : h β g = i β f) : Tendsto f (comap g (π d)) (π a) := by |
have lim1 : map g (comap g (π d)) β€ π d := map_comap_le
replace lim1 : map h (map g (comap g (π d))) β€ map h (π d) := map_mono lim1
rw [Filter.map_map, comm, β Filter.map_map, map_le_iff_le_comap] at lim1
have lim2 : comap i (map h (π d)) β€ comap i (π (i a)) := comap_mono H
rw [β di.nhds_eq_comap] at l... | [
" closure (i '' s) β π (i a)",
" U β closure (i '' s)",
" Dense (i '' s) β Dense s",
" x β closure s",
" x β univ",
" interior s = β
",
" False",
" Tendsto f (comap g (π d)) (π a)"
] | [
" closure (i '' s) β π (i a)",
" U β closure (i '' s)",
" Dense (i '' s) β Dense s",
" x β closure s",
" x β univ",
" interior s = β
",
" False",
" Tendsto f (comap g (π d)) (π a)"
] |
import Mathlib.Tactic.CategoryTheory.Coherence
import Mathlib.CategoryTheory.Monoidal.Free.Coherence
#align_import category_theory.monoidal.coherence_lemmas from "leanprover-community/mathlib"@"b8b8bf3ea0c625fa1f950034a184e07c67f7bcfe"
open CategoryTheory Category Iso
namespace CategoryTheory.MonoidalCategory
v... | Mathlib/CategoryTheory/Monoidal/CoherenceLemmas.lean | 63 | 64 | theorem unitors_equal : (Ξ»_ (π_ C)).hom = (Ο_ (π_ C)).hom := by |
coherence
| [
" (Ξ±_ (π_ C) X Y).hom β« (Ξ»_ (X β Y)).hom = (Ξ»_ X).hom β π Y",
" (Ξ»_ (X β Y)).hom = (Ξ±_ (π_ C) X Y).inv β« ((Ξ»_ X).hom β π Y)",
" (Ξ»_ (X β Y)).inv = ((Ξ»_ X).inv β π Y) β« (Ξ±_ (π_ C) X Y).hom",
" π X β (Ο_ Y).inv = (Ο_ (X β Y)).inv β« (Ξ±_ X Y (π_ C)).hom",
" (Ξ»_ X).inv β π Y = (Ξ»_ (X β Y)).inv β« (Ξ±_ (π... | [
" (Ξ±_ (π_ C) X Y).hom β« (Ξ»_ (X β Y)).hom = (Ξ»_ X).hom β π Y",
" (Ξ»_ (X β Y)).hom = (Ξ±_ (π_ C) X Y).inv β« ((Ξ»_ X).hom β π Y)",
" (Ξ»_ (X β Y)).inv = ((Ξ»_ X).inv β π Y) β« (Ξ±_ (π_ C) X Y).hom",
" π X β (Ο_ Y).inv = (Ο_ (X β Y)).inv β« (Ξ±_ X Y (π_ C)).hom",
" (Ξ»_ X).inv β π Y = (Ξ»_ (X β Y)).inv β« (Ξ±_ (π... |
import Mathlib.CategoryTheory.Monoidal.Category
import Mathlib.CategoryTheory.Limits.Shapes.BinaryProducts
import Mathlib.CategoryTheory.PEmpty
#align_import category_theory.monoidal.of_chosen_finite_products.basic from "leanprover-community/mathlib"@"95a87616d63b3cb49d3fe678d416fbe9c4217bf4"
universe v u
names... | Mathlib/CategoryTheory/Monoidal/OfChosenFiniteProducts/Basic.lean | 242 | 246 | theorem tensor_id (Xβ Xβ : C) : tensorHom β¬ (π Xβ) (π Xβ) = π (tensorObj β¬ Xβ Xβ) := by |
apply IsLimit.hom_ext (β¬ _ _).isLimit;
rintro β¨β¨β©β© <;>
Β· dsimp [tensorHom]
simp
| [
" tensorHom β¬ (π Xβ) (π Xβ) = π (tensorObj β¬ Xβ Xβ)",
" β (j : Discrete WalkingPair),\n tensorHom β¬ (π Xβ) (π Xβ) β« (β¬ Xβ Xβ).cone.Ο.app j = π (tensorObj β¬ Xβ Xβ) β« (β¬ Xβ Xβ).cone.Ο.app j",
" tensorHom β¬ (π Xβ) (π Xβ) β« (β¬ Xβ Xβ).cone.Ο.app { as := WalkingPair.left } =\n π (tensorObj β¬ Xβ Xβ) β« (... | [
" tensorHom β¬ (π Xβ) (π Xβ) = π (tensorObj β¬ Xβ Xβ)"
] |
import Mathlib.Data.Finset.Sort
import Mathlib.Data.Fin.VecNotation
import Mathlib.Data.Sign
import Mathlib.LinearAlgebra.AffineSpace.Combination
import Mathlib.LinearAlgebra.AffineSpace.AffineEquiv
import Mathlib.LinearAlgebra.Basis.VectorSpace
#align_import linear_algebra.affine_space.independent from "leanprover-c... | Mathlib/LinearAlgebra/AffineSpace/Independent.lean | 72 | 81 | theorem affineIndependent_iff_of_fintype [Fintype ΞΉ] (p : ΞΉ β P) :
AffineIndependent k p β
β w : ΞΉ β k, β i, w i = 0 β Finset.univ.weightedVSub p w = (0 : V) β β i, w i = 0 := by |
constructor
Β· exact fun h w hw hs i => h Finset.univ w hw hs i (Finset.mem_univ _)
Β· intro h s w hw hs i hi
rw [Finset.weightedVSub_indicator_subset _ _ (Finset.subset_univ s)] at hs
rw [β Finset.sum_indicator_subset _ (Finset.subset_univ s)] at hw
replace h := h ((βs : Set ΞΉ).indicator w) hw hs i
... | [
" AffineIndependent k p β β (w : ΞΉ β k), β i : ΞΉ, w i = 0 β (univ.weightedVSub p) w = 0 β β (i : ΞΉ), w i = 0",
" AffineIndependent k p β β (w : ΞΉ β k), β i : ΞΉ, w i = 0 β (univ.weightedVSub p) w = 0 β β (i : ΞΉ), w i = 0",
" (β (w : ΞΉ β k), β i : ΞΉ, w i = 0 β (univ.weightedVSub p) w = 0 β β (i : ΞΉ), w i = 0) β A... | [
" AffineIndependent k p β β (w : ΞΉ β k), β i : ΞΉ, w i = 0 β (univ.weightedVSub p) w = 0 β β (i : ΞΉ), w i = 0"
] |
import Mathlib.ModelTheory.Syntax
import Mathlib.ModelTheory.Semantics
import Mathlib.Algebra.Ring.Equiv
variable {Ξ± : Type*}
namespace FirstOrder
open FirstOrder
inductive ringFunc : β β Type
| add : ringFunc 2
| mul : ringFunc 2
| neg : ringFunc 1
| zero : ringFunc 0
| one : ringFunc 0
deriving D... | Mathlib/ModelTheory/Algebra/Ring/Basic.lean | 138 | 140 | theorem card_ring : card Language.ring = 5 := by |
have : Fintype.card Language.ring.Symbols = 5 := rfl
simp [Language.card, this]
| [
" DecidableEq (ring.Functions n)",
" DecidableEq (ringFunc n)",
" DecidableEq (ring.Relations n)",
" DecidableEq Empty",
" (β[Sum.inl β¨2, addβ©, Sum.inl β¨2, mulβ©, Sum.inl β¨1, negβ©, Sum.inl β¨0, zeroβ©, Sum.inl β¨0, oneβ©]).Nodup",
" β (x : ring.Symbols),\n x β\n { val := β[Sum.inl β¨2, addβ©, Sum.inl β¨2,... | [
" DecidableEq (ring.Functions n)",
" DecidableEq (ringFunc n)",
" DecidableEq (ring.Relations n)",
" DecidableEq Empty",
" (β[Sum.inl β¨2, addβ©, Sum.inl β¨2, mulβ©, Sum.inl β¨1, negβ©, Sum.inl β¨0, zeroβ©, Sum.inl β¨0, oneβ©]).Nodup",
" β (x : ring.Symbols),\n x β\n { val := β[Sum.inl β¨2, addβ©, Sum.inl β¨2,... |
import Mathlib.LinearAlgebra.Span
import Mathlib.RingTheory.Ideal.IsPrimary
import Mathlib.RingTheory.Ideal.QuotientOperations
import Mathlib.RingTheory.Noetherian
#align_import ring_theory.ideal.associated_prime from "leanprover-community/mathlib"@"f0c8bf9245297a541f468be517f1bde6195105e9"
variable {R : Type*} [... | Mathlib/RingTheory/Ideal/AssociatedPrime.lean | 83 | 103 | theorem exists_le_isAssociatedPrime_of_isNoetherianRing [H : IsNoetherianRing R] (x : M)
(hx : x β 0) : β P : Ideal R, IsAssociatedPrime P M β§ (R β x).annihilator β€ P := by |
have : (R β x).annihilator β β€ := by
rwa [Ne, Ideal.eq_top_iff_one, Submodule.mem_annihilator_span_singleton, one_smul]
obtain β¨P, β¨l, hβ, y, rflβ©, hββ© :=
set_has_maximal_iff_noetherian.mpr H
{ P | (R β x).annihilator β€ P β§ P β β€ β§ β y : M, P = (R β y).annihilator }
β¨(R β x).annihilator, rfl.le... | [
" IsAssociatedPrime I M'",
" IsAssociatedPrime (Submodule.span R {x}).annihilator M'",
" (Submodule.span R {x}).annihilator = (Submodule.span R {f x}).annihilator",
" r β (Submodule.span R {x}).annihilator β r β (Submodule.span R {f x}).annihilator",
" Β¬IsAssociatedPrime I M",
" False",
" I = β€",
" β ... | [
" IsAssociatedPrime I M'",
" IsAssociatedPrime (Submodule.span R {x}).annihilator M'",
" (Submodule.span R {x}).annihilator = (Submodule.span R {f x}).annihilator",
" r β (Submodule.span R {x}).annihilator β r β (Submodule.span R {f x}).annihilator",
" Β¬IsAssociatedPrime I M",
" False",
" I = β€",
" β ... |
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 | 147 | 149 | theorem intrinsicClosure_singleton (x : P) : intrinsicClosure π ({x} : Set P) = {x} := by |
simpa only [intrinsicClosure, preimage_coe_affineSpan_singleton, closure_univ, image_univ,
Subtype.range_coe] using coe_affineSpan_singleton _ _ _
| [
" intrinsicInterior π β
= β
",
" intrinsicFrontier π β
= β
",
" intrinsicClosure π β
= β
",
" (intrinsicClosure π s).Nonempty β s.Nonempty",
" intrinsicClosure π s β β
β s β β
",
" False",
" intrinsicInterior π {x} = {x}",
" intrinsicFrontier π {x} = β
",
" intrinsicClosure π {x} = {x}"
] | [
" intrinsicInterior π β
= β
",
" intrinsicFrontier π β
= β
",
" intrinsicClosure π β
= β
",
" (intrinsicClosure π s).Nonempty β s.Nonempty",
" intrinsicClosure π s β β
β s β β
",
" False",
" intrinsicInterior π {x} = {x}",
" intrinsicFrontier π {x} = β
",
" intrinsicClosure π {x} = {x}"
] |
import Mathlib.MeasureTheory.Decomposition.RadonNikodym
import Mathlib.Probability.Kernel.Disintegration.CdfToKernel
#align_import probability.kernel.cond_cdf from "leanprover-community/mathlib"@"3b88f4005dc2e28d42f974cc1ce838f0dafb39b8"
open MeasureTheory Set Filter TopologicalSpace
open scoped NNReal ENNReal Me... | Mathlib/Probability/Kernel/Disintegration/CondCdf.lean | 54 | 58 | theorem IicSnd_apply (r : β) {s : Set Ξ±} (hs : MeasurableSet s) :
Ο.IicSnd r s = Ο (s ΓΛ’ Iic r) := by |
rw [IicSnd, fst_apply hs,
restrict_apply' (MeasurableSet.univ.prod (measurableSet_Iic : MeasurableSet (Iic r))), β
prod_univ, prod_inter_prod, inter_univ, univ_inter]
| [
" (Ο.IicSnd r) s = Ο (s ΓΛ’ Iic r)"
] | [
" (Ο.IicSnd r) s = Ο (s ΓΛ’ Iic r)"
] |
import Mathlib.Analysis.Calculus.FDeriv.Prod
import Mathlib.Analysis.Calculus.InverseFunctionTheorem.FDeriv
import Mathlib.LinearAlgebra.Dual
#align_import analysis.calculus.lagrange_multipliers from "leanprover-community/mathlib"@"f2ce6086713c78a7f880485f7917ea547a215982"
open Filter Set
open scoped Topology Fi... | Mathlib/Analysis/Calculus/LagrangeMultipliers.lean | 108 | 121 | theorem IsLocalExtrOn.exists_multipliers_of_hasStrictFDerivAt {ΞΉ : Type*} [Fintype ΞΉ]
{f : ΞΉ β E β β} {f' : ΞΉ β E βL[β] β} (hextr : IsLocalExtrOn Ο {x | β i, f i x = f i xβ} xβ)
(hf' : β i, HasStrictFDerivAt (f i) (f' i) xβ) (hΟ' : HasStrictFDerivAt Ο Ο' xβ) :
β (Ξ : ΞΉ β β) (Ξβ : β), (Ξ, Ξβ) β 0 β§ (β i, Ξ i... |
letI := Classical.decEq ΞΉ
replace hextr : IsLocalExtrOn Ο {x | (fun i => f i x) = fun i => f i xβ} xβ := by
simpa only [Function.funext_iff] using hextr
rcases hextr.exists_linear_map_of_hasStrictFDerivAt (hasStrictFDerivAt_pi.2 fun i => hf' i)
hΟ' with
β¨Ξ, Ξβ, h0, hsumβ©
rcases (LinearEquiv.piRin... | [
" LinearMap.range (f'.prod Ο') β β€",
" False",
" map Ο (π[f β»ΒΉ' {f xβ}] xβ) = π (Ο xβ)",
" map (Prod.snd β fΟ) (π[fΟ β»ΒΉ' {p | p.1 = f xβ}] xβ) = π (Ο xβ)",
" map Prod.snd (π (f xβ, Ο xβ) β π {p | p.1 = f xβ}) = π (Ο xβ)",
" β Ξ Ξβ, (Ξ, Ξβ) β 0 β§ β (x : E), Ξ (f' x) + Ξβ β’ Ο' x = 0",
" Ξ (f' x) + ... | [
" LinearMap.range (f'.prod Ο') β β€",
" False",
" map Ο (π[f β»ΒΉ' {f xβ}] xβ) = π (Ο xβ)",
" map (Prod.snd β fΟ) (π[fΟ β»ΒΉ' {p | p.1 = f xβ}] xβ) = π (Ο xβ)",
" map Prod.snd (π (f xβ, Ο xβ) β π {p | p.1 = f xβ}) = π (Ο xβ)",
" β Ξ Ξβ, (Ξ, Ξβ) β 0 β§ β (x : E), Ξ (f' x) + Ξβ β’ Ο' x = 0",
" Ξ (f' x) + ... |
import Mathlib.Algebra.Module.Zlattice.Basic
import Mathlib.NumberTheory.NumberField.Embeddings
import Mathlib.NumberTheory.NumberField.FractionalIdeal
#align_import number_theory.number_field.canonical_embedding from "leanprover-community/mathlib"@"60da01b41bbe4206f05d34fd70c8dd7498717a30"
variable (K : Type*) [F... | Mathlib/NumberTheory/NumberField/CanonicalEmbedding/Basic.lean | 286 | 288 | theorem normAtPlace_apply_isReal {w : InfinitePlace K} (hw : IsReal w) (x : E K):
normAtPlace w x = βx.1 β¨w, hwβ©β := by |
rw [normAtPlace, MonoidWithZeroHom.coe_mk, ZeroHom.coe_mk, dif_pos]
| [
" Nontrivial (({ w // w.IsReal } β β) Γ ({ w // w.IsComplex } β β))",
" finrank β (({ w // w.IsReal } β β) Γ ({ w // w.IsComplex } β β)) = finrank β K",
" Function.Injective β(mixedEmbedding K)",
" (fun x => if hw : w.IsReal then βx.1 β¨w, hwβ©β else βx.2 β¨w, β―β©β) 0 = 0",
" { toFun := fun x => if hw : w.IsRea... | [
" Nontrivial (({ w // w.IsReal } β β) Γ ({ w // w.IsComplex } β β))",
" finrank β (({ w // w.IsReal } β β) Γ ({ w // w.IsComplex } β β)) = finrank β K",
" Function.Injective β(mixedEmbedding K)",
" (fun x => if hw : w.IsReal then βx.1 β¨w, hwβ©β else βx.2 β¨w, β―β©β) 0 = 0",
" { toFun := fun x => if hw : w.IsRea... |
import Mathlib.Algebra.DualNumber
import Mathlib.Algebra.QuaternionBasis
import Mathlib.Data.Complex.Module
import Mathlib.LinearAlgebra.CliffordAlgebra.Conjugation
import Mathlib.LinearAlgebra.CliffordAlgebra.Star
import Mathlib.LinearAlgebra.QuadraticForm.Prod
#align_import linear_algebra.clifford_algebra.equivs fr... | Mathlib/LinearAlgebra/CliffordAlgebra/Equivs.lean | 182 | 185 | theorem toComplex_comp_ofComplex : toComplex.comp ofComplex = AlgHom.id β β := by |
ext1
dsimp only [AlgHom.comp_apply, Subtype.coe_mk, AlgHom.id_apply]
rw [ofComplex_I, toComplex_ΞΉ, one_smul]
| [
" (LinearMap.toSpanSingleton β β Complex.I) r * (LinearMap.toSpanSingleton β β Complex.I) r = (algebraMap β β) (Q r)",
" βr * Complex.I * (βr * Complex.I) = β(-(r * r))",
" βr * βr * (Complex.I * Complex.I) = β(-(r * r))",
" toComplex (involute c) = (starRingEnd β) (toComplex c)",
" toComplex (involute ((ΞΉ ... | [
" (LinearMap.toSpanSingleton β β Complex.I) r * (LinearMap.toSpanSingleton β β Complex.I) r = (algebraMap β β) (Q r)",
" βr * Complex.I * (βr * Complex.I) = β(-(r * r))",
" βr * βr * (Complex.I * Complex.I) = β(-(r * r))",
" toComplex (involute c) = (starRingEnd β) (toComplex c)",
" toComplex (involute ((ΞΉ ... |
import Mathlib.Order.Monotone.Odd
import Mathlib.Analysis.SpecialFunctions.ExpDeriv
import Mathlib.Analysis.SpecialFunctions.Trigonometric.Basic
#align_import analysis.special_functions.trigonometric.deriv from "leanprover-community/mathlib"@"2c1d8ca2812b64f88992a5294ea3dba144755cd1"
noncomputable section
open s... | Mathlib/Analysis/SpecialFunctions/Trigonometric/Deriv.lean | 35 | 41 | theorem hasStrictDerivAt_sin (x : β) : HasStrictDerivAt sin (cos x) x := by |
simp only [cos, div_eq_mul_inv]
convert ((((hasStrictDerivAt_id x).neg.mul_const I).cexp.sub
((hasStrictDerivAt_id x).mul_const I).cexp).mul_const I).mul_const (2 : β)β»ΒΉ using 1
simp only [Function.comp, id]
rw [sub_mul, mul_assoc, mul_assoc, I_mul_I, neg_one_mul, neg_neg, mul_one, one_mul, mul_assoc,
... | [
" HasStrictDerivAt sin x.cos x",
" HasStrictDerivAt sin ((cexp (x * I) + cexp (-x * I)) * 2β»ΒΉ) x",
" (cexp (x * I) + cexp (-x * I)) * 2β»ΒΉ = (cexp (-id x * I) * (-1 * I) - cexp (id x * I) * (1 * I)) * I * 2β»ΒΉ",
" (cexp (x * I) + cexp (-x * I)) * 2β»ΒΉ = (cexp (-x * I) * (-1 * I) - cexp (x * I) * (1 * I)) * I * 2... | [
" HasStrictDerivAt sin x.cos x"
] |
import Mathlib.Control.Applicative
import Mathlib.Control.Traversable.Basic
import Mathlib.Data.List.Forall2
import Mathlib.Data.Set.Functor
#align_import control.traversable.instances from "leanprover-community/mathlib"@"18a5306c091183ac90884daa9373fa3b178e8607"
universe u v
section Option
open Functor
variab... | Mathlib/Control/Traversable/Instances.lean | 31 | 32 | theorem Option.id_traverse {Ξ±} (x : Option Ξ±) : Option.traverse (pure : Ξ± β Id Ξ±) x = x := by |
cases x <;> rfl
| [
" Option.traverse pure x = x",
" Option.traverse pure none = none",
" Option.traverse pure (some valβ) = some valβ"
] | [
" Option.traverse pure x = x"
] |
import Mathlib.CategoryTheory.Limits.Shapes.Biproducts
import Mathlib.CategoryTheory.Limits.Preserves.Shapes.Zero
#align_import category_theory.limits.preserves.shapes.biproducts from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a"
universe wβ wβ vβ vβ uβ uβ
noncomputable section
open ... | Mathlib/CategoryTheory/Limits/Preserves/Shapes/Biproducts.lean | 349 | 351 | theorem biprodComparison'_comp_biprodComparison :
biprodComparison' F X Y β« biprodComparison F X Y = π (F.obj X β F.obj Y) := by |
ext <;> simp [β Functor.map_comp]
| [
" F.biprodComparison' X Y β« F.biprodComparison X Y = π (F.obj X β F.obj Y)",
" (biprod.inl β« F.biprodComparison' X Y β« F.biprodComparison X Y) β« biprod.fst =\n (biprod.inl β« π (F.obj X β F.obj Y)) β« biprod.fst",
" (biprod.inl β« F.biprodComparison' X Y β« F.biprodComparison X Y) β« biprod.snd =\n (biprod.i... | [
" F.biprodComparison' X Y β« F.biprodComparison X Y = π (F.obj X β F.obj Y)"
] |
import Mathlib.Algebra.MvPolynomial.Degrees
#align_import data.mv_polynomial.variables from "leanprover-community/mathlib"@"2f5b500a507264de86d666a5f87ddb976e2d8de4"
noncomputable section
open Set Function Finsupp AddMonoidAlgebra
universe u v w
variable {R : Type u} {S : Type v}
namespace MvPolynomial
varia... | Mathlib/Algebra/MvPolynomial/Variables.lean | 87 | 88 | theorem vars_C : (C r : MvPolynomial Ο R).vars = β
:= by |
classical rw [vars_def, degrees_C, Multiset.toFinset_zero]
| [
" p.vars = p.degrees.toFinset",
" p.degrees.toFinset = p.degrees.toFinset",
" vars 0 = β
",
" ((monomial s) r).vars = s.support",
" (C r).vars = β
"
] | [
" p.vars = p.degrees.toFinset",
" p.degrees.toFinset = p.degrees.toFinset",
" vars 0 = β
",
" ((monomial s) r).vars = s.support",
" (C r).vars = β
"
] |
import Mathlib.Topology.Bases
import Mathlib.Order.Filter.CountableInter
import Mathlib.Topology.Compactness.SigmaCompact
open Set Filter Topology TopologicalSpace
universe u v
variable {X : Type u} {Y : Type v} {ΞΉ : Type*}
variable [TopologicalSpace X] [TopologicalSpace Y] {s t : Set X}
section Lindelof
def I... | Mathlib/Topology/Compactness/Lindelof.lean | 129 | 151 | theorem IsLindelof.elim_countable_subcover {ΞΉ : Type v} (hs : IsLindelof s) (U : ΞΉ β Set X)
(hUo : β i, IsOpen (U i)) (hsU : s β β i, U i) :
β r : Set ΞΉ, r.Countable β§ (s β β i β r, U i) := by |
have hmono : β β¦s t : Set Xβ¦, s β t β (β r : Set ΞΉ, r.Countable β§ t β β i β r, U i)
β (β r : Set ΞΉ, r.Countable β§ s β β i β r, U i) := by
intro _ _ hst β¨r, β¨hrcountable, hsubβ©β©
exact β¨r, hrcountable, Subset.trans hst hsubβ©
have hcountable_union : β (S : Set (Set X)), S.Countable
β (β s β S, β r... | [
" sαΆ β f",
" β x β s, sαΆ β π x β f",
" β x β s, (π x β (f β π s)).NeBot",
" sαΆ β π x β f",
" β i β π x β π s, (id i)αΆ β f",
" p s",
" β x β s, β t β π[s] x, tαΆ β f",
" IsLindelof (s β© t)",
" β x β s β© t, ClusterPt x f",
" IsLindelof (f '' s)",
" β x β f '' s, ClusterPt x l",
" ClusterPt... | [
" sαΆ β f",
" β x β s, sαΆ β π x β f",
" β x β s, (π x β (f β π s)).NeBot",
" sαΆ β π x β f",
" β i β π x β π s, (id i)αΆ β f",
" p s",
" β x β s, β t β π[s] x, tαΆ β f",
" IsLindelof (s β© t)",
" β x β s β© t, ClusterPt x f",
" IsLindelof (f '' s)",
" β x β f '' s, ClusterPt x l",
" ClusterPt... |
import Mathlib.Algebra.Group.Subgroup.Basic
import Mathlib.Data.Fintype.Card
import Mathlib.GroupTheory.Nilpotent
import Mathlib.Order.Radical
def frattini (G : Type*) [Group G] : Subgroup G :=
Order.radical (Subgroup G)
variable {G H : Type*} [Group G] [Group H] {Ο : G β* H} (hΟ : Function.Surjective Ο)
lemma... | Mathlib/GroupTheory/Frattini.lean | 59 | 74 | theorem frattini_nilpotent [Finite G] : Group.IsNilpotent (frattini G) := by |
-- We use the characterisation of nilpotency in terms of all Sylow subgroups being normal.
have q := (isNilpotent_of_finite_tfae (G := frattini G)).out 0 3
rw [q]; clear q
-- Consider each prime `p` and Sylow `p`-subgroup `P` of `frattini G`.
intro p p_prime P
-- The Frattini argument shows that the normal... | [
" frattini G β€ comap Ο (frattini H)",
" β i β {H_1 | IsCoatom H_1}, β¨
a β {H | IsCoatom H}, a β€ comap Ο i",
" β¨
a β {H | IsCoatom H}, a β€ comap Ο M",
" comap Ο M β {H | IsCoatom H}",
" (frattini G).Characteristic",
" β (Ο : G β* G), comap Ο.toMonoidHom (frattini G) = frattini G",
" comap Ο.toMonoidHom (... | [
" frattini G β€ comap Ο (frattini H)",
" β i β {H_1 | IsCoatom H_1}, β¨
a β {H | IsCoatom H}, a β€ comap Ο i",
" β¨
a β {H | IsCoatom H}, a β€ comap Ο M",
" comap Ο M β {H | IsCoatom H}",
" (frattini G).Characteristic",
" β (Ο : G β* G), comap Ο.toMonoidHom (frattini G) = frattini G",
" comap Ο.toMonoidHom (... |
import Mathlib.Algebra.CharZero.Lemmas
import Mathlib.Algebra.GroupWithZero.Commute
import Mathlib.Algebra.Order.Field.Basic
import Mathlib.Algebra.Order.Ring.Pow
import Mathlib.Algebra.Ring.Int
#align_import algebra.order.field.power from "leanprover-community/mathlib"@"acb3d204d4ee883eb686f45d486a2a6811a01329"
... | Mathlib/Algebra/Order/Field/Power.lean | 150 | 152 | theorem Even.zpow_pos_iff (hn : Even n) (h : n β 0) : 0 < a ^ n β a β 0 := by |
obtain β¨k, rflβ© := hn
rw [zpow_add' (by simp [em']), mul_self_pos, zpow_ne_zero_iff (by simpa using h)]
| [
" 0 β€ a ^ n",
" 0 β€ a ^ (k + k)",
" a β 0 β¨ k + k β 0 β¨ k = 0 β§ k = 0",
" 0 β€ a ^ k * a ^ k",
" 0 < a ^ n β a β 0",
" 0 < a ^ (k + k) β a β 0",
" k β 0"
] | [
" 0 β€ a ^ n",
" 0 β€ a ^ (k + k)",
" a β 0 β¨ k + k β 0 β¨ k = 0 β§ k = 0",
" 0 β€ a ^ k * a ^ k",
" 0 < a ^ n β a β 0"
] |
import Mathlib.Analysis.NormedSpace.Basic
import Mathlib.Topology.Algebra.Module.Basic
#align_import analysis.normed_space.basic from "leanprover-community/mathlib"@"bc91ed7093bf098d253401e69df601fc33dde156"
open Metric Set Function Filter
open scoped NNReal Topology
instance Real.punctured_nhds_module_neBot {E ... | Mathlib/Analysis/NormedSpace/Real.lean | 61 | 73 | theorem closure_ball (x : E) {r : β} (hr : r β 0) : closure (ball x r) = closedBall x r := by |
refine Subset.antisymm closure_ball_subset_closedBall fun y hy => ?_
have : ContinuousWithinAt (fun c : β => c β’ (y - x) + x) (Ico 0 1) 1 :=
((continuous_id.smul continuous_const).add continuous_const).continuousWithinAt
convert this.mem_closure _ _
Β· rw [one_smul, sub_add_cancel]
Β· simp [closure_Ico zer... | [
" βxββ»ΒΉ β’ x β closedBall 0 1",
" βt β’ xβ = t * βxβ",
" dist (r β’ x + (1 - r) β’ y) x = β1 - rβ * βx - yβ",
" β1 - rβ * βx - yβ = (1 - r) * dist y x",
" (1 - r) * dist y x β€ (1 - 0) * dist y x",
" 0 β€ r",
" (1 - 0) * dist y x = dist y x",
" closure (ball x r) = closedBall x r",
" y β closure (ball x r... | [
" βxββ»ΒΉ β’ x β closedBall 0 1",
" βt β’ xβ = t * βxβ",
" dist (r β’ x + (1 - r) β’ y) x = β1 - rβ * βx - yβ",
" β1 - rβ * βx - yβ = (1 - r) * dist y x",
" (1 - r) * dist y x β€ (1 - 0) * dist y x",
" 0 β€ r",
" (1 - 0) * dist y x = dist y x",
" closure (ball x r) = closedBall x r"
] |
import Mathlib.SetTheory.Game.State
#align_import set_theory.game.domineering from "leanprover-community/mathlib"@"b134b2f5cf6dd25d4bbfd3c498b6e36c11a17225"
namespace SetTheory
namespace PGame
namespace Domineering
open Function
@[simps!]
def shiftUp : β€ Γ β€ β β€ Γ β€ :=
(Equiv.refl β€).prodCongr (Equiv.addRig... | Mathlib/SetTheory/Game/Domineering.lean | 79 | 83 | theorem fst_pred_mem_erase_of_mem_right {b : Board} {m : β€ Γ β€} (h : m β right b) :
(m.1 - 1, m.2) β b.erase m := by |
rw [mem_right] at h
apply Finset.mem_erase_of_ne_of_mem _ h.2
exact ne_of_apply_ne Prod.fst (pred_ne_self m.1)
| [
" (m.1 - 1, m.2) β Finset.erase b m",
" (m.1 - 1, m.2) β m"
] | [
" (m.1 - 1, m.2) β Finset.erase b m"
] |
import Mathlib.Data.Matrix.Basis
import Mathlib.RingTheory.TensorProduct.Basic
#align_import ring_theory.matrix_algebra from "leanprover-community/mathlib"@"6c351a8fb9b06e5a542fdf427bfb9f46724f9453"
suppress_compilation
universe u v w
open TensorProduct
open TensorProduct
open Algebra.TensorProduct
open Matri... | Mathlib/RingTheory/MatrixAlgebra.lean | 99 | 101 | theorem invFun_smul (a : A) (M : Matrix n n A) :
invFun R A n (a β’ M) = a ββ 1 * invFun R A n M := by |
simp [invFun, Finset.mul_sum]
| [
" β (aβ aβ : A) (bβ bβ : Matrix n n R),\n (toFunLinear R A n) ((aβ * aβ) ββ[R] (bβ * bβ)) =\n (toFunLinear R A n) (aβ ββ[R] bβ) * (toFunLinear R A n) (aβ ββ[R] bβ)",
" (toFunLinear R A n) ((aββ * aββ) ββ[R] (bββ * bββ)) =\n (toFunLinear R A n) (aββ ββ[R] bββ) * (toFunLinear R A n) (aββ ββ[R] bββ)",
"... | [
" β (aβ aβ : A) (bβ bβ : Matrix n n R),\n (toFunLinear R A n) ((aβ * aβ) ββ[R] (bβ * bβ)) =\n (toFunLinear R A n) (aβ ββ[R] bβ) * (toFunLinear R A n) (aβ ββ[R] bβ)",
" (toFunLinear R A n) ((aββ * aββ) ββ[R] (bββ * bββ)) =\n (toFunLinear R A n) (aββ ββ[R] bββ) * (toFunLinear R A n) (aββ ββ[R] bββ)",
"... |
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 RelPrime
variable {Ξ± I} [Comm... | Mathlib/RingTheory/Coprime/Lemmas.lean | 235 | 240 | theorem IsRelPrime.prod_left : (β i β t, IsRelPrime (s i) x) β IsRelPrime (β i β t, s i) x := by |
classical
refine Finset.induction_on t (fun _ β¦ isRelPrime_one_left) fun b t hbt ih H β¦ ?_
rw [Finset.prod_insert hbt]
rw [Finset.forall_mem_insert] at H
exact H.1.mul_left (ih H.2)
| [
" (β i β t, IsRelPrime (s i) x) β IsRelPrime (β i β t, s i) x",
" IsRelPrime (β i β insert b t, s i) x",
" IsRelPrime (s b * β x β t, s x) x"
] | [
" (β i β t, IsRelPrime (s i) x) β IsRelPrime (β i β t, s i) x"
] |
import Mathlib.Data.Finset.Lattice
#align_import combinatorics.set_family.compression.down from "leanprover-community/mathlib"@"9003f28797c0664a49e4179487267c494477d853"
variable {Ξ± : Type*} [DecidableEq Ξ±] {π β¬ : Finset (Finset Ξ±)} {s : Finset Ξ±} {a : Ξ±}
namespace Finset
def nonMemberSubfamily (a : Ξ±) (π : ... | Mathlib/Combinatorics/SetFamily/Compression/Down.lean | 99 | 110 | theorem memberSubfamily_union_nonMemberSubfamily (a : Ξ±) (π : Finset (Finset Ξ±)) :
π.memberSubfamily a βͺ π.nonMemberSubfamily a = π.image fun s => s.erase a := by |
ext s
simp only [mem_union, mem_memberSubfamily, mem_nonMemberSubfamily, mem_image, exists_prop]
constructor
Β· rintro (h | h)
Β· exact β¨_, h.1, erase_insert h.2β©
Β· exact β¨_, h.1, erase_eq_of_not_mem h.2β©
Β· rintro β¨s, hs, rflβ©
by_cases ha : a β s
Β· exact Or.inl β¨by rwa [insert_erase ha], not_me... | [
" s β nonMemberSubfamily a π β s β π β§ a β s",
" s β memberSubfamily a π β insert a s β π β§ a β s",
" (β a_1, (a_1 β π β§ a β a_1) β§ a_1.erase a = s) β insert a s β π β§ a β s",
" a β insert a s",
" (β a_1, (a_1 β π β§ a β a_1) β§ a_1.erase a = s) β insert a s β π β§ a β s",
" insert a (s.erase a) β π... | [
" s β nonMemberSubfamily a π β s β π β§ a β s",
" s β memberSubfamily a π β insert a s β π β§ a β s",
" (β a_1, (a_1 β π β§ a β a_1) β§ a_1.erase a = s) β insert a s β π β§ a β s",
" a β insert a s",
" (β a_1, (a_1 β π β§ a β a_1) β§ a_1.erase a = s) β insert a s β π β§ a β s",
" insert a (s.erase a) β π... |
import Mathlib.Geometry.Manifold.SmoothManifoldWithCorners
import Mathlib.Geometry.Manifold.LocalInvariantProperties
#align_import geometry.manifold.cont_mdiff from "leanprover-community/mathlib"@"e5ab837fc252451f3eb9124ae6e7b6f57455e7b9"
open Set Function Filter ChartedSpace SmoothManifoldWithCorners
open scope... | Mathlib/Geometry/Manifold/ContMDiff/Defs.lean | 116 | 154 | theorem contDiffWithinAt_localInvariantProp (n : ββ) :
(contDiffGroupoid β I).LocalInvariantProp (contDiffGroupoid β I')
(ContDiffWithinAtProp I I' n) where
is_local {s x u f} u_open xu := by |
have : I.symm β»ΒΉ' (s β© u) β© range I = I.symm β»ΒΉ' s β© range I β© I.symm β»ΒΉ' u := by
simp only [inter_right_comm, preimage_inter]
rw [ContDiffWithinAtProp, ContDiffWithinAtProp, this]
symm
apply contDiffWithinAt_inter
have : u β π (I.symm (I x)) := by
rw [ModelWithCorners.left_inv]
... | [
" ContDiffWithinAtProp π(π, E) I' n f s x β ContDiffWithinAt π n (βI' β f) s x",
" ContDiffWithinAtProp I I' n f s x β ContDiffWithinAtProp I I' n f (s β© u) x",
" βI.symm β»ΒΉ' (s β© u) β© range βI = βI.symm β»ΒΉ' s β© range βI β© βI.symm β»ΒΉ' u",
" ContDiffWithinAt π n (βI' β f β βI.symm) (βI.symm β»ΒΉ' s β© range β... | [
" ContDiffWithinAtProp π(π, E) I' n f s x β ContDiffWithinAt π n (βI' β f) s x",
" ContDiffWithinAtProp I I' n f s x β ContDiffWithinAtProp I I' n f (s β© u) x"
] |
import Mathlib.RingTheory.MvPowerSeries.Basic
import Mathlib.RingTheory.Ideal.LocalRing
#align_import ring_theory.power_series.basic from "leanprover-community/mathlib"@"2d5739b61641ee4e7e53eca5688a08f66f2e6a60"
noncomputable section
open Finset (antidiagonal mem_antidiagonal)
namespace MvPowerSeries
open Fi... | Mathlib/RingTheory/MvPowerSeries/Inverse.lean | 107 | 137 | theorem mul_invOfUnit (Ο : MvPowerSeries Ο R) (u : RΛ£) (h : constantCoeff Ο R Ο = u) :
Ο * invOfUnit Ο u = 1 :=
ext fun n =>
letI := Classical.decEq (Ο ββ β)
if H : n = 0 then by
rw [H]
simp [coeff_mul, support_single_ne_zero, h]
else by
classical
have : ((0 : Ο ββ β), n) β ant... | rw [mem_antidiagonal, zero_add]
rw [coeff_one, if_neg H, coeff_mul, β Finset.insert_erase this,
Finset.sum_insert (Finset.not_mem_erase _ _), coeff_zero_eq_constantCoeff_apply, h,
coeff_invOfUnit, if_neg H, neg_mul, mul_neg, Units.mul_inv_cancel_left, β
Finset.insert_erase this, Finset.su... | [
" inv.aux a Ο n =\n if n = 0 then a else -a * β x β antidiagonal n, if x.2 < n then (coeff R x.1) Ο * (coeff R x.2) (inv.aux a Ο) else 0",
" (if n = 0 then a else -a * β x β antidiagonal n, if x_1 : x.2 < n then (coeff R x.1) Ο * inv.aux a Ο x.2 else 0) =\n if n = 0 then a else -a * β x β antidiagonal n, if... | [
" inv.aux a Ο n =\n if n = 0 then a else -a * β x β antidiagonal n, if x.2 < n then (coeff R x.1) Ο * (coeff R x.2) (inv.aux a Ο) else 0",
" (if n = 0 then a else -a * β x β antidiagonal n, if x_1 : x.2 < n then (coeff R x.1) Ο * inv.aux a Ο x.2 else 0) =\n if n = 0 then a else -a * β x β antidiagonal n, if... |
import Mathlib.Algebra.EuclideanDomain.Basic
import Mathlib.RingTheory.PrincipalIdealDomain
import Mathlib.Algebra.GCDMonoid.Nat
#align_import ring_theory.int.basic from "leanprover-community/mathlib"@"e655e4ea5c6d02854696f97494997ba4c31be802"
namespace Int
theorem gcd_eq_one_iff_coprime {a b : β€} : Int.gcd a b ... | Mathlib/RingTheory/Int/Basic.lean | 49 | 50 | theorem coprime_iff_nat_coprime {a b : β€} : IsCoprime a b β Nat.Coprime a.natAbs b.natAbs := by |
rw [β gcd_eq_one_iff_coprime, Nat.coprime_iff_gcd_eq_one, gcd_eq_natAbs]
| [
" a.gcd b = 1 β IsCoprime a b",
" a.gcd b = 1 β IsCoprime a b",
" IsCoprime a b",
" a.natAbs.gcdA b.natAbs * ua * a + a.natAbs.gcdB b.natAbs * ub * b = 1",
" IsCoprime a b β a.gcd b = 1",
" a.gcd b = 1",
" False",
" p β£ 1",
" βp β£ r * a + s * b",
" IsCoprime a b β a.natAbs.Coprime b.natAbs"
] | [
" a.gcd b = 1 β IsCoprime a b",
" a.gcd b = 1 β IsCoprime a b",
" IsCoprime a b",
" a.natAbs.gcdA b.natAbs * ua * a + a.natAbs.gcdB b.natAbs * ub * b = 1",
" IsCoprime a b β a.gcd b = 1",
" a.gcd b = 1",
" False",
" p β£ 1",
" βp β£ r * a + s * b",
" IsCoprime a b β a.natAbs.Coprime b.natAbs"
] |
import Mathlib.Tactic.Ring
#align_import algebra.group_power.identities from "leanprover-community/mathlib"@"c4658a649d216f57e99621708b09dcb3dcccbd23"
variable {R : Type*} [CommRing R] {a b xβ xβ xβ xβ xβ
xβ xβ xβ yβ yβ yβ yβ yβ
yβ yβ yβ n : R}
theorem sq_add_sq_mul_sq_add_sq :
(xβ ^ 2 + xβ ^ 2) * (yβ ^ 2 +... | Mathlib/Algebra/Ring/Identities.lean | 55 | 60 | theorem sum_four_sq_mul_sum_four_sq :
(xβ ^ 2 + xβ ^ 2 + xβ ^ 2 + xβ ^ 2) * (yβ ^ 2 + yβ ^ 2 + yβ ^ 2 + yβ ^ 2) =
(xβ * yβ - xβ * yβ - xβ * yβ - xβ * yβ) ^ 2 + (xβ * yβ + xβ * yβ + xβ * yβ - xβ * yβ) ^ 2 +
(xβ * yβ - xβ * yβ + xβ * yβ + xβ * yβ) ^ 2 +
(xβ * yβ + xβ * yβ - xβ * yβ + xβ * yβ) ... |
ring
| [
" (xβ ^ 2 + xβ ^ 2) * (yβ ^ 2 + yβ ^ 2) = (xβ * yβ - xβ * yβ) ^ 2 + (xβ * yβ + xβ * yβ) ^ 2",
" (xβ ^ 2 + n * xβ ^ 2) * (yβ ^ 2 + n * yβ ^ 2) = (xβ * yβ - n * xβ * yβ) ^ 2 + n * (xβ * yβ + xβ * yβ) ^ 2",
" a ^ 4 + 4 * b ^ 4 = ((a - b) ^ 2 + b ^ 2) * ((a + b) ^ 2 + b ^ 2)",
" a ^ 4 + 4 * b ^ 4 = (a ^ 2 - 2 * a... | [
" (xβ ^ 2 + xβ ^ 2) * (yβ ^ 2 + yβ ^ 2) = (xβ * yβ - xβ * yβ) ^ 2 + (xβ * yβ + xβ * yβ) ^ 2",
" (xβ ^ 2 + n * xβ ^ 2) * (yβ ^ 2 + n * yβ ^ 2) = (xβ * yβ - n * xβ * yβ) ^ 2 + n * (xβ * yβ + xβ * yβ) ^ 2",
" a ^ 4 + 4 * b ^ 4 = ((a - b) ^ 2 + b ^ 2) * ((a + b) ^ 2 + b ^ 2)",
" a ^ 4 + 4 * b ^ 4 = (a ^ 2 - 2 * a... |
import Mathlib.RingTheory.Ideal.Basic
import Mathlib.RingTheory.Ideal.Maps
import Mathlib.LinearAlgebra.Finsupp
import Mathlib.RingTheory.GradedAlgebra.Basic
#align_import ring_theory.graded_algebra.homogeneous_ideal from "leanprover-community/mathlib"@"4e861f25ba5ceef42ba0712d8ffeb32f38ad6441"
open SetLike Direc... | Mathlib/RingTheory/GradedAlgebra/HomogeneousIdeal.lean | 102 | 107 | theorem HomogeneousIdeal.ext' {I J : HomogeneousIdeal π} (h : β i, β x β π i, x β I β x β J) :
I = J := by |
ext
rw [I.isHomogeneous.mem_iff, J.isHomogeneous.mem_iff]
apply forall_congr'
exact fun i β¦ h i _ (decompose π _ i).2
| [
" x β I β β (i : ΞΉ), β(((decompose π) x) i) β I",
" x β I",
" β i β DFinsupp.support ((decompose π) x), β(((decompose π) x) i) β I",
" { toSubmodule := x, is_homogeneous' := hx } = { toSubmodule := y, is_homogeneous' := hy }",
" I = J",
" xβ β I.toIdeal β xβ β J.toIdeal",
" (β (i : ΞΉ), β(((decompose ... | [
" x β I β β (i : ΞΉ), β(((decompose π) x) i) β I",
" x β I",
" β i β DFinsupp.support ((decompose π) x), β(((decompose π) x) i) β I",
" { toSubmodule := x, is_homogeneous' := hx } = { toSubmodule := y, is_homogeneous' := hy }",
" I = J"
] |
import Mathlib.CategoryTheory.Abelian.Basic
#align_import category_theory.idempotents.basic from "leanprover-community/mathlib"@"3a061790136d13594ec10c7c90d202335ac5d854"
open CategoryTheory
open CategoryTheory.Category
open CategoryTheory.Limits
open CategoryTheory.Preadditive
open Opposite
namespace Catego... | Mathlib/CategoryTheory/Idempotents/Basic.lean | 63 | 92 | theorem isIdempotentComplete_iff_hasEqualizer_of_id_and_idempotent :
IsIdempotentComplete C β β (X : C) (p : X βΆ X), p β« p = p β HasEqualizer (π X) p := by |
constructor
Β· intro
intro X p hp
rcases IsIdempotentComplete.idempotents_split X p hp with β¨Y, i, e, β¨hβ, hββ©β©
exact
β¨Nonempty.intro
{ cone := Fork.ofΞΉ i (show i β« π X = i β« p by rw [comp_id, β hβ, β assoc, hβ, id_comp])
isLimit := by
apply Fork.IsLimit.mk'
... | [
" IsIdempotentComplete C β β (X : C) (p : X βΆ X), p β« p = p β HasEqualizer (π X) p",
" IsIdempotentComplete C β β (X : C) (p : X βΆ X), p β« p = p β HasEqualizer (π X) p",
" β (X : C) (p : X βΆ X), p β« p = p β HasEqualizer (π X) p",
" HasEqualizer (π X) p",
" i β« π X = i β« p",
" IsLimit (Fork.ofΞΉ i β―)",... | [
" IsIdempotentComplete C β β (X : C) (p : X βΆ X), p β« p = p β HasEqualizer (π X) p"
] |
import Mathlib.Algebra.Polynomial.Degree.Definitions
import Mathlib.Algebra.Polynomial.Induction
#align_import data.polynomial.eval from "leanprover-community/mathlib"@"728baa2f54e6062c5879a3e397ac6bac323e506f"
set_option linter.uppercaseLean3 false
noncomputable section
open Finset AddMonoidAlgebra
open Polyn... | Mathlib/Algebra/Polynomial/Eval.lean | 77 | 78 | theorem evalβ_monomial {n : β} {r : R} : (monomial n r).evalβ f x = f r * x ^ n := by |
simp [evalβ_eq_sum]
| [
" evalβ f x p = p.sum fun e a => f a * x ^ e",
" f = g β s = t β Ο = Ο β evalβ f s Ο = evalβ g t Ο",
" evalβ f s Ο = evalβ f s Ο",
" evalβ f 0 p = f (p.coeff 0)",
" evalβ f x 0 = 0",
" evalβ f x (C a) = f a",
" evalβ f x X = x",
" evalβ f x ((monomial n) r) = f r * x ^ n"
] | [
" evalβ f x p = p.sum fun e a => f a * x ^ e",
" f = g β s = t β Ο = Ο β evalβ f s Ο = evalβ g t Ο",
" evalβ f s Ο = evalβ f s Ο",
" evalβ f 0 p = f (p.coeff 0)",
" evalβ f x 0 = 0",
" evalβ f x (C a) = f a",
" evalβ f x X = x",
" evalβ f x ((monomial n) r) = f r * x ^ n"
] |
import Mathlib.NumberTheory.BernoulliPolynomials
import Mathlib.MeasureTheory.Integral.IntervalIntegral
import Mathlib.Analysis.Calculus.Deriv.Polynomial
import Mathlib.Analysis.Fourier.AddCircle
import Mathlib.Analysis.PSeries
#align_import number_theory.zeta_values from "leanprover-community/mathlib"@"f0c8bf9245297... | Mathlib/NumberTheory/ZetaValues.lean | 49 | 50 | theorem bernoulliFun_eval_zero (k : β) : bernoulliFun k 0 = bernoulli k := by |
rw [bernoulliFun, Polynomial.eval_zero_map, Polynomial.bernoulli_eval_zero, eq_ratCast]
| [
" bernoulliFun k 0 = β(bernoulli k)"
] | [
" bernoulliFun k 0 = β(bernoulli k)"
] |
import Mathlib.Algebra.Field.Basic
import Mathlib.Algebra.Order.Group.Basic
import Mathlib.Algebra.Order.Ring.Basic
import Mathlib.RingTheory.Int.Basic
import Mathlib.Tactic.Ring
import Mathlib.Tactic.FieldSimp
import Mathlib.Data.Int.NatPrime
import Mathlib.Data.ZMod.Basic
#align_import number_theory.pythagorean_tri... | Mathlib/NumberTheory/PythagoreanTriples.lean | 132 | 161 | theorem even_odd_of_coprime (hc : Int.gcd x y = 1) :
x % 2 = 0 β§ y % 2 = 1 β¨ x % 2 = 1 β§ y % 2 = 0 := by |
cases' Int.emod_two_eq_zero_or_one x with hx hx <;>
cases' Int.emod_two_eq_zero_or_one y with hy hy
-- x even, y even
Β· exfalso
apply Nat.not_coprime_of_dvd_of_dvd (by decide : 1 < 2) _ _ hc
Β· apply Int.natCast_dvd.1
apply Int.dvd_of_emod_eq_zero hx
Β· apply Int.natCast_dvd.1
apply Int... | [
" z * z β 2",
" β¨0, β―β© * β¨0, β―β© β 2",
" β¨1, β―β© * β¨1, β―β© β 2",
" β¨2, β―β© * β¨2, β―β© β 2",
" β¨3, β―β© * β¨3, β―β© β 2",
" z * z % 4 β 2",
" Β¬z * z % β4 = 2 % β4",
" Β¬β(z * z) = β2",
" PythagoreanTriple x y z β PythagoreanTriple y x z",
" x * x + y * y = z * z β y * y + x * x = z * z",
" PythagoreanTriple ... | [
" z * z β 2",
" β¨0, β―β© * β¨0, β―β© β 2",
" β¨1, β―β© * β¨1, β―β© β 2",
" β¨2, β―β© * β¨2, β―β© β 2",
" β¨3, β―β© * β¨3, β―β© β 2",
" z * z % 4 β 2",
" Β¬z * z % β4 = 2 % β4",
" Β¬β(z * z) = β2",
" PythagoreanTriple x y z β PythagoreanTriple y x z",
" x * x + y * y = z * z β y * y + x * x = z * z",
" PythagoreanTriple ... |
import Mathlib.Analysis.Convex.Between
import Mathlib.MeasureTheory.Constructions.BorelSpace.Basic
import Mathlib.MeasureTheory.Measure.Lebesgue.Basic
import Mathlib.Topology.MetricSpace.Holder
import Mathlib.Topology.MetricSpace.MetricSeparated
#align_import measure_theory.measure.hausdorff from "leanprover-communit... | Mathlib/MeasureTheory/Measure/Hausdorff.lean | 159 | 226 | theorem borel_le_caratheodory (hm : IsMetric ΞΌ) : borel X β€ ΞΌ.caratheodory := by |
rw [borel_eq_generateFrom_isClosed]
refine MeasurableSpace.generateFrom_le fun t ht => ΞΌ.isCaratheodory_iff_le.2 fun s => ?_
set S : β β Set X := fun n => {x β s | (βn)β»ΒΉ β€ infEdist x t}
have Ssep (n) : IsMetricSeparated (S n) t :=
β¨nβ»ΒΉ, ENNReal.inv_ne_zero.2 (ENNReal.natCast_ne_top _),
fun x hx y hy... | [
" ΞΌ (β i β I, s i) = β i β I, ΞΌ (s i)",
" ΞΌ (β i β β
, s i) = β i β β
, ΞΌ (s i)",
" ΞΌ (β i_1 β insert i I, s i_1) = β i β insert i I, ΞΌ (s i)",
" IsMetricSeparated (s i) (β x β I, s x)",
" borel X β€ ΞΌ.caratheodory",
" MeasurableSpace.generateFrom {s | IsClosed s} β€ ΞΌ.caratheodory",
" ΞΌ (s β© t) + ΞΌ (s \\ t... | [
" ΞΌ (β i β I, s i) = β i β I, ΞΌ (s i)",
" ΞΌ (β i β β
, s i) = β i β β
, ΞΌ (s i)",
" ΞΌ (β i_1 β insert i I, s i_1) = β i β insert i I, ΞΌ (s i)",
" IsMetricSeparated (s i) (β x β I, s x)",
" borel X β€ ΞΌ.caratheodory"
] |
import Mathlib.Data.Matrix.Basic
import Mathlib.LinearAlgebra.Matrix.Trace
#align_import data.matrix.basis from "leanprover-community/mathlib"@"320df450e9abeb5fc6417971e75acb6ae8bc3794"
variable {l m n : Type*}
variable {R Ξ± : Type*}
namespace Matrix
open Matrix
variable [DecidableEq l] [DecidableEq m] [Decida... | Mathlib/Data/Matrix/Basis.lean | 51 | 54 | theorem stdBasisMatrix_add (i : m) (j : n) (a b : Ξ±) :
stdBasisMatrix i j (a + b) = stdBasisMatrix i j a + stdBasisMatrix i j b := by |
unfold stdBasisMatrix; ext
split_ifs with h <;> simp [h]
| [
" r β’ stdBasisMatrix i j a = stdBasisMatrix i j (r β’ a)",
" (r β’ fun i' j' => if i = i' β§ j = j' then a else 0) = fun i' j' => if i = i' β§ j = j' then r β’ a else 0",
" (r β’ fun i' j' => if i = i' β§ j = j' then a else 0) iβ jβ = if i = iβ β§ j = jβ then r β’ a else 0",
" stdBasisMatrix i j 0 = 0",
" (fun i' j'... | [
" r β’ stdBasisMatrix i j a = stdBasisMatrix i j (r β’ a)",
" (r β’ fun i' j' => if i = i' β§ j = j' then a else 0) = fun i' j' => if i = i' β§ j = j' then r β’ a else 0",
" (r β’ fun i' j' => if i = i' β§ j = j' then a else 0) iβ jβ = if i = iβ β§ j = jβ then r β’ a else 0",
" stdBasisMatrix i j 0 = 0",
" (fun i' j'... |
import Mathlib.Order.BooleanAlgebra
import Mathlib.Tactic.Common
#align_import order.heyting.boundary from "leanprover-community/mathlib"@"70d50ecfd4900dd6d328da39ab7ebd516abe4025"
variable {Ξ± : Type*}
namespace Coheyting
variable [CoheytingAlgebra Ξ±] {a b : Ξ±}
def boundary (a : Ξ±) : Ξ± :=
a β οΏ’a
#align cohe... | Mathlib/Order/Heyting/Boundary.lean | 80 | 82 | theorem boundary_inf (a b : Ξ±) : β (a β b) = β a β b β a β β b := by |
unfold boundary
rw [hnot_inf_distrib, inf_sup_left, inf_right_comm, β inf_assoc]
| [
" β β€ = β₯",
" β (οΏ’οΏ’a) = β (οΏ’a)",
" οΏ’β a = β€",
" β (a β b) = β a β b β a β β b",
" a β b β οΏ’(a β b) = a β οΏ’a β b β a β (b β οΏ’b)"
] | [
" β β€ = β₯",
" β (οΏ’οΏ’a) = β (οΏ’a)",
" οΏ’β a = β€",
" β (a β b) = β a β b β a β β b"
] |
import Mathlib.Algebra.BigOperators.Finsupp
import Mathlib.Algebra.BigOperators.Finprod
import Mathlib.Data.Fintype.BigOperators
import Mathlib.LinearAlgebra.Finsupp
import Mathlib.LinearAlgebra.LinearIndependent
import Mathlib.SetTheory.Cardinal.Cofinality
#align_import linear_algebra.basis from "leanprover-communit... | Mathlib/LinearAlgebra/Basis.lean | 167 | 169 | theorem repr_total (v) : b.repr (Finsupp.total _ _ _ b v) = v := by |
rw [β b.coe_repr_symm]
exact b.repr.apply_symm_apply v
| [
" { repr := b } = default",
" f = g",
" { repr := reprβ } = g",
" { repr := reprβΒΉ } = { repr := reprβ }",
" βf.repr.symm = βg.repr.symm",
" (βf.repr.symm ββ Finsupp.lsingle aβ) 1 = (βg.repr.symm ββ Finsupp.lsingle aβ) 1",
" b.repr.symm (Finsupp.single i c) = b.repr.symm (c β’ Finsupp.single i 1)",
" b... | [
" { repr := b } = default",
" f = g",
" { repr := reprβ } = g",
" { repr := reprβΒΉ } = { repr := reprβ }",
" βf.repr.symm = βg.repr.symm",
" (βf.repr.symm ββ Finsupp.lsingle aβ) 1 = (βg.repr.symm ββ Finsupp.lsingle aβ) 1",
" b.repr.symm (Finsupp.single i c) = b.repr.symm (c β’ Finsupp.single i 1)",
" b... |
import Mathlib.Algebra.BigOperators.Group.List
import Mathlib.Algebra.Group.Prod
import Mathlib.Data.Multiset.Basic
#align_import algebra.big_operators.multiset.basic from "leanprover-community/mathlib"@"6c5f73fd6f6cc83122788a80a27cdd54663609f4"
assert_not_exists MonoidWithZero
variable {F ΞΉ Ξ± Ξ² Ξ³ : Type*}
names... | Mathlib/Algebra/BigOperators/Group/Multiset.lean | 125 | 127 | theorem prod_filter_mul_prod_filter_not (p) [DecidablePred p] :
(s.filter p).prod * (s.filter (fun a β¦ Β¬ p a)).prod = s.prod := by |
rw [β prod_add, filter_add_not]
| [
" (fun x x_1 => x * x_1) x ((fun x x_1 => x * x_1) y z) = (fun x x_1 => x * x_1) y ((fun x x_1 => x * x_1) x z)",
" (fun x x_1 => x * x_1) ((fun x x_1 => x * x_1) x y) z = (fun x x_1 => x * x_1) ((fun x x_1 => x * x_1) x z) y",
" foldl (fun x y => y * x) β― 1 s = foldl (fun x x_1 => x * x_1) β― 1 s",
" s.toList... | [
" (fun x x_1 => x * x_1) x ((fun x x_1 => x * x_1) y z) = (fun x x_1 => x * x_1) y ((fun x x_1 => x * x_1) x z)",
" (fun x x_1 => x * x_1) ((fun x x_1 => x * x_1) x y) z = (fun x x_1 => x * x_1) ((fun x x_1 => x * x_1) x z) y",
" foldl (fun x y => y * x) β― 1 s = foldl (fun x x_1 => x * x_1) β― 1 s",
" s.toList... |
import Mathlib.Data.Set.Subsingleton
import Mathlib.Order.WithBot
#align_import data.set.image from "leanprover-community/mathlib"@"001ffdc42920050657fd45bd2b8bfbec8eaaeb29"
universe u v
open Function Set
namespace Set
variable {Ξ± Ξ² Ξ³ : Type*} {ΞΉ ΞΉ' : Sort*}
section Image
variable {f : Ξ± β Ξ²} {s t : Set... | Mathlib/Data/Set/Image.lean | 263 | 263 | theorem image_comp (f : Ξ² β Ξ³) (g : Ξ± β Ξ²) (a : Set Ξ±) : f β g '' a = f '' (g '' a) := by | aesop
| [
" (β y β f '' s, p y) β β β¦x : Ξ±β¦, x β s β p (f x)",
" (β y β f '' s, p y) β β x β s, p (f x)",
" f '' s = g '' s",
" x β f '' s β x β g '' s",
" f a = x β g a = x",
" f '' s β f '' t",
" f a β f '' t",
" f β g '' a = f '' (g '' a)"
] | [
" (β y β f '' s, p y) β β β¦x : Ξ±β¦, x β s β p (f x)",
" (β y β f '' s, p y) β β x β s, p (f x)",
" f '' s = g '' s",
" x β f '' s β x β g '' s",
" f a = x β g a = x",
" f '' s β f '' t",
" f a β f '' t",
" f β g '' a = f '' (g '' a)"
] |
import Mathlib.CategoryTheory.Limits.Preserves.Finite
import Mathlib.CategoryTheory.Limits.Opposites
import Mathlib.CategoryTheory.Limits.Preserves.Shapes.Products
import Mathlib.CategoryTheory.Limits.Shapes.Types
import Mathlib.Topology.Category.TopCat.Limits.Products
universe w w' v u
open CategoryTheory Opposit... | Mathlib/Topology/Category/TopCat/Yoneda.lean | 48 | 58 | theorem piComparison_fac {Ξ± : Type} (X : Ξ± β TopCat) :
piComparison (yonedaPresheaf'.{w, w'} Y) (fun x β¦ op (X x)) =
(yonedaPresheaf' Y).map ((opCoproductIsoProduct X).inv β« (TopCat.sigmaIsoSigma X).inv.op) β«
(equivEquivIso (sigmaEquiv Y (fun x β¦ (X x).1))).inv β« (Types.productIso _).inv := by |
rw [β Category.assoc, Iso.eq_comp_inv]
ext
simp only [yonedaPresheaf', unop_op, piComparison, types_comp_apply,
Types.productIso_hom_comp_eval_apply, Types.pi_lift_Ο_apply, comp_apply, TopCat.coe_of,
unop_comp, Quiver.Hom.unop_op, sigmaEquiv, equivEquivIso_hom, Equiv.toIso_inv,
Equiv.coe_fn_symm_mk, ... | [
" (piComparison (yonedaPresheaf' Y) fun x => { unop := X x }) =\n (yonedaPresheaf' Y).map ((opCoproductIsoProduct X).inv β« (TopCat.sigmaIsoSigma X).inv.op) β«\n (equivEquivIso (sigmaEquiv Y fun x => β(X x))).inv β« (Types.productIso fun i => C(β(X i), Y)).inv",
" (piComparison (yonedaPresheaf' Y) fun x => {... | [
" (piComparison (yonedaPresheaf' Y) fun x => { unop := X x }) =\n (yonedaPresheaf' Y).map ((opCoproductIsoProduct X).inv β« (TopCat.sigmaIsoSigma X).inv.op) β«\n (equivEquivIso (sigmaEquiv Y fun x => β(X x))).inv β« (Types.productIso fun i => C(β(X i), Y)).inv"
] |
import Mathlib.CategoryTheory.Balanced
import Mathlib.CategoryTheory.Limits.EssentiallySmall
import Mathlib.CategoryTheory.Limits.Opposites
import Mathlib.CategoryTheory.Limits.Shapes.ZeroMorphisms
import Mathlib.CategoryTheory.Subobject.Lattice
import Mathlib.CategoryTheory.Subobject.WellPowered
import Mathlib.Data.S... | Mathlib/CategoryTheory/Generator.lean | 109 | 110 | theorem isCoseparating_unop_iff (π’ : Set Cα΅α΅) : IsCoseparating π’.unop β IsSeparating π’ := by |
rw [β isSeparating_op_iff, Set.unop_op]
| [
" IsSeparating π’.op β IsCoseparating π’",
" f = g",
" (h β« f.op).unop = (h β« g.op).unop",
" (f.unop β« h).op = (g.unop β« h).op",
" IsCoseparating π’.op β IsSeparating π’",
" (f.op β« h).unop = (g.op β« h).unop",
" (h β« f.unop).op = (h β« g.unop).op",
" IsCoseparating π’.unop β IsSeparating π’"
] | [
" IsSeparating π’.op β IsCoseparating π’",
" f = g",
" (h β« f.op).unop = (h β« g.op).unop",
" (f.unop β« h).op = (g.unop β« h).op",
" IsCoseparating π’.op β IsSeparating π’",
" (f.op β« h).unop = (g.op β« h).unop",
" (h β« f.unop).op = (h β« g.unop).op",
" IsCoseparating π’.unop β IsSeparating π’"
] |
import Mathlib.Analysis.Convex.Hull
#align_import analysis.convex.extreme from "leanprover-community/mathlib"@"c5773405394e073885e2a144c9ca14637e8eb963"
open Function Set
open scoped Classical
open Affine
variable {π E F ΞΉ : Type*} {Ο : ΞΉ β Type*}
section SMul
variable (π) [OrderedSemiring π] [AddCommMonoi... | Mathlib/Analysis/Convex/Extreme.lean | 111 | 117 | theorem isExtreme_iInter {ΞΉ : Sort*} [Nonempty ΞΉ] {F : ΞΉ β Set E}
(hAF : β i : ΞΉ, IsExtreme π A (F i)) : IsExtreme π A (β i : ΞΉ, F i) := by |
obtain i := Classical.arbitrary ΞΉ
refine β¨iInter_subset_of_subset i (hAF i).1, fun xβ hxβA xβ hxβA x hxF hx β¦ ?_β©
simp_rw [mem_iInter] at hxF β’
have h := fun i β¦ (hAF i).2 hxβA hxβA (hxF i) hx
exact β¨fun i β¦ (h i).1, fun i β¦ (h i).2β©
| [
" IsExtreme π A C",
" xβ β C β§ xβ β C",
" IsExtreme π A (B β© C)",
" β β¦xβ : Eβ¦, xβ β A β β β¦xβ : Eβ¦, xβ β A β β β¦x : Eβ¦, x β B β© C β x β openSegment π xβ xβ β xβ β B β© C β§ xβ β B β© C",
" xβ β B β© C β§ xβ β B β© C",
" IsExtreme π A (β i, F i)",
" xβ β β i, F i β§ xβ β β i, F i",
" (β (i : ΞΉ), xβ β F i... | [
" IsExtreme π A C",
" xβ β C β§ xβ β C",
" IsExtreme π A (B β© C)",
" β β¦xβ : Eβ¦, xβ β A β β β¦xβ : Eβ¦, xβ β A β β β¦x : Eβ¦, x β B β© C β x β openSegment π xβ xβ β xβ β B β© C β§ xβ β B β© C",
" xβ β B β© C β§ xβ β B β© C",
" IsExtreme π A (β i, F i)"
] |
import Mathlib.CategoryTheory.Adjunction.Unique
import Mathlib.CategoryTheory.Adjunction.FullyFaithful
import Mathlib.CategoryTheory.Sites.Sheaf
import Mathlib.CategoryTheory.Limits.Preserves.Finite
universe vβ vβ uβ uβ
namespace CategoryTheory
open Limits
variable {C : Type uβ} [Category.{vβ} C] (J : Grothendiec... | Mathlib/CategoryTheory/Sites/Sheafification.lean | 131 | 138 | theorem isIso_toSheafify {P : Cα΅α΅ β₯€ D} (hP : Presheaf.IsSheaf J P) : IsIso (toSheafify J P) := by |
refine β¨(sheafificationAdjunction J D |>.counit.app β¨P, hPβ©).val, ?_, ?_β©
Β· change _ = (π (sheafToPresheaf J D β π (Cα΅α΅ β₯€ D)) : _).app β¨P, hPβ©
rw [β sheafificationAdjunction J D |>.right_triangle]
rfl
Β· change (sheafToPresheaf _ _).map _ β« _ = _
change _ β« (sheafificationAdjunction J D).unit.app ((... | [
" PreservesFiniteLimits (sheafToPresheaf J A).leftAdjoint",
" sheafifyMap J (π P) = π (sheafify J P)",
" sheafifyMap J (Ξ· β« Ξ³) = sheafifyMap J Ξ· β« sheafifyMap J Ξ³",
" IsIso (toSheafify J P)",
" toSheafify J P β« ((sheafificationAdjunction J D).counit.app { val := P, cond := hP }).val = π P",
" toSheafif... | [
" PreservesFiniteLimits (sheafToPresheaf J A).leftAdjoint",
" sheafifyMap J (π P) = π (sheafify J P)",
" sheafifyMap J (Ξ· β« Ξ³) = sheafifyMap J Ξ· β« sheafifyMap J Ξ³",
" IsIso (toSheafify J P)"
] |
import Mathlib.Algebra.DirectSum.Finsupp
import Mathlib.LinearAlgebra.Finsupp
import Mathlib.LinearAlgebra.DirectSum.TensorProduct
#align_import linear_algebra.direct_sum.finsupp from "leanprover-community/mathlib"@"9b9d125b7be0930f564a68f1d73ace10cf46064d"
noncomputable section
open DirectSum TensorProduct
ope... | Mathlib/LinearAlgebra/DirectSum/Finsupp.lean | 137 | 142 | theorem finsuppRight_apply (t : M β[R] (ΞΉ ββ N)) (i : ΞΉ) :
finsuppRight R M N ΞΉ t i = lTensor M (Finsupp.lapply i) t := by |
induction t using TensorProduct.induction_on with
| zero => simp
| tmul m f => simp [finsuppRight_apply_tmul_apply]
| add x y hx hy => simp [map_add, hx, hy]
| [
" (finsuppLeft R M N ΞΉ) (p ββ[R] n) = p.sum fun i m => Finsupp.single i (m ββ[R] n)",
" (finsuppLeft R M N ΞΉ) (0 ββ[R] n) = Finsupp.sum 0 fun i m => Finsupp.single i (m ββ[R] n)",
" β (f g : ΞΉ ββ M),\n ((finsuppLeft R M N ΞΉ) (f ββ[R] n) = f.sum fun i m => Finsupp.single i (m ββ[R] n)) β\n ((finsuppLeft ... | [
" (finsuppLeft R M N ΞΉ) (p ββ[R] n) = p.sum fun i m => Finsupp.single i (m ββ[R] n)",
" (finsuppLeft R M N ΞΉ) (0 ββ[R] n) = Finsupp.sum 0 fun i m => Finsupp.single i (m ββ[R] n)",
" β (f g : ΞΉ ββ M),\n ((finsuppLeft R M N ΞΉ) (f ββ[R] n) = f.sum fun i m => Finsupp.single i (m ββ[R] n)) β\n ((finsuppLeft ... |
import Mathlib.Analysis.BoxIntegral.Partition.Basic
#align_import analysis.box_integral.partition.split from "leanprover-community/mathlib"@"6ca1a09bc9aa75824bf97388c9e3b441fc4ccf3f"
noncomputable section
open scoped Classical
open Filter
open Function Set Filter
namespace BoxIntegral
variable {ΞΉ M : Type*} {... | Mathlib/Analysis/BoxIntegral/Partition/Split.lean | 147 | 153 | theorem splitLower_ne_splitUpper (I : Box ΞΉ) (i : ΞΉ) (x : β) :
I.splitLower i x β I.splitUpper i x := by |
cases' le_or_lt x (I.lower i) with h
Β· rw [splitUpper_eq_self.2 h, splitLower_eq_bot.2 h]
exact WithBot.bot_ne_coe
Β· refine (disjoint_splitLower_splitUpper I i x).ne ?_
rwa [Ne, splitLower_eq_bot, not_le]
| [
" β(I.splitLower i x) = βI β© {y | y i β€ x}",
" (univ.pi fun i_1 => Ioc (I.lower i_1) (update I.upper i (min x (I.upper i)) i_1)) = βI β© {y | y i β€ x}",
" (y β univ.pi fun i_1 => Ioc (I.lower i_1) (update I.upper i (min x (I.upper i)) i_1)) β y β βI β© {y | y i β€ x}",
" ((β (x : ΞΉ), I.lower x < y x) β§ y i β€ x β§... | [
" β(I.splitLower i x) = βI β© {y | y i β€ x}",
" (univ.pi fun i_1 => Ioc (I.lower i_1) (update I.upper i (min x (I.upper i)) i_1)) = βI β© {y | y i β€ x}",
" (y β univ.pi fun i_1 => Ioc (I.lower i_1) (update I.upper i (min x (I.upper i)) i_1)) β y β βI β© {y | y i β€ x}",
" ((β (x : ΞΉ), I.lower x < y x) β§ y i β€ x β§... |
import Mathlib.Analysis.Calculus.ContDiff.Defs
import Mathlib.Analysis.Calculus.FDeriv.Add
import Mathlib.Analysis.Calculus.FDeriv.Mul
import Mathlib.Analysis.Calculus.Deriv.Inverse
#align_import analysis.calculus.cont_diff from "leanprover-community/mathlib"@"3bce8d800a6f2b8f63fe1e588fd76a9ff4adcebe"
noncomputab... | Mathlib/Analysis/Calculus/ContDiff/Basic.lean | 117 | 118 | theorem contDiffWithinAt_of_subsingleton [Subsingleton F] : ContDiffWithinAt π n f s x := by |
rw [Subsingleton.elim f fun _ => 0]; exact contDiffWithinAt_const
| [
" iteratedFDerivWithin π i (fun x => 0) s x = 0",
" iteratedFDerivWithin π 0 (fun x => 0) s x = 0",
" (iteratedFDerivWithin π 0 (fun x => 0) s x) xβ = 0 xβ",
" iteratedFDerivWithin π (i + 1) (fun x => 0) s x = 0",
" (iteratedFDerivWithin π (i + 1) (fun x => 0) s x) m = 0 m",
" ((fderivWithin π (fun ... | [
" iteratedFDerivWithin π i (fun x => 0) s x = 0",
" iteratedFDerivWithin π 0 (fun x => 0) s x = 0",
" (iteratedFDerivWithin π 0 (fun x => 0) s x) xβ = 0 xβ",
" iteratedFDerivWithin π (i + 1) (fun x => 0) s x = 0",
" (iteratedFDerivWithin π (i + 1) (fun x => 0) s x) m = 0 m",
" ((fderivWithin π (fun ... |
import Mathlib.Init.Control.Combinators
import Mathlib.Data.Option.Defs
import Mathlib.Logic.IsEmpty
import Mathlib.Logic.Relator
import Mathlib.Util.CompileInductive
import Aesop
#align_import data.option.basic from "leanprover-community/mathlib"@"f340f229b1f461aa1c8ee11e0a172d0a3b301a4a"
universe u
namespace Op... | Mathlib/Data/Option/Basic.lean | 108 | 110 | theorem bind_congr {f g : Ξ± β Option Ξ²} {x : Option Ξ±}
(h : β a β x, f a = g a) : x.bind f = x.bind g := by |
cases x <;> simp only [some_bind, none_bind, mem_def, h]
| [
" y β Option.map f o β β x, x β o β§ f x = y",
" f a β Option.map f o β a β o",
" (β (y : Ξ²), y β Option.map f o β p y) β β (x : Ξ±), x β o β p (f x)",
" (β y, y β Option.map f o β§ p y) β β x, x β o β§ p (f x)",
" some aβ = some aβ",
" x.bind f = some b β β a, x = some a β§ f a = some b",
" none.bind f = so... | [
" y β Option.map f o β β x, x β o β§ f x = y",
" f a β Option.map f o β a β o",
" (β (y : Ξ²), y β Option.map f o β p y) β β (x : Ξ±), x β o β p (f x)",
" (β y, y β Option.map f o β§ p y) β β x, x β o β§ p (f x)",
" some aβ = some aβ",
" x.bind f = some b β β a, x = some a β§ f a = some b",
" none.bind f = so... |
import Mathlib.Algebra.Polynomial.Expand
import Mathlib.Algebra.Polynomial.Splits
import Mathlib.Algebra.Squarefree.Basic
import Mathlib.FieldTheory.Minpoly.Field
import Mathlib.RingTheory.PowerBasis
#align_import field_theory.separable from "leanprover-community/mathlib"@"92ca63f0fb391a9ca5f22d2409a6080e786d99f7"
... | Mathlib/FieldTheory/Separable.lean | 138 | 149 | theorem _root_.Associated.separable {f g : R[X]}
(ha : Associated f g) (h : f.Separable) : g.Separable := by |
obtain β¨β¨u, v, h1, h2β©, haβ© := ha
obtain β¨a, b, hβ© := h
refine β¨a * v + b * derivative v, b * v, ?_β©
replace h := congr($h * $(h1))
have h3 := congr(derivative $(h1))
simp only [β ha, derivative_mul, derivative_one] at h3 β’
calc
_ = (a * f + b * derivative f) * (u * v)
+ (b * f) * (derivative u... | [
" Β¬Separable 0",
" False",
" f.Separable",
" (X + C a).Separable",
" IsCoprime (X + C a) 1",
" X.Separable",
" IsCoprime X 1",
" (C r).Separable β IsUnit r",
" g.Separable",
" IsCoprime f g",
" IsUnit f β¨ f.Separable β§ n + 2 = 1 β¨ n + 2 = 0",
" Polynomial.map f a * Polynomial.map f p + Polynom... | [
" Β¬Separable 0",
" False",
" f.Separable",
" (X + C a).Separable",
" IsCoprime (X + C a) 1",
" X.Separable",
" IsCoprime X 1",
" (C r).Separable β IsUnit r",
" g.Separable",
" IsCoprime f g",
" IsUnit f β¨ f.Separable β§ n + 2 = 1 β¨ n + 2 = 0",
" Polynomial.map f a * Polynomial.map f p + Polynom... |
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 | 61 | 66 | theorem IsEquipartition.card_part_eq_average_iff (hP : P.IsEquipartition) (ht : t β P.parts) :
t.card = s.card / P.parts.card β t.card β s.card / P.parts.card + 1 := by |
have a := hP.card_parts_eq_average ht
have b : Β¬(t.card = s.card / P.parts.card β§ t.card = s.card / P.parts.card + 1) := by
by_contra h; exact absurd (h.1 βΈ h.2) (lt_add_one _).ne
tauto
| [
" 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"
] | [
" 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"
] |
import Mathlib.Algebra.Order.BigOperators.Group.Finset
import Mathlib.Data.Set.Subsingleton
#align_import combinatorics.double_counting from "leanprover-community/mathlib"@"1126441d6bccf98c81214a0780c73d499f6721fe"
open Finset Function Relator
variable {Ξ± Ξ² : Type*}
namespace Finset
section Bipartite
varia... | Mathlib/Combinatorics/Enumerative/DoubleCounting.lean | 110 | 120 | theorem card_le_card_of_forall_subsingleton (hs : β a β s, β b, b β t β§ r a b)
(ht : β b β t, ({ a β s | r a b } : Set Ξ±).Subsingleton) : s.card β€ t.card := by |
classical
rw [β mul_one s.card, β mul_one t.card]
exact card_mul_le_card_mul r
(fun a h β¦ card_pos.2 (by
rw [β coe_nonempty, coe_bipartiteAbove]
exact hs _ h : (t.bipartiteAbove r a).Nonempty))
(fun b h β¦ card_le_one.2 (by
simp_rw [mem_bipartiteBelow]
exact ht _ h)... | [
" β a β s, (bipartiteAbove r t a).card = β b β t, (bipartiteBelow r s b).card",
" (β x β s, β a β t, if r x a then 1 else 0) = β x β t, β a β s, if r a x then 1 else 0",
" s.card β€ t.card",
" s.card * 1 β€ t.card * 1",
" (bipartiteAbove r t a).Nonempty",
" {b | b β t β§ r a b}.Nonempty",
" β a β bipartite... | [
" β a β s, (bipartiteAbove r t a).card = β b β t, (bipartiteBelow r s b).card",
" (β x β s, β a β t, if r x a then 1 else 0) = β x β t, β a β s, if r a x then 1 else 0",
" s.card β€ t.card"
] |
import Mathlib.Algebra.BigOperators.Group.Finset
import Mathlib.Data.Finsupp.Defs
import Mathlib.Data.Finset.Pairwise
#align_import data.finsupp.big_operators from "leanprover-community/mathlib"@"59694bd07f0a39c5beccba34bd9f413a160782bf"
variable {ΞΉ M : Type*} [DecidableEq ΞΉ]
theorem List.support_sum_subset [Add... | Mathlib/Data/Finsupp/BigOperators.lean | 81 | 96 | theorem List.support_sum_eq [AddMonoid M] (l : List (ΞΉ ββ M))
(hl : l.Pairwise (_root_.Disjoint on Finsupp.support)) :
l.sum.support = l.foldr (Finsupp.support Β· β Β·) β
:= by |
induction' l with hd tl IH
Β· simp
Β· simp only [List.pairwise_cons] at hl
simp only [List.sum_cons, List.foldr_cons, Function.comp_apply]
rw [Finsupp.support_add_eq, IH hl.right, Finset.sup_eq_union]
suffices _root_.Disjoint hd.support (tl.foldr (fun x y β¦ (Finsupp.support x β y)) β
) by
exact Fi... | [
" l.sum.support β foldr (fun x x_1 => x.support β x_1) β
l",
" [].sum.support β foldr (fun x x_1 => x.support β x_1) β
[]",
" (hd :: tl).sum.support β foldr (fun x x_1 => x.support β x_1) β
(hd :: tl)",
" (hd + tl.sum).support β foldr (fun x x_1 => x.support β x_1) β
(hd :: tl)",
" hd.support β hd.support",... | [
" l.sum.support β foldr (fun x x_1 => x.support β x_1) β
l",
" [].sum.support β foldr (fun x x_1 => x.support β x_1) β
[]",
" (hd :: tl).sum.support β foldr (fun x x_1 => x.support β x_1) β
(hd :: tl)",
" (hd + tl.sum).support β foldr (fun x x_1 => x.support β x_1) β
(hd :: tl)",
" hd.support β hd.support",... |
import Mathlib.Analysis.Calculus.Deriv.Basic
import Mathlib.Analysis.Calculus.FDeriv.Mul
import Mathlib.Analysis.Calculus.FDeriv.Add
#align_import analysis.calculus.deriv.mul from "leanprover-community/mathlib"@"3bce8d800a6f2b8f63fe1e588fd76a9ff4adcebe"
universe u v w
noncomputable section
open scoped Classical... | Mathlib/Analysis/Calculus/Deriv/Mul.lean | 336 | 339 | theorem HasDerivAt.finset_prod (hf : β i β u, HasDerivAt (f i) (f' i) x) :
HasDerivAt (β i β u, f i Β·) (β i β u, (β j β u.erase i, f j x) β’ f' i) x := by |
simpa [ContinuousLinearMap.sum_apply, ContinuousLinearMap.smul_apply] using
(HasFDerivAt.finset_prod (fun i hi β¦ (hf i hi).hasFDerivAt)).hasDerivAt
| [
" HasDerivAt (fun x => β i β u, f i x) (β i β u, (β j β u.erase i, f j x) β’ f' i) x"
] | [
" HasDerivAt (fun x => β i β u, f i x) (β i β u, (β j β u.erase i, f j x) β’ f' i) x"
] |
import Mathlib.Data.Matroid.Restrict
variable {Ξ± : Type*} {M : Matroid Ξ±} {E B I X R J : Set Ξ±}
namespace Matroid
open Set
section EmptyOn
def emptyOn (Ξ± : Type*) : Matroid Ξ± where
E := β
Base := (Β· = β
)
Indep := (Β· = β
)
indep_iff' := by simp [subset_empty_iff]
exists_base := β¨β
, rflβ©
base_exchange... | Mathlib/Data/Matroid/Constructions.lean | 57 | 59 | theorem ground_eq_empty_iff : (M.E = β
) β M = emptyOn Ξ± := by |
simp only [emptyOn, eq_iff_indep_iff_indep_forall, iff_self_and]
exact fun h β¦ by simp [h, subset_empty_iff]
| [
" β β¦I : Set Ξ±β¦, (fun x => x = β
) I β β B, (fun x => x = β
) B β§ I β B",
" ExchangeProperty fun x => x = β
",
" (fun x => x = β
) Yβ β β a β β
\\ Yβ, β b β Yβ \\ β
, (fun x => x = β
) (insert b (β
\\ {a}))",
" β X β β
, ExistsMaximalSubsetProperty (fun x => x = β
) X",
" (maximals (fun x x_1 => x β x_1) {Y | (fun ... | [
" β β¦I : Set Ξ±β¦, (fun x => x = β
) I β β B, (fun x => x = β
) B β§ I β B",
" ExchangeProperty fun x => x = β
",
" (fun x => x = β
) Yβ β β a β β
\\ Yβ, β b β Yβ \\ β
, (fun x => x = β
) (insert b (β
\\ {a}))",
" β X β β
, ExistsMaximalSubsetProperty (fun x => x = β
) X",
" (maximals (fun x x_1 => x β x_1) {Y | (fun ... |
import Mathlib.Analysis.SpecialFunctions.Exponential
#align_import analysis.special_functions.trigonometric.series from "leanprover-community/mathlib"@"ccf84e0d918668460a34aa19d02fe2e0e2286da0"
open NormedSpace
open scoped Nat
section SinCos
theorem Complex.hasSum_cos' (z : β) :
HasSum (fun n : β => (z *... | Mathlib/Analysis/SpecialFunctions/Trigonometric/Series.lean | 75 | 79 | theorem Complex.hasSum_sin (z : β) :
HasSum (fun n : β => (-1) ^ n * z ^ (2 * n + 1) / β(2 * n + 1)!) (Complex.sin z) := by |
convert Complex.hasSum_sin' z using 1
simp_rw [mul_pow, pow_succ, pow_mul, Complex.I_sq, β mul_assoc, mul_div_assoc, div_right_comm,
div_self Complex.I_ne_zero, mul_comm _ ((-1 : β) ^ _), mul_one_div, mul_div_assoc, mul_assoc]
| [
" HasSum (fun n => (z * I) ^ (2 * n) / β(2 * n)!) z.cos",
" HasSum (fun n => (z * I) ^ (2 * n) / β(2 * n)!) ((NormedSpace.exp β (z * I) + NormedSpace.exp β (-z * I)) / 2)",
" HasSum\n (fun c =>\n ((z * I) ^ (2 * (k, c).1 + β(k, c).2) / β(2 * (k, c).1 + β(k, c).2)! +\n (-z * I) ^ (2 * (k, c).1 +... | [
" HasSum (fun n => (z * I) ^ (2 * n) / β(2 * n)!) z.cos",
" HasSum (fun n => (z * I) ^ (2 * n) / β(2 * n)!) ((NormedSpace.exp β (z * I) + NormedSpace.exp β (-z * I)) / 2)",
" HasSum\n (fun c =>\n ((z * I) ^ (2 * (k, c).1 + β(k, c).2) / β(2 * (k, c).1 + β(k, c).2)! +\n (-z * I) ^ (2 * (k, c).1 +... |
import Mathlib.LinearAlgebra.Eigenspace.Basic
import Mathlib.FieldTheory.IsAlgClosed.Spectrum
#align_import linear_algebra.eigenspace.is_alg_closed from "leanprover-community/mathlib"@"6b0169218d01f2837d79ea2784882009a0da1aa1"
open Set Function Module FiniteDimensional
variable {K V : Type*} [Field K] [AddCommGro... | Mathlib/LinearAlgebra/Eigenspace/Triangularizable.lean | 64 | 123 | theorem iSup_genEigenspace_eq_top [IsAlgClosed K] [FiniteDimensional K V] (f : End K V) :
β¨ (ΞΌ : K) (k : β), f.genEigenspace ΞΌ k = β€ := by |
-- We prove the claim by strong induction on the dimension of the vector space.
induction' h_dim : finrank K V using Nat.strong_induction_on with n ih generalizing V
cases' n with n
-- If the vector space is 0-dimensional, the result is trivial.
Β· rw [β top_le_iff]
simp only [Submodule.finrank_eq_zero.1 ... | [
" β c, f.HasEigenvalue c",
" β c, c β spectrum K f",
" β¨ ΞΌ, β¨ k, (f.genEigenspace ΞΌ) k = β€",
" β€ β€ β¨ ΞΌ, β¨ k, (f.genEigenspace ΞΌ) k",
" 0 < finrank ?m.11865 V",
" 0 < n + 1",
" 0 < finrank K β₯ES",
" 0 < finrank K β₯((f.genEigenspace ΞΌβ) (finrank K V))",
" 0 < finrank K β₯((f.genEigenspace ΞΌβ) (n + 1))"... | [
" β c, f.HasEigenvalue c",
" β c, c β spectrum K f",
" β¨ ΞΌ, β¨ k, (f.genEigenspace ΞΌ) k = β€"
] |
import Mathlib.Analysis.SpecialFunctions.Trigonometric.Complex
#align_import analysis.special_functions.trigonometric.complex_deriv from "leanprover-community/mathlib"@"2c1d8ca2812b64f88992a5294ea3dba144755cd1"
noncomputable section
namespace Complex
open Set Filter
open scoped Real
theorem hasStrictDerivAt_t... | Mathlib/Analysis/SpecialFunctions/Trigonometric/ComplexDeriv.lean | 53 | 56 | theorem continuousAt_tan {x : β} : ContinuousAt tan x β cos x β 0 := by |
refine β¨fun hc hβ => ?_, fun h => (hasDerivAt_tan h).continuousAtβ©
exact not_tendsto_nhds_of_tendsto_atTop (tendsto_abs_tan_of_cos_eq_zero hβ) _
(hc.norm.tendsto.mono_left inf_le_left)
| [
" HasStrictDerivAt tan (1 / x.cos ^ 2) x",
" 1 / x.cos ^ 2 = (x.cos * x.cos - x.sin * -x.sin) / x.cos ^ 2",
" (x.sin ^ 2 + x.cos ^ 2) / x.cos ^ 2 = (x.cos * x.cos - x.sin * -x.sin) / x.cos ^ 2",
" Tendsto (fun x => abs x.tan) (π[β ] x) atTop",
" Tendsto (fun x => βx.sinβ / βx.cosβ) (π[β ] x) atTop",
" Fal... | [
" HasStrictDerivAt tan (1 / x.cos ^ 2) x",
" 1 / x.cos ^ 2 = (x.cos * x.cos - x.sin * -x.sin) / x.cos ^ 2",
" (x.sin ^ 2 + x.cos ^ 2) / x.cos ^ 2 = (x.cos * x.cos - x.sin * -x.sin) / x.cos ^ 2",
" Tendsto (fun x => abs x.tan) (π[β ] x) atTop",
" Tendsto (fun x => βx.sinβ / βx.cosβ) (π[β ] x) atTop",
" Fal... |
import Mathlib.Topology.Perfect
import Mathlib.Topology.MetricSpace.Polish
import Mathlib.Topology.MetricSpace.CantorScheme
#align_import topology.perfect from "leanprover-community/mathlib"@"3905fa80e62c0898131285baab35559fbc4e5cda"
open Set Filter
section CantorInjMetric
open Function ENNReal
variable {Ξ± : T... | Mathlib/Topology/MetricSpace/Perfect.lean | 80 | 129 | theorem Perfect.exists_nat_bool_injection [CompleteSpace Ξ±] :
β f : (β β Bool) β Ξ±, range f β C β§ Continuous f β§ Injective f := by |
obtain β¨u, -, upos', huβ© := exists_seq_strictAnti_tendsto' (zero_lt_one' ββ₯0β)
have upos := fun n => (upos' n).1
let P := Subtype fun E : Set Ξ± => Perfect E β§ E.Nonempty
choose C0 C1 h0 h1 hdisj using
fun {C : Set Ξ±} (hC : Perfect C) (hnonempty : C.Nonempty) {Ξ΅ : ββ₯0β} (hΞ΅ : 0 < Ξ΅) =>
hC.small_diam_spl... | [
" let D := closure (EMetric.ball x (Ξ΅ / 2) β© C);\n Perfect D β§ D.Nonempty β§ D β C β§ EMetric.diam D β€ Ξ΅",
" x β EMetric.ball x (Ξ΅ / 2)",
" 0 < Ξ΅ / 2",
" Ξ΅ β 0 β§ 2 β β€",
" 2 β β€",
" closure (EMetric.ball x (Ξ΅ / 2) β© C) β C",
" EMetric.ball x (Ξ΅ / 2) β© C β C",
" EMetric.diam (closure (EMetric.ball x (Ξ΅ ... | [
" let D := closure (EMetric.ball x (Ξ΅ / 2) β© C);\n Perfect D β§ D.Nonempty β§ D β C β§ EMetric.diam D β€ Ξ΅",
" x β EMetric.ball x (Ξ΅ / 2)",
" 0 < Ξ΅ / 2",
" Ξ΅ β 0 β§ 2 β β€",
" 2 β β€",
" closure (EMetric.ball x (Ξ΅ / 2) β© C) β C",
" EMetric.ball x (Ξ΅ / 2) β© C β C",
" EMetric.diam (closure (EMetric.ball x (Ξ΅ ... |
import Mathlib.Analysis.Calculus.ContDiff.Bounds
import Mathlib.Analysis.Calculus.IteratedDeriv.Defs
import Mathlib.Analysis.Calculus.LineDeriv.Basic
import Mathlib.Analysis.LocallyConvex.WithSeminorms
import Mathlib.Analysis.Normed.Group.ZeroAtInfty
import Mathlib.Analysis.SpecialFunctions.Pow.Real
import Mathlib.Ana... | Mathlib/Analysis/Distribution/SchwartzSpace.lean | 210 | 214 | theorem decay_smul_aux (k n : β) (f : π’(E, F)) (c : π) (x : E) :
βxβ ^ k * βiteratedFDeriv β n (c β’ (f : E β F)) xβ =
βcβ * βxβ ^ k * βiteratedFDeriv β n f xβ := by |
rw [mul_comm βcβ, mul_assoc, iteratedFDeriv_const_smul_apply (f.smooth _),
norm_smul c (iteratedFDeriv β n (βf) x)]
| [
" f = g",
" { toFun := toFunβ, smooth' := smooth'β, decay' := decay'β } = g",
" { toFun := toFunβΒΉ, smooth' := smooth'βΒΉ, decay' := decay'βΒΉ } =\n { toFun := toFunβ, smooth' := smooth'β, decay' := decay'β }",
" β C, 0 < C β§ β (x : E), βxβ ^ k * βiteratedFDeriv β n (βf) xβ β€ C",
" 0 < max C 1",
" βxβ ^ ... | [
" f = g",
" { toFun := toFunβ, smooth' := smooth'β, decay' := decay'β } = g",
" { toFun := toFunβΒΉ, smooth' := smooth'βΒΉ, decay' := decay'βΒΉ } =\n { toFun := toFunβ, smooth' := smooth'β, decay' := decay'β }",
" β C, 0 < C β§ β (x : E), βxβ ^ k * βiteratedFDeriv β n (βf) xβ β€ C",
" 0 < max C 1",
" βxβ ^ ... |
import Mathlib.MeasureTheory.Measure.Lebesgue.EqHaar
import Mathlib.MeasureTheory.Covering.Besicovitch
import Mathlib.Tactic.AdaptationNote
#align_import measure_theory.covering.besicovitch_vector_space from "leanprover-community/mathlib"@"fd5edc43dc4f10b85abfe544b88f82cf13c5f844"
universe u
open Metric Set Fini... | Mathlib/MeasureTheory/Covering/BesicovitchVectorSpace.lean | 87 | 89 | theorem centerAndRescale_radius {N : β} {Ο : β} (a : SatelliteConfig E N Ο) :
a.centerAndRescale.r (last N) = 1 := by |
simp [SatelliteConfig.centerAndRescale, inv_mul_cancel (a.rpos _).ne']
| [
" 0 < (fun i => (a.r (last N))β»ΒΉ * a.r i) i",
" (fun i j =>\n (fun i => (a.r (last N))β»ΒΉ * a.r i) i β€\n dist ((fun i => (a.r (last N))β»ΒΉ β’ (a.c i - a.c (last N))) i)\n ((fun i => (a.r (last N))β»ΒΉ β’ (a.c i - a.c (last N))) j) β§\n (fun i => (a.r (last N))β»ΒΉ * a.r i) j β€ Ο * (fu... | [
" 0 < (fun i => (a.r (last N))β»ΒΉ * a.r i) i",
" (fun i j =>\n (fun i => (a.r (last N))β»ΒΉ * a.r i) i β€\n dist ((fun i => (a.r (last N))β»ΒΉ β’ (a.c i - a.c (last N))) i)\n ((fun i => (a.r (last N))β»ΒΉ β’ (a.c i - a.c (last N))) j) β§\n (fun i => (a.r (last N))β»ΒΉ * a.r i) j β€ Ο * (fu... |
import Mathlib.FieldTheory.Normal
import Mathlib.FieldTheory.Perfect
import Mathlib.RingTheory.Localization.Integral
#align_import field_theory.is_alg_closed.basic from "leanprover-community/mathlib"@"00f91228655eecdcd3ac97a7fd8dbcb139fe990a"
universe u v w
open scoped Classical Polynomial
open Polynomial
vari... | Mathlib/FieldTheory/IsAlgClosed/Basic.lean | 104 | 111 | theorem roots_eq_zero_iff [IsAlgClosed k] {p : k[X]} :
p.roots = 0 β p = Polynomial.C (p.coeff 0) := by |
refine β¨fun h => ?_, fun hp => by rw [hp, roots_C]β©
rcases le_or_lt (degree p) 0 with hd | hd
Β· exact eq_C_of_degree_le_zero hd
Β· obtain β¨z, hzβ© := IsAlgClosed.exists_root p hd.ne'
rw [β mem_roots (ne_zero_of_degree_gt hd), h] at hz
simp at hz
| [
" Splits f p",
" Splits f p β Splits (RingHom.id k) (map f p)",
" β z, z ^ n = x",
" (X ^ n - C x).degree β 0",
" βn β 0",
" z ^ n = x",
" β z, x = z * z",
" β z_1, z ^ 2 = z_1 * z_1",
" p.roots = 0 β p = C (p.coeff 0)",
" p.roots = 0",
" p = C (p.coeff 0)"
] | [
" Splits f p",
" Splits f p β Splits (RingHom.id k) (map f p)",
" β z, z ^ n = x",
" (X ^ n - C x).degree β 0",
" βn β 0",
" z ^ n = x",
" β z, x = z * z",
" β z_1, z ^ 2 = z_1 * z_1",
" p.roots = 0 β p = C (p.coeff 0)"
] |
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 | 62 | 67 | theorem mul_matrix_apply [Fintype m] [DecidableEq m] [Semiring Ξ±] (f : l β. m) (M : Matrix m n Ξ±)
(i j) : (f.toMatrix * M :) i j = Option.casesOn (f i) 0 fun fi => M fi j := by |
dsimp [toMatrix, Matrix.mul_apply]
cases' h : f i with fi
Β· simp [h]
Β· rw [Finset.sum_eq_single fi] <;> simp (config := { contextual := true }) [h, eq_comm]
| [
" (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"
] |
import Mathlib.CategoryTheory.Limits.Shapes.Equalizers
import Mathlib.CategoryTheory.Limits.Shapes.Pullbacks
import Mathlib.CategoryTheory.Limits.Shapes.StrongEpi
import Mathlib.CategoryTheory.MorphismProperty.Factorization
#align_import category_theory.limits.shapes.images from "leanprover-community/mathlib"@"563aed... | Mathlib/CategoryTheory/Limits/Shapes/Images.lean | 108 | 115 | theorem ext {F F' : MonoFactorisation f} (hI : F.I = F'.I)
(hm : F.m = eqToHom hI β« F'.m) : F = F' := by |
cases' F with _ Fm _ _ Ffac; cases' F' with _ Fm' _ _ Ffac'
cases' hI
simp? at hm says simp only [eqToHom_refl, Category.id_comp] at hm
congr
apply (cancel_mono Fm).1
rw [Ffac, hm, Ffac']
| [
" F = F'",
" mk Iβ Fm eβ Ffac = F'",
" mk IβΒΉ Fm eβΒΉ Ffac = mk Iβ Fm' eβ Ffac'",
" mk Iβ Fm eβΒΉ Ffac = mk Iβ Fm' eβ Ffac'",
" eβΒΉ = eβ",
" eβΒΉ β« Fm = eβ β« Fm"
] | [
" F = F'"
] |
import Mathlib.Data.Set.Image
import Mathlib.Order.Interval.Set.Basic
#align_import data.set.intervals.with_bot_top from "leanprover-community/mathlib"@"d012cd09a9b256d870751284dd6a29882b0be105"
open Set
variable {Ξ± : Type*}
namespace WithTop
@[simp]
theorem preimage_coe_top : (some : Ξ± β WithTop Ξ±) β»ΒΉ' {β€} =... | Mathlib/Order/Interval/Set/WithBotTop.lean | 59 | 59 | theorem preimage_coe_Icc : (some : Ξ± β WithTop Ξ±) β»ΒΉ' Icc a b = Icc a b := by | simp [β Ici_inter_Iic]
| [
" range some = Iio β€",
" x β range some β x β Iio β€",
" some β»ΒΉ' Icc βa βb = Icc a b"
] | [
" range some = Iio β€",
" x β range some β x β Iio β€",
" some β»ΒΉ' Icc βa βb = Icc a b"
] |
import Mathlib.Analysis.InnerProductSpace.Projection
import Mathlib.Analysis.NormedSpace.Dual
import Mathlib.Analysis.NormedSpace.Star.Basic
#align_import analysis.inner_product_space.dual from "leanprover-community/mathlib"@"46b633fd842bef9469441c0209906f6dddd2b4f5"
noncomputable section
open scoped Classical
o... | Mathlib/Analysis/InnerProductSpace/Dual.lean | 82 | 91 | theorem ext_inner_left_basis {ΞΉ : Type*} {x y : E} (b : Basis ΞΉ π E)
(h : β i : ΞΉ, βͺb i, xβ« = βͺb i, yβ«) : x = y := by |
apply (toDualMap π E).map_eq_iff.mp
refine (Function.Injective.eq_iff ContinuousLinearMap.coe_injective).mp (Basis.ext b ?_)
intro i
simp only [ContinuousLinearMap.coe_coe]
rw [toDualMap_apply, toDualMap_apply]
rw [β inner_conj_symm]
conv_rhs => rw [β inner_conj_symm]
exact congr_arg conj (h i)
| [
" x = y",
" (toDualMap π E) x = (toDualMap π E) y",
" β (i : ΞΉ), β((toDualMap π E) x) (b i) = β((toDualMap π E) y) (b i)",
" β((toDualMap π E) x) (b i) = β((toDualMap π E) y) (b i)",
" ((toDualMap π E) x) (b i) = ((toDualMap π E) y) (b i)",
" βͺx, b iβ«_π = βͺy, b iβ«_π",
" (starRingEnd π) βͺb i, ... | [
" x = y"
] |
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 | 211 | 222 | theorem smul_Ico : r β’ Ico a b = Ico (r β’ a) (r β’ b) := by |
ext x
simp only [mem_smul_set, smul_eq_mul, mem_Ico]
constructor
Β· rintro β¨a, β¨a_h_left_left, a_h_left_rightβ©, rflβ©
constructor
Β· exact (mul_le_mul_left hr).mpr a_h_left_left
Β· exact (mul_lt_mul_left hr).mpr a_h_left_right
Β· rintro β¨a_left, a_rightβ©
use x / r
refine β¨β¨(le_div_iff' hr).mpr... | [
" r β’ Ioo a b = Ioo (r β’ a) (r β’ b)",
" x β r β’ Ioo a b β x β Ioo (r β’ a) (r β’ b)",
" (β y, (a < y β§ y < b) β§ r * y = x) β r * a < x β§ x < r * b",
" (β y, (a < y β§ y < b) β§ r * y = x) β r * a < x β§ x < r * b",
" r * aβ < r * a β§ r * a < r * b",
" r * aβ < r * a",
" r * a < r * b",
" r * a < x β§ x < r ... | [
" r β’ Ioo a b = Ioo (r β’ a) (r β’ b)",
" x β r β’ Ioo a b β x β Ioo (r β’ a) (r β’ b)",
" (β y, (a < y β§ y < b) β§ r * y = x) β r * a < x β§ x < r * b",
" (β y, (a < y β§ y < b) β§ r * y = x) β r * a < x β§ x < r * b",
" r * aβ < r * a β§ r * a < r * b",
" r * aβ < r * a",
" r * a < r * b",
" r * a < x β§ x < r ... |
import Mathlib.Algebra.GCDMonoid.Finset
import Mathlib.Algebra.Polynomial.CancelLeads
import Mathlib.Algebra.Polynomial.EraseLead
import Mathlib.Algebra.Polynomial.FieldDivision
#align_import ring_theory.polynomial.content from "leanprover-community/mathlib"@"7a030ab8eb5d99f05a891dccc49c5b5b90c947d3"
namespace Po... | Mathlib/RingTheory/Polynomial/Content.lean | 106 | 106 | theorem content_one : content (1 : R[X]) = 1 := by | rw [β C_1, content_C, normalize_one]
| [
" p.content β£ p.coeff n",
" p.content β£ 0",
" (C r).content = normalize r",
" (C r).support.gcd (C r).coeff = normalize r",
" content 0 = 0",
" content 1 = 1"
] | [
" p.content β£ p.coeff n",
" p.content β£ 0",
" (C r).content = normalize r",
" (C r).support.gcd (C r).coeff = normalize r",
" content 0 = 0",
" content 1 = 1"
] |
import Mathlib.Algebra.MvPolynomial.PDeriv
import Mathlib.Algebra.Polynomial.AlgebraMap
import Mathlib.Algebra.Polynomial.Derivative
import Mathlib.Data.Nat.Choose.Sum
import Mathlib.LinearAlgebra.LinearIndependent
import Mathlib.RingTheory.Polynomial.Pochhammer
#align_import ring_theory.polynomial.bernstein from "le... | Mathlib/RingTheory/Polynomial/Bernstein.lean | 93 | 99 | theorem eval_at_1 (n Ξ½ : β) : (bernsteinPolynomial R n Ξ½).eval 1 = if Ξ½ = n then 1 else 0 := by |
rw [bernsteinPolynomial]
split_ifs with h
Β· subst h; simp
Β· obtain hΞ½n | hnΞ½ := Ne.lt_or_lt h
Β· simp [zero_pow $ Nat.sub_ne_zero_of_lt hΞ½n]
Β· simp [Nat.choose_eq_zero_of_lt hnΞ½]
| [
" bernsteinPolynomial β€ 3 2 = 3 * X ^ 2 - 3 * X ^ 3",
" 3 * X ^ 2 * (1 - X) = 3 * X ^ 2 - 3 * X ^ 3",
" bernsteinPolynomial R n Ξ½ = 0",
" Polynomial.map f (bernsteinPolynomial R n Ξ½) = bernsteinPolynomial S n Ξ½",
" (bernsteinPolynomial R n Ξ½).comp (1 - X) = bernsteinPolynomial R n (n - Ξ½)",
" bernsteinPol... | [
" bernsteinPolynomial β€ 3 2 = 3 * X ^ 2 - 3 * X ^ 3",
" 3 * X ^ 2 * (1 - X) = 3 * X ^ 2 - 3 * X ^ 3",
" bernsteinPolynomial R n Ξ½ = 0",
" Polynomial.map f (bernsteinPolynomial R n Ξ½) = bernsteinPolynomial S n Ξ½",
" (bernsteinPolynomial R n Ξ½).comp (1 - X) = bernsteinPolynomial R n (n - Ξ½)",
" bernsteinPol... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.