Celeritas
0.5.0-86+4a8eea4
|
Functor for floating point equality. More...
#include <SoftEqual.hh>
Public Types | |
Type aliases | |
using | argument_type = RealType |
using | value_type = RealType |
Public Member Functions | |
CELER_CONSTEXPR_FUNCTION | SoftZero () |
Construct with default relative/absolute precision. | |
CELER_FUNCTION | SoftZero (value_type abs) |
Construct with specified precision. More... | |
CELER_FUNCTION bool | operator() (value_type actual) const |
See if the value is within absolute tolerance of zero. More... | |
CELER_CONSTEXPR_FUNCTION value_type | abs () const |
Absolute tolerance. | |
Functor for floating point equality.
|
explicit |
Construct with specified precision.
abs | threshold for absolute error (default 1.0e-14 for doubles) |
|
inline |
See if the value is within absolute tolerance of zero.
actual | scalar floating point value |