3

Let's say that I have the following continuous system:

$$G(s)= \frac{2}{1+s}$$

I could convert it to a discrete system using for example the Tustin approximation https://en.wikipedia.org/wiki/Bilinear_transform

So I replace s with:

$$s \rightarrow{} \frac{2(1-z^{-1})}{T_e(1+z^{-1})} $$

Hence I get the approx. discrete transfer function:

$$G(z)= \frac{2}{1+\frac{2(1-z^{-1})}{T_e(1+z^{-1})}}$$

Now my question is, how can I compute its frequency response ?

In the end, I would like to be able to compare the discrete approx. freqe. response with the freq. response of the continuous original transfer function.

james
  • 268
  • 2
  • 9

2 Answers2

5

If you want to evaluate a continues time transfer function at a specific frequency $\omega$ in rad/s you substitute $s$ with $j\,\omega$. For a discrete time transfer function you substitute $z$ with $e^{T_e\,j\,\omega}$.

In order to see why you have to substitute $z$ with $e^{T_e\,j\,\omega}$ you can consider the transfer function $z^{-1}$, which is a delay of $T_e$. So the response to $\sin(\omega\,t)$ would be $\sin(\omega\,(t-T_e))$ which is equivalent to $\sin(\omega\,t-\omega\,T_e)$. The frequency response function should therefore have a constant magnitude of one (or 0 dB), since the output sine wave always has the same amplitude as the input sine wave and the amount of phase shift the output has relative to the input is $-\omega\,T_e$. It can be shown that both the amplitude and phase are captured by $e^{-T_e\,j\,\omega}$, where the minus sign is because we are considering $z^{-1}$ instead of $z$.

fibonatic
  • 1,663
  • 9
  • 13
2

In matlab, using c2d (link) and bode (link) functions:

s = tf('s');
G_c = 2/(1+s);
Ts = 1;
G_d = c2d(G_c,Ts,'Tustin');
bode(G_c), hold on, bode(G_d)

enter image description here