80 y[i] = y0[i] + dx*dydx0[i];
90 y[i] = y0[i] + 0.5*dx*(dydx0[i] + err_[i]);
91 err_[i] = 0.5*dx*(err_[i] - dydx0[i]);
#define forAll(list, i)
Loop across all elements in list.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Abstract base class for the systems of ordinary differential equations.
virtual bool resize()=0
Resize the ODE solver.
A list of keyword definitions, which are a keyword followed by any number of values (e...
virtual void derivatives(const scalar x, const scalarField &y, const label li, scalarField &dydx) const =0
Calculate the derivatives in dydx.
An ODE solver for chemistry.
scalar normaliseError(const scalarField &y0, const scalarField &y, const scalarField &err) const
Return the normalised scalar error.
Macros for easy insertion into run-time selection tables.
bool resize(const label n)
Resize the ODE solver.
const ODESystem & odes_
Reference to ODESystem.
virtual scalar solve(const scalar x0, const scalarField &y0, const label li, const scalarField &dydx0, const scalar dx, scalarField &y) const
Solve a single step dx and return the error.
addToRunTimeSelectionTable(ensightPart, ensightPartCells, istream)
defineTypeNameAndDebug(combustionModel, 0)
Abstract base-class for ODE system solvers.
static void resizeField(UList< Type > &f, const label n)
Trapezoid(const ODESystem &ode, const dictionary &dict)
Construct from ODESystem.
virtual scalar solve(const scalar x0, const scalarField &y0, const label li, const scalarField &dydx0, const scalar dx, scalarField &y) const =0
Solve a single step dx and return the error.
label n_
Size of the ODESystem (adjustable)
virtual bool resize()
Resize the ODE solver.