ModelSpace
Documentation for ModelSpace models and classes.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
cfspp::ForwardEulerIntegrator< N > Class Template Reference

#include <ForwardEulerIntegrator.hpp>

Inheritance diagram for cfspp::ForwardEulerIntegrator< N >:

Public Member Functions

 ForwardEulerIntegrator (Rates< N > &rate_calculator)
 
int16 step (floating_point start_time, floating_point end_time, const std::array< floating_point, N > &start_state, std::array< floating_point, N > &out_state) override
 
- Public Member Functions inherited from cfspp::Integrator< N >
 Integrator (Rates< N > &rate_calculator)
 Constructor for the integrator. More...
 

Protected Attributes

floating_point _step_size = 1.0
 Step size for integrator. More...
 
int16 _error = 0
 Error code. More...
 
std::array< floating_point, N > _rates
 
- Protected Attributes inherited from cfspp::Integrator< N >
Rates< N > & _rate_calculator
 Reference to dynamics object that calculates rates. More...
 

Constructor & Destructor Documentation

◆ ForwardEulerIntegrator()

template<uint32 N>
cfspp::ForwardEulerIntegrator< N >::ForwardEulerIntegrator ( Rates< N > &  rate_calculator)

Member Function Documentation

◆ step()

template<uint32 N>
int16 cfspp::ForwardEulerIntegrator< N >::step ( floating_point  start_time,
floating_point  end_time,
const std::array< floating_point, N > &  start_state,
std::array< floating_point, N > &  out_state 
)
overridevirtual

Function to step the integrator forward from time start to time end

Parameters
start_timeStart time for integration
end_timeEnd time for integration
start_stateState at start of integration
out_stateOutput state via implicit – result of integration
Returns
Error code describing success/failure

Reimplemented from cfspp::Integrator< N >.

Member Data Documentation

◆ _error

template<uint32 N>
int16 cfspp::ForwardEulerIntegrator< N >::_error = 0
protected

Error code.

◆ _rates

template<uint32 N>
std::array<floating_point, N> cfspp::ForwardEulerIntegrator< N >::_rates
protected

◆ _step_size

template<uint32 N>
floating_point cfspp::ForwardEulerIntegrator< N >::_step_size = 1.0
protected

Step size for integrator.


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