If I have a transfer function of a system $G(s)$

$$G(s) = \frac{4 - 2s}{4 + 0.8s + s^2}$$

$G(s)$ has the poles and zeros and is a stable system.

enter image description here

And the step answer look like. It has a delay as you can see, a.k.a non-minimum phase system.

enter image description here

I want to control the system $G(s)$ so it will act as the system $G_m(s)$

$$G_m(s) = \frac{\omega^2}{ s^2 + 2\eta \omega s + \omega ^2} = \frac{1}{1 + 1.4s + s^2 }$$

Where $\eta = 0.7$ and $\omega = 1$. The step answer look like:

enter image description here

The first thing I need to to is to turn both $G_m(s)$ and $G(s)$ to discrete transfer functions with the sampling rate of $h=0.1$.

$$H_m(s) = \frac{B_m}{A_m} = \frac{b_{m0} z + b_{m1}}{a_{m0} z^2 + a_{m0} z + a_{m1}} = \frac{0.0045531 + 0.0047707z }{0.8693582 - 1.8600345z + z^2 }$$

$$H(s) = \frac{B}{A} = \frac{b_0 z + b_1}{az^2 + a_0 z + a_1} = \frac{0.2098316 - 0.1715178z }{0.9231163 - 1.8848025z + z^2}$$

We follow this feedback system:

enter image description here

Where $R, T, S$ are polynomials and $u_c$ is reference input and $y$ is output and $v$ is disturbance input.

The control law $$u = \frac{T}{R}u_c - \frac{S}{R}y$$

Will result the closed loop system:

$$y =\frac{BT}{AR + BS}u_c + \frac{BR}{AR + BS}v$$

Let's say that $v = 0$ and we only focusing on:

$$y =\frac{BT}{AR + BS}u_c$$

Our goal is that the system model $H_m$ should have the same behaviour as reference model $H_m$

$$y =\frac{BT}{AR + BS}u_c = \frac{B_m}{A_m}u_c$$

That means we can write down the diophantine equations:

$$BT = B_m$$ $$AR + BS = A_m$$

Which can be solved as:

$$T = \frac{B_m}{B} = \frac{b_{m0} z + b_{m1}}{b_0 z + b_1}$$

And if we assume $R = 1$ when we can say:

$$S = \frac{A_m - A}{B} = \frac{(a_m - a)z^2 + (a_{m0} - a_0) z + (a_{m1} - a_1)}{b_0 z + b_1}$$

In all cases, $$(a_m - a)z^2= 0$$ so $S$ will be:

$$S = \frac{A_m - A}{B} = \frac{(a_{m0} - a_0) z + (a_{m1} - a_1)}{b_0 z + b_1}$$


This will work, if the $G(s)$ system has no positive zeros. Rigth now, it has one zero at 2. When I simulate the system, it look like this:

enter image description here

enter image description here

How can I find the polynomals $T, R, S$ so the model $G(s)$ can follow $G_m(s)$ ?


If you use Recursive Least Square(RLS) to estimate $b_0, b_1, a_0, a_1$, then you have a self tuning controller.


I tried this:

enter image description here

And the result was:

The system above:

enter image description here

The system below: enter image description here

Clearly I can se that the $z$ variable is out of the unit circle = unstable system:

$$1.2233809 = \frac{0.2098316}{0.1715178}$$

So $T, S$ are unstable transfer functions. How can I make them stable?

  • $\begingroup$ With feedback you can't change the closed loop zeros. What you are doing is choosing the controller to be the inverse of the plant times a control law which would give the desired closed loop dynamics, but that first part should give pole zero cancellations. However in order to simulate such system you have to consider the minimal realisation. Anyway when the plant has a "unstable" zero, the inverse will be unstable, so the actual controller will be internally unstable. $\endgroup$ – Kwin van der Veen Jun 24 '18 at 2:27
  • $\begingroup$ Do you have any ideas how to create the control law? $\endgroup$ – Daniel Mårtensson Jun 24 '18 at 8:57
  • 1
    $\begingroup$ You can't achieve that closed loop dynamics, since when using this for a plant which has "unstable" zeros the closed loop will always be unstable. $\endgroup$ – Kwin van der Veen Jun 24 '18 at 11:07
  • $\begingroup$ @KwinvanderVeen So if I model a transfer function with unstable zeros, I have model a wrong model? $\endgroup$ – Daniel Mårtensson Jun 24 '18 at 11:20
  • $\begingroup$ @KwinvanderVeen According to Karl Johan Åström, the author of "Adaptive Control, Second Edition, Page 119". It's possible to have those dynamics for a closed loop non-minimum phase system. bayanbox.ir/view/8821671619590593184/… $\endgroup$ – Daniel Mårtensson Jun 24 '18 at 11:22

I found a answer now!

In this case $B$ was $b_0 z + b_1$.

I set

$$b_0 = - |\frac{A_m(1)}{B(1)} + 0.01|= -|\frac{0.8693582−1.8600345*1+1^2}{0.2098316−0.1715178*1} + 0.01| -1.71$$

And $$b_1 = |\frac{A_m(1)}{B(1)}| = |\frac{0.8693582−1.8600345*1+1^2}{0.2098316−0.1715178*1}| = 1.71$$

The constant of 0.01 is just so the denominator don't having an integration effect.

enter image description here

And the result was:

enter image description here

One issue left is the reference tracking factor. Right now the step answer is -3 and the $y$ is 0.95. I need a reference tracking. Do you know how to create one? It's need to be an adaptive one!


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.