Error using Kalman function - cannot compute stabilizing Riccati solution

22 Ansichten (letzte 30 Tage)
Please see below a snippet of my code:
sys=ss(A_ae_control,B_ae_control,C_ae_control,0);
Qn=0.0001;
Rn=0.01*eye(size(C_ae_control,1));
[kest,L,P]=kalman(sys,Qn,Rn);
I can't seem to figure out why this won't run. I keep getting the following error:
Cannot compute the stabilizing Riccati solution P for the Kalman filter.
This could be because:
* RN is singular,
* [QN NN;NN' RN] needs to be positive definite,
* The E matrix in the state equation is singular.
Any insight would be appreciated. I have attached my A, B and C matrices.
Also, is it possible to somehow create a Kalman estimator without any measurement noise (only a disturbance). I tried setting Rn to 0 but not sure why this does not work.
  4 Kommentare
Emir Acevedo
Emir Acevedo am 13 Sep. 2022
I had designing a LQR controller and after an Kalman Filter. For mi satellite control, I used the same Q and R matrix in Ricatti to solve Kest. May that can fix your problem.
Regards.
rajesh r
rajesh r am 17 Apr. 2023
Did you sort-out this problem?
I am also getting same issue.

Melden Sie sich an, um zu kommentieren.

Antworten (1)

Ivo Houtzager
Ivo Houtzager am 17 Apr. 2023
Your state-space model is probably not a minimal realization, in other words not fully obervable or not fully controllable. Perform the function minreal to remove unobservable or uncontrollable states.
sys=ss(A_ae_control,B_ae_control,C_ae_control,0);
sys=minreal(sys);
Qn=0.0001;
Rn=0.01*eye(size(C_ae_control,1));
[kest,L,P]=kalman(sys,Qn,Rn);
  2 Kommentare
rajesh r
rajesh r am 17 Apr. 2023
My model is:
A = [1 0.01; 0 1];
B = [0 ; 0];
C= [1 0];
D = 0;
after minreal,
the complete A matrix is zero
Ivo Houtzager
Ivo Houtzager am 17 Apr. 2023
You have no inputs defined, because both B and D are zero. Thus your model is fully uncontrollable. So you have review your model inputs for correctness.

Melden Sie sich an, um zu kommentieren.

Produkte


Version

R2020a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by