FflasFfpack
Public Types | Public Member Functions | Static Public Member Functions | Data Fields | Static Public Attributes | Protected Attributes
ModularBalanced< double > Class Template Reference

it is forbiden to have char 2 More...

#include <modular-balanced-double.h>

Public Types

typedef double Element
typedef unsigned long FieldInt
typedef
ModularBalancedRandIter
< double > 
RandIter
typedef NonzeroRandIter
< ModularBalanced< double >
, RandIter > 
NonZeroRandIter

Public Member Functions

 ModularBalanced (int32_t p, int exp=1)
 ModularBalanced (double p)
 ModularBalanced (unsigned long p)
 ModularBalanced (long p)
 ModularBalanced (const ModularBalanced< double > &mf)
ModularBalanced< Element > & assign (const ModularBalanced< Element > &F)
const ModularBalanced< double > & operator= (const ModularBalanced< double > &F)
FieldInt & cardinality (FieldInt &c) const
FieldInt cardinality () const
unsigned long characteristic () const
FieldInt & characteristic (FieldInt &c) const
unsigned long & convert (unsigned long &x, const Element &y) const
double & convert (double &x, const Element &y) const
float & convert (float &x, const Element &y) const
std::ostream & write (std::ostream &os) const
std::istream & read (std::istream &is)
std::ostream & write (std::ostream &os, const Element &x) const
std::istream & read (std::istream &is, Element &x) const
Element & init (Element &x, const unsigned long &y) const
Element & init (Element &x, const double y) const
Element & init (Element &x) const
template<class T >
Element & init (Element &x, const T y) const
Element & assign (Element &x, const Element &y) const
bool areEqual (const Element &x, const Element &y) const
 Tests equality.
bool isZero (const Element &x) const
bool isOne (const Element &x) const
Element & add (Element &x, const Element &y, const Element &z) const
Element & sub (Element &x, const Element &y, const Element &z) const
Element & mul (Element &x, const Element &y, const Element &z) const
Element & div (Element &x, const Element &y, const Element &z) const
Element & neg (Element &x, const Element &y) const
Element & inv (Element &x, const Element &y) const
Element & axpy (Element &r, const Element &a, const Element &x, const Element &y) const
Element & addin (Element &x, const Element &y) const
Element & subin (Element &x, const Element &y) const
Element & mulin (Element &x, const Element &y) const
Element & divin (Element &x, const Element &y) const
Element & negin (Element &x) const
Element & invin (Element &x) const
Element & axpyin (Element &r, const Element &a, const Element &x) const

Static Public Member Functions

static double getMaxModulus ()

Data Fields

const Element one
const Element zero
const Element mOne

Static Public Attributes

static const bool balanced = true

Protected Attributes

double modulus
double half_mod
double mhalf_mod
unsigned long lmodulus

Detailed Description

template<>
class FFPACK::ModularBalanced< double >

it is forbiden to have char 2


Member Typedef Documentation

typedef double Element
typedef unsigned long FieldInt

Constructor & Destructor Documentation

ModularBalanced ( int32_t  p,
int  exp = 1 
)
inline
ModularBalanced ( double  p)
inline
ModularBalanced ( unsigned long  p)
inline
ModularBalanced ( long  p)
inline
ModularBalanced ( const ModularBalanced< double > &  mf)
inline

Member Function Documentation

ModularBalanced<Element>& assign ( const ModularBalanced< Element > &  F)
inline
const ModularBalanced<double>& operator= ( const ModularBalanced< double > &  F)
inline
FieldInt& cardinality ( FieldInt &  c) const
inline
FieldInt cardinality ( ) const
inline
unsigned long characteristic ( ) const
inline
FieldInt& characteristic ( FieldInt &  c) const
inline
unsigned long& convert ( unsigned long &  x,
const Element &  y 
) const
inline
double& convert ( double &  x,
const Element &  y 
) const
inline
float& convert ( float &  x,
const Element &  y 
) const
inline
std::ostream& write ( std::ostream &  os) const
inline
std::istream& read ( std::istream &  is)
inline
std::ostream& write ( std::ostream &  os,
const Element &  x 
) const
inline
std::istream& read ( std::istream &  is,
Element &  x 
) const
inline
Element& init ( Element &  x,
const unsigned long &  y 
) const
inline
Element& init ( Element &  x,
const double  y 
) const
inline
Element& init ( Element &  x) const
inline
Element& init ( Element &  x,
const T  y 
) const
inline
Element& assign ( Element &  x,
const Element &  y 
) const
inline
bool areEqual ( const Element &  x,
const Element &  y 
) const
inline

Tests equality.

Parameters:
xelement
yelement
Warning:
x and y are supposed to be reduced.
bool isZero ( const Element &  x) const
inline
bool isOne ( const Element &  x) const
inline
Element& add ( Element &  x,
const Element &  y,
const Element &  z 
) const
inline
Element& sub ( Element &  x,
const Element &  y,
const Element &  z 
) const
inline
Element& mul ( Element &  x,
const Element &  y,
const Element &  z 
) const
inline
Element& div ( Element &  x,
const Element &  y,
const Element &  z 
) const
inline
Element& neg ( Element &  x,
const Element &  y 
) const
inline
Element& inv ( Element &  x,
const Element &  y 
) const
inline
Element& axpy ( Element &  r,
const Element &  a,
const Element &  x,
const Element &  y 
) const
inline
Element& addin ( Element &  x,
const Element &  y 
) const
inline
Element& subin ( Element &  x,
const Element &  y 
) const
inline
Element& mulin ( Element &  x,
const Element &  y 
) const
inline
Element& divin ( Element &  x,
const Element &  y 
) const
inline
Element& negin ( Element &  x) const
inline
Element& invin ( Element &  x) const
inline
Element& axpyin ( Element &  r,
const Element &  a,
const Element &  x 
) const
inline
static double getMaxModulus ( )
inlinestatic

Field Documentation

double modulus
protected
double half_mod
protected
double mhalf_mod
protected
unsigned long lmodulus
protected
const Element one
const Element zero
const Element mOne
const bool balanced = true
static

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