CoDiPack  3.1.3
A Code Differentiation Package
SciComp TU Kaiserslautern
Loading...
Searching...
No Matches
codi::GradientTraits::TraitsImplementation< T_Gradient, typename > Struct Template Reference

Common traits for all types used as gradients. More...

#include <gradientTraits.hpp>

Inheritance diagram for codi::GradientTraits::TraitsImplementation< T_Gradient, typename >:

Public Types

using Gradient = T_Gradient
 See TraitsImplementation.
using Real = Gradient
 The base value used in the gradient entries.

Public Member Functions

inlinestatic Real & at (Gradient &gradient, size_t dim)
 Get the entry at the given index.
inlinestatic Real const & at (Gradient const &gradient, size_t dim)
 Get the entry at the given index.
inlinestatic std::array< AtomicTraits::RemoveAtomic< Real >, dim > toArray (Gradient const &gradient)
 Converts the (possibly multi-component) gradient to an array of Reals.

Static Public Attributes

static size_t constexpr dim = 1
 Number of dimensions this gradient value has.

Detailed Description

template<typename T_Gradient, typename = void>
struct codi::GradientTraits::TraitsImplementation< T_Gradient, typename >

Common traits for all types used as gradients.

Template Parameters
T_GradientThe type of the gradient.

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