dlqe [control]
— Function File: [l, m, p, e] = dlqe (a, g, c, sigw, sigv, z)

Construct the linear quadratic estimator (Kalman filter) for the discrete time system

          x[k+1] = A x[k] + B u[k] + G w[k]
          y[k] = C x[k] + D u[k] + v[k]

where w, v are zero-mean gaussian noise processes with respective intensities sigw = cov (w, w) and sigv = cov (v, v).

If specified, z is cov (w, v). Otherwise cov (w, v) = 0.

The observer structure is

          z[k|k] = z[k|k-1] + L (y[k] - C z[k|k-1] - D u[k])
          z[k+1|k] = A z[k|k] + B u[k]

The following values are returned:

l
The observer gain, (a - alc). is stable.
m
The Riccati equation solution.
p
The estimate error covariance after the measurement update.
e
The closed loop poles of (a - alc).