Documentation

SSA.Experimental.Bits.AutoStructs.Constructions

def NFA.addSink {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m : NFA A) :
NFA A
Equations
  • One or more equations did not get rendered due to their size.
Instances For
    def NFA.flipFinals {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m : NFA A) :
    NFA A
    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      def product {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (final? : BoolBoolBool) (m1 : NFA A) (m2 : NFA A) :
      NFA A
      Equations
      Instances For
        def product.init {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m1 : NFA A) (m2 : NFA A) (st : product.State) :
        product.State
        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          @[irreducible]
          def product.go {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (final? : BoolBoolBool) (m1 : NFA A) (m2 : NFA A) (st0 : product.State) :
          NFA A
          Equations
          • One or more equations did not get rendered due to their size.
          Instances For
            def NFA.inter {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m1 : NFA A) (m2 : NFA A) :
            NFA A
            Equations
            Instances For
              def NFA.union {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m1 : NFA A) (m2 : NFA A) :
              NFA A
              Equations
              • m1.union m2 = product (fun (b1 b2 : Bool) => b1 || b2) m1.addSink m2.addSink
              Instances For
                def HashSet.inter {A : Type u_1} [BEq A] [Hashable A] (m1 : Std.HashSet A) (m2 : Std.HashSet A) :
                Equations
                Instances For
                  def Std.HashSet.isDisjoint {A : Type u_1} [BEq A] [Hashable A] (m1 : Std.HashSet A) (m2 : Std.HashSet A) :
                  Equations
                  Instances For
                    def HashSet.areIncluded {A : Type u_1} [BEq A] [Hashable A] (m1 : Std.HashSet A) (m2 : Std.HashSet A) :
                    Equations
                    Instances For
                      instance hashableHashSet {A : Type} [BEq A] [Hashable A] :
                      Equations
                      def NFA.determinize {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (mi : NFA A) :
                      NFA A
                      Equations
                      • One or more equations did not get rendered due to their size.
                      Instances For
                        @[irreducible]
                        def NFA.determinize.go {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (mi : NFA A) (st : NFA.determinize.St) :
                        NFA A
                        Equations
                        • One or more equations did not get rendered due to their size.
                        Instances For
                          def NFA.neg {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m : NFA A) :
                          NFA A
                          Equations
                          • m.neg = m.determinize.flipFinals
                          Instances For
                            def NFA.isIncluded {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m1 : NFA A) (m2 : NFA A) :

                            Returns true when L(m1) ⊆ L(m2)

                            Equations
                            • One or more equations did not get rendered due to their size.
                            Instances For
                              @[irreducible]
                              def NFA.isIncluded.go {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m1 : NFA A) (m2 : NFA A) (st : isIncluded.State) :
                              Equations
                              • One or more equations did not get rendered due to their size.
                              Instances For
                                def NFA.isUniversal {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m : NFA A) :

                                Returns true when L(m) = A*

                                Equations
                                Instances For
                                  @[irreducible]
                                  def NFA.isUniversal.go {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m : NFA A) (st : isUniversal.State) :
                                  Equations
                                  • One or more equations did not get rendered due to their size.
                                  Instances For
                                    def NFA.emptyWord {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] :
                                    NFA A

                                    Recognizes the empty word

                                    Equations
                                    • NFA.emptyWord = match NFA.empty.newState with | (s, m) => let m := m.addInitial s; let m := m.addFinal s; m
                                    Instances For
                                      def NFA.isUniversal' {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m : NFA A) :

                                      Returns true when L(m) ∪ {ε} = A*. This is useful because the bitvector of with width zero has strange properties.

                                      Equations
                                      • m.isUniversal' = (m.union NFA.emptyWord).isUniversal
                                      Instances For
                                        def NFA.isEmpty {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m : NFA A) :
                                        Equations
                                        • m.isEmpty = m.finals.isEmpty
                                        Instances For
                                          def NFA.isNotEmpty {A : Type} [BEq A] [Hashable A] [DecidableEq A] [FinEnum A] (m : NFA A) :
                                          Equations
                                          • m.isNotEmpty = !m.finals.isEmpty
                                          Instances For
                                            Equations
                                            • instHashableBitVec_sSA = { hash := fun (x : BitVec n) => hash x.toFin }
                                            def transport {n2 : } {n1 : } (f : Fin n2Fin n1) (bv : BitVec n1) :
                                            Equations
                                            Instances For
                                              def NFA.lift {n1 : } {n2 : } (m1 : NFA (BitVec n1)) (f : Fin n1Fin n2) :
                                              NFA (BitVec n2)
                                              Equations
                                              • One or more equations did not get rendered due to their size.
                                              Instances For
                                                def NFA.proj {n1 : } {n2 : } (m1 : NFA (BitVec n1)) (f : Fin n2Fin n1) :
                                                NFA (BitVec n2)
                                                Equations
                                                • One or more equations did not get rendered due to their size.
                                                Instances For