define constants inside a laplace function

8 visualizaciones (últimos 30 días)
Ivonne R
Ivonne R el 22 de Sept. de 2015
Respondida: Walter Roberson el 23 de Sept. de 2015
I'd like to get the Laplace of a window function. I'd get the right output if I write this:
b=1;a=2;
syms t s
laplace((heaviside(t-a)-heaviside(t-b)))
ans =
exp(-2*s)/s - exp(-s)/s
but I'd like to preserve a and b as constants. However when I defined as " syms t s a b " it doesn't give the Laplace Transform because there's too many variables. Thanks!

Respuestas (1)

Walter Roberson
Walter Roberson el 23 de Sept. de 2015
laplace((heaviside(t-a)-heaviside(t-b)), t, s)

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by