moi
2018-11-10 05:45:10 UTC
Hello,
I'm trying to convert a function from continuous time to discrete time.
There is following continuous time transfer function.
Gc = 1 / (1 + 0.1*s)
I converted to continuous time state space.
Gsl = tf2ss(Gc)
and converted to discrete time state space with dt = 0.001 sec.
Gsd = dscr(Gsl, 0.001)
Finally, converted to discrete time transfer function.
Gd = ss2tf(Gsd)
The result is following:
Gd =
0.0099502
---------------
-0.9900498 + z
I converted these function with the inverse Laplace transform and the
inverse z transform.
Inverse Laplace transform:
L^-1[Gc] = y(t) = 10*e^(-10*t)
Inverse Z transform:
Apply 'z^-1' to numerator and denominator.
Z^-1[Gd] = 0.0099502 * z^-1 / (-0.9900498 * z^-1 + 1)
Apply the inverse z transform formula 'L^-1[1/(1 - az)] = a^n * u[n]'
and 'L^-1[z^-k * F] = D^k * F'.
Z^-1[Gd] = 0.0099502 * D^-1 * 0.9900498^n * u[n];
y[n] = 0.0099502 * 0.9900498^[n-1] * u[n];
I calculated these expressions in Excel.
t y(t) y[n]
0 10 0.0099502
1 9.900498337 0.0099502
2 9.801986733 0.009851194
3 9.704455335 0.009753172
4 9.607894392 0.009656126
5 9.512294245 0.009560046
6 9.417645336 0.009464921
7 9.323938199 0.009370744
8 9.231163464 0.009277503
9 9.139311853 0.00918519
The numerical value is greatly different.
Did I mistake something?
Thanks in advance.
moi
I'm trying to convert a function from continuous time to discrete time.
There is following continuous time transfer function.
Gc = 1 / (1 + 0.1*s)
I converted to continuous time state space.
Gsl = tf2ss(Gc)
and converted to discrete time state space with dt = 0.001 sec.
Gsd = dscr(Gsl, 0.001)
Finally, converted to discrete time transfer function.
Gd = ss2tf(Gsd)
The result is following:
Gd =
0.0099502
---------------
-0.9900498 + z
I converted these function with the inverse Laplace transform and the
inverse z transform.
Inverse Laplace transform:
L^-1[Gc] = y(t) = 10*e^(-10*t)
Inverse Z transform:
Apply 'z^-1' to numerator and denominator.
Z^-1[Gd] = 0.0099502 * z^-1 / (-0.9900498 * z^-1 + 1)
Apply the inverse z transform formula 'L^-1[1/(1 - az)] = a^n * u[n]'
and 'L^-1[z^-k * F] = D^k * F'.
Z^-1[Gd] = 0.0099502 * D^-1 * 0.9900498^n * u[n];
y[n] = 0.0099502 * 0.9900498^[n-1] * u[n];
I calculated these expressions in Excel.
t y(t) y[n]
0 10 0.0099502
1 9.900498337 0.0099502
2 9.801986733 0.009851194
3 9.704455335 0.009753172
4 9.607894392 0.009656126
5 9.512294245 0.009560046
6 9.417645336 0.009464921
7 9.323938199 0.009370744
8 9.231163464 0.009277503
9 9.139311853 0.00918519
The numerical value is greatly different.
Did I mistake something?
Thanks in advance.
moi