scalar< T > Struct Template Reference

#include <scalar.hpp>

List of all members.

Public Member Functions

Public Attributes


Detailed Description

template<class T>
struct mmx::scalar< T >

The general interface for scalars.

Definition at line 24 of file scalar.hpp.


Constructor & Destructor Documentation

scalar (  )  [inline]

Definition at line 37 of file scalar.hpp.

00037 {this->init();};

scalar ( const scalar< T > &  b  ) 
scalar ( const scalar< R > &  x  )  [inline, explicit]

Definition at line 40 of file scalar.hpp.

00040 { this->init(); let::assign(*this,x); }

scalar ( double  d  )  [inline]

Definition at line 41 of file scalar.hpp.

00041                    {this->init();
00042       let::assign(*this,d);
00043       //data=T(d);
00044   };

scalar ( signed long  sl  ) 
scalar ( unsigned long  ul  ) 
scalar ( int  si  ) 
scalar ( unsigned  x  )  [inline]

Definition at line 48 of file scalar.hpp.

00048 {this->init(); let::assign(*this,x);};

scalar ( const char *  string,
unsigned int  b = 10 
)
scalar ( const scalar< U > &  a,
const scalar< U > &  b,
const scalar< U > &  c 
) [inline]
~scalar (  )  [inline]

Definition at line 55 of file scalar.hpp.

00055 {}

scalar (  )  [inline]

Definition at line 25 of file scalar_extended_integer.hpp.

00025 : data() {}

~scalar (  )  [inline]

Definition at line 28 of file scalar_extended_integer.hpp.

00028 {}

scalar ( int  si  )  [inline]

Definition at line 31 of file scalar_extended_integer.hpp.

00031 : data(scalar<MPZ>(si)) {}

scalar ( unsigned  si  )  [inline]

Definition at line 34 of file scalar_extended_integer.hpp.

00034 : data(scalar<MPZ>(si)) {}

scalar ( const char *  string,
unsigned int  base 
) [inline]

Definition at line 37 of file scalar_extended_integer.hpp.

00037 : data(scalar<MPZ>(string, base)) {}

scalar ( const scalar< U > &  a,
const scalar< U > &  b,
const scalar< U > &  c 
) [inline]

Definition at line 40 of file scalar_extended_integer.hpp.

00040 : data(a, b, c) {}

scalar ( signed long int  sl  )  [inline]

Definition at line 43 of file scalar_extended_integer.hpp.

00043 : data(scalar<MPZ>(sl)) {}

scalar ( unsigned long int  ul  )  [inline]

Definition at line 46 of file scalar_extended_integer.hpp.

00046 : data(scalar<MPZ>(ul)) {}

scalar ( const scalar< EMPZ > &  rhs  )  [inline]

Definition at line 49 of file scalar_extended_integer.hpp.

00049 : data(rhs.rep()) {}

scalar ( double  rhs  )  [inline]

Definition at line 52 of file scalar_extended_integer.hpp.

00052 : data(scalar<MPZ>(rhs)) {}

scalar (  )  [inline]

Definition at line 26 of file scalar_extended_rational.hpp.

00026 : data() {}

~scalar (  )  [inline]

Definition at line 29 of file scalar_extended_rational.hpp.

00029 {}

scalar ( int  si  )  [inline]

Definition at line 32 of file scalar_extended_rational.hpp.

00032 : data(scalar<MPQ>(si)) {}

scalar ( unsigned  si  )  [inline]

Definition at line 35 of file scalar_extended_rational.hpp.

00035 : data(scalar<MPQ>(si)) {}

scalar ( const char *  string,
unsigned int  base 
) [inline]

Definition at line 38 of file scalar_extended_rational.hpp.

00038 : data(scalar<MPQ>(string, base)) {}

scalar ( const scalar< U > &  a,
const scalar< U > &  b,
const scalar< U > &  c 
) [inline]

Definition at line 41 of file scalar_extended_rational.hpp.

00041 : data(a, b, c) {}

scalar ( signed long int  sl  )  [inline]

Definition at line 44 of file scalar_extended_rational.hpp.

00044 : data(scalar<MPQ>(sl)) {}

scalar ( unsigned long int  ul  )  [inline]

Definition at line 47 of file scalar_extended_rational.hpp.

00047 : data(scalar<MPQ>(ul)) {}

scalar ( const scalar< EMPQ > &  rhs  )  [inline]

Definition at line 50 of file scalar_extended_rational.hpp.

00050 : data(rhs.rep()) {}

scalar ( double  rhs  )  [inline]

Definition at line 53 of file scalar_extended_rational.hpp.

00053 : data(scalar<MPQ>(rhs)) {}

scalar (  )  [inline]

Definition at line 27 of file scalar_floating.hpp.

References scalar< T >::rep().

00027                                          {
00028   //  cout<<"default construct "<<endl;
00029 mpf_init(&rep());}

scalar ( const scalar< MPF > &  rhs  )  [inline]

Definition at line 32 of file scalar_floating.hpp.

References scalar< T >::rep().

00033 {
00034   //cout<<"const SCl "<<endl;
00035   mpf_init_set(&rep(),&rhs.rep()); 
00036 }

scalar ( signed long int  sl  )  [inline]

Definition at line 48 of file scalar_floating.hpp.

References scalar< T >::rep().

00048 {mpf_init_set_si(&rep(),sl);}

scalar ( unsigned long int  ul  )  [inline]

Definition at line 51 of file scalar_floating.hpp.

References scalar< T >::rep().

00051 {mpf_init_set_ui(&rep(),ul);}

scalar ( int  si  )  [inline]

Definition at line 54 of file scalar_floating.hpp.

References scalar< T >::rep().

00054                                          {
00055   // cout<<"init set si "<<endl;
00056 mpf_init_set_si(&rep(), si);}

scalar ( const char *  string,
unsigned int  base 
) [inline]

Definition at line 59 of file scalar_floating.hpp.

References scalar< T >::rep().

00060 {
00061   if (mpf_init_set_str(&rep(), string, base))
00062     std::cerr << "scalar<MPF>: The string " << string 
00063               << " is not a valid number in base " << base << std::endl;
00064 }

scalar ( double  d  )  [inline]

Definition at line 66 of file scalar_floating.hpp.

References scalar< T >::rep().

00067 {
00068   //cout<<"je passe dans construct double "<<endl;
00069   mpf_init_set_d(&rep(),d);
00070 }

~scalar (  )  [inline]

Definition at line 72 of file scalar_floating.hpp.

References scalar< T >::rep().

00072 {mpf_clear(&rep());}

~scalar (  )  [inline]

Definition at line 27 of file scalar_integer.hpp.

References scalar< T >::rep().

00028 { 
00029   //COUT <<"Delete mpz"<<endl;
00030   mpz_clear(&rep());
00031 }

scalar (  )  [inline]

Definition at line 40 of file scalar_integer.hpp.

References scalar< T >::rep().

00040                        : data()            
00041 {
00042   mpz_init(&rep());
00043 }

scalar ( signed long int  sl  )  [inline]

Definition at line 46 of file scalar_integer.hpp.

References scalar< T >::rep().

00046 : data()  {mpz_init_set_si(&rep(),sl);}

scalar ( unsigned long int  ul  )  [inline]

Definition at line 49 of file scalar_integer.hpp.

References scalar< T >::rep().

00049 : data() {mpz_init_set_ui(&rep(),ul);}

scalar ( int  si  )  [inline]

Definition at line 52 of file scalar_integer.hpp.

References scalar< T >::rep().

00052 : data()               {mpz_init_set_si(&rep(), si);}

scalar ( const char *  s,
unsigned int  base 
) [inline]

Definition at line 55 of file scalar_integer.hpp.

References scalar< T >::rep().

00055                                                     : data()
00056 {
00057   if (mpz_init_set_str(&rep(), s, base))
00058     std::cerr << "scalar<MPZ>: The string " << s 
00059               << " is not a valid number in base " << base << std::endl;
00060 }

scalar ( const scalar< MPZ > &  rhs  )  [inline]

Definition at line 63 of file scalar_integer.hpp.

References scalar< T >::rep().

00064 {
00065   //COUT <<"Init mpz"<<endl;
00066   //COUNT<MPZ>('c');
00067   mpz_init_set(&rep(), &rhs.rep());      
00068 }

scalar (  )  [inline]

Definition at line 25 of file scalar_rational.hpp.

References scalar< T >::rep().

00025 {mpq_init(&rep());}

~scalar (  )  [inline]

Definition at line 27 of file scalar_rational.hpp.

References scalar< T >::rep().

00027 {mpq_clear(&rep());}

scalar ( int  si  )  [inline]

Definition at line 30 of file scalar_rational.hpp.

References scalar< T >::rep().

00031      {mpq_init(&rep());mpq_set_si(&rep(),si,1);}

scalar ( unsigned  si  )  [inline]

Definition at line 34 of file scalar_rational.hpp.

References scalar< T >::rep().

00035      {mpq_init(&rep());mpq_set_ui(&rep(),si,1);}

scalar ( const char *  string,
unsigned int  base 
) [inline]

Definition at line 38 of file scalar_rational.hpp.

References scalar< T >::rep().

00039 {
00040   MP_INT tmp;
00041   mpz_init_set_str(&tmp, string, base);
00042   mpq_init(&rep());
00043   mpq_set_z(&rep(),&tmp);      
00044 }

scalar ( signed long int  sl  )  [inline]

Definition at line 47 of file scalar_rational.hpp.

References scalar< T >::rep().

00048      {mpq_init(&rep());mpq_set_si(&rep(),sl,1);}

scalar ( unsigned long int  ul  )  [inline]

Definition at line 51 of file scalar_rational.hpp.

References scalar< T >::rep().

00052      {mpq_init(&rep());mpq_set_ui(&rep(),ul,1);}

scalar ( const scalar< MPQ > &  rhs  )  [inline]

Definition at line 55 of file scalar_rational.hpp.

References scalar< T >::rep().

00056 {
00057   mpz_init_set(&rep()._mp_num, &rhs.rep()._mp_num); 
00058   mpz_init_set(&rep()._mp_den, &rhs.rep()._mp_den); 
00059 }

scalar ( double  rhs  )  [inline]

Definition at line 62 of file scalar_rational.hpp.

References scalar< T >::rep().

00063 {
00064   mpq_init(&rep());
00065   mpq_set_d(&rep(), rhs); 
00066 }


Member Function Documentation

void abs (  )  [inline]

Definition at line 502 of file scalar_rational.hpp.

References scalar< T >::rep().

00503 {
00504   if (rep()._mp_num._mp_size < 0) rep()._mp_num._mp_size = - rep()._mp_num._mp_size;
00505 }

void abs (  )  [inline]

Definition at line 501 of file scalar_integer.hpp.

References scalar< T >::rep().

00502 {
00503   if (rep()._mp_size < 0)
00504     rep()._mp_size = - rep()._mp_size;
00505 }

void abs (  )  [inline]

Definition at line 485 of file scalar_floating.hpp.

References scalar< T >::rep().

00486 {
00487   if (mpf_sgn(&rep()) < 0)
00488     mpf_neg(&rep(),&rep());
00489 }

void abs (  )  [inline]

Definition at line 338 of file scalar_extended_rational.hpp.

00339 {
00340     if (*this < 0)
00341         *this = -*this;
00342 }

void abs (  )  [inline]

Definition at line 315 of file scalar_extended_integer.hpp.

00316 {
00317     if (*this < 0)
00318         *this = -*this;
00319 }

void abs (  ) 
void Div2Exp ( unsigned long  exponent_of_2  )  [inline]

Definition at line 464 of file scalar_integer.hpp.

References scalar< T >::rep().

00465 {
00466   mpz_div_2exp(&rep(), &rep(), exponent_of_2);
00467 }

void Div2Exp ( unsigned long  exponent_of_2  )  [inline]

Definition at line 479 of file scalar_floating.hpp.

References scalar< T >::rep().

00480 {
00481   mpf_div_2exp(&rep(), &rep(), exponent_of_2);
00482 }

void Div2Exp ( unsigned long  exponent_of_2  ) 
void factorial ( unsigned long  n  )  [inline]

Definition at line 508 of file scalar_integer.hpp.

References scalar< T >::rep().

00509 {
00510   mpz_fac_ui(&rep(), n);
00511 }

void factorial ( unsigned long  n  ) 
void GCD ( const scalar< MPZ > &  b2  )  [inline]

Definition at line 470 of file scalar_integer.hpp.

References scalar< T >::rep().

00471 {
00472     mpz_gcd (&rep(), &rep(), &b2.rep());
00473 }

void GCD ( const scalar< T > &  b2  ) 
void init (  )  [inline]

Definition at line 22 of file scalar_rational.hpp.

References scalar< T >::rep().

00022 {mpq_init(&rep());}

void init (  )  [inline]

Definition at line 34 of file scalar_integer.hpp.

References scalar< T >::rep().

00035 { 
00036   mpz_init(&rep());
00037 }

void init (  )  [inline]

Definition at line 24 of file scalar_floating.hpp.

References scalar< T >::rep().

00024 {mpf_init(&rep());}

void init (  )  [inline]

Definition at line 23 of file scalar_extended_rational.hpp.

00023 {}

void init (  )  [inline]

Definition at line 22 of file scalar_extended_integer.hpp.

00022 {}

void Mod2Exp ( unsigned long  exponent_of_2  )  [inline]

Definition at line 477 of file scalar_integer.hpp.

References scalar< T >::rep().

00478 {
00479   mpz_mod_2exp(&rep(), &rep(), exponent_of_2);
00480 }

void Mod2Exp ( unsigned long  exponent_of_2  ) 
void Mul2Exp ( unsigned long  exponent_of_2  )  [inline]

Definition at line 483 of file scalar_integer.hpp.

References scalar< T >::rep().

00484 {
00485   mpz_mul_2exp(&rep(), &rep(), exponent_of_2);
00486 }

void Mul2Exp ( unsigned long  exponent_of_2  ) 
scalar< MPQ > & negate (  )  [inline]

Definition at line 508 of file scalar_rational.hpp.

References scalar< T >::rep().

00509 {
00510   rep()._mp_num._mp_size = - rep()._mp_num._mp_size; return *this;
00511 }

scalar< MPZ > & negate (  )  [inline]

Definition at line 514 of file scalar_integer.hpp.

References scalar< T >::rep().

00515 {
00516   rep()._mp_size = - rep()._mp_size; return *this;
00517 }

scalar< MPF > & negate (  )  [inline]

Definition at line 492 of file scalar_floating.hpp.

References scalar< T >::rep().

00493 {
00494   mpf_neg(&rep(),&rep());
00495   //&rep()._mp_size = - &rep()._mp_size; 
00496   return *this;
00497 }

scalar< EMPQ > & negate (  )  [inline]

Definition at line 345 of file scalar_extended_rational.hpp.

00346 {
00347     *this = -*this;
00348     return *this;
00349 }

scalar< EMPZ > & negate (  )  [inline]

Definition at line 322 of file scalar_extended_integer.hpp.

00323 {
00324     *this = -*this;
00325     return *this;
00326 }

scalar<T>& negate (  ) 
bool operator!= ( unsigned long  ul  )  const [inline]

Definition at line 123 of file scalar_rational.hpp.

References scalar< T >::rep().

00124 {
00125   return mpq_cmp_ui(&rep(), ul,1) != 0;
00126 }

bool operator!= ( int  si  )  const [inline]

Definition at line 117 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00117                                            {
00118   assert(si>=0);
00119   return mpq_cmp_ui(&rep(), (long) si,1) != 0;
00120 }

bool operator!= ( long  sl  )  const [inline]

Definition at line 111 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00111                                             {
00112   assert(sl>=0);
00113   return mpq_cmp_ui(&rep(), sl,1) != 0;
00114 }

bool operator!= ( const scalar< MPQ > &  rhs  )  const [inline]

Definition at line 105 of file scalar_rational.hpp.

References scalar< T >::rep().

00106 {
00107   return mpq_cmp(&rep(), &rhs.rep()) != 0;
00108 }

bool operator!= ( unsigned long  ul  )  const [inline]

Definition at line 126 of file scalar_integer.hpp.

References scalar< T >::rep().

00127 {
00128   return mpz_cmp_ui(&rep(), ul) != 0;
00129 }

bool operator!= ( int  si  )  const [inline]

Definition at line 121 of file scalar_integer.hpp.

References scalar< T >::rep().

00121                                            {
00122   return mpz_cmp_si(&rep(), (long) si) != 0;
00123 }

bool operator!= ( long  sl  )  const [inline]

Definition at line 116 of file scalar_integer.hpp.

References scalar< T >::rep().

00116                                             {
00117   return mpz_cmp_si(&rep(), sl) != 0;
00118 }

bool operator!= ( const scalar< MPZ > &  rhs  )  const [inline]

Definition at line 110 of file scalar_integer.hpp.

References scalar< T >::rep().

00111 {
00112   return mpz_cmp(&rep(), &rhs.rep()) != 0;
00113 }

bool operator!= ( unsigned long  ul  )  const [inline]

Definition at line 114 of file scalar_floating.hpp.

References scalar< T >::rep().

00115 {
00116   return mpf_cmp_ui(&rep(), ul) != 0;
00117 }

bool operator!= ( int  si  )  const [inline]

Definition at line 109 of file scalar_floating.hpp.

References scalar< T >::rep().

00109                                            {
00110   return mpf_cmp_si(&rep(), (long) si) != 0;
00111 }

bool operator!= ( long  sl  )  const [inline]

Definition at line 104 of file scalar_floating.hpp.

References scalar< T >::rep().

00104                                             {
00105   return mpf_cmp_si(&rep(), sl) != 0;
00106 }

bool operator!= ( const scalar< MPF > &  rhs  )  const [inline]

Definition at line 98 of file scalar_floating.hpp.

References scalar< T >::rep().

00099 {
00100   return mpf_cmp(&rep(), &rhs.rep()) != 0;
00101 }

bool operator!= ( unsigned long  ul  )  const [inline]

Definition at line 81 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00081 { return rep() != EMPQ(ul); }

bool operator!= ( int  si  )  const [inline]

Definition at line 78 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00078 { return rep() != EMPQ(si); }

bool operator!= ( long  sl  )  const [inline]

Definition at line 75 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00075 { return rep() != EMPQ(sl); }

bool operator!= ( const scalar< EMPQ > &  rhs  )  const [inline]

Definition at line 72 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00072 { return rep() != rhs.rep(); }

bool operator!= ( unsigned long  ul  )  const [inline]

Definition at line 80 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00080 { return rep() != EMPZ(ul); }

bool operator!= ( int  si  )  const [inline]

Definition at line 77 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00077 { return rep() != EMPZ(si); }

bool operator!= ( long  sl  )  const [inline]

Definition at line 74 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00074 { return rep() != EMPZ(sl); }

bool operator!= ( const scalar< EMPZ > &  rhs  )  const [inline]

Definition at line 71 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00071 { return rep() != rhs.rep(); }

bool operator!= ( unsigned long  ul  )  const
bool operator!= ( int  si  )  const
bool operator!= ( long  sl  )  const
bool operator!= ( const scalar< T > &  rhs  )  const
scalar< MPZ > & operator%= ( unsigned long  ul  )  [inline]

Definition at line 369 of file scalar_integer.hpp.

References scalar< T >::rep().

00370 {
00371   mpz_mod_ui(&rep(), &rep(), ul); return *this;
00372 }

scalar< MPZ > & operator%= ( const scalar< MPZ > &  rhs  )  [inline]

Definition at line 363 of file scalar_integer.hpp.

References scalar< T >::rep().

00364 {
00365   mpz_mod(&rep(), &rep(), &rhs.rep()); return *this;
00366 }

scalar<T>& operator%= ( unsigned long  rhs  ) 
scalar<T>& operator%= ( int  rhs  ) 
scalar<T>& operator%= ( unsigned  rhs  ) 
scalar<T>& operator%= ( const scalar< T > &  rhs  ) 
scalar< MPQ > & operator*= ( long  sl  )  [inline]

Definition at line 336 of file scalar_rational.hpp.

References scalar< T >::rep().

00337 {
00338   mpq_mul(&rep(), &rep(), &scalar<MPQ>(sl).rep());
00339   //mpq_canonicalize(&rep());
00340   return *this; 
00341 }

scalar< MPQ > & operator*= ( unsigned long  ul  )  [inline]

Definition at line 330 of file scalar_rational.hpp.

References scalar< T >::rep().

00331 {
00332   mpq_mul(&rep(), &rep(), &scalar<MPQ>(ul).rep()); 
00333   return *this;
00334 }

scalar< MPQ > & operator*= ( int  ul  )  [inline]

Definition at line 324 of file scalar_rational.hpp.

References scalar< T >::rep().

00325 {
00326   mpq_mul(&rep(), &rep(), &scalar<MPQ>(ul).rep()); 
00327   return *this;
00328 }

scalar< MPQ > & operator*= ( const scalar< MPQ > &  rhs  )  [inline]

Definition at line 317 of file scalar_rational.hpp.

References scalar< T >::rep().

00318 {
00319   mpq_mul(&rep(), &rep(), &rhs.rep()); 
00320   return *this;
00321 }

scalar< MPZ > & operator*= ( int  ul  )  [inline]

Definition at line 324 of file scalar_integer.hpp.

References scalar< T >::rep().

00325 {
00326    if (ul >= 0)
00327      mpz_mul_ui(&rep(), &rep(), (unsigned long) ul);
00328    else {
00329      mpz_mul_ui(&rep(), &rep(), (unsigned long) (-ul));
00330      mpz_neg(&rep(), &rep());
00331    }
00332    return *this;
00333 }

scalar< MPZ > & operator*= ( long  sl  )  [inline]

Definition at line 312 of file scalar_integer.hpp.

References scalar< T >::rep().

00313 {
00314   if (sl >= 0)
00315     mpz_mul_ui(&rep(), &rep(), (unsigned long) sl);
00316   else
00317     {
00318       rep()._mp_size = -rep()._mp_size;
00319       mpz_mul_ui(&rep(), &rep(), ((unsigned long) -sl));
00320     }
00321   return *this; 
00322 }

scalar< MPZ > & operator*= ( unsigned long  ul  )  [inline]

Definition at line 307 of file scalar_integer.hpp.

References scalar< T >::rep().

00308 {
00309   mpz_mul_ui(&rep(), &rep(), ul); return *this;
00310 }

scalar< MPZ > & operator*= ( const scalar< MPZ > &  rhs  )  [inline]

Definition at line 302 of file scalar_integer.hpp.

References scalar< T >::rep().

00303 {
00304   mpz_mul(&rep(), &rep(), &rhs.rep()); return *this;
00305 }

scalar< MPF > & operator*= ( int  ul  )  [inline]

Definition at line 323 of file scalar_floating.hpp.

References scalar< T >::rep().

00324 {
00325    if (ul >= 0)
00326      mpf_mul_ui(&rep(), &rep(), (unsigned long) ul);
00327    else {
00328      mpf_mul_ui(&rep(), &rep(), (unsigned long) (-ul));
00329      mpf_neg(&rep(), &rep());
00330    }
00331    return *this;
00332 }

scalar< MPF > & operator*= ( double  d  )  [inline]

Definition at line 317 of file scalar_floating.hpp.

00318 {
00319   return *this*=(scalar<MPF>)d;
00320 }

scalar< MPF > & operator*= ( long  sl  )  [inline]

Definition at line 305 of file scalar_floating.hpp.

References scalar< T >::rep().

00306 {
00307   if (sl >= 0)
00308     mpf_mul_ui(&rep(), &rep(), (unsigned long) sl);
00309   else
00310     {
00311       mpf_neg(&rep(),&rep());
00312       mpf_mul_ui(&rep(), &rep(),(unsigned long)(-sl));
00313     }
00314   return *this; 
00315 }

scalar< MPF > & operator*= ( unsigned long  ul  )  [inline]

Definition at line 300 of file scalar_floating.hpp.

References scalar< T >::rep().

00301 {
00302   mpf_mul_ui(&rep(), &rep(), ul); return *this;
00303 }

scalar< MPF > & operator*= ( const scalar< MPF > &  rhs  )  [inline]

Definition at line 295 of file scalar_floating.hpp.

References scalar< T >::rep().

00296 {
00297   mpf_mul(&rep(), &rep(), &rhs.rep()); return *this;
00298 }

scalar< EMPQ > & operator*= ( int  si  )  [inline]

Definition at line 182 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00182 { rep() *= EMPQ(si); return *this;}

scalar< EMPQ > & operator*= ( long  sl  )  [inline]

Definition at line 179 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00179 { rep() *= EMPQ(sl); return *this;}

scalar< EMPQ > & operator*= ( unsigned long  ul  )  [inline]

Definition at line 176 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00176 { rep() *= EMPQ(ul); return *this;}

scalar< EMPQ > & operator*= ( const scalar< EMPQ > &  rhs  )  [inline]

Definition at line 173 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00173 { rep() *= rhs.rep(); return *this; }

scalar< EMPZ > & operator*= ( int  si  )  [inline]

Definition at line 181 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00181 { rep() *= EMPZ(si); return *this;}

scalar< EMPZ > & operator*= ( long  sl  )  [inline]

Definition at line 178 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00178 { rep() *= EMPZ(sl); return *this;}

scalar< EMPZ > & operator*= ( unsigned long  ul  )  [inline]

Definition at line 175 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00175 { rep() *= EMPZ(ul); return *this;}

scalar< EMPZ > & operator*= ( const scalar< EMPZ > &  rhs  )  [inline]

Definition at line 172 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00172 { rep() *= rhs.rep(); return *this; }

scalar<T>& operator*= ( long  rhs  ) 
scalar<T>& operator*= ( double  rhs  ) 
scalar<T>& operator*= ( unsigned long  rhs  ) 
scalar<T>& operator*= ( int  rhs  ) 
scalar<T>& operator*= ( unsigned  rhs  ) 
scalar<T>& operator*= ( const scalar< T > &  rhs  ) 
void operator++ (  )  [inline]

Definition at line 456 of file scalar_rational.hpp.

References scalar< T >::rep().

00457 {
00458   mpq_add(&rep(), &rep(), &scalar<MPQ>(1).rep());
00459   //mpq_canonicalize(&rep());
00460 }

void operator++ (  )  [inline]

Definition at line 418 of file scalar_integer.hpp.

References scalar< T >::rep().

00419 {
00420   mpz_add_ui(&rep(), &rep(), 1);
00421 }

void operator++ (  )  [inline]

Definition at line 421 of file scalar_floating.hpp.

References scalar< T >::rep().

00422 {
00423   mpf_add_ui(&rep(), &rep(), 1);
00424 }

void operator++ (  )  [inline]

Definition at line 306 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00307 {
00308     ++rep().a;
00309 }

void operator++ (  )  [inline]

Definition at line 278 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00279 {
00280     ++rep().a;
00281 }

void operator++ (  ) 
scalar< MPQ > & operator+= ( int  ul  )  [inline]

Definition at line 275 of file scalar_rational.hpp.

00276 {
00277   scalar<MPQ> tmp(ul);
00278   *this += tmp;  
00279   //mpq_canonicalize(&rep());
00280   return *this;
00281 }

scalar< MPQ > & operator+= ( long  sl  )  [inline]

Definition at line 267 of file scalar_rational.hpp.

References scalar< T >::rep().

00268 {
00269   mpq_add(&rep(), &rep(), &scalar<MPQ>(sl).rep());
00270   //mpq_canonicalize(&rep());
00271   return *this;
00272 }

scalar< MPQ > & operator+= ( unsigned long  ul  )  [inline]

Definition at line 259 of file scalar_rational.hpp.

References scalar< T >::rep().

00260 {
00261   mpq_add(&rep(), &rep(), &scalar<MPQ>(ul).rep());
00262   //  mpq_canonicalize(&rep());
00263   return *this;
00264 }

scalar< MPQ > & operator+= ( const scalar< MPQ > &  rhs  )  [inline]

Definition at line 249 of file scalar_rational.hpp.

References scalar< T >::rep().

00250 {
00251   scalar<MPQ> tmp;
00252   mpq_add(&tmp.rep(), &rep(), &rhs.rep());  
00253   mpq_swap(&tmp.rep(),&rep());
00254   //  mpq_canonicalize(&rep());
00255   return *this;
00256 }

scalar< MPZ > & operator+= ( int  ul  )  [inline]

Definition at line 267 of file scalar_integer.hpp.

00268 {
00269   *this += scalar<MPZ>(ul);  return *this;
00270 }

scalar< MPZ > & operator+= ( long  sl  )  [inline]

Definition at line 257 of file scalar_integer.hpp.

References scalar< T >::rep().

00258 {
00259   if (sl >= 0)
00260     mpz_add_ui(&rep(), &rep(), (unsigned long) sl);
00261   else
00262     mpz_sub_ui(&rep(), &rep(), ((unsigned long) -sl));
00263   return *this;
00264 }

scalar< MPZ > & operator+= ( unsigned long  ul  )  [inline]

Definition at line 251 of file scalar_integer.hpp.

References scalar< T >::rep().

00252 {
00253   mpz_add_ui(&rep(), &rep(), ul); return *this;
00254 }

scalar< MPZ > & operator+= ( const scalar< MPZ > &  rhs  )  [inline]

Definition at line 245 of file scalar_integer.hpp.

References scalar< T >::rep().

00246 {
00247   mpz_add(&rep(), &rep(), &rhs.rep());  return *this;
00248 }

scalar< MPF > & operator+= ( int  ul  )  [inline]

Definition at line 260 of file scalar_floating.hpp.

00261 {
00262   *this += scalar<MPF>(ul);  return *this;
00263 }

scalar< MPF > & operator+= ( long  sl  )  [inline]

Definition at line 250 of file scalar_floating.hpp.

References scalar< T >::rep().

00251 {
00252   if (sl >= 0)
00253     mpf_add_ui(&rep(), &rep(), (unsigned long) sl);
00254   else
00255     mpf_sub_ui(&rep(), &rep(), ((unsigned long) -sl));
00256   return *this;
00257 }

scalar< MPF > & operator+= ( unsigned long  ul  )  [inline]

Definition at line 244 of file scalar_floating.hpp.

References scalar< T >::rep().

00245 {
00246   mpf_add_ui(&rep(), &rep(), ul); return *this;
00247 }

scalar< MPF > & operator+= ( const scalar< MPF > &  rhs  )  [inline]

Definition at line 233 of file scalar_floating.hpp.

References scalar< T >::rep().

00234 {
00235   scalar<MPF> tmp;
00236   //mpf_init(tmp.&rep());
00237   mpf_add(&tmp.rep(), &rep(), &rhs.rep());  
00238   mpf_swap(&tmp.rep(),&rep());
00239   return *this;
00240 
00241 }

scalar< EMPQ > & operator+= ( int  si  )  [inline]

Definition at line 156 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00156 { rep() += EMPQ(si); return *this;}

scalar< EMPQ > & operator+= ( long  sl  )  [inline]

Definition at line 153 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00153 { rep() += EMPQ(sl); return *this;}

scalar< EMPQ > & operator+= ( unsigned long  ul  )  [inline]

Definition at line 150 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00150 { rep() += EMPQ(ul); return *this;}

scalar< EMPQ > & operator+= ( const scalar< EMPQ > &  rhs  )  [inline]

Definition at line 147 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00147 { rep() += rhs.rep(); return *this; }

scalar< EMPZ > & operator+= ( int  si  )  [inline]

Definition at line 155 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00155 { rep() += EMPZ(si); return *this;}

scalar< EMPZ > & operator+= ( long  sl  )  [inline]

Definition at line 152 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00152 { rep() += EMPZ(sl); return *this;}

scalar< EMPZ > & operator+= ( unsigned long  ul  )  [inline]

Definition at line 149 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00149 { rep() += EMPZ(ul); return *this;}

scalar< EMPZ > & operator+= ( const scalar< EMPZ > &  rhs  )  [inline]

Definition at line 146 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00146 { rep() += rhs.rep(); return *this; }

scalar<T>& operator+= ( long  rhs  ) 
scalar<T>& operator+= ( double  rhs  ) 
scalar<T>& operator+= ( unsigned long  rhs  ) 
scalar<T>& operator+= ( int  rhs  ) 
scalar<T>& operator+= ( unsigned  rhs  ) 
scalar<T>& operator+= ( const scalar< T > &  rhs  ) 
void operator-- (  )  [inline]

Definition at line 464 of file scalar_rational.hpp.

References scalar< T >::rep().

00465 {
00466   mpq_sub(&rep(), &rep(), &scalar<MPQ>(1).rep());
00467   //mpq_canonicalize(&rep());
00468 }

void operator-- (  )  [inline]

Definition at line 425 of file scalar_integer.hpp.

References scalar< T >::rep().

00426 {
00427   mpz_sub_ui(&rep(), &rep(), 1);
00428 }

void operator-- (  )  [inline]

Definition at line 428 of file scalar_floating.hpp.

References scalar< T >::rep().

00429 {
00430   mpf_sub_ui(&rep(), &rep(), 1);
00431 }

void operator-- (  )  [inline]

Definition at line 313 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00314 {
00315     --rep().a;
00316 }

void operator-- (  )  [inline]

Definition at line 285 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00286 {
00287     --rep().a;
00288 }

void operator-- (  ) 
scalar< MPQ > & operator-= ( int  ul  )  [inline]

Definition at line 309 of file scalar_rational.hpp.

00310 {
00311   *this -= scalar<MPQ>(ul); 
00312   //mpq_canonicalize(&rep());
00313   return *this;
00314 }

scalar< MPQ > & operator-= ( long  sl  )  [inline]

Definition at line 301 of file scalar_rational.hpp.

References scalar< T >::rep().

00302 {
00303   mpq_sub(&rep(), &rep(), &scalar<MPQ>(sl).rep());
00304   //mpq_canonicalize(&rep());
00305   return *this;
00306 }

scalar< MPQ > & operator-= ( unsigned long  ul  )  [inline]

Definition at line 293 of file scalar_rational.hpp.

References scalar< T >::rep().

00294 {
00295   mpq_sub(&rep(), &rep(), &scalar<MPQ>(ul).rep()); 
00296   //mpq_canonicalize(&rep());
00297   return *this;
00298 }

scalar< MPQ > & operator-= ( const scalar< MPQ > &  rhs  )  [inline]

Definition at line 285 of file scalar_rational.hpp.

References scalar< T >::rep().

00286 {
00287   mpq_sub(&rep(), &rep(), &rhs.rep()); 
00288   //mpq_canonicalize(&rep());
00289   return *this;
00290 }

scalar< MPZ > & operator-= ( int  ul  )  [inline]

Definition at line 296 of file scalar_integer.hpp.

00297 {
00298   *this -= scalar<MPZ>(ul); return *this;
00299 }

scalar< MPZ > & operator-= ( long  sl  )  [inline]

Definition at line 286 of file scalar_integer.hpp.

References scalar< T >::rep().

00287 {
00288   if (sl >= 0)
00289     mpz_sub_ui(&rep(), &rep(), (unsigned long) sl);
00290   else
00291     mpz_add_ui(&rep(), &rep(), (unsigned long) sl);
00292   return *this;
00293 }

scalar< MPZ > & operator-= ( unsigned long  ul  )  [inline]

Definition at line 280 of file scalar_integer.hpp.

References scalar< T >::rep().

00281 {
00282   mpz_sub_ui(&rep(), &rep(), ul); return *this;
00283 }

scalar< MPZ > & operator-= ( const scalar< MPZ > &  rhs  )  [inline]

Definition at line 274 of file scalar_integer.hpp.

References scalar< T >::rep().

00275 {
00276   mpz_sub(&rep(), &rep(), &rhs.rep()); return *this;
00277 }

scalar< MPF > & operator-= ( int  ul  )  [inline]

Definition at line 289 of file scalar_floating.hpp.

00290 {
00291   *this -= scalar<MPF>(ul); return *this;
00292 }

scalar< MPF > & operator-= ( long  sl  )  [inline]

Definition at line 279 of file scalar_floating.hpp.

References scalar< T >::rep().

00280 {
00281   if (sl >= 0)
00282     mpf_sub_ui(&rep(), &rep(), (unsigned long) sl);
00283   else
00284     mpf_add_ui(&rep(), &rep(), (unsigned long) sl);
00285   return *this;
00286 }

scalar< MPF > & operator-= ( unsigned long  ul  )  [inline]

Definition at line 273 of file scalar_floating.hpp.

References scalar< T >::rep().

00274 {
00275   mpf_sub_ui(&rep(), &rep(), ul); return *this;
00276 }

scalar< MPF > & operator-= ( const scalar< MPF > &  rhs  )  [inline]

Definition at line 267 of file scalar_floating.hpp.

References scalar< T >::rep().

00268 {
00269   mpf_sub(&rep(), &rep(), &rhs.rep()); return *this;
00270 }

scalar< EMPQ > & operator-= ( int  si  )  [inline]

Definition at line 169 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00169 { rep() -= EMPQ(si); return *this;}

scalar< EMPQ > & operator-= ( long  sl  )  [inline]

Definition at line 166 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00166 { rep() -= EMPQ(sl); return *this;}

scalar< EMPQ > & operator-= ( unsigned long  ul  )  [inline]

Definition at line 163 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00163 { rep() -= EMPQ(ul); return *this;}

scalar< EMPQ > & operator-= ( const scalar< EMPQ > &  rhs  )  [inline]

Definition at line 160 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00160 { rep() -= rhs.rep(); return *this; }

scalar< EMPZ > & operator-= ( int  si  )  [inline]

Definition at line 168 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00168 { rep() -= EMPZ(si); return *this;}

scalar< EMPZ > & operator-= ( long  sl  )  [inline]

Definition at line 165 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00165 { rep() -= EMPZ(sl); return *this;}

scalar< EMPZ > & operator-= ( unsigned long  ul  )  [inline]

Definition at line 162 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00162 { rep() -= EMPZ(ul); return *this;}

scalar< EMPZ > & operator-= ( const scalar< EMPZ > &  rhs  )  [inline]

Definition at line 159 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00159 { rep() -= rhs.rep(); return *this; }

scalar<T>& operator-= ( long  rhs  ) 
scalar<T>& operator-= ( unsigned long  rhs  ) 
scalar<T>& operator-= ( int  rhs  ) 
scalar<T>& operator-= ( unsigned  rhs  ) 
scalar<T>& operator-= ( const scalar< T > &  rhs  ) 
scalar< MPQ > & operator/= ( long int  sl  )  [inline]

Definition at line 373 of file scalar_rational.hpp.

References scalar< T >::rep().

00374 {
00375   
00376   mpq_div(&rep(), &rep(),  &scalar<MPQ>(sl).rep());
00377   //mpq_canonicalize(&rep());
00378   return *this;
00379 }

scalar< MPQ > & operator/= ( unsigned long  ul  )  [inline]

Definition at line 366 of file scalar_rational.hpp.

References scalar< T >::rep().

00367 {
00368   mpq_div(&rep(), &rep(), &scalar<MPQ>(ul).rep()); 
00369   return *this;
00370 }

scalar< MPQ > & operator/= ( int  sl  )  [inline]

Definition at line 359 of file scalar_rational.hpp.

References scalar< T >::rep().

00360 {
00361   mpq_div(&rep(), &rep(),  &scalar<MPQ>(sl).rep());
00362   return *this;
00363 }

scalar< MPQ > & operator/= ( unsigned  sl  )  [inline]

Definition at line 352 of file scalar_rational.hpp.

References scalar< T >::rep().

00353 {
00354   mpq_div(&rep(), &rep(),  &scalar<MPQ>(sl).rep());
00355   return *this;
00356 }

scalar< MPQ > & operator/= ( const scalar< MPQ > &  rhs  )  [inline]

Definition at line 345 of file scalar_rational.hpp.

References scalar< T >::rep().

00346 {
00347   mpq_div(&rep(), &rep(), &rhs.rep());
00348   return *this;
00349 }

scalar< MPZ > & operator/= ( long  sl  )  [inline]

Definition at line 349 of file scalar_integer.hpp.

References scalar< T >::rep().

00350 {
00351   if (sl >= 0)
00352     mpz_div_ui(&rep(), &rep(), (unsigned long) sl);
00353   else
00354     {
00355       rep()._mp_size = -rep()._mp_size;
00356       mpz_div_ui(&rep(), &rep(), ((unsigned long) -sl));
00357     }
00358   return *this;
00359 }

scalar< MPZ > & operator/= ( unsigned long  ul  )  [inline]

Definition at line 343 of file scalar_integer.hpp.

References scalar< T >::rep().

00344 {
00345   mpz_div_ui(&rep(), &rep(), ul); return *this;
00346 }

scalar< MPZ > & operator/= ( const scalar< MPZ > &  rhs  )  [inline]

Definition at line 336 of file scalar_integer.hpp.

References scalar< T >::rep().

00337 {
00338   mpz_div(&rep(), &rep(), &rhs.rep());
00339   //mpz_divexact(&rep(), &rep(), &rhs.rep()); 
00340   return *this;
00341 }

scalar< MPF > & operator/= ( int  sl  )  [inline]

Definition at line 360 of file scalar_floating.hpp.

References scalar< T >::rep().

00361 {
00362   if (sl >= 0)
00363     mpf_div_ui(&rep(), &rep(), (unsigned long) sl);
00364   else
00365     {
00366       mpf_neg(&rep(),&rep());
00367       mpf_div_ui(&rep(), &rep(), ((unsigned long) -sl));
00368     }
00369   return *this;
00370 }

scalar< MPF > & operator/= ( long  sl  )  [inline]

Definition at line 348 of file scalar_floating.hpp.

References scalar< T >::rep().

00349 {
00350   if (sl >= 0)
00351     mpf_div_ui(&rep(), &rep(), (unsigned long) sl);
00352   else
00353     {
00354       mpf_neg(&rep(),&rep());
00355       mpf_div_ui(&rep(), &rep(), ((unsigned long) -sl));
00356     }
00357   return *this;
00358 }

scalar< MPF > & operator/= ( unsigned long  ul  )  [inline]

Definition at line 342 of file scalar_floating.hpp.

References scalar< T >::rep().

00343 {
00344   mpf_div_ui(&rep(), &rep(), ul); return *this;
00345 }

scalar< MPF > & operator/= ( const scalar< MPF > &  rhs  )  [inline]

Definition at line 335 of file scalar_floating.hpp.

References scalar< T >::rep().

00336 {
00337   mpf_div(&rep(), &rep(), &rhs.rep());
00338   //mpf_divexact(&rep(), &rep(), &rhs.rep()); 
00339   return *this;
00340 }

scalar< EMPQ > & operator/= ( int  si  )  [inline]

Definition at line 195 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00195 { rep() /= EMPQ(si); return *this;}

scalar< EMPQ > & operator/= ( long  sl  )  [inline]

Definition at line 192 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00192 { rep() /= EMPQ(sl); return *this;}

scalar< EMPQ > & operator/= ( unsigned long  ul  )  [inline]

Definition at line 189 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00189 { rep() /= EMPQ(ul); return *this;}

scalar< EMPQ > & operator/= ( const scalar< EMPQ > &  rhs  )  [inline]

Definition at line 186 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00186 { rep() /= rhs.rep(); return *this; }

scalar< EMPZ > & operator/= ( int  si  )  [inline]

Definition at line 194 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00194 { rep() /= EMPZ(si); return *this;}

scalar< EMPZ > & operator/= ( long  sl  )  [inline]

Definition at line 191 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00191 { rep() /= EMPZ(sl); return *this;}

scalar< EMPZ > & operator/= ( unsigned long  ul  )  [inline]

Definition at line 188 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00188 { rep() /= EMPZ(ul); return *this;}

scalar< EMPZ > & operator/= ( const scalar< EMPZ > &  rhs  )  [inline]

Definition at line 185 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00185 { rep() /= rhs.rep(); return *this; }

scalar<T>& operator/= ( long  rhs  ) 
scalar<T>& operator/= ( unsigned long  rhs  ) 
scalar<T>& operator/= ( int  rhs  ) 
scalar<T>& operator/= ( unsigned  rhs  ) 
scalar<T>& operator/= ( const scalar< T > &  rhs  ) 
bool operator< ( unsigned long  ul  )  const [inline]

Definition at line 197 of file scalar_rational.hpp.

References scalar< T >::rep().

00198 {
00199   return mpq_cmp_ui(&rep(), ul, 1) < 0;
00200 }

bool operator< ( int  si  )  const [inline]

Definition at line 190 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00191 {
00192   assert(si>=0);
00193   return mpq_cmp_ui(&rep(), (long) si, 1) < 0;
00194 }

bool operator< ( long  sl  )  const [inline]

Definition at line 185 of file scalar_rational.hpp.

References scalar< T >::rep().

00185                                            {
00186   return mpq_cmp_ui(&rep(), sl, 1) < 0;
00187 }

bool operator< ( const scalar< MPQ > &  rhs  )  const [inline]

Definition at line 179 of file scalar_rational.hpp.

References scalar< T >::rep().

00180 {
00181   return mpq_cmp(&rep(), &rhs.rep()) < 0;
00182 }

bool operator< ( unsigned long  ul  )  const [inline]

Definition at line 195 of file scalar_integer.hpp.

References scalar< T >::rep().

00196 {
00197   return mpz_cmp_ui(&rep(), ul) < 0;
00198 }

bool operator< ( int  si  )  const [inline]

Definition at line 189 of file scalar_integer.hpp.

References scalar< T >::rep().

00190 {
00191   return mpz_cmp_si(&rep(), (long) si) < 0;
00192 }

bool operator< ( long  sl  )  const [inline]

Definition at line 184 of file scalar_integer.hpp.

References scalar< T >::rep().

00184                                            {
00185   return mpz_cmp_si(&rep(), sl) < 0;
00186 }

bool operator< ( const scalar< MPZ > &  rhs  )  const [inline]

Definition at line 178 of file scalar_integer.hpp.

References scalar< T >::rep().

00179 {
00180   return mpz_cmp(&rep(), &rhs.rep()) < 0;
00181 }

bool operator< ( unsigned long  ul  )  const [inline]

Definition at line 183 of file scalar_floating.hpp.

References scalar< T >::rep().

00184 {
00185   return mpf_cmp_ui(&rep(), ul) < 0;
00186 }

bool operator< ( int  si  )  const [inline]

Definition at line 177 of file scalar_floating.hpp.

References scalar< T >::rep().

00178 {
00179   return mpf_cmp_si(&rep(), (long) si) < 0;
00180 }

bool operator< ( long  sl  )  const [inline]

Definition at line 172 of file scalar_floating.hpp.

References scalar< T >::rep().

00172                                            {
00173   return mpf_cmp_si(&rep(), sl) < 0;
00174 }

bool operator< ( const scalar< MPF > &  rhs  )  const [inline]

Definition at line 166 of file scalar_floating.hpp.

References scalar< T >::rep().

00167 {
00168   return mpf_cmp(&rep(), &rhs.rep()) < 0;
00169 }

bool operator< ( unsigned long  ul  )  const [inline]

Definition at line 120 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00120 { return rep() < EMPQ(ul); }

bool operator< ( int  si  )  const [inline]

Definition at line 117 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00117 { return rep() < EMPQ(si); }

bool operator< ( long  sl  )  const [inline]

Definition at line 114 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00114 { return rep() < EMPQ(sl); }

bool operator< ( const scalar< EMPQ > &  rhs  )  const [inline]

Definition at line 111 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00111 { return rep() < rhs.rep(); }

bool operator< ( unsigned long  ul  )  const [inline]

Definition at line 119 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00119 { return rep() < EMPZ(ul); }

bool operator< ( int  si  )  const [inline]

Definition at line 116 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00116 { return rep() < EMPZ(si); }

bool operator< ( long  sl  )  const [inline]

Definition at line 113 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00113 { return rep() < EMPZ(sl); }

bool operator< ( const scalar< EMPZ > &  rhs  )  const [inline]

Definition at line 110 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00110 { return rep() < rhs.rep(); }

bool operator< ( unsigned long  ul  )  const
bool operator< ( int  si  )  const
bool operator< ( long  sl  )  const
bool operator< ( const scalar< T > &  rhs  )  const
bool operator<= ( unsigned long  ul  )  const [inline]

Definition at line 224 of file scalar_rational.hpp.

References scalar< T >::rep().

00225 {
00226   return mpq_cmp_ui(&rep(), ul, 1) <= 0;
00227 }

bool operator<= ( int  si  )  const [inline]

Definition at line 217 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00218 {
00219   assert(si>=0);
00220   return mpq_cmp_ui(&rep(), (long) si, 1) <= 0;
00221 }

bool operator<= ( long  sl  )  const [inline]

Definition at line 211 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00211                                             {
00212   assert(sl>=0);
00213   return mpq_cmp_ui(&rep(), sl,1) <= 0;
00214 }

bool operator<= ( const scalar< MPQ > &  rhs  )  const [inline]

Definition at line 205 of file scalar_rational.hpp.

References scalar< T >::rep().

00206 {
00207   return mpq_cmp(&rep(), &rhs.rep()) <= 0;
00208 }

bool operator<= ( unsigned long  ul  )  const [inline]

Definition at line 220 of file scalar_integer.hpp.

References scalar< T >::rep().

00221 {
00222   return mpz_cmp_ui(&rep(), ul) <= 0;
00223 }

bool operator<= ( int  si  )  const [inline]

Definition at line 214 of file scalar_integer.hpp.

References scalar< T >::rep().

00215 {
00216   return mpz_cmp_si(&rep(), (long) si) <= 0;
00217 }

bool operator<= ( long  sl  )  const [inline]

Definition at line 209 of file scalar_integer.hpp.

References scalar< T >::rep().

00209                                             {
00210   return mpz_cmp_si(&rep(), sl) <= 0;
00211 }

bool operator<= ( const scalar< MPZ > &  rhs  )  const [inline]

Definition at line 203 of file scalar_integer.hpp.

References scalar< T >::rep().

00204 {
00205   return mpz_cmp(&rep(), &rhs.rep()) <= 0;
00206 }

bool operator<= ( unsigned long  ul  )  const [inline]

Definition at line 208 of file scalar_floating.hpp.

References scalar< T >::rep().

00209 {
00210   return mpf_cmp_ui(&rep(), ul) <= 0;
00211 }

bool operator<= ( int  si  )  const [inline]

Definition at line 202 of file scalar_floating.hpp.

References scalar< T >::rep().

00203 {
00204   return mpf_cmp_si(&rep(), (long) si) <= 0;
00205 }

bool operator<= ( long  sl  )  const [inline]

Definition at line 197 of file scalar_floating.hpp.

References scalar< T >::rep().

00197                                             {
00198   return mpf_cmp_si(&rep(), sl) <= 0;
00199 }

bool operator<= ( const scalar< MPF > &  rhs  )  const [inline]

Definition at line 191 of file scalar_floating.hpp.

References scalar< T >::rep().

00192 {
00193   return mpf_cmp(&rep(), &rhs.rep()) <= 0;
00194 }

bool operator<= ( unsigned long  ul  )  const [inline]

Definition at line 133 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00133 { return rep() <= EMPQ(ul); }

bool operator<= ( int  si  )  const [inline]

Definition at line 130 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00130 { return rep() <= EMPQ(si); }

bool operator<= ( long  sl  )  const [inline]

Definition at line 127 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00127 { return rep() <= EMPQ(sl); }

bool operator<= ( const scalar< EMPQ > &  rhs  )  const [inline]

Definition at line 124 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00124 { return rep() <= rhs.rep(); }

bool operator<= ( unsigned long  ul  )  const [inline]

Definition at line 132 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00132 { return rep() <= EMPZ(ul); }

bool operator<= ( int  si  )  const [inline]

Definition at line 129 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00129 { return rep() <= EMPZ(si); }

bool operator<= ( long  sl  )  const [inline]

Definition at line 126 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00126 { return rep() <= EMPZ(sl); }

bool operator<= ( const scalar< EMPZ > &  rhs  )  const [inline]

Definition at line 123 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00123 { return rep() <= rhs.rep(); }

bool operator<= ( unsigned long  ul  )  const
bool operator<= ( int  si  )  const
bool operator<= ( long  sl  )  const
bool operator<= ( const scalar< T > &  rhs  )  const
scalar< MPQ > & operator= ( int  ul  )  [inline]

Definition at line 243 of file scalar_rational.hpp.

References scalar< T >::rep().

00244 {
00245   mpq_set_si(&rep(), ul, 1);  return *this;
00246 }

scalar< MPQ > & operator= ( long  sl  )  [inline]

Definition at line 237 of file scalar_rational.hpp.

References scalar< T >::rep().

00238 {
00239   mpq_set_si(&rep(), sl, 1);  return *this;
00240 }

scalar< MPQ > & operator= ( unsigned long  ul  )  [inline]

Definition at line 231 of file scalar_rational.hpp.

References scalar< T >::rep().

00232 {
00233   mpq_set_ui(&rep(), ul, 1); return *this;
00234 }

scalar< MPQ > & operator= ( const scalar< MPQ > &  rhs  )  [inline]

Definition at line 69 of file scalar_rational.hpp.

References scalar< T >::rep().

00070 {
00071   // COUNT<MPQ>('=');
00072   //if (this != &rhs) 
00073   //mpq_clear(&rep());
00074   //mpq_init(&rep());
00075   mpq_set(&rep(), &rhs.rep()); 
00076   return *this;
00077 }

scalar< MPZ > & operator= ( int  ul  )  [inline]

Definition at line 239 of file scalar_integer.hpp.

References scalar< T >::rep().

00240 {
00241   mpz_init_set_si(&(this->rep()), ul);  return *this;
00242 }

scalar< MPZ > & operator= ( long  sl  )  [inline]

Definition at line 233 of file scalar_integer.hpp.

References scalar< T >::rep().

00234 {
00235   mpz_set_si(&rep(), sl);  return *this;
00236 }

scalar< MPZ > & operator= ( unsigned long  ul  )  [inline]

Definition at line 227 of file scalar_integer.hpp.

References scalar< T >::rep().

00228 {
00229   mpz_set_ui(&rep(), ul); return *this;
00230 }

scalar< MPZ > & operator= ( unsigned  rhs  )  [inline]

Definition at line 79 of file scalar_integer.hpp.

References scalar< T >::rep().

00080 {
00081   //COUNT<MPZ>('=');
00082   mpz_set_ui(&rep(), rhs); 
00083   return *this;
00084 }

scalar< MPZ > & operator= ( const scalar< MPZ > &  rhs  )  [inline]

Definition at line 72 of file scalar_integer.hpp.

References scalar< T >::rep().

00073 {
00074   //COUNT<MPZ>('=');
00075   if (this != &rhs) mpz_set(&rep(), &rhs.rep()); 
00076   return *this;
00077 }

scalar< MPF > & operator= ( int  ul  )  [inline]

Definition at line 227 of file scalar_floating.hpp.

References scalar< T >::rep().

00228 {
00229   mpf_set_si(&rep(), ul);  return *this;
00230 }

scalar< MPF > & operator= ( long  sl  )  [inline]

Definition at line 221 of file scalar_floating.hpp.

References scalar< T >::rep().

00222 {
00223   mpf_set_si(&rep(), sl);  return *this;
00224 }

scalar< MPF > & operator= ( unsigned long  ul  )  [inline]

Definition at line 215 of file scalar_floating.hpp.

References scalar< T >::rep().

00216 {
00217   mpf_set_ui(&rep(), ul); return *this;
00218 }

scalar< MPF > & operator= ( const scalar< MPF > &  rhs  )  [inline]

Definition at line 39 of file scalar_floating.hpp.

References scalar< T >::rep().

00040 {
00041   if (this != &rhs) {
00042     mpf_set(&rep(), &rhs.rep());
00043   }
00044   return *this;
00045 }

scalar< EMPQ > & operator= ( int  si  )  [inline]

Definition at line 143 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00143 { rep() = EMPQ(si); return *this;}

scalar< EMPQ > & operator= ( long  sl  )  [inline]

Definition at line 140 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00140 { rep() = EMPQ(sl); return *this;}

scalar< EMPQ > & operator= ( unsigned long  ul  )  [inline]

Definition at line 137 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00137 { rep() = EMPQ(ul); return *this;}

scalar< EMPQ > & operator= ( const scalar< EMPQ > &  rhs  )  [inline]

Definition at line 56 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00056 { rep() = rhs.rep(); return *this; }

scalar< EMPZ > & operator= ( int  si  )  [inline]

Definition at line 142 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00142 { rep() = EMPZ(si); return *this;}

scalar< EMPZ > & operator= ( long  sl  )  [inline]

Definition at line 139 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00139 { rep() = EMPZ(sl); return *this;}

scalar< EMPZ > & operator= ( unsigned long  ul  )  [inline]

Definition at line 136 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00136 { rep() = EMPZ(ul); return *this;}

scalar< EMPZ > & operator= ( const scalar< EMPZ > &  rhs  )  [inline]

Definition at line 55 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00055 { rep() = rhs.rep(); return *this; }

scalar<T>& operator= ( long  rhs  ) 
scalar<T>& operator= ( unsigned long  rhs  ) 
scalar<T>& operator= ( int  rhs  ) 
scalar<T>& operator= ( unsigned  rhs  ) 
scalar<T>& operator= ( const scalar< T > &  rhs  ) 
bool operator== ( unsigned long  ul  )  const [inline]

Definition at line 98 of file scalar_rational.hpp.

References scalar< T >::rep().

00099 {
00100   return mpq_cmp_ui(&rep(), ul, 1) == 0;
00101 }

bool operator== ( int  si  )  const [inline]

Definition at line 93 of file scalar_rational.hpp.

References scalar< T >::rep().

00093                                            {
00094   return mpq_cmp_ui(&rep(), (long) si, 1) == 0;
00095 }

bool operator== ( long  sl  )  const [inline]

Definition at line 86 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00086                                             {
00087   assert(sl>0);
00088   return mpq_cmp_ui(&rep(), sl, 1) == 0;
00089   
00090 }

bool operator== ( const scalar< MPQ > &  rhs  )  const [inline]

Definition at line 80 of file scalar_rational.hpp.

References scalar< T >::rep().

00081 {
00082   return mpq_cmp(&rep(), &rhs.rep()) == 0;
00083 }

bool operator== ( unsigned long  ul  )  const [inline]

Definition at line 103 of file scalar_integer.hpp.

References scalar< T >::rep().

00104 {
00105   return mpz_cmp_ui(&rep(), ul) == 0;
00106 }

bool operator== ( int  si  )  const [inline]

Definition at line 98 of file scalar_integer.hpp.

References scalar< T >::rep().

00098                                            {
00099   return mpz_cmp_si(&rep(), (long) si) == 0;
00100 }

bool operator== ( long  sl  )  const [inline]

Definition at line 93 of file scalar_integer.hpp.

References scalar< T >::rep().

00093                                             {
00094   return mpz_cmp_si(&rep(), sl) == 0;
00095 }

bool operator== ( const scalar< MPZ > &  rhs  )  const [inline]

Definition at line 87 of file scalar_integer.hpp.

References scalar< T >::rep().

00088 {
00089   return mpz_cmp(&rep(), &rhs.rep()) == 0;
00090 }

bool operator== ( unsigned long  ul  )  const [inline]

Definition at line 91 of file scalar_floating.hpp.

References scalar< T >::rep().

00092 {
00093   return mpf_cmp_ui(&rep(), ul) == 0;
00094 }

bool operator== ( int  si  )  const [inline]

Definition at line 86 of file scalar_floating.hpp.

References scalar< T >::rep().

00086                                            {
00087   return mpf_cmp_si(&rep(), (long) si) == 0;
00088 }

bool operator== ( long  sl  )  const [inline]

Definition at line 81 of file scalar_floating.hpp.

References scalar< T >::rep().

00081                                             {
00082   return mpf_cmp_si(&rep(), sl) == 0;
00083 }

bool operator== ( const scalar< MPF > &  rhs  )  const [inline]

Definition at line 75 of file scalar_floating.hpp.

References scalar< T >::rep().

00076 {
00077   return mpf_cmp(&rep(), &rhs.rep()) == 0;
00078 }

bool operator== ( unsigned long  ul  )  const [inline]

Definition at line 68 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00068 { return rep() == EMPQ(ul); }

bool operator== ( int  si  )  const [inline]

Definition at line 65 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00065 { return rep() == EMPQ(si); }

bool operator== ( long  sl  )  const [inline]

Definition at line 62 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00062 { return rep() == EMPQ(sl); }

bool operator== ( const scalar< EMPQ > &  rhs  )  const [inline]

Definition at line 59 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00059 { return rep() == rhs.rep(); }

bool operator== ( unsigned long  ul  )  const [inline]

Definition at line 67 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00067 { return rep() == EMPZ(ul); }

bool operator== ( int  si  )  const [inline]

Definition at line 64 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00064 { return rep() == EMPZ(si); }

bool operator== ( long  sl  )  const [inline]

Definition at line 61 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00061 { return rep() == EMPZ(sl); }

bool operator== ( const scalar< EMPZ > &  rhs  )  const [inline]

Definition at line 58 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00058 { return rep() == rhs.rep(); }

bool operator== ( unsigned long  ul  )  const
bool operator== ( int  si  )  const
bool operator== ( long  sl  )  const
bool operator== ( const scalar< T > &  rhs  )  const
bool operator> ( unsigned long  ul  )  const [inline]

Definition at line 147 of file scalar_rational.hpp.

References scalar< T >::rep().

00148 {
00149   return mpq_cmp_ui(&rep(), ul,1) > 0;
00150 }

bool operator> ( int  si  )  const [inline]

Definition at line 141 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00141                                           {
00142   assert(si>=0);
00143   return mpq_cmp_ui(&rep(), (long) si, 1) > 0;
00144 }

bool operator> ( long  sl  )  const [inline]

Definition at line 135 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00135                                            {
00136   assert(sl>=0);
00137   return mpq_cmp_ui(&rep(), sl, 1) > 0;
00138 }

bool operator> ( const scalar< MPQ > &  rhs  )  const [inline]

Definition at line 129 of file scalar_rational.hpp.

References scalar< T >::rep().

00130 {
00131   return mpq_cmp(&rep(), &rhs.rep()) > 0;
00132 }

bool operator> ( unsigned long  ul  )  const [inline]

Definition at line 148 of file scalar_integer.hpp.

References scalar< T >::rep().

00149 {
00150   return mpz_cmp_ui(&rep(), ul) > 0;
00151 }

bool operator> ( int  si  )  const [inline]

Definition at line 143 of file scalar_integer.hpp.

References scalar< T >::rep().

00143                                           {
00144   return mpz_cmp_si(&rep(), (long) si) > 0;
00145 }

bool operator> ( long  sl  )  const [inline]

Definition at line 138 of file scalar_integer.hpp.

References scalar< T >::rep().

00138                                            {
00139   return mpz_cmp_si(&rep(), sl) > 0;
00140 }

bool operator> ( const scalar< MPZ > &  rhs  )  const [inline]

Definition at line 132 of file scalar_integer.hpp.

References scalar< T >::rep().

00133 {
00134   return mpz_cmp(&rep(), &rhs.rep()) > 0;
00135 }

bool operator> ( unsigned long  ul  )  const [inline]

Definition at line 136 of file scalar_floating.hpp.

References scalar< T >::rep().

00137 {
00138   return mpf_cmp_ui(&rep(), ul) > 0;
00139 }

bool operator> ( int  si  )  const [inline]

Definition at line 131 of file scalar_floating.hpp.

References scalar< T >::rep().

00131                                           {
00132   return mpf_cmp_si(&rep(), (long) si) > 0;
00133 }

bool operator> ( long  sl  )  const [inline]

Definition at line 126 of file scalar_floating.hpp.

References scalar< T >::rep().

00126                                            {
00127   return mpf_cmp_si(&rep(), sl) > 0;
00128 }

bool operator> ( const scalar< MPF > &  rhs  )  const [inline]

Definition at line 120 of file scalar_floating.hpp.

References scalar< T >::rep().

00121 {
00122   return mpf_cmp(&rep(), &rhs.rep()) > 0;
00123 }

bool operator> ( unsigned long  ul  )  const [inline]

Definition at line 94 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00094 { return rep() > EMPQ(ul); }

bool operator> ( int  si  )  const [inline]

Definition at line 91 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00091 { return rep() > EMPQ(si); }

bool operator> ( long  sl  )  const [inline]

Definition at line 88 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00088 { return rep() > EMPQ(sl); }

bool operator> ( const scalar< EMPQ > &  rhs  )  const [inline]

Definition at line 85 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00085 { return rep() > rhs.rep(); }

bool operator> ( unsigned long  ul  )  const [inline]

Definition at line 93 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00093 { return rep() > EMPZ(ul); }

bool operator> ( int  si  )  const [inline]

Definition at line 90 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00090 { return rep() > EMPZ(si); }

bool operator> ( long  sl  )  const [inline]

Definition at line 87 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00087 { return rep() > EMPZ(sl); }

bool operator> ( const scalar< EMPZ > &  rhs  )  const [inline]

Definition at line 84 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00084 { return rep() > rhs.rep(); }

bool operator> ( unsigned long  ul  )  const
bool operator> ( int  si  )  const
bool operator> ( long  sl  )  const
bool operator> ( const scalar< T > &  rhs  )  const
bool operator>= ( unsigned long  ul  )  const [inline]

Definition at line 172 of file scalar_rational.hpp.

References scalar< T >::rep().

00173 {
00174   return mpq_cmp_ui(&rep(), ul, 1) >= 0;
00175 }

bool operator>= ( int  si  )  const [inline]

Definition at line 165 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00166 {
00167   assert(si>=0);
00168   return mpq_cmp_ui(&rep(), (long) si, 1) >= 0;
00169 }

bool operator>= ( long  sl  )  const [inline]

Definition at line 159 of file scalar_rational.hpp.

References assert, and scalar< T >::rep().

00159                                             {
00160   assert(sl>=0);
00161   return mpq_cmp_ui(&rep(), sl, 1) >= 0;
00162 }

bool operator>= ( const scalar< MPQ > &  rhs  )  const [inline]

Definition at line 153 of file scalar_rational.hpp.

References scalar< T >::rep().

00154 {
00155   return mpq_cmp(&rep(), &rhs.rep()) >= 0;
00156 }

bool operator>= ( unsigned long  ul  )  const [inline]

Definition at line 171 of file scalar_integer.hpp.

References scalar< T >::rep().

00172 {
00173   return mpz_cmp_ui(&rep(), ul) >= 0;
00174 }

bool operator>= ( int  si  )  const [inline]

Definition at line 165 of file scalar_integer.hpp.

References scalar< T >::rep().

00166 {
00167   return mpz_cmp_si(&rep(), (long) si) >= 0;
00168 }

bool operator>= ( long  sl  )  const [inline]

Definition at line 160 of file scalar_integer.hpp.

References scalar< T >::rep().

00160                                             {
00161   return mpz_cmp_si(&rep(), sl) >= 0;
00162 }

bool operator>= ( const scalar< MPZ > &  rhs  )  const [inline]

Definition at line 154 of file scalar_integer.hpp.

References scalar< T >::rep().

00155 {
00156   return mpz_cmp(&rep(), &rhs.rep()) >= 0;
00157 }

bool operator>= ( unsigned long  ul  )  const [inline]

Definition at line 159 of file scalar_floating.hpp.

References scalar< T >::rep().

00160 {
00161   return mpf_cmp_ui(&rep(), ul) >= 0;
00162 }

bool operator>= ( int  si  )  const [inline]

Definition at line 153 of file scalar_floating.hpp.

References scalar< T >::rep().

00154 {
00155   return mpf_cmp_si(&rep(), (long) si) >= 0;
00156 }

bool operator>= ( long  sl  )  const [inline]

Definition at line 148 of file scalar_floating.hpp.

References scalar< T >::rep().

00148                                             {
00149   return mpf_cmp_si(&rep(), sl) >= 0;
00150 }

bool operator>= ( const scalar< MPF > &  rhs  )  const [inline]

Definition at line 142 of file scalar_floating.hpp.

References scalar< T >::rep().

00143 {
00144   return mpf_cmp(&rep(), &rhs.rep()) >= 0;
00145 }

bool operator>= ( unsigned long  ul  )  const [inline]

Definition at line 107 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00107 { return rep() >= EMPQ(ul); }

bool operator>= ( int  si  )  const [inline]

Definition at line 104 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00104 { return rep() >= EMPQ(si); }

bool operator>= ( long  sl  )  const [inline]

Definition at line 101 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00101 { return rep() >= EMPQ(sl); }

bool operator>= ( const scalar< EMPQ > &  rhs  )  const [inline]

Definition at line 98 of file scalar_extended_rational.hpp.

References scalar< T >::rep().

00098 { return rep() >= rhs.rep(); }

bool operator>= ( unsigned long  ul  )  const [inline]

Definition at line 106 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00106 { return rep() >= EMPZ(ul); }

bool operator>= ( int  si  )  const [inline]

Definition at line 103 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00103 { return rep() >= EMPZ(si); }

bool operator>= ( long  sl  )  const [inline]

Definition at line 100 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00100 { return rep() >= EMPZ(sl); }

bool operator>= ( const scalar< EMPZ > &  rhs  )  const [inline]

Definition at line 97 of file scalar_extended_integer.hpp.

References scalar< T >::rep().

00097 { return rep() >= rhs.rep(); }

bool operator>= ( unsigned long  ul  )  const
bool operator>= ( int  si  )  const
bool operator>= ( long  sl  )  const
bool operator>= ( const scalar< T > &  rhs  )  const
scalar< MPZ > & pow ( unsigned long  base,
unsigned long  exp 
) [inline]

Definition at line 529 of file scalar_integer.hpp.

References scalar< T >::rep().

00530 {
00531   mpz_ui_pow_ui(&rep(), base, exp); return *this;
00532 }

scalar< MPZ > & pow ( unsigned long  exp  )  [inline]

Definition at line 523 of file scalar_integer.hpp.

References scalar< T >::rep().

00524 {
00525   mpz_pow_ui(&rep(), &rep(), exp); return *this;
00526 }

scalar<T>& pow ( unsigned long  base,
unsigned long  exp 
)
scalar<T>& pow ( unsigned long  exp  ) 
void PowMod ( unsigned long  exp,
const scalar< MPZ > &  m 
) [inline]

Definition at line 495 of file scalar_integer.hpp.

References scalar< T >::rep().

00496 {
00497   mpz_powm_ui(&rep(), &rep(), exp, &m.rep());
00498 }

void PowMod ( const scalar< MPZ > &  exp,
const scalar< MPZ > &  m 
) [inline]

Definition at line 489 of file scalar_integer.hpp.

References scalar< T >::rep().

00490 {
00491   mpz_powm(&rep(), &rep(), &exp.rep(), &m.rep());
00492 }

void PowMod ( unsigned long  exp,
const scalar< T > &  m 
)
void PowMod ( const scalar< T > &  exp,
const scalar< T > &  m 
)
void quo ( unsigned long  divisor  )  [inline]

Definition at line 541 of file scalar_integer.hpp.

References scalar< T >::rep().

00542 {
00543   mpz_mdiv_ui(&rep(), &rep(), divisor);
00544 }

void quo ( const scalar< MPZ > &  divisor  )  [inline]

Definition at line 535 of file scalar_integer.hpp.

References scalar< T >::rep().

00536 {
00537   mpz_mdiv (&rep(), &rep(), &divisor.rep());
00538 }

void quo ( unsigned long  divisor  ) 
void quo ( const scalar< T > &  divisor  ) 
unsigned long rem ( unsigned long  divisor  )  [inline]

Definition at line 553 of file scalar_integer.hpp.

References scalar< T >::rep().

00554 {
00555   return mpz_mmod_ui(&rep(), &rep(), divisor);
00556 }

void rem ( const scalar< MPZ > &  divisor  )  [inline]

Definition at line 547 of file scalar_integer.hpp.

References scalar< T >::rep().

00548 {
00549   mpz_mmod(&rep(), &rep(), &divisor.rep());
00550 }

unsigned long rem ( unsigned long  divisor  ) 
void rem ( const scalar< T > &  divisor  ) 

Referenced by mmx::rem().

const T& rep (  )  const [inline]

Definition at line 31 of file scalar.hpp.

00031 {return (*data);}

T& rep (  )  [inline]

Definition at line 30 of file scalar.hpp.

Referenced by scalar< T >::abs(), mmx::as_charp(), mmx::as_double(), mmx::assign(), mmx::BigIntToSL(), mmx::BigIntToUL(), mmx::bit_precision(), mmx::bit_size(), mmx::compare(), mmx::convert(), as_helper< double, scalar< MPZ > >::cv(), as_helper< double, RR >::cv(), as_helper< RR, double >::cv(), as_helper< ZZ, double >::cv(), as_helper< ZZ, unsigned >::cv(), as_helper< RR, QQ >::cv(), as_helper< QQ, RR >::cv(), as_helper< QQ, ZZ >::cv(), mmx::denominator(), scalar< T >::Div2Exp(), mmx::DivMod(), mmx::ExtGCD(), scalar< T >::factorial(), mmx::gcd(), scalar< T >::GCD(), mmx::HalfExtGCD(), scalar< T >::init(), mmx::IsEven(), mmx::IsMinusOne(), mmx::IsNegative(), mmx::IsOdd(), mmx::IsOne(), mmx::IsPerfectSquare(), mmx::IsPositive(), mmx::IsProbablyPrime(), mmx::IsZero(), mmx::log(), scalar< T >::Mod2Exp(), scalar< T >::Mul2Exp(), scalar< T >::negate(), mmx::numerator(), scalar< T >::operator!=(), scalar< T >::operator%=(), mmx::operator*(), scalar< T >::operator*=(), mmx::operator+(), scalar< T >::operator++(), scalar< T >::operator+=(), mmx::operator-(), scalar< T >::operator--(), scalar< T >::operator-=(), mmx::operator/(), scalar< T >::operator/=(), scalar< T >::operator<(), mmx::operator<<(), mmx::operator<<=(), scalar< T >::operator<=(), scalar< T >::operator=(), scalar< T >::operator==(), scalar< T >::operator>(), scalar< T >::operator>=(), mmx::operator>>(), mmx::pow(), scalar< T >::pow(), scalar< T >::PowMod(), mmx::Precision(), mmx::print(), scalar< T >::quo(), mmx::QuoRem(), scalar< T >::rem(), scalar< T >::scalar(), mmx::sign(), scalar< T >::sqrt(), mmx::SqrtRem(), mmx::to_double(), and scalar< T >::~scalar().

00030 {return (*data);}

void sqrt (  )  [inline]

Definition at line 559 of file scalar_integer.hpp.

References scalar< T >::rep().

00560 {
00561   mpz_sqrt(&rep(), &rep());
00562 }

void sqrt (  )  [inline]

Definition at line 500 of file scalar_floating.hpp.

References scalar< T >::rep().

00501 {
00502   mpf_sqrt(&rep(), &rep());
00503 }

void sqrt (  ) 

Member Data Documentation

Definition at line 29 of file scalar.hpp.

Referenced by scalar< NT >::rep().


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

Generated on 6 Dec 2012 for realroot by  doxygen 1.6.1