|
| AnalyticalDerivativeAD (unsigned targetDIM, ARGS &&... args) |
|
| AnalyticalDerivativeAD (const F &f) |
|
bool | operator() (T output[], const S input[]) override |
| Computes the partial derivatives of _f and writes them into output.
|
|
AnalyticalF< D, T, S > & | operator- (AnalyticalF< D, T, S > &rhs) |
|
AnalyticalF< D, T, S > & | operator+ (AnalyticalF< D, T, S > &rhs) |
|
AnalyticalF< D, T, S > & | operator* (AnalyticalF< D, T, S > &rhs) |
|
AnalyticalF< D, T, S > & | operator/ (AnalyticalF< D, T, S > &rhs) |
|
virtual | ~GenericF ()=default |
|
int | getSourceDim () const |
| read only access to member variable _m
|
|
int | getTargetDim () const |
| read only access to member variable _n
|
|
std::string & | getName () |
| read and write access to name
|
|
std::string const & | getName () const |
| read only access to name
|
|
bool | operator() (T output[]) |
| wrapper that call the pure virtual operator() (T output[], const S input[]) from above
|
|
bool | operator() (T output[], S input0) |
|
bool | operator() (T output[], S input0, S input1) |
|
bool | operator() (T output[], S input0, S input1, S input2) |
|
bool | operator() (T output[], S input0, S input1, S input2, S input3) |
|
template<class F, typename T, typename S, unsigned sourceDIM, typename... ARGS>
class olb::AnalyticalDerivativeAD< F, T, S, sourceDIM, ARGS >
Definition at line 106 of file derivativeF.h.
template<class F , typename T , typename S , unsigned sourceDIM, typename... ARGS>
Computes the partial derivatives of _f and writes them into output.
- Returns
- output[j*sourceDIM+i] = d/dx_i F_j --> output is an arithmetic array of length targetDIM*sourceDIM
Implements olb::GenericF< T, S >.
Definition at line 127 of file derivativeF.h.
127 {
128 SAD inputAD[sourceDIM];
131 TAD outputAD[
_f.getTargetDim()];
132
133 _f(outputAD, inputAD);
134
136
137 return true;
138 }
util::ADf< S, sourceDIM > SAD
util::ADf< T, sourceDIM > TAD
void copyDerivatives(T *target, const TAD *source, int length)
Copy the derivatives from an ADf array into an array.
void copyN(T c[], const T a[], const unsigned dim) any_platform
void iniDiagonal(SAD *a, int dim)
The variables of an array are set to be the differential variables.
References olb::AnalyticalDerivativeAD< F, T, S, sourceDIM, ARGS >::_f, olb::util::copyDerivatives(), olb::util::copyN(), and olb::util::iniDiagonal().