35 #ifndef _BLAZE_MATH_SHIMS_EQUAL_H_
36 #define _BLAZE_MATH_SHIMS_EQUAL_H_
44 #include <boost/math/special_functions/next.hpp>
76 inline bool equal(
float a,
float b )
79 (
std::fabs( boost::math::float_distance( a, b ) ) <= 6.0F );
103 inline bool equal(
float a,
double b )
105 return equal( a, static_cast<float>( b ) );
129 inline bool equal(
float a,
long double b )
131 return equal( a, static_cast<float>( b ) );
151 inline bool equal(
double a,
float b )
153 return equal( static_cast<float>( a ), b );
177 inline bool equal(
double a,
double b )
180 (
std::fabs( boost::math::float_distance( a, b ) ) <= 4.0 );
204 inline bool equal(
double a,
long double b )
230 inline bool equal(
long double a,
float b )
232 return equal( static_cast<float>( a ), b );
256 inline bool equal(
long double a,
double b )
258 return equal( static_cast<double>( a ), b );
282 inline bool equal(
long double a,
long double b )
285 (
std::fabs( boost::math::float_distance( a, b ) ) <= 4.0L );
304 template<
typename T1
306 inline bool equal( complex<T1> a, T2 b )
327 template<
typename T1
329 inline bool equal( T1 a, complex<T2> b )
350 template<
typename T1
352 inline bool equal( complex<T1> a, complex<T2> b )
354 return equal( a.real(), b.real() ) &&
equal( a.imag(), b.imag() );
374 template<
typename T1
376 inline bool equal(
const T1& a,
const T2& b )
Computation accuracy for floating point data types.
const StaticMatrix< Type, 3UL, 3UL, false > fabs(const RotationMatrix< Type > &m)
Returns a matrix containing the absolute values of each single element of m.
Definition: RotationMatrix.h:1102
bool equal(const T1 &a, const T2 &b)
Generic equality check.
Definition: Equal.h:376
Header file for the isDefault shim.
BLAZE_ALWAYS_INLINE bool isDefault(const NonNumericProxy< MT > &proxy)
Returns whether the represented element is in default state.
Definition: NonNumericProxy.h:874
const Accuracy accuracy
Global Accuracy instance.The blaze::accuracy instance can be used wherever a floating point data type...
Definition: Accuracy.h:901
Header file for the complex data type.