Documentation

LeanPool.MatchingLogic.EntryIII.Completion

MatchingLogic.EntryIII.Completion #

@[instance_reducible]

Local decidable equality used by the model-completion construction.

Equations
Instances For

    Some element variable is absent from every world generated by root.

    Equations
    Instances For

      The source's conditional completion: all generated worlds are present, while none is a legal point exactly when Missing root holds.

      Equations
      Instances For

        A completed point is the added star precisely when its option is none.

        Equations
        Instances For

          Embed a generated world into the completed carrier.

          Equations
          Instances For

            Construct the star point from evidence that a variable is missing.

            Equations
            Instances For

              The generated-world embedding is injective.

              theorem MatchingLogic.completedStar_ne_embed {S : Signature} {root : CanonicalCarrier S} (hmissing : Missing root) (world : GeneratedCarrier root) :
              completedStar hmissing completedEmbed root world

              The conditional star is distinct from every embedded generated world.

              The representation has a star point exactly in the source's missing-variable case.

              theorem MatchingLogic.completedCarrier_cases {S : Signature} {root : CanonicalCarrier S} (point : CompletedCarrier root) :
              (∃ (world : GeneratedCarrier root), point = completedEmbed root world) ∃ (hmissing : Missing root), point = completedStar hmissing

              Every completed point is either an embedded generated world or the unique conditional star.

              Completed interpretation #

              def MatchingLogic.completedInterp {S : Signature} (root : CanonicalCarrier S) (sigma : S.Sym) (inputs : Fin (S.arity sigma)CompletedCarrier root) :

              Source Definition 79's interpretation. The existential tuple makes the three cases exact: a star input admits no tuple; real outputs are the generated interpretation; and star is an additional output exactly when some real input is the generated root.

              Equations
              • One or more equations did not get rendered due to their size.
              Instances For
                @[reducible, inline]

                The completed one-sorted model.

                Equations
                Instances For
                  @[simp]
                  theorem MatchingLogic.mem_completedInterp {S : Signature} {root : CanonicalCarrier S} {sigma : S.Sym} {inputs : Fin (S.arity sigma)CompletedCarrier root} {output : CompletedCarrier root} :
                  output completedInterp root sigma inputs ∃ (components : Fin (S.arity sigma)GeneratedCarrier root), (∀ (i : Fin (S.arity sigma)), inputs i = completedEmbed root (components i)) ((∃ (world : GeneratedCarrier root), output = completedEmbed root world world generatedInterp root sigma components) output.isStar ∃ (i : Fin (S.arity sigma)), components i = generatedRoot root)
                  @[simp]
                  theorem MatchingLogic.completedModel_interp {S : Signature} (root : CanonicalCarrier S) (sigma : S.Sym) (inputs : Fin (S.arity sigma)CompletedCarrier root) :
                  (completedModel root).interp sigma inputs = completedInterp root sigma inputs
                  theorem MatchingLogic.mem_completedModel_interp {S : Signature} {root : CanonicalCarrier S} {sigma : S.Sym} {inputs : Fin (S.arity sigma)CompletedCarrier root} {output : CompletedCarrier root} :
                  output (completedModel root).interp sigma inputs output completedInterp root sigma inputs
                  theorem MatchingLogic.completedInterp_eq_empty_of_input_star {S : Signature} {root : CanonicalCarrier S} {sigma : S.Sym} {inputs : Fin (S.arity sigma)CompletedCarrier root} (i : Fin (S.arity sigma)) (hstar : (inputs i).isStar) :
                  completedInterp root sigma inputs =

                  Any star input forces the completed symbol interpretation to be empty.

                  theorem MatchingLogic.completedEmbed_mem_completedInterp_iff {S : Signature} (root : CanonicalCarrier S) {sigma : S.Sym} (components : Fin (S.arity sigma)GeneratedCarrier root) (world : GeneratedCarrier root) :
                  (completedEmbed root world completedInterp root sigma fun (i : Fin (S.arity sigma)) => completedEmbed root (components i)) world generatedInterp root sigma components

                  On all-real inputs, real output membership is exactly membership in the generated interpretation.

                  theorem MatchingLogic.completedStar_mem_completedInterp_iff {S : Signature} {root : CanonicalCarrier S} (hmissing : Missing root) {sigma : S.Sym} (components : Fin (S.arity sigma)GeneratedCarrier root) :
                  (completedStar hmissing completedInterp root sigma fun (i : Fin (S.arity sigma)) => completedEmbed root (components i)) ∃ (i : Fin (S.arity sigma)), components i = generatedRoot root

                  On all-real inputs, star is output exactly when one component is the generated root.

                  Completed valuation #

                  noncomputable def MatchingLogic.completedValuation {S : Signature} (root : CanonicalCarrier S) (x : ) :

                  Select the unique generated world containing var x, when one exists; otherwise select the conditional star justified by x itself.

                  Equations
                  • One or more equations did not get rendered due to their size.
                  Instances For
                    theorem MatchingLogic.completedValuation_isStar_iff {S : Signature} (root : CanonicalCarrier S) (x : ) :
                    (completedValuation root x).isStar ∀ (world : GeneratedCarrier root), Pattern.var xworld

                    The completed valuation is star exactly for variables missing from all generated worlds.

                    The selection is well-defined: it names an embedded world exactly when that world contains the variable, with uniqueness supplied by Lemma 78.

                    Every point of the completed carrier is named by some element variable.