Säätö- ja systeemitekniikan kehittyneet menetelmät (477607S) Advanced control and systems engineering (477607S) 2019 Enso Ikonen säätö- ja systeemitekniikan professori professor of control and systems engineering
SSKM (Säätö- ja systeemitekniikan kehittyneet menetelmät) Advaced Control and Systems Engineering Outline of 1st session (2h) Session language? MSc thesis advertisements Practicalities for passing the course (15min) what, where and how: lectures, exercises homeworks exam time schedules Preliminary assignments (15min) Introduction to the topics of Advanced control and systems engineering (15min) Getting started with Matlab (45min) matrices, indexing useful functions writing m-files/functions Exercise Simulation of a PID controlled process
Course language policy: All course material is in English (recordings, book, slides,..) rec. with Finnish subtitles Exercises & consultation in Finnish or in English or both
diplomityöpaikkoja IMS/systeemitekniikassa 1/2019 vesivoiman tuotannossa työ tehdään yliopistolla, yhteistyössä PVO:n kanssa aloitus 2019 aihe täsmentyy myöhemmin PVO:n kanssa HYPE-hankkeet Haetaan osaavaa opiskelijaa jolla mielenkiintoa/potentiaalia myös jatko-opintoihin Alustava työn aihe: Vesivoiman käyttö verkoston taajuussäädössä TkT Istvan Selek automaatiokoulutuksen kehittämishankkeessa työ tehdään yliopistolla loppuu 12/2019 (aloitus n. 5/2019) opetuksen kehittämishanke automaation koulutusympäristö prosessiautomaation +logiikkaohjauksen +robotiikan laitteet OY+OAMK+OSAO yhteistyö opettajien koulutus uudessa koulutusympäristössä toimimiseen Haetaan opetuksesta kiinnostunutta organisaattoria ja järjestelijää alustava työn aihe: Automaatiotekniikan opetuksen työelämälähtöisyys (hankkeen taustat+toteutus+tulokset) koulutusalavastaava Jukka Hiltunen teollisuusrobotiikan selvitys työ tehdään PLC Automationilla ohjelmoitavien logiikoiden ja automaatiojärjestelmätoimittaja aloitus 2019 (keväällä) aihe tarkentuu kun henkilö löytyy Haetaan henkilöä joka on innokas, oma-aloitteinen, tunnollinen ja ulospäin suuntautunut Aihe: Perusteellinen selvitys liiketoiminnan pohjaksi siitä minkälaista tietotaitoa sekä välineistöä teollisuusrobottien toimittaminen vaatisi. DI Jouni Huotari (PLC) / prof. Enso Ikonen (OY)
Säätö- ja systeemitekniikan kehittyneet menetelmät (477607S) Ennustava säätö ja bayesilainen tilaestimointi prosessitekniikassa Advanced control and systems engineering (477607S) Model predictive control (MPC) and bayesian state estimation for process engineering Kurssin järjestää systeemitekniikan tutkimusyksikkö (SYTE) Course is provided by the Systems Engineering Research Unit (SYTE) Enso Ikonen säätö- ja systeemitekniikan professori professor of control and systems engineering 5 op, lähiopetusta kevätperiodilla 3. 5 ects, face-to-face teaching during spring period 3 Kurssin e-versio löytyy Nopasta, suoritusaika vapaa An e-version of the course is available in Noppa, can be taken whenever: https://noppa.oulu.fi/noppa/kurssi/477607s/
Practicalities for the *new* course format https://noppa.oulu.fi/noppa/kurssi/477607s/ home pages: http://cc.oulu.fi/~iko/sskm.htm Course structure/material: Lecture videos including exercises Finnish subtitles Lecture notes (book-pdf) Home works (0-3) groups of 1-2 students follow a given time schedule to be reported & presented & defended all group members must be present points to exam, max 15pnts Exam obligatory, max 30pnts 1 st March 2019 class exam + Examinarium (3hrs) No live lecturing (see noppa) Face-to-face teaching: Opening lecture 9 Jan 2019 Exercises (3) 18 & 23 Jan 2019 on DMC/QDMC coding 20 Feb 2019 KF/PF Home work seminars (3+) 25 Jan, 6 Feb, 27 Feb 2019 Weekly consultation available during hours scheduled for the course (email warning pls!) Wed 14-16, Thu 14-16, Fri 10-12 Fri 11 Jan 2019 cancelled Thu-Fri 7-8 Feb 2019 cancelled
Alkutehtävät / Preliminary assignments Using your mobile phone laptop go to: fbr.io/jnhon Tutkinto-ohjelmani:opintosuuntani on / My degree program? Minua kiinnostavat säätötekniikassa seuraavat näkökulmat / In control engineering, I'm interested in.. Osaan kohtuullisesti näiden kurssien sisällöt / I'm confident with.. Olen opiskellut käyttänyt olennaisena osana opetusta / I'm familiar with.. Osaan koodata itsenäisesti ainakin näillä työkaluilla / I can code with..
A short introduction to the topics Model predictive control (MPC) and bayesian state estimation for process engineering MPC State estimation u=? x y MPC = Model Predictive Control at instant k.. find an optimal input sequence.. u(k), u(k+1), u(k+h) which minimizes a given cost function.. J( x(k+1), x(k+2), x(k+h), u(k), u(k+1),, u(k+h-1) ) using a model of the controlled plant s future behaviour x(k+1) = f(x(k),u(k)) x(k+2) = f(x(k),u(k), u(k+1)) x(k+h) = f(x(k),u(k),, u(k+h-1)) Apply control, and repeat at next k u(k)
A short introduction to the topics Model predictive control (MPC) and bayesian state estimation for process engineering MPC DMC QDMC State estimation MPC = Model Predictive Control Ennustava säätö, malliprediktiivinen säätö DMC: uses a FIR plant model y(k+1) = b 0 u(k) + b 1 u(k-1) + + b N u(k-n) QDMC: optimization under constraints constraints on y, u, x u=? x y Many more other MPC s exist plant model + optimization problem
A short introduction to the topics Model predictive control (MPC) and bayesian state estimation for process engineering MPC DMC QDMC State estimation Bayesian reasoning Kalman filter Particle filter State estimation: State is not measured or measurement may contain noise. Fuse model & measurements.. to make a wise guess about x smoothing, filtering, prediction u x=? y Useful for control monitoring
Algorithms / Simulation Course requires coding abilities basic coding (for, if-then-else,..), decomposing into sub-functions, matrix algebra, optimization libraries, curve plotting, Matlab Possible to use any programming environment, but not recommended only Matlab is supported..
Getting started with Matlab Matlab is an interactive program for numerical computation and data visualization. Univ Oulu licence allows students also to install the program on a home computer. Software Distribution Service: http://www.oulu.fi/ict/node/15 835 https://se.mathworks.com/help/ matlab/getting-started-withmatlab.html Desktop Basics Matrices and Arrays Array Indexing Calling Functions Programming and Scripts https://se.mathworks.com/help/ matlab/functions.html
Matlab in one page Desktop basics >> workspace command window = a = 1, b=2, c=a+b () d= cos(a) ; c=a*b; clc, clear cd, path cd Matrices and arrays [] ; A=[1 2 3;4 5 6;7 8 9] zeros, ones, eye create matrices using functions A+1, sin(a), randn matrix operations A inv inv(a)*a. A.*A ^ A^3, A.^3 [A A] B=[A A] i 3+2i Array indexing A(r,c) A(2,3) A(i) A(8) : A(1:2,3), A(:,3), b=[1:2:10] end A(2:end,3) length, size size(a) Workspace variables whos save save tmp load load tmp Text and chars mytext = Hello, world sprintf T=36.5; mytext = sprintf( Temp = %gc,t) Calling functions () [oarg1,oarg2] = fun(iarg1,iarg2) help help max Plotting plot x=[0:pi/100:2*pi]; y=sin(x); plot(x,y) axis axis([-1 2*pi+1-2 2]) xlabel, ylabel xlabel( x ), ylabel( sin(x) ) title title( sinifunktio ) style plot(x,y, r: ) subplot subplot(211); plot(x,y); subplot(212); plot(xy,cos(x)); stairs stairs(x,y) Programming edit edit tmpfun - save >> tmpfun execute script/function for - end for k=1:10, k, end if elseif else end Functions & scripts mfiles function b = myfunction(a) b = 2*a end Stored as a myfunction.m -file >> myfunction(pi) anonymous sqr = @(x) x.^2; A function handle >> sqr(5) integral(sqr,0,1) Data types double default numeric type char c = Hello, world string c = [ Hello, world, Hello, moon ] struct.field s.a = 1 s.b = { A, B, C } cell C = {1,2,3, hello,rand(3,2)}
Exercise: Closed loop simulation Ex: Simulate a first order plant in closed loop using a P-controller (PIcontroller). Plot plant input/output vs. time. Plant is given by G(s) = k p / tau*s+1 Controller is given by C(s) = U(s)/E(s) = K P Function arguments: input: h (discretization) output: K P (controller parameter) Use k p =5, tau=10 Discretization G(s) => y(k+1) = ay(k) + bu(k) a = e -h/tau b = (1-e -h/tau )k p Tuning rule (~Ziegler-Nichols) K P = tau / k p h h is delay ~sampling time
function K_P = ex_lti1( h) % EX_LTI1 Example code for closed loop simulation % K_P = ex_lti1( h) % A file saved as ex_lti.m. Solution % plant & controller params k_p = 5; tau = 10; a = exp(-h/tau); b = (1-exp(-h/tau))*k_p; K_P = tau/(k_p*h); >> ex_lti1(1); % set point sequence w = [zeros(10,1);ones(10,1);-2*ones(10,1)]; lw = length(w); % process initial state y(1) = 0; % measurement/control loop for k=1:lw % deviation e e = w(k)-y(k); % process control u u(k) = K_P*e; % process output y y(k+1) = a*y(k) + b*u(k); end % plot output and control t = h*[1:lw]'; subplot(211); [x1,y1]=stairs(t,y(1:lw)); [x2,y2]=stairs(t,w(1:lw)); plot(x1,y1,'-',x2,y2,':'); ylabel('y(-), w(:)') ax=axis; axis([0 h*lw ax(3:4)]) subplot(212); stairs(t,u); ylabel('u') xlabel('t') ax=axis; axis([0 h*lw ax(3:4)]) end % function-end
What to do next? Go through videos & book material: videos 11-1 to 13-7 including exercises! book Sections 1.1-1.6 Next class exercises Fri 18 Jan 2018 on DMC/QDMC coding