1 #ifndef GAUDIKERNEL_LOMONT_H
2 #define GAUDIKERNEL_LOMONT_H 1
12 #include "GaudiKernel/Kernel.h"
91 const unsigned short maxULPs ) ;
132 const unsigned int maxULPs ) ;
154 class Lomont<float> :
public std::binary_function<float,float,bool>
160 Lomont (
const unsigned short ulps ) : m_ulps ( ulps ) {}
165 inline bool operator () (
const float a ,
const float b )
const
200 class Lomont<double> :
public std::binary_function<double,double,bool>
206 Lomont (
const unsigned int ulps ) : m_ulps ( ulps ) {}
211 inline bool operator () (
const double a ,
const double b )
const
243 float next_float (
const float af ,
const short ulps ) ;
262 double next_double (
const double af ,
const short ulps ) ;
270 #endif // GAUDIKERNEL_LOMONT_H
GAUDI_API double next_double(const double af, const short ulps)
Get the floating number that representation is different with respect to the argument for the certain...
unsigned short m_ulps
the precision in "units in last place"
Lomont(const unsigned int ulps)
constructor from ULPS:
unsigned int m_ulps
the precision in "units in last place"
The equality comparison of double numbers using as the metric the maximal number of Units in the Last...
GAUDI_API float next_float(const float af, const short ulps)
Get the floating number that representation is different with respect to the argument for the certain...
GAUDI_API bool lomont_compare_double(const double af, const double bf, const unsigned int maxULPs)
equality comparison of double numbers using as the metric the maximal number of Units in the Last Pla...
Helper functions to set/get the application return code.
Lomont(const unsigned short ulps)
constructor from ULPS:
GAUDI_API bool lomont_compare_float(const float af, const float bf, const unsigned short maxULPs)
equality comparison of float numbers using as the metric the maximal number of Units in the Last Plac...