Unscented Kalman Filter.
Public Member Functions | |
UKF () | |
Constructor. | |
~UKF () | |
Destructor. | |
void | set_filter_mode (UKF_mode mode) |
Sets the filter mode. | |
void | set_filter_parameters (const double alpha, const double kappa, const double beta) |
Sets the filter parameters. | |
void | set_integrator_time_info (double t, double dt) |
Sets the integrator time and time step. | |
void | set_initial_values (const ml_matrix &state0, const ml_matrix &covariance0, const ml_matrix ¶meter0=ml_matrix()) |
Sets the initial state and covariance. | |
void | set_noise_covariances (const ml_matrix &Rp, const ml_matrix &Rm) |
Sets the noise covariance matrices. | |
void | set_state_function (state_func state_fun) |
Sets the state function. | |
void | set_integrator (integ_func integ_fun) |
Sets the integrator function. | |
void | set_measurement_function (meas_func meas_fun) |
Sets the measurement function. | |
void | set_context (void *context) |
Sets the context pointer for data needed by the state or measurement functions. | |
ml_matrix | current_state (void) const |
Returns the current estimated state. | |
ml_matrix | current_residual (void) const |
Returns the current residual. | |
ml_matrix | current_parameter (void) const |
Returns the current estimated parameter. | |
ml_matrix | current_covariance (void) const |
Returns the current estimated covariance. | |
ml_matrix | current_residual_covariance (void) const |
Returns the current residual covariance. | |
ml_matrix | current_rhs_params (void) const |
Returns the current RHS parameters (only used in parameter mode). | |
void | update_estimate (const ml_matrix &measurement) |
Updates the current estimate. |
void UKF::set_filter_mode | ( | UKF_mode | mode ) |
mode | desired mode (from enum UKF_mode). |
void UKF::set_filter_parameters | ( | const double | alpha, |
const double | kappa, | ||
const double | beta | ||
) |
alpha | usually in [.0001,1] |
kappa | 0 for state estimation |
beta | 2 for normally distributed data |
void UKF::set_integrator_time_info | ( | double | t, |
double | dt | ||
) |
t | time (s) |
dt | timestep (s) |
void UKF::set_initial_values | ( | const ml_matrix & | state0, |
const ml_matrix & | covariance0, | ||
const ml_matrix & | parameter0 = ml_matrix() |
||
) |
Sets the initial state, parameter and covariance.
state0 | state (nx1) |
covariance0 | covariance (nxn) |
parameter0 | parameter (nx1) (not used in state mode) |
void UKF::set_noise_covariances | ( | const ml_matrix & | Rp, |
const ml_matrix & | Rm | ||
) |
Rp | noise covariance matrix (nxn) |
Rm | measurement covariance matrix (mxm) |
void UKF::set_state_function | ( | state_func | state_fun ) |
Sets the state function, which is the right hand side of the state update.
state_fun | a function pointer to a state_func function |
void UKF::set_integrator | ( | integ_func | integ_fun ) |
Sets the integrator function used to propagate the state.
integ_fun | a function pointer to a integ_func function |
void UKF::set_measurement_function | ( | meas_func | meas_fun ) |
meas_fun | a function pointer to a meas_func function |
void UKF::set_context | ( | void * | context ) |
Sets the context pointer that will be passed in to the other functions.
*context | a function pointer to a meas_func function |
void UKF::update_estimate | ( | const ml_matrix & | measurement ) |
measurement | updated measurement vector (mx1) |