classical methods

logistic_guy

Senior Member
Joined
Apr 17, 2024
Messages
1,490
Solve the following differential equation using classical methods and the given initial conditions.

\(\displaystyle \frac{d^2 x}{dt^2} + 2\frac{dx}{dt} + 2x = \sin 2t\)

\(\displaystyle x(0) = 2; \ \ \ \frac{dx}{dt}(0) = -3\)
 
First we solve the homogeneous.

\(\displaystyle \frac{d^2 x}{dt^2} + 2\frac{dx}{dt} + 2x = 0\)

\(\displaystyle r = \frac{-2\pm\sqrt{2^2 - 4(1)(2)}}{2(1)} = -1\pm i\)

Then, the solution is:

\(\displaystyle x(t) = c_1 e^{-t}\cos t + c_2 e^{-t}\sin t\)
 
Now we will look for a particular solution of the form \(\displaystyle x_p(t) = A\cos 2t + B\sin 2t\)

\(\displaystyle \frac{dx_p}{dt} = -2A\sin 2t + 2B\cos 2t\)

\(\displaystyle \frac{d^2x_p}{dt^2} = -4A\cos 2t - 4B\sin 2t\)

When we substitute this in the original differential equation, we get:

\(\displaystyle -4A\cos 2t - 4B\sin 2t + 2(-2A\sin 2t + 2B\cos 2t) + 2(A\cos 2t + B\sin 2t) = \sin 2t\)

\(\displaystyle -4A\cos 2t - 4B\sin 2t - 4A\sin 2t + 4B\cos 2t + 2A\cos 2t + 2B\sin 2t = \sin 2t\)

\(\displaystyle (4B - 2A)\cos 2t + (-2B - 4A)\sin 2t = \sin 2t\)

If we compare the left side with the right side, we see that:

\(\displaystyle 4B - 2A = 0\)
\(\displaystyle -2B - 4A = 1\)

This gives:

\(\displaystyle A = 2B\)
\(\displaystyle -2B -4(2B) = 1\)
\(\displaystyle -2B - 8B = 1\)
\(\displaystyle -10B = 1\)
\(\displaystyle B = -\frac{1}{10}\)

And

\(\displaystyle A = 2\left(-\frac{1}{10}\right) = -\frac{1}{5}\)

Then,

\(\displaystyle x_p(t) = -\frac{1}{5}\cos 2t - \frac{1}{10}\sin 2t\)

💪😒
 
The general solution is:

\(\displaystyle x(t) = c_1e^{-t}\cos t + c_2e^{-t}\sin t - \frac{1}{5}\cos 2t - \frac{1}{10}\sin 2t\)

All remained is just to apply the initial conditions. And the idea of those conditions is to find the two constants \(\displaystyle c_1\) and \(\displaystyle c_2\).

That's what we'll do in the next post.
 
Let us apply the first initial conditions.

\(\displaystyle x(0) = 2 = c_1 - \frac{1}{5}\)

This gives:

\(\displaystyle c_1 = 2 + \frac{1}{5} = \frac{10}{5} + \frac{1}{5} = \frac{11}{5}\)
 
Let us apply the second initial condition.

\(\displaystyle \frac{dx}{dt} = -c_1e^{-t}\cos t + c_1e^{-t}(-\sin t) - c_2e^{-t}\sin t + c_2e^{-t}\cos t + \frac{2}{5}\sin 2t - \frac{2}{10}\cos 2t\)

\(\displaystyle \frac{dx}{dt}(0) = -3 = -c_1 + c_2 - \frac{2}{10} = -\frac{11}{5} + c_2 - \frac{2}{10}\)

This gives:

\(\displaystyle c_2 = \frac{11}{5} + \frac{2}{10} - 3 = -\frac{3}{5}\)
 
The FINAL general solution is:

\(\displaystyle x(t) = \frac{11}{5}e^{-t}\cos t - \frac{3}{5}e^{-t}\sin t - \frac{1}{5}\cos 2t - \frac{1}{10}\sin 2t\)
 
Top