OpenWalnut  1.4.0
Functions | Variables
wlimits Namespace Reference

Project wide limits for different quantities. More...

Functions

template<typename T >
bool isNaN (T value)
 Determines if a number is considered as NaN (aka Not a Number) or not.
template<typename T >
bool isInf (T value)
 Determines if a number is considered as infinity or not.

Variables

const double MAX_DOUBLE = std::numeric_limits< double >::max()
 Maximum double value.
const float MAX_FLOAT = std::numeric_limits< float >::max()
 Maximum float value.
const size_t MAX_SIZE_T = std::numeric_limits< size_t >::max()
 Maximum size value.
const int32_t MAX_INT32_T = std::numeric_limits< int32_t >::max()
 Maximum int32_t value.
const double MIN_DOUBLE = std::numeric_limits< double >::min()
 Positive minimum double value.
const double DBL_EPS = std::numeric_limits< double >::epsilon()
 Smallest double such: 1.0 + DBL_EPS == 1.0 is still true.
const float FLT_EPS = std::numeric_limits< float >::epsilon()
 Smallest float such: 1.0 + FLT_EPS == 1.0 is still true.

Detailed Description

Project wide limits for different quantities.


Function Documentation

template<typename T >
bool wlimits::isInf ( value)

Determines if a number is considered as infinity or not.

Notes:
The reason for using here a wrapper to cmath's isinf is that it is only included in C99 which is not part of any existing C++ standard yet.
Parameters:
valueThe value to be checked
Returns:
True if the value is infinity, false otherwise.

Definition at line 87 of file WLimits.h.

Referenced by wtracking::WTrackingUtility::followToNextVoxel().

template<typename T >
bool wlimits::isNaN ( value)

Determines if a number is considered as NaN (aka Not a Number) or not.

Notes:
The reason for using here a wrapper to cmath's isnan is that it is only included in C99 which is not part of any existing C++ standard yet.
Parameters:
valueThe value to be checked
Returns:
True if the value is a NaN, false otherwise.

Definition at line 82 of file WLimits.h.

Referenced by WDataSetTimeSeries::calcDataSetAtTime(), WDataSetTimeSeries::findNearestTimeSlice(), wtracking::WTrackingUtility::followToNextVoxel(), WDataSetTimeSeries::interpolate(), and WDataSetTimeSeries::WDataSetTimeSeries().


Variable Documentation

const double wlimits::DBL_EPS = std::numeric_limits< double >::epsilon()
const float wlimits::FLT_EPS = std::numeric_limits< float >::epsilon()
const double wlimits::MAX_DOUBLE = std::numeric_limits< double >::max()

Maximum double value.

Definition at line 31 of file WLimits.cpp.

const float wlimits::MAX_FLOAT = std::numeric_limits< float >::max()

Maximum float value.

Definition at line 32 of file WLimits.cpp.

const int32_t wlimits::MAX_INT32_T = std::numeric_limits< int32_t >::max()

Maximum int32_t value.

Definition at line 34 of file WLimits.cpp.

const size_t wlimits::MAX_SIZE_T = std::numeric_limits< size_t >::max()

Maximum size value.

Definition at line 33 of file WLimits.cpp.

const double wlimits::MIN_DOUBLE = std::numeric_limits< double >::min()

Positive minimum double value.

Definition at line 35 of file WLimits.cpp.