Rosetta  3.7
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Classes | Namespaces | Functions
numeric.functions.hh File Reference

Numeric functions. More...

#include <numeric/types.hh>
#include <platform/types.hh>
#include <algorithm>
#include <utility/assert.hh>
#include <cmath>
#include <limits>

Classes

struct  numeric::NearestSelector< R, T, bool >
 Nearest function selector class for R non-integer or T integer. More...
 
struct  numeric::NearestSelector< R, T, true >
 Nearest function selector class for R integer and T non-integer. More...
 
struct  numeric::ModSelector< T, bool >
 Mod function selector class for non-integer types. More...
 
struct  numeric::ModSelector< T, true >
 Mod function selector class for integer types. More...
 
struct  numeric::ModuloSelector< T, bool >
 Modulo function selector class for non-integer types. More...
 
struct  numeric::ModuloSelector< T, true >
 Modulo function selector class for integer types. More...
 
struct  numeric::RemainderSelector< T, bool >
 Remainder function selector class for non-integer types. More...
 
struct  numeric::RemainderSelector< T, true >
 Remainder function selector class for integer types. More...
 
struct  numeric::FastRemainderSelector< T, bool >
 Fast remainder function selector class for non-integer types. More...
 
struct  numeric::FastRemainderSelector< T, true >
 Fast remainder function selector class for integer types. More...
 

Namespaces

 numeric
 Unit headers.
 

Functions

short int numeric::min (short int const a, short int const b)
 min( short int, short int ) More...
 
int numeric::min (int const a, int const b)
 min( int, int ) More...
 
long int numeric::min (long int const a, long int const b)
 min( long int, long int ) More...
 
unsigned short int numeric::min (unsigned short int const a, unsigned short int const b)
 min( unsigned short int, unsigned short int ) More...
 
unsigned int numeric::min (unsigned int const a, unsigned int const b)
 min( unsigned int, unsigned int ) More...
 
unsigned long int numeric::min (unsigned long int const a, unsigned long int const b)
 min( unsigned long int, unsigned long int ) More...
 
float numeric::min (float const a, float const b)
 min( float, float ) More...
 
double numeric::min (double const a, double const b)
 min( double, double ) More...
 
long double numeric::min (long double const a, long double const b)
 min( long double, long double ) More...
 
template<typename T >
T const & numeric::min (T const &a, T const &b, T const &c)
 min( a, b, c ) More...
 
template<typename T >
T const & numeric::min (T const &a, T const &b, T const &c, T const &d)
 min( a, b, c, d ) More...
 
template<typename T >
T const & numeric::min (T const &a, T const &b, T const &c, T const &d, T const &e)
 min( a, b, c, d, e ) More...
 
template<typename T >
T const & numeric::min (T const &a, T const &b, T const &c, T const &d, T const &e, T const &f)
 min( a, b, c, d, e, f ) More...
 
short int numeric::max (short int const a, short int const b)
 max( short int, short int ) More...
 
int numeric::max (int const a, int const b)
 max( int, int ) More...
 
long int numeric::max (long int const a, long int const b)
 max( long int, long int ) More...
 
unsigned short int numeric::max (unsigned short int const a, unsigned short int const b)
 max( unsigned short int, unsigned short int ) More...
 
unsigned int numeric::max (unsigned int const a, unsigned int const b)
 max( unsigned int, unsigned int ) More...
 
unsigned long int numeric::max (unsigned long int const a, unsigned long int const b)
 max( unsigned long int, unsigned long int ) More...
 
float numeric::max (float const a, float const b)
 max( float, float ) More...
 
double numeric::max (double const a, double const b)
 max( double, double ) More...
 
long double numeric::max (long double const a, long double const b)
 max( long double, long double ) More...
 
template<typename T >
T const & numeric::max (T const &a, T const &b, T const &c)
 max( a, b, c ) More...
 
template<typename T >
T const & numeric::max (T const &a, T const &b, T const &c, T const &d)
 max( a, b, c, d ) More...
 
template<typename T >
T const & numeric::max (T const &a, T const &b, T const &c, T const &d, T const &e)
 max( a, b, c, d, e ) More...
 
template<typename T >
T const & numeric::max (T const &a, T const &b, T const &c, T const &d, T const &e, T const &f)
 max( a, b, c, d, e, f ) More...
 
template<typename T >
numeric::square (T const &x)
 square( x ) == x^2 More...
 
template<typename T >
numeric::cube (T const &x)
 cube( x ) == x^3 More...
 
template<typename T >
int numeric::sign (T const &x)
 sign( x ) More...
 
template<typename S , typename T >
numeric::sign_transfered (S const &sigma, T const &x)
 Sign transfered value. More...
 
template<typename T >
numeric::abs_difference (T const &a, T const &b)
 Absolute difference. More...
 
template<typename R , typename T >
numeric::nearest (T const &x)
 nearest< R >( x ): Nearest R More...
 
template<typename T >
std::size_t numeric::nearest_size (T const &x)
 nearest_size( x ): Nearest std::size_t More...
 
template<typename T >
SSize numeric::nearest_ssize (T const &x)
 nearest_ssize( x ): Nearest SSize More...
 
template<typename T >
int numeric::nearest_int (T const &x)
 nearest_int( x ): Nearest int More...
 
template<typename T >
int numeric::nint (T const &x)
 nint( x ): Nearest int More...
 
template<typename T >
numeric::mod (T const &x, T const &y)
 x(mod y) computational modulo returning magnitude < | y | and sign of x More...
 
template<typename T >
numeric::modulo (T const &x, T const &y)
 x(mod y) mathematical modulo returning magnitude < | y | and sign of y More...
 
template<typename T >
numeric::remainder (T const &x, T const &y)
 Remainder of x with respect to division by y that is of smallest magnitude. More...
 
template<typename T >
numeric::fast_remainder (T const &x, T const &y)
 Remainder of x with respect to division by y that is of smallest magnitude. More...
 
template<typename T , typename S >
numeric::remainder_conversion (T const &t, S &s)
 Remainder and result of conversion to a different type. More...
 
template<typename T >
numeric::gcd (T const &m, T const &n)
 Greatest common divisor. More...
 
template<typename T >
bool numeric::eq_tol (T const &x, T const &y, T const &r_tol, T const &a_tol)
 Equal within specified relative and absolute tolerances? More...
 
template<typename T >
bool numeric::lt_tol (T const &x, T const &y, T const &r_tol, T const &a_tol)
 Less than within specified relative and absolute tolerances? More...
 
template<typename T >
bool numeric::le_tol (T const &x, T const &y, T const &r_tol, T const &a_tol)
 Less than or equal within specified relative and absolute tolerances? More...
 
template<typename T >
bool numeric::ge_tol (T const &x, T const &y, T const &r_tol, T const &a_tol)
 Greater than or equal within specified relative and absolute tolerances? More...
 
template<typename T >
bool numeric::gt_tol (T const &x, T const &y, T const &r_tol, T const &a_tol)
 Greater than within specified relative and absolute tolerances? More...
 
bool numeric::is_a_finitenumber (double s, double a, double b)
 

Detailed Description

Numeric functions.

Author
Stuart G. Mentzer (Stuar.nosp@m.t_Me.nosp@m.ntzer.nosp@m.@obj.nosp@m.exx.c.nosp@m.om)