Reaktoro
A unified framework for modeling chemically reactive systems
DaeSolver Class Reference

A class for solving differential-algebraic equations (DAE). More...

#include <DaeSolver.hpp>

Public Member Functions

 DaeSolver ()
 Construct a default DaeSolver instance.
 
 DaeSolver (const DaeSolver &other)
 Construct a copy of an DaeSolver instance.
 
virtual ~DaeSolver ()
 Destroy this DaeSolver instance.
 
auto operator= (DaeSolver other) -> DaeSolver &
 Assign a DaeSolver instance to this instance.
 
auto setOptions (const DaeOptions &options) -> void
 Set the options for the ODE solver. More...
 
auto setProblem (const DaeProblem &problem) -> void
 Set the ODE problem. More...
 
auto initialize (double tstart, VectorConstRef y) -> void
 Initializes the ODE solver. More...
 
auto integrate (double &t, VectorRef y) -> void
 Integrate the ODE performing a single step. More...
 
auto integrate (double &t, VectorRef y, double tfinal) -> void
 Integrate the ODE performing a single step not going over a given time. More...
 
auto solve (double &t, double dt, VectorRef y) -> void
 Solve the ODE equations from a given start time to a final one. More...
 

Detailed Description

A class for solving differential-algebraic equations (DAE).

See also
DaeProblem, DaeOptions

Member Function Documentation

◆ setOptions()

auto setOptions ( const DaeOptions options) -> void

Set the options for the ODE solver.

See also
DaeOptions

◆ setProblem()

auto setProblem ( const DaeProblem problem) -> void

Set the ODE problem.

See also
DaeProblem

◆ initialize()

auto initialize ( double  tstart,
VectorConstRef  y 
) -> void

Initializes the ODE solver.

This method should be invoked whenever the user intends to make a call to DaeSolver::integrate.

Parameters
tstartThe start time of the integration.
yThe initial values of the variables

◆ integrate() [1/2]

auto integrate ( double &  t,
VectorRef  y 
) -> void

Integrate the ODE performing a single step.

Parameters
[in,out]tThe current time of the integration as input, the new current time as output
[in,out]yThe current variables as input, the new current variables as output

◆ integrate() [2/2]

auto integrate ( double &  t,
VectorRef  y,
double  tfinal 
) -> void

Integrate the ODE performing a single step not going over a given time.

Parameters
[in,out]tThe current time of the integration as input, the new current time as output
[in,out]yThe current variables as input, the new current variables as output
tfinalThe final time that the integration must satisfy

◆ solve()

auto solve ( double &  t,
double  dt,
VectorRef  y 
) -> void

Solve the ODE equations from a given start time to a final one.

Parameters
[in,out]tThe current time of the integration as input, the new current time as output
dtThe value of the time step
[in,out]yThe current variables as input, the new current variables as output

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