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

#include <givrational.h>

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
Integer & characteristic (Integer &p) const
Rep & init (Rep &a) const
Rep & init (Rep &a, const Rep &b) const
Rep & assign (Rep &a, const Rep &b) const
Rep & mul (Rep &r, const Rep &a, const Rep &b) const
Rep & div (Rep &r, const Rep &a, const Rep &b) const
Rep & add (Rep &r, const Rep &a, const Rep &b) const
Rep & sub (Rep &r, const Rep &a, const Rep &b) const
Rep & mulin (Rep &r, const Rep &a) const
Rep & divin (Rep &r, const Rep &a) const
Rep & addin (Rep &r, const Rep &a) const
Rep & subin (Rep &r, const Rep &a) const
Rep & axpy (Rep &r, const Rep &a, const Rep &b, const Rep &c) const
Rep & axpyin (Rep &r, const Rep &a, const Rep &b) const
Rep & maxpy (Rep &r, const Rep &a, const Rep &b, const Rep &c) const
Rep & axmy (Rep &r, const Rep &a, const Rep &b, const Rep &c) const
Rep & axmyin (Rep &r, const Rep &a, const Rep &b) const
Rep & maxpyin (Rep &r, const Rep &a, const Rep &b) const
Rep & neg (Rep &r, const Rep &a) const
Rep & inv (Rep &r, const Rep &a) const
Rep & negin (Rep &r) const
Rep & invin (Rep &r) const
Rep & pow (Rep &r, const Rep &n, const unsigned long l) const
Rep & pow (Rep &r, const Rep &n, const unsigned int l) const
Rep & ratrecon (Rep &r, const Integer &f, const Integer &m, const Integer &k, bool recurs=false) const
Rep & ratrecon (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 >
Rep & random (RandIter &g, Rep &r, long s=1) const
template<class RandIter >
Rep & random (RandIter &g, Rep &r, const Rep &b) const
template<class RandIter >
Rep & nonzerorandom (RandIter &g, Rep &r, long s=1) const
template<class RandIter >
Rep & nonzerorandom (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 zero

Detailed Description

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 zero

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