Skip to content

Struct TempLat::ZeroType

ClassList > TempLat > ZeroType

A class which represents zero. Attempt to simplify derivative expressions. More...

  • #include <zerotype.h>

Public Static Attributes

Type Name
constexpr int value = 0

Public Functions

Type Name
operator double () const
operator float () const
constexpr auto operator() (const Tag< N > t) const

Public Static Functions

Type Name
DEVICE_INLINE_FUNCTION constexpr auto eval (const IDX &... i)
std::string toString ()

Detailed Description

Unit test: ctest -R test-zerotype

@vocab-summary Compile-time zero. Multiplying by it collapses a whole expression tree to nothing, and adding it is free — this is how TempLat prunes terms before generating any code.

Public Static Attributes Documentation

variable value

constexpr int TempLat::ZeroType::value;

Public Functions Documentation

function operator double

inline explicit TempLat::ZeroType::operator double () const

function operator float

inline explicit TempLat::ZeroType::operator float () const

function operator()

template<int N>
inline constexpr auto TempLat::ZeroType::operator() (
    const Tag < N > t
) const

Public Static Functions Documentation

function eval

template<typename... IDX>
static inline DEVICE_INLINE_FUNCTION constexpr auto TempLat::ZeroType::eval (
    const IDX &... i
) 

function toString

static inline std::string TempLat::ZeroType::toString () 


The documentation for this class was generated from the following file cosmolatticeweb/tmp/code_source/templat/include/TempLat/lattice/algebra/constants/zerotype.h