template <class T, int N>
class vtb::core::Fixed_point_iteration_yule_walker_solver

Multi-dimensional solver that determines MA model coefficients from ACF. The solver uses fixed point iteration to find the coefficients.

Base classes
Types
  • using pointer = std::unique_ptr< Yule_walker_solver< T, N > >
  • using array_type = blitz::Array< T, N >

    Three-dimensional array type.

  • using value_type = T

    Array element type.

  • using shape_type = blitz::TinyVector< int, N >
Methods
  • min_white_noise_variance_delta() const -> T

    Minimal white noise variance difference between iterations.

  • min_white_noise_variance_delta(T rhs) -> void
  • min_white_noise_variance() const -> T
  • min_white_noise_variance(T rhs) -> void

    Minimal white noise variance. White noise variance, that is lower than this value, is considered to be nought.

  • max_residual(T rhs) -> void
  • max_residual() const -> T
  • max_iterations(int rhs) -> void
  • max_iterations() const -> int

    Maximum number of iterations.

  • order() const -> const shape_type &

    Moving average model order.

  • order(const shape_type & rhs) -> void
  • copy() const -> pointervirtual
  • solve(array_type acf) -> array_typevirtual

    Solve Yule—Walker system of equations.

    acf
    autocovariance function

    1. Precompute white noise variance for the first iteration.
    2. Update coefficients from back to front using the following formula (adapted from G. Box and G. Jenkins (1970) "Time Series Analysis: Forecasting and Control", pp. 226–227). Here .
    3. Ensure that coefficients are finite.
    4. Calculate residual. Here .
    5. Compute white noise variance by calling moving_average_white_noise_variance.
    6. Validate white noise variance.

    Return
    three-dimensional array of coefficients
template <class T>
class vtb::core::Autocovariance_matrix_generator< T, 4 >
Methods
  • operator()() -> matrix_type
  • AC_matrix_block(int i0) -> matrix_type
  • AC_matrix_block(int i0, int j0) -> matrix_type
  • AC_matrix_block(int i0, int j0, int k0) -> matrix_type
  • Autocovariance_matrix_generator(const array_type & acf, const shape_type & ar_order)
template <class T, int N>
class vtb::core::Autocovariance_matrix_generator

Autocovariate matrix generator that reduces the size of ACF to match AR model order.

template <class T, int N>
class vtb::core::Gauss_yule_walker_solver
Base classes
Types
  • using pointer = std::unique_ptr< Yule_walker_solver< T, N > >
  • using array_type = blitz::Array< T, N >

    Three-dimensional array type.

  • using value_type = T

    Array element type.

Methods
template <class T, int N>
class vtb::core::Choi_yule_walker_solver

Computes AR model coefficients using an order-recursvive method from [2]. The AR model order is determined automatically. The algorithm works for square ACFs (i.e. ACF with the same number of points along each dimension).

Base classes
Types
  • using pointer = std::unique_ptr< Yule_walker_solver< T, N > >
  • using array_type = blitz::Array< T, N >

    Three-dimensional array type.

  • using value_type = T

    Array element type.

Methods
  • min_variance() const -> T

    Minimum variance. Reaching this value stops computations.

  • min_variance(T rhs) -> void
  • max_order() const -> int

    Maximum AR model order.

  • max_order(int rhs) -> void
  • var_epsilon(value_type rhs) -> void
  • var_epsilon() const -> value_type

    Maximum variance difference between subsequent algorithm iterations. The algorithm stops when .

  • chop_epsilon(value_type rhs) -> void
  • chop_epsilon() const -> value_type

    Maximum ACF value. Smaller values are considered noughts and are removed from the end of ACF.

  • do_not_chop() -> void
  • chop() const -> bool

    Determines whether to chop the result removing adjacent values smaller than from the end of the resulting ACF.

  • chop(bool rhs) -> void
  • do_not_determine_the_order() -> void
  • determine_the_order(bool rhs) -> void
  • determine_the_order() const -> bool

    Determine the order of AR model automatically by comparing the variance in subsequent algorithm iterations.

  • copy() const -> pointervirtual
  • solve(array_type acf) -> array_typevirtual

    Solve Yule—Walker system of equations. Initial stage.

    Return
    three-dimensional array of coefficients
  • operator=(const Choi_yule_walker_solver &) -> Choi_yule_walker_solver &
  • Choi_yule_walker_solver(const Choi_yule_walker_solver &)
  • ~Choi_yule_walker_solver()
  • Choi_yule_walker_solver()
template <class T>
class vtb::core::Autocovariance_matrix_generator< T, 3 >
Methods
  • operator()() -> matrix_type
  • AC_matrix_block(int i0) -> matrix_type
  • AC_matrix_block(int i0, int j0) -> matrix_type
  • Autocovariance_matrix_generator(const array_type & acf, const shape_type & ar_order)
template <class T, int N>
class vtb::core::Yule_walker_solver
Derived classes
Types
  • using pointer = std::unique_ptr< Yule_walker_solver< T, N > >
  • using array_type = blitz::Array< T, N >

    Three-dimensional array type.

  • using value_type = T

    Array element type.

Methods
  • white_noise_variance(value_type rhs) -> voidprotected
  • white_noise_variance() const -> value_type

    White noise variance, calculated by the algorithm.

  • operator()(array_type acf) -> array_type

    Solve Yule—Walker system of equations.

    acf
    autocovariance function

    Return
    three-dimensional array of coefficients
  • copy() const -> pointervirtual
  • solve(array_type acf) -> array_typevirtual

    Solve Yule—Walker system of equations.

    acf
    autocovariance function

    Return
    three-dimensional array of coefficients
  • ~Yule_walker_solver()virtual
  • operator=(const Yule_walker_solver &) -> Yule_walker_solver &
  • Yule_walker_solver(const Yule_walker_solver &)
  • Yule_walker_solver()
template <class T>
chop_right(const blitz::Array< T, 4 > & rhs, T eps) -> blitz::TinyVector< int, 4 >
template <class T, int N>
moving_average_white_noise_variance(const blitz::Array< T, N > & acf, const blitz::Array< T, N > & theta) -> T

Compute white noise variance via the formula assuming .

template <class T, int N>
acf_variance(const blitz::Array< T, N > & acf) -> T
template <class T, int N>
autoregression_white_noise_variance(const blitz::Array< T, N > & acf, const blitz::Array< T, N > & phi) -> T
template <class T>
chop_right(const blitz::Array< T, 3 > & rhs, T eps) -> blitz::TinyVector< int, 3 >