CoxIter  1.2 CoxIter - Computing invariants of hyperbolic Coxeter groups
Rational< T > Class Template Reference

`#include <rational.h>`

## Public Member Functions

Rational ()

Rational (T a, T b)

Rational (T a)

Rational (const int &i)

bool operator> (Rational const &) const

bool operator>= (int const &) const

bool operator== (int const &) const

bool operator== (Rational const &) const

bool operator!= (Rational const &) const

Rationaloperator= (long int)

Rational operator+ (Rational const &n) const

Rationaloperator+= (Rational const &n)

Rational operator- (Rational const &n) const

Rational operator- () const

void opp (Rational *&_c) const

Rationaloperator-= (Rational const &n)

Rational operator* (Rational const &n) const

Rationaloperator*= (Rational const &n)

Rational operator/ (Rational const &n) const

Rationaloperator/= (Rational const &n)

void print (ostream &) const

string to_string () const

bool get_hasDenominatorOne () const

a

b

## Private Member Functions

void update ()
Met à jour les attributs (gcd, isInt, ...) More...

## Private Attributes

bool isZero

bool hasDenominatorOne

bool isOne

bool isMinusOne

## Constructor & Destructor Documentation

template<typename T >
 Rational< T >::Rational ( )
template<typename T >
 Rational< T >::Rational ( T a, T b )
template<typename T >
 Rational< T >::Rational ( T a )
template<typename T >
 Rational< T >::Rational ( const int & i )

## Member Function Documentation

template<typename T >
 bool Rational< T >::get_hasDenominatorOne ( ) const
template<typename T >
 bool Rational< T >::operator!= ( Rational< T > const & ) const
template<typename T >
 Rational Rational< T >::operator* ( Rational< T > const & n ) const
template<typename T >
 Rational& Rational< T >::operator*= ( Rational< T > const & n )
template<typename T >
 Rational Rational< T >::operator+ ( Rational< T > const & n ) const
template<typename T >
 Rational& Rational< T >::operator+= ( Rational< T > const & n )
template<typename T >
 Rational Rational< T >::operator- ( Rational< T > const & n ) const
template<typename T >
 Rational Rational< T >::operator- ( ) const
template<typename T >
 Rational& Rational< T >::operator-= ( Rational< T > const & n )
template<typename T >
 Rational Rational< T >::operator/ ( Rational< T > const & n ) const
template<typename T >
 Rational& Rational< T >::operator/= ( Rational< T > const & n )
template<typename T >
 Rational& Rational< T >::operator= ( long int )
template<typename T >
 bool Rational< T >::operator== ( int const & ) const
template<typename T >
 bool Rational< T >::operator== ( Rational< T > const & ) const
template<typename T >
 bool Rational< T >::operator> ( Rational< T > const & ) const
template<typename T >
 bool Rational< T >::operator>= ( int const & ) const
template<typename T >
 void Rational< T >::opp ( Rational< T > *& _c ) const
template<typename T >
 void Rational< T >::print ( ostream & ) const
template<typename T >
 string Rational< T >::to_string ( ) const
template<typename T >
 Rational< T >::update ( )
private

Met à jour les attributs (gcd, isInt, ...)

## Member Data Documentation

template<typename T >
 T Rational< T >::a
template<typename T >
 T Rational< T >::b
template<typename T >
 bool Rational< T >::hasDenominatorOne
private
template<typename T >
 bool Rational< T >::isMinusOne
private
template<typename T >
 bool Rational< T >::isOne
private
template<typename T >
 bool Rational< T >::isZero
private

The documentation for this class was generated from the following file: