To transform a function f(t) into the Laplace domain in Matlab, you can use the Symbolic Math Toolbox. Here's an example of how to do it:
main.m149 chars5 lines
In this example, f(t) = cos(2t) - 3e^(-4t) is defined as a symbolic expression using the syms command. The Laplace transform of f is then obtained using the laplace function. Finally, the result is simplified using the simplify function.
You can substitute specific values for s to obtain the Laplace transform at specific points in the complex plane. For example:
main.m78 chars3 lines
This will give you the Laplace transform of f at s=1+i and s=2, respectively.
gistlibby LogSnag