StateSpaceMultiPeak

StateSpaceMultiPeak()

StateSpaceMultiPeak class extends the MultiPeakModel class to to form a state space model with multiple peak observation function and enable its estimation. Contains a simulate function,

NOTE: The class was built with the intention of allowing general

SDEs for the state evolution equation. However, this was never fully realized, though the inputs are still in their functional form (in particular, Phi, f_integr, and Q). Consequently, the simulate class function is also not generalized. It assumes an identity transition, constant noise covariances, and times given by the integer times steps. Moreover, because of this and for computation speed, the EKF/IEKF filters used to estimate the model overwrite the state evolution equation, assuming x(t) = 0.9*Phi*x(t-1) + w(t), with Phi(t1,t2) = I, and constant noise covariances Q and R.

obj = StateSpaceMultiPeak(peakModels, isDynamic, peakCombos,

probTrans, f, Phi, fIntegr, fIntegrParams, Q, omega, R, EX0, CovX0, alpha0)

INPUTS:

peakModels – an array (num_peaks x 1) of PeakModel objects. isDynamic – an indicator vector (1 x num_peaks) of which

peaks are allowed to turn on and off. Default is ones(num_peaks,1).

peakCombos – a indicator matrix (num_combos x num_peaks) of

which peaks are on in which combos. Default is all possible combos from makePeakCombos.

probTrans – scalar or vector of probability inputs to

makeComboTransitionMatr. Can be 1x1, 1x2, or 1x3. Default is [0.2 0.2 0.9].

f – drift function of state f(t,x). Currently unused.

Default is [].

Phi – state transition function Phi(t2,t1) that takes

an initial time t1 and finial time t2 and returns a matrix (dim_x x dim_x). Default is @(t2,t1)(eye(dim_x)).

fIintegr – integral of state drift function, integr_f(x,t1,t2,…)

takes state x, initial time t1, final time t2, and any additional parameters returns matrix (dim_x x 1). Default is @(x,t1,t2,params)(zeros(dim_x,1)).

fIntegrParams – additional parameters needed for evalulation of integr_f

takes final time t2 and initial time t1. Default is empty {}.

Q – state noise covariance function Q(t) that

takes time t and returns matrix (dim_x x dim_x). Default is @(t)(eye(dim_y)). If Q is a scalar, a matrix with that value along the diagonal is returned at each time. If Q is a vector of same dimension as the observations, a matrix with that vector on the diagonal is returned at each time. If Q is a matrix, that matrix is returned at each time. Otherwise, Q is the provided function.

omega – a vector (1 x dim_y) of frequency bins at which

the observations are made and the observation function evaluated

R – observation noise covariance function R(t) that

takes time t and and returns a matrix (dim_y x dim_y). Default is @(t)(eye(dim_y)). If R is a scalar, a matrix with that value along the diagonal is returned at each time. If R is a vector of same dimension as the observations, a matrix with that vector on the diagonal is returned at each time. If R is a matrix, that matrix is returned at each time. Otherwise, R is the provided function.

EX0 – initial state mean vector (dim_x x 1).

Default is zeros(dim_x,1).

CovX0 – initial state covariance matrix (dim_x x dim_x).

Default is diagonal matrix with variance 0.1 for bound parameters and variance 0.5 otherwise.

alpha0 – vector (dim_x x 1) of initial state

probabilities. Default is ones(num_combos,1)/num_combos.

Modified: Created: 20190601 – Patrick Stokes