How do I use Inverse LaPlace Transform
8 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I need to inverse LaPlace transform this.
clc; clear all; close
num=[100 4000 70000 600000 3e6];
den=[1000 5e4 1.1e6 1.3e7 9e7 3e8 1e9];
pfract(num,den)
H=tf(num,den)
damp(H);
Output =
From input 1 to output:
-1.329e-17 s + 0.01076
----------------------
s^2 + 32.47 s + 324.7
From input 2 to output:
1.167e-17 s + 0.03493
---------------------
s^2 + 15.55 s + 155.5
From input 3 to output:
3.961e-18 s + 0.05431
---------------------
s^2 + 1.981 s + 19.81
Continuous-time transfer function.
The output is in partial fraction form. I need the inverse to get into the time domain for all three inputs.
I have tried using ilaplace(H) and I get this error.

0 comentarios
Respuestas (1)
Walter Roberson
el 10 de Mzo. de 2021
you need to use the symbolic toolbox. Query the coefficients for the tf to get cell arrays of numeric coefficients. Use poly2sym to construct symbolic polynomials. Divide appropriate parts. ilaplace.
2 comentarios
Walter Roberson
el 10 de Mzo. de 2021
Editada: Walter Roberson
el 10 de Mzo. de 2021
The s you see in your transfer functions is not a symbolic variable: it is a label introduced into the display. Sort of like
den=[1000 5e4 1.1e6 1.3e7 9e7 3e8 1e9];
exponent = length(den)-1:-1:0;
strjoin(den + " s^" + exponent, " + ")
Just text, not an actual variable.
Your pfract() is not part of MATLAB; it appears to be part of a textbook; code can currently be found at https://www.scribd.com/document/177697560/Chapter-13-m-files-docx . I am not going to type it in for this purpose, so I will work just on the easy transfer function, H:
num = [100 4000 70000 600000 3e6];
den = [1000 5e4 1.1e6 1.3e7 9e7 3e8 1e9];
H = tf(num,den)
N = H.Numerator
D = H.Denominator
syms s t
time_domain = cellfun(@(n,d) simplify(ilaplace(poly2sym(n,s)/poly2sym(d,s), s, t)), N, D)
You will notice that this is expressed in terms of roots of polynomials of degree 6. Unfortunately MATLAB does not offer any way of expanding those even for degree up to 4. https://www.mathworks.com/matlabcentral/answers/618168-how-do-i-plot-an-inverse-laplace-symbolic-to-vectorized-equations#answer_517418
I could write code that broken upon those sums of roots, but it is a nuisance to get right as the roots are not used directly (they are used in exp(ROOT*t) for example)
Ver también
Categorías
Más información sobre Calculus en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
