|
Chaste Release::3.1
|
#include <EulerIvpOdeSolver.hpp>
Inheritance diagram for EulerIvpOdeSolver:
Collaboration diagram for EulerIvpOdeSolver:Public Member Functions | |
| EulerIvpOdeSolver () | |
| virtual | ~EulerIvpOdeSolver () |
Protected Member Functions | |
| void | CalculateNextYValue (AbstractOdeSystem *pAbstractOdeSystem, double timeStep, double time, std::vector< double > &rCurrentYValues, std::vector< double > &rNextYValues) |
Private Member Functions | |
| template<class Archive > | |
| void | serialize (Archive &archive, const unsigned int version) |
Friends | |
| class | boost::serialization::access |
A concrete one step ODE solver class that employs the forward Euler method. This numerical method is explicit.
Definition at line 49 of file EulerIvpOdeSolver.hpp.
| EulerIvpOdeSolver::EulerIvpOdeSolver | ( | ) | [inline] |
Constructor.
Definition at line 94 of file EulerIvpOdeSolver.hpp.
| virtual EulerIvpOdeSolver::~EulerIvpOdeSolver | ( | ) | [inline, virtual] |
Destructor.
Definition at line 100 of file EulerIvpOdeSolver.hpp.
| void EulerIvpOdeSolver::CalculateNextYValue | ( | AbstractOdeSystem * | pAbstractOdeSystem, |
| double | timeStep, | ||
| double | time, | ||
| std::vector< double > & | rCurrentYValues, | ||
| std::vector< double > & | rNextYValues | ||
| ) | [protected, virtual] |
Calculate the solution to the ODE system at the next timestep.
A usage example: EulerIvpOdeSolver mySolver; OdeSolution solution = mySolver.Solve(pMyOdeSystem, yInit, StartTime, EndTime, TimeStep, SamplingTime);
| pAbstractOdeSystem | the ODE system to solve |
| timeStep | dt |
| time | the current time |
| rCurrentYValues | the current (initial) state |
| rNextYValues | the state at the next timestep |
Implements AbstractOneStepIvpOdeSolver.
Definition at line 38 of file EulerIvpOdeSolver.cpp.
References AbstractOdeSystem::EvaluateYDerivatives(), and AbstractUntemplatedParameterisedSystem::GetNumberOfStateVariables().
| void EulerIvpOdeSolver::serialize | ( | Archive & | archive, |
| const unsigned int | version | ||
| ) | [inline, private] |
Archive the abstract IVP Solver, never used directly - boost uses this.
| archive | the archive |
| version | the current version of this class |
Reimplemented from AbstractOneStepIvpOdeSolver.
Reimplemented in MockEulerIvpOdeSolver.
Definition at line 62 of file EulerIvpOdeSolver.hpp.
friend class boost::serialization::access [friend] |
Needed for serialization.
Reimplemented from AbstractOneStepIvpOdeSolver.
Reimplemented in MockEulerIvpOdeSolver.
Definition at line 54 of file EulerIvpOdeSolver.hpp.