Borderbasix

Classes | Macros | Functions
Scl.hpp File Reference
#include <assert.h>
#include <stdio.h>
#include "gmp.h"

Go to the source code of this file.

Classes

struct  Scl< T >
 

Macros

#define NO_NRV   1
 
#define NRVAL(name)
 
#define NRCODE(code)
 
#define NONRCODE(code)   code
 
#define OPCODE(a, b, op)   Scl<T> r(a); return (r op b);
 

Functions

template<class T >
Scl< T > operator+ (const Scl< T > &b, unsigned long ul)
 
template<class T >
Scl< T > operator- (const Scl< T > &b, unsigned long ul)
 
template<class T >
Scl< T > operator* (const Scl< T > &b, int ul)
 
template<class T >
Scl< T > operator* (const Scl< T > &b, unsigned long ul)
 
template<class T >
Scl< T > operator/ (const Scl< T > &b, unsigned long ul)
 
template<class T >
Scl< T > operator% (const Scl< T > &b, unsigned long ul)
 
template<class T >
Scl< T > operator+ (unsigned long ul, const Scl< T > &b)
 
template<class T >
Scl< T > operator* (unsigned long ul, const Scl< T > &b)
 
template<class T >
Scl< T > operator* (int ul, const Scl< T > &b)
 
template<class T >
Scl< T > operator+ (const Scl< T > &b, long sl)
 
template<class T >
Scl< T > operator- (const Scl< T > &b, long sl)
 
template<class T >
Scl< T > operator* (const Scl< T > &b, long sl)
 
template<class T >
Scl< T > operator/ (const Scl< T > &b, long sl)
 
template<class T >
Scl< T > operator% (const Scl< T > &b, long sl)
 
template<class T >
Scl< T > operator+ (long sl, const Scl< T > &b)
 
template<class T >
Scl< T > operator* (long sl, const Scl< T > &b)
 
template<class T >
Scl< T > operator* (const Scl< T > &b, double d)
 
template<class T >
Scl< T > operator+ (const Scl< T > &b, double sl)
 
template<class T >
Scl< T > operator+ (double s, const Scl< T > &b)
 
template<class T >
Scl< T > operator* (double d, const Scl< T > &b)
 
template<class T >
Scl< T > operator/ (double ul, const Scl< T > &b)
 
template<class T >
Scl< T > operator/ (const Scl< T > &b, double ul)
 
template<class T >
Scl< T > operator/ (int ul, const Scl< T > &b)
 
template<class T >
Scl< T > operator/ (const Scl< T > &b, int ul)
 
template<class T >
Scl< T > operator- (double d, const Scl< T > &b)
 
template<class T >
Scl< T > operator- (const Scl< T > &b, double sl)
 
template<class T >
Scl< T > Div2Exp (const Scl< T > &b, unsigned long exponent_of_2)
 
template<class T >
Scl< T > GCD (const Scl< T > &b1, const Scl< T > &b2)
 
template<class T >
Scl< T > gcd (const Scl< T > &b1, const Scl< T > &b2)
 
template<class T >
Scl< T > Mod2Exp (const Scl< T > &b, unsigned long exponent_of_2)
 
template<class T >
Scl< T > Mul2Exp (const Scl< T > &b, unsigned long exponent_of_2)
 
template<class T >
Scl< T > PowMod (const Scl< T > &b, const Scl< T > &exp, const Scl< T > &m)
 
template<class T >
Scl< T > PowMod (const Scl< T > &b, unsigned long exp, const Scl< T > &m)
 
template<class T >
Scl< T > abs (const Scl< T > &b)
 
template<class T >
Scl< T > pow (const Scl< T > &base, int exp)
 
template<class T >
Scl< T > quo (const Scl< T > &dividend, const Scl< T > &divisor)
 
template<class T >
Scl< T > quo (const Scl< T > &dividend, unsigned long divisor)
 
template<class T >
Scl< T > rem (const Scl< T > &dividend, const Scl< T > &divisor)
 
template<class T >
Scl< T > sqrt (const Scl< T > &b)
 
template<class T >
unsigned long rem (const Scl< T > &b, unsigned long divisor)
 
template<class T >
Scl< T > BigIntFactorial (unsigned long n)
 
template<class T >
Scl< T > operator+ (int ul, const Scl< T > &b)
 
template<class T >
Scl< T > operator+ (const Scl< T > &b, int ul)
 
template<class T >
Scl< T > & operator% (const Scl< T > &b, long sl) NRVAL(r(b))
 
template<class T >
Scl< T > & Div2Exp (const Scl< T > &b, unsigned long exponent_of_2) NRVAL(r(b))
 
template<class T >
Scl< T > & GCD (const Scl< T > &b1, const Scl< T > &b2) NRVAL(r(b1))
 
template<class T >
Scl< T > & gcd (const Scl< T > &b1, const Scl< T > &b2) NRVAL(r(b1))
 
template<class T >
Scl< T > & Mod2Exp (const Scl< T > &b, unsigned long exponent_of_2) NRVAL(r(b))
 
template<class T >
Scl< T > & Mul2Exp (const Scl< T > &b, unsigned long exponent_of_2) NRVAL(r(b))
 
template<class T >
Scl< T > & PowMod (const Scl< T > &b, const Scl< T > &exp, const Scl< T > &m) NRVAL(r(b))
 
template<class T >
Scl< T > & PowMod (const Scl< T > &b, unsigned long exp, const Scl< T > &m) NRVAL(r(b))
 
template<class T >
Scl< T > pow (const Scl< T > &base, const Scl< T > &exp)
 
template<class T >
Scl< T > & quo (const Scl< T > &dividend, const Scl< T > &divisor) NRVAL(r(dividend))
 
template<class T >
Scl< T > & quo (const Scl< T > &dividend, unsigned long divisor) NRVAL(r(dividend))
 
template<class T >
Scl< T > & rem (const Scl< T > &dividend, const Scl< T > &divisor) NRVAL(r(dividend))
 
template<class T >
Scl< T > & BigIntFactorial (unsigned long n) NRVAL(r)
 
template<class T >
Scl< T > & BigIntPow (unsigned long base, unsigned long exp) NRVAL(r)
 
template<class T >
Scl< T > Size (const Scl< T > &r)
 
template<class T >
Scl< T > hypot (const Scl< T > &a, const Scl< T > &b)
 

Macro Definition Documentation

#define NO_NRV   1
#define NONRCODE (   code)    code
#define NRCODE (   code)
#define NRVAL (   name)
#define OPCODE (   a,
  b,
  op 
)    Scl<T> r(a); return (r op b);

Function Documentation

template<class T >
Scl<T> abs ( const Scl< T > &  b)
template<class T >
Scl<T> BigIntFactorial ( unsigned long  n)
inline
template<class T >
Scl<T>& BigIntFactorial ( unsigned long  n)
inline
template<class T >
Scl<T>& BigIntPow ( unsigned long  base,
unsigned long  exp 
)
inline
template<class T >
Scl<T> Div2Exp ( const Scl< T > &  b,
unsigned long  exponent_of_2 
)
inline
template<class T >
Scl<T>& Div2Exp ( const Scl< T > &  b,
unsigned long  exponent_of_2 
)
inline
template<class T >
Scl<T> GCD ( const Scl< T > &  b1,
const Scl< T > &  b2 
)
inline
template<class T >
Scl<T> gcd ( const Scl< T > &  b1,
const Scl< T > &  b2 
)
inline
template<class T >
Scl<T>& GCD ( const Scl< T > &  b1,
const Scl< T > &  b2 
)
inline
template<class T >
Scl<T>& gcd ( const Scl< T > &  b1,
const Scl< T > &  b2 
)
inline
template<class T >
Scl<T> hypot ( const Scl< T > &  a,
const Scl< T > &  b 
)
inline
template<class T >
Scl<T> Mod2Exp ( const Scl< T > &  b,
unsigned long  exponent_of_2 
)
inline
template<class T >
Scl<T>& Mod2Exp ( const Scl< T > &  b,
unsigned long  exponent_of_2 
)
inline
template<class T >
Scl<T> Mul2Exp ( const Scl< T > &  b,
unsigned long  exponent_of_2 
)
inline
template<class T >
Scl<T>& Mul2Exp ( const Scl< T > &  b,
unsigned long  exponent_of_2 
)
inline
template<class T >
Scl<T> operator% ( const Scl< T > &  b,
unsigned long  ul 
)
template<class T >
Scl<T> operator% ( const Scl< T > &  b,
long  sl 
)
inline
template<class T >
Scl<T>& operator% ( const Scl< T > &  b,
long  sl 
)
inline
template<class T >
Scl< T > operator* ( const Scl< T > &  b,
int  ul 
)
inline
template<class T >
Scl<T> operator* ( const Scl< T > &  b,
unsigned long  ul 
)
template<class T >
Scl<T> operator* ( unsigned long  ul,
const Scl< T > &  b 
)
template<class T >
Scl< T > operator* ( int  ul,
const Scl< T > &  b 
)
inline
template<class T >
Scl<T> operator* ( const Scl< T > &  b,
long  sl 
)
template<class T >
Scl<T> operator* ( long  sl,
const Scl< T > &  b 
)
template<class T >
Scl< T > operator* ( const Scl< T > &  b,
double  d 
)
inline
template<class T >
Scl< T > operator* ( double  d,
const Scl< T > &  b 
)
inline
template<class T >
Scl<T> operator+ ( const Scl< T > &  b,
unsigned long  ul 
)
template<class T >
Scl<T> operator+ ( unsigned long  ul,
const Scl< T > &  b 
)
template<class T >
Scl<T> operator+ ( const Scl< T > &  b,
long  sl 
)
template<class T >
Scl<T> operator+ ( long  sl,
const Scl< T > &  b 
)
template<class T >
Scl< T > operator+ ( const Scl< T > &  b,
double  sl 
)
inline
template<class T >
Scl< T > operator+ ( double  s,
const Scl< T > &  b 
)
inline
template<class T >
Scl<T> operator+ ( int  ul,
const Scl< T > &  b 
)
inline
template<class T >
Scl<T> operator+ ( const Scl< T > &  b,
int  ul 
)
inline
template<class T >
Scl<T> operator- ( const Scl< T > &  b,
unsigned long  ul 
)
template<class T >
Scl<T> operator- ( const Scl< T > &  b,
long  sl 
)
template<class T >
Scl< T > operator- ( double  d,
const Scl< T > &  b 
)
inline
template<class T >
Scl< T > operator- ( const Scl< T > &  b,
double  sl 
)
inline
template<class T >
Scl<T> operator/ ( const Scl< T > &  b,
unsigned long  ul 
)
template<class T >
Scl<T> operator/ ( const Scl< T > &  b,
long  sl 
)
template<class T >
Scl<T> operator/ ( double  ul,
const Scl< T > &  b 
)
template<class T >
Scl<T> operator/ ( const Scl< T > &  b,
double  ul 
)
template<class T >
Scl< T > operator/ ( int  ul,
const Scl< T > &  b 
)
inline
template<class T >
Scl< T > operator/ ( const Scl< T > &  b,
int  ul 
)
inline
template<class T >
Scl< T > pow ( const Scl< T > &  base,
int  exp 
)
inline
template<class T >
Scl<T> pow ( const Scl< T > &  base,
const Scl< T > &  exp 
)
inline
template<class T >
Scl<T> PowMod ( const Scl< T > &  b,
const Scl< T > &  exp,
const Scl< T > &  m 
)
inline
template<class T >
Scl<T> PowMod ( const Scl< T > &  b,
unsigned long  exp,
const Scl< T > &  m 
)
inline
template<class T >
Scl<T>& PowMod ( const Scl< T > &  b,
const Scl< T > &  exp,
const Scl< T > &  m 
)
inline
template<class T >
Scl<T>& PowMod ( const Scl< T > &  b,
unsigned long  exp,
const Scl< T > &  m 
)
inline
template<class T >
Scl<T> quo ( const Scl< T > &  dividend,
const Scl< T > &  divisor 
)
inline
template<class T >
Scl<T> quo ( const Scl< T > &  dividend,
unsigned long  divisor 
)
inline
template<class T >
Scl<T>& quo ( const Scl< T > &  dividend,
const Scl< T > &  divisor 
)
inline
template<class T >
Scl<T>& quo ( const Scl< T > &  dividend,
unsigned long  divisor 
)
inline
template<class T >
Scl<T> rem ( const Scl< T > &  dividend,
const Scl< T > &  divisor 
)
inline
template<class T >
unsigned long rem ( const Scl< T > &  b,
unsigned long  divisor 
)
template<class T >
Scl<T>& rem ( const Scl< T > &  dividend,
const Scl< T > &  divisor 
)
inline
template<class T >
Scl<T> Size ( const Scl< T > &  r)
template<class T >
Scl<T> sqrt ( const Scl< T > &  b)
Home  |  Download & InstallContributions