Context stringlengths 285 157k | file_name stringlengths 21 79 | start int64 14 3.67k | end int64 18 3.69k | theorem stringlengths 25 2.71k | proof stringlengths 5 10.6k |
|---|---|---|---|---|---|
/-
Copyright (c) 2018 Kenny Lau. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Kenny Lau
-/
import Mathlib.Algebra.Algebra.Operations
import Mathlib.Data.Fintype.Lattice
import Mathlib.RingTheory.Coprime.Lemmas
#align_import ring_theory.ideal.operations from "leanpro... | Mathlib/RingTheory/Ideal/Operations.lean | 382 | 387 | theorem smul_comap_le_comap_smul (f : M →ₗ[R] M') (S : Submodule R M') (I : Ideal R) :
I • S.comap f ≤ (I • S).comap f := by |
refine Submodule.smul_le.mpr fun r hr x hx => ?_
rw [Submodule.mem_comap] at hx ⊢
rw [f.map_smul]
exact Submodule.smul_mem_smul hr hx
|
/-
Copyright (c) 2018 Chris Hughes. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Chris Hughes, Abhimanyu Pallavi Sudhir, Jean Lo, Calle Sönne, Sébastien Gouëzel,
Rémy Degenne, David Loeffler
-/
import Mathlib.Analysis.SpecialFunctions.Pow.Real
#align_import analys... | Mathlib/Analysis/SpecialFunctions/Pow/NNReal.lean | 554 | 566 | theorem rpow_mul (x : ℝ≥0∞) (y z : ℝ) : x ^ (y * z) = (x ^ y) ^ z := by |
cases' x with x
· rcases lt_trichotomy y 0 with (Hy | Hy | Hy) <;>
rcases lt_trichotomy z 0 with (Hz | Hz | Hz) <;>
simp [Hy, Hz, zero_rpow_of_neg, zero_rpow_of_pos, top_rpow_of_neg, top_rpow_of_pos,
mul_pos_of_neg_of_neg, mul_neg_of_neg_of_pos, mul_neg_of_pos_of_neg]
· by_cases h : x = 0
... |
/-
Copyright (c) 2020 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
-/
import Mathlib.Algebra.BigOperators.Fin
import Mathlib.Algebra.GeomSum
import Mathlib.LinearAlgebra.Matrix.Block
import Mathlib.LinearAlgebra.Matrix.Determinant.Basic
impor... | Mathlib/LinearAlgebra/Vandermonde.lean | 176 | 181 | theorem eq_zero_of_forall_index_sum_mul_pow_eq_zero {R : Type*} [CommRing R] [IsDomain R] {n : ℕ}
{f v : Fin n → R} (hf : Function.Injective f) (hfv : ∀ j, (∑ i, v i * f j ^ (i : ℕ)) = 0) :
v = 0 := by |
apply eq_zero_of_forall_index_sum_pow_mul_eq_zero hf
simp_rw [mul_comm]
exact hfv
|
/-
Copyright (c) 2023 Josha Dekker. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Josha Dekker
-/
import Mathlib.Topology.Bases
import Mathlib.Order.Filter.CountableInter
import Mathlib.Topology.Compactness.SigmaCompact
/-!
# Lindelöf sets and Lindelöf spaces
## Mai... | Mathlib/Topology/Compactness/Lindelof.lean | 696 | 699 | theorem HereditarilyLindelof_LindelofSets [HereditarilyLindelofSpace X] (s : Set X):
IsLindelof s := by |
apply HereditarilyLindelofSpace.isHereditarilyLindelof_univ
exact subset_univ s
|
/-
Copyright (c) 2014 Parikshit Khanna. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Parikshit Khanna, Jeremy Avigad, Leonardo de Moura, Floris van Doorn, Mario Carneiro
-/
import Batteries.Control.ForInStep.Lemmas
import Batteries.Data.List.Basic
import Batteries.Ta... | .lake/packages/batteries/Batteries/Data/List/Lemmas.lean | 1,379 | 1,380 | theorem mem_range {m n : Nat} : m ∈ range n ↔ m < n := by |
simp only [range_eq_range', mem_range'_1, Nat.zero_le, true_and, Nat.zero_add]
|
/-
Copyright (c) 2020 Yury G. Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury G. Kudryashov
-/
import Mathlib.Analysis.SpecialFunctions.Pow.NNReal
import Mathlib.Analysis.SpecialFunctions.Pow.Continuity
import Mathlib.Analysis.SumOverResidueClass
#alig... | Mathlib/Analysis/PSeries.lean | 363 | 367 | theorem tendsto_sum_range_one_div_nat_succ_atTop :
Tendsto (fun n => ∑ i ∈ Finset.range n, (1 / (i + 1) : ℝ)) atTop atTop := by |
rw [← not_summable_iff_tendsto_nat_atTop_of_nonneg]
· exact_mod_cast mt (_root_.summable_nat_add_iff 1).1 not_summable_one_div_natCast
· exact fun i => by positivity
|
/-
Copyright (c) 2020 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel
-/
import Mathlib.Algebra.BigOperators.Fin
import Mathlib.Algebra.Order.BigOperators.Group.Finset
import Mathlib.Data.Finset.Sort
import Mathlib.Data.Set.Subsingle... | Mathlib/Combinatorics/Enumerative/Composition.lean | 921 | 930 | theorem blocks_partial_sum {i : ℕ} (h : i < c.boundaries.card) :
(c.blocks.take i).sum = c.boundary ⟨i, h⟩ := by |
induction' i with i IH
· simp
have A : i < c.blocks.length := by
rw [c.card_boundaries_eq_succ_length] at h
simp [blocks, Nat.lt_of_succ_lt_succ h]
have B : i < c.boundaries.card := lt_of_lt_of_le A (by simp [blocks, length, Nat.sub_le])
rw [sum_take_succ _ _ A, IH B]
simp [blocks, blocksFun, get_o... |
/-
Copyright (c) 2020 Heather Macbeth, Patrick Massot. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Heather Macbeth, Patrick Massot
-/
import Mathlib.Algebra.Group.Subgroup.Basic
import Mathlib.Algebra.Order.Archimedean
import Mathlib.Data.Set.Lattice
#align_import ... | Mathlib/GroupTheory/Archimedean.lean | 91 | 95 | theorem AddSubgroup.cyclic_of_isolated_zero {H : AddSubgroup G} {a : G} (h₀ : 0 < a)
(hd : Disjoint (H : Set G) (Ioo 0 a)) : ∃ b, H = closure {b} := by |
rcases eq_or_ne H ⊥ with rfl | hbot
· exact ⟨0, closure_singleton_zero.symm⟩
· exact (exists_isLeast_pos hbot h₀ hd).imp fun _ => cyclic_of_min
|
/-
Copyright (c) 2018 Chris Hughes. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Chris Hughes, Johannes Hölzl, Scott Morrison, Jens Wagemaker
-/
import Mathlib.Algebra.MonoidAlgebra.Degree
import Mathlib.Algebra.Polynomial.Coeff
import Mathlib.Algebra.Polynomial.Mono... | Mathlib/Algebra/Polynomial/Degree/Definitions.lean | 938 | 942 | theorem leadingCoeff_add_of_degree_lt (h : degree p < degree q) :
leadingCoeff (p + q) = leadingCoeff q := by |
have : coeff p (natDegree q) = 0 := coeff_natDegree_eq_zero_of_degree_lt h
simp only [leadingCoeff, natDegree_eq_of_degree_eq (degree_add_eq_right_of_degree_lt h), this,
coeff_add, zero_add]
|
/-
Copyright (c) 2022 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Felix Weilacher
-/
import Mathlib.Data.Real.Cardinality
import Mathlib.Topology.MetricSpace.Perfect
import Mathlib.MeasureTheory.Constructions.BorelSpace.Metric
i... | Mathlib/MeasureTheory/Constructions/Polish.lean | 272 | 285 | theorem AnalyticSet.iUnion [Countable ι] {s : ι → Set α} (hs : ∀ n, AnalyticSet (s n)) :
AnalyticSet (⋃ n, s n) := by |
/- For the proof, write each `s n` as the continuous image under a map `f n` of a
Polish space `β n`. The union space `γ = Σ n, β n` is also Polish, and the map `F : γ → α` which
coincides with `f n` on `β n` sends it to `⋃ n, s n`. -/
choose β hβ h'β f f_cont f_range using fun n =>
analyticSet_iff_exi... |
/-
Copyright (c) 2020 Yury Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury Kudryashov, Frédéric Dupuis
-/
import Mathlib.Analysis.Convex.Hull
#align_import analysis.convex.cone.basic from "leanprover-community/mathlib"@"915591b2bb3ea303648db07284a161a7... | Mathlib/Analysis/Convex/Cone/Basic.lean | 368 | 369 | theorem salient_iff_not_flat (S : ConvexCone 𝕜 E) : S.Salient ↔ ¬S.Flat := by |
simp [Salient, Flat]
|
/-
Copyright (c) 2015 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Leonardo de Moura, Jeremy Avigad, Mario Carneiro
-/
import Mathlib.Data.List.Count
import Mathlib.Data.List.Dedup
import Mathlib.Data.List.InsertNth
import Mathlib.Data.List.Lat... | Mathlib/Data/List/Perm.lean | 619 | 632 | theorem perm_of_mem_permutationsAux :
∀ {ts is l : List α}, l ∈ permutationsAux ts is → l ~ ts ++ is := by |
show ∀ (ts is l : List α), l ∈ permutationsAux ts is → l ~ ts ++ is
refine permutationsAux.rec (by simp) ?_
introv IH1 IH2 m
rw [permutationsAux_cons, permutations, mem_foldr_permutationsAux2] at m
rcases m with (m | ⟨l₁, l₂, m, _, rfl⟩)
· exact (IH1 _ m).trans perm_middle
· have p : l₁ ++ l₂ ~ is := by
... |
/-
Copyright (c) 2020 Kevin Kappelmann. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Kevin Kappelmann
-/
import Mathlib.Algebra.ContinuedFractions.Computation.Approximations
import Mathlib.Algebra.ContinuedFractions.Computation.CorrectnessTerminating
import Mathlib.D... | Mathlib/Algebra/ContinuedFractions/Computation/TerminatesIffRat.lean | 228 | 236 | theorem coe_of_rat_eq :
(⟨(of q).h, (of q).s.map (Pair.map (↑))⟩ : GeneralizedContinuedFraction K) = of v := by |
cases' gcf_v_eq : of v with h s; subst v
-- Porting note: made coercion target explicit
obtain rfl : ↑⌊(q : K)⌋ = h := by injection gcf_v_eq
-- Porting note: was
-- simp [coe_of_h_rat_eq rfl, coe_of_s_rat_eq rfl, gcf_v_eq]
simp only [gcf_v_eq, Int.cast_inj, Rat.floor_cast, of_h_eq_floor, eq_self_iff_true,
... |
/-
Copyright (c) 2022 Robert Y. Lewis. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Robert Y. Lewis, Heather Macbeth
-/
import Mathlib.Data.Nat.Cast.WithTop
import Mathlib.FieldTheory.IsAlgClosed.Basic
import Mathlib.RingTheory.WittVector.DiscreteValuationRing
#alig... | Mathlib/RingTheory/WittVector/FrobeniusFractionField.lean | 162 | 168 | theorem solution_nonzero {a₁ a₂ : 𝕎 k} (ha₁ : a₁.coeff 0 ≠ 0) (ha₂ : a₂.coeff 0 ≠ 0) :
solution p a₁ a₂ ≠ 0 := by |
intro h
have := solution_spec p a₁ a₂
rw [h, zero_pow] at this
· simpa [ha₁, ha₂] using _root_.div_eq_zero_iff.mp this.symm
· exact Nat.sub_ne_zero_of_lt hp.out.one_lt
|
/-
Copyright (c) 2023 Peter Nelson. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Peter Nelson
-/
import Mathlib.SetTheory.Cardinal.Finite
#align_import data.set.ncard from "leanprover-community/mathlib"@"74c2af38a828107941029b03839882c5c6f87a04"
/-!
# Noncomputable... | Mathlib/Data/Set/Card.lean | 306 | 307 | theorem one_lt_encard_iff : 1 < s.encard ↔ ∃ a b, a ∈ s ∧ b ∈ s ∧ a ≠ b := by |
rw [← not_iff_not, not_exists, not_lt, encard_le_one_iff]; aesop
|
/-
Copyright (c) 2022 Vincent Beffara. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Vincent Beffara
-/
import Mathlib.Analysis.Analytic.IsolatedZeros
import Mathlib.Analysis.Complex.CauchyIntegral
import Mathlib.Analysis.Complex.AbsMax
#align_import analysis.complex... | Mathlib/Analysis/Complex/OpenMapping.lean | 113 | 157 | theorem AnalyticAt.eventually_constant_or_nhds_le_map_nhds {z₀ : E} (hg : AnalyticAt ℂ g z₀) :
(∀ᶠ z in 𝓝 z₀, g z = g z₀) ∨ 𝓝 (g z₀) ≤ map g (𝓝 z₀) := by |
/- The idea of the proof is to use the one-dimensional version applied to the restriction of `g`
to lines going through `z₀` (indexed by `sphere (0 : E) 1`). If the restriction is eventually
constant along each of these lines, then the identity theorem implies that `g` is constant on
any ball centered at... |
/-
Copyright (c) 2022 Joseph Myers. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Joseph Myers, Heather Macbeth
-/
import Mathlib.Analysis.InnerProductSpace.TwoDim
import Mathlib.Geometry.Euclidean.Angle.Unoriented.Basic
#align_import geometry.euclidean.angle.oriente... | Mathlib/Geometry/Euclidean/Angle/Oriented/Basic.lean | 1,064 | 1,083 | theorem abs_oangle_sub_left_toReal_lt_pi_div_two {x y : V} (h : ‖x‖ = ‖y‖) :
|(o.oangle (y - x) y).toReal| < π / 2 := by |
by_cases hn : x = y; · simp [hn, div_pos, Real.pi_pos]
have hs : ((2 : ℤ) • o.oangle (y - x) y).sign = (o.oangle (y - x) y).sign := by
conv_rhs => rw [oangle_sign_sub_left_swap]
rw [o.oangle_eq_pi_sub_two_zsmul_oangle_sub_of_norm_eq hn h, Real.Angle.sign_pi_sub]
rw [Real.Angle.sign_two_zsmul_eq_sign_iff]... |
/-
Copyright (c) 2017 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl, Mario Carneiro, Floris van Doorn
-/
import Mathlib.Data.Fintype.BigOperators
import Mathlib.Data.Finsupp.Defs
import Mathlib.Data.Nat.Cast.Order
import Mathlib.Data.Set... | Mathlib/SetTheory/Cardinal/Basic.lean | 1,515 | 1,518 | theorem card_le_of {α : Type u} {n : ℕ} (H : ∀ s : Finset α, s.card ≤ n) : #α ≤ n := by |
contrapose! H
apply exists_finset_le_card α (n+1)
simpa only [nat_succ, succ_le_iff] using H
|
/-
Copyright (c) 2020 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen, Wen Yang
-/
import Mathlib.LinearAlgebra.GeneralLinearGroup
import Mathlib.LinearAlgebra.Matrix.Adjugate
import Mathlib.LinearAlgebra.Matrix.Transvection
import Mathlib.RingT... | Mathlib/LinearAlgebra/Matrix/SpecialLinearGroup.lean | 511 | 511 | theorem coe_T_inv : ↑ₘT⁻¹ = !![1, -1; 0, 1] := by | simp [coe_inv, coe_T, adjugate_fin_two]
|
/-
Copyright (c) 2019 Zhouhang Zhou. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Zhouhang Zhou
-/
import Mathlib.MeasureTheory.Function.LpOrder
#align_import measure_theory.function.l1_space from "leanprover-community/mathlib"@"ccdbfb6e5614667af5aa3ab2d50885e0ef44a... | Mathlib/MeasureTheory/Function/L1Space.lean | 1,452 | 1,453 | theorem toL1_coeFn (f : α →₁[μ] β) (hf : Integrable f μ) : hf.toL1 f = f := by |
simp [Integrable.toL1]
|
/-
Copyright (c) 2020 Aaron Anderson. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Aaron Anderson
-/
import Mathlib.Algebra.GCDMonoid.Finset
import Mathlib.Algebra.Polynomial.CancelLeads
import Mathlib.Algebra.Polynomial.EraseLead
import Mathlib.Algebra.Polynomial.Fi... | Mathlib/RingTheory/Polynomial/Content.lean | 311 | 318 | theorem aeval_primPart_eq_zero {S : Type*} [Ring S] [IsDomain S] [Algebra R S]
[NoZeroSMulDivisors R S] {p : R[X]} {s : S} (hpzero : p ≠ 0) (hp : aeval s p = 0) :
aeval s p.primPart = 0 := by |
rw [eq_C_content_mul_primPart p, map_mul, aeval_C] at hp
have hcont : p.content ≠ 0 := fun h => hpzero (content_eq_zero_iff.1 h)
replace hcont := Function.Injective.ne (NoZeroSMulDivisors.algebraMap_injective R S) hcont
rw [map_zero] at hcont
exact eq_zero_of_ne_zero_of_mul_left_eq_zero hcont hp
|
/-
Copyright (c) 2017 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Algebra.Associated
import Mathlib.Algebra.Star.Unitary
import Mathlib.RingTheory.Int.Basic
import Mathlib.RingTheory.PrincipalIdealDomain
import Mathli... | Mathlib/NumberTheory/Zsqrtd/Basic.lean | 1,067 | 1,069 | theorem norm_eq_one_iff_mem_unitary {d : ℤ} {a : ℤ√d} : a.norm = 1 ↔ a ∈ unitary (ℤ√d) := by |
rw [unitary.mem_iff_self_mul_star, ← norm_eq_mul_conj]
norm_cast
|
/-
Copyright (c) 2019 Zhouhang Zhou. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Zhouhang Zhou, Sébastien Gouëzel, Frédéric Dupuis
-/
import Mathlib.Algebra.DirectSum.Module
import Mathlib.Analysis.Complex.Basic
import Mathlib.Analysis.Convex.Uniform
import Mathlib.... | Mathlib/Analysis/InnerProductSpace/Basic.lean | 1,065 | 1,068 | theorem norm_sub_mul_self (x y : E) :
‖x - y‖ * ‖x - y‖ = ‖x‖ * ‖x‖ - 2 * re ⟪x, y⟫ + ‖y‖ * ‖y‖ := by |
repeat' rw [← sq (M := ℝ)]
exact norm_sub_sq _ _
|
/-
Copyright (c) 2022 Damiano Testa. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Damiano Testa
-/
import Mathlib.Algebra.MonoidAlgebra.Basic
import Mathlib.Data.Finset.Pointwise
#align_import algebra.monoid_algebra.support from "leanprover-community/mathlib"@"16749... | Mathlib/Algebra/MonoidAlgebra/Support.lean | 95 | 97 | theorem mem_span_support (f : MonoidAlgebra k G) :
f ∈ Submodule.span k (of k G '' (f.support : Set G)) := by |
erw [of, MonoidHom.coe_mk, ← supported_eq_span_single, Finsupp.mem_supported]
|
/-
Copyright (c) 2014 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Leonardo de Moura, Jeremy Avigad, Floris van Doorn, Mario Carneiro
-/
import Batteries.Tactic.Init
import Batteries.Tactic.Alias
import Batteries.Tactic.Lint.Misc
instance {f :... | .lake/packages/batteries/Batteries/Logic.lean | 94 | 97 | theorem eqRec_heq_self {α : Sort _} {a : α} {motive : (a' : α) → a = a' → Sort _}
(x : motive a (rfl : a = a)) {a' : α} (e : a = a') :
HEq (@Eq.rec α a motive x a' e) x := by |
subst e; rfl
|
/-
Copyright (c) 2019 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl
-/
import Mathlib.Data.Finsupp.Encodable
import Mathlib.LinearAlgebra.Pi
import Mathlib.LinearAlgebra.Span
import Mathlib.Data.Set.Countable
#align_import linear_algebr... | Mathlib/LinearAlgebra/Finsupp.lean | 1,187 | 1,190 | theorem Fintype.total_apply_single [DecidableEq α] (i : α) (r : R) :
Fintype.total R S v (Pi.single i r) = r • v i := by |
simp_rw [Fintype.total_apply, Pi.single_apply, ite_smul, zero_smul]
rw [Finset.sum_ite_eq', if_pos (Finset.mem_univ _)]
|
/-
Copyright (c) 2021 Yaël Dillies. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yaël Dillies
-/
import Mathlib.Order.Interval.Finset.Nat
import Mathlib.Data.PNat.Defs
#align_import data.pnat.interval from "leanprover-community/mathlib"@"1d29de43a5ba4662dd33b5cfeecf... | Mathlib/Data/PNat/Interval.lean | 76 | 81 | theorem card_Ico : (Ico a b).card = b - a := by |
rw [← Nat.card_Ico]
-- Porting note: I had to change this to `erw` *and* provide the proof, yuck.
-- https://github.com/leanprover-community/mathlib4/issues/5164
erw [← Finset.map_subtype_embedding_Ico _ a b (fun c x _ hx _ hc _ => hc.trans_le hx)]
rw [card_map]
|
/-
Copyright (c) 2023 Floris van Doorn. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Floris van Doorn, Heather Macbeth
-/
import Mathlib.MeasureTheory.Constructions.Pi
import Mathlib.MeasureTheory.Integral.Lebesgue
/-!
# Marginals of multivariate functions
In this ... | Mathlib/MeasureTheory/Integral/Marginal.lean | 230 | 235 | theorem lmarginal_le_of_subset {f g : (∀ i, π i) → ℝ≥0∞} (hst : s ⊆ t)
(hf : Measurable f) (hg : Measurable g) (hfg : ∫⋯∫⁻_s, f ∂μ ≤ ∫⋯∫⁻_s, g ∂μ) :
∫⋯∫⁻_t, f ∂μ ≤ ∫⋯∫⁻_t, g ∂μ := by |
rw [← union_sdiff_of_subset hst, lmarginal_union' μ f hf disjoint_sdiff,
lmarginal_union' μ g hg disjoint_sdiff]
exact lmarginal_mono hfg
|
/-
Copyright (c) 2019 Zhouhang Zhou. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Zhouhang Zhou, Frédéric Dupuis, Heather Macbeth
-/
import Mathlib.Analysis.Convex.Basic
import Mathlib.Analysis.InnerProductSpace.Orthogonal
import Mathlib.Analysis.InnerProductSpace.Sy... | Mathlib/Analysis/InnerProductSpace/Projection.lean | 537 | 540 | theorem orthogonalProjection_minimal {U : Submodule 𝕜 E} [HasOrthogonalProjection U] (y : E) :
‖y - orthogonalProjection U y‖ = ⨅ x : U, ‖y - x‖ := by |
rw [norm_eq_iInf_iff_inner_eq_zero _ (Submodule.coe_mem _)]
exact orthogonalProjection_inner_eq_zero _
|
/-
Copyright (c) 2015 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Leonardo de Moura, Jeremy Avigad, Minchao Wu, Mario Carneiro
-/
import Mathlib.Data.Finset.Attr
import Mathlib.Data.Multiset.FinsetOps
import Mathlib.Logic.Equiv.Set
import Math... | Mathlib/Data/Finset/Basic.lean | 3,002 | 3,003 | theorem range_eq_empty_iff : range n = ∅ ↔ n = 0 := by |
rw [← not_nonempty_iff_eq_empty, nonempty_range_iff, not_not]
|
/-
Copyright (c) 2018 Kenny Lau. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Kenny Lau, Yury Kudryashov
-/
import Mathlib.FieldTheory.Perfect
#align_import field_theory.perfect_closure from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a"
... | Mathlib/FieldTheory/PerfectClosure.lean | 388 | 393 | theorem natCast_eq_iff (x y : ℕ) : (x : PerfectClosure K p) = y ↔ (x : K) = y := by |
constructor <;> intro H
· rw [natCast K p 0, natCast K p 0, mk_eq_iff] at H
cases' H with z H
simpa only [zero_add, iterate_fixed (frobenius_natCast K p _)] using H
rw [natCast K p 0, natCast K p 0, H]
|
/-
Copyright (c) 2021 Eric Wieser. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Eric Wieser
-/
import Mathlib.GroupTheory.Perm.Cycle.Type
import Mathlib.GroupTheory.Perm.Option
import Mathlib.Logic.Equiv.Fin
import Mathlib.Logic.Equiv.Fintype
#align_import group_the... | Mathlib/GroupTheory/Perm/Fin.lean | 306 | 312 | theorem cycleType_cycleRange {n : ℕ} {i : Fin (n + 1)} (h0 : i ≠ 0) :
cycleType (cycleRange i) = {(i + 1 : ℕ)} := by |
cases' i with i hi
cases i
· exact (h0 rfl).elim
rw [cycleRange, cycleType_extendDomain]
exact cycleType_finRotate
|
/-
Copyright (c) 2021 Yury Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury Kudryashov
-/
import Mathlib.Analysis.BoxIntegral.Partition.Filter
import Mathlib.Analysis.BoxIntegral.Partition.Measure
import Mathlib.Topology.UniformSpace.Compact
import Mathl... | Mathlib/Analysis/BoxIntegral/Basic.lean | 449 | 452 | theorem convergenceR_cond (h : Integrable I l f vol) (ε : ℝ) (c : ℝ≥0) :
l.RCond (h.convergenceR ε c) := by |
rw [convergenceR]; split_ifs with h₀
exacts [(hasIntegral_iff.1 h.hasIntegral ε h₀).choose_spec.1 _, fun _ x => rfl]
|
/-
Copyright (c) 2020 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel
-/
import Mathlib.Topology.Separation
import Mathlib.Topology.UniformSpace.Basic
import Mathlib.Topology.UniformSpace.Cauchy
#align_import topology.uniform_space.... | Mathlib/Topology/UniformSpace/UniformConvergence.lean | 563 | 571 | theorem tendstoUniformlyOn_of_seq_tendstoUniformlyOn {l : Filter ι} [l.IsCountablyGenerated]
(h : ∀ u : ℕ → ι, Tendsto u atTop l → TendstoUniformlyOn (fun n => F (u n)) f atTop s) :
TendstoUniformlyOn F f l s := by |
rw [tendstoUniformlyOn_iff_tendsto, tendsto_iff_seq_tendsto]
intro u hu
rw [tendsto_prod_iff'] at hu
specialize h (fun n => (u n).fst) hu.1
rw [tendstoUniformlyOn_iff_tendsto] at h
exact h.comp (tendsto_id.prod_mk hu.2)
|
/-
Copyright (c) 2020 Rémy Degenne. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Rémy Degenne, Eric Wieser
-/
import Mathlib.MeasureTheory.Function.LpSeminorm.Basic
import Mathlib.MeasureTheory.Integral.MeanInequalities
#align_import measure_theory.function.lp_semin... | Mathlib/MeasureTheory/Function/LpSeminorm/CompareExp.lean | 158 | 196 | theorem snorm_le_snorm_top_mul_snorm (p : ℝ≥0∞) (f : α → E) {g : α → F}
(hg : AEStronglyMeasurable g μ) (b : E → F → G)
(h : ∀ᵐ x ∂μ, ‖b (f x) (g x)‖₊ ≤ ‖f x‖₊ * ‖g x‖₊) :
snorm (fun x => b (f x) (g x)) p μ ≤ snorm f ∞ μ * snorm g p μ := by |
by_cases hp_top : p = ∞
· simp_rw [hp_top, snorm_exponent_top]
refine le_trans (essSup_mono_ae <| h.mono fun a ha => ?_) (ENNReal.essSup_mul_le _ _)
simp_rw [Pi.mul_apply, ← ENNReal.coe_mul, ENNReal.coe_le_coe]
exact ha
by_cases hp_zero : p = 0
· simp only [hp_zero, snorm_exponent_zero, mul_zero, l... |
/-
Copyright (c) 2020 Kenji Nakagawa. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Kenji Nakagawa, Anne Baanen, Filippo A. E. Nuccio
-/
import Mathlib.Algebra.Algebra.Subalgebra.Pointwise
import Mathlib.AlgebraicGeometry.PrimeSpectrum.Maximal
import Mathlib.Algebraic... | Mathlib/RingTheory/DedekindDomain/Ideal.lean | 148 | 150 | theorem spanSingleton_div_spanSingleton (x y : K) :
spanSingleton R₁⁰ x / spanSingleton R₁⁰ y = spanSingleton R₁⁰ (x / y) := by |
rw [div_spanSingleton, mul_comm, spanSingleton_mul_spanSingleton, div_eq_mul_inv]
|
/-
Copyright (c) 2021 Ashvni Narayanan. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Ashvni Narayanan, Anne Baanen
-/
import Mathlib.Algebra.Ring.Int
import Mathlib.RingTheory.DedekindDomain.IntegralClosure
#align_import number_theory.number_field.basic from "leanpr... | Mathlib/NumberTheory/NumberField/Basic.lean | 193 | 196 | theorem isIntegral (x : 𝓞 K) : IsIntegral ℤ x := by |
obtain ⟨P, hPm, hP⟩ := x.isIntegral_coe
refine ⟨P, hPm, ?_⟩
rwa [IsScalarTower.algebraMap_eq (S := 𝓞 K), ← Polynomial.hom_eval₂, coe_eq_zero_iff] at hP
|
/-
Copyright (c) 2022 Kexing Ying. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Kexing Ying
-/
import Mathlib.Probability.Martingale.BorelCantelli
import Mathlib.Probability.ConditionalExpectation
import Mathlib.Probability.Independence.Basic
#align_import probabili... | Mathlib/Probability/BorelCantelli.lean | 60 | 66 | theorem iIndepSet.condexp_indicator_filtrationOfSet_ae_eq (hsm : ∀ n, MeasurableSet (s n))
(hs : iIndepSet s μ) (hij : i < j) :
μ[(s j).indicator (fun _ => 1 : Ω → ℝ)|filtrationOfSet hsm i] =ᵐ[μ]
fun _ => (μ (s j)).toReal := by |
rw [Filtration.filtrationOfSet_eq_natural (β := ℝ) hsm]
refine (iIndepFun.condexp_natural_ae_eq_of_lt _ hs.iIndepFun_indicator hij).trans ?_
simp only [integral_indicator_const _ (hsm _), Algebra.id.smul_eq_mul, mul_one]; rfl
|
/-
Copyright (c) 2020 Frédéric Dupuis. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Frédéric Dupuis
-/
import Mathlib.Data.Real.Sqrt
import Mathlib.Analysis.NormedSpace.Star.Basic
import Mathlib.Analysis.NormedSpace.ContinuousLinearMap
import Mathlib.Analysis.NormedS... | Mathlib/Analysis/RCLike/Basic.lean | 362 | 365 | theorem sub_conj (z : K) : z - conj z = 2 * im z * I :=
calc
z - conj z = re z + im z * I - (re z - im z * I) := by | rw [re_add_im, ← conj_eq_re_sub_im]
_ = 2 * im z * I := by rw [add_sub_sub_cancel, ← two_mul, mul_assoc]
|
/-
Copyright (c) 2020 Thomas Browning, Patrick Lutz. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Thomas Browning, Patrick Lutz
-/
import Mathlib.FieldTheory.IsAlgClosed.AlgebraicClosure
import Mathlib.RingTheory.IntegralDomain
#align_import field_theory.primitive_e... | Mathlib/FieldTheory/PrimitiveElement.lean | 395 | 402 | theorem primitive_element_iff_algHom_eq_of_eval' (α : E) :
F⟮α⟯ = ⊤ ↔ Function.Injective fun φ : E →ₐ[F] A ↦ φ α := by |
classical
simp_rw [primitive_element_iff_minpoly_natDegree_eq, ← card_rootSet_eq_natDegree (K := A)
(IsSeparable.separable F α) (hA _), ← toFinset_card,
← (Algebra.IsAlgebraic.of_finite F E).range_eval_eq_rootSet_minpoly_of_splits _ hA α,
← AlgHom.card_of_splits F E A hA, Fintype.card, toFinset_range, ... |
/-
Copyright (c) 2018 Chris Hughes. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Chris Hughes, Johannes Hölzl, Scott Morrison, Jens Wagemaker
-/
import Mathlib.Algebra.Polynomial.Derivative
import Mathlib.Algebra.Polynomial.Roots
import Mathlib.RingTheory.EuclideanDo... | Mathlib/Algebra/Polynomial/FieldDivision.lean | 487 | 490 | theorem rootSet_X_pow [CommRing S] [IsDomain S] [Algebra R S] {n : ℕ} (hn : n ≠ 0) :
(X ^ n : R[X]).rootSet S = {0} := by |
rw [← one_mul (X ^ n : R[X]), ← C_1, rootSet_C_mul_X_pow hn]
exact one_ne_zero
|
/-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro, Johannes Hölzl, Sander Dahmen, Scott Morrison
-/
import Mathlib.LinearAlgebra.LinearIndependent
#align_import linear_algebra.dimension from "leanprover-community/mathl... | Mathlib/LinearAlgebra/Dimension/Basic.lean | 135 | 142 | theorem lift_rank_le_of_surjective_injective (i : ZeroHom R R') (j : M →+ M')
(hi : Surjective i) (hj : Injective j) (hc : ∀ (r : R) (m : M), j (r • m) = i r • j m) :
lift.{v'} (Module.rank R M) ≤ lift.{v} (Module.rank R' M') := by |
obtain ⟨i', hi'⟩ := hi.hasRightInverse
refine lift_rank_le_of_injective_injective i' j (fun _ h ↦ ?_) hj fun r m ↦ ?_
· apply_fun i at h
rwa [hi', i.map_zero] at h
rw [hc (i' r) m, hi']
|
/-
Copyright (c) 2020 Bhavik Mehta. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Bhavik Mehta
-/
import Mathlib.CategoryTheory.Limits.Shapes.SplitCoequalizer
import Mathlib.CategoryTheory.Limits.Preserves.Basic
#align_import category_theory.limits.preserves.shapes.e... | Mathlib/CategoryTheory/Limits/Preserves/Shapes/Equalizers.lean | 215 | 218 | theorem map_π_preserves_coequalizer_inv_desc {W : D} (k : G.obj Y ⟶ W)
(wk : G.map f ≫ k = G.map g ≫ k) : G.map (coequalizer.π f g) ≫
(PreservesCoequalizer.iso G f g).inv ≫ coequalizer.desc k wk = k := by |
rw [← Category.assoc, map_π_preserves_coequalizer_inv, coequalizer.π_desc]
|
/-
Copyright (c) 2017 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Logic.Relation
import Mathlib.Data.Option.Basic
import Mathlib.Data.Seq.Seq
#align_import data.seq.wseq from "leanprover-community/mathlib"@"a7... | Mathlib/Data/Seq/WSeq.lean | 1,053 | 1,061 | theorem exists_of_liftRel_left {R : α → β → Prop} {s t} (H : LiftRel R s t) {a} (h : a ∈ s) :
∃ b, b ∈ t ∧ R a b := by |
let ⟨n, h⟩ := exists_get?_of_mem h
-- Porting note: This line is required to infer metavariables in
-- `Computation.exists_of_mem_map`.
dsimp only [get?, head] at h
let ⟨some (_, s'), sd, rfl⟩ := Computation.exists_of_mem_map h
let ⟨some (b, t'), td, ⟨ab, _⟩⟩ := (liftRel_dropn_destruct H n).l... |
/-
Copyright (c) 2020 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Floris van Doorn
-/
import Mathlib.Geometry.Manifold.MFDeriv.Defs
#align_import geometry.manifold.mfderiv from "leanprover-community/mathlib"@"e473c3198bb41f6856... | Mathlib/Geometry/Manifold/MFDeriv/Basic.lean | 352 | 355 | theorem mfderivWithin_inter (ht : t ∈ 𝓝 x) :
mfderivWithin I I' f (s ∩ t) x = mfderivWithin I I' f s x := by |
rw [mfderivWithin, mfderivWithin, extChartAt_preimage_inter_eq, mdifferentiableWithinAt_inter ht,
fderivWithin_inter (extChartAt_preimage_mem_nhds I ht)]
|
/-
Copyright (c) 2017 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl, Mario Carneiro, Jeremy Avigad
-/
import Mathlib.Order.Filter.Lift
import Mathlib.Topology.Defs.Filter
#align_import topology.basic from "leanprover-community/mathlib"@... | Mathlib/Topology/Basic.lean | 737 | 738 | theorem isClosed_frontier : IsClosed (frontier s) := by |
rw [frontier_eq_closure_inter_closure]; exact IsClosed.inter isClosed_closure isClosed_closure
|
/-
Copyright (c) 2021 Yury G. Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury G. Kudryashov
-/
import Mathlib.Geometry.Manifold.Algebra.Structures
import Mathlib.Geometry.Manifold.BumpFunction
import Mathlib.Topology.MetricSpace.PartitionOfUnity
import ... | Mathlib/Geometry/Manifold/PartitionOfUnity.lean | 620 | 631 | theorem exists_isSubordinate {s : Set M} (hs : IsClosed s) (U : ι → Set M) (ho : ∀ i, IsOpen (U i))
(hU : s ⊆ ⋃ i, U i) : ∃ f : SmoothPartitionOfUnity ι I M s, f.IsSubordinate U := by |
haveI : LocallyCompactSpace H := I.locallyCompactSpace
haveI : LocallyCompactSpace M := ChartedSpace.locallyCompactSpace H M
-- porting note(https://github.com/leanprover/std4/issues/116):
-- split `rcases` into `have` + `rcases`
have := BumpCovering.exists_isSubordinate_of_prop (Smooth I 𝓘(ℝ)) ?_ hs U ho h... |
/-
Copyright (c) 2022 Andrew Yang. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Andrew Yang
-/
import Mathlib.AlgebraicGeometry.GammaSpecAdjunction
import Mathlib.AlgebraicGeometry.Restrict
import Mathlib.CategoryTheory.Limits.Opposites
import Mathlib.RingTheory.Loca... | Mathlib/AlgebraicGeometry/AffineScheme.lean | 209 | 215 | theorem isBasis_affine_open (X : Scheme) : Opens.IsBasis X.affineOpens := by |
rw [Opens.isBasis_iff_nbhd]
rintro U x (hU : x ∈ (U : Set X))
obtain ⟨S, hS, hxS, hSU⟩ := X.affineBasisCover_is_basis.exists_subset_of_mem_open hU U.isOpen
refine ⟨⟨S, X.affineBasisCover_is_basis.isOpen hS⟩, ?_, hxS, hSU⟩
rcases hS with ⟨i, rfl⟩
exact rangeIsAffineOpenOfOpenImmersion _
|
/-
Copyright (c) 2019 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen, Eric Wieser
-/
import Mathlib.Data.Matrix.Basic
/-!
# Row and column matrices
This file provides results about row and column matrices
## Main definitions
* `Matrix.row r... | Mathlib/Data/Matrix/RowCol.lean | 123 | 126 | theorem col_vecMul [Fintype m] [NonUnitalNonAssocSemiring α] (M : Matrix m n α) (v : m → α) :
Matrix.col (v ᵥ* M) = (Matrix.row v * M)ᵀ := by |
ext
rfl
|
/-
Copyright (c) 2017 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro
-/
import Mathlib.Algebra.Order.Group.Basic
import Mathlib.Algebra.Order.Ring.Basic
import Mathlib.Algebra.Star.Unitary
import Mathlib.Data.Nat.ModEq
import Mathlib.Numb... | Mathlib/NumberTheory/PellMatiyasevic.lean | 778 | 799 | theorem eq_of_xn_modEq' {i j n} (ipos : 0 < i) (hin : i ≤ n) (j4n : j ≤ 4 * n)
(h : xn a1 j ≡ xn a1 i [MOD xn a1 n]) : j = i ∨ j + i = 4 * n :=
have i2n : i ≤ 2 * n := by | apply le_trans hin; rw [two_mul]; apply Nat.le_add_left
(le_or_gt j (2 * n)).imp
(fun j2n : j ≤ 2 * n =>
eq_of_xn_modEq a1 j2n i2n h fun a2 n1 =>
⟨fun j0 i2 => by rw [n1, i2] at hin; exact absurd hin (by decide), fun _ i0 =>
_root_.ne_of_gt ipos i0⟩)
fun j2n : 2 * n < j =>
suffice... |
/-
Copyright (c) 2020 Yury Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury Kudryashov, Frédéric Dupuis
-/
import Mathlib.Analysis.Convex.Hull
#align_import analysis.convex.cone.basic from "leanprover-community/mathlib"@"915591b2bb3ea303648db07284a161a7... | Mathlib/Analysis/Convex/Cone/Basic.lean | 670 | 674 | theorem convexHull_toCone_isLeast (s : Set E) :
IsLeast { t : ConvexCone 𝕜 E | s ⊆ t } ((convex_convexHull 𝕜 s).toCone _) := by |
convert (convex_convexHull 𝕜 s).toCone_isLeast using 1
ext t
exact ⟨fun h => convexHull_min h t.convex, (subset_convexHull 𝕜 s).trans⟩
|
/-
Copyright (c) 2020 Johan Commelin. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johan Commelin
-/
import Mathlib.Algebra.Group.Basic
import Mathlib.Algebra.GroupWithZero.NeZero
import Mathlib.Logic.Unique
#align_import algebra.group_with_zero.basic from "leanprov... | Mathlib/Algebra/GroupWithZero/Basic.lean | 406 | 407 | theorem one_div_ne_zero {a : G₀} (h : a ≠ 0) : 1 / a ≠ 0 := by |
simpa only [one_div] using inv_ne_zero h
|
/-
Copyright (c) 2014 Jeremy Avigad. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jeremy Avigad, Leonardo de Moura, Johannes Hölzl, Mario Carneiro
-/
import Mathlib.Logic.Pairwise
import Mathlib.Order.CompleteBooleanAlgebra
import Mathlib.Order.Directed
import Mathli... | Mathlib/Data/Set/Lattice.lean | 2,141 | 2,142 | theorem Ici_iSup₂ (f : ∀ i, κ i → α) : Ici (⨆ (i) (j), f i j) = ⋂ (i) (j), Ici (f i j) := by |
simp_rw [Ici_iSup]
|
/-
Copyright (c) 2019 Zhouhang Zhou. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Zhouhang Zhou, Frédéric Dupuis, Heather Macbeth
-/
import Mathlib.Analysis.Convex.Basic
import Mathlib.Analysis.InnerProductSpace.Orthogonal
import Mathlib.Analysis.InnerProductSpace.Sy... | Mathlib/Analysis/InnerProductSpace/Projection.lean | 575 | 582 | theorem LinearIsometry.map_orthogonalProjection {E E' : Type*} [NormedAddCommGroup E]
[NormedAddCommGroup E'] [InnerProductSpace 𝕜 E] [InnerProductSpace 𝕜 E'] (f : E →ₗᵢ[𝕜] E')
(p : Submodule 𝕜 E) [HasOrthogonalProjection p] [HasOrthogonalProjection (p.map f.toLinearMap)]
(x : E) : f (orthogonalProjecti... |
refine (eq_orthogonalProjection_of_mem_of_inner_eq_zero ?_ fun y hy => ?_).symm
· refine Submodule.apply_coe_mem_map _ _
rcases hy with ⟨x', hx', rfl : f x' = y⟩
rw [← f.map_sub, f.inner_map_map, orthogonalProjection_inner_eq_zero x x' hx']
|
/-
Copyright (c) 2022 Jujian Zhang. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jujian Zhang, Scott Morrison, Joël Riou
-/
import Mathlib.CategoryTheory.Preadditive.Injective
import Mathlib.Algebra.Homology.ShortComplex.HomologicalComplex
import Mathlib.Algebra.Homo... | Mathlib/CategoryTheory/Preadditive/InjectiveResolution.lean | 104 | 106 | theorem ι_f_zero_comp_complex_d :
I.ι.f 0 ≫ I.cocomplex.d 0 1 = 0 := by |
simp
|
/-
Copyright (c) 2021 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel
-/
import Mathlib.MeasureTheory.Measure.Trim
import Mathlib.MeasureTheory.MeasurableSpace.CountablyGenerated
#align_import measure_theory.measure.ae_measurable fr... | Mathlib/MeasureTheory/Measure/AEMeasurable.lean | 82 | 118 | theorem sum_measure [Countable ι] {μ : ι → Measure α} (h : ∀ i, AEMeasurable f (μ i)) :
AEMeasurable f (sum μ) := by |
nontriviality β
inhabit β
set s : ι → Set α := fun i => toMeasurable (μ i) { x | f x ≠ (h i).mk f x }
have hsμ : ∀ i, μ i (s i) = 0 := by
intro i
rw [measure_toMeasurable]
exact (h i).ae_eq_mk
have hsm : MeasurableSet (⋂ i, s i) :=
MeasurableSet.iInter fun i => measurableSet_toMeasurable _ _
... |
/-
Copyright (c) 2017 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl
-/
import Mathlib.Algebra.BigOperators.GroupWithZero.Finset
import Mathlib.Algebra.BigOperators.Ring.Multiset
import Mathlib.Algebra.Field.Defs
import Mathlib.Data.Finty... | Mathlib/Algebra/BigOperators/Ring.lean | 207 | 227 | theorem prod_add_ordered [LinearOrder ι] [CommSemiring α] (s : Finset ι) (f g : ι → α) :
∏ i ∈ s, (f i + g i) =
(∏ i ∈ s, f i) +
∑ i ∈ s,
g i * (∏ j ∈ s.filter (· < i), (f j + g j)) * ∏ j ∈ s.filter fun j => i < j, f j := by |
refine Finset.induction_on_max s (by simp) ?_
clear s
intro a s ha ihs
have ha' : a ∉ s := fun ha' => lt_irrefl a (ha a ha')
rw [prod_insert ha', prod_insert ha', sum_insert ha', filter_insert, if_neg (lt_irrefl a),
filter_true_of_mem ha, ihs, add_mul, mul_add, mul_add, add_assoc]
congr 1
rw [add_com... |
/-
Copyright (c) 2021 Yury Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury Kudryashov
-/
import Mathlib.Analysis.Convex.Between
import Mathlib.MeasureTheory.Constructions.BorelSpace.Basic
import Mathlib.MeasureTheory.Measure.Lebesgue.Basic
import Mathli... | Mathlib/MeasureTheory/Measure/Hausdorff.lean | 469 | 471 | theorem OuterMeasure.coe_mkMetric [MeasurableSpace X] [BorelSpace X] (m : ℝ≥0∞ → ℝ≥0∞) :
⇑(OuterMeasure.mkMetric m : OuterMeasure X) = Measure.mkMetric m := by |
rw [← Measure.mkMetric_toOuterMeasure, Measure.coe_toOuterMeasure]
|
/-
Copyright (c) 2019 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, Bhavik Mehta
-/
import Mathlib.CategoryTheory.Comma.Over
import Mathlib.CategoryTheory.DiscreteCategory
import Mathlib.CategoryTheory.EpiMono
import Mathlib.CategoryThe... | Mathlib/CategoryTheory/Limits/Shapes/BinaryProducts.lean | 886 | 889 | theorem coprod.desc_comp_inl_comp_inr {W X Y Z : C} [HasBinaryCoproduct W Y]
[HasBinaryCoproduct X Z] (g : W ⟶ X) (g' : Y ⟶ Z) :
coprod.desc (g ≫ coprod.inl) (g' ≫ coprod.inr) = coprod.map g g' := by |
rw [← coprod.map_desc]; simp
|
/-
Copyright (c) 2020 Kevin Kappelmann. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Kevin Kappelmann
-/
import Mathlib.Algebra.ContinuedFractions.Computation.CorrectnessTerminating
import Mathlib.Algebra.Order.Group.Basic
import Mathlib.Algebra.Order.Ring.Basic
impo... | Mathlib/Algebra/ContinuedFractions/Computation/Approximations.lean | 194 | 234 | theorem fib_le_of_continuantsAux_b :
n ≤ 1 ∨ ¬(of v).TerminatedAt (n - 2) → (fib n : K) ≤ ((of v).continuantsAux n).b :=
Nat.strong_induction_on n
(by
intro n IH hyp
rcases n with (_ | _ | n)
· simp [fib_add_two, continuantsAux] -- case n = 0
· simp [fib_add_two, continuantsAux] -- cas... | omega
have not_terminated_at_n : ¬g.TerminatedAt n := Or.resolve_left hyp this
obtain ⟨gp, s_ppred_nth_eq⟩ : ∃ gp, g.s.get? n = some gp :=
Option.ne_none_iff_exists'.mp not_terminated_at_n
set pconts := g.continuantsAux (n + 1) with pconts_eq
set ppconts := g.continuantsAux n ... |
/-
Copyright (c) 2018 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl, Jens Wagemaker, Aaron Anderson
-/
import Mathlib.Algebra.BigOperators.Associated
import Mathlib.Algebra.GCDMonoid.Basic
import Mathlib.Data.Finsupp.Multiset
import Math... | Mathlib/RingTheory/UniqueFactorizationDomain.lean | 682 | 683 | theorem normalizedFactors_zero : normalizedFactors (0 : α) = 0 := by |
simp [normalizedFactors, factors]
|
/-
Copyright (c) 2017 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl
-/
import Mathlib.Init.Algebra.Classes
import Mathlib.Logic.Nontrivial.Basic
import Mathlib.Order.BoundedOrder
import Mathlib.Data.Option.NAry
import Mathlib.Tactic.Lift... | Mathlib/Order/WithBot.lean | 894 | 895 | theorem coe_le_coe : (a : WithTop α) ≤ b ↔ a ≤ b := by |
simp only [← toDual_le_toDual_iff, toDual_apply_coe, WithBot.coe_le_coe, toDual_le_toDual]
|
/-
Copyright (c) 2021 David Wärn. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: David Wärn, Joachim Breitner
-/
import Mathlib.Algebra.FreeMonoid.Basic
import Mathlib.Algebra.Group.Submonoid.Membership
import Mathlib.GroupTheory.Congruence.Basic
import Mathlib.GroupTh... | Mathlib/GroupTheory/CoprodI.lean | 535 | 539 | theorem equivPair_smul_same {i} (m : M i) (w : Word M) :
equivPair i (of m • w) = ⟨m * (equivPair i w).head, (equivPair i w).tail,
(equivPair i w).fstIdx_ne⟩ := by |
rw [of_smul_def, ← equivPair_symm]
simp
|
/-
Copyright (c) 2020 Johan Commelin. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johan Commelin
-/
import Mathlib.Algebra.CharP.Two
import Mathlib.Algebra.CharP.Reduced
import Mathlib.Algebra.NeZero
import Mathlib.Algebra.Polynomial.RingDivision
import Mathlib.Grou... | Mathlib/RingTheory/RootsOfUnity/Basic.lean | 989 | 1,013 | theorem nthRoots_one_eq_biUnion_primitiveRoots' {ζ : R} {n : ℕ+} (h : IsPrimitiveRoot ζ n) :
nthRootsFinset n R = (Nat.divisors ↑n).biUnion fun i => primitiveRoots i R := by |
symm
apply Finset.eq_of_subset_of_card_le
· intro x
simp only [nthRootsFinset, ← Multiset.toFinset_eq (nthRoots_one_nodup h), exists_prop,
Finset.mem_biUnion, Finset.mem_filter, Finset.mem_range, mem_nthRoots, Finset.mem_mk,
Nat.mem_divisors, and_true_iff, Ne, PNat.ne_zero, PNat.pos, not_false_if... |
/-
Copyright (c) 2021 Yury Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury Kudryashov
-/
import Mathlib.MeasureTheory.Measure.AEMeasurable
#align_import measure_theory.group.arithmetic from "leanprover-community/mathlib"@"a75898643b2d774cced9ae7c0b28c2... | Mathlib/MeasureTheory/Group/Arithmetic.lean | 398 | 404 | theorem nullMeasurableSet_eq_fun {E} [MeasurableSpace E] [AddGroup E] [MeasurableSingletonClass E]
[MeasurableSub₂ E] {f g : α → E} (hf : AEMeasurable f μ) (hg : AEMeasurable g μ) :
NullMeasurableSet { x | f x = g x } μ := by |
apply (measurableSet_eq_fun hf.measurable_mk hg.measurable_mk).nullMeasurableSet.congr
filter_upwards [hf.ae_eq_mk, hg.ae_eq_mk] with x hfx hgx
change (hf.mk f x = hg.mk g x) = (f x = g x)
simp only [hfx, hgx]
|
/-
Copyright (c) 2019 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, Yaël Dillies
-/
import Mathlib.Order.Cover
import Mathlib.Order.Interval.Finset.Defs
#align_import data.finset.locally_finite from "leanprover-community/mathlib"@"442a... | Mathlib/Order/Interval/Finset/Basic.lean | 345 | 349 | theorem Ico_filter_le_of_left_le {a b c : α} [DecidablePred (c ≤ ·)] (hac : a ≤ c) :
(Ico a b).filter (c ≤ ·) = Ico c b := by |
ext x
rw [mem_filter, mem_Ico, mem_Ico, and_comm, and_left_comm]
exact and_iff_right_of_imp fun h => hac.trans h.1
|
/-
Copyright (c) 2021 Heather Macbeth. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Heather Macbeth
-/
import Mathlib.Analysis.SpecialFunctions.Exp
import Mathlib.Topology.ContinuousFunction.Basic
import Mathlib.Analysis.Normed.Field.UnitBall
#align_import analysis.... | Mathlib/Analysis/Complex/Circle.lean | 66 | 66 | theorem normSq_eq_of_mem_circle (z : circle) : normSq z = 1 := by | simp [normSq_eq_abs]
|
/-
Copyright (c) 2021 Anatole Dedecker. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anatole Dedecker, Bhavik Mehta
-/
import Mathlib.Analysis.Calculus.Deriv.Support
import Mathlib.Analysis.SpecialFunctions.Pow.Deriv
import Mathlib.MeasureTheory.Integral.FundThmCalcu... | Mathlib/MeasureTheory/Integral/IntegralEqImproper.lean | 434 | 438 | theorem AECover.integrable_of_lintegral_nnnorm_bounded [l.NeBot] [l.IsCountablyGenerated]
{φ : ι → Set α} (hφ : AECover μ l φ) {f : α → E} (I : ℝ) (hfm : AEStronglyMeasurable f μ)
(hbounded : ∀ᶠ i in l, (∫⁻ x in φ i, ‖f x‖₊ ∂μ) ≤ ENNReal.ofReal I) : Integrable f μ := by |
refine ⟨hfm, (le_of_tendsto ?_ hbounded).trans_lt ENNReal.ofReal_lt_top⟩
exact hφ.lintegral_tendsto_of_countably_generated hfm.ennnorm
|
/-
Copyright (c) 2020 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel
-/
import Mathlib.Algebra.Algebra.Defs
import Mathlib.Algebra.Order.BigOperators.Group.Finset
import Mathlib.Data.Fintype.BigOperators
import Mathlib.Data.Fintype.... | Mathlib/LinearAlgebra/Multilinear/Basic.lean | 1,827 | 1,836 | theorem curryFinFinset_symm_apply_piecewise_const_aux {k l n : ℕ} {s : Finset (Fin n)}
(hk : s.card = k) (hl : sᶜ.card = l)
(f : MultilinearMap R (fun _ : Fin k => M') (MultilinearMap R (fun _ : Fin l => M') M₂))
(x y : M') :
((⇑f fun _ => x) (fun i => (Finset.piecewise s (fun _ => x) (fun _ => y)
... |
have := curryFinFinset_symm_apply_piecewise_const hk hl f x y
simp only [curryFinFinset_symm_apply, finSumEquivOfFinset_inl, Finset.orderEmbOfFin_mem,
Finset.piecewise_eq_of_mem, finSumEquivOfFinset_inr] at this
exact this
|
/-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro, Johannes Hölzl
-/
import Mathlib.Dynamics.Ergodic.MeasurePreserving
import Mathlib.MeasureTheory.Function.SimpleFunc
import Mathlib.MeasureTheory.Measure.MutuallySingul... | Mathlib/MeasureTheory/Integral/Lebesgue.lean | 1,330 | 1,333 | theorem lintegral_biUnion_finset₀ {s : Finset β} {t : β → Set α}
(hd : Set.Pairwise (↑s) (AEDisjoint μ on t)) (hm : ∀ b ∈ s, NullMeasurableSet (t b) μ)
(f : α → ℝ≥0∞) : ∫⁻ a in ⋃ b ∈ s, t b, f a ∂μ = ∑ b ∈ s, ∫⁻ a in t b, f a ∂μ := by |
simp only [← Finset.mem_coe, lintegral_biUnion₀ s.countable_toSet hm hd, ← Finset.tsum_subtype']
|
/-
Copyright (c) 2019 Zhouhang Zhou. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Zhouhang Zhou, Yury Kudryashov, Patrick Massot
-/
import Mathlib.MeasureTheory.Integral.IntervalIntegral
import Mathlib.Order.Filter.IndicatorFunction
/-!
# The dominated convergence t... | Mathlib/MeasureTheory/Integral/DominatedConvergence.lean | 167 | 184 | theorem _root_.Antitone.tendsto_setIntegral (hsm : ∀ i, MeasurableSet (s i)) (h_anti : Antitone s)
(hfi : IntegrableOn f (s 0) μ) :
Tendsto (fun i => ∫ a in s i, f a ∂μ) atTop (𝓝 (∫ a in ⋂ n, s n, f a ∂μ)) := by |
let bound : α → ℝ := indicator (s 0) fun a => ‖f a‖
have h_int_eq : (fun i => ∫ a in s i, f a ∂μ) = fun i => ∫ a, (s i).indicator f a ∂μ :=
funext fun i => (integral_indicator (hsm i)).symm
rw [h_int_eq]
rw [← integral_indicator (MeasurableSet.iInter hsm)]
refine tendsto_integral_of_dominated_convergence... |
/-
Copyright (c) 2020 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
-/
import Mathlib.Data.Fin.Tuple.Basic
import Mathlib.Data.List.Range
#align_import data.fin.vec_notation from "leanprover-community/mathlib"@"2445c98ae4b87eabebdde552593519b... | Mathlib/Data/Fin/VecNotation.lean | 422 | 423 | theorem empty_vecAlt1 (α) {h} : vecAlt1 h (![] : Fin 0 → α) = ![] := by |
simp [eq_iff_true_of_subsingleton]
|
/-
Copyright (c) 2020 Frédéric Dupuis. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Frédéric Dupuis, Eric Wieser
-/
import Mathlib.GroupTheory.Congruence.Basic
import Mathlib.LinearAlgebra.Basic
import Mathlib.LinearAlgebra.Multilinear.TensorProduct
import Mathlib.Ta... | Mathlib/LinearAlgebra/PiTensorProduct.lean | 549 | 551 | theorem map_comp : map (fun (i : ι) ↦ g i ∘ₗ f i) = map g ∘ₗ map f := by |
ext
simp only [LinearMap.compMultilinearMap_apply, map_tprod, LinearMap.coe_comp, Function.comp_apply]
|
/-
Copyright (c) 2020 Aaron Anderson. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Aaron Anderson
-/
import Mathlib.Data.Set.Lattice
import Mathlib.Order.ModularLattice
import Mathlib.Order.WellFounded
import Mathlib.Tactic.Nontriviality
#align_import order.atoms fr... | Mathlib/Order/Atoms.lean | 536 | 544 | theorem isSimpleOrder_iff_isSimpleOrder_orderDual [LE α] [BoundedOrder α] :
IsSimpleOrder α ↔ IsSimpleOrder αᵒᵈ := by |
constructor <;> intro i <;> haveI := i
· exact
{ exists_pair_ne := @exists_pair_ne α _
eq_bot_or_eq_top := fun a => Or.symm (eq_bot_or_eq_top (OrderDual.ofDual a) : _ ∨ _) }
· exact
{ exists_pair_ne := @exists_pair_ne αᵒᵈ _
eq_bot_or_eq_top := fun a => Or.symm (eq_bot_or_eq_top (Order... |
/-
Copyright (c) 2021 Benjamin Davidson. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Benjamin Davidson
-/
import Mathlib.Algebra.Field.Opposite
import Mathlib.Algebra.Group.Subgroup.ZPowers
import Mathlib.Algebra.Group.Submonoid.Membership
import Mathlib.Algebra.Rin... | Mathlib/Algebra/Periodic.lean | 315 | 321 | theorem Periodic.image_uIcc [LinearOrderedAddCommGroup α] [Archimedean α] (h : Periodic f c)
(hc : c ≠ 0) (a : α) : f '' uIcc a (a + c) = range f := by |
cases hc.lt_or_lt with
| inl hc =>
rw [uIcc_of_ge (add_le_of_nonpos_right hc.le), ← h.neg.image_Icc (neg_pos.2 hc) (a + c),
add_neg_cancel_right]
| inr hc => rw [uIcc_of_le (le_add_of_nonneg_right hc.le), h.image_Icc hc]
|
/-
Copyright (c) 2022 Heather Macbeth. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Heather Macbeth
-/
import Mathlib.Analysis.InnerProductSpace.Dual
import Mathlib.Analysis.InnerProductSpace.Orientation
import Mathlib.Data.Complex.Orientation
import Mathlib.Tactic.L... | Mathlib/Analysis/InnerProductSpace/TwoDim.lean | 268 | 270 | theorem inner_rightAngleRotation_right (x y : E) : ⟪x, J y⟫ = -ω x y := by |
rw [rightAngleRotation]
exact o.inner_rightAngleRotationAux₁_right x y
|
/-
Copyright (c) 2018 Jeremy Avigad. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Jeremy Avigad, Mario Carneiro, Simon Hudon
-/
import Mathlib.Data.Fin.Fin2
import Mathlib.Logic.Function.Basic
import Mathlib.Tactic.Common
#align_import data.typevec from "leanprover-... | Mathlib/Data/TypeVec.lean | 797 | 800 | theorem toSubtype_of_subtype_assoc
{α β : TypeVec n} (p : α ⟹ «repeat» n Prop) (f : β ⟹ Subtype_ p) :
@toSubtype n _ p ⊚ ofSubtype _ ⊚ f = f := by |
rw [← comp_assoc, toSubtype_of_subtype]; simp
|
/-
Copyright (c) 2021 Heather Macbeth. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Heather Macbeth
-/
import Mathlib.Analysis.MeanInequalities
import Mathlib.Analysis.MeanInequalitiesPow
import Mathlib.Analysis.SpecialFunctions.Pow.Continuity
import Mathlib.Data.Set... | Mathlib/Analysis/NormedSpace/lpSpace.lean | 779 | 789 | theorem _root_.Memℓp.infty_mul {f g : ∀ i, B i} (hf : Memℓp f ∞) (hg : Memℓp g ∞) :
Memℓp (f * g) ∞ := by |
rw [memℓp_infty_iff]
obtain ⟨⟨Cf, hCf⟩, ⟨Cg, hCg⟩⟩ := hf.bddAbove, hg.bddAbove
refine ⟨Cf * Cg, ?_⟩
rintro _ ⟨i, rfl⟩
calc
‖(f * g) i‖ ≤ ‖f i‖ * ‖g i‖ := norm_mul_le (f i) (g i)
_ ≤ Cf * Cg :=
mul_le_mul (hCf ⟨i, rfl⟩) (hCg ⟨i, rfl⟩) (norm_nonneg _)
((norm_nonneg _).trans (hCf ⟨i, rfl⟩)... |
/-
Copyright (c) 2018 Scott Morrison. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Scott Morrison, Bhavik Mehta
-/
import Mathlib.CategoryTheory.Limits.HasLimits
import Mathlib.CategoryTheory.DiscreteCategory
#align_import category_theory.limits.shapes.products from... | Mathlib/CategoryTheory/Limits/Shapes/Products.lean | 245 | 248 | theorem Pi.π_comp_eqToHom {J : Type*} (f : J → C) [HasProduct f] {j j' : J} (w : j = j') :
Pi.π f j ≫ eqToHom (by simp [w]) = Pi.π f j' := by |
cases w
simp
|
/-
Copyright (c) 2021 Johan Commelin. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johan Commelin
-/
import Mathlib.Analysis.Normed.Field.Basic
#align_import analysis.normed_space.int from "leanprover-community/mathlib"@"5cc2dfdd3e92f340411acea4427d701dc7ed26f8"
/-... | Mathlib/Analysis/NormedSpace/Int.lean | 41 | 42 | theorem toNat_add_toNat_neg_eq_nnnorm (n : ℤ) : ↑n.toNat + ↑(-n).toNat = ‖n‖₊ := by |
rw [← Nat.cast_add, toNat_add_toNat_neg_eq_natAbs, NNReal.natCast_natAbs]
|
/-
Copyright (c) 2022 Joseph Myers. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Joseph Myers
-/
import Mathlib.Algebra.CharP.Invertible
import Mathlib.Algebra.Order.Interval.Set.Group
import Mathlib.Analysis.Convex.Segment
import Mathlib.LinearAlgebra.AffineSpace.Fi... | Mathlib/Analysis/Convex/Between.lean | 67 | 74 | theorem affineSegment_same (x : P) : affineSegment R x x = {x} := by |
-- Porting note: added as this doesn't do anything in `simp_rw` any more
rw [affineSegment]
-- Note: when adding "simp made no progress" in lean4#2336,
-- had to change `lineMap_same` to `lineMap_same _`. Not sure why?
-- Porting note: added `_ _` and `Function.const`
simp_rw [lineMap_same _, AffineMap.coe... |
/-
Copyright (c) 2021 Thomas Browning. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Thomas Browning, Jireh Loreaux
-/
import Mathlib.Algebra.Group.Center
#align_import group_theory.subsemigroup.centralizer from "leanprover-community/mathlib"@"cc67cd75b4e54191e13c2e8... | Mathlib/Algebra/Group/Centralizer.lean | 64 | 65 | theorem zero_mem_centralizer [MulZeroClass M] : (0 : M) ∈ centralizer S := by |
simp [mem_centralizer_iff]
|
/-
Copyright (c) 2022 Michael Stoll. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Michael Stoll
-/
import Mathlib.NumberTheory.LegendreSymbol.JacobiSymbol
#align_import number_theory.legendre_symbol.norm_num from "leanprover-community/mathlib"@"e2621d935895abe70071a... | Mathlib/Tactic/NormNum/LegendreSymbol.lean | 173 | 175 | theorem jacobiSymNat.qr₁ (a b : ℕ) (r : ℤ) (ha : a % 4 = 1) (hb : b % 2 = 1)
(hr : jacobiSymNat b a = r) : jacobiSymNat a b = r := by |
rwa [jacobiSymNat, jacobiSym.quadratic_reciprocity_one_mod_four ha (Nat.odd_iff.mpr hb)]
|
/-
Copyright (c) 2015 Microsoft Corporation. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Leonardo de Moura, Mario Carneiro
-/
import Mathlib.Data.Bool.Basic
import Mathlib.Data.Option.Defs
import Mathlib.Data.Prod.Basic
import Mathlib.Data.Sigma.Basic
import Mathlib... | Mathlib/Logic/Equiv/Basic.lean | 1,738 | 1,748 | theorem swap_apply_ne_self_iff {a b x : α} : swap a b x ≠ x ↔ a ≠ b ∧ (x = a ∨ x = b) := by |
by_cases hab : a = b
· simp [hab]
by_cases hax : x = a
· simp [hax, eq_comm]
by_cases hbx : x = b
· simp [hbx]
simp [hab, hax, hbx, swap_apply_of_ne_of_ne]
|
/-
Copyright (c) 2022 Joseph Myers. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Joseph Myers
-/
import Mathlib.Analysis.Convex.Between
import Mathlib.Analysis.Convex.StrictConvexSpace
import Mathlib.Analysis.NormedSpace.AffineIsometry
#align_import analysis.convex.... | Mathlib/Analysis/Convex/StrictConvexBetween.lean | 29 | 43 | theorem Sbtw.dist_lt_max_dist (p : P) {p₁ p₂ p₃ : P} (h : Sbtw ℝ p₁ p₂ p₃) :
dist p₂ p < max (dist p₁ p) (dist p₃ p) := by |
have hp₁p₃ : p₁ -ᵥ p ≠ p₃ -ᵥ p := by simpa using h.left_ne_right
rw [Sbtw, ← wbtw_vsub_const_iff p, Wbtw, affineSegment_eq_segment, ← insert_endpoints_openSegment,
Set.mem_insert_iff, Set.mem_insert_iff] at h
rcases h with ⟨h | h | h, hp₂p₁, hp₂p₃⟩
· rw [vsub_left_cancel_iff] at h
exact False.elim (hp₂... |
/-
Copyright (c) 2022 Andrew Yang. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Andrew Yang
-/
import Mathlib.CategoryTheory.Adjunction.FullyFaithful
import Mathlib.CategoryTheory.Adjunction.Limits
import Mathlib.CategoryTheory.Limits.Shapes.CommSq
import Mathlib.Cat... | Mathlib/CategoryTheory/Limits/VanKampen.lean | 231 | 245 | theorem IsUniversalColimit.whiskerEquivalence {K : Type*} [Category K] (e : J ≌ K)
{F : K ⥤ C} {c : Cocone F} (hc : IsUniversalColimit c) :
IsUniversalColimit (c.whisker e.functor) := by |
intro F' c' α f e' hα H
convert hc (c'.whisker e.inverse) (whiskerLeft e.inverse α ≫ (e.invFunIdAssoc F).hom) f ?_
((hα.whiskerLeft _).comp (NatTrans.equifibered_of_isIso _)) ?_ using 1
· exact (IsColimit.whiskerEquivalenceEquiv e.symm).nonempty_congr
· convert congr_arg (whiskerLeft e.inverse) e'
ext
... |
/-
Copyright (c) 2021 Anne Baanen. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Anne Baanen
-/
import Mathlib.FieldTheory.RatFunc.Defs
import Mathlib.RingTheory.EuclideanDomain
import Mathlib.RingTheory.Localization.FractionRing
import Mathlib.RingTheory.Polynomial.C... | Mathlib/FieldTheory/RatFunc/Basic.lean | 89 | 91 | theorem ofFractionRing_add (p q : FractionRing K[X]) :
ofFractionRing (p + q) = ofFractionRing p + ofFractionRing q := by |
simp only [HAdd.hAdd, Add.add, RatFunc.add]
|
/-
Copyright (c) 2022 Justin Thomas. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Justin Thomas
-/
import Mathlib.FieldTheory.Minpoly.Field
import Mathlib.RingTheory.PrincipalIdealDomain
import Mathlib.Algebra.Polynomial.Module.AEval
#align_import linear_algebra.ann... | Mathlib/LinearAlgebra/AnnihilatingPolynomial.lean | 179 | 182 | theorem span_minpoly_eq_annihilator {M} [AddCommGroup M] [Module 𝕜 M] (f : Module.End 𝕜 M) :
Ideal.span {minpoly 𝕜 f} = Module.annihilator 𝕜[X] (Module.AEval' f) := by |
rw [← annIdealGenerator_eq_minpoly, span_singleton_annIdealGenerator]; ext
rw [mem_annIdeal_iff_aeval_eq_zero, DFunLike.ext_iff, Module.mem_annihilator]; rfl
|
/-
Copyright (c) 2019 Sébastien Gouëzel. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Sébastien Gouëzel, Yury Kudryashov
-/
import Mathlib.Topology.UniformSpace.Basic
import Mathlib.Topology.Separation
import Mathlib.Order.Filter.CountableInter
#align_import topolog... | Mathlib/Topology/GDelta.lean | 120 | 124 | theorem IsGδ.biInter {s : Set ι} (hs : s.Countable) {t : ∀ i ∈ s, Set X}
(ht : ∀ (i) (hi : i ∈ s), IsGδ (t i hi)) : IsGδ (⋂ i ∈ s, t i ‹_›) := by |
rw [biInter_eq_iInter]
haveI := hs.to_subtype
exact .iInter fun x => ht x x.2
|
/-
Copyright (c) 2021 Yury Kudryashov. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Yury Kudryashov
-/
import Mathlib.Analysis.BoxIntegral.Partition.Basic
#align_import analysis.box_integral.partition.split from "leanprover-community/mathlib"@"6ca1a09bc9aa75824bf973... | Mathlib/Analysis/BoxIntegral/Partition/Split.lean | 130 | 136 | theorem splitUpper_def [DecidableEq ι] {i x} (h : x ∈ Ioo (I.lower i) (I.upper i))
(h' : ∀ j, update I.lower i x j < I.upper j :=
(forall_update_iff I.lower fun j y => y < I.upper j).2
⟨h.2, fun j _ => I.lower_lt_upper _⟩) :
I.splitUpper i x = (⟨update I.lower i x, I.upper, h'⟩ : Box ι) := by |
simp (config := { unfoldPartialApp := true }) only [splitUpper, mk'_eq_coe, max_eq_left h.1.le,
update, and_self]
|
/-
Copyright (c) 2017 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl, Jeremy Avigad, Yury Kudryashov, Patrick Massot
-/
import Mathlib.Algebra.BigOperators.Group.Finset
import Mathlib.Algebra.Order.Field.Defs
import Mathlib.Algebra.Order.... | Mathlib/Order/Filter/AtTopBot.lean | 1,628 | 1,631 | theorem eventually_atTop_curry [SemilatticeSup α] [SemilatticeSup β] {p : α × β → Prop}
(hp : ∀ᶠ x : α × β in Filter.atTop, p x) : ∀ᶠ k in atTop, ∀ᶠ l in atTop, p (k, l) := by |
rw [← prod_atTop_atTop_eq] at hp
exact hp.curry
|
/-
Copyright (c) 2017 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl, Mario Carneiro, Yury Kudryashov
-/
import Mathlib.Order.Filter.Interval
import Mathlib.Order.Interval.Set.Pi
import Mathlib.Tactic.TFAE
import Mathlib.Tactic.NormNum
im... | Mathlib/Topology/Order/Basic.lean | 608 | 611 | theorem countable_setOf_covBy_left [SecondCountableTopology α] :
Set.Countable { x : α | ∃ y, y ⋖ x } := by |
convert countable_setOf_covBy_right (α := αᵒᵈ) using 5
exact toDual_covBy_toDual_iff.symm
|
/-
Copyright (c) 2018 Johannes Hölzl. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johannes Hölzl, Floris van Doorn, Gabriel Ebner, Yury Kudryashov
-/
import Mathlib.Order.ConditionallyCompleteLattice.Finset
import Mathlib.Order.Interval.Finset.Nat
#align_import dat... | Mathlib/Data/Nat/Lattice.lean | 75 | 77 | theorem sInf_mem {s : Set ℕ} (h : s.Nonempty) : sInf s ∈ s := by |
rw [Nat.sInf_def h]
exact Nat.find_spec h
|
/-
Copyright (c) 2018 Johan Commelin. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Johan Commelin
-/
import Mathlib.Algebra.Algebra.Defs
import Mathlib.Algebra.Order.BigOperators.Ring.Finset
import Mathlib.Algebra.Order.Field.Canonical.Basic
import Mathlib.Algebra.Or... | Mathlib/Data/Real/NNReal.lean | 1,080 | 1,081 | theorem iInf_empty [IsEmpty ι] (f : ι → ℝ≥0) : ⨅ i, f i = 0 := by |
rw [_root_.iInf_of_isEmpty, sInf_empty]
|
/-
Copyright (c) 2018 Patrick Massot. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Patrick Massot, Johannes Hölzl
-/
import Mathlib.Topology.Algebra.UniformGroup
import Mathlib.Topology.Algebra.UniformMulAction
import Mathlib.Topology.UniformSpace.Completion
#align_... | Mathlib/Topology/Algebra/GroupCompletion.lean | 288 | 298 | theorem AddMonoidHom.completion_add {γ : Type*} [AddCommGroup γ] [UniformSpace γ]
[UniformAddGroup γ] (f g : α →+ γ) (hf : Continuous f) (hg : Continuous g) :
AddMonoidHom.completion (f + g) (hf.add hg) =
AddMonoidHom.completion f hf + AddMonoidHom.completion g hg := by |
have hfg := hf.add hg
ext x
refine Completion.induction_on x ?_ ?_
· exact isClosed_eq ((f + g).continuous_completion hfg)
((f.continuous_completion hf).add (g.continuous_completion hg))
· intro a
simp [(f + g).completion_coe hfg, coe_add, f.completion_coe hf, g.completion_coe hg]
|
/-
Copyright (c) 2018 Chris Hughes. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Chris Hughes, Johannes Hölzl, Scott Morrison, Jens Wagemaker, Johan Commelin
-/
import Mathlib.Algebra.Polynomial.RingDivision
import Mathlib.RingTheory.Localization.FractionRing
#alig... | Mathlib/Algebra/Polynomial/Roots.lean | 220 | 221 | theorem roots_smul_nonzero (p : R[X]) (ha : a ≠ 0) : (a • p).roots = p.roots := by |
rw [smul_eq_C_mul, roots_C_mul _ ha]
|
/-
Copyright (c) 2023 Moritz Doll. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Moritz Doll, Sébastien Gouëzel, Jireh Loreaux
-/
import Mathlib.Analysis.MeanInequalities
import Mathlib.Analysis.NormedSpace.WithLp
/-!
# `L^p` distance on products of two metric space... | Mathlib/Analysis/NormedSpace/ProdLp.lean | 231 | 233 | theorem prod_dist_eq_card (f g : WithLp 0 (α × β)) : dist f g =
(if dist f.fst g.fst = 0 then 0 else 1) + (if dist f.snd g.snd = 0 then 0 else 1) := by |
convert if_pos rfl
|
/-
Copyright (c) 2024 Etienne Marion. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Etienne Marion
-/
import Mathlib.MeasureTheory.SetSemiring
/-!
# Algebra of sets
in this file we define the notion of algebra of sets ang give its basic properties. An algebra
of set... | Mathlib/MeasureTheory/SetAlgebra.lean | 151 | 158 | theorem generateSetAlgebra_subset {ℬ : Set (Set α)} (h : 𝒜 ⊆ ℬ)
(hℬ : IsSetAlgebra ℬ) : generateSetAlgebra 𝒜 ⊆ ℬ := by |
intro s hs
induction hs with
| base t t_mem => exact h t_mem
| empty => exact hℬ.empty_mem
| compl t _ t_mem => exact hℬ.compl_mem t_mem
| union t u _ _ t_mem u_mem => exact hℬ.union_mem t_mem u_mem
|
/-
Copyright (c) 2023 Damiano Testa. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Damiano Testa
-/
import Mathlib.Algebra.Polynomial.Degree.Lemmas
/-!
# `compute_degree` and `monicity`: tactics for explicit polynomials
This file defines two related tactics: `comp... | Mathlib/Tactic/ComputeDegree.lean | 117 | 126 | theorem coeff_pow_of_natDegree_le_of_eq_ite' {m n o : ℕ} {a : R} {p : R[X]}
(h_pow : natDegree p ≤ n) (h_exp : m * n ≤ o) (h_pow_bas : coeff p n = a) :
coeff (p ^ m) o = if o = m * n then a ^ m else 0 := by |
split_ifs with h
· subst h h_pow_bas
exact coeff_pow_of_natDegree_le ‹_›
· apply coeff_eq_zero_of_natDegree_lt
apply lt_of_le_of_lt ?_ (lt_of_le_of_ne ‹_› ?_)
· exact natDegree_pow_le_of_le m ‹_›
· exact Iff.mp ne_comm h
|
/-
Copyright (c) 2018 Mario Carneiro. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Mario Carneiro, Kenny Lau
-/
import Mathlib.Data.List.Forall2
import Mathlib.Data.Set.Pairwise.Basic
import Mathlib.Init.Data.Fin.Basic
#align_import data.list.nodup from "leanprover-... | Mathlib/Data/List/Nodup.lean | 277 | 280 | theorem Nodup.pmap {p : α → Prop} {f : ∀ a, p a → β} {l : List α} {H}
(hf : ∀ a ha b hb, f a ha = f b hb → a = b) (h : Nodup l) : Nodup (pmap f l H) := by |
rw [pmap_eq_map_attach]
exact h.attach.map fun ⟨a, ha⟩ ⟨b, hb⟩ h => by congr; exact hf a (H _ ha) b (H _ hb) h
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.