授業
Advanced Automation 2025†
latest lecture
[lecture #1] 2025.9.4 outline of the lecture, review of classical and modern control theory (1/3)†
- review : stabilization of SISO unstable plant by classical and modern control theory
- transfer functions / differential equations
- poles / eigenvalues
- impulse response / initial value response
- ...
s = tf('s')
P = 1/(s-1)
pole(P)
impulse(P)
K = 2
Tyr = K/(s-1+K)
step(Tyr)
%-- 2025/09/04 13:57 --%
s = tf('s')
P = 1/(s-1)
pole(P)
impulse(P)
K = 2
Tyr = K/(s-1+K)
step(Tyr)
- Q: 英語だと一度分からない単語が出てくると置いて行かれる。
- Q: 日本語による授業がいいです。
- Q: できれば日本語にしていただけると理解がよりはかどります。
- Q: 日本語での授業の方が理解が深まると感じたため、日本語で授業していただけるとありがたいです。
- A: 受講者が日本人のみの場合は日本語とします。
- Q: 動的システムのように要点をまとめたプリントを配布してほしいです。
- A: 「動的システムの解析と制御」後半(現代制御、小林担当)ではプリントは配布しておらず、本講義と同じようにホームページ上に講義項目を記載しています。
[lecture #2] 2025.9.11 review of classical and modern control theory (2/3) with introduction of Matlab/Simulink†
- introduction of Matlab and Simulink
text_fixed.pdf Basic usage of MATLAB and Simulink used for 情報処理演習及び考究II/Consideration and Practice of Information Processing II: Advanced Course of MATLAB
- interactive system (no compilation, no variable definition)
- m file
- system representation: Transfer Function(TF) / State-Space Representation (SSR)
- example: mass-spring-damper system
- definition of SSR
- from SSR to TF
- from TF to SSR: controllable canonical form
- open-loop characteristic
- open-loop stability: poles and eigenvalues
- Bode plot and frequency response
ex0911_1.m
mod0911_1.mdl
- cut off frequency; DC gain; -40dB/dec; variation of c
- relation between P(jw) and steady-state response
- closed-loop stability
- Nyquist stability criterion (for L(s):stable)
- Nyquist plot
ex0911_2.m
mod0911_2.mdl
- Gain Margin(GM); Phase Margin(PM)
%-- 2025/09/11 13:09 --%
a = 1
V=[1 2 3 ; 4 5 6 ; 7 8 9]
size(V)
pwd
ex0911_1
a
ex0911_1
a = 1
a = 1;
ctrlpref
sqrt(k/m)
sqrt(k/m)/(2*pi)
pi
ex0911_1
ex0911_2
K
K = 1
ex0911_2
[lecture #3] 2024.9.19 review of classical and modern control theory (3/3)†
- LQR problem
- controllability
- cost function J >= 0
- positive (semi-)definite matrices
- solution of LQR problem
- example
ex0918_1.m
mod0918_1.mdl
- ARE and quadratic equation
%-- 2025/09/18 13:26 --%
ex0918_1
pwd
ls mod0918*
ex0918_1
J
t
plot(t, J)
A
B
Uc
[B, A*B]
M = [2, 0; 0, 3]
eig(M)
P
[lecture #4] 2025.9.25 relation between LQR and H infinity control problem (1/2)†
- GOAL: to learn difference in concepts between LQR problem and H infinity control problem
- a simple example relating LQR and H infinity control problems
- For given plant G
\[
G = \left[\begin{array}{c|c:c} a & 1 & b \\ \hline \sqrt{q} & 0 & 0 \\ 0 & 0 & \sqrt{r} \\ \hdashline 1 & 0 & 0 \end{array} \right]
= \left\{ \begin{array}{l} \dot x = ax + bu + w\\ z = \left[ \begin{array}{c} \sqrt{q} x \\ \sqrt{r} u \end{array}\right] \\ x = x \end{array}\right.
\]
with zero initial state value x(0) = 0,
find a state-feedback controller
\[ u = -f x \]
such that
\begin{eqnarray}
(i) &&\quad \mbox{closed loop is stable} \\
(ii) &&\quad \mbox{minimize}
\left\{\begin{array}{l} \| z \|_2 \mbox{ for } w(t) = \delta(t) \quad \mbox{(LQR)} \\
\| T_{zw} \|_\infty \mbox{($H_\infty$ control problem)}\end{array}\right.
\end{eqnarray}
- comparison of norms in (ii) (for a = -1, b = 1, q = 1, r = 1)
\[
\begin{array}{|c||c|c|}\hline
& \mbox{LQR}: f=-1+\sqrt{2} & \quad \quad H_\infty: f=1\quad\quad \\ \hline\hline
J=\|z\|_2^2 & & \\ \hline
\|T_{zw}\|_\infty & & \\ \hline
\end{array}
\]
- an alternative description to LQR problem
- J = (L2 norm of z)^2
- impulse resp. with zero initial value = initial value resp. with zero disturbance
- definition of H infinity norm (SISO)
s = tf('s');
G1 = 1/(s+1);
bode(G1);
norm(G1, 'inf')
G2 = s/(s+1);
bode(G2);
norm(G2, 'inf')
G3 = 1/(s^2 + 0.1*s + 1);
bode(G3);
norm(G3, 'inf')
- definition of H infinity norm (SIMO)
G4 = [1/(s+2); -1/(s+2)];
norm(G4, 'inf')
- solve the problem by hand
- solve the problem by tool(hinfsyn)
ex0925_1.m
%-- 2025/09/25 13:55 --%
s = tf('s');
G1 = 1/(s+1);
bode(G1);
norm(G1, 'inf')
G2 = s/(s+1);
bode(G2);
norm(G2, 'inf')
G3 = 1/(s^2 + 0.1*s + 1);
bode(G3);
norm(G3, 'inf')
ctrlpref
bode(G3);
grid on
G4 = [1/(s+2); -1/(s+2)];
norm(G4, 'inf')
- Q: 次は成り立つのか?
\[ \overline{\left(\frac{1}{\alpha + j\beta}\right)} = \frac{1}{\overline{\alpha + j\beta}} = \frac{1}{\alpha - j\beta} \]
- A: 成り立ちます。即答できず失礼しました。
\[ (左辺) = \overline{\left(\frac{\alpha - j\beta}{\alpha^2 + \beta^2}\right)} = \frac{\alpha + j\beta}{\alpha^2 + \beta^2} = (右辺) \]
より一般的に、複素数 c1, c2 について、
\[ \overline{c_1 c_2} = \overline{c_1} \cdot \overline{c_2}, \quad \overline{\left(\frac{c_1}{c_2}\right)} = \frac{\overline{c_1}}{\overline{c_2}} \]
が成り立ち、結局 j を -j で置き換えることで複素共役が得られます。
[lecture #5] 2025.10.02 relation between LQR and H infinity control problem (2/2)†
- cont.
- solve the problem by hand
- solve the problem by tool(hinfsyn)
ex0925_1.m
- complete the table in simple example
- confirm the cost function J for both controllers by simulation
mod1002.mdl
- block diagram in the simulink model
- how to approximate impulse disturbance with a step function
- (unit) impulse disturbance resp. with zero initial condition = (unit) initial condition resp. with zero disturbance
- confirm the closed-loop H infinity norm for both controllers by simulation
- H infinity norm = L2 induced norm
- review: steady-state response for sinusoidal input signal; how to choose the frequency such that the output amplitude is maximized ?
- the worst-case disturbance w(t) for the simple example ?
- general state-feedback case:
hinf.pdf
- includes the simple example as a special case
- LQR
lqr.pdf is included as a special case in which gamma -> infinity, w(t) = 0, B2 -> B, and non-zero x(0) are considered
%-- 2025/10/02 13:19 --%
1/sqrt(2)
ex0925_1
help hinfsyn
K
clp1 = lft(G, -1);
figure(2)
hold on
sigma(clp1, 'k--')
sqrt(2-sqrt(2))
mod1002
f = -1+sqrt(2)
h = 0.01
x0 = 0
zz
x0 = 1
zz
x0 = 0
h = 100
f
zz
sqrt(zz(end)/ww(end))
h
f
f = 1
sqrt(zz(end)/ww(end))
h
h = 1000
sqrt(zz(end)/ww(end))
[lecture #6] 2025.10.9 Mixed sensitivity problem 1/3†
- outline:
map_v1.1_mixedsens1.pdf
- sensitivity function S and complementary sensitivity function T
- H infinity control problem (general case)
- with generalized plant G
- including the state-feedback case
- reference tracking problem
- how to translate the condition (ii) into one with H infinity norm ?
- corresponding generalized plant G ?
- introduction of weighting function for sensitivity function in (ii)
- design example
ex1009_1.m
ex1009_2.m
- the small gain theorem
- proof: Nyquist stability criterion
%-- 2025/10/09 13:39 --%
ex1009_1
P
eig(P)
ex1009_2
K_hinf
K_hinf.a
eig(K_hinf.a)
[lecture #7] 2025.10.16 Mixed sensitivity problem 2/3†
- outline: from point to set
map_v1.1_mixedsens2.pdf
- the small gain theorem ... robust stability = H infinity norm condition
- normalized uncertainty Delta
- uncertainty model
- simple example of plant set
- given plant P tilde
- frequency response of plant with perturbation
ex1016_1.m
- how to determine P0 and WT ?
- frequency response based procedure for P0 and WT
ex1016_2.m
- robust stabilization problem and equivalent problem
ex1016_1
ex1016_2
help hinfsyn
ex1016_3
K
mod1016
c
c = 0.8
c = 1
c = 1.5
c = 2
c = 0
c = -0.1
[lecture #8] 2025.10.23 Mixed sensitivity problem 3/3†
- review:
map_v1.1_mixedsens2.pdf (1)performance optimization and (2)robust stabilization
- outline:
- how to design controllers considering both conditions in (1) and (2)
- gap between NP(nominal performance) and RP(robust performance)
- mixed sensitivity problem => (1) and (2) : proof
- generalized plant for mixed senstivity problem
- design example
ex1023_1.m minimize gamma by hand
- gamma iteration by bisection method
ex1023_2.m tradeoff between robust stability and performance
- intro. to RP: weak point of mixed sensitivity problem(problem of NP)
ex1023_3.m
%-- 2025/10/23 13:30 --%
ex1023_1
K
ex1023_2
gam
0.0001
ex1023_2
gam
gam_opt
ex1023_2
gam_opt
ex1023_2
gam_opt
ex1023_2
ex1023_3
[lecture #9] 2025.10.30 robust performance problem 1/3†
- review
- mixed sensitivity problem : N.P. but not R.P.
- robust performance problem (R.P.), but can not be solved by tool
- an equivalent robust stability (R.S.) problem to R.P.
- (i) introduction of a fictitious uncertainty Delta_p (for performance)
- (ii) for 2-by-2 uncertainty block Delta hat which includes Delta and Delta_p
- definition of H infinity norm for general case (MIMO)
- proof of ||Delta hat||_inf <= 1
- design example:
ex1030_1.m
- robust performance is achieved but large gap
- non structured uncertainty is considered ... the design problem is too conservative
%-- 2025/10/30 13:59 --%
M = [sqrt(2), sqrt(2); -1i/sqrt(2), 1i/sqrt(2)]
M'
M''
eig(M'*M)
svd(M)
help svd
ex1030_1
[lecture #10] 2025.11.6 Robust performance problem (2/3)†
- return of mini report #1
- SVD: singular value decomposition
- definition
- meaning of the largest singular value (a property and proof)
- 2 norm of vectors (Euclidean norm)
- SVD for 2-by-2 real matrix
ex1106_1.m
%-- 2025/11/06 13:21 --%
M = [1i, -1i; 0, 1]
[U, S, V] = svd(M);
S
sqrt((3+sqrt(5))/2)
sqrt((3-sqrt(5))/2)
(1+sqrt(5))/2
(sqrt(5)-1)/2
U
U'*U
format long e
U'*U
U*U'
1+1e-16
1e-16 + 1e-16
svd(U)
ex1106_1
help rand
M
ex1106_1
M = 2*rand(2,2)-1;
M
zeros(2,2)
zeros(2,2)-1
ex1106_1
[lecture #11] 2025.11.20 Robust performance problem (3/3)†
- review : R.S. problems for structured and unstructured uncertainty
- scaled H infinity control problem
- relation between three problems
- how to determine structure of scaling matrix
- design example
ex1120_1.m
dgam.jpg
ex1030_1
gam2 = gam_opt
ex1120_1
gam_opt
- mini exam #1 (10 min.)
%-- 2025/11/20 13:03 --%
ex1030_1
gam2 = gam_opt
ex1120_1
gam_opt
help hinfsyn
doc hinfsyn
[lecture #12] 2025.11.27 Robust performance problem (3/3) (cont.), Control system design for practical system (1/3)†
- return of mini exam #1
- review of scaling
ex1127_1.m
- mini report #2
report2.pdf
- introduction of a practical system: active noise control in duct
- experimental setup (tentative)
photo1.jpg
photo2.jpg
- objective of control system: to drive control loudspeaker by generating proper driving signal u using reference microphone output y such that the error microphone's output z is attenuated against the disturbance input w
- frequency response experiment
ex1127_2.m
spk1.dat
spk2.dat
- room 157 @ Dept. Mech. Bldg. 2
%-- 2025/11/27 13:04 --%
ex1127_1
ex1127_2
ctrlpref
ex1127_2
L = 1.6
c0 = 346
c0/(4*L)
c0/(4*L)*3
[lecture #13] 2025.12.4 Control system design for practical system (2/3)†
- return of mini report #2; ... You will have a mini exam #2 related to this report next week
- review of the experimental system (no change)
- closed-loop system of 2-by-2 plant G and controller K
- closed-loop gain is desired to be minimized
- frequency response data of G can be used; how to handle modeling error of G ?
- design example (modeling error for Gyu is only considered for simplicity)
- final report and remote experimental system
- design your controller(s) so that the system performance is improved compared with the design example
- Draw the following figures and explain the difference between two control systems (your controller and the design example):
- bode diagram of controllers
- gain characteristic of closed-loop system from w to z
- time response of control experiment
- Why is the performance of your system improved(or unfortunately deteriorated)?
- due date: 5th(Mon) Jan 17:00
- submit your report(pdf file) by e-mail to kobayasi@nagaokaut.ac.jp
- You can use Japanese
- maximum controller order is 35
- submit your controller.dat, controller_order.dat, and controller.mat at this page:participant list2025(download is also possible) not later than 23th(Tue) Dec
- the system will be started until next lecture
- You can send up to 10 controllers
- control experimental results will be uploaded here
- freqresp ... frequency response will be measured and uploaded everyday
- how to improve the performance ?
- order of the nominal plant
- weighting for robust stability
- specifications of the experimental system
- experimental equipments
- loudspeakers: FOSTEX FE87E(10W)
- A/D, D/A converters: CONTEC AD12-16(PCI), DA12-4(PCI)
- PC: Dell Dimension 1100
- OS: Linux kernel 2.4.22 / Real Time Linux 3.2-pre3
- program sources for frequency response experiment
- program sources for control experiment
- configuration of control experiment
- disturbance signal w is specified as described in hinf.h and hinf_module.c:
#define AMP 0.5 // amplitude for disturbance
w = AMP * (2. * rand() / (RAND_MAX + 1.) - 1.); // uniform random number in [-AMP, AMP]
da_conv(V_OFFSET + w, 0); // D/A output to noise source
- control signal u is limited to [-1.5, 1.5] as specified in hinf.h and hinf_module.c:
#define U_MAX 1.5
if(u > U_MAX) u = U_MAX;
if(u < -U_MAX) u = -U_MAX;
u is set to 0 for t < 5(s). (controller is operated for 5 <= t < 10)
%-- 2025/12/04 13:26 --%
pwd
nominal
load data/spk1.dat
save data/nominal.mat G0
save data/nominal.mat G0 G_g G0_g w
%-- 2025/12/04 13:33 --%
nominal
help frd
n4sid
weight
cont
compare
nominal
%-- 2025/12/04 14:04 --%
pwd
nominal
pwd
cd ..
nominal
weight
cont
compare
perf
weight
result
plot(result(:,1), result(:,2))
plot(result(:,1), result(:,4))
plot(result(:,1), result(:,5))
[lecture #14] 2025.12.11 Control system design for practical system (3/3)†
- supplemental explanations
- room temperature is displayed and stored in temp.txt (Bosch Sensortec BME280 is used)
- c2d() is used to discretize the resultant continuous-time controller in cont.m
- no strict control objective is given ( there is a freedom to define what is good performance )
- preparation of your own controller(s) by using the remote experiment system
- mini exam #2
%-- 2025/12/11 12:56 --%
ls
pwd
nominal
weight
cont
compare
perf
help c2d
cont
perf
cont
[lecture #15] 2025.12.18 Control system design for practical system (cont.)†
- no lecture will be given as in schedule2025
- preparation of your own controller(s) by using the remote experiment system