# Variation of Parameters Diff EQ

Printable View

• Feb 24th 2008, 05:34 PM
jblorien
Variation of Parameters Diff EQ
Hey all,

heres the differential equation to be solved using Variation of parameter's:

y" + y = sin(x)^2

i got this far:

u1'cos(2x) + u2'sin(2x) =0
-2*u1'*sin(2x) + 2*u2'*cos(2x) = sin(x)^2

solving for u1' gives: (-sin(x)^2*sin(2x))/2

and u2': (-sin(x)^2*cos(2x))/2

The final solution should take the form

u1*cos(2x) + u2*sin(2x)

so whats left is integrating u1' and u2'. Unfortunately due to problems with integrating and simplfying trig expressions i'm not getting the solution which is

1/8(1-xsin(2x))

thanks alot
• Feb 24th 2008, 05:52 PM
TheEmptySet
The double formulas
This may help with your integrals

$sin(2\theta)=2sin(\theta)cos(\theta)$

and

$cos(2\theta)=1-2sin^2(\theta)$

so

$u_1=\frac{1}{2}\int\sin^3(x)cos(x)dx$

the other

$u_2=-\frac{1}{2}\int\sin^2(x)(1-2sin^2(x))dx$

You can use the reduction formula for u2 or the half angle formula

I hope this helps
• Feb 24th 2008, 06:22 PM
TheEmptySet
Let me see if I have this correct...

$y''+y=\sin^2(x)$

If this is the case then our complementry solution is

$y=c_1\sin(x)+c_2\cos(x)$

so computing the wronskian
$\begin{vmatrix}\sin(x) & \cos(x) \\ \cos(x) & -\sin(x)\end{vmatrix}=-1$

then

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

and

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

this would give the integrals

$\int\cos(x)\sin^2(x)dx$

and

$-\int\sin^3(x)dx$
• Feb 24th 2008, 06:31 PM
jblorien
i'm so sorry.

its acutally y" +4y = sin(x) ^2

this is why it takes the form

c1*cos(2x) + c2(sin(2x)
• Feb 24th 2008, 07:55 PM
TheEmptySet
Alright, lets try this again...

$y''+4y=\sin^2(x)$

If this is the case then our complementry solution is

$y=c_1\sin(2x)+c_2\cos(2x)$

so computing the wronskian
$\begin{vmatrix}\sin(2x) & \cos(2x) \\ 2\cos(2x) & -2\sin(2x)\end{vmatrix}=-2$

then

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

and

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

this would give the integrals

$\frac{1}{2}\int\cos(2x)\sin^2(x)dx$

and

$-\frac{1}{2}\int\sin^2(x)\sin(2x)dx$

$\frac{1}{2}\int\cos(2x)\sin^2(x)dx=\frac{1}{2}\int (1-2\sin^2(x))\sin^2(x)dx =$

$\frac{1}{2}\int\sin^2(x)dx-\int(\sin^2(x))^2dx$

by the double angle formula...

$\frac{1}{2}\int2\sin(x)\cos(x)dx-\int(2\sin(x)\cos(x))^2dx=$

$\int\sin(x)\cos(x)dx-4\int\sin^2(x)\cos^2(x)dx =$

using the double angle formula again on sine...

$\int\sin(x)\cos(x)dx-4\int2\sin(x)\cos(x)\cos^2(x)dx =$
$\int\sin(x)\cos(x)dx-8\int\sin(x)\cos^3(x)dx$

finally, now we let $u=\cos(x)$ and $du=-\sin(x)dx$
This yeilds... $u_1=-\frac{1}{2}\cos^2(x)+2\cos^4(x)$

$u_2$ is a bit better

$-\frac{1}{2}\int\sin^2(x)\sin(2x)dx$
rewritting with the double angle formula

$-\frac{1}{2}\int\sin^2(x)(2\sin(x)\cos(x))dx=-\int\sin^3(x)\cos(x)dx$

with $u=sin(x)$ and $du=\cos(x)dx$ we get

$u_2=-\frac{1}{4}\sin^4(x)$

I hope this gets it...
• Feb 24th 2008, 08:10 PM
jblorien
I follow all of your work,

but it seems when i try to get my final particular solution in the form

yp = u1*sin(2x) + u2*cos(2x)

i'm not getting the solution

1/8(1-x*sin(2x))

am i wrong in saying the particular solution yp should be in the form

yp = u1*sin(2x) + u2*cos(2x)
• Feb 25th 2008, 07:51 PM
jblorien
I get it now, thanks alot