Documentation

Cslib.Foundations.Syntax.Congruence

Typeclass for congruence over a context.

class Cslib.Congruence {α : Sort u_1} (r : ααProp) :

The relation r is a congruence on α. This class gives access to the ≡[r] notation. To instantiate a canonical congruence for α, see HasCongruence.

Congruence relations should also instantiate LawfulCongruence to prove that the relation respects the expected congruence laws.

    Instances
      def Cslib.Congruence.r {α : Sort u_1} (r : ααProp) [Congruence r] :
      ααProp

      a ≡[r] b means that the a and b are related by the congruence r.

      Equations
      Instances For

        a ≡[r] b means that the a and b are related by the congruence r.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          class Cslib.DefaultCongruence (α : Type u_1) (r : outParam (ααProp)) :

          The type α has a canonical congruence relation. This gives access to the notation.

            Instances
              def Cslib.DefaultCongruence.r {α : Type u_1} {r : ααProp} [DefaultCongruence α r] (a b : α) :

              a ≡ b means that a and b are related by the canonical congruence relation for their type.

              Equations
              Instances For

                a ≡ b means that a and b are related by the canonical congruence relation for their type.

                Equations
                Instances For
                  @[instance_reducible]
                  instance Cslib.instCongruenceOfDefaultCongruence (α : Type u_1) (r : ααProp) [DefaultCongruence α r] :
                  Equations
                  class Cslib.LawfulCongruence {α : Type u_1} (r : ααProp) [Congruence r] [HasContext α] extends IsEquiv α r, CovariantClass (Cslib.HasContext.Context α) α (fun (x1 : Cslib.HasContext.Context α) (x2 : α) => x1<[x2]) fun (x1 x2 : α) => Cslib.Congruence.r r x1 x2 :

                  An equivalence relation on α preserved by all contexts.

                  Instances