Message Boards Message Boards

Avoid problem with solving the LaplaceTransform and inversing it?

GROUPS:

Hello all,

I have been working on a project involving the Laplace equation. Sadly enough, somehow I don't get it to work. I have tried looking for a solution in the manual of Mathematica and tried several solutions, but non of them seem to work. Every time I end up getting the same thing, with the words LaplaceTransform and InverseLaplaceTransform, as I put in. I have tried using different domains for the NSolve, as well as reformulating the whole function which needs to be solved and trying different ways of formulating the variable t in the NSolve. The idea is that I get the Laplace transformation of the function (2nd line in the code), get a solution for variable t. After which the inverse Laplace transformation should be taking from this solution. My starting code is as following:

Clear["Global`*"]
Sin[\[Omega] t] == 
 q''[t]/Subscript[dw, 0]^2 + (2 \[Xi]q'[t])/Subscript[dw, 0] + q[t]/d

LaplaceTransform[%, t, s]
NSolve[%, t]
InverseLaplaceTransform[%, s, t]

Gratitude in advance.

Kind regards, Justin Warners

POSTED BY: Justin Warners
Answer
18 days ago

Welcome to Wolfram Community! Please make sure you know the rules: https://wolfr.am/READ-1ST

Please EDIT your post and make the title informative and concise, as advised in the rules linked above.

POSTED BY: Moderation Team
Answer
18 days ago

Hello

You made a syntax mistake.

 Sin[\[Omega] t] == q''[t]/Subscript[dw, 0]^2 + (2 \[Xi]q'[t])/Subscript[dw, 0] + q[t]/d

It should be:

 Sin[\[Omega] t] == q''[t]/Subscript[dw, 0]^2 + (2 \[Xi] q'[t])/Subscript[dw, 0] + q[t]/d

You forgot a backspace to add between $\xi$ and q'(t)

NSolve is a numerical solver, can't solve a symbolically.

   Clear["Global`*"]

   eq = Sin[\[Omega] t] == q''[t]/Subscript[dw, 0]^2 + (2*\[Xi] *q'[t])/Subscript[dw, 0] + q[t]/d

   eq1 = LaplaceTransform[eq, t, s] /. q[0] -> 0 /. q'[0] -> 0 (* Initial conditions,you may delete it or change to:  eq1 = LaplaceTransform[eq, t, s] *)

   sol = First@Solve[eq1, LaplaceTransform[q[t], t, s]] // Simplify

   q[t] = InverseLaplaceTransform[LaplaceTransform[q[t], t, s] /. sol, s, t]
POSTED BY: Mariusz Iwaniuk
Answer
18 days ago

First, I think, you have a typo. There should be a blank between [Xi] and q'[t]).

Then as far as I know one should solve the transformed equation for the Laplacetransform and then apply the inverse transformation (if possible). I did that as outlined in the notebook attached

Attachments:
POSTED BY: Hans Dolhaine
Answer
18 days ago

Group Abstract Group Abstract