Arcane  4.1.12.0
User documentation
Loading...
Searching...
No Matches
Arcane::FloatEqualT< T > Class Template Reference

Static Public Member Functions

constexpr __host__ static __device__ bool isNearlyZero (T a)
constexpr __host__ static __device__ bool isNearlyZeroWithEpsilon (T a, T epsilon)
 Compares a to zero within epsilon.
__host__ static __device__ bool isNearlyZero (T a, T b)
 Compares with b*epsilon.
constexpr __host__ static __device__ bool isTrueZero (T a)
constexpr __host__ static __device__ bool isZero (T a)
constexpr __host__ static __device__ bool isNearlyEqual (T a, T b)
constexpr __host__ static __device__ bool isNearlyEqualWithEpsilon (T a, T b, T epsilon)
constexpr __host__ static __device__ bool isEqual (T a, T b)

Detailed Description

template<class T>
class Arcane::FloatEqualT< T >

Definition at line 111 of file Numeric.h.

Member Function Documentation

◆ isEqual()

template<class T>
__host__ static __device__ bool Arcane::FloatEqualT< T >::isEqual ( T a,
T b )
inlinestaticconstexpr

Definition at line 158 of file Numeric.h.

◆ isNearlyEqual()

template<class T>
__host__ static __device__ bool Arcane::FloatEqualT< T >::isNearlyEqual ( T a,
T b )
inlinestaticconstexpr

Definition at line 146 of file Numeric.h.

◆ isNearlyEqualWithEpsilon()

template<class T>
__host__ static __device__ bool Arcane::FloatEqualT< T >::isNearlyEqualWithEpsilon ( T a,
T b,
T epsilon )
inlinestaticconstexpr

Definition at line 152 of file Numeric.h.

◆ isNearlyZero() [1/2]

template<class T>
__host__ static __device__ bool Arcane::FloatEqualT< T >::isNearlyZero ( T a)
inlinestaticconstexpr

Definition at line 119 of file Numeric.h.

◆ isNearlyZero() [2/2]

template<class T>
__host__ static __device__ bool Arcane::FloatEqualT< T >::isNearlyZero ( T a,
T b )
inlinestatic

Compares with b*epsilon.

Warning
b must be positive.

Definition at line 139 of file Numeric.h.

◆ isNearlyZeroWithEpsilon()

template<class T>
__host__ static __device__ bool Arcane::FloatEqualT< T >::isNearlyZeroWithEpsilon ( T a,
T epsilon )
inlinestaticconstexpr

Compares a to zero within epsilon.

epsilon must be positive.

Return values
trueif abs(a)<epilon
falseotherwise

Definition at line 132 of file Numeric.h.

◆ isTrueZero()

template<class T>
__host__ static __device__ bool Arcane::FloatEqualT< T >::isTrueZero ( T a)
inlinestaticconstexpr

Definition at line 144 of file Numeric.h.

◆ isZero()

template<class T>
__host__ static __device__ bool Arcane::FloatEqualT< T >::isZero ( T a)
inlinestaticconstexpr

Definition at line 145 of file Numeric.h.


The documentation for this class was generated from the following file: