filename
stringlengths
5
42
content
stringlengths
15
319k
HasFibers.lean
/- Copyright (c) 2024 Calle Sönne. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Calle Sönne, Paul Lezeau -/ import Mathlib.CategoryTheory.FiberedCategory.Fiber import Mathlib.CategoryTheory.FiberedCategory.Fibered /-! # Fibers of functors In this file we introduce...
Embedding.lean
/- Copyright (c) 2025 Antoine Chambert-Loir. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Antoine Chambert-Loir -/ import Mathlib.Data.ENat.Lattice import Mathlib.Data.Fin.Tuple.Embedding import Mathlib.Data.Finite.Card import Mathlib.Data.Set.Card /-! # Existence ...
TensorProduct.lean
/- Copyright (c) 2024 Amelia Livingston. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Amelia Livingston, Andrew Yang -/ import Mathlib.RingTheory.Bialgebra.Equiv import Mathlib.RingTheory.Coalgebra.TensorProduct import Mathlib.RingTheory.TensorProduct.Basic /-! # Te...
Prod.lean
/- Copyright (c) 2023 Joël Riou. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joël Riou -/ import Mathlib.CategoryTheory.Functor.Currying import Mathlib.CategoryTheory.Localization.Predicate import Mathlib.CategoryTheory.MorphismProperty.Composition /-! # Localizati...
Ptolemy.lean
/- Copyright (c) 2021 Manuel Candales. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Manuel Candales, Benjamin Davidson -/ import Mathlib.Geometry.Euclidean.Sphere.Power import Mathlib.Geometry.Euclidean.Triangle /-! # Ptolemy's theorem This file proves Ptolemy's th...
GoalsLocation.lean
/- Copyright (c) 2023 Jovan Gerbscheid. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Jovan Gerbscheid -/ import Mathlib.Init import Lean.Meta.Tactic.Util import Lean.SubExpr /-! This file defines some functions for dealing with `SubExpr.GoalsLocation`. -/ namespace...
Units.lean
/- Copyright (c) 2021 Chris Birkbeck. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Chris Birkbeck -/ import Mathlib.Algebra.Group.Subgroup.Defs import Mathlib.Algebra.Group.Submonoid.Operations import Mathlib.Algebra.Order.GroupWithZero.Submonoid import Mathlib.Algeb...
Metric.lean
/- Copyright (c) 2022 Yury Kudryashov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yury Kudryashov -/ import Mathlib.Analysis.Complex.UpperHalfPlane.Topology import Mathlib.Analysis.SpecialFunctions.Arsinh import Mathlib.Geometry.Euclidean.Inversion.Basic /-! # Met...
Matrix.lean
/- Copyright (c) 2024 Jujian Zhang. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Jujian Zhang -/ import Mathlib.LinearAlgebra.Matrix.Ideal import Mathlib.RingTheory.SimpleRing.Basic /-! The matrix ring over a simple ring is simple -/ namespace IsSimpleRing variabl...
Linear.lean
/- Copyright (c) 2019 Jeremy Avigad. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Jeremy Avigad, Sébastien Gouëzel, Yury Kudryashov -/ import Mathlib.Analysis.Calculus.FDeriv.Basic import Mathlib.Analysis.Normed.Operator.BoundedLinearMaps /-! # The derivative of bou...
all_order.v
Require Export order.
Imo1975Q1.lean
/- Copyright (c) 2022 Mantas Bakšys. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Mantas Bakšys -/ import Mathlib.Algebra.BigOperators.Ring.Finset import Mathlib.Algebra.Order.Rearrangement import Mathlib.Data.Real.Basic import Mathlib.Order.Interval.Finset.Nat /-! ...
Henselian.lean
/- 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.Algebra.Polynomial.Taylor import Mathlib.RingTheory.LocalRing.ResidueField.Basic import Mathlib.RingTheory.AdicCompletion.Basic /-! # Henselian rings ...
DirichletTheorem.lean
/- Copyright (c) 2023 Xavier Roblot. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Xavier Roblot -/ import Mathlib.LinearAlgebra.Matrix.Gershgorin import Mathlib.NumberTheory.NumberField.CanonicalEmbedding.ConvexBody import Mathlib.NumberTheory.NumberField.Units.Basic...
finmodule.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From HB Require Import structures. From mathcomp Require Import ssreflect ssrbool ssrfun eqtype ssrnat seq path. From mathcomp Require Import div choice fintype...
apply_congr.lean
import Mathlib.Tactic.ApplyCongr import Mathlib.Algebra.BigOperators.Group.Finset.Powerset example (f g : ℤ → ℤ) (S : Finset ℤ) (h : ∀ m ∈ S, f m = g m) : Finset.sum S f = Finset.sum S g := by conv_lhs => -- If we just call `congr` here, in the second goal we're helpless, -- because we are only given the...
Pi.lean
/- Copyright (c) 2020 Floris van Doorn. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Floris van Doorn -/ import Mathlib.MeasureTheory.MeasurableSpace.Constructions import Mathlib.MeasureTheory.PiSystem /-! # Bases of the indexed product σ-algebra In this file we pr...
ShiftSequence.lean
/- Copyright (c) 2023 Joël Riou. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joël Riou -/ import Mathlib.CategoryTheory.Shift.Basic import Mathlib.CategoryTheory.Preadditive.AdditiveFunctor /-! Sequences of functors from a category equipped with a shift Let `F : C...
Action.lean
/- 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.Dynamics.Ergodic.MeasurePreserving import Mathlib.Dynamics.Minimal import Mathlib.GroupTheory.GroupAction.Hom import Mathlib.MeasureTheory.Group.Meas...
SemistandardTableau.lean
/- Copyright (c) 2022 Jake Levinson. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Jake Levinson -/ import Mathlib.Combinatorics.Young.YoungDiagram /-! # Semistandard Young tableaux A semistandard Young tableau is a filling of a Young diagram by natural numbers, suc...
Uniqueness.lean
/- 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 -/ import Mathlib.Analysis.Analytic.Linear import Mathlib.Analysis.Analytic.Composition import Mathlib.Analysis.Analytic.Constructions import Mathlib.Analysis.Norm...
Banach.lean
/- 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 -/ import Mathlib.Topology.Baire.Lemmas import Mathlib.Topology.Baire.CompleteMetrizable import Mathlib.Analysis.NormedSpace.OperatorNorm.NormedSpace import Mathli...
LinearDisjoint.lean
/- Copyright (c) 2024 Jz Pan. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Jz Pan -/ import Mathlib.FieldTheory.IntermediateField.Adjoin.Basic import Mathlib.RingTheory.AlgebraicIndependent.RankAndCardinality import Mathlib.RingTheory.LinearDisjoint /-! # Linearly ...
tuple.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From HB Require Import structures. From mathcomp Require Import ssreflect ssrfun ssrbool eqtype ssrnat. From mathcomp Require Import seq choice fintype path. S...
Basic.lean
/- Copyright (c) 2018 Simon Hudon. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Simon Hudon -/ import Mathlib.Control.Bifunctor import Mathlib.Control.Traversable.Basic /-! # Bitraversable type class Type class for traversing bifunctors. Simple examples of `Bitrav...
Submodule.lean
/- Copyright (c) 2024 Andrew Yang. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Andrew Yang -/ import Mathlib.Algebra.Module.Submodule.Pointwise import Mathlib.LinearAlgebra.Quotient.Basic import Mathlib.RingTheory.Localization.Module import Mathlib.Algebra.Algebra.O...
TFAE.lean
/- Copyright (c) 2018 Johan Commelin. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Johan Commelin, Reid Barton, Simon Hudon, Thomas Murrills, Mario Carneiro -/ import Qq import Mathlib.Data.Nat.Notation import Mathlib.Util.AtomM import Mathlib.Data.List.TFAE import M...
Topology.lean
/- Copyright (c) 2024 Yury Kudryashov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yury Kudryashov -/ import Mathlib.Topology.Algebra.Module.Multilinear.Topology import Mathlib.Topology.Algebra.Module.Alternating.Basic /-! # Topology on continuous alternating maps ...
ExtClass.lean
/- Copyright (c) 2024 Joël Riou. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joël Riou -/ import Mathlib.Algebra.Homology.DerivedCategory.Ext.Basic import Mathlib.Algebra.Homology.DerivedCategory.SingleTriangle /-! # The Ext class of a short exact sequence In this...
DocPrime.lean
/- Copyright (c) 2024 Damiano Testa. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Damiano Testa -/ import Lean.Elab.Command -- Import this linter explicitly to ensure that -- this file has a valid copyright header and module docstring. import Mathlib.Tactic.Linter.He...
Tower.lean
/- Copyright (c) 2020 Kenny Lau. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Kenny Lau, Anne Baanen -/ import Mathlib.Algebra.Algebra.Subalgebra.Lattice import Mathlib.Algebra.Algebra.Tower /-! # Subalgebras in towers of algebras In this file we prove facts about ...
mxred.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From mathcomp Require Import ssreflect ssrfun ssrbool eqtype ssrnat seq div. From mathcomp Require Import choice fintype finfun bigop fingroup perm order. From ...
CompactlyGeneratedSpace.lean
/- Copyright (c) 2024 Etienne Marion. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Dagur Asgeirsson, Etienne Marion -/ import Mathlib.Topology.Category.CompHaus.Basic import Mathlib.Topology.Compactification.OnePoint.Basic /-! # Compactly generated topological space...
Integrals.lean
/- Copyright (c) 2023 Joachim Breitner. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joachim Breitner -/ import Mathlib.Probability.ProbabilityMassFunction.Basic import Mathlib.Probability.ProbabilityMassFunction.Constructions import Mathlib.MeasureTheory.Integral.Bo...
Kuratowski.lean
/- Copyright (c) 2018 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.Analysis.Normed.Lp.lpSpace import Mathlib.Topology.Sets.Compacts /-! # The Kuratowski embedding Any separable metric space can be embedded isom...
Div.lean
/- Copyright (c) 2023 Yaël Dillies. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yaël Dillies -/ import Mathlib.Algebra.GroupWithZero.Action.Pi import Mathlib.Algebra.Order.Group.Nat import Mathlib.Algebra.Order.Module.Defs import Mathlib.Algebra.Order.Sub.Basic impo...
Reflective.lean
/- 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.Adjunction.FullyFaithful import Mathlib.CategoryTheory.Functor.EpiMono import Mathlib.CategoryTheory.HomCongr /-! # Reflective functors Ba...
TotalComplexSymmetry.lean
/- Copyright (c) 2024 Joël Riou. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joël Riou -/ import Mathlib.Algebra.Homology.TotalComplex /-! The symmetry of the total complex of a bicomplex Let `K : HomologicalComplex₂ C c₁ c₂` be a bicomplex. If we assume both `[To...
ssrAC.v
From HB Require Import structures. From Corelib Require Import PosDef. (* use #[warning="-hiding-delimiting-key"] attribute once we require Coq 8.18 *) (* (the warning was completely removed in 9.0) *) Set Warnings "-hiding-delimiting-key". From mathcomp Require Import ssreflect ssrbool ssrfun ssrnat eqtype seq bigop. ...
Basic.lean
/- Copyright (c) 2020 Kevin Buzzard. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Kevin Buzzard -/ import Mathlib.RingTheory.AdicCompletion.Basic import Mathlib.RingTheory.LocalRing.MaximalIdeal.Basic import Mathlib.RingTheory.LocalRing.RingHom.Basic import Mathlib.R...
Int.lean
/- Copyright (c) 2023 Koundinya Vajjha. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Koundinya Vajjha, Thomas Browning -/ import Mathlib.NumberTheory.Harmonic.Defs import Mathlib.NumberTheory.Padics.PadicNumbers import Mathlib.Tactic.Positivity /-! The nth Harmonic...
Semigroup.lean
/- 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 -/ import Mathlib.Algebra.Group.Defs import Mathlib.Topology.Separation.Hausdorff /-! # Idempotents in topological semigroups This file provides a sufficient condition for a s...
Gluing.lean
/- 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.Restrict import Mathlib.CategoryTheory.LocallyDirected import Mathlib.Geometry.RingedSpace.PresheafedSpace.Gluing /-! # Gluing Schemes Gi...
all_boot.v
Require Export ssreflect. Require Export ssrbool. Require Export ssrfun. Require Export eqtype. Require Export ssrnat. Require Export seq. Require Export choice. Require Export monoid. Require Export nmodule. Require Export path. Require Export div. Require Export fintype. Require Export fingraph. Require Export tuple....
Basic.lean
/- Copyright (c) 2018 Kenny Lau. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Kenny Lau, Chris Hughes, Mario Carneiro, Anne Baanen -/ import Mathlib.GroupTheory.QuotientGroup.Finite import Mathlib.LinearAlgebra.Quotient.Defs import Mathlib.RingTheory.Congruence.Basic...
Domineering.lean
/- Copyright (c) 2019 Kim Morrison. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Kim Morrison -/ import Mathlib.SetTheory.Game.State import Mathlib.Tactic.Linter.DeprecatedModule deprecated_module "This module is now at `CombinatorialGames.Game.Specific.Domineerin...
Constructions.lean
/- Copyright (c) 2022 Nicolò Cavalleri. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Nicolò Cavalleri, Sébastien Gouëzel, Heather Macbeth, Floris van Doorn -/ import Mathlib.Topology.FiberBundle.Constructions import Mathlib.Topology.VectorBundle.Basic import Mathlib....
Defs.lean
/- Copyright (c) 2020 Anne Baanen. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Nathaniel Thomas, Jeremy Avigad, Johannes Hölzl, Mario Carneiro, Anne Baanen, Frédéric Dupuis, Heather Macbeth -/ import Mathlib.Algebra.Group.Hom.Instances import Mathlib.Algebra.Modul...
SkewAdjoint.lean
/- Copyright (c) 2020 Oliver Nash. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Oliver Nash -/ import Mathlib.Algebra.Lie.Matrix import Mathlib.LinearAlgebra.Matrix.SesquilinearForm import Mathlib.Tactic.NoncommRing /-! # Lie algebras of skew-adjoint endomorphisms o...
Cospan.lean
/- Copyright (c) 2018 Kim Morrison. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Kim Morrison, Markus Himmel, Bhavik Mehta -/ import Mathlib.CategoryTheory.Limits.Shapes.WidePullbacks import Mathlib.CategoryTheory.Limits.Shapes.BinaryProducts /-! # Cospan & Span We...
Scheme.lean
import Mathlib.AlgebraicGeometry.Restrict universe u open AlgebraicGeometry variable (X : Scheme.{u}) (x : X) in /-- info: x : ↥X -/ #guard_msgs in #check x variable (R : CommRingCat.{u}) (x : Spec R) in /-- info: x : ↥(Spec R) -/ #guard_msgs in #check x variable (X : Scheme.{u}) (U : X.Opens) (x : U.toScheme) in ...
Ideal.lean
/- Copyright (c) 2022 Pierre-Alexandre Bazin. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Pierre-Alexandre Bazin -/ import Mathlib.LinearAlgebra.DFinsupp import Mathlib.RingTheory.Ideal.BigOperators import Mathlib.RingTheory.Ideal.Operations /-! # An additional lem...
FinEnum.lean
/- Copyright (c) 2019 Simon Hudon. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Simon Hudon -/ import Mathlib.Data.Fintype.Basic import Mathlib.Data.Fintype.EquivFin import Mathlib.Data.List.ProdSigma import Mathlib.Data.List.Pi /-! Type class for finitely enumerabl...
KummerDedekind.lean
/- Copyright (c) 2021 Anne Baanen. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Anne Baanen, Paul Lezeau -/ import Mathlib.RingTheory.DedekindDomain.Ideal.Lemmas import Mathlib.RingTheory.IsAdjoinRoot /-! # Kummer-Dedekind theorem This file proves the Kummer-Dedeki...
Preprocessing.lean
/- Copyright (c) 2025 Vasilii Nesterov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Vasilii Nesterov -/ import Mathlib.Tactic.Order.CollectFacts /-! # Facts preprocessing for the `order` tactic In this file we implement the preprocessing procedure for the `order` ...
Basic.lean
/- Copyright (c) 2023 Yury Kudryashov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yury Kudryashov, Heather Macbeth, Sébastien Gouëzel -/ import Mathlib.LinearAlgebra.Alternating.Basic import Mathlib.LinearAlgebra.BilinearMap import Mathlib.Topology.Algebra.Module.E...
Girard.lean
/- Copyright (c) 2021 Mario Carneiro. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Mario Carneiro -/ import Mathlib.Logic.Basic import Mathlib.Data.Set.Defs /-! # Girard's paradox Girard's paradox is a proof that `Type : Type` entails a contradiction. We can't say ...
Completion.lean
/- Copyright (c) 2024 Salvatore Mercuri. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Salvatore Mercuri -/ import Mathlib.Algebra.Field.Subfield.Basic import Mathlib.Analysis.Normed.Module.Completion import Mathlib.Analysis.Normed.Field.WithAbs import Mathlib.NumberT...
Formula.lean
/- Copyright (c) 2025 David Kurniadi Angdinata. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: David Kurniadi Angdinata -/ import Mathlib.AlgebraicGeometry.EllipticCurve.Affine.Formula import Mathlib.AlgebraicGeometry.EllipticCurve.Jacobian.Basic /-! # Negation and ad...
VitaliCaratheodory.lean
/- 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.Regular import Mathlib.Topology.Semicontinuous import Mathlib.MeasureTheory.Integral.Bochner.Basic import Mathlib.Topology....
Hamiltonian.lean
/- Copyright (c) 2023 Bhavik Mehta, Rishi Mehta, Linus Sommer. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Bhavik Mehta, Rishi Mehta, Linus Sommer -/ import Mathlib.Algebra.GroupWithZero.Nat import Mathlib.Algebra.Order.Group.Nat import Mathlib.Combinatorics.SimpleG...
galois.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From HB Require Import structures. From mathcomp Require Import ssreflect ssrbool ssrfun eqtype ssrnat seq div. From mathcomp Require Import choice fintype tupl...
FourFunctions.lean
/- Copyright (c) 2023 Yaël Dillies. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yaël Dillies -/ import Mathlib.Algebra.BigOperators.Group.Finset.Piecewise import Mathlib.Algebra.Order.BigOperators.Group.Finset import Mathlib.Algebra.Order.Pi import Mathlib.Algebra.O...
DoubleCounting.lean
/- Copyright (c) 2022 Yaël Dillies. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yaël Dillies -/ import Mathlib.Algebra.BigOperators.Ring.Finset import Mathlib.Algebra.Order.BigOperators.Group.Finset import Mathlib.Algebra.Order.Ring.Nat /-! # Double countings This...
Group.lean
/- Copyright (c) 2019 Yury Kudryashov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yury Kudryashov -/ import Mathlib.Algebra.Order.Group.MinMax import Mathlib.Order.Filter.AtTopBot.Basic import Mathlib.Order.Filter.AtTopBot.Map import Mathlib.Order.Filter.AtTopBot.M...
Even.lean
/- Copyright (c) 2016 Jeremy Avigad. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Jeremy Avigad -/ import Mathlib.Algebra.Group.Int.Defs import Mathlib.Algebra.Group.Nat.Even import Mathlib.Data.Int.Sqrt /-! # Parity of integers -/ open Nat namespace Int /-! ####...
NoZeroDivisors.lean
/- 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.Group.UniqueProds.Basic import Mathlib.Algebra.MonoidAlgebra.Opposite /-! # Variations on non-zero divisors in `AddMonoidAlgebra`s This file st...
Projective.lean
/- Copyright (c) 2021 Kevin Buzzard. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Kevin Buzzard, Antoine Labelle -/ import Mathlib.Algebra.Module.Shrink import Mathlib.LinearAlgebra.TensorProduct.Basis import Mathlib.Logic.UnivLE /-! # Projective modules This file...
Order.lean
/- Copyright (c) 2021 Damiano Testa. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Damiano Testa -/ import Mathlib.Algebra.Order.Hom.Ring import Mathlib.Algebra.Order.Ring.InjSurj import Mathlib.Algebra.Ring.Subring.Defs /-! # Subrings of ordered rings We study sub...
alt.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From HB Require Import structures. From mathcomp Require Import ssreflect ssrbool ssrfun eqtype ssrnat seq choice. From mathcomp Require Import div fintype tupl...
Imo1961Q3.lean
/- Copyright (c) 2024 Yury Kudryashov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yury Kudryashov -/ import Mathlib.Analysis.SpecialFunctions.Trigonometric.Complex /-! # IMO 1961 Q3 Solve the equation $\cos^n x - \sin^n x = 1$, where $n$ is a given positive int...
Opposite.lean
/- 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.Group.Opposite import Mathlib.Algebra.GroupWithZero.InjSurj import Mathlib.Algebra.GroupWithZero.NeZero /-! # Opposites of groups with zero -/ assert_n...
MeanInequalities.lean
/- Copyright (c) 2019 Yury Kudryashov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yury Kudryashov, Sébastien Gouëzel, Rémy Degenne -/ import Mathlib.Algebra.BigOperators.Expect import Mathlib.Algebra.BigOperators.Field import Mathlib.Analysis.Convex.Jensen import M...
End.lean
/- Copyright (c) 2024 Joël Riou. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joël Riou -/ import Mathlib.CategoryTheory.Limits.Shapes.Multiequalizer /-! # Ends and coends In this file, given a functor `F : Jᵒᵖ ⥤ J ⥤ C`, we define its end `end_ F`, which is a suita...
StoneCech.lean
/- Copyright (c) 2018 Reid Barton. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Reid Barton -/ import Mathlib.Topology.Bases import Mathlib.Topology.DenseEmbedding import Mathlib.Topology.Connected.TotallyDisconnected /-! # Stone-Čech compactification Construction ...
zmodp.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From HB Require Import structures. From mathcomp Require Import ssreflect ssrfun ssrbool choice eqtype ssrnat seq. From mathcomp Require Import div fintype bigo...
Recall.lean
/- Copyright (c) 2023 Mac Malone. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Mac Malone, Kyle Miller -/ import Mathlib.Init import Lean.Elab.Command import Lean.Elab.DeclUtil /-! # `recall` command -/ namespace Mathlib.Tactic.Recall /-- The `recall` command rede...
action.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From mathcomp Require Import ssreflect ssrbool ssrfun ssrnotations eqtype. From mathcomp Require Import ssrnat div seq prime fintype bigop finset. From mathcomp...
ZeroHypercover.lean
/- Copyright (c) 2025 Christian Merten. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Christian Merten -/ import Mathlib.CategoryTheory.Sites.Coverage /-! # 0-hypercovers Given a coverage `J` on a category `C`, we define the type of `0`-hypercovers of an object `S :...
GeomSum.lean
/- Copyright (c) 2019 Neil Strickland. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Neil Strickland -/ import Mathlib.Algebra.BigOperators.Intervals import Mathlib.Algebra.BigOperators.Ring.Finset import Mathlib.Algebra.Ring.Opposite /-! # Partial sums of geometric ...
poly.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From HB Require Import structures. From mathcomp Require Import ssreflect ssrbool ssrfun eqtype ssrnat seq choice. From mathcomp Require Import fintype bigop fi...
Basic.lean
/- Copyright (c) 2018 Kenny Lau. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Kenny Lau, Chris Hughes, Anne Baanen -/ import Mathlib.Data.Matrix.Basic import Mathlib.Data.Matrix.Block import Mathlib.Data.Matrix.Notation import Mathlib.Data.Matrix.RowCol import Mathli...
Rotate.lean
/- Copyright (c) 2025 Paul Lezeau. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Paul Lezeau, Lawrence Wu -/ import Mathlib.Algebra.Group.Fin.Basic import Mathlib.Logic.Equiv.Fin.Basic /-! # Maximum order cyclic permutations on `Fin n` This file defines `finRotate`,...
AEDisjoint.lean
/- Copyright (c) 2022 Yury Kudryashov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yury Kudryashov -/ import Mathlib.MeasureTheory.Measure.MeasureSpaceDef /-! # Almost everywhere disjoint sets We say that sets `s` and `t` are `μ`-a.e. disjoint (see `MeasureTheory....
Core.lean
/- Copyright (c) 2022 Mario Carneiro. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Mario Carneiro -/ import Mathlib.Lean.Expr.Rat import Mathlib.Tactic.NormNum.Result import Mathlib.Util.Qq import Lean.Elab.Tactic.Location /-! ## `norm_num` core functionality This ...
Adhesive.lean
/- 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.Extensive import Mathlib.CategoryTheory.Limits.Shapes.KernelPair import Mathlib.CategoryTheory.Limits.Constructions.EpiMono /-! # Adhesive c...
PicardLindelof.lean
/- Copyright (c) 2021 Yury Kudryashov. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Yury Kudryashov, Winston Yin -/ import Mathlib.Analysis.SpecialFunctions.Integrals.Basic import Mathlib.Topology.Algebra.Order.Floor import Mathlib.Topology.MetricSpace.Contracting /...
Pi.lean
/- Copyright (c) 2015, 2017 Jeremy Avigad. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Jeremy Avigad, Robert Y. Lewis, Johannes Hölzl, Mario Carneiro, Sébastien Gouëzel -/ import Mathlib.Topology.EMetricSpace.Basic import Mathlib.Topology.UniformSpace.Pi /-! # Inde...
Fractions.lean
/- Copyright (c) 2024 Joël Riou. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joël Riou -/ import Mathlib.CategoryTheory.Localization.CalculusOfFractions /-! # Lemmas on fractions Let `W : MorphismProperty C`, and objects `X` and `Y` in `C`. In this file, we introd...
Constructions.lean
/- 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, Kim Morrison, Chris Hughes, Anne Baanen -/ import Mathlib.Algebra.Algebra.Subalgebra.Lattice import Mathlib.LinearAlgebra.Basis.Prod impo...
Linear.lean
/- Copyright (c) 2024 Joël Riou. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Joël Riou -/ import Mathlib.CategoryTheory.Quotient import Mathlib.CategoryTheory.Linear.LinearFunctor /-! # The quotient category is linear If `r : HomRel C` is a congruence on a preaddi...
Positive.lean
/- Copyright (c) 2022 Anatole Dedecker. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Anatole Dedecker -/ import Mathlib.Analysis.InnerProductSpace.Adjoint import Mathlib.Analysis.InnerProductSpace.Spectrum /-! # Positive operators In this file we define when an ope...
Height.lean
/- 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.Data.ENat.Lattice import Mathlib.Order.OrderIsoNat import Mathlib.Tactic.TFAE /-! # Maximal length of chains This file contains lemmas to work with the ma...
EpiMono.lean
/- Copyright (c) 2021 Kim Morrison. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Kim Morrison -/ import Mathlib.LinearAlgebra.Quotient.Basic import Mathlib.Algebra.Category.ModuleCat.Basic import Mathlib.CategoryTheory.ConcreteCategory.EpiMono /-! # Monomorphisms in...
RegularMeasure.lean
import Mathlib.MeasureTheory.Group.Measure import Mathlib.Topology.Metrizable.Urysohn /-! Check that typeclass inference knows that a Haar measure on a locally compact second countable topological group is automatically regular and inner regular. -/ open MeasureTheory Measure variable {G : Type*} [MeasurableSpace G]...
MulOpposite.lean
/- Copyright (c) 2022 Alex Kontorovich. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Alex Kontorovich, Eric Wieser -/ import Mathlib.Algebra.Group.Subgroup.Defs import Mathlib.Algebra.Group.Submonoid.MulOpposite /-! # Mul-opposite subgroups ## Tags subgroup, subgro...
ListOfFn.lean
/- Copyright (c) 2022 Eric Wieser. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Eric Wieser -/ import Mathlib.Data.List.OfFn import Mathlib.Algebra.BigOperators.Group.List.Defs import Mathlib.Algebra.Group.Pointwise.Set.Basic /-! # Pointwise operations with lists of...
DFinsupp.lean
/- Copyright (c) 2024 Eric Wieser. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Eric Wieser, Sophie Morel -/ import Mathlib.Data.Fintype.Quotient import Mathlib.LinearAlgebra.DFinsupp import Mathlib.LinearAlgebra.Multilinear.Basic /-! # Interactions between finitely...
cyclotomic.v
(* (c) Copyright 2006-2016 Microsoft Corporation and Inria. *) (* Distributed under the terms of CeCILL-B. *) From mathcomp Require Import ssreflect ssrbool ssrfun eqtype ssrnat seq path. From mathcomp Require Import div choice fintype tuple finfun bigop prime. From mat...
Idempotents.lean
/- Copyright (c) 2024 Andrew Yang. All rights reserved. Released under Apache 2.0 license as described in the file LICENSE. Authors: Andrew Yang -/ import Mathlib.Algebra.BigOperators.Fin import Mathlib.Algebra.Ring.GeomSum import Mathlib.RingTheory.Ideal.Quotient.Operations import Mathlib.RingTheory.Nilpotent.Defs /-...