boost::numeric::odeint::dense_output_runge_kutta<Stepper, stepper_tag> — The class representing dense-output Runge-Kutta steppers.
// In header: <boost/numeric/odeint/stepper/dense_output_runge_kutta.hpp> template<typename Stepper> class dense_output_runge_kutta<Stepper, stepper_tag> { public: // types typedef Stepper stepper_type; typedef stepper_type::state_type state_type; typedef stepper_type::wrapped_state_type wrapped_state_type; typedef stepper_type::value_type value_type; typedef stepper_type::deriv_type deriv_type; typedef stepper_type::wrapped_deriv_type wrapped_deriv_type; typedef stepper_type::time_type time_type; typedef stepper_type::algebra_type algebra_type; typedef stepper_type::operations_type operations_type; typedef stepper_type::resizer_type resizer_type; typedef dense_output_stepper_tag stepper_category; typedef dense_output_runge_kutta< Stepper > dense_output_stepper_type; // construct/copy/destruct dense_output_runge_kutta(const stepper_type & = stepper_type()); // public member functions template<typename StateType> void initialize(const StateType &, time_type, time_type); template<typename System> std::pair< time_type, time_type > do_step(System); template<typename StateOut> void calc_state(time_type, StateOut &) const; template<typename StateOut> void calc_state(time_type, const StateOut &) const; template<typename StateType> void adjust_size(const StateType &); const state_type & current_state(void) const; time_type current_time(void) const; const state_type & previous_state(void) const; time_type previous_time(void) const; // private member functions state_type & get_current_state(void); const state_type & get_current_state(void) const; state_type & get_old_state(void); const state_type & get_old_state(void) const; void toggle_current_state(void); template<typename StateIn> bool resize_impl(const StateIn &); };
Note | |
---|---|
In this stepper, the initialize method has to be called before using the do_step method. |
The dense-output functionality allows to interpolate the solution between subsequent integration points using intermediate results obtained during the computation. This version works based on a normal stepper without step-size control.
dense_output_runge_kutta
public member functionstemplate<typename StateType> void initialize(const StateType & x0, time_type t0, time_type dt0);Initializes the stepper. Has to be called before do_step can be used to set the initial conditions and the step size.
Parameters: |
|
template<typename System> std::pair< time_type, time_type > do_step(System system);Does one time step.
Note | |
---|---|
initialize has to be called before using this method to set the initial conditions x,t and the stepsize. |
Parameters: |
|
||
Returns: |
Pair with start and end time of the integration step. |
template<typename StateOut> void calc_state(time_type t, StateOut & x) const;Calculates the solution at an intermediate point.
Parameters: |
|
template<typename StateOut> void calc_state(time_type t, const StateOut & x) const;Calculates the solution at an intermediate point. Solves the forwarding problem.
Parameters: |
|
template<typename StateType> void adjust_size(const StateType & x);Adjust the size of all temporaries in the stepper manually.
Parameters: |
|
const state_type & current_state(void) const;Returns the current state of the solution.
Returns: |
The current state of the solution x(t). |
time_type current_time(void) const;Returns the current time of the solution.
Returns: |
The current time of the solution t. |
const state_type & previous_state(void) const;Returns the last state of the solution.
Returns: |
The last state of the solution x(t-dt). |
time_type previous_time(void) const;Returns the last time of the solution.
Returns: |
The last time of the solution t-dt. |