OPAL (Object Oriented Parallel Accelerator Library)  2.2.0
OPAL
Public Member Functions | Static Public Member Functions | Private Attributes | Static Private Attributes | List of all members
TransportFun< T, N > Class Template Reference

Transport function in N variables of type T. More...

#include <TransportFun.h>

Public Member Functions

 TransportFun ()
 Default constructor. More...
 
 TransportFun (const T &)
 Conversion. More...
 
 TransportFun (int)
 Conversion. More...
 
TransportFunoperator= (const T &y)
 Convert and assign. More...
 
const T getCoefficient (int index) const
 Get coefficient. More...
 
const T getCoefficient (int index1, int index2) const
 Get coefficient. More...
 
void setCoefficient (int index, const T &value)
 Set coefficient. More...
 
void setCoefficient (int index1, int index2, const T &value)
 Set coefficient. More...
 
const T operator[] (int) const
 Get coefficient. More...
 
Toperator[] (int)
 Get coefficient. More...
 
const T operator() (int i1, int i2) const
 Get coefficient. More...
 
Toperator() (int i1, int i2)
 Get coefficient. More...
 
TransportFun operator+ () const
 Unary plus. More...
 
TransportFun operator- () const
 Unary minus. More...
 
TransportFunoperator+= (const TransportFun &y)
 Add and assign. More...
 
TransportFunoperator-= (const TransportFun &y)
 Subtract and assign. More...
 
TransportFunoperator*= (const TransportFun &y)
 Multiply and assign. More...
 
TransportFunoperator/= (const TransportFun &y)
 Approximate division and assignation. More...
 
TransportFunoperator+= (const T &y)
 Add constant and assign. More...
 
TransportFunoperator-= (const T &y)
 Subtract constant and assign. More...
 
TransportFunoperator*= (const T &y)
 Multiply by constant and assign. More...
 
TransportFunoperator/= (const T &y)
 Divide by constant and assign. More...
 
bool operator== (const TransportFun &y) const
 Equality operator. More...
 
bool operator== (const T &y) const
 Equality with constant. More...
 
bool operator!= (const TransportFun &y) const
 Inequality operator. More...
 
bool operator!= (const T &y) const
 Inequality with constant. More...
 
TransportFun inverse () const
 Approximate reciprocal value 1/(*this). More...
 
TransportFun multiply (const TransportFun &y) const
 Multiplication truncated to order one. More...
 
TransportFun< T, N > multiplyVariable (int var) const
 Multiply by variable var. More...
 
T evaluate (const FVector< T, N > &) const
 Evaluate TransportFun at point. More...
 
TransportFun< T, N > substitute (const TransportMap< T, N > &m) const
 Substitute. More...
 
TransportFun< T, N > substitute (const FMatrix< T, N, N > &M) const
 Substitute. More...
 
TransportFun taylor (const T series[2]) const
 Taylor series. More...
 
std::istream & get (std::istream &is)
 Read TransportFun on the stream [b]is[/b]. More...
 
std::ostream & put (std::ostream &os) const
 Write TransportFun on the stream [b]os[/b]. More...
 

Static Public Member Functions

static TransportFun makeVariable (int var)
 Make variable. More...
 

Private Attributes

T data [SIZE]
 Representation. More...
 

Static Private Attributes

static const int SIZE = (N + 1) *(N + 2) / 2
 Size of representation. More...
 

Detailed Description

template<class T, int N>
class TransportFun< T, N >

Transport function in N variables of type T.

Definition at line 40 of file TransportFun.h.

Constructor & Destructor Documentation

template<class T , int N>
TransportFun< T, N >::TransportFun ( )

Default constructor.

Definition at line 40 of file TransportFun.hpp.

References SIZE.

template<class T, int N>
TransportFun< T, N >::TransportFun ( const T rhs)

Conversion.

Definition at line 46 of file TransportFun.hpp.

References SIZE.

template<class T, int N>
TransportFun< T, N >::TransportFun ( int  rhs)

Conversion.

Definition at line 53 of file TransportFun.hpp.

References SIZE, and T.

Member Function Documentation

template<class T, int N>
T TransportFun< T, N >::evaluate ( const FVector< T, N > &  rhs) const

Evaluate TransportFun at point.

Definition at line 282 of file TransportFun.hpp.

References T.

template<class T , int N>
std::istream & TransportFun< T, N >::get ( std::istream &  is)

Read TransportFun on the stream [b]is[/b].

Definition at line 340 of file TransportFun.hpp.

References T.

Referenced by operator>>().

template<class T , int N>
const T TransportFun< T, N >::getCoefficient ( int  index) const

Get coefficient.

Definition at line 68 of file TransportFun.hpp.

References T.

template<class T , int N>
const T TransportFun< T, N >::getCoefficient ( int  index1,
int  index2 
) const

Get coefficient.

Definition at line 74 of file TransportFun.hpp.

References T.

template<class T , int N>
TransportFun< T, N > TransportFun< T, N >::inverse ( ) const

Approximate reciprocal value 1/(*this).

Definition at line 239 of file TransportFun.hpp.

References T.

Referenced by operator/(), TransportMap< T, N >::operator/=(), and TransportFun< T, N >::operator/=().

template<class T , int N>
TransportFun< T, N > TransportFun< T, N >::makeVariable ( int  var)
static

Make variable.

Definition at line 126 of file TransportFun.hpp.

References TransportFun< T, N >::data, SIZE, and T.

template<class T , int N>
TransportFun< T, N > TransportFun< T, N >::multiply ( const TransportFun< T, N > &  y) const

Multiplication truncated to order one.

Definition at line 252 of file TransportFun.hpp.

References TransportFun< T, N >::data, and SIZE.

Referenced by operator*(), and operator/().

template<class T, int N>
TransportFun<T, N> TransportFun< T, N >::multiplyVariable ( int  var) const

Multiply by variable var.

template<class T , int N>
bool TransportFun< T, N >::operator!= ( const TransportFun< T, N > &  y) const
inline

Inequality operator.

Definition at line 227 of file TransportFun.hpp.

template<class T, int N>
bool TransportFun< T, N >::operator!= ( const T y) const
inline

Inequality with constant.

Definition at line 233 of file TransportFun.hpp.

template<class T , int N>
const T TransportFun< T, N >::operator() ( int  i1,
int  i2 
) const
inline

Get coefficient.

Definition at line 112 of file TransportFun.hpp.

template<class T , int N>
T & TransportFun< T, N >::operator() ( int  i1,
int  i2 
)
inline

Get coefficient.

Definition at line 119 of file TransportFun.hpp.

template<class T , int N>
TransportFun< T, N > & TransportFun< T, N >::operator*= ( const TransportFun< T, N > &  y)

Multiply and assign.

Definition at line 163 of file TransportFun.hpp.

template<class T, int N>
TransportFun< T, N > & TransportFun< T, N >::operator*= ( const T y)

Multiply by constant and assign.

Definition at line 190 of file TransportFun.hpp.

References SIZE.

template<class T , int N>
TransportFun< T, N > TransportFun< T, N >::operator+ ( ) const
inline

Unary plus.

Definition at line 135 of file TransportFun.hpp.

template<class T , int N>
TransportFun< T, N > & TransportFun< T, N >::operator+= ( const TransportFun< T, N > &  y)

Add and assign.

Definition at line 149 of file TransportFun.hpp.

References TransportFun< T, N >::data, and SIZE.

template<class T, int N>
TransportFun< T, N > & TransportFun< T, N >::operator+= ( const T y)
inline

Add constant and assign.

Definition at line 176 of file TransportFun.hpp.

template<class T , int N>
TransportFun< T, N > TransportFun< T, N >::operator- ( ) const

Unary minus.

Definition at line 141 of file TransportFun.hpp.

References TransportFun< T, N >::data, and SIZE.

template<class T , int N>
TransportFun< T, N > & TransportFun< T, N >::operator-= ( const TransportFun< T, N > &  y)

Subtract and assign.

Definition at line 156 of file TransportFun.hpp.

References TransportFun< T, N >::data, and SIZE.

template<class T, int N>
TransportFun< T, N > & TransportFun< T, N >::operator-= ( const T y)
inline

Subtract constant and assign.

Definition at line 183 of file TransportFun.hpp.

template<class T , int N>
TransportFun< T, N > & TransportFun< T, N >::operator/= ( const TransportFun< T, N > &  y)

Approximate division and assignation.

Definition at line 169 of file TransportFun.hpp.

References TransportFun< T, N >::data, TransportFun< T, N >::inverse(), and T.

Here is the call graph for this function:

template<class T, int N>
TransportFun< T, N > & TransportFun< T, N >::operator/= ( const T y)

Divide by constant and assign.

Definition at line 197 of file TransportFun.hpp.

References SIZE, and T.

template<class T, int N>
TransportFun< T, N > & TransportFun< T, N >::operator= ( const T y)

Convert and assign.

Definition at line 60 of file TransportFun.hpp.

References SIZE.

template<class T , int N>
bool TransportFun< T, N >::operator== ( const TransportFun< T, N > &  y) const

Equality operator.

Definition at line 205 of file TransportFun.hpp.

References TransportFun< T, N >::data, and SIZE.

template<class T, int N>
bool TransportFun< T, N >::operator== ( const T y) const

Equality with constant.

Definition at line 215 of file TransportFun.hpp.

References SIZE, and T.

template<class T , int N>
const T TransportFun< T, N >::operator[] ( int  index) const
inline

Get coefficient.

Definition at line 100 of file TransportFun.hpp.

template<class T , int N>
T & TransportFun< T, N >::operator[] ( int  index)
inline

Get coefficient.

Definition at line 106 of file TransportFun.hpp.

template<class T , int N>
std::ostream & TransportFun< T, N >::put ( std::ostream &  os) const

Write TransportFun on the stream [b]os[/b].

Definition at line 395 of file TransportFun.hpp.

References endl(), Inform::precision(), and T.

Here is the call graph for this function:

template<class T, int N>
void TransportFun< T, N >::setCoefficient ( int  index,
const T value 
)

Set coefficient.

Definition at line 85 of file TransportFun.hpp.

Referenced by TransportMapper::applyTransportMap().

template<class T, int N>
void TransportFun< T, N >::setCoefficient ( int  index1,
int  index2,
const T value 
)

Set coefficient.

Definition at line 91 of file TransportFun.hpp.

template<class T, int N>
TransportFun< T, N > TransportFun< T, N >::substitute ( const TransportMap< T, N > &  m) const

Substitute.

Definition at line 310 of file TransportFun.hpp.

References TransportFun< T, N >::data.

template<class T, int N>
TransportFun< T, N > TransportFun< T, N >::substitute ( const FMatrix< T, N, N > &  M) const

Substitute.

Definition at line 304 of file TransportFun.hpp.

template<class T, int N>
TransportFun< T, N > TransportFun< T, N >::taylor ( const T  series[2]) const

Taylor series.

Definition at line 332 of file TransportFun.hpp.

Referenced by cos(), cosh(), exp(), log(), sin(), sinh(), and sqrt().

Member Data Documentation

template<class T, int N>
T TransportFun< T, N >::data[SIZE]
private
template<class T, int N>
const int TransportFun< T, N >::SIZE = (N + 1) *(N + 2) / 2
staticprivate

Size of representation.

Definition at line 187 of file TransportFun.h.


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