Class CompositeStochasticProcess
Defined in File composite_stochastic_process.hpp
Inheritance Relationships
Base Type
public otyca::StochasticProcess
(Class StochasticProcess)
Class Documentation
-
class CompositeStochasticProcess : public otyca::StochasticProcess
A composite stochastic process combining multiple StochasticProcess components.
This class represents a collection of stochastic processes, allowing the user to build complex models by combining simpler components. Each component can contribute to the overall characteristic function and its derivatives.
Public Functions
-
inline virtual CompositeStochasticProcess *clone() const
Clone this process.
- Returns:
A deep copy of the current CompositeStochasticProcess instance.
-
inline CompositeStochasticProcess()
Default constructor.
-
inline CompositeStochasticProcess(const CompositeStochasticProcess &other)
Copy constructor.
- Parameters:
other – The process to copy from.
-
virtual arma::cx_mat characteristic_function(const arma::cx_colvec &u, const arma::rowvec &t) const override
Computes the characteristic function.
- Parameters:
u – Complex-valued column vector of Fourier arguments.
t – Row vector of time points.
- Returns:
A characteristic function matrix where rows correspond to u and columns to t.
-
virtual std::vector<arma::cx_mat> characteristic_function_derivatives(const arma::cx_colvec &u, const arma::rowvec &t) const override
Computes the characteristic function’s derivatives to process parameters.
- Parameters:
u – Complex-valued column vector of Fourier arguments.
t – Row vector of time points.
- Returns:
A vector of characteristic function matrices with each matrix is the characteristic function’s derivatives to each process parameter
Add a component process to the composite.
- Parameters:
component – Shared pointer to a StochasticProcess instance.
-
virtual void set_transformed_calibration_parameters(const std::vector<double> &transformed_parameters)
Set transformed parameters for all components.
- Parameters:
transformed_parameters – A flat vector of transformed parameters.
-
virtual void set_calibration_parameters(const std::vector<double> ¶meters)
set the calibration parameters.
- Parameters:
calibration_parameters – the calibration parameters
-
virtual void set_parameters(const std::vector<double> ¶meters)
Set raw (untransformed) parameters for all components.
- Parameters:
parameters – A flat vector of raw parameters.
-
virtual std::vector<double> get_transformed_calibration_parameters() const
Get the transformed parameters of the composite process.
- Returns:
A flat vector of all transformed parameters.
-
virtual std::vector<double> get_calibration_parameters() const
Get the calibration parameters of the composite process.
- Returns:
A flat vector of all calibration parameters.
-
virtual std::vector<double> transformation_derivatives() const
Get the derivatives of the transformation function.
- Returns:
A vector of partial derivatives of the transformation with respect to the parameters.
-
virtual std::vector<double> get_parameters() const
Get raw parameters of the composite process.
- Returns:
A flat vector of raw parameters.
-
virtual std::vector<std::string> get_parameter_names() const
Get names of parameters in the composite process.
- Returns:
A vector of parameter names.
-
virtual std::vector<double> get_transformed_calibration_parameter_variances() const
Get variances of the transformed parameters.
- Returns:
A vector of parameter variances.
-
virtual std::string name() const
Get a human-readable name of this process.
- Returns:
Name string.
-
virtual std::string specification() const
Get a textual specification of the composite structure.
- Returns:
Specification string (e.g., “lcir(mt+bm)+kou”).
-
virtual std::ostream &print(std::ostream &out) const
Print the process to an output stream.
- Parameters:
out – Output stream.
- Returns:
The output stream with process info written.
-
inline std::vector<std::shared_ptr<StochasticProcess>> get_components() const
Get all components in this composite process.
- Returns:
Vector of shared pointers to the component processes.
-
inline virtual CompositeStochasticProcess *clone() const