Professional Documents
Culture Documents
Assignment
Assignment
By
……………………………………………………………………………………………………………………………...
Question # 01…………………………………………………………………………………………………….
Solution
-24.1755
-16.4772
-5.4012
20.0907
15.3074
b) By changing the weight for large number of times, it seems that given
eigen values are not to much effected so the corresponding optimal
optimal weights are as follows
Code
%% Update your weights here to get better performance
v=[28,38,600,990,44];
Q=diag(v)
d=[10000, 1000];
R=diag(d);
P=are(A,B*inv(R)*B',Q);
K1=inv(R)*B'*P;
optimal_eigen_value = eig(A-B*K1)
Output
Q =
28 0 0 0 0
0 38 0 0 0
0 0 600 0 0
0 0 0 990 0
0 0 0 0 44
R =
10000 0
0 1000
P =
1.0e+07 *
0.0537 0.1758 0.6519 0.1125 -0.0840
0.1758 0.5754 2.1352 0.3711 -0.2659
0.6519 2.1352 7.9254 1.3849 -0.9607
0.1125 0.3711 1.3849 0.2647 -0.0875
-0.0840 -0.2659 -0.9607 -0.0875 0.401
optimal_eigen_value =
-5.4012
-15.3081
-16.4766
-20.0907
-24.1755
Output
P =
K =
1.0e+03 *
>>
b) The resulting K is not the same this is because that K has 10 components
and all 10 component are used to minimize cost when using LQ while only
five are needed to place poles
……………………………………………………………………………………………………………………………….
Question # 03…………………………………………………………………………………………………………
Solution:
Question # 4……………………………………………………………………………………………………………
Solution