DunWorry
- 40
- 0
Homework Statement
basically solve \frac{d^{2}y}{dx^{2}} + 4\frac{dy}{dx} + 4y = cos2x
Boundary conditions are y=0, dy/dx =1 at x=0
Homework Equations
The Attempt at a Solution
I am having trouble getting the coefficients to the solution. I got the complementary function as y_{cf} = (A_{1}x+A_{2})e^{-2x}
and the paticular integral is y_{PI} = Bcos2x
So first I find coefficient B I \frac{dy}{dx} = -2Bsin2x
and \frac{d^{2}y}{dx^{2}} = -4Bcos2x
Now I sub back into equation and compare coefficients I get -4Bcos2x -8Bsin2x + 4Bcos2x = cos2x
This simplifies to -8Bsin2x = cos2x. I am not sure how I am supposed to compare coefficients here, in the answers it looks like the particular integral is \frac{1}{8} sin2x. If I rearrange -8Bsin2x = cos2x I get B = - \frac{1}{8}cotx
So not only have I got the trig function wrong but I got the sign wrong too, have I done something wrong elsewhere?
Thanks