Luenberger observer in state space

12 vues (au cours des 30 derniers jours)
steven rijns
steven rijns le 14 Jan 2020
I am trying to build a Luenberger observer for my state-space model.
For the Luenberger observer I need my state space in the form of;
xdot = Ax + Bu + L(y-Y)
y = Cx+Du.
Does anyone know how to implement this in my current state space model and how I can solve that state space so the results can be compared between the normal state space and the one with an observer?
Ts = 1;
R0_bat = 0.01196;
R1_bat = 0.0110;
R2_bat = 0.0076;
C1_bat = 1.2818*10^4;
C2_bat = 297.6403;
A_statespace_terminal = [1-(Ts/(R1_bat*C1_bat)) 0 0; 0 1-(Ts/(R2_bat*C2_bat)) 0; 0 0 1];
B_statespace_terminal = [Ts/C1_bat; Ts/C2_bat; Ts/(3600*Capacity_true)]; %12.5Ah = 12.5*3600 As
C_statespace_terminal = [1 1 alpha_affine];
D_statespace_terminal = R0_bat;
state_space = ss(A_statespace_terminal, B_statespace_terminal, C_statespace_terminal, D_statespace_terminal, Ts);
[Y_sp_out, time_vector]=lsim(state_space,pulse_discharge.amps,pulse_discharge.time);
V_sp = Y_sp_out + (alpha_affine+beta_affine);

Réponses (0)

Catégories

En savoir plus sur Control System Toolbox dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by