19 template<
typename IntegerType>
29 mN(
gf == nullptr ? n :
gf->symmetric_modulo(n)),
53 assert(
mGf !=
nullptr);
79 template<
typename IntegerT>
85 template<
typename IntegerT>
91 template<
typename IntegerT>
93 template<
typename IntegerT>
99 template<
typename IntegerT>
105 template<
typename IntegerT>
107 template<
typename IntegerT>
109 template<
typename IntegerT>
111 template<
typename IntegerT>
113 template<
typename IntegerT>
115 template<
typename IntegerT>
121 template<
typename IntegerT>
123 template<
typename IntegerT>
125 template<
typename IntegerT>
132 template<
typename IntegerT>
134 template<
typename IntegerT>
136 template<
typename IntegerT>
143 template<
typename IntegerT>
145 template<
typename IntegerT>
147 template<
typename IntegerT>
153 template<
typename IntegerT>
160 os <<
"(" << rhs.
mN <<
") mod ";
161 if(rhs.
mGf !=
nullptr)
163 os << rhs.
mGf->size();
174 template<
typename IntegerT>
179 template<
typename IntegerT>
184 template<
typename IntegerT>
189 template<
typename IntegerT>
199 template<
typename IntegerT>
209 template<
typename IntegerType>
carl is the main namespace for the library.
std::string toString(Relation r)
Interval< Number > abs(const Interval< Number > &_in)
Method which returns the absolute value of the passed number.
Interval< Number > quotient(const Interval< Number > &_lhs, const Interval< Number > &_rhs)
Implements the division with remainder.
bool is_zero(const Interval< Number > &i)
Check if this interval is a point-interval containing 0.
bool is_integer(const Interval< Number > &n)
bool is_one(const Interval< Number > &i)
Check if this interval is a point-interval containing 1.
Galois Field numbers, i.e.
friend bool operator==(const GFNumber< IntegerT > &lhs, const IntegerT &rhs)
lhs == rhs, if rhs \in [lhs].
GFNumber(IntegerType n, const GaloisField< IntegerType > *gf=nullptr)
friend bool operator==(const GFNumber< IntegerT > &lhs, int rhs)
lhs == rhs, if rhs \in [lhs].
friend bool operator!=(int lhs, const GFNumber< IntegerT > &rhs)
GFNumber & operator*=(const IntegerType &rhs)
friend bool operator!=(const GFNumber< IntegerT > &lhs, const GFNumber< IntegerT > &rhs)
GFNumber & operator*=(const GFNumber &rhs)
GFNumber & operator-=(const GFNumber &rhs)
GFNumber & operator+=(const GFNumber &rhs)
friend bool operator==(const GFNumber< IntegerT > &lhs, const GFNumber< IntegerT > &rhs)
GFNumber< IntegerType > toGF(const GaloisField< IntegerType > *newfield) const
friend GFNumber< IntegerT > operator-(const GFNumber< IntegerT > &lhs, const IntegerT &rhs)
friend GFNumber< IntegerT > operator*(const IntegerT &lhs, const GFNumber< IntegerT > &rhs)
friend bool operator!=(const GFNumber< IntegerT > &lhs, int rhs)
const GaloisField< IntegerType > * gf() const
friend bool operator!=(const IntegerT &lhs, const GFNumber< IntegerT > &rhs)
friend GFNumber< IntegerT > operator+(const IntegerT &lhs, const GFNumber< IntegerT > &rhs)
GFNumber & operator/=(const GFNumber &rhs)
friend GFNumber< IntegerT > operator/(const GFNumber< IntegerT > &lhs, const GFNumber< IntegerT > &rhs)
friend GFNumber< IntegerT > operator+(const GFNumber< IntegerT > &lhs, const IntegerT &rhs)
friend GFNumber< IntegerT > operator-(const IntegerT &lhs, const GFNumber< IntegerT > &rhs)
friend bool operator==(int lhs, const GFNumber< IntegerT > &rhs)
lhs == rhs, if lhs \in [rhs].
friend bool operator!=(const GFNumber< IntegerT > &lhs, const IntegerT &rhs)
GFNumber(const GFNumber &n, const GaloisField< IntegerType > *gf)
GFNumber & operator+=(const IntegerType &rhs)
const GaloisField< IntegerType > * mGf
friend GFNumber< IntegerT > operator*(const GFNumber< IntegerT > &lhs, const IntegerT &rhs)
const IntegerType & representing_integer() const
friend GFNumber< IntegerT > operator+(const GFNumber< IntegerT > &lhs, const GFNumber< IntegerT > &rhs)
friend GFNumber< IntegerT > operator-(const GFNumber< IntegerT > &lhs, const GFNumber< IntegerT > &rhs)
friend GFNumber< IntegerT > operator*(const GFNumber< IntegerT > &lhs, const GFNumber< IntegerT > &rhs)
GFNumber & operator-=(const IntegerType &rhs)
friend std::ostream & operator<<(std::ostream &os, const GFNumber &rhs)
const GFNumber operator-() const
friend bool operator==(const IntegerT &lhs, const GFNumber< IntegerT > &rhs)
lhs == rhs, if lhs \in [rhs].