Documentation

Cvc.Untyped.Theory.Bag

Generated Bag constructors, sort-erased #

def Cvc.Untyped.Term.bagInterMinN [Ω] (terms : Terms) (atLeastTwoElements : 2 ≤ Array.size terms := by (try grind) <;> fail "failed to prove term array has at least two elements") :

bagInterMin over two or more terms.

Equations
Instances For

    Whether every multiplicity in lft is at most the one in rgt.

    Equations
    Instances For

      The empty bag of elements of sort α.

      Equations
      Instances For

        Difference subtracting the multiplicities.

        Equations
        Instances For

          Duplicate removal, yielding a bag whose multiplicities are all at most one.

          Equations
          Instances For
            def Cvc.Untyped.Term.bagUnionMaxN [Ω] (terms : Terms) (atLeastTwoElements : 2 ≤ Array.size terms := by (try grind) <;> fail "failed to prove term array has at least two elements") :

            bagUnionMax over two or more terms.

            Equations
            Instances For

              Whether elm is in b; the element comes first, as in cvc5.

              Equations
              Instances For

                Union adding the multiplicities.

                Equations
                Instances For

                  The elements of a bag satisfying a predicate, with their multiplicities.

                  Equations
                  Instances For

                    Cardinality, counting multiplicities.

                    Equations
                    Instances For

                      An unspecified element of a non-empty bag.

                      Equations
                      Instances For

                        Union taking the maximum of the multiplicities.

                        Equations
                        Instances For
                          def Cvc.Untyped.Term.bagMake [Ω] (elm count : Term) :

                          The bag holding elm count times; the element comes first, as in cvc5.

                          Equations
                          Instances For

                            Intersection taking the minimum of the multiplicities.

                            Equations
                            Instances For

                              Whether some element of a bag satisfies a predicate.

                              Equations
                              Instances For
                                def Cvc.Untyped.Term.bagUnionDisjointN [Ω] (terms : Terms) (atLeastTwoElements : 2 ≤ Array.size terms := by (try grind) <;> fail "failed to prove term array has at least two elements") :

                                bagUnionDisjoint over two or more terms.

                                Equations
                                Instances For
                                  Equations
                                  • One or more equations did not get rendered due to their size.
                                  Instances For

                                    Folds f over the elements of b from init, in no specified order.

                                    Equations
                                    Instances For

                                      Whether every element of a bag satisfies a predicate.

                                      Equations
                                      Instances For

                                        The image of a bag under a function.

                                        Equations
                                        Instances For

                                          Partitions a bag into the equivalence classes of a binary predicate.

                                          The predicate is expected to be an equivalence relation; the result holds one bag per class.

                                          Equations
                                          Instances For

                                            Difference removing every element occurring on the right.

                                            Equations
                                            Instances For

                                              Multiplicity of elm in b; the element comes first, as in cvc5.

                                              Equations
                                              Instances For
                                                Equations
                                                • One or more equations did not get rendered due to their size.
                                                Instances For

                                                  Bag's operators, taken apart one level, sort-erased.

                                                  • bagMember [Ω] (elm b : Term) : View.Bag

                                                    Whether elm is in b; the element comes first, as in cvc5.

                                                  • bagSubbag [Ω] (lft rgt : Term) : View.Bag

                                                    Whether every multiplicity in lft is at most the one in rgt.

                                                  • bagMake [Ω] (elm count : Term) : View.Bag

                                                    The bag holding elm count times; the element comes first, as in cvc5.

                                                  • bagCount [Ω] (elm b : Term) : View.Bag

                                                    Multiplicity of elm in b; the element comes first, as in cvc5.

                                                  • bagCard [Ω] (b : Term) : View.Bag

                                                    Cardinality, counting multiplicities.

                                                  • bagSetof [Ω] (b : Term) : View.Bag

                                                    Duplicate removal, yielding a bag whose multiplicities are all at most one.

                                                  • bagChoose [Ω] (b : Term) : View.Bag

                                                    An unspecified element of a non-empty bag.

                                                  • bagUnionMax [Ω] (kids : Kids) : View.Bag

                                                    Union taking the maximum of the multiplicities.

                                                    kids holds every operand, two or more.

                                                  • bagUnionDisjoint [Ω] (kids : Kids) : View.Bag

                                                    Union adding the multiplicities.

                                                    kids holds every operand, two or more.

                                                  • bagInterMin [Ω] (kids : Kids) : View.Bag

                                                    Intersection taking the minimum of the multiplicities.

                                                    kids holds every operand, two or more.

                                                  • bagDifferenceSubtract [Ω] (lft rgt : Term) : View.Bag

                                                    Difference subtracting the multiplicities.

                                                  • bagDifferenceRemove [Ω] (lft rgt : Term) : View.Bag

                                                    Difference removing every element occurring on the right.

                                                  • bagMap [Ω] (f b : Term) : View.Bag

                                                    The image of a bag under a function.

                                                  • bagFilter [Ω] (p b : Term) : View.Bag

                                                    The elements of a bag satisfying a predicate, with their multiplicities.

                                                  • bagFold [Ω] (f init b : Term) : View.Bag

                                                    Folds f over the elements of b from init, in no specified order.

                                                  • bagAll [Ω] (p b : Term) : View.Bag

                                                    Whether every element of a bag satisfies a predicate.

                                                  • bagSome [Ω] (p b : Term) : View.Bag

                                                    Whether some element of a bag satisfies a predicate.

                                                  • bagPartition [Ω] (p b : Term) : View.Bag

                                                    Partitions a bag into the equivalence classes of a binary predicate.

                                                    The predicate is expected to be an equivalence relation; the result holds one bag per class.

                                                  • bagEmpty [Ω] : View.Bag

                                                    The empty bag of elements of sort α.

                                                  Instances For

                                                    Takes a term apart one level, if Bag owns its operator.

                                                    Equations
                                                    • One or more equations did not get rendered due to their size.
                                                    Instances For

                                                      Values #

                                                      A Cvc.Bag denotes an SMT bag: the empty bag, unioned with one singleton bag per element, each carrying that element's multiplicity.

                                                      def Cvc.Untyped.Term.mkBagValue {α : Type} [Ω] [Ord α] [ToTyp α] [ValueToTerm α] (bag : Bag α) :

                                                      The bag term denoting a bag of values.

                                                      Equations
                                                      • One or more equations did not get rendered due to their size.
                                                      Instances For
                                                        partial def Cvc.Untyped.Term.getBagValue {α : Type} [Ω] [Ord α] [TermToValue α] (term : Term) :
                                                        Env (Bag α)

                                                        The bag of values a constant bag term denotes.

                                                        Works on a bag built from bagEmpty, bagMake and unions as well as on a model's answer; an intersection or a difference is refused.

                                                        @[instance_reducible]
                                                        Equations
                                                        @[instance_reducible]
                                                        Equations