'sym' returns val = k11
Ältere Kommentare anzeigen
I am trying to obtain each of the k values in the K_bar matrix but it returns this instead:
val =
k12
A_bar and B_bar are 6x6 and 6x2 matrices respectively, desired_A is a 6x6 matrix
syms k11 k12 k13 k14 k15 k16 k21 k22 k23 k24 k25 k26
K_bar = [k11 k12 k13 k14 k15 k16; k21 k22 k23 k24 k25 k26];
desired_A = [0 1 0 0 0 0;
0 0 1 0 0 0;
0 0 0 1 0 0;
0 0 0 0 1 0;
0 0 0 0 0 1;
P_1(1,1) P_1(2,1) P_1(3,1) P_1(4,1) P_1(5,1) P_1(6,1)];
solve(A_bar-B_bar*K_bar == desired_A)
2 Kommentare
Torsten
am 26 Okt. 2022
We cannot run your code since P_1, A_bar and B_bar are not included.
Specify the variables to be solved for in the solve-command:
solve(A_bar-B_bar*K_bar == desired_A,[....])
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Numeric Solvers finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!