casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions
casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations Struct Reference

Implements all mathematical operators and functions for SparseDiff. More...

#include <SparseDiffMath.h>

List of all members.

Public Member Functions

template<class T >
SparseDiff< T > operator+ (const SparseDiff< T > &other)
 Unary arithmetic operators.
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
template<class T >
Bool isInf (SparseDiff< T > &val)
template<class T >
SparseDiff< T > min (const SparseDiff< T > &left, const SparseDiff< T > &right)
 Minimum/maximum.
template<class T >
SparseDiff< T > max (const SparseDiff< T > &left, const SparseDiff< T > &right)

Detailed Description

Implements all mathematical operators and functions for SparseDiff.

Review Status

Reviewed By:
UNKNOWN
Test programs:
tSparseDiff

Prerequisite

Etymology

Implements all mathematical operators and functions for SparseDiff.

To Do

Definition at line 60 of file SparseDiffMath.h.


Member Function Documentation

Transcendental functions.

template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnear ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnear ( const SparseDiff< T > &  left,
const T &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnear ( const T &  left,
const SparseDiff< T > &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnearAbs ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnearAbs ( const SparseDiff< T > &  left,
const T &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::allnearAbs ( const T &  left,
const SparseDiff< T > &  right,
const Double  tol 
)

Floor and ceil of values.

Floating-point remainder of x/c, with the same sign as x, where c is a constant.

Test special values.

template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::max ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::min ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)

Minimum/maximum.

template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near ( const SparseDiff< T > &  left,
const T &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::near ( const T &  left,
const SparseDiff< T > &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::nearAbs ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::nearAbs ( const SparseDiff< T > &  left,
const T &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::nearAbs ( const T &  left,
const SparseDiff< T > &  right,
const Double  tol 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator!= ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator!= ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator!= ( const T &  left,
const SparseDiff< T > &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator* ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator* ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator* ( const T &  left,
const SparseDiff< T > &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator+ ( const SparseDiff< T > &  other)

Unary arithmetic operators.

template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator+ ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)

Arithmetic on two SparseDiff objects, returning a SparseDiff object.

template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator+ ( const SparseDiff< T > &  left,
const T &  right 
)

Arithmetic on a SparseDiff and a scalar, returning a SparseDiff.

template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator+ ( const T &  left,
const SparseDiff< T > &  right 
)

Arithmetic between a scalar and a SparseDiff returning a SparseDiff.

template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator- ( const SparseDiff< T > &  other)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator- ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator- ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator- ( const T &  left,
const SparseDiff< T > &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator/ ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator/ ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
SparseDiff<T> casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator/ ( const T &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator< ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator< ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator< ( const T &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator<= ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator<= ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator<= ( const T &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator== ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator== ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator== ( const T &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::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

template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator> ( const SparseDiff< T > &  left,
const T &  right 
)

Compare a SparseDiff and a constant.

template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator> ( const T &  left,
const SparseDiff< T > &  right 
)

Compare a constant and a SparseDiff.

template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator>= ( const SparseDiff< T > &  left,
const SparseDiff< T > &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator>= ( const SparseDiff< T > &  left,
const T &  right 
)
template<class T >
Bool casa::SparseDiffMath_global_functions_SparseDiff_mathematical_operations::operator>= ( const T &  left,
const SparseDiff< T > &  right 
)

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