LinearMeasurementModel

The LinearMeasurementModel class describes the relationship between a system state \(x_k \in \mathbb{R}^N\) and a noisy measurement \(y_k \in \mathbb{R}^M\) in the form of $$y_k = \mathbf{H}_k x_k + v_k \enspace,$$ with

  • measurement matrix \(\mathbf{H}_k \in \mathbb{R}^{M \times N}\) and

  • measurement noise \(v_k \in \mathbb{R}^M \).

The LinearMeasurementModel class also implements an AdditiveNoiseMeasurementModel.

Usage

Configure a LinearMeasurementModel instance using the respective set* methods:

  • Set the measurement matrix \(\mathbf{H}_k\) with setMeasurementMatrix()

    If no measurement matrix is set, the LinearMeasurementModel instance uses an identity matrix of appropriate dimensions as measurement matrix.

  • Set the measurement noise \(v_k\) with setNoise()

    You have to pass an instance of a Distribution subclass, e.g., a Gaussian. See also the list of available Probability Distributions.

You can pass a measurement matrix \(\mathbf{H}_k\) to the LinearMeasurementModel's constructor.

You can access the set measurement matrix and noise through the LinearMeasurementModel's properties.

Example

We implement position measurement model for a 2D target described by the system state $$x_k = [p^x_k, p^y_k, \dot{p}^x_k, \dot{p}^y_k, \ddot{p}^x_k, \ddot{p}^y_k]^\top \enspace.$$ The measurement model is given by $$y_k = \mathbf{H} x_k + v_k \enspace,$$ with matrix \(\mathbf{H} = \begin{bmatrix} \mathbf{I}_2 & \mathbf{0} & \mathbf{0} \end{bmatrix}\) and zero-mean white Gaussian noise \(v_k\) with covariance matrix \(\mathbf{R} = 0.5\mathbf{I}_2\).

H = [eye(2) zeros(2, 4)];

v = Gaussian(zeros(2, 1), 0.5*eye(2));

measModel = LinearMeasurementModel();

measModel.setMeasurementMatrix(H);
measModel.setNoise(v);

% Alternative construction:
measModel = LinearMeasurementModel(H);

measModel.setNoise(v);