Linear-quadratic (LQ) state-feedback regulator for discrete-time state-space system
[K,S,e] = dlqr(A,B,Q,R,N)
for the discrete-time state-space mode
The default value N=0 is assumed when N is omitted.
In addition to the state-feedback gain K, dlqr returns the infinite horizon solution S of the associated discrete-time Riccati equation
and the closed-loop eigenvalues e = eig(A-B*K). Note that K is derived from S by
The problem data must satisfy:
The pair (A, B) is stabilizable.
R > 0 and Q − NR–1NT ≥ 0
(Q − NR–1NT, A − BR–1NT) has no unobservable mode on the unit circle.