Microsoft PowerPoint FundCtrlSys Chapter9 ppt [Compatibility Mode] Lecture NotesLecture Notes Fundamentals of Control SystemsFundamentals of Control Systems Instructor Assoc Prof Dr Huynh Thai Hoang D[.]
Lecture Notes Fundamentals of Control Systems Instructor: Assoc Prof Dr Huynh Thai Hoang Department of Automatic Control Faculty of Electrical & Electronics Engineering Ho Chi Minh City University of Technology Email: hthoang@hcmut.edu.vn huynhthaihoang@yahoo.com Homepage: www4.hcmut.edu.vn/~hthoang/ www4 hcmut edu vn/ hthoang/ December 2013 © H T Hoang - www4.hcmut.edu.vn/~hthoang/ Chapter DESIGN OF DISCRETE CONTROL SYSTEMS December 2013 © H T Hoàng - www4.hcmut.edu.vn/~hthoang/ Content Introduction Discrete lead – lag compensator and PID controller Design discrete systems in the Z domain Controllability and observability of discrete systems Design D i state t t feedback f db k controller t ll using i pole l placement Design state estimator December 2013 © H T Hoàng - www4.hcmut.edu.vn/~hthoang/ Discrete lead lag compensators and PID controllers December 2013 © H T Hoàng - www4.hcmut.edu.vn/~hthoang/ Control schemes Serial compensator R(z) + T GC(z) ZOH G(z) Y(z) H( ) H(z) State feedback control r(k) + u(k) x (k 1) Ad x (k ) Bd u (k ) x(t) Cd y(k) K December 2013 © H T Hoàng - www4.hcmut.edu.vn/~hthoang/ Transfer function of discrete difference term u(k) e(k) D Differential term: dde(t ) u (t ) dt e( kT ) e[( k 1)T ] Discrete difference: u ( kT ) T E ( z ) z 1 E ( z ) U ( z) T Transfer function of the discrete difference term: z 1 GD ( z ) T z December 2013 © H T Hoàng - www4.hcmut.edu.vn/~hthoang/ Transfer function of discrete integral term e(t) I t Integral l u(t) t Continuous integral:u(t ) e( )d Di Discrete t integral: i t l u ( kT ) = u[( k - 1)T ] + U ( z ) z 1U ( z ) kT ( k 1)T kT 0 ( k 1)T u (kT ) e( )d e( )d e( )d kT T e ( t ) d t = u [( k 1) T ] + (e[( k - 1)T ] + e(kT ) ò ( k -1) T T 1 z E( z) E( z) TF of discrete integral term: GI ( z ) T z z 1 December 2013 © H T Hồng - www4.hcmut.edu.vn/~hthoang/ Transfer function of discrete PID controller C ti Continuous PID controller: t ll K GPID ( s ) K P K D s s Discrete PID controller: KIT z KD z GPID ( z ) K P z 1 T z P or D z KD z GPID ( z ) K P K I T z 1 T z P December 2013 I I D © H T Hoàng - www4.hcmut.edu.vn/~hthoang/ Digital PID controller r(k) (k) + e(k) PID u(k) D/A G(s) y(k) A/D KIT z KD z U ( z) G PID ( z ) KP E( z) z 1 T z u( k ) u( k 1) K P [e( k ) e( k 1)] ) KIT KD [e( k ) e( k 1)] [e( k ) 2e( k 1) e( k 2)] T December 2013 © H T Hoàng - www4.hcmut.edu.vn/~hthoang/ Digital PID control programming float PID_control(float PID control(float setpoint, setpoint float measure) { ek_2 = ek_1; ek_1 = ek; ek = setpoint – measure; uk_1 = uk; uk = uk_1 uk + Kp Kp*(ek (ek-ek_1) ek 1) + Ki Ki*T/2*(ek+ek T/2 (ek+ek_1) 1) +… + Kd/T*(ek – 2ek_1+ek_2); If uk > umax, uk = umax; If uk < umin, uk = umin; return(uk) } Note: Kp, Ki, Kd, uk, uk_1, ek, ek_1, ek_2 must be declared as gglobal variables;; uk_1,, ek_1 and ek_e must be initialized to be zero; umax and umin are constants December 2013 © H T Hồng - www4.hcmut.edu.vn/~hthoang/ 10