Impulse, step and ramp response of a differential equation.

1.2k Views Asked by At

Two months ago I had a test about systems and their properties. One part of the test was an electrical circuit system and the diff. equation I got from that circuit was:

$2\cdot10^{-2}y' + y = 10^4 x + 10^2 x'$

And part of the question was to get the ramp, step and unit response of the system (everything in time, I couldn't use Laplace or other type of transformations). First I found the general solution of the system which is $y=Ae^{\frac{-10^2}{2}t}$ for t>0. Then, to find the ramp response I equaled $x=t{\cdot}u(t)$. So the particular solution to that input is $y=10^4t-10^2$ for t>0. Solving for $y(0)=0$, the ramp response is

$y=10^2{\cdot}e^{\frac{-10^2}{2}t}+10^4t-10^2$ for t>0 or $y=10^2{\cdot}e^{\frac{-10^2}{2}t}u(t)+10^4t{\cdot}u(t)-10^2u(t)$

Derivating the ramp response I get step response which is

$s(t)=-\frac{1}{2}\cdot10^4e^{\frac{-10^2}{2}t}u(t)+10^4u(t)$

and finally I get the impulse response which is

$h(t)=\frac{1}{4}\cdot10^6e^{\frac{-10^2}{2}t}u(t)+\frac{1}{2}\cdot10^4\delta(t)$

Those were the answers of my test and I don't know why my teacher mark them as wrong, I was sure that I got that answer right and when my test came back I got 0 in that part. Lately I couldn't get that question out of my head because I'm sure what I did is right, because I even did that same problem, but this time using Laplace and I got the same answers. According to the teacher, to get the responses I should had solve for $2\cdot10^{-2}y' + y = 10^4x$ and then solve for $2\cdot10^{-2}y' + y = 10^2 x'$ and sum them at the end, because if I equaled $x'=u(t)$ the solution I would get is the response to the ramp, I know that, but what I don't know is why the method I chose to follow was wrong.

Did the teacher make a mistake by marking me wrong, or the answers that I get coincidently are the same as the correct answers. If I was wrong, can someone please tell me how to sum the responses I get separately or how is it done. Thanks in advance.

Edit: Also, I don't know the teacher's answer, he said a month ago he was going to upload the solution but he never did, so I don't know which are his ¨correct¨ answers.

2

There are 2 best solutions below

0
On

You can test the answer when you do use Laplace transform:

$$2\cdot10^{-2}\cdot\text{y}'\left(t\right)+\text{y}\left(t\right)=10^4\cdot\text{x}\left(t\right)+10^2\cdot\text{x}'\left(t\right)\space\space\space\to^{\space\mathcal{L}}$$ $$2\cdot10^{-2}\cdot\text{s}\cdot\text{Y}\left(\text{s}\right)-2\cdot10^{-2}\cdot\text{y}\left(0\right)+\text{Y}\left(\text{s}\right)=10^4\cdot\text{X}\left(\text{s}\right)+10^2\cdot\text{s}\cdot\text{X}\left(\text{s}\right)-10^2\cdot\text{x}\left(0\right)$$

So, when $\text{x}\left(t\right)$ is the input, solve $\text{Y}\left(\text{s}\right)$:

$$\text{Y}\left(\text{s}\right)=\frac{5000\cdot\left(\text{X}\left(\text{s}\right)\cdot\left(100+\text{s}\right)-\text{x}\left(0\right)\right)+\text{y}\left(0\right)}{50+\text{s}}$$

For example:

  1. When $\text{x}\left(t\right)=\theta\left(t\right)$: $$\text{Y}\left(\text{s}\right)=\frac{5000\cdot\left(\frac{1}{\text{s}}\cdot\left(100+\text{s}\right)-\text{x}\left(0\right)\right)+\text{y}\left(0\right)}{50+\text{s}}$$

So:

$$\text{y}\left(t\right)=10000+e^{-50t}\cdot\left(\text{y}\left(0\right)-5000\cdot\left(1+\text{x}\left(0\right)\right)\right)$$

  1. When $\text{x}\left(t\right)=\delta\left(t\right)$: $$\text{Y}\left(\text{s}\right)=\frac{5000\cdot\left(1\cdot\left(100+\text{s}\right)-\text{x}\left(0\right)\right)+\text{y}\left(0\right)}{50+\text{s}}$$

So:

$$\text{y}\left(t\right)=5000\cdot\delta\left(t\right)+e^{-50t}\cdot\left(\text{y}\left(0\right)-5000\cdot\left(\text{x}\left(0\right)-50\right)\right)$$

0
On

Same idea as Jan but using Maxima to inverse the Laplace transform

$$c1*y' + y = c2*x + c3*x'$$

$$c1*(s*Y - y0) + Y = c2*X + c3*(s*X - x0)$$

$$(c1*s+1)*Y = (c3*s+c2)*X + c1*y0 - c3*x0$$

$$Y = X*(c3*s+c2)/(c1*s+1) + (c1*y0 - c3*x0)/(c1*s+1)$$

Maxima instructions

ilt(X(s)*(10^2*s+10^4)/(2*10^-2*s+1) + (2*10^-2*y0 - 10^2*x0)/(2*10^-2*s+1),s,t); 

$\delta(t) \to X(s) = 1$

ilt( 5000 +  5000/(2*10^-2*s+1) + (2*10^-2*y0 - 10^2*x0)/(2*10^-2*s+1),s,t); 

$u(t) \to X(s) = \frac1{s}$

ilt(1/s*(10^2*s+10^4)/(2*10^-2*s+1) + (2*10^-2*y0 - 10^2*x0)/(2*10^-2*s+1),s,t); 

$ t \to X(s) = \frac1{s^2}$

ilt(1/s^2*(10^2*s+10^4)/(2*10^-2*s+1) + (2*10^-2*y0 - 10^2*x0)/(2*10^-2*s+1),s,t); 

results:

$$y_{delta}(t) = e^ {- 50\,t }\,\left({\it y_0}-5000\,{\it x_0}\right)+250000\,e ^ {- 50\,t }+ 5000 \, \delta(t)$$

$$y_{step}(t) = e^ {- 50\,t }\,\left({\it y_0}-5000\,{\it x_0}\right)-5000\,e^ {- 50\,t }+10000$$

$$y_{ramp}(t) = e^ {- 50\,t }\,\left({\it y_0}-5000\,{\it x_0}\right)+100\,e^ {- 50 \,t }+10000\,t-100$$