9 #include <carl-arith/poly/umvpoly/MultivariatePolynomial.h>
10 #include <carl-arith/core/Variable.h>
11 #include <carl-arith/poly/umvpoly/functions/Factorization.h>
20 namespace onecellcad {
22 template<
typename PolyType>
26 for (
const auto& poly : polys) {
27 if (poly.is_constant())
29 else if (carl::irreducible_factors(poly,
false).size() > 1)
36 template<
typename PolyType>
38 return hasOnlyNonConstIrreducibles<PolyType>({poly});
43 std::set<T> containerAsSet(container.begin(), container.end());
44 return containerAsSet.size() == container.size();
48 bool isSubset(
const std::vector<T>& c1,
const std::vector<T>& c2) {
53 return c1Copy.size() <= c2Copy.size() &&
54 std::includes(c2Copy.begin(), c2Copy.end(), c1Copy.begin(), c1Copy.end());
59 std::vector<T> vec(s.begin(), s.end());
68 template<
typename PolyType>
70 const std::vector<PolyType>& polys,
71 const std::vector<carl::Variable>& variables) {
72 for (
const auto& poly : polys) {
73 if (!isSubset<carl::Variable>(carl::variables(poly).as_vector(), variables))
void sort(T *array, int size, LessThan lt)
bool isNonConstIrreducible(const PolyType &poly)
bool polyVarsAreAllInList(const std::vector< PolyType > &polys, const std::vector< carl::Variable > &variables)
std::vector< T > asVector(const std::set< T > s)
bool isSubset(const std::vector< T > &c1, const std::vector< T > &c2)
bool hasOnlyNonConstIrreducibles(const std::vector< PolyType > &polys)
bool hasUniqElems(const std::vector< T > &container)
bool includes(const VariableRange &superset, const carl::Variables &subset)
Class to create the formulas for axioms.