Tatooine
rungekuttadopri5.h
Go to the documentation of this file.
1#ifndef TATOOINE_ODE_BOOST_RUNGEKUTTADOPRI5_H
2#define TATOOINE_ODE_BOOST_RUNGEKUTTADOPRI5_H
3//==============================================================================
4#include <tatooine/concepts.h>
7
8#include <boost/numeric/odeint/stepper/controlled_runge_kutta.hpp>
9#include <boost/numeric/odeint/stepper/runge_kutta_dopri5.hpp>
10//==============================================================================
11namespace tatooine::ode::boost {
12//==============================================================================
13template <typename Real, std::size_t N>
14struct rkd5_aux {
16 ::boost::numeric::odeint::runge_kutta_dopri5<vec<Real, N>>;
18 domain_error_checker<Real, typename stepper_type::algebra_type,
19 typename stepper_type::operations_type>;
21 ::boost::numeric::odeint::controlled_runge_kutta<stepper_type,
23};
24//==============================================================================
25template <typename Real, std::size_t N>
28 Real, N, typename rkd5_aux<Real, N>::controller_type> {
31 rungekuttadopri5(Real const absolute_error_tolerance = 1e-10,
32 Real const relative_error_tolerance = 1e-6,
33 Real const initial_stepsize = 0.01, Real const a_x = 1,
34 Real const a_dxdt = 1)
35 : tatooine::ode::boost::solver<Real, N, controller_type>(
36 controller_type{error_checker_type{absolute_error_tolerance,
37 relative_error_tolerance, a_x,
38 a_dxdt}},
39 initial_stepsize) {}
40};
41//==============================================================================
42} // namespace tatooine::ode::boost
43//==============================================================================
44#endif
Definition: domain_error_checker.h:11
Definition: solver.h:9
Definition: controller_runge_kutta_with_domain_check.h:19
Definition: algorithm.h:6
Definition: rungekuttadopri5.h:14
::boost::numeric::odeint::runge_kutta_dopri5< vec< Real, N > > stepper_type
Definition: rungekuttadopri5.h:16
::boost::numeric::odeint::controlled_runge_kutta< stepper_type, error_checker_type > controller_type
Definition: rungekuttadopri5.h:22
Definition: rungekuttadopri5.h:28
typename rkd5_aux< Real, N >::controller_type controller_type
Definition: rungekuttadopri5.h:29
typename rkd5_aux< Real, N >::error_checker_type error_checker_type
Definition: rungekuttadopri5.h:30
rungekuttadopri5(Real const absolute_error_tolerance=1e-10, Real const relative_error_tolerance=1e-6, Real const initial_stepsize=0.01, Real const a_x=1, Real const a_dxdt=1)
Definition: rungekuttadopri5.h:31
Definition: solver.h:22