Documentation

Cslib.Languages.LambdaCalculus.LocallyNameless.Untyped.MultiApp

multiApp f [x₁, x₂, ..., xₙ] applies the arguments x₁, x₂, ..., xₙ to f in left-associative order, i.e. as (((f x₁) x₂) ... xₙ).

Equations
Instances For

    A list of arguments performs a single reduction step

    [x₁, ..., xᵢ ..., xₙ] ⭢βᶠ [x₁, ..., xᵢ', ..., xₙ]

    if one of the arguments performs a single step xᵢ ⭢βᶠ xᵢ' and the rest of the arguments are locally closed.

    Instances For
      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          theorem Cslib.LambdaCalculus.LocallyNameless.Untyped.Term.multiApp_lc {Var : Type u} {M : Term Var} {Ns : List (Term Var)} :
          (M.multiApp Ns).LC M.LC NNs, N.LC

          A term resulting from a multi-application is locally closed if and only if the leftmost term and all arguments applied to it are locally closed

          theorem Cslib.LambdaCalculus.LocallyNameless.Untyped.Term.step_multiApp_l {Var : Type u} {M M' : Term Var} {Ns : List (Term Var)} (steps : M.FullBeta M') (lc_Ns : NNs, N.LC) :
          (M.multiApp Ns).FullBeta (M'.multiApp Ns)

          Just like ordinary beta reduction, the left-hand side of a multi-application step is locally closed

          theorem Cslib.LambdaCalculus.LocallyNameless.Untyped.Term.steps_multiApp_l {Var : Type u} {M M' : Term Var} {Ns : List (Term Var)} (steps : Relation.ReflTransGen FullBeta M M') (lc_Ns : NNs, N.LC) :

          Congruence lemma for multi reduction of the left most term of a multi-application

          theorem Cslib.LambdaCalculus.LocallyNameless.Untyped.Term.step_multiApp_r {Var : Type u} {M : Term Var} {Ns Ns' : List (Term Var)} (steps : ListFullBeta Ns Ns') (lc_M : M.LC) :
          (M.multiApp Ns).FullBeta (M.multiApp Ns')

          Congruence lemma for single reduction of one of the arguments of a multi-application

          Congruence lemma for multiple reduction of one of the arguments of a multi-application

          theorem Cslib.LambdaCalculus.LocallyNameless.Untyped.Term.invert_abs_multiApp_st {Var : Type u} {Ps : List (Term Var)} {M N Q : Term Var} (h_red : ((M.abs.app N).multiApp Ps).FullBeta Q) :
          (∃ (M' : Term Var), M.abs.FullBeta M'.abs Q = (M'.abs.app N).multiApp Ps) (∃ (N' : Term Var), N.FullBeta N' Q = (M.abs.app N').multiApp Ps) (∃ (Ps' : List (Term Var)), ListFullBeta Ps Ps' Q = (M.abs.app N).multiApp Ps') Q = (M.open' N).multiApp Ps

          If a term (λ M) N P_1 ... P_n reduces in a single step to Q, then Q must be one of the following forms:

          Q = (λ M') N P₁ ... Pₙ where M ⭢βᶠ M' or Q = (λ M) N' P₁ ... Pₙ where N ⭢βᶠ N' or Q = (λ M) N P₁' ... Pₙ' where P_i ⭢βᶠ P_i' for some i or Q = (M ^ N) P₁ ... Pₙ

          If a term (λ M) N P₁ ... Pₙ reduces in multiple steps to Q, then either Q if of the form

          Q = (λ M') N' P'₁ ... P'ₙ

          or

          we first reach an intermediate term of this shape,

          (λ M) N P₁ ... Pₙ ↠βᶠ (λ M') N' P'₁ ... P'ₙ

          then perform a beta reduction and reduce further to Q

          (λ M') N' P'₁ ... P'ₙ ↠βᶠ M' ^ N' P'_₁ ... P'_ₙ ↠βᶠ Q

          where M ↠βᶠ M' and N ↠βᶠ N' and P_i ↠βᶠ P_i' for all i

          theorem Cslib.LambdaCalculus.LocallyNameless.Untyped.Term.multiApp_step_lc_r {Var : Type u} {Ns Ns' : List (Term Var)} [DecidableEq Var] [HasFresh Var] (step : ListFullBeta Ns Ns') (N : Term Var) :
          N Ns'N.LC

          Just like ordinary beta reduction, the right-hand side of a multi-application step is locally closed

          theorem Cslib.LambdaCalculus.LocallyNameless.Untyped.Term.multiApp_steps_lc {Var : Type u} {Ns Ns' : List (Term Var)} [DecidableEq Var] [HasFresh Var] (step : Relation.ReflTransGen ListFullBeta Ns Ns') (H : NNs, N.LC) (N : Term Var) :
          N Ns'N.LC

          Just like ordinary beta reduction, multiple steps of a argument list preserves local closure