Mundy: Multibody Nonlocal Dynamics Version of the Day
Loading...
Searching...
No Matches
mundy::NumTraits< AutoDiffScalar< T, N > > Struct Template Reference

Numeric traits for AutoDiffScalar. Numeric values come from the passive type; the related types remain differentiable.

#include <AutoDiffScalar.hpp>

Inheritance diagram for mundy::NumTraits< AutoDiffScalar< T, N > >:
[legend]

Public Types

using Real = AutoDiffScalar<typename NumTraits<T>::Real, N>
using NonInteger = AutoDiffScalar<typename NumTraits<T>::NonInteger, N>
using Literal = typename NumTraits<T>::Literal
using Real
 The real-valued counterpart of T (T itself for real scalars).
using NonInteger
 A type closed under division and roots; integers widen to double, others are unchanged.
using Literal
 The type of a numeric literal paired with a value of type T.

Static Public Member Functions

static constexpr Real epsilon ()
 Machine epsilon: the gap between 1 and the next representable value.
static constexpr Real dummy_precision ()
 Loose tolerance for fuzzy comparisons; 0 for exact types.
static constexpr Real highest ()
 Largest finite representable value.
static constexpr Real lowest ()
 Most negative finite representable value (min() for integers, -max() for floats).
static constexpr Real norm_min ()
 Smallest positive normalized value.
static constexpr Real infinity ()
 Positive infinity (or highest() for types without an infinity).
static constexpr Real quiet_NaN ()
 A quiet NaN.

Static Public Attributes

static constexpr bool IsInteger = false
static constexpr bool IsComplex = false
static constexpr bool RequireInitialization = true
static constexpr bool IsInteger
 Whether T represents integers.
static constexpr bool IsSigned
 Whether T is a signed type.
static constexpr bool IsComplex
 Whether T is complex; always false (complex scalars are not supported).
static constexpr bool RequireInitialization
 Whether T must be constructed before use (true for non-trivial custom scalars).

Member Typedef Documentation

◆ Real [1/2]

template<typename T, size_t N>
using mundy::NumTraits< AutoDiffScalar< T, N > >::Real = AutoDiffScalar<typename NumTraits<T>::Real, N>

◆ NonInteger [1/2]

template<typename T, size_t N>
using mundy::NumTraits< AutoDiffScalar< T, N > >::NonInteger = AutoDiffScalar<typename NumTraits<T>::NonInteger, N>

◆ Literal [1/2]

template<typename T, size_t N>
using mundy::NumTraits< AutoDiffScalar< T, N > >::Literal = typename NumTraits<T>::Literal

◆ Real [2/2]

using mundy::GenericNumTraits< T >::Real

◆ NonInteger [2/2]

using mundy::GenericNumTraits< T >::NonInteger

◆ Literal [2/2]

using mundy::GenericNumTraits< T >::Literal

Member Function Documentation

◆ epsilon()

constexpr Real mundy::GenericNumTraits< T >::epsilon ( )
inlinestaticconstexpr

◆ dummy_precision()

constexpr Real mundy::GenericNumTraits< T >::dummy_precision ( )
inlinestaticconstexpr

◆ highest()

constexpr Real mundy::GenericNumTraits< T >::highest ( )
inlinestaticconstexpr

◆ lowest()

constexpr Real mundy::GenericNumTraits< T >::lowest ( )
inlinestaticconstexpr

◆ norm_min()

constexpr Real mundy::GenericNumTraits< T >::norm_min ( )
inlinestaticconstexpr

◆ infinity()

constexpr Real mundy::GenericNumTraits< T >::infinity ( )
inlinestaticconstexpr

◆ quiet_NaN()

constexpr Real mundy::GenericNumTraits< T >::quiet_NaN ( )
inlinestaticconstexpr

Member Data Documentation

◆ IsInteger [1/2]

template<typename T, size_t N>
bool mundy::NumTraits< AutoDiffScalar< T, N > >::IsInteger = false
staticconstexpr

◆ IsComplex [1/2]

template<typename T, size_t N>
bool mundy::NumTraits< AutoDiffScalar< T, N > >::IsComplex = false
staticconstexpr

◆ RequireInitialization [1/2]

template<typename T, size_t N>
bool mundy::NumTraits< AutoDiffScalar< T, N > >::RequireInitialization = true
staticconstexpr

◆ IsInteger [2/2]

bool mundy::GenericNumTraits< T >::IsInteger
staticconstexpr

◆ IsSigned

bool mundy::GenericNumTraits< T >::IsSigned
staticconstexpr

◆ IsComplex [2/2]

bool mundy::GenericNumTraits< T >::IsComplex
staticconstexpr

◆ RequireInitialization [2/2]

bool mundy::GenericNumTraits< T >::RequireInitialization
staticconstexpr