Public Member Functions | |
xreal () | |
default | |
xreal (xint_t ii, xfrac_t ff) | |
xreal (int ii) | |
x = int | |
xreal (real x) | |
x = real | |
xint_t | get_i () |
xfrac_t | get_f () |
real | get_frac () |
int | to_int () |
Always round down! | |
real | to_real () |
Convert to real. | |
void | print (ostream &s=cerr, bool newline=false) |
xprint(x) is better | |
operator int () | |
operator real () | |
xreal | operator- () |
xreal | operator+ (const xreal y) |
xreal | operator- (const xreal y) |
xreal & | operator+= (const xreal y) |
xreal & | operator-= (const xreal y) |
xreal | operator+ (const real y) |
xreal | operator- (const real y) |
xreal & | operator+= (const real y) |
xreal & | operator-= (const real y) |
bool | operator== (const xreal y) |
bool | operator!= (const xreal y) |
bool | operator< (const xreal y) |
bool | operator<= (const xreal y) |
bool | operator> (const xreal y) |
bool | operator>= (const xreal y) |
Private Attributes | |
xint_t | i |
x = i + f/TWO64 | |
xfrac_t | f |
x = i + f/TWO64 | |
Friends | |
istream & | operator>> (ostream &, xreal &) |
Definition at line 46 of file xreal.h.