Ember
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
TridiagonalIntegrator Class Reference

Integrator using 1st and 2nd order BDF for tridiagonal systems, with matrix inversions done using the Thomas algorithm. More...

#include <integrator.h>

Inheritance diagram for TridiagonalIntegrator:
[legend]

Public Member Functions

 TridiagonalIntegrator (TridiagonalODE &ode)
 
virtual ~TridiagonalIntegrator ()
 
void set_y0 (const dvec &y0)
 Set the initial condition for the problem.
 
void resize (size_t N_in)
 
void initialize (const double t0, const double h)
 Set up parameters and problem-dependent data structures for the solver.
 
const dvecget_ydot ()
 Get the time derivative of the current state vector.
 
void step ()
 Take a single step using the current step size.
 
- Public Member Functions inherited from Integrator
 Integrator ()
 
virtual ~Integrator ()
 
virtual void set_y0 (const dvec &y0)
 Set the initial condition for the problem.
 
virtual void initialize (const double t0, const double h)
 Set up parameters and problem-dependent data structures for the solver.
 
double get_h () const
 Get the last step size used.
 
double get_t () const
 Get the current time reached by the integrator.
 
virtual const dvecget_y () const
 Get the current state vector.
 
virtual const dvecget_ydot ()=0
 Get the time derivative of the current state vector.
 
virtual void step ()=0
 Take a single step using the current step size.
 
virtual void integrateToTime (double tEnd)
 Take as many steps as necessary to reach tEnd without stepping past it.
 

Private Attributes

TridiagonalODEmyODE
 
dvec a
 subdiagonal components of right-hand-side
 
dvec b
 diagonal components of right-hand-side
 
dvec c
 superdiagonal components of right-hand-side
 
dvec k
 constant contribution to ‘y’`
 
dvec lu_b
 
dvec lu_c
 
dvec lu_d
 
dvec invDenom_
 
unsigned int stepCount
 the number of steps taken since last initialization
 
int N
 The system size.
 
dvec yprev
 previous solution
 

Additional Inherited Members

- Public Attributes inherited from Integrator
dvec y
 solution vector
 
dvec ydot
 derivative of state vector
 
double t
 current time
 
- Protected Attributes inherited from Integrator
double h
 timestep
 
size_t N
 Dimension of y.
 

Detailed Description

Integrator using 1st and 2nd order BDF for tridiagonal systems, with matrix inversions done using the Thomas algorithm.

Constructor & Destructor Documentation

◆ TridiagonalIntegrator()

TridiagonalIntegrator::TridiagonalIntegrator ( TridiagonalODE ode)

◆ ~TridiagonalIntegrator()

virtual TridiagonalIntegrator::~TridiagonalIntegrator ( )
inlinevirtual

Member Function Documentation

◆ set_y0()

void TridiagonalIntegrator::set_y0 ( const dvec y0)
virtual

Set the initial condition for the problem.

Must be called before starting integration.

Reimplemented from Integrator.

◆ resize()

void TridiagonalIntegrator::resize ( size_t  N_in)

◆ initialize()

void TridiagonalIntegrator::initialize ( const double  t0,
const double  h 
)
virtual

Set up parameters and problem-dependent data structures for the solver.

Must be called before starting integration.

Parameters
t0Start time for the integration
hinitial step size

Reimplemented from Integrator.

◆ get_ydot()

const dvec & TridiagonalIntegrator::get_ydot ( )
virtual

Get the time derivative of the current state vector.

Implements Integrator.

◆ step()

void TridiagonalIntegrator::step ( )
virtual

Take a single step using the current step size.

Implements Integrator.

Member Data Documentation

◆ myODE

TridiagonalODE& TridiagonalIntegrator::myODE
private

◆ a

dvec TridiagonalIntegrator::a
private

subdiagonal components of right-hand-side

◆ b

dvec TridiagonalIntegrator::b
private

diagonal components of right-hand-side

◆ c

dvec TridiagonalIntegrator::c
private

superdiagonal components of right-hand-side

◆ k

dvec TridiagonalIntegrator::k
private

constant contribution to ‘y’`

◆ lu_b

dvec TridiagonalIntegrator::lu_b
private

◆ lu_c

dvec TridiagonalIntegrator::lu_c
private

◆ lu_d

dvec TridiagonalIntegrator::lu_d
private

◆ invDenom_

dvec TridiagonalIntegrator::invDenom_
private

◆ stepCount

unsigned int TridiagonalIntegrator::stepCount
private

the number of steps taken since last initialization

◆ N

int TridiagonalIntegrator::N
private

The system size.

◆ yprev

dvec TridiagonalIntegrator::yprev
private

previous solution


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