Entwurf eines Zustandsreglers auf der Grundlage des identifizierten Systems
(EN google-translate)
(PL google-translate)
Bild 0-1: Prinzip des Zustandsreglers.
005_zustandsregler.zip - Scilab-Skripte zu nachfolgender Darstellung.
$ \dot \vec y = A \cdot \vec y - B \cdot R \cdot \vec y $
Formel 0-1: Allgemeine Form eines Zus \tan dsreglers.
RR = zeros(1,4);
Agii=[ 0, 1, 0, 0;
0, 0, 1, 0;
0, 0, 0, 1;
0, 0,-pc/pa,-pb/pa];
Code 0-1: Bgii=[0;0;0;1/pa];
Um Integralanteil zu φ erweitertes Zustandsmodell. u_begrenzt_aktuell wird im Simulationsprogramm aus einem numerisch bestimmten aktuellen Zustand als -R*y berechnet. function f = modell(t,yy) f = Agii*yy+Bgii*u_begrenzt_aktuell; endfunction einachsermodell.sce - Um Integralanteil zu φ erweitertes Zustandsmodell.
function ygir_sim=simulation(x,y0,t)
RR = [x(1),x(2),x(3),x(4)];
zs=size(t);
z=zs(2);
t0 = 0;
yalt = y0;
ygir_sim = yalt
u_begrenzt_aktuell = 0;
u_merk = [0];
index_umerk = 1;
//Für die numerische Bestimmung der Zustandsgrößen
phi = y0(1);
phi_alt = y0(1);
phi_integ = 0.0;
omega = 0.0;
omega_alt = 0.0;
for i=1:1:z-1
takt = t(i);
//Der nachfolgende Bereich könnte in dieser in einem Mikrocontroller realisiert werden:
//**************************************
//******* STELLGRÖSSE BESTIMMEN ********
phi_alt = phi;
omega_alt = omega;
// phi = yalt(1) + grand(1, 1, "nor", MITTELWERT, STREUUNG);
phi = yalt(1);
phi_integ = phi_integ + phi*dt;
omega = (phi - phi_alt)/dt;
alfa = (omega - omega_alt)/dt;
//Numerisch rekonstruierter Zustand:
ynum = [phi_integ;phi;omega;alfa];
//Zeitschritt durchführen:
yneu=ruku(yalt,takt,dt);
ygir_sim=[ygir_sim,yneu];
yalt=yneu;
//Erst danach das Stellsignal aktualisieren:
u_begrenzt_aktuell = -RR*ynum;
if u_begrenzt_aktuell>480 then
u_begrenzt_aktuell=480;
end
if u_begrenzt_aktuell<-480 then
u_begrenzt_aktuell=-480;
end
//**************************************
//****** ENDE STELLGRÖSSE BESTIMMEN ****
end
endfunction
Code 0-2: simulation.sce - Rekonstruktion des aktuellen Zustands und Bilden der Stellgröße unter Verwendung der Regelmatrix.
Bild 0-2: Simulation mit optimierter Regelmatrix R.
RR = [ 28.33612 695.28647 3200.6461 12.687827 ] (mit leichtem Rauschen, s=0.0001) RR = [ 1.2629642 417.84224 7470.5486 0.3518931 ] (ohne Rauschen)
Code 0-3: Varianten für die optimierte Regelmatrix R.
Variante unter Verzicht des Integrationsanteils
006_zustandsregler2.zip - Skripte zu nachfolgender Darstellung.
RR = zeros(1,4);
Agii=[
0, 1, 0;
0, 0, 1;
0,-pc/pa,-pb/pa];
Bgii=[0;0;1/pa];
function f = modell(t,yy)
f = Agii*yy+Bgii*u_begrenzt_aktuell;
endfunction
Code 0-4: einachsermodell.sce - Zustandsgeregeltes Einachsermodell ohne Integralbildung von φ.
Bild 0-3: Ergebnis mit optimiertem R für ursprüngliche Systemmatrix ohne Integralanteil. φ wurde mit Ruaschen überlagert.