Helios++
Helios software for LiDAR simulations
fluxionum::FixedParametricIterativeEulerMethod< A, B > Class Template Reference

Fixed parametric iterative Euler method. More...

#include <FixedParametricIterativeEulerMethod.h>

Inheritance diagram for fluxionum::FixedParametricIterativeEulerMethod< A, B >:
Collaboration diagram for fluxionum::FixedParametricIterativeEulerMethod< A, B >:

Public Member Functions

 FixedParametricIterativeEulerMethod (Function< A, arma::Col< B >> &dydt, A const &t0, arma::Col< B > const &y0, arma::Col< A > const &ta, arma::Mat< B > const &ya, size_t const i=0)
 FixedParametricIterativeEulerMethod default constructor. More...
 
arma::Col< B > eval (A const &h) override
 Compute the parametric iterative Euler method but considering given fixed frontiers. More...
 
void restart () override
 
size_t getCurrentPieceIndex () const
 Obtain the index identifying the current piece. More...
 
void setCurrentPieceIndex (size_t const i)
 Set the index identifying the current piece. More...
 
- Public Member Functions inherited from fluxionum::ParametricIterativeEulerMethod< A, B >
 ParametricIterativeEulerMethod (Function< A, arma::Col< B >> &dydt, A const &t0, arma::Col< B > const &y0)
 ParametricIterativeEulerMethod default constructor. More...
 
arma::Col< B > eval (A const &h) override
 Iteratively compute the next value using Euler method. More...
 
Function< A, B > const & getDydt () const
 
getT () const
 
void setT (A const t)
 
getT0 () const
 
arma::Col< B > getY () const
 
void setY (arma::Col< B > const y)
 
arma::Col< B > getY0 () const
 
- Public Member Functions inherited from fluxionum::Function< A, arma::Col< B > >
 Function ()=default
 
arma::Col< B > operator() (A const &x)
 Evaluate the function \(f(x)=y\). More...
 

Protected Attributes

arma::Col< A > const & ta
 The \(m\) frontiers such that \(\forall t,\, \exists i \ni t \in [a_i, a_{i+1})\). For the last frontier, the interval is \([a_{m}, \infty)\).
 
arma::Mat< B > const & ya
 The value of \(\vec{y}(t_i)\) at each of the \(m\) frontiers such that \(\forall i,\, \vec{y_i} = \left(y_{i1}, \ldots, y_{in}\right)\).
 
size_t i
 The index of the current piece. More...
 
- Protected Attributes inherited from fluxionum::ParametricIterativeEulerMethod< A, B >
Function< A, arma::Col< B > > & dydt
 Reference to the parametric derivative function. More...
 
t0
 The initial value of \(t\), \(t_0\). More...
 
t
 The current value of \(t\). More...
 
arma::Col< B > y0
 The initial value of \(\vec{y}\), \(\vec{y}(t_0)\). More...
 
arma::Col< B > y
 The current value of \(\vec{y}(t)\). More...
 

Detailed Description

template<typename A, typename B>
class fluxionum::FixedParametricIterativeEulerMethod< A, B >

Fixed parametric iterative Euler method.

Author
Alberto M. Esmoris Pena
Version
1.0

It is like the ParametricIterativeEulerMethod, but the values at the frontiers are given and thus can be used to fix/correct the function value at those points. This helps preserving the stability of the approximation, specially for those cases which have a significant number of frontiers

See also
fluxionum::ParametricIterativeEulerMethod
fluxionum::FixedIterativeEulerMethod
fluxionum::Function

Constructor & Destructor Documentation

◆ FixedParametricIterativeEulerMethod()

template<typename A , typename B >
fluxionum::FixedParametricIterativeEulerMethod< A, B >::FixedParametricIterativeEulerMethod ( Function< A, arma::Col< B >> &  dydt,
A const &  t0,
arma::Col< B > const &  y0,
arma::Col< A > const &  ta,
arma::Mat< B > const &  ya,
size_t const  i = 0 
)
inline

FixedParametricIterativeEulerMethod default constructor.

Parameters
iThe index of the initial piece for the iterative method. By default, it is assumed to be 0, it is the first piece.
See also
ParametricIterativeEulerMethod::ParametricIterativeEulerMethod
FixedParametricIterativeEulerMethod::ta
FixedParametricIterativeEulerMethod::ya
FixedParametricIterativeEulerMethod::i

Member Function Documentation

◆ eval()

template<typename A , typename B >
arma::Col<B> fluxionum::FixedParametricIterativeEulerMethod< A, B >::eval ( A const &  h)
inlineoverridevirtual

Compute the parametric iterative Euler method but considering given fixed frontiers.

Parameters
hThe step between current \(t_i\) and next \(t_{i+1}\) such that \(h = t_{i+1} - t_i\)
See also
fluxionum::ParametricIterativeEulerMethod::eval

Implements fluxionum::Function< A, arma::Col< B > >.

◆ getCurrentPieceIndex()

template<typename A , typename B >
size_t fluxionum::FixedParametricIterativeEulerMethod< A, B >::getCurrentPieceIndex ( ) const
inline

Obtain the index identifying the current piece.

See also
fluxionum::FixedParametricIterativeEulerMethod::i

◆ restart()

template<typename A , typename B >
void fluxionum::FixedParametricIterativeEulerMethod< A, B >::restart ( )
inlineoverridevirtual

◆ setCurrentPieceIndex()

template<typename A , typename B >
void fluxionum::FixedParametricIterativeEulerMethod< A, B >::setCurrentPieceIndex ( size_t const  i)
inline

Set the index identifying the current piece.

See also
fluxionum::FixedParametricIterativeEulerMethod::i

Member Data Documentation

◆ i

template<typename A , typename B >
size_t fluxionum::FixedParametricIterativeEulerMethod< A, B >::i
protected

The index of the current piece.

\[ i : t_{i} \in [a_{i}, a_{i+1}) \]


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