Givaro
Public Types | Public Member Functions | Data Fields
RationalDom Class Reference

Rational Domain. More...

#include <givrational.h>

+ Collaboration diagram for RationalDom:

Public Types

typedef Rational Element
typedef Rational Rep

Public Member Functions

 RationalDom ()
template<class X >
 RationalDom (const X &x)
int operator== (const RationalDom &) const
int operator!= (const RationalDom &) const
unsigned long characteristic () const
Integercharacteristic (Integer &p) const
Repinit (Rep &a) const
Repinit (Rep &a, const Rep &b) const
Repassign (Rep &a, const Rep &b) const
Repmul (Rep &r, const Rep &a, const Rep &b) const
Repdiv (Rep &r, const Rep &a, const Rep &b) const
Repadd (Rep &r, const Rep &a, const Rep &b) const
Repsub (Rep &r, const Rep &a, const Rep &b) const
Repmulin (Rep &r, const Rep &a) const
Repdivin (Rep &r, const Rep &a) const
Repaddin (Rep &r, const Rep &a) const
Repsubin (Rep &r, const Rep &a) const
Repaxpy (Rep &r, const Rep &a, const Rep &b, const Rep &c) const
Repaxpyin (Rep &r, const Rep &a, const Rep &b) const
Repmaxpy (Rep &r, const Rep &a, const Rep &b, const Rep &c) const
Repaxmy (Rep &r, const Rep &a, const Rep &b, const Rep &c) const
Repaxmyin (Rep &r, const Rep &a, const Rep &b) const
Repmaxpyin (Rep &r, const Rep &a, const Rep &b) const
Repneg (Rep &r, const Rep &a) const
Repinv (Rep &r, const Rep &a) const
Repnegin (Rep &r) const
Repinvin (Rep &r) const
Reppow (Rep &r, const Rep &n, const unsigned long l) const
Reppow (Rep &r, const Rep &n, const unsigned int l) const
Repratrecon (Rep &r, const Integer &f, const Integer &m, const Integer &k, bool recurs=false) const
Repratrecon (Rep &r, const Integer &f, const Integer &m, bool recurs=true) const
size_t length (const Rep &a) const
int sign (const Rep &a) const
int isOne (const Rep &a) const
int isZero (const Rep &a) const
int areEqual (const Rep &a, const Rep &b) const
int areNEqual (const Rep &a, const Rep &b) const
template<class RandIter >
Reprandom (RandIter &g, Rep &r, long s=1) const
template<class RandIter >
Reprandom (RandIter &g, Rep &r, const Rep &b) const
template<class RandIter >
Repnonzerorandom (RandIter &g, Rep &r, long s=1) const
template<class RandIter >
Repnonzerorandom (RandIter &g, Rep &r, const Rep &b) const
std::istream & read (std::istream &i)
std::ostream & write (std::ostream &o) const
std::istream & read (std::istream &i, Rep &n) const
std::ostream & write (std::ostream &o, const Rep &n) const

Data Fields

const Rational one
const Rational mOne
const Rational zero

Detailed Description

Rational Domain.

Examples:
examples/FiniteField/all_field.C, examples/Polynomial/PolynomialCRT.C, examples/Rational/iratrecon.C, and examples/Rational/polydouble.C.

Member Typedef Documentation

typedef Rational Element
typedef Rational Rep

Constructor & Destructor Documentation

RationalDom ( )
inline
RationalDom ( const X &  x)
inline

Member Function Documentation

int operator== ( const RationalDom ) const
inline
int operator!= ( const RationalDom ) const
inline
unsigned long characteristic ( ) const
inline
Integer& characteristic ( Integer p) const
inline
Rep& init ( Rep a) const
inline
Rep& init ( Rep a,
const Rep b 
) const
inline
Rep& assign ( Rep a,
const Rep b 
) const
inline
Rep& mul ( Rep r,
const Rep a,
const Rep b 
) const
inline
Rep& div ( Rep r,
const Rep a,
const Rep b 
) const
inline
Rep& add ( Rep r,
const Rep a,
const Rep b 
) const
inline
Rep& sub ( Rep r,
const Rep a,
const Rep b 
) const
inline
Rep& mulin ( Rep r,
const Rep a 
) const
inline
Rep& divin ( Rep r,
const Rep a 
) const
inline
Rep& addin ( Rep r,
const Rep a 
) const
inline
Rep& subin ( Rep r,
const Rep a 
) const
inline
Rep& axpy ( Rep r,
const Rep a,
const Rep b,
const Rep c 
) const
inline
Rep& axpyin ( Rep r,
const Rep a,
const Rep b 
) const
inline
Rep& maxpy ( Rep r,
const Rep a,
const Rep b,
const Rep c 
) const
inline
Rep& axmy ( Rep r,
const Rep a,
const Rep b,
const Rep c 
) const
inline
Rep& axmyin ( Rep r,
const Rep a,
const Rep b 
) const
inline
Rep& maxpyin ( Rep r,
const Rep a,
const Rep b 
) const
inline
Rep& neg ( Rep r,
const Rep a 
) const
inline
Rep& inv ( Rep r,
const Rep a 
) const
inline
Rep& negin ( Rep r) const
inline
Rep& invin ( Rep r) const
inline
Rep& pow ( Rep r,
const Rep n,
const unsigned long  l 
) const
inline
Rep& pow ( Rep r,
const Rep n,
const unsigned int  l 
) const
inline
Rep& ratrecon ( Rep r,
const Integer f,
const Integer m,
const Integer k,
bool  recurs = false 
) const
inline
Rep& ratrecon ( Rep r,
const Integer f,
const Integer m,
bool  recurs = true 
) const
inline
size_t length ( const Rep a) const
inline
int sign ( const Rep a) const
inline
int isOne ( const Rep a) const
inline
int isZero ( const Rep a) const
inline
int areEqual ( const Rep a,
const Rep b 
) const
inline
int areNEqual ( const Rep a,
const Rep b 
) const
inline
Rep& random ( RandIter &  g,
Rep r,
long  s = 1 
) const
inline
Rep& random ( RandIter &  g,
Rep r,
const Rep b 
) const
inline
Rep& nonzerorandom ( RandIter &  g,
Rep r,
long  s = 1 
) const
inline
Rep& nonzerorandom ( RandIter &  g,
Rep r,
const Rep b 
) const
inline
std::istream& read ( std::istream &  i)
inline
std::ostream& write ( std::ostream &  o) const
inline
std::istream& read ( std::istream &  i,
Rep n 
) const
inline
std::ostream& write ( std::ostream &  o,
const Rep n 
) const
inline

Field Documentation

const Rational one
const Rational mOne
const Rational zero

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