OPAL (Object Oriented Parallel Accelerator Library)  2021.1.99
OPAL
Public Member Functions | Protected Attributes | List of all members
Vps< T > Class Template Reference

Vector truncated power series. More...

#include <Vps.h>

Inheritance diagram for Vps< T >:
Inheritance graph
[legend]
Collaboration diagram for Vps< T >:
Collaboration graph
[legend]

Public Member Functions

 Vps (int nDim, int nVar=0)
 Constructor. More...
 
 Vps (const Matrix< T > &M)
 Convert. More...
 
 Vps (const Vector< T > &V)
 Convert from vector. More...
 
 Vps ()
 
 Vps (const Vps< T > &rhs)
 
 ~Vps ()
 
Vps< T > & operator= (const Vps< T > &)
 
const Tps< T > & getComponent (int index) const
 Get component. More...
 
void setComponent (int index, const Tps< T > &value)
 Set component. More...
 
Tps< T > & operator[] (int index)
 Get component. More...
 
const Tps< T > & operator[] (int index) const
 Set component. More...
 
void check () const
 Check consistency. More...
 
Vps< T > operator+ () const
 Unary plus. More...
 
Vps< T > operator- () const
 Unary minus. More...
 
Vps< T > & operator*= (const Tps< T > &y)
 Multiply by Tps<T> and assign. More...
 
Vps< T > & operator/= (const Tps< T > &y)
 Divide by Tps<T> and assign. More...
 
Vps< T > & operator*= (const T &y)
 Multiply by constant and assign. More...
 
Vps< T > & operator/= (const T &y)
 Divide by constant and assign. More...
 
Vps< T > & operator+= (const Vps< T > &y)
 Addition. More...
 
Vps< T > & operator-= (const Vps< T > &y)
 Subtraction. More...
 
Vps< T > & operator+= (const Vector< T > &y)
 Add and assign. More...
 
Vps< T > & operator-= (const Vector< T > &y)
 Subtract and assign. More...
 
std::istream & get (std::istream &is)
 Get a Vps<T> from stream is. More...
 
std::ostream & put (std::ostream &os) const
 Put a Vps<T> to stream os. More...
 
int getDimension () const
 Get dimension (number of Tps<T> components). More...
 
int getTopOrder () const
 Get highest order contained in any component. More...
 
int getTruncOrder () const
 Get lowest truncation order in any component. More...
 
int getVariables () const
 Get number of variables (the same in all components). More...
 
Vps< T > filter (int lowOrder, int highOrder) const
 Extract range of orders, set others to zero. More...
 
Vps< T > truncate (int trunc)
 Truncate, may also increase truncation order. More...
 

Protected Attributes

Array1D< Tps< T > > data
 
int variables
 

Detailed Description

template<class T>
class Vps< T >

Vector truncated power series.

Definition at line 38 of file Vps.h.

Constructor & Destructor Documentation

◆ Vps() [1/5]

template<class T >
Vps< T >::Vps ( int  nDim,
int  nVar = 0 
)

Constructor.

Definition at line 46 of file Vps.hpp.

◆ Vps() [2/5]

template<class T >
Vps< T >::Vps ( const Matrix< T > &  M)

Convert.

Definition at line 59 of file Vps.hpp.

References Vps< T >::data, Array2D< T >::ncols(), and Array2D< T >::nrows().

Here is the call graph for this function:

◆ Vps() [3/5]

template<class T >
Vps< T >::Vps ( const Vector< T > &  V)

Convert from vector.

Definition at line 72 of file Vps.hpp.

◆ Vps() [4/5]

template<class T >
Vps< T >::Vps

Definition at line 40 of file Vps.hpp.

◆ Vps() [5/5]

template<class T >
Vps< T >::Vps ( const Vps< T > &  rhs)

Definition at line 52 of file Vps.hpp.

◆ ~Vps()

template<class T >
Vps< T >::~Vps

Definition at line 79 of file Vps.hpp.

Member Function Documentation

◆ check()

template<class T >
void Vps< T >::check

Check consistency.

Definition at line 108 of file Vps.hpp.

Referenced by Vps< T >::get(), and VpsMap< T >::substitute().

◆ filter()

template<class T >
Vps< T > Vps< T >::filter ( int  lowOrder,
int  highOrder 
) const

Extract range of orders, set others to zero.

Definition at line 286 of file Vps.hpp.

References Vps< T >::data.

◆ get()

template<class T >
std::istream & Vps< T >::get ( std::istream &  is)

Get a Vps<T> from stream is.

Definition at line 213 of file Vps.hpp.

References Vps< T >::check().

Referenced by operator>>().

Here is the call graph for this function:

◆ getComponent()

template<class T >
const Tps< T > & Vps< T >::getComponent ( int  index) const

Get component.

Definition at line 92 of file Vps.hpp.

◆ getDimension()

template<class T >
int Vps< T >::getDimension

Get dimension (number of Tps<T> components).

Definition at line 247 of file Vps.hpp.

Referenced by Vps< T >::operator+=(), Vps< T >::operator-=(), Tps< T >::substitute(), and VpsMap< T >::substitute().

◆ getTopOrder()

template<class T >
int Vps< T >::getTopOrder

Get highest order contained in any component.

Definition at line 253 of file Vps.hpp.

References Tps< T >::getMaxOrder(), and max().

Here is the call graph for this function:

◆ getTruncOrder()

template<class T >
int Vps< T >::getTruncOrder

Get lowest truncation order in any component.

Definition at line 266 of file Vps.hpp.

References Tps< T >::getTruncOrder(), and min().

Here is the call graph for this function:

◆ getVariables()

template<class T >
int Vps< T >::getVariables

Get number of variables (the same in all components).

Definition at line 279 of file Vps.hpp.

◆ operator*=() [1/2]

template<class T >
Vps< T > & Vps< T >::operator*= ( const T &  y)

Multiply by constant and assign.

Definition at line 153 of file Vps.hpp.

◆ operator*=() [2/2]

template<class T >
Vps< T > & Vps< T >::operator*= ( const Tps< T > &  y)

Multiply by Tps<T> and assign.

Definition at line 138 of file Vps.hpp.

◆ operator+()

template<class T >
Vps< T > Vps< T >::operator+

Unary plus.

Definition at line 124 of file Vps.hpp.

◆ operator+=() [1/2]

template<class T >
Vps< T > & Vps< T >::operator+= ( const Vector< T > &  y)

Add and assign.

Definition at line 191 of file Vps.hpp.

References Array1D< T >::size().

Here is the call graph for this function:

◆ operator+=() [2/2]

template<class T >
Vps< T > & Vps< T >::operator+= ( const Vps< T > &  y)

Addition.

Definition at line 169 of file Vps.hpp.

References Vps< T >::data, and Vps< T >::getDimension().

Here is the call graph for this function:

◆ operator-()

template<class T >
Vps< T > Vps< T >::operator-

Unary minus.

Definition at line 130 of file Vps.hpp.

◆ operator-=() [1/2]

template<class T >
Vps< T > & Vps< T >::operator-= ( const Vector< T > &  y)

Subtract and assign.

Definition at line 202 of file Vps.hpp.

References Array1D< T >::size().

Here is the call graph for this function:

◆ operator-=() [2/2]

template<class T >
Vps< T > & Vps< T >::operator-= ( const Vps< T > &  y)

Subtraction.

Definition at line 180 of file Vps.hpp.

References Vps< T >::data, and Vps< T >::getDimension().

Here is the call graph for this function:

◆ operator/=() [1/2]

template<class T >
Vps< T > & Vps< T >::operator/= ( const T &  y)

Divide by constant and assign.

Definition at line 160 of file Vps.hpp.

References Attrib::Legacy::Distribution::T.

◆ operator/=() [2/2]

template<class T >
Vps< T > & Vps< T >::operator/= ( const Tps< T > &  y)

Divide by Tps<T> and assign.

Definition at line 145 of file Vps.hpp.

References Tps< T >::inverse().

Here is the call graph for this function:

◆ operator=()

template<class T >
Vps< T > & Vps< T >::operator= ( const Vps< T > &  y)

Definition at line 84 of file Vps.hpp.

References Vps< T >::data, and Vps< T >::variables.

Referenced by VpsMap< T >::operator=().

◆ operator[]() [1/2]

template<class T >
Tps< T > & Vps< T >::operator[] ( int  index)
inline

Get component.

Definition at line 154 of file Vps.h.

◆ operator[]() [2/2]

template<class T >
const Tps< T > & Vps< T >::operator[] ( int  index) const
inline

Set component.

Definition at line 158 of file Vps.h.

◆ put()

template<class T >
std::ostream & Vps< T >::put ( std::ostream &  os) const

Put a Vps<T> to stream os.

Definition at line 238 of file Vps.hpp.

References endl().

Referenced by operator<<().

Here is the call graph for this function:

◆ setComponent()

template<class T >
void Vps< T >::setComponent ( int  index,
const Tps< T > &  value 
)

Set component.

Definition at line 98 of file Vps.hpp.

References Tps< T >::getVariables().

Here is the call graph for this function:

◆ truncate()

template<class T >
Vps< T > Vps< T >::truncate ( int  trunc)

Truncate, may also increase truncation order.

Definition at line 299 of file Vps.hpp.

References Vps< T >::data.

Member Data Documentation

◆ data

template<class T >
Array1D< Tps<T> > Vps< T >::data
protected

◆ variables

template<class T >
int Vps< T >::variables
mutableprotected

Definition at line 146 of file Vps.h.

Referenced by Vps< T >::operator=().


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