OPAL (Object Oriented Parallel Accelerator Library) 2024.2
OPAL
FTps< T, N > Class Template Reference

Truncated power series in N variables of type T. More...

#include <FTps.h>

Inheritance diagram for FTps< T, N >:
Collaboration diagram for FTps< T, N >:

Public Member Functions

 FTps ()
 Default constructor.
 FTps (const FTps &x)
 Copy constructor.
 FTps (int minOrder, int maxOrder, int trcOrder)
 Constructor.
 FTps (const T &)
 Conversion.
 FTps (int)
 Conversion.
 ~FTps ()
 Destructor.
FTpsoperator= (const FTps &y)
 Assign.
FTpsoperator= (const T &y)
 Convert and assign.
const T getCoefficient (int index) const
 Get coefficient.
void setCoefficient (int index, const T &value)
 Set coefficient.
const T getCoefficient (const FMonomial< N > &monomial) const
 Get coefficient.
void setCoefficient (const FMonomial< N > &monomial, const T &value)
 Set coefficient.
const T operator[] (int index) const
 Get coefficient.
T & operator[] (int index)
 Get (Set) coefficient.
const T operator[] (const FMonomial< N > &monomial) const
 Get coefficient.
T & operator[] (const FMonomial< N > &monomial)
 Get (Set) coefficient.
T * begin () const
 Return beginning of monomial array.
T * end () const
 Return end of monomial array.
T * begin (int order) const
 Return beginning of coefficient storage for given order.
T * end (int order) const
 Return end of coefficient storage for given order.
int getSize () const
 Get total number of coefficients.
int getMinOrder () const
 Get minimum order.
void setMinOrder (int order)
 Set minimum order.
int getMaxOrder () const
 Get maximum order.
void setMaxOrder (int order)
 Set maximum order.
int getTruncOrder () const
 Get truncation order.
void setTruncOrder (int order)
 Set truncation order.
FTps filter (int minOrder, int maxOrder, int trcOrder=EXACT) const
 Extract given range of orders, with truncation.
FTps truncate (int trunc)
 Truncate.
FTps operator+ () const
 Unary plus.
FTps operator- () const
 Unary minus.
FTpsoperator+= (const FTps &y)
 Add and assign.
FTpsoperator-= (const FTps &y)
 Subtract and assign.
FTpsoperator*= (const FTps &y)
 Multiply and assign.
FTpsoperator/= (const FTps &y)
 Divide and assign.
FTpsoperator+= (const T &y)
 Add constant and assign.
FTpsoperator-= (const T &y)
 Subtract constant and assign.
FTpsoperator*= (const T &y)
 Multiply by constant and assign.
FTpsoperator/= (const T &y)
 Divide by constant and assign.
FTps scaleMonomials (const FTps &y) const
 Scale monomial coefficients by coefficients in [b]y[/b].
FTps multiplyVariable (int var, int trunc=EXACT) const
 Multiply by variable [b]var[/b].
FTps multiply (const FTps &y, int trunc=EXACT) const
 Multiplication.
FTps inverse (int trunc=EXACT) const
 Reciprocal, 1/(*this).
FTps divide (const FTps &y, int trunc=EXACT) const
 Division.
bool operator== (const FTps &y) const
 Equality operator.
bool operator== (const T &y) const
 Equality with constant.
bool operator!= (const FTps &y) const
 Inequality operator.
bool operator!= (const T &y) const
 Inequality with constant.
evaluate (const FVector< T, N > &) const
 Evaluate FTps at point.
Array1D< int > getSubstOrders (const FVps< T, N > &rhs, int trunc=EXACT) const
 Return orders {min, max, trc} of f(rhs(z)).
FTps substitute (const FMatrix< T, N, N > &M, int n) const
 Substitute.
FTps substitute (const FMatrix< T, N, N > &M, int nl, int nh) const
 Substitute.
FTps substitute (const FMatrix< T, N, N > &M) const
 Substitute.
FTps substitute (const FVps< T, N > &m, int trunc=EXACT) const
 Substitute.
FTps derivative (int var) const
 Partial derivative.
FVps< T, N > gradient () const
 Gradient.
FTps integral (int var, int trunc=EXACT) const
 Partial integral.
FTps taylor (const Array1D< T > &series, int order) const
 Taylor series.
void unique ()
 Make representation unique.
std::list< int > getListOfNonzeroCoefficients () const
 Get a list containing the indexes of non-zero coefficients of a FTps.
FArray1D< int, N > extractExponents (int index) const
 Extract exponents of coefficient.
FTps< T, N > makePower (int power) const
 Multiply FTps with itself.
std::istream & get (std::istream &is)
 Read FTps on the stream [b]is[/b].
std::ostream & put (std::ostream &os) const
 Write FTps on the stream [b]os[/b].

Static Public Member Functions

static int getVariables ()
 Get number of variables.
static int getSize (int order)
 Get number of coefficients of degree [b]order[/b] or less.
static int orderStart (int order)
 Get index at which [b]order[/b] starts.
static int orderEnd (int order)
 Get one plus index at which [b]order[/b] ends.
static int orderLength (int order)
static int orderLength (int orderL, int orderH)
static const FMonomial< N > & getExponents (int index)
 Get exponents for given index.
static int getIndex (const FMonomial< N > &mono)
 Get Giorgilli index for monomial.
static int getGlobalTruncOrder ()
 Return the global truncation order.
static void setGlobalTruncOrder (int order)
 Set the global truncation order.
static const Array1D< int > & getProductArray (int index)
 Index array for products of monomial "index".
static const Array1D< int > & getVariableList (int index)
 List of variables contained in monomial "index".
static const Array1D< TpsSubstitution > & getSubTable ()
 Return the substitution table.
static FTps makeVariable (int var)
 Make variable.
static FTps makeVarPower (int var, int power)
 Make power.
static FTps makeMonomial (int index, const T &t)
 Make monomial.
static FTps makeMonomial (const FMonomial< N > &m, const T &t)
 Make monomial.
static Array1D< T > evalMonoms (const FVector< T, N > &, int)
 Evaluate monomials at point.
static Array1D< int > getSubstOrders (Array1D< int > &ordersL, Array1D< int > &ordersR, int trunc=EXACT)
 Return orders {min, max, trc} of f(rhs(z)),.

Static Public Attributes

static const int EXACT
 Representation of infinite precision.

Private Member Functions

void grow (int maxOrder, int trcOrder)
Array1D< int > getRepOrders () const

Static Private Member Functions

static FTpsRep< T, N > * allocate (int minOrder, int maxOrder, int trcOrder)
static void deallocate (FTpsRep< T, N > *)
static void checkOrders (const std::string &method, int minOrder, int maxOrder, int &trcOrder)

Private Attributes

FTpsRep< T, N > * itsRep

Static Private Attributes

static FTpsRep< T, N > * freeList [100]
static int globalTruncOrder

Detailed Description

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

Truncated power series in N variables of type T.

Definition at line 45 of file FTps.h.

Constructor & Destructor Documentation

◆ FTps() [1/5]

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

Default constructor.

Definition at line 159 of file FTps.hpp.

References allocate(), EXACT, and itsRep.

Referenced by derivative(), divide(), filter(), FTps(), get(), integral(), inverse(), makeMonomial(), makeMonomial(), makePower(), makeVariable(), makeVarPower(), multiply(), multiplyVariable(), operator!=(), operator*=(), operator*=(), operator+(), operator+=(), operator+=(), operator-(), operator-=(), operator-=(), operator/=(), operator/=(), operator=(), operator=(), operator==(), scaleMonomials(), substitute(), substitute(), substitute(), substitute(), taylor(), and truncate().

Here is the call graph for this function:

◆ FTps() [2/5]

template<class T, int N>
FTps< T, N >::FTps ( const FTps< T, N > & x)

Copy constructor.

Definition at line 166 of file FTps.hpp.

References FTps(), and itsRep.

Here is the call graph for this function:

◆ FTps() [3/5]

template<class T, int N>
FTps< T, N >::FTps ( int minOrder,
int maxOrder,
int trcOrder )

Constructor.

Definition at line 173 of file FTps.hpp.

References allocate(), and itsRep.

Here is the call graph for this function:

◆ FTps() [4/5]

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

Conversion.

Definition at line 180 of file FTps.hpp.

References allocate(), EXACT, and itsRep.

Here is the call graph for this function:

◆ FTps() [5/5]

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

Conversion.

Definition at line 187 of file FTps.hpp.

References allocate(), EXACT, and itsRep.

Here is the call graph for this function:

◆ ~FTps()

template<class T, int N>
FTps< T, N >::~FTps ( )

Destructor.

Definition at line 194 of file FTps.hpp.

References deallocate(), and itsRep.

Here is the call graph for this function:

Member Function Documentation

◆ allocate()

template<class T, int N>
FTpsRep< T, N > * FTps< T, N >::allocate ( int minOrder,
int maxOrder,
int trcOrder )
inlinestaticprivate

Definition at line 1692 of file FTps.hpp.

References FTpsRep< T, N >::allocOrd, checkOrders(), EXACT, freeList, FTpsRep< T, N >::maxOrd, FTpsRep< T, N >::minOrd, FTpsRep< T, N >::next, FTpsRep< T, N >::ref, and FTpsRep< T, N >::trcOrd.

Referenced by FTps(), FTps(), FTps(), FTps(), grow(), operator=(), and unique().

Here is the call graph for this function:

◆ begin() [1/2]

template<class T, int N>
T * FTps< T, N >::begin ( ) const
inline

◆ begin() [2/2]

template<class T, int N>
T * FTps< T, N >::begin ( int order) const
inline

Return beginning of coefficient storage for given order.

Definition at line 124 of file FTps.h.

◆ checkOrders()

template<class T, int N>
void FTps< T, N >::checkOrders ( const std::string & method,
int minOrder,
int maxOrder,
int & trcOrder )
staticprivate

Definition at line 1767 of file FTps.hpp.

References EXACT, and globalTruncOrder.

Referenced by allocate(), and filter().

◆ deallocate()

template<class T, int N>
void FTps< T, N >::deallocate ( FTpsRep< T, N > * rep)
inlinestaticprivate

Definition at line 1726 of file FTps.hpp.

References FTpsRep< T, N >::allocOrd, freeList, and FTpsRep< T, N >::next.

Referenced by grow(), operator=(), operator=(), and ~FTps().

◆ derivative()

template<class T, int N>
FTps< T, N > FTps< T, N >::derivative ( int var) const

Partial derivative.

Definition at line 1396 of file FTps.hpp.

References Array1D< T >::begin(), begin(), begin(), EXACT, FTps(), FTpsData< N >::getExponents(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), FTpsData< N >::getProductArray(), FVps< T, N >::getTruncOrder(), orderEnd(), and orderStart().

Referenced by Tracker::applyThinSBend(), Tracker::buildSBendVectorPotential(), Tracker::buildSBendVectorPotential2D(), ExpMap(), ExpMap(), and PoissonBracket().

Here is the call graph for this function:

◆ divide()

template<class T, int N>
FTps< T, N > FTps< T, N >::divide ( const FTps< T, N > & y,
int trunc = EXACT ) const

Division.

Definition at line 761 of file FTps.hpp.

References begin(), begin(), c, end(), EXACT, FTps(), getMaxOrder(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), FTpsData< N >::getProductArray(), getTruncOrder(), FVps< T, N >::getTruncOrder(), globalTruncOrder, itsRep, orderEnd(), orderStart(), and prod().

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

Here is the call graph for this function:

◆ end() [1/2]

template<class T, int N>
T * FTps< T, N >::end ( ) const
inline

Return end of monomial array.

Definition at line 121 of file FTps.h.

Referenced by substitute().

◆ end() [2/2]

template<class T, int N>
T * FTps< T, N >::end ( int order) const
inline

Return end of coefficient storage for given order.

Definition at line 128 of file FTps.h.

◆ evalMonoms()

template<class T, int N>
Array1D< T > FTps< T, N >::evalMonoms ( const FVector< T, N > & rhs,
int maxOrder )
static

Evaluate monomials at point.

Definition at line 898 of file FTps.hpp.

References Array1D< T >::begin(), FArray1D< T, N >::begin(), getSize(), and FTpsData< N >::orderStart().

Referenced by FVps< T, N >::linearTerms().

Here is the call graph for this function:

◆ evaluate()

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

Evaluate FTps at point.

Definition at line 934 of file FTps.hpp.

References begin(), FArray1D< T, N >::begin(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), getSize(), and FTpsData< N >::orderStart().

Referenced by Tracker::applyThinSBend(), and operator*().

Here is the call graph for this function:

◆ extractExponents()

template<class T, int N>
FArray1D< int, N > FTps< T, N >::extractExponents ( int index) const

Extract exponents of coefficient.

Definition at line 1535 of file FTps.hpp.

References getExponents(), and getSize().

Referenced by FVps< T, N >::operator*().

Here is the call graph for this function:

◆ filter()

template<class T, int N>
FTps< T, N > FTps< T, N >::filter ( int minOrder,
int maxOrder,
int trcOrder = EXACT ) const

Extract given range of orders, with truncation.

Definition at line 451 of file FTps.hpp.

References begin(), begin(), checkOrders(), end(), FTps(), and itsRep.

Here is the call graph for this function:

◆ get()

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

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

Definition at line 1571 of file FTps.hpp.

References EXACT, FTps(), FTpsData< N >::getIndex(), getMaxOrder(), getMinOrder(), and itsRep.

Referenced by operator>>().

Here is the call graph for this function:

◆ getCoefficient() [1/2]

template<class T, int N>
const T FTps< T, N >::getCoefficient ( const FMonomial< N > & monomial) const

Get coefficient.

Definition at line 261 of file FTps.hpp.

References getCoefficient(), and FTpsData< N >::getIndex().

Here is the call graph for this function:

◆ getCoefficient() [2/2]

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

Get coefficient.

Definition at line 223 of file FTps.hpp.

References itsRep, orderEnd(), and orderStart().

Referenced by getCoefficient(), getListOfNonzeroCoefficients(), and FVps< T, N >::operator*().

Here is the call graph for this function:

◆ getExponents()

template<class T, int N>
const FMonomial< N > & FTps< T, N >::getExponents ( int index)
static

Get exponents for given index.

Definition at line 309 of file FTps.hpp.

References FTpsData< N >::getExponents().

Referenced by extractExponents().

Here is the call graph for this function:

◆ getGlobalTruncOrder()

template<class T, int N>
int FTps< T, N >::getGlobalTruncOrder ( )
inlinestatic

Return the global truncation order.

Definition at line 191 of file FTps.h.

Referenced by FVps< T, N >::getFTps(), FVps< T, N >::operator*(), FVps< T, N >::substitute(), FVps< T, N >::substitute(), and FVps< T, N >::substitute().

◆ getIndex()

template<class T, int N>
int FTps< T, N >::getIndex ( const FMonomial< N > & mono)
static

Get Giorgilli index for monomial.

Definition at line 315 of file FTps.hpp.

References FTpsData< N >::getIndex().

Here is the call graph for this function:

◆ getListOfNonzeroCoefficients()

template<class T, int N>
std::list< int > FTps< T, N >::getListOfNonzeroCoefficients ( ) const

Get a list containing the indexes of non-zero coefficients of a FTps.

Definition at line 1515 of file FTps.hpp.

References getCoefficient(), and getSize().

Referenced by FVps< T, N >::operator*().

Here is the call graph for this function:

◆ getMaxOrder()

◆ getMinOrder()

template<class T, int N>
int FTps< T, N >::getMinOrder ( ) const
inline

◆ getProductArray()

template<class T, int N>
const Array1D< int > & FTps< T, N >::getProductArray ( int index)
inlinestatic

Index array for products of monomial "index".

Definition at line 433 of file FTps.hpp.

References FTpsData< N >::getProductArray().

Here is the call graph for this function:

◆ getRepOrders()

template<class T, int N>
Array1D< int > FTps< T, N >::getRepOrders ( ) const
private

Definition at line 1756 of file FTps.hpp.

References itsRep.

◆ getSize() [1/2]

template<class T, int N>
int FTps< T, N >::getSize ( ) const
inline

◆ getSize() [2/2]

template<class T, int N>
int FTps< T, N >::getSize ( int order)
static

Get number of coefficients of degree [b]order[/b] or less.

Definition at line 303 of file FTps.hpp.

References FTpsData< N >::getSize().

Here is the call graph for this function:

◆ getSubstOrders() [1/2]

template<class T, int N>
Array1D< int > FTps< T, N >::getSubstOrders ( Array1D< int > & ordersL,
Array1D< int > & ordersR,
int trunc = EXACT )
static

Return orders {min, max, trc} of f(rhs(z)),.

Definition at line 1022 of file FTps.hpp.

References EXACT.

◆ getSubstOrders() [2/2]

template<class T, int N>
Array1D< int > FTps< T, N >::getSubstOrders ( const FVps< T, N > & rhs,
int trunc = EXACT ) const

Return orders {min, max, trc} of f(rhs(z)).

Definition at line 1008 of file FTps.hpp.

References FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), FVps< T, N >::getSubstOrders(), and FVps< T, N >::getTruncOrder().

Referenced by FVps< T, N >::getSubstOrders().

Here is the call graph for this function:

◆ getSubTable()

template<class T, int N>
const Array1D< TpsSubstitution > & FTps< T, N >::getSubTable ( )
inlinestatic

Return the substitution table.

Definition at line 445 of file FTps.hpp.

References FTpsData< N >::getSubTable().

Here is the call graph for this function:

◆ getTruncOrder()

template<class T, int N>
int FTps< T, N >::getTruncOrder ( ) const
inline

◆ getVariableList()

template<class T, int N>
const Array1D< int > & FTps< T, N >::getVariableList ( int index)
inlinestatic

List of variables contained in monomial "index".

Definition at line 439 of file FTps.hpp.

References FTpsData< N >::getVariableList().

Here is the call graph for this function:

◆ getVariables()

template<class T, int N>
int FTps< T, N >::getVariables ( )
inlinestatic

Get number of variables.

Definition at line 132 of file FTps.h.

◆ gradient()

template<class T, int N>
FVps< T, N > FTps< T, N >::gradient ( ) const

Gradient.

Definition at line 1433 of file FTps.hpp.

References FVps< T, N >::derivative().

Here is the call graph for this function:

◆ grow()

template<class T, int N>
void FTps< T, N >::grow ( int maxOrder,
int trcOrder )
private

Definition at line 1734 of file FTps.hpp.

References allocate(), FTpsRep< T, N >::begin(), deallocate(), FTpsRep< T, N >::end(), ge(), and itsRep.

Referenced by setCoefficient(), setMaxOrder(), setMinOrder(), and setTruncOrder().

Here is the call graph for this function:

◆ integral()

template<class T, int N>
FTps< T, N > FTps< T, N >::integral ( int var,
int trunc = EXACT ) const

Partial integral.

Definition at line 1441 of file FTps.hpp.

References begin(), begin(), EXACT, FTps(), FTpsData< N >::getExponents(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), FTpsData< N >::getProductArray(), FVps< T, N >::getTruncOrder(), globalTruncOrder, orderEnd(), and orderStart().

Here is the call graph for this function:

◆ inverse()

template<class T, int N>
FTps< T, N > FTps< T, N >::inverse ( int trunc = EXACT) const

Reciprocal, 1/(*this).

Definition at line 707 of file FTps.hpp.

References c, FTps(), FTpsData< N >::getProductArray(), globalTruncOrder, itsRep, orderEnd(), orderStart(), and prod().

Referenced by operator/(), FVps< T, N >::operator/=(), pow(), sec(), and sech().

Here is the call graph for this function:

◆ makeMonomial() [1/2]

template<class T, int N>
FTps< T, N > FTps< T, N >::makeMonomial ( const FMonomial< N > & m,
const T & t )
static

Make monomial.

Definition at line 508 of file FTps.hpp.

References EXACT, FTps(), and FMonomial< N >::getOrder().

Here is the call graph for this function:

◆ makeMonomial() [2/2]

template<class T, int N>
FTps< T, N > FTps< T, N >::makeMonomial ( int index,
const T & t )
static

Make monomial.

Definition at line 499 of file FTps.hpp.

References EXACT, FTps(), and FTpsData< N >::getOrder().

Here is the call graph for this function:

◆ makePower()

template<class T, int N>
FTps< T, N > FTps< T, N >::makePower ( int power) const

Multiply FTps with itself.

Definition at line 1555 of file FTps.hpp.

References FTps(), globalTruncOrder, and multiply().

Referenced by FVps< T, N >::operator*().

Here is the call graph for this function:

◆ makeVariable()

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

Make variable.

Definition at line 481 of file FTps.hpp.

References EXACT, and FTps().

Here is the call graph for this function:

◆ makeVarPower()

template<class T, int N>
FTps< T, N > FTps< T, N >::makeVarPower ( int var,
int power )
static

Make power.

Definition at line 489 of file FTps.hpp.

References EXACT, and FTps().

Here is the call graph for this function:

◆ multiply()

template<class T, int N>
FTps< T, N > FTps< T, N >::multiply ( const FTps< T, N > & y,
int trunc = EXACT ) const

Multiplication.

Definition at line 650 of file FTps.hpp.

References begin(), begin(), EXACT, FTps(), FTpsData< N >::getProductArray(), itsRep, orderEnd(), orderStart(), and prod().

Referenced by FVps< T, N >::getFTps(), makePower(), FVps< T, N >::operator*(), operator*(), operator*=(), PoissonBracket(), pow(), and taylor().

Here is the call graph for this function:

◆ multiplyVariable()

template<class T, int N>
FTps< T, N > FTps< T, N >::multiplyVariable ( int var,
int trunc = EXACT ) const

Multiply by variable [b]var[/b].

Definition at line 610 of file FTps.hpp.

References begin(), begin(), EXACT, FTps(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), FTpsData< N >::getProductArray(), FVps< T, N >::getTruncOrder(), and orderStart().

Here is the call graph for this function:

◆ operator!=() [1/2]

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

Inequality operator.

Definition at line 886 of file FTps.hpp.

References FTps().

Here is the call graph for this function:

◆ operator!=() [2/2]

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

Inequality with constant.

Definition at line 892 of file FTps.hpp.

◆ operator*=() [1/2]

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

Multiply and assign.

Definition at line 545 of file FTps.hpp.

References FTps(), and multiply().

Here is the call graph for this function:

◆ operator*=() [2/2]

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

Multiply by constant and assign.

Definition at line 575 of file FTps.hpp.

References begin(), end(), FTps(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), and unique().

Here is the call graph for this function:

◆ operator+()

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

Unary plus.

Definition at line 517 of file FTps.hpp.

References FTps().

Here is the call graph for this function:

◆ operator+=() [1/2]

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

Add and assign.

Definition at line 533 of file FTps.hpp.

References FTps().

Here is the call graph for this function:

◆ operator+=() [2/2]

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

Add constant and assign.

Definition at line 557 of file FTps.hpp.

References FTps(), itsRep, FVps< T, N >::setMinOrder(), and unique().

Here is the call graph for this function:

◆ operator-()

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

Unary minus.

Definition at line 523 of file FTps.hpp.

References begin(), begin(), end(), FTps(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), and FVps< T, N >::getTruncOrder().

Here is the call graph for this function:

◆ operator-=() [1/2]

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

Subtract and assign.

Definition at line 539 of file FTps.hpp.

References FTps().

Here is the call graph for this function:

◆ operator-=() [2/2]

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

Subtract constant and assign.

Definition at line 566 of file FTps.hpp.

References FTps(), itsRep, FVps< T, N >::setMinOrder(), and unique().

Here is the call graph for this function:

◆ operator/=() [1/2]

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

Divide and assign.

Definition at line 551 of file FTps.hpp.

References divide(), and FTps().

Here is the call graph for this function:

◆ operator/=() [2/2]

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

Divide by constant and assign.

Definition at line 583 of file FTps.hpp.

References FTps().

Here is the call graph for this function:

◆ operator=() [1/2]

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

Assign.

Definition at line 201 of file FTps.hpp.

References deallocate(), FTps(), and itsRep.

Here is the call graph for this function:

◆ operator=() [2/2]

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

Convert and assign.

Definition at line 213 of file FTps.hpp.

References allocate(), deallocate(), EXACT, FTps(), and itsRep.

Here is the call graph for this function:

◆ operator==() [1/2]

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

Equality operator.

Definition at line 831 of file FTps.hpp.

References begin(), begin(), FTps(), getMaxOrder(), FVps< T, N >::getMaxOrder(), getMinOrder(), FVps< T, N >::getMinOrder(), getTruncOrder(), FVps< T, N >::getTruncOrder(), itsRep, orderEnd(), and orderStart().

Here is the call graph for this function:

◆ operator==() [2/2]

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

Equality with constant.

Definition at line 867 of file FTps.hpp.

References begin(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), orderEnd(), and orderStart().

Here is the call graph for this function:

◆ operator[]() [1/4]

template<class T, int N>
T & FTps< T, N >::operator[] ( const FMonomial< N > & monomial)

Get (Set) coefficient.

Definition at line 295 of file FTps.hpp.

References FTpsData< N >::getIndex(), itsRep, and unique().

Here is the call graph for this function:

◆ operator[]() [2/4]

template<class T, int N>
const T FTps< T, N >::operator[] ( const FMonomial< N > & monomial) const

Get coefficient.

Definition at line 288 of file FTps.hpp.

References FTpsData< N >::getIndex(), and itsRep.

Here is the call graph for this function:

◆ operator[]() [3/4]

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

Get (Set) coefficient.

Definition at line 281 of file FTps.hpp.

References itsRep, and unique().

Here is the call graph for this function:

◆ operator[]() [4/4]

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

Get coefficient.

Definition at line 275 of file FTps.hpp.

References itsRep.

◆ orderEnd()

template<class T, int N>
int FTps< T, N >::orderEnd ( int order)
inlinestatic

◆ orderLength() [1/2]

template<class T, int N>
int FTps< T, N >::orderLength ( int order)
inlinestatic

Definition at line 151 of file FTps.h.

◆ orderLength() [2/2]

template<class T, int N>
int FTps< T, N >::orderLength ( int orderL,
int orderH )
inlinestatic

Definition at line 155 of file FTps.h.

◆ orderStart()

template<class T, int N>
int FTps< T, N >::orderStart ( int order)
inlinestatic

◆ put()

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

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

Definition at line 1648 of file FTps.hpp.

References begin(), end(), EXACT, FTpsData< N >::getExponents(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), itsRep, and orderStart().

Referenced by FTpsRep< T, N >::FTps< T, N >.

Here is the call graph for this function:

◆ scaleMonomials()

template<class T, int N>
FTps< T, N > FTps< T, N >::scaleMonomials ( const FTps< T, N > & y) const

Scale monomial coefficients by coefficients in [b]y[/b].

Definition at line 589 of file FTps.hpp.

References begin(), begin(), end(), FTps(), getMaxOrder(), FVps< T, N >::getMaxOrder(), getMinOrder(), FVps< T, N >::getMinOrder(), getTruncOrder(), and FVps< T, N >::getTruncOrder().

Here is the call graph for this function:

◆ setCoefficient() [1/2]

template<class T, int N>
void FTps< T, N >::setCoefficient ( const FMonomial< N > & monomial,
const T & value )

Set coefficient.

Definition at line 268 of file FTps.hpp.

References FTpsData< N >::getIndex(), and setCoefficient().

Here is the call graph for this function:

◆ setCoefficient() [2/2]

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

Set coefficient.

Definition at line 236 of file FTps.hpp.

References EXACT, FTpsData< N >::getOrder(), grow(), itsRep, FVps< T, N >::setMaxOrder(), FVps< T, N >::setMinOrder(), and unique().

Referenced by setCoefficient().

Here is the call graph for this function:

◆ setGlobalTruncOrder()

template<class T, int N>
void FTps< T, N >::setGlobalTruncOrder ( int order)
static

Set the global truncation order.

Definition at line 419 of file FTps.hpp.

References EXACT, globalTruncOrder, and FTpsData< N >::setup().

Referenced by opalMain().

Here is the call graph for this function:

◆ setMaxOrder()

template<class T, int N>
void FTps< T, N >::setMaxOrder ( int order)

Set maximum order.

Definition at line 357 of file FTps.hpp.

References EXACT, globalTruncOrder, grow(), itsRep, and unique().

Here is the call graph for this function:

◆ setMinOrder()

template<class T, int N>
void FTps< T, N >::setMinOrder ( int order)

Set minimum order.

Definition at line 321 of file FTps.hpp.

References EXACT, globalTruncOrder, grow(), itsRep, and unique().

Referenced by FVps< T, N >::operator*(), and taylor().

Here is the call graph for this function:

◆ setTruncOrder()

template<class T, int N>
void FTps< T, N >::setTruncOrder ( int order)

Set truncation order.

Definition at line 393 of file FTps.hpp.

References EXACT, globalTruncOrder, grow(), itsRep, and unique().

Referenced by Tracker::buildMultipoleVectorPotential(), Tracker::buildMultipoleVectorPotential2D(), Tracker::buildSBendVectorPotential(), Tracker::buildSBendVectorPotential2D(), ExpMap(), ExpMap(), and taylor().

Here is the call graph for this function:

◆ substitute() [1/4]

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

Substitute.

Definition at line 1302 of file FTps.hpp.

References FTps(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), and FVps< T, N >::substitute().

Here is the call graph for this function:

◆ substitute() [2/4]

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

Substitute.

Definition at line 1075 of file FTps.hpp.

References begin(), begin(), end(), FTps(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), FTpsData< N >::getProductArray(), getSize(), FVps< T, N >::getTruncOrder(), FTpsData< N >::getVariableList(), globalTruncOrder, orderEnd(), orderStart(), and prod().

Here is the call graph for this function:

◆ substitute() [3/4]

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

Substitute.

Definition at line 1174 of file FTps.hpp.

References begin(), begin(), end(), end(), FTps(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), FTpsData< N >::getProductArray(), getSize(), FVps< T, N >::getTruncOrder(), FTpsData< N >::getVariableList(), globalTruncOrder, orderEnd(), orderStart(), and prod().

Here is the call graph for this function:

◆ substitute() [4/4]

template<class T, int N>
FTps< T, N > FTps< T, N >::substitute ( const FVps< T, N > & m,
int trunc = EXACT ) const

Substitute.

Definition at line 1308 of file FTps.hpp.

References begin(), EXACT, FTps(), FVps< T, N >::getMaxOrder(), FVps< T, N >::getMinOrder(), FVps< T, N >::getSubstOrders(), FTpsData< N >::getVariableList(), globalTruncOrder, orderEnd(), and orderStart().

Here is the call graph for this function:

◆ taylor()

template<class T, int N>
FTps< T, N > FTps< T, N >::taylor ( const Array1D< T > & series,
int order ) const

Taylor series.

Definition at line 1481 of file FTps.hpp.

References FTps(), itsRep, multiply(), setMinOrder(), setTruncOrder(), and unique().

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

Here is the call graph for this function:

◆ truncate()

template<class T, int N>
FTps< T, N > FTps< T, N >::truncate ( int trunc)
inline

Truncate.

Definition at line 475 of file FTps.hpp.

References FVps< T, N >::filter(), and FTps().

Here is the call graph for this function:

◆ unique()

template<class T, int N>
void FTps< T, N >::unique ( )
inline

Make representation unique.

Definition at line 1505 of file FTps.hpp.

References allocate(), FTpsRep< T, N >::begin(), FTpsRep< T, N >::end(), itsRep, and FTpsRep< T, N >::ref.

Referenced by operator*=(), operator+=(), operator-=(), operator[](), operator[](), setCoefficient(), setMaxOrder(), setMinOrder(), setTruncOrder(), and taylor().

Here is the call graph for this function:

Member Data Documentation

◆ EXACT

◆ freeList

template<class T, int N>
FTpsRep<T, N>* FTps< T, N >::freeList[100]
staticprivate

Definition at line 409 of file FTps.h.

Referenced by allocate(), and deallocate().

◆ globalTruncOrder

template<class T, int N>
int FTps< T, N >::globalTruncOrder
staticprivate

◆ itsRep


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