Laplace of Constant a

23 views (last 30 days)
Jeff Lee
Jeff Lee on 9 Oct 2019
Commented: Star Strider on 15 Dec 2020
Hi,
I can't get Matlab to return the correct answer for a single constant. Lest say a
For example
f(t)=1
LT f(t) =1/s
However what I change 1 to a constant matlab return the incorrect answer
Why does matlab not like the constant? As the laplace inverse of 1/s^2 = t

Accepted Answer

Star Strider
Star Strider on 9 Oct 2019
You must tell the laplace function what the independent variable and transformation variable are. It has no way of knowing, otherwise.
Using your example:
syms a s t
f1 = (a*t)/t
F1 = laplace(f1,t,s)
producing:
f1 =
a
F1 =
a/s
  4 Comments
Cosmas Kwalira-Phiri
Cosmas Kwalira-Phiri on 15 Dec 2020
Thanks you have helped me too
Star Strider
Star Strider on 15 Dec 2020
Cosmas Kwalira-Phiri —
My pleasure!
Thanks for the Vote!

Sign in to comment.

More Answers (0)

Categories

Find more on Loops and Conditional Statements in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!