dune-common  2.4
Classes | Namespaces | Functions | Variables
float_cmp.cc File Reference
#include "float_cmp.hh"
#include <vector>
#include <limits>
#include <algorithm>
#include <cstdlib>
#include <dune/common/fvector.hh>

Classes

struct  Dune::FloatCmp::EpsilonType< T >
 Mapping of value type to epsilon type. More...
 
struct  Dune::FloatCmp::EpsilonType< std::vector< T, A > >
 Specialization of EpsilonType for std::vector. More...
 
struct  Dune::FloatCmp::EpsilonType< FieldVector< T, n > >
 Specialization of EpsilonType for Dune::FieldVector. More...
 
struct  Dune::FloatCmp::DefaultEpsilon< T, relativeWeak >
 
struct  Dune::FloatCmp::DefaultEpsilon< T, relativeStrong >
 
struct  Dune::FloatCmp::DefaultEpsilon< T, absolute >
 
struct  Dune::FloatCmp::Detail::eq_t< T, style >
 
struct  Dune::FloatCmp::Detail::eq_t< T, relativeWeak >
 
struct  Dune::FloatCmp::Detail::eq_t< T, relativeStrong >
 
struct  Dune::FloatCmp::Detail::eq_t< T, absolute >
 
struct  Dune::FloatCmp::Detail::eq_t< std::vector< T >, cstyle >
 
struct  Dune::FloatCmp::Detail::eq_t< Dune::FieldVector< T, n >, cstyle >
 
struct  Dune::FloatCmp::Detail::round_t< I, T, cstyle, rstyle >
 
struct  Dune::FloatCmp::Detail::round_t< I, T, cstyle, downward >
 
struct  Dune::FloatCmp::Detail::round_t< I, T, cstyle, upward >
 
struct  Dune::FloatCmp::Detail::round_t< I, T, cstyle, towardZero >
 
struct  Dune::FloatCmp::Detail::round_t< I, T, cstyle, towardInf >
 
struct  Dune::FloatCmp::Detail::round_t< std::vector< I >, std::vector< T >, cstyle, rstyle >
 
struct  Dune::FloatCmp::Detail::round_t< Dune::FieldVector< I, n >, Dune::FieldVector< T, n >, cstyle, rstyle >
 
struct  Dune::FloatCmp::Detail::trunc_t< I, T, cstyle, rstyle >
 
struct  Dune::FloatCmp::Detail::trunc_t< I, T, cstyle, downward >
 
struct  Dune::FloatCmp::Detail::trunc_t< I, T, cstyle, upward >
 
struct  Dune::FloatCmp::Detail::trunc_t< I, T, cstyle, towardZero >
 
struct  Dune::FloatCmp::Detail::trunc_t< I, T, cstyle, towardInf >
 
struct  Dune::FloatCmp::Detail::trunc_t< std::vector< I >, std::vector< T >, cstyle, rstyle >
 
struct  Dune::FloatCmp::Detail::trunc_t< Dune::FieldVector< I, n >, Dune::FieldVector< T, n >, cstyle, rstyle >
 

Namespaces

 Dune
 Dune namespace.
 
 Dune::FloatCmp
 
 Dune::FloatCmp::Detail
 

Functions

template<class T , CmpStyle style>
bool Dune::FloatCmp::eq (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, style >::value())
 test for equality using epsilon More...
 
template<class T , CmpStyle style>
bool Dune::FloatCmp::ne (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, style >::value())
 test for inequality using epsilon More...
 
template<class T , CmpStyle style>
bool Dune::FloatCmp::gt (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, style >::value())
 test if first greater than second More...
 
template<class T , CmpStyle style>
bool Dune::FloatCmp::lt (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, style >::value())
 test if first lesser than second More...
 
template<class T , CmpStyle style>
bool Dune::FloatCmp::ge (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, style >::value())
 test if first greater or equal second More...
 
template<class T , CmpStyle style>
bool Dune::FloatCmp::le (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, style >::value())
 test if first lesser or equal second More...
 
template<class T >
bool Dune::FloatCmp::eq (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, defaultCmpStyle >::value())
 
template<class T >
bool Dune::FloatCmp::ne (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, defaultCmpStyle >::value())
 
template<class T >
bool Dune::FloatCmp::gt (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, defaultCmpStyle >::value())
 
template<class T >
bool Dune::FloatCmp::lt (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, defaultCmpStyle >::value())
 
template<class T >
bool Dune::FloatCmp::ge (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, defaultCmpStyle >::value())
 
template<class T >
bool Dune::FloatCmp::le (const T &first, const T &second, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, defaultCmpStyle >::value())
 
template<class I , class T , CmpStyle cstyle, RoundingStyle rstyle>
Dune::FloatCmp::round (const T &val, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, cstyle >::value())
 round using epsilon More...
 
template<class I , class T , CmpStyle cstyle>
Dune::FloatCmp::round (const T &val, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, cstyle >::value())
 
template<class I , class T >
Dune::FloatCmp::round (const T &val, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, defaultCmpStyle >::value())
 
template<class I , class T , CmpStyle cstyle, RoundingStyle rstyle>
Dune::FloatCmp::trunc (const T &val, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, cstyle >::value())
 truncate using epsilon More...
 
template<class I , class T , CmpStyle cstyle>
Dune::FloatCmp::trunc (const T &val, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, cstyle >::value())
 
template<class I , class T >
Dune::FloatCmp::trunc (const T &val, typename EpsilonType< T >::Type epsilon=DefaultEpsilon< T, defaultCmpStyle >::value())
 

Variables

struct Dune::FloatCmp::EpsilonType Dune::FloatCmp::nextRow