# Math Help - [SOLVED] initial value problem

1. ## [SOLVED] initial value problem

Solve the following initial value problem
y′′ + 9y = 3 cos(3x), y(0) = 0, y(0) = 0 and write the final solution using real valued functions. Sketch the graph of the solution in a x-y diagram.

Can someone help me solve this?
This is what i done so far

y′′ + 9y - 3 cos(3x)= 0
z^2 +9z -3 cos(3x)= 0

z^2+6z+3z -3cos(3x)=0
z(z+6) + 3(z-cos(3x))=0

(z+3)(z+6)(z-cos(3x))=0

2. Originally Posted by ronaldo_07
Solve the following initial value problem
y′′ + 9y = 3 cos(3x), y(0) = 0, y(0) = 0 and write the final solution using real valued functions. Sketch the graph of the solution in a x-y diagram.

Can someone help me solve this?
This is what i done so far

y′′ + 9y - 3 cos(3x)= 0
z^2 +9z -3 cos(3x)= 0

z^2+6z+3z -3cos(3x)=0
z(z+6) + 3(z-cos(3x))=0

(z+3)(z+6)(z-cos(3x))=0

Nothing that you have done so far makes sense. Why did you replace y with z and y" with $z^2$? If you are trying to find the "characteristic equation" for this differential equation, that only works for homogeneous equations. First solve the associated homogeneous equation.

3. Originally Posted by ronaldo_07
Solve the following initial value problem

y′′ + 9y = 3 cos(3x), y(0) = 0, y(0) = 0 and write the final solution using real valued functions. Sketch the graph of the solution in a x-y diagram.

Can someone help me solve this?
This is what i done so far

y′′ + 9y - 3 cos(3x)= 0
z^2 +9z -3 cos(3x)= 0

z^2+6z+3z -3cos(3x)=0
z(z+6) + 3(z-cos(3x))=0

(z+3)(z+6)(z-cos(3x))=0

You need to break this problem up into two parts.

Fist we need to solve the homogenious equation

$y''+9y=0 \implies m^2+9m=0 \implies m=\pm 3i$

So this gives us the complimentry solution

$y_c=c_1\cos(3x)+c_2\sin(3x)$

Now we need to find a particualr solution. There are a few different ways to do this, but here is one way.

$w=\begin{vmatrix}
\cos(3x) & \sin(3x) \\
-3\sin(3x) & 3\cos(3x)
\end{vmatrix}=3$

$w_1=\begin{vmatrix}
0 & \sin(3x) \\
3\cos(3x) & 3\cos(3x)
\end{vmatrix}=-\sin(3x)\cos(3x)$

$w_2=\begin{vmatrix}
\cos(3x) & 0 \\
-3\sin(3x) & 3\cos(3x)
\end{vmatrix}=\cos^2(3x)$

$
u_1'=\frac{w_1}{w} \implies u=-\int \sin(3x)\cos(3x)dx=\frac {1}{6} \cos^2(3x)
$

$u_2'=\frac{w_2}{w} \implies \int \cos^2(3x)dx=\frac{1}{2}x+\frac{1}{6}\sin(3x)\cos( 3x)$

so

$y_p=\frac{1}{6}\cos^3(3x)+(\frac{1}{2}x+\frac{1}{6 }\sin(3x)\cos(3x))\sin(3x)=$

$y_p=\frac{1}{6}\cos^3(3x)+\frac{x}{2}\sin(3x)+\fra c{1}{6}\sin^2(3x)\cos(3x)=$

$y_p=\frac{1}{6}\cos^3(3x)+\frac{x}{2}\sin(3x)+\fra c{1}{6}(1-\cos^2(3x))\cos(3x)=$

$y_p=\frac{x}{2}\sin(3x)+\frac{1}{6}\cos(3x)$

so the final solution is

$y=y_c+y_p=c_1\cos(3x)+c_2\sin(3x)+\frac{x}{2}\sin( 3x)+\frac{1}{6}\cos(3x)$

Now using the intial conditions we get

$0=c_1+\frac{1}{6} \iff c_1=-\frac{1}{6}$

$y=c_2\sin(3x) + \frac{x}{2}\sin(3x)$

taking the derivative we get

$y'=3c_2\cos(3x)+\frac{1}{2}\sin(3x)+\frac{3x}{2}\c os(3x)$

using the 2nd ic we get

$0=3c_2 \iff c_2=0$

$y=\frac{x}{2}\sin(3x)$