Confusion with step response and laplace inverse
2 views (last 30 days)
Show older comments
Hey all
Im hoping someone can explain this
This is fairly embarrassing i don't remember why this is not working out
Simple RC circuit
We know the transfer function to be the following
Vout/Vin = (1)/(S*R*C+1)
Or if you want to rearrange it in the proper form you get.
(1/RC)/(S+1/RC)
Anyways. If you give this thing a step input you get a curve that looks like the following using matlab
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/159837/image.png)
Again no surprise. As the cap begins to block the voltage builds up as the current flow tends towards zero
No surprise here
So anyway here is what i can't remember.
Just for the hell of it, i was trying to take the laplace and do the inverse and plot it in math against time t without using the step command. Obviously i should get the same results
The inverse is easily found using the table of course
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/159838/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/159839/image.png)
Now lets just take something simple
Say R = 1k and C = 1u
And plot the thing
You get something very different then what the step response should be
You clearly get a decay which is obviously not the case. Step response of RC is an exponential growth then settles which is very well known
So what am i missing? Why when put back into time does the function not behave properly? or more likely, what am i doing wrong here? Note the second plot is just an example not the exact plot
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/159841/image.png)
0 Comments
Accepted Answer
Star Strider
on 16 Jan 2017
Try this:
syms R C s t
Z = 1/(R*C)/(s + 1/(R*C));
V = 1/s;
H = Z*V;
h = ilaplace(H,s,t);
h = subs(h, {R,C}, {1, 1E-6});
figure(1)
fplot(h, [0, 5E-6])
grid
Since you’re starting at t=0 (I assume), a=0, and:
h = 1 - exp(-1000000*t)
giving the expected output.
0 Comments
More Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!