SpECTRE  v2024.09.29
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Modules Pages
MathFunction< 1, Fr > Class Template Referenceabstract

#include <MathFunction.hpp>

Public Types

using frame = Fr
 

Public Member Functions

 WRAPPED_PUPable_abstract (MathFunction)
 
virtual std::unique_ptr< MathFunctionget_clone () const =0
 
virtual double operator() (const double &x) const =0
 Returns the function value at the coordinate 'x'. More...
 
virtual DataVector operator() (const DataVector &x) const =0
 
Scalar< double > operator() (const tnsr::I< double, 1, Fr > &x) const
 
Scalar< DataVectoroperator() (const tnsr::I< DataVector, 1, Fr > &x) const
 
virtual double first_deriv (const double &x) const =0
 Returns the first derivative at 'x'. More...
 
virtual DataVector first_deriv (const DataVector &x) const =0
 
tnsr::i< double, 1, Fr > first_deriv (const tnsr::I< double, 1, Fr > &x) const
 
tnsr::i< DataVector, 1, Fr > first_deriv (const tnsr::I< DataVector, 1, Fr > &x) const
 
virtual double second_deriv (const double &x) const =0
 Returns the second derivative at 'x'. More...
 
virtual DataVector second_deriv (const DataVector &x) const =0
 
tnsr::ii< double, 1, Fr > second_deriv (const tnsr::I< double, 1, Fr > &x) const
 
tnsr::ii< DataVector, 1, Fr > second_deriv (const tnsr::I< DataVector, 1, Fr > &x) const
 
virtual double third_deriv (const double &x) const =0
 Returns the third derivative at 'x'. More...
 
virtual DataVector third_deriv (const DataVector &x) const =0
 
tnsr::iii< double, 1, Fr > third_deriv (const tnsr::I< double, 1, Fr > &x) const
 
tnsr::iii< DataVector, 1, Fr > third_deriv (const tnsr::I< DataVector, 1, Fr > &x) const
 
virtual bool operator== (const MathFunction< 1, Fr > &other) const =0
 
virtual bool operator!= (const MathFunction< 1, Fr > &other) const =0
 

Static Public Attributes

static constexpr size_t volume_dim = 1
 

Detailed Description

template<typename Fr>
class MathFunction< 1, Fr >

Partial template specialization of MathFunction which encodes a function RR. In this 1D specialization, the input and output can be Tensors, doubles, or DataVectors.

Member Function Documentation

◆ first_deriv()

template<typename Fr >
virtual double MathFunction< 1, Fr >::first_deriv ( const double &  x) const
pure virtual

Returns the first derivative at 'x'.

Implemented in MathFunctions::Gaussian< 1, Fr >, MathFunctions::PowX< 1, Fr >, and MathFunctions::Sinusoid< 1, Fr >.

◆ operator()()

template<typename Fr >
virtual double MathFunction< 1, Fr >::operator() ( const double &  x) const
pure virtual

Returns the function value at the coordinate 'x'.

Implemented in MathFunctions::Gaussian< 1, Fr >, MathFunctions::PowX< 1, Fr >, and MathFunctions::Sinusoid< 1, Fr >.

◆ second_deriv()

template<typename Fr >
virtual double MathFunction< 1, Fr >::second_deriv ( const double &  x) const
pure virtual

Returns the second derivative at 'x'.

Implemented in MathFunctions::Gaussian< 1, Fr >, MathFunctions::PowX< 1, Fr >, and MathFunctions::Sinusoid< 1, Fr >.

◆ third_deriv()

template<typename Fr >
virtual double MathFunction< 1, Fr >::third_deriv ( const double &  x) const
pure virtual

Returns the third derivative at 'x'.

Implemented in MathFunctions::Gaussian< 1, Fr >, MathFunctions::PowX< 1, Fr >, and MathFunctions::Sinusoid< 1, Fr >.


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