big_float.hpp File Reference

#include "config.hpp"
#include <iostream>
#include "std_import.hpp"
#include "big_int.hpp"

Go to the source code of this file.

Namespaces

namespace  Arageli

Classes

class  Arageli::big_float

Rounding Modes for big_float

const int Arageli::EXACT = 1
 Rounds to the closest value.
const int Arageli::ROUND = 2
 Uses rules of `'manual'' computations.
const int Arageli::TO_NEAREST = 3
 Rounds towards the nearest number.
const int Arageli::TO_ZERO = 4
 Rounds towards zero.
const int Arageli::TO_P_INF = 5
 Rounds towards +infinity.
const int Arageli::TO_M_INF = 6
 Rounds towards -infinity.
const int Arageli::TO_INF = 7
 Rounds outwards zero.

Special big_float numbers

const int Arageli::NAN = 1
const int Arageli::PINF = 2
const int Arageli::M_INF = 3
const int Arageli::P_ZERO = 4
const int Arageli::M_ZERO = 5

Functions

big_float Arageli::abs (const big_float &x)
template<typename Outiter>
void Arageli::generate_range_helper (big_float &t1, const big_float &t2, Outiter outiter)
big_float & Arageli::operator+= (big_float &b, const big_float &c)
big_float & Arageli::operator-= (big_float &b, const big_float &c)
big_float & Arageli::operator *= (big_float &b, const big_float &c)
big_float & Arageli::operator/= (big_float &b, const big_float &c)

Variables

const int Arageli::PREC_MIN = 2
const unsigned long Arageli::PREC_MAX = _Internal::max_digit
const unsigned long Arageli::D_PREC_MAX = ( long ) (_Internal::max_digit * log ( 2.0l ) / log ( 10.0l ))


Detailed Description

Big Float Numbers implementation.

This module implements a class big_float for representing Big Float Numbers, i.e. unlimited precision real numbers with floating point.

Implementation of a Big Float Number. An instance of the data type big_float is a number of the form s*2^e where s is the significant and e is the exponent. Both are instances of type big_int. There are the special big_float values NaN (not a number), pZero, nZero (+0, -0), pInf, mInf (+infinity, -infinity).

Arithmetic on big_float numbers uses two parameters: precision and rounding mode

Definition in file big_float.hpp.


Generated on Thu Aug 31 17:38:17 2006 for Arageli by  doxygen 1.4.7