Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of Boost. Click here to view this page for the latest version.
Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext

Class template default_error_checker

boost::numeric::odeint::default_error_checker — The default error checker to be used with Runge-Kutta error steppers.

Synopsis

// In header: <boost/numeric/odeint/stepper/controlled_runge_kutta.hpp>

template<typename Value, typename Algebra, typename Operations> 
class default_error_checker {
public:
  // types
  typedef Value      value_type;     
  typedef Algebra    algebra_type;   
  typedef Operations operations_type;

  // construct/copy/destruct
  default_error_checker(value_type = static_cast< value_type >(1.0e-6), 
                        value_type = static_cast< value_type >(1.0e-6), 
                        value_type = static_cast< value_type >(1), 
                        value_type = static_cast< value_type >(1));

  // public member functions
  template<typename State, typename Deriv, typename Err, typename Time> 
    value_type error(const State &, const Deriv &, Err &, Time) const;
  template<typename State, typename Deriv, typename Err, typename Time> 
    value_type error(algebra_type &, const State &, const Deriv &, Err &, 
                     Time) const;
};

Description

This class provides the default mechanism to compare the error estimates reported by Runge-Kutta error steppers with user defined error bounds. It is used by the controlled_runge_kutta steppers.

Template Parameters

  1. typename Value

    The value type.

  2. typename Algebra

    The algebra type.

  3. typename Operations

    The operations type.

default_error_checker public construct/copy/destruct

  1. default_error_checker(value_type eps_abs = static_cast< value_type >(1.0e-6), 
                          value_type eps_rel = static_cast< value_type >(1.0e-6), 
                          value_type a_x = static_cast< value_type >(1), 
                          value_type a_dxdt = static_cast< value_type >(1));

default_error_checker public member functions

  1. template<typename State, typename Deriv, typename Err, typename Time> 
      value_type error(const State & x_old, const Deriv & dxdt_old, Err & x_err, 
                       Time dt) const;
  2. template<typename State, typename Deriv, typename Err, typename Time> 
      value_type error(algebra_type & algebra, const State & x_old, 
                       const Deriv & dxdt_old, Err & x_err, Time dt) const;

PrevUpHomeNext