|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.opensourcephysics.numerics.AbstractODESolver org.opensourcephysics.numerics.Heun3
public class Heun3
Heun3 implements Heun's third order algorithm for solving ODEs by evaluating the rate at the initial state, and two intermediate states. It then uses a weighted average to advance the state. Heun's method is known as a predictor-corrector method because it first predicts the state (estimated_state) and then corrects the rate based on the prediction.
Field Summary |
---|
Fields inherited from class org.opensourcephysics.numerics.AbstractODESolver |
---|
numEqn, ode, stepSize |
Constructor Summary | |
---|---|
Heun3(ODE ode)
Constructor Heun3 |
Method Summary | |
---|---|
void |
initialize(double stepSize)
Initializes the ODE solver and allocates the rate and state arrays. |
double |
step()
Steps (advances) the differential equations by the stepSize. |
Methods inherited from class org.opensourcephysics.numerics.AbstractODESolver |
---|
getStepSize, setStepSize |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Heun3(ODE ode)
ode
- Method Detail |
---|
public void initialize(double stepSize)
initialize
in interface ODESolver
initialize
in class AbstractODESolver
stepSize
- public double step()
step
in interface ODESolver
step
in class AbstractODESolver
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |