Optimal State Regulator
through the Matrix Riccati
Equation
Submitted to
Mrs. Shimi SL
Assistant Professor
Submitted By
Mr. Dhruv Upadhaya
162510
ME [ I&C ], Regular
4/17/2017 1Mr. Dhruv Upadhaya
What we are finding
• Solution for Optimal Control problem for a linear multivariable
system with the quadratic criterion function
4/17/2017 2Mr. Dhruv Upadhaya
Completely controllable plant
𝑥 = 𝐴𝑥 + 𝐵𝑢
Where 𝑥 is the n x 1 state vector
u is the p x 1 state vector
A is the n x n state vector
B is the n x p state vector
And the null state 𝒙 = 0 is the desired steady state.
4/17/2017 3
………..(1.1)
Mr. Dhruv Upadhaya
Find the control law
u = -K x(t)
Where K is p x n real constant unconstrained gain matrix,
that minimizes the following performance index subject to the initial
conditions x(0) ≜ x0;
J =
1
2 0
∞
(x 𝑇 𝑄x+uT Ru) dt
Where Q is n x n positive definite, real, symmetric, constant matrix, and
R is p x p positive definite, real, symmetric, constant matrix.
4/17/2017 4
………..(1.2)
………..(1.3)
Mr. Dhruv Upadhaya
There are several ways to solve this optimal control problem. We will
use the Lyapunov function approach.
Substituting the equation (1.1) in (1.2), we obtain
ẋ = A x – BK x = (A – BK)x
Since the (A, B) pair is completely controllable, there exists a feedback
matrix K such that the (A – Bk) is a stable matrix.
The controllability of the given plant, thus, ensures the existence of a K
that minimizes J.
Now we obtain the following design equations for the optimal control
problem.
4/17/2017 5
………..(1.4)
Mr. Dhruv Upadhaya
The time derivative of the Lyapunov function is
𝑉(𝑥) =
1
2
x 𝑇(𝑄 + KT RK)x
The Lyapunov function
V(x) =
1
2
x 𝑇 P x
Where P is a positive definite, real, symmetric, constant matrix, and
(A – BK)TP + P(A – BK) + KTRK + Q = 0
The performance index
J =
1
2
x 𝑇(0) P x(0)
4/17/2017 6
………..(1.5)
………..(1.6)
………..(1.7)
………..(1.8)
Mr. Dhruv Upadhaya
Since feedback matrix K is unconstrained, the optimum value of J is
independent of initial conditions. The optimal kij’s are obtained from the
equations
𝜕𝑃
𝜕kij
= 0
For all i, j.
Since R has been assumed to be a positive definite matrix, we can write
R = ΓT Γ
Where Γ is a non singular matrix. Then equation (1.7) can be written as
(AT – KTBT) P + P(A – BK) + KT ΓT ΓK + Q = 0
Which can be written as
4/17/2017 7
………..(1.9)
Mr. Dhruv Upadhaya
ATP + PA – [ΓK – (ΓT)-1BTP]T [ΓK – (ΓT)-1BTP] – PBR-1BTP + Q= 0
The condition 1.9 for the unconstrained minimization of J leads to the
following equations :
𝜕
𝜕kij
[(ΓK – (ΓT)−1BTP)T (ΓK – (ΓT)−1BTP)] = 0
Since the matrix within brackets is non negative definite, the minimum
occurs when it is zero, or when
ΓK = (ΓT)−1BTP
Hence
K = Γ−1(ΓT)−1BTP = R−1BTP
4/17/2017 8
………..(1.10)
………..(1.11)
Mr. Dhruv Upadhaya
Equation (1.11) gives the optimal gain matrix K. Thus the optimal
control law is given by
u t = –Kx t = −R−1BTPx(t)
The matrix P in equation (1.12) must satisfy equation (1.10), or the
following reduced equation:
ATP + PA – PBR−1BTP + Q = 0
This equation is called Riccati equation
We have assumed Q to be positive definite matrix. This makes 𝑉 𝑥 in
equation (1.5) always negative definite; therefore the optimal feedback
system asymptotically stable. Controllability of the (A, B) pair and
positive definiteness of Q are, thus, sufficient for the existence of
asymptotically stable optimal solution to the control problem.
4/17/2017 9
………..(1.12)
………..(1.13)
Mr. Dhruv Upadhaya
1. Solve the matrix Ricatti equation (1.13) for positive definite matrix
P, and
2. Substitute this matrix P into equation (1.12); the resulting equation
gives optimal control law.
Once the designer has specified Q and R, representing his assessment of
the relative importance of the various terms in the performance index
the solution of 1.13 specifies the optimal control law 1.12. This yields
the optimal closed loop system.
4/17/2017 10
Design Steps
Mr. Dhruv Upadhaya
If the resulting transient response is unsatisfactory, the designer may
alter the weighting matrices Q and R and try again.
4/17/2017 11Mr. Dhruv Upadhaya
1. The matrix R has been assumed to be positive definite. This is a necessary
condition for the existence of the optimal solution to the control problem as seen
from Eqn. (1.12)
2. We have assumed that the plant (1.1) is completely controllable, and the matrix
Q in performance index J given by Eqn. (1.3) is positive definite. These are
sufficient conditions for the existence of asymptotically stable optimal solution
to the control problem. The requirement on matrix Q may be relaxed to a
positive semidefinite matrix with the pair (A, H) completely observable, where
Q = HTH.
3. The solution of Eqn. (1.13) is not unique. Of the several possible solutions, the
desired answer is obtained by enforcing the requirement that P be positive
definite. The positive definite solution of Eqn. (1.13) is unique.
4. In very simple cases, the Riccati equation can be solved analytically, but usually
a numerical solution is required. A number of computer programs for the
purpose are available.
4/17/2017 12
Comments:
Mr. Dhruv Upadhaya
Comments
1. It is important to be able to find out whether the sought-after
solution exists or not before we start working out the solution. This
is possible only if necessary conditions for the existence of
asymptotically stable optimal solution are established. A discussion
of this subject entails not only controllability and observability but
also the concepts of stabilizability and detectability.
2. Equation (1.13) is a set of n2 nonlinear algebraic equations. Since P
is a symmetric matrix, we need to solve only n (n + 1)/2 equations.
4/17/2017 Mr. Dhruv Upadhaya 13
4/17/2017 14Mr. Dhruv Upadhaya

Ricatti Equation

  • 1.
    Optimal State Regulator throughthe Matrix Riccati Equation Submitted to Mrs. Shimi SL Assistant Professor Submitted By Mr. Dhruv Upadhaya 162510 ME [ I&C ], Regular 4/17/2017 1Mr. Dhruv Upadhaya
  • 2.
    What we arefinding • Solution for Optimal Control problem for a linear multivariable system with the quadratic criterion function 4/17/2017 2Mr. Dhruv Upadhaya
  • 3.
    Completely controllable plant 𝑥= 𝐴𝑥 + 𝐵𝑢 Where 𝑥 is the n x 1 state vector u is the p x 1 state vector A is the n x n state vector B is the n x p state vector And the null state 𝒙 = 0 is the desired steady state. 4/17/2017 3 ………..(1.1) Mr. Dhruv Upadhaya
  • 4.
    Find the controllaw u = -K x(t) Where K is p x n real constant unconstrained gain matrix, that minimizes the following performance index subject to the initial conditions x(0) ≜ x0; J = 1 2 0 ∞ (x 𝑇 𝑄x+uT Ru) dt Where Q is n x n positive definite, real, symmetric, constant matrix, and R is p x p positive definite, real, symmetric, constant matrix. 4/17/2017 4 ………..(1.2) ………..(1.3) Mr. Dhruv Upadhaya
  • 5.
    There are severalways to solve this optimal control problem. We will use the Lyapunov function approach. Substituting the equation (1.1) in (1.2), we obtain ẋ = A x – BK x = (A – BK)x Since the (A, B) pair is completely controllable, there exists a feedback matrix K such that the (A – Bk) is a stable matrix. The controllability of the given plant, thus, ensures the existence of a K that minimizes J. Now we obtain the following design equations for the optimal control problem. 4/17/2017 5 ………..(1.4) Mr. Dhruv Upadhaya
  • 6.
    The time derivativeof the Lyapunov function is 𝑉(𝑥) = 1 2 x 𝑇(𝑄 + KT RK)x The Lyapunov function V(x) = 1 2 x 𝑇 P x Where P is a positive definite, real, symmetric, constant matrix, and (A – BK)TP + P(A – BK) + KTRK + Q = 0 The performance index J = 1 2 x 𝑇(0) P x(0) 4/17/2017 6 ………..(1.5) ………..(1.6) ………..(1.7) ………..(1.8) Mr. Dhruv Upadhaya
  • 7.
    Since feedback matrixK is unconstrained, the optimum value of J is independent of initial conditions. The optimal kij’s are obtained from the equations 𝜕𝑃 𝜕kij = 0 For all i, j. Since R has been assumed to be a positive definite matrix, we can write R = ΓT Γ Where Γ is a non singular matrix. Then equation (1.7) can be written as (AT – KTBT) P + P(A – BK) + KT ΓT ΓK + Q = 0 Which can be written as 4/17/2017 7 ………..(1.9) Mr. Dhruv Upadhaya
  • 8.
    ATP + PA– [ΓK – (ΓT)-1BTP]T [ΓK – (ΓT)-1BTP] – PBR-1BTP + Q= 0 The condition 1.9 for the unconstrained minimization of J leads to the following equations : 𝜕 𝜕kij [(ΓK – (ΓT)−1BTP)T (ΓK – (ΓT)−1BTP)] = 0 Since the matrix within brackets is non negative definite, the minimum occurs when it is zero, or when ΓK = (ΓT)−1BTP Hence K = Γ−1(ΓT)−1BTP = R−1BTP 4/17/2017 8 ………..(1.10) ………..(1.11) Mr. Dhruv Upadhaya
  • 9.
    Equation (1.11) givesthe optimal gain matrix K. Thus the optimal control law is given by u t = –Kx t = −R−1BTPx(t) The matrix P in equation (1.12) must satisfy equation (1.10), or the following reduced equation: ATP + PA – PBR−1BTP + Q = 0 This equation is called Riccati equation We have assumed Q to be positive definite matrix. This makes 𝑉 𝑥 in equation (1.5) always negative definite; therefore the optimal feedback system asymptotically stable. Controllability of the (A, B) pair and positive definiteness of Q are, thus, sufficient for the existence of asymptotically stable optimal solution to the control problem. 4/17/2017 9 ………..(1.12) ………..(1.13) Mr. Dhruv Upadhaya
  • 10.
    1. Solve thematrix Ricatti equation (1.13) for positive definite matrix P, and 2. Substitute this matrix P into equation (1.12); the resulting equation gives optimal control law. Once the designer has specified Q and R, representing his assessment of the relative importance of the various terms in the performance index the solution of 1.13 specifies the optimal control law 1.12. This yields the optimal closed loop system. 4/17/2017 10 Design Steps Mr. Dhruv Upadhaya
  • 11.
    If the resultingtransient response is unsatisfactory, the designer may alter the weighting matrices Q and R and try again. 4/17/2017 11Mr. Dhruv Upadhaya
  • 12.
    1. The matrixR has been assumed to be positive definite. This is a necessary condition for the existence of the optimal solution to the control problem as seen from Eqn. (1.12) 2. We have assumed that the plant (1.1) is completely controllable, and the matrix Q in performance index J given by Eqn. (1.3) is positive definite. These are sufficient conditions for the existence of asymptotically stable optimal solution to the control problem. The requirement on matrix Q may be relaxed to a positive semidefinite matrix with the pair (A, H) completely observable, where Q = HTH. 3. The solution of Eqn. (1.13) is not unique. Of the several possible solutions, the desired answer is obtained by enforcing the requirement that P be positive definite. The positive definite solution of Eqn. (1.13) is unique. 4. In very simple cases, the Riccati equation can be solved analytically, but usually a numerical solution is required. A number of computer programs for the purpose are available. 4/17/2017 12 Comments: Mr. Dhruv Upadhaya
  • 13.
    Comments 1. It isimportant to be able to find out whether the sought-after solution exists or not before we start working out the solution. This is possible only if necessary conditions for the existence of asymptotically stable optimal solution are established. A discussion of this subject entails not only controllability and observability but also the concepts of stabilizability and detectability. 2. Equation (1.13) is a set of n2 nonlinear algebraic equations. Since P is a symmetric matrix, we need to solve only n (n + 1)/2 equations. 4/17/2017 Mr. Dhruv Upadhaya 13
  • 14.