Help with Laplace ODE
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
gurjeevan singh
le 3 Mai 2021
Commenté : Star Strider
le 5 Mai 2021
Help solving this laplace ode with intial condition, my a and b values are respectively. I have tried solving this Laplace ode without using my a and b values. below is my code.
Any help is massively appreciated! Thank you
syms t y(t) Y(s) Dy0 a b y0
Dy1 = diff(y,t,1);
eqn = laplace(Dy1== a*sinh(a*t));
eqn = subs(eqn, {laplace(y(t), t, s), subs(diff(y(t), t), t, 0), y(0)},{Y(s), 0,0})
cond= y(0)==22;
Ys(s)= simplify(eqn/Y);
yt = ilaplace(Ys,s,t)
0 commentaires
Réponse acceptée
Star Strider
le 4 Mai 2021
Try this —
syms t y(t) Y(s) Dy0 a b y0
Dy1 = diff(y,t,1);
eqn = laplace(Dy1== a*sinh(a*t))
eqn = subs(eqn, {laplace(y(t), t, s), subs(diff(y(t), t), t, 0), y(0)},{Y(s), 0, 22}) % Substitute 'y(0)' Here
% cond= y(0)==22;
eqn = isolate(eqn, Y)
y(t,a) = ilaplace(rhs(eqn))
figure
fplot(y(t,34), [-0.1 0.1]) % Substitute 'a' Here
grid
.
10 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Symbolic Math Toolbox dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!