casacore
|
#include <SparseDiffRep.h>
Public Types | |
typedef T | value_type |
typedef value_type & | reference |
typedef const value_type & | const_reference |
typedef value_type * | iterator |
typedef const value_type * | const_iterator |
Public Member Functions | |
SparseDiffRep () | |
Construct a constant with a value of zero. More... | |
SparseDiffRep< T > & | operator= (const T &v) |
Assignment operators. More... | |
SparseDiffRep< T > & | operator= (const vector< pair< uInt, T > > &grad) |
SparseDiffRep< T > & | operator= (const SparseDiffRep< T > &other) |
void | operator*= (const T other) |
void | operator/= (const T other) |
void | operator+= (const T other) |
void | operator-= (const T other) |
void | clear () |
Clear for reuse. More... | |
Public Attributes | |
T | val_p |
The function value. More... | |
vector< pair< uInt, T > > | grad_p |
The derivatives. More... | |
uInt | link_p |
Link to indicate its status (1=linked in stack; 2=used in modules) More... | |
Representation of data for the spare automatic differentiation calss.
Internal
Class that represents partial derivatives obtained by automatic differentiation.
Class representing the data necessary for automatic differentiation. The structure contains a value, and the derivatives of the value with respect to a number of dependent variables.
The actual differentiation and access is done through the SparseDiff class.
See the example in SparseDiff
To separate the data container from the actual calculations. To be able to create special conatiners; constructors and destructors (including memory allocation) to speed up processes.
Definition at line 89 of file SparseDiffRep.h.
typedef const value_type* casacore::SparseDiffRep< T >::const_iterator |
Definition at line 96 of file SparseDiffRep.h.
typedef const value_type& casacore::SparseDiffRep< T >::const_reference |
Definition at line 94 of file SparseDiffRep.h.
typedef value_type* casacore::SparseDiffRep< T >::iterator |
Definition at line 95 of file SparseDiffRep.h.
typedef value_type& casacore::SparseDiffRep< T >::reference |
Definition at line 93 of file SparseDiffRep.h.
typedef T casacore::SparseDiffRep< T >::value_type |
Definition at line 92 of file SparseDiffRep.h.
casacore::SparseDiffRep< T >::SparseDiffRep | ( | ) |
Construct a constant with a value of zero.
Zero derivatives.
|
inline |
Clear for reuse.
Definition at line 117 of file SparseDiffRep.h.
References casacore::SparseDiffRep< T >::grad_p.
void casacore::SparseDiffRep< T >::operator*= | ( | const T | other | ) |
void casacore::SparseDiffRep< T >::operator+= | ( | const T | other | ) |
void casacore::SparseDiffRep< T >::operator-= | ( | const T | other | ) |
void casacore::SparseDiffRep< T >::operator/= | ( | const T | other | ) |
SparseDiffRep<T>& casacore::SparseDiffRep< T >::operator= | ( | const SparseDiffRep< T > & | other | ) |
SparseDiffRep<T>& casacore::SparseDiffRep< T >::operator= | ( | const T & | v | ) |
Assignment operators.
SparseDiffRep<T>& casacore::SparseDiffRep< T >::operator= | ( | const vector< pair< uInt, T > > & | grad | ) |
vector<pair<uInt, T> > casacore::SparseDiffRep< T >::grad_p |
The derivatives.
Definition at line 123 of file SparseDiffRep.h.
Referenced by casacore::SparseDiffRep< T >::clear().
uInt casacore::SparseDiffRep< T >::link_p |
Link to indicate its status (1=linked in stack; 2=used in modules)
Definition at line 125 of file SparseDiffRep.h.
T casacore::SparseDiffRep< T >::val_p |
The function value.
Definition at line 121 of file SparseDiffRep.h.