The Mathlib Handbook

The volumes of the handbook are not written yet. This site shows the map of Mathlib that they will follow, at Mathlib 4472534b60.

The areas / V34. The tactics of Mathlib

Mathlib.Tactic.Inclusion.Core.Types

87 declarations. Mathlib docs · Source

theorem Inclusion.IExpr.mk.inj E1 #

∀ {iType : Inclusion.IType} {expr : Lean.Expr} {iType_1 : Inclusion.IType} {expr_1 : Lean.Expr},
  { iType := iType, expr := expr } = { iType := iType_1, expr := expr_1 } → iType = iType_1 ∧ expr = expr_1

def Inclusion.instInhabitedExprInclusion.default E1 #

Inclusion.ExprInclusion

def Inclusion.IExpr.ctorIdx E1 #

Inclusion.IExpr → ℕ

theorem Inclusion.IExpr.mk.injEq E0 #

∀ (iType : Inclusion.IType) (expr : Lean.Expr) (iType_1 : Inclusion.IType) (expr_1 : Lean.Expr),
  ({ iType := iType, expr := expr } = { iType := iType_1, expr := expr_1 }) = (iType = iType_1 ∧ expr = expr_1)

def Inclusion.InclusionM.State.ctorIdx E1 #

Inclusion.InclusionM.State → ℕ

theorem Inclusion.HypothesisM.State.mk.inj E1 #

∀ {inclusions inclusions_1 : Lean.ExprMap (Array Inclusion.ExprInclusionBody)},
  { inclusions := inclusions } = { inclusions := inclusions_1 } → inclusions = inclusions_1

def Inclusion.instInhabitedIExpr.default E1 #

Inclusion.IExpr

theorem Inclusion.InclusionM.State.mk.injEq E0 #

∀ (iVars : Lean.ExprMap Inclusion.IVar) (iVarDisplays : Lean.ExprMap Lean.Expr) (iVars_1 : Lean.ExprMap Inclusion.IVar)
  (iVarDisplays_1 : Lean.ExprMap Lean.Expr),
  ({ iVars := iVars, iVarDisplays := iVarDisplays } = { iVars := iVars_1, iVarDisplays := iVarDisplays_1 }) =
    (iVars = iVars_1 ∧ iVarDisplays = iVarDisplays_1)

theorem Inclusion.IVar.mk.injEq E0 #

∀ (iExpr : Inclusion.IExpr) (setVar hypVar : Lean.Expr) (cover? : Option Lean.Expr) (iExpr_1 : Inclusion.IExpr)
  (setVar_1 hypVar_1 : Lean.Expr) (cover?_1 : Option Lean.Expr),
  ({ iExpr := iExpr, setVar := setVar, hypVar := hypVar, cover? := cover? } =
      { iExpr := iExpr_1, setVar := setVar_1, hypVar := hypVar_1, cover? := cover?_1 }) =
    (iExpr = iExpr_1 ∧ setVar = setVar_1 ∧ hypVar = hypVar_1 ∧ cover? = cover?_1)

theorem Inclusion.IVar.mk.inj E1 #

∀ {iExpr : Inclusion.IExpr} {setVar hypVar : Lean.Expr} {cover? : Option Lean.Expr} {iExpr_1 : Inclusion.IExpr}
  {setVar_1 hypVar_1 : Lean.Expr} {cover?_1 : Option Lean.Expr},
  { iExpr := iExpr, setVar := setVar, hypVar := hypVar, cover? := cover? } =
      { iExpr := iExpr_1, setVar := setVar_1, hypVar := hypVar_1, cover? := cover?_1 } →
    iExpr = iExpr_1 ∧ setVar = setVar_1 ∧ hypVar = hypVar_1 ∧ cover? = cover?_1

theorem Inclusion.IType.mk.injEq E0 #

∀ (elemType setType toSetInst elemType_1 setType_1 toSetInst_1 : Lean.Expr),
  ({ elemType := elemType, setType := setType, toSetInst := toSetInst } =
      { elemType := elemType_1, setType := setType_1, toSetInst := toSetInst_1 }) =
    (elemType = elemType_1 ∧ setType = setType_1 ∧ toSetInst = toSetInst_1)

theorem Inclusion.InclusionM.Context.mk.inj E1 #

∀ {localContext : Lean.LocalContext} {localInstances : Lean.LocalInstances} {paramSettings : Lean.NameMap Lean.Expr}
  {families : Array Lean.Name} {noIVars : Bool} {localContext_1 : Lean.LocalContext}
  {localInstances_1 : Lean.LocalInstances} {paramSettings_1 : Lean.NameMap Lean.Expr} {families_1 : Array Lean.Name}
  {noIVars_1 : Bool},
  { localContext := localContext, localInstances := localInstances, paramSettings := paramSettings,
        families := families, noIVars := noIVars } =
      { localContext := localContext_1, localInstances := localInstances_1, paramSettings := paramSettings_1,
        families := families_1, noIVars := noIVars_1 } →
    localContext = localContext_1 ∧
      localInstances = localInstances_1 ∧ paramSettings = paramSettings_1 ∧ families = families_1 ∧ noIVars = noIVars_1

def Inclusion.HypothesisM.Context.ctorIdx E1 #

Inclusion.HypothesisM.Context → ℕ

def Inclusion.IType.ctorIdx E1 #

Inclusion.IType → ℕ

def Inclusion.instInhabitedExprInclusionBody.default E1 #

Inclusion.ExprInclusionBody

theorem Inclusion.HypothesisM.Context.mk.injEq E0 #

∀ (toContext : Inclusion.InclusionM.Context) (iVarsMap : Lean.ExprMap Inclusion.IVar) (iVars : Array Inclusion.IVar)
  (toContext_1 : Inclusion.InclusionM.Context) (iVarsMap_1 : Lean.ExprMap Inclusion.IVar)
  (iVars_1 : Array Inclusion.IVar),
  ({ toContext := toContext, iVarsMap := iVarsMap, iVars := iVars } =
      { toContext := toContext_1, iVarsMap := iVarsMap_1, iVars := iVars_1 }) =
    (toContext = toContext_1 ∧ iVarsMap = iVarsMap_1 ∧ iVars = iVars_1)

def Inclusion.instInhabitedIType.default E1 #

Inclusion.IType

theorem Inclusion.InclusionM.State.mk.inj E1 #

∀ {iVars : Lean.ExprMap Inclusion.IVar} {iVarDisplays : Lean.ExprMap Lean.Expr} {iVars_1 : Lean.ExprMap Inclusion.IVar}
  {iVarDisplays_1 : Lean.ExprMap Lean.Expr},
  { iVars := iVars, iVarDisplays := iVarDisplays } = { iVars := iVars_1, iVarDisplays := iVarDisplays_1 } →
    iVars = iVars_1 ∧ iVarDisplays = iVarDisplays_1

theorem Inclusion.HypothesisM.State.mk.injEq E0 #

∀ (inclusions inclusions_1 : Lean.ExprMap (Array Inclusion.ExprInclusionBody)),
  ({ inclusions := inclusions } = { inclusions := inclusions_1 }) = (inclusions = inclusions_1)

theorem Inclusion.HypothesisM.Context.mk.inj E1 #

∀ {toContext : Inclusion.InclusionM.Context} {iVarsMap : Lean.ExprMap Inclusion.IVar} {iVars : Array Inclusion.IVar}
  {toContext_1 : Inclusion.InclusionM.Context} {iVarsMap_1 : Lean.ExprMap Inclusion.IVar}
  {iVars_1 : Array Inclusion.IVar},
  { toContext := toContext, iVarsMap := iVarsMap, iVars := iVars } =
      { toContext := toContext_1, iVarsMap := iVarsMap_1, iVars := iVars_1 } →
    toContext = toContext_1 ∧ iVarsMap = iVarsMap_1 ∧ iVars = iVars_1

def Inclusion.HypothesisM.State.ctorIdx E1 #

Inclusion.HypothesisM.State → ℕ

def Inclusion.InclusionM.Context.ctorIdx E1 #

Inclusion.InclusionM.Context → ℕ

def Inclusion.ExprInclusion.ctorIdx E1 #

Inclusion.ExprInclusion → ℕ

def Inclusion.IVar.ctorIdx E1 #

Inclusion.IVar → ℕ

theorem Inclusion.ExprInclusion.mk.injEq E0 #

∀ (inclusion proof inclusion_1 proof_1 : Lean.Expr),
  ({ inclusion := inclusion, proof := proof } = { inclusion := inclusion_1, proof := proof_1 }) =
    (inclusion = inclusion_1 ∧ proof = proof_1)

def Inclusion.ExprInclusionBody.ctorIdx E1 #

Inclusion.ExprInclusionBody → ℕ

theorem Inclusion.ExprInclusion.mk.inj E1 #

∀ {inclusion proof inclusion_1 proof_1 : Lean.Expr},
  { inclusion := inclusion, proof := proof } = { inclusion := inclusion_1, proof := proof_1 } →
    inclusion = inclusion_1 ∧ proof = proof_1

theorem Inclusion.InclusionM.Context.mk.injEq E0 #

∀ (localContext : Lean.LocalContext) (localInstances : Lean.LocalInstances) (paramSettings : Lean.NameMap Lean.Expr)
  (families : Array Lean.Name) (noIVars : Bool) (localContext_1 : Lean.LocalContext)
  (localInstances_1 : Lean.LocalInstances) (paramSettings_1 : Lean.NameMap Lean.Expr) (families_1 : Array Lean.Name)
  (noIVars_1 : Bool),
  ({ localContext := localContext, localInstances := localInstances, paramSettings := paramSettings,
        families := families, noIVars := noIVars } =
      { localContext := localContext_1, localInstances := localInstances_1, paramSettings := paramSettings_1,
        families := families_1, noIVars := noIVars_1 }) =
    (localContext = localContext_1 ∧
      localInstances = localInstances_1 ∧ paramSettings = paramSettings_1 ∧ families = families_1 ∧ noIVars = noIVars_1)

theorem Inclusion.ExprInclusionBody.mk.injEq E0 #

∀ (inclusionBody proofBody inclusionBody_1 proofBody_1 : Lean.Expr),
  ({ inclusionBody := inclusionBody, proofBody := proofBody } =
      { inclusionBody := inclusionBody_1, proofBody := proofBody_1 }) =
    (inclusionBody = inclusionBody_1 ∧ proofBody = proofBody_1)

theorem Inclusion.IType.mk.inj E1 #

∀ {elemType setType toSetInst elemType_1 setType_1 toSetInst_1 : Lean.Expr},
  { elemType := elemType, setType := setType, toSetInst := toSetInst } =
      { elemType := elemType_1, setType := setType_1, toSetInst := toSetInst_1 } →
    elemType = elemType_1 ∧ setType = setType_1 ∧ toSetInst = toSetInst_1

theorem Inclusion.ExprInclusionBody.mk.inj E1 #

∀ {inclusionBody proofBody inclusionBody_1 proofBody_1 : Lean.Expr},
  { inclusionBody := inclusionBody, proofBody := proofBody } =
      { inclusionBody := inclusionBody_1, proofBody := proofBody_1 } →
    inclusionBody = inclusionBody_1 ∧ proofBody = proofBody_1

structure Inclusion.IType E1 #

Type

An IType is a structure that holds the types of an inclusion expression x ∈ s, where the type of x is elemType, the type of s is setType and the ToSet setType elemType instance used is toSetInst.

ctor Inclusion.IType.mk E0 #

Lean.Expr → Lean.Expr → Lean.Expr → Inclusion.IType

abbrev Inclusion.IType.elemType E1 #

Inclusion.IType → Lean.Expr

The element type of an inclusion expression.

abbrev Inclusion.IType.setType E1 #

Inclusion.IType → Lean.Expr

The set type of an inclusion expression.

abbrev Inclusion.IType.toSetInst E1 #

Inclusion.IType → Lean.Expr

The ToSet setType elemType instance of an inclusion expression.

instance Inclusion.instInhabitedIType E0 #

Inhabited Inclusion.IType

structure Inclusion.IExpr E1 #

Type

An IExpr is an expression expr together with a choice of IType used to represent inclusion expressions of the form expr ∈ s.

ctor Inclusion.IExpr.mk E0 #

Inclusion.IType → Lean.Expr → Inclusion.IExpr

abbrev Inclusion.IExpr.iType E1 #

Inclusion.IExpr → Inclusion.IType

The types of an IExpr.

abbrev Inclusion.IExpr.expr E1 #

Inclusion.IExpr → Lean.Expr

The underlying expression of an IExpr.

instance Inclusion.instInhabitedIExpr E0 #

Inhabited Inclusion.IExpr

structure Inclusion.IVar E1 #

Type

An IVar is a structure that holds the data of a "free inclusion variable" associated to an inclusion expression iExpr. This includes a pair of variables setVar, hypVar (which are sometimes free variables but often synthetic opaque metavariables), where setVar is a variable for an inclusion set and hypVar is a (variable) proof of iExpr.expr ∈ setVar.

ctor Inclusion.IVar.mk E0 #

Inclusion.IExpr → Lean.Expr → Lean.Expr → Option Lean.Expr → Inclusion.IVar

abbrev Inclusion.IVar.iExpr E1 #

Inclusion.IVar → Inclusion.IExpr

The inclusion expression represented by the inclusion variable.

abbrev Inclusion.IVar.setVar E1 #

Inclusion.IVar → Lean.Expr

The inclusion set variable.

abbrev Inclusion.IVar.hypVar E1 #

Inclusion.IVar → Lean.Expr

The variable hypVar : iExpr.expr ∈ setVar.

abbrev Inclusion.IVar.cover? E1 #

Inclusion.IVar → Option Lean.Expr

An optional expression of type Cover iVar.type.setType iVar.type.elemType. When present, the inclusion computation is mapped over this cover to reduce the "dependency effect".

def Inclusion.IVar.type E1 #

Inclusion.IVar → Inclusion.IType

The IType of an IVar.

def Inclusion.IVar.expr E1 #

Inclusion.IVar → Lean.Expr

The associated expression of an IVar.

structure Inclusion.ExprInclusion E1 #

Type

An ExprInclusion is a structure associated with an expression e, containing a computed inclusion set for e and a proof that this inclusion is correct.

ctor Inclusion.ExprInclusion.mk E0 #

Lean.Expr → Lean.Expr → Inclusion.ExprInclusion

abbrev Inclusion.ExprInclusion.inclusion E1 #

Inclusion.ExprInclusion → Lean.Expr

The expression computing an inclusion set for e.

abbrev Inclusion.ExprInclusion.proof E1 #

Inclusion.ExprInclusion → Lean.Expr

A proof of e ∈ inclusion, where e is the represented expression.

instance Inclusion.instInhabitedExprInclusion E0 #

Inhabited Inclusion.ExprInclusion

structure Inclusion.ExprInclusionBody E1 #

Type

An ExprInclusionBody is an intermediate structure used in the process of building the ExprInclusion associated to an expression e. It contains an inclusionBody and proofBody which contain the (possibly partially completed) body of the inclusion and proof expressions of the ExprInclusion respectively.

ctor Inclusion.ExprInclusionBody.mk E0 #

Lean.Expr → Lean.Expr → Inclusion.ExprInclusionBody

abbrev Inclusion.ExprInclusionBody.inclusionBody E1 #

Inclusion.ExprInclusionBody → Lean.Expr

The (possibly partially completed) body of the inclusion expression.

abbrev Inclusion.ExprInclusionBody.proofBody E1 #

Inclusion.ExprInclusionBody → Lean.Expr

The (possibly partially completed) proof of e ∈ inclusionBody.

instance Inclusion.instInhabitedExprInclusionBody E0 #

Inhabited Inclusion.ExprInclusionBody

def Inclusion.IVar.toExprInclusionBody E1 #

Inclusion.IVar → Inclusion.ExprInclusionBody

Convert an IVar to an ExprInclusionBody.

structure Inclusion.InclusionM.Context E1 #

Type

The fixed context of the InclusionM monad.

ctor Inclusion.InclusionM.Context.mk E0 #

Lean.LocalContext → Lean.LocalInstances → Lean.NameMap Lean.Expr → Array Lean.Name → Bool → Inclusion.InclusionM.Context

abbrev Inclusion.InclusionM.Context.localContext E1 #

Inclusion.InclusionM.Context → Lean.LocalContext

The initial LocalContext.

abbrev Inclusion.InclusionM.Context.localInstances E1 #

Inclusion.InclusionM.Context → Lean.LocalInstances

The LocalInstances associated with localContext.

abbrev Inclusion.InclusionM.Context.paramSettings E1 #

Inclusion.InclusionM.Context → Lean.NameMap Lean.Expr

A map from inclusion parameter names to their user-supplied values.

abbrev Inclusion.InclusionM.Context.families E1 #

Inclusion.InclusionM.Context → Array Lean.Name

The names of the inclusion extension families to use.

abbrev Inclusion.InclusionM.Context.noIVars E1 #

Inclusion.InclusionM.Context → Bool

If noIVars is true then inclusion extensions should not register IVars.

structure Inclusion.InclusionM.State E1 #

Type

The mutable state of the InclusionM monad.

ctor Inclusion.InclusionM.State.mk E0 #

Lean.ExprMap Inclusion.IVar → Lean.ExprMap Lean.Expr → Inclusion.InclusionM.State

abbrev Inclusion.InclusionM.State.iVars E1 #

Inclusion.InclusionM.State → Lean.ExprMap Inclusion.IVar

A map from expressions to their inclusion variables.

abbrev Inclusion.InclusionM.State.iVarDisplays E1 #

Inclusion.InclusionM.State → Lean.ExprMap Lean.Expr

A map from inclusion set variables to the expressions used to display them in traces.

abbrev Inclusion.InclusionM E1 #

Type → Type

The monad used by the inclusion tactic during the construction of ExprInclusions.

instance Inclusion.instMonadBacktrackProdSavedStateStateInclusionM E0 #

Lean.MonadBacktrack (Lean.Meta.SavedState × Inclusion.InclusionM.State) Inclusion.InclusionM

def Inclusion.InclusionM.runWith E1 #

{α : Type} →
  Inclusion.InclusionM α →
    Inclusion.InclusionM.Context → optParam Inclusion.InclusionM.State { } → Lean.MetaM (α × Inclusion.InclusionM.State)

Run the InclusionM monad with an explicit context and initial state.

def Inclusion.InclusionM.run E1 #

{α : Type} →
  Inclusion.InclusionM α → optParam (Lean.NameMap Lean.Expr) ∅ → optParam (Array Lean.Name) #[] → Lean.MetaM α

Run the InclusionM monad using the current local context.

structure Inclusion.HypothesisM.Context E1 #

Type

The fixed context of the HypothesisM monad.

abbrev Inclusion.HypothesisM.Context.toContext E1 #

Inclusion.HypothesisM.Context → Inclusion.InclusionM.Context

ctor Inclusion.HypothesisM.Context.mk E0 #

Inclusion.InclusionM.Context → Lean.ExprMap Inclusion.IVar → Array Inclusion.IVar → Inclusion.HypothesisM.Context

abbrev Inclusion.HypothesisM.Context.iVarsMap E1 #

Inclusion.HypothesisM.Context → Lean.ExprMap Inclusion.IVar

The inclusion variables indexed by their associated expressions.

abbrev Inclusion.HypothesisM.Context.iVars E1 #

Inclusion.HypothesisM.Context → Array Inclusion.IVar

The inclusion variables whose hypotheses are being constructed.

structure Inclusion.HypothesisM.State E1 #

Type

The mutable state of the HypothesisM monad.

ctor Inclusion.HypothesisM.State.mk E0 #

Lean.ExprMap (Array Inclusion.ExprInclusionBody) → Inclusion.HypothesisM.State

abbrev Inclusion.HypothesisM.State.inclusions E1 #

Inclusion.HypothesisM.State → Lean.ExprMap (Array Inclusion.ExprInclusionBody)

The candidate inclusion bodies derived for each requested expression.

abbrev Inclusion.HypothesisM E1 #

Type → Type

The monad used by the inclusion tactic to construct initial inclusion hypotheses.

instance Inclusion.instMonadBacktrackProdSavedStateStateHypothesisM E0 #

Lean.MonadBacktrack (Lean.Meta.SavedState × Inclusion.HypothesisM.State) Inclusion.HypothesisM

def Inclusion.HypothesisM.run E1 #

{α : Type} → Inclusion.HypothesisM α → Inclusion.InclusionM α

Run the HypothesisM monad using the context and state of the current InclusionM computation.