Public Member Functions | Private Attributes
adaptiveSolver Class Referenceabstract
Inheritance diagram for adaptiveSolver:
Inheritance graph
[legend]
Collaboration diagram for adaptiveSolver:
Collaboration graph
[legend]

Public Member Functions

 adaptiveSolver (const ODESystem &ode, const dictionary &dict)
 Construct from ODESystem. More...
 
virtual ~adaptiveSolver ()
 Destructor. More...
 
virtual scalar solve (const scalar x0, const scalarField &y0, const scalarField &dydx0, const scalar dx, scalarField &y) const =0
 Solve a single step dx and return the error. More...
 
void solve (const ODESystem &ode, scalar &x, scalarField &y, scalar &dxTry) const
 Solve the ODE system and the update the state. More...
 

Private Attributes

scalar safeScale_
 Step-size adjustment controls. More...
 
scalar alphaInc_
 
scalar alphaDec_
 
scalar minScale_
 
scalar maxScale_
 
scalarField dydx0_
 Cache for dydx at the initial time. More...
 
scalarField yTemp_
 Temprorary for the test-step solution. More...
 

Detailed Description

Source files

Definition at line 47 of file adaptiveSolver.H.

Constructor & Destructor Documentation

◆ adaptiveSolver()

adaptiveSolver ( const ODESystem ode,
const dictionary dict 
)

Construct from ODESystem.

Definition at line 32 of file adaptiveSolver.C.

◆ ~adaptiveSolver()

virtual ~adaptiveSolver ( )
inlinevirtual

Destructor.

Definition at line 70 of file adaptiveSolver.H.

Member Function Documentation

◆ solve() [1/2]

virtual scalar solve ( const scalar  x0,
const scalarField y0,
const scalarField dydx0,
const scalar  dx,
scalarField y 
) const
pure virtual

◆ solve() [2/2]

void solve ( const ODESystem ode,
scalar &  x,
scalarField y,
scalar &  dxTry 
) const

Solve the ODE system and the update the state.

Definition at line 50 of file adaptiveSolver.C.

References ODESystem::derivatives(), Foam::exit(), Foam::FatalError, FatalErrorInFunction, Foam::max(), Foam::min(), Foam::pow(), solve(), x, and y.

Here is the call graph for this function:

Field Documentation

◆ safeScale_

scalar safeScale_
private

Step-size adjustment controls.

Definition at line 52 of file adaptiveSolver.H.

◆ alphaInc_

scalar alphaInc_
private

Definition at line 52 of file adaptiveSolver.H.

◆ alphaDec_

scalar alphaDec_
private

Definition at line 52 of file adaptiveSolver.H.

◆ minScale_

scalar minScale_
private

Definition at line 52 of file adaptiveSolver.H.

◆ maxScale_

scalar maxScale_
private

Definition at line 52 of file adaptiveSolver.H.

◆ dydx0_

scalarField dydx0_
mutableprivate

Cache for dydx at the initial time.

Definition at line 55 of file adaptiveSolver.H.

◆ yTemp_

scalarField yTemp_
mutableprivate

Temprorary for the test-step solution.

Definition at line 58 of file adaptiveSolver.H.


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