casacore
|
Implements all mathematical operators and functions for SparseDiff. More...
#include <SparseDiffMath.h>
Public Member Functions | |
template<class T > | |
SparseDiff< T > | operator+ (const SparseDiff< T > &other) |
Unary arithmetic operators. More... | |
template<class T > | |
SparseDiff< T > | operator- (const SparseDiff< T > &other) |
template<class T > | |
SparseDiff< T > | operator+ (const SparseDiff< T > &left, const SparseDiff< T > &right) |
Arithmetic on two SparseDiff objects, returning a SparseDiff object. More... | |
template<class T > | |
SparseDiff< T > | operator- (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
SparseDiff< T > | operator* (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
SparseDiff< T > | operator/ (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
SparseDiff< T > | operator+ (const SparseDiff< T > &left, const T &right) |
Arithmetic on a SparseDiff and a scalar, returning a SparseDiff. More... | |
template<class T > | |
SparseDiff< T > | operator- (const SparseDiff< T > &left, const T &right) |
template<class T > | |
SparseDiff< T > | operator* (const SparseDiff< T > &left, const T &right) |
template<class T > | |
SparseDiff< T > | operator/ (const SparseDiff< T > &left, const T &right) |
template<class T > | |
SparseDiff< T > | operator+ (const T &left, const SparseDiff< T > &right) |
Arithmetic between a scalar and a SparseDiff returning a SparseDiff. More... | |
template<class T > | |
SparseDiff< T > | operator- (const T &left, const SparseDiff< T > &right) |
template<class T > | |
SparseDiff< T > | operator* (const T &left, const SparseDiff< T > &right) |
template<class T > | |
SparseDiff< T > | operator/ (const T &left, const SparseDiff< T > &right) |
template<class T > | |
SparseDiff< T > | acos (const SparseDiff< T > &ad) |
Transcendental functions. More... | |
template<class T > | |
SparseDiff< T > | asin (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | atan (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | atan2 (const SparseDiff< T > &y, const SparseDiff< T > &x) |
template<class T > | |
SparseDiff< T > | cos (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | cosh (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | exp (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | log (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | log10 (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | erf (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | erfc (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | pow (const SparseDiff< T > &a, const SparseDiff< T > &b) |
template<class T > | |
SparseDiff< T > | pow (const SparseDiff< T > &a, const T &b) |
template<class T > | |
SparseDiff< T > | square (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | cube (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | sin (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | sinh (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | sqrt (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | tan (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | tanh (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | abs (const SparseDiff< T > &ad) |
template<class T > | |
SparseDiff< T > | fmod (const SparseDiff< T > &x, const T &c) |
Floating-point remainder of x/c, with the same sign as x, where c is a constant. More... | |
template<class T > | |
SparseDiff< T > | fmod (const SparseDiff< T > &x, const SparseDiff< T > &c) |
template<class T > | |
SparseDiff< T > | floor (const SparseDiff< T > &ad) |
Floor and ceil of values. More... | |
template<class T > | |
SparseDiff< T > | ceil (const SparseDiff< T > &ad) |
template<class T > | |
Bool | operator> (const SparseDiff< T > &left, const SparseDiff< T > &right) |
Comparison operators. More... | |
template<class T > | |
Bool | operator< (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | operator>= (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | operator<= (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | operator== (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | operator!= (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | near (const SparseDiff< T > &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | near (const SparseDiff< T > &left, const SparseDiff< T > &right, const Double tol) |
template<class T > | |
Bool | allnear (const SparseDiff< T > &left, const SparseDiff< T > &right, const Double tol) |
template<class T > | |
Bool | nearAbs (const SparseDiff< T > &left, const SparseDiff< T > &right, const Double tol) |
template<class T > | |
Bool | allnearAbs (const SparseDiff< T > &left, const SparseDiff< T > &right, const Double tol) |
template<class T > | |
Bool | operator> (const SparseDiff< T > &left, const T &right) |
Compare a SparseDiff and a constant. More... | |
template<class T > | |
Bool | operator< (const SparseDiff< T > &left, const T &right) |
template<class T > | |
Bool | operator>= (const SparseDiff< T > &left, const T &right) |
template<class T > | |
Bool | operator<= (const SparseDiff< T > &left, const T &right) |
template<class T > | |
Bool | operator== (const SparseDiff< T > &left, const T &right) |
template<class T > | |
Bool | operator!= (const SparseDiff< T > &left, const T &right) |
template<class T > | |
Bool | near (const SparseDiff< T > &left, const T &right) |
template<class T > | |
Bool | near (const SparseDiff< T > &left, const T &right, const Double tol) |
template<class T > | |
Bool | allnear (const SparseDiff< T > &left, const T &right, const Double tol) |
template<class T > | |
Bool | nearAbs (const SparseDiff< T > &left, const T &right, const Double tol) |
template<class T > | |
Bool | allnearAbs (const SparseDiff< T > &left, const T &right, const Double tol) |
template<class T > | |
Bool | operator> (const T &left, const SparseDiff< T > &right) |
Compare a constant and a SparseDiff. More... | |
template<class T > | |
Bool | operator< (const T &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | operator>= (const T &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | operator<= (const T &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | operator== (const T &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | operator!= (const T &left, const SparseDiff< T > &right) |
template<class T > | |
Bool | near (const T &left, const SparseDiff< T > &right, const Double tol) |
template<class T > | |
Bool | allnear (const T &left, const SparseDiff< T > &right, const Double tol) |
template<class T > | |
Bool | nearAbs (const T &left, const SparseDiff< T > &right, const Double tol) |
template<class T > | |
Bool | allnearAbs (const T &left, const SparseDiff< T > &right, const Double tol) |
template<class T > | |
Bool | isNaN (const SparseDiff< T > &val) |
Test special values. More... | |
template<class T > | |
Bool | isInf (SparseDiff< T > &val) |
template<class T > | |
SparseDiff< T > | min (const SparseDiff< T > &left, const SparseDiff< T > &right) |
Minimum/maximum. More... | |
template<class T > | |
SparseDiff< T > | max (const SparseDiff< T > &left, const SparseDiff< T > &right) |
Implements all mathematical operators and functions for SparseDiff.
Implements all mathematical operators and functions for SparseDiff.
Definition at line 60 of file SparseDiffMath.h.
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::abs | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::acos | ( | const SparseDiff< T > & | ad | ) |
Transcendental functions.
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnear | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnear | ( | const SparseDiff< T > & | left, |
const T & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnear | ( | const T & | left, |
const SparseDiff< T > & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnearAbs | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnearAbs | ( | const SparseDiff< T > & | left, |
const T & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnearAbs | ( | const T & | left, |
const SparseDiff< T > & | right, | ||
const Double | tol | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::asin | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::atan | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::atan2 | ( | const SparseDiff< T > & | y, |
const SparseDiff< T > & | x | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::ceil | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::cos | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::cosh | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::cube | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::erf | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::erfc | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::exp | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::floor | ( | const SparseDiff< T > & | ad | ) |
Floor and ceil of values.
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::fmod | ( | const SparseDiff< T > & | x, |
const T & | c | ||
) |
Floating-point remainder of x/c, with the same sign as x, where c is a constant.
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::fmod | ( | const SparseDiff< T > & | x, |
const SparseDiff< T > & | c | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::isInf | ( | SparseDiff< T > & | val | ) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::isNaN | ( | const SparseDiff< T > & | val | ) |
Test special values.
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::log | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::log10 | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::max | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::min | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Minimum/maximum.
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near | ( | const SparseDiff< T > & | left, |
const T & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near | ( | const T & | left, |
const SparseDiff< T > & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::nearAbs | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::nearAbs | ( | const SparseDiff< T > & | left, |
const T & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::nearAbs | ( | const T & | left, |
const SparseDiff< T > & | right, | ||
const Double | tol | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator!= | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator!= | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator!= | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator* | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator* | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator* | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator+ | ( | const SparseDiff< T > & | other | ) |
Unary arithmetic operators.
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator+ | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Arithmetic on two SparseDiff objects, returning a SparseDiff object.
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator+ | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
Arithmetic on a SparseDiff and a scalar, returning a SparseDiff.
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator+ | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
Arithmetic between a scalar and a SparseDiff returning a SparseDiff.
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator- | ( | const SparseDiff< T > & | other | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator- | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator- | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator- | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator/ | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator/ | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator/ | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator< | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator< | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator< | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator<= | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator<= | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator<= | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator== | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator== | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator== | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator> | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Comparison operators.
Only the values are compared: in the actual functions, comparisons are used to decide on algorithms. To check if two SparseDiff values are equal, use comparison for both value and derivatives.
Tip: To check if two SparseDiff values are equal, use the member method equals()
(e;g; for debugging and testing);
Compare two SparseDiff's
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator> | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
Compare a SparseDiff and a constant.
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator> | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
Compare a constant and a SparseDiff.
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator>= | ( | const SparseDiff< T > & | left, |
const SparseDiff< T > & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator>= | ( | const SparseDiff< T > & | left, |
const T & | right | ||
) |
Bool casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator>= | ( | const T & | left, |
const SparseDiff< T > & | right | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::pow | ( | const SparseDiff< T > & | a, |
const SparseDiff< T > & | b | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::pow | ( | const SparseDiff< T > & | a, |
const T & | b | ||
) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::sin | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::sinh | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::sqrt | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::square | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::tan | ( | const SparseDiff< T > & | ad | ) |
SparseDiff<T> casacore::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::tanh | ( | const SparseDiff< T > & | ad | ) |