Documentation

ExistentialRules.ChaseSequence.Termination.ConstantMappings.InterplayWithRenamingConstantsApart

Interaction of Strict Constant Mappings and Renaming Constant Apart #

For PreGroundTerm, GroundTerm, GroundSubstitution, and PreTrigger, we do the following things:

  1. We define what it means for them to have the same_skeleton, which is the case if their only difference is the naming of constants in terms (but their structure is the same),
  2. we show that applying a StrictConstantMapping yields something that has the same skeleton,
  3. we show that for two things with the same skeleton, we can find a StrictConstantMapping that maps the renamed apart version of the first thing to the second one while mapping each constant to itself that does not occur in the renamed apart version.
theorem PreGroundTerm.same_skeleton_symm {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] (term term2 : PreGroundTerm sig) :
term.same_skeleton term2term2.same_skeleton term
theorem PreGroundTerm.same_skeleton_list_symm {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] (terms terms2 : List (PreGroundTerm sig)) :
same_skeleton_list terms terms2same_skeleton_list terms2 terms
theorem PreGroundTerm.exists_strict_constant_mapping_to_reverse_renaming {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] [DecidableEq sig.P] [GetFreshInhabitant sig.C] (term term2 : PreGroundTerm sig) (terms_same_skeleton : term.same_skeleton term2) (forbidden_constants : List sig.C) :
(g : StrictConstantMapping sig), g.toConstantMapping.apply_pre_ground_term (term.rename_constants_apart forbidden_constants) = term2 ∀ (d : sig.C), ¬d FiniteTree.leaves (term.rename_constants_apart forbidden_constants)g d = d
theorem PreGroundTerm.exists_strict_constant_mapping_to_reverse_renaming_list {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] [DecidableEq sig.P] [GetFreshInhabitant sig.C] (terms terms2 : List (PreGroundTerm sig)) (terms_same_skeleton : same_skeleton_list terms terms2) (forbidden_constants : List sig.C) :
(g : StrictConstantMapping sig), List.map (fun (term : PreGroundTerm sig) => g.toConstantMapping.apply_pre_ground_term term) (rename_constants_apart.foldl_list terms forbidden_constants) = terms2 ∀ (d : sig.C), ¬d List.flatMap FiniteTree.leaves (rename_constants_apart.foldl_list terms forbidden_constants)g d = d
def GroundTerm.same_skeleton {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] (term term2 : GroundTerm sig) :
Equations
Instances For
    theorem GroundTerm.same_skeleton_symm {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] (term term2 : GroundTerm sig) :
    term.same_skeleton term2term2.same_skeleton term
    theorem GroundTerm.exists_strict_constant_mapping_to_reverse_renaming {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] [DecidableEq sig.P] [GetFreshInhabitant sig.C] (term term2 : GroundTerm sig) (terms_same_skeleton : term.same_skeleton term2) (forbidden_constants : List sig.C) :
    (g : StrictConstantMapping sig), g.toConstantMapping.apply_ground_term (term.rename_constants_apart forbidden_constants) = term2 ∀ (d : sig.C), ¬d (term.rename_constants_apart forbidden_constants).constantsg d = d
    Equations
    Instances For
      theorem GroundSubstitution.same_skeleton_for_vars_symm {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] (subs subs2 : GroundSubstitution sig) (vars : List sig.V) :
      subs.same_skeleton_for_vars subs2 varssubs2.same_skeleton_for_vars subs vars
      theorem GroundSubstitution.exists_strict_constant_mapping_to_reverse_renaming_for_vars {sig : Signature} [DecidableEq sig.C] [DecidableEq sig.V] [DecidableEq sig.P] [GetFreshInhabitant sig.C] (subs subs2 : GroundSubstitution sig) (vars : List sig.V) (vars_nodup : vars.Nodup) (subs_same_skeleton : subs.same_skeleton_for_vars subs2 vars) (forbidden_constants : List sig.C) :
      (g : StrictConstantMapping sig), (∀ (v : sig.V), v varsg.toConstantMapping.apply_ground_term (subs.rename_constants_apart_for_vars forbidden_constants vars v) = subs2 v) ∀ (d : sig.C), ¬d List.flatMap GroundTerm.constants (List.map (subs.rename_constants_apart_for_vars forbidden_constants vars) vars)g d = d
      def PreTrigger.same_skeleton {sig : Signature} [DecidableEq sig.P] [DecidableEq sig.C] [DecidableEq sig.V] (trg trg2 : PreTrigger sig) :
      Equations
      Instances For
        theorem PreTrigger.same_skeleton_symm {sig : Signature} [DecidableEq sig.P] [DecidableEq sig.C] [DecidableEq sig.V] (trg trg2 : PreTrigger sig) :
        trg.same_skeleton trg2trg2.same_skeleton trg
        theorem PreTrigger.exists_strict_constant_mapping_to_reverse_renaming {sig : Signature} [DecidableEq sig.P] [DecidableEq sig.C] [DecidableEq sig.V] [GetFreshInhabitant sig.C] (trg trg2 : PreTrigger sig) (trgs_same_skeleton : trg.same_skeleton trg2) (forbidden_constants : List sig.C) :