Question #36319

How to find excat solution of y'+ y =x + cos x

i am doing euler method but could not find a method to find exact solution of above probelm?plz explain with steps it is first order differental equation.pls note that i have find y using euler method.
1

Expert's answer

2013-10-23T08:50:15-0400

How to find exact solution of y+y=x+cosxy' + y = x + \cos x?

I am doing Euler method but could not find a method to find exact solution of above problem? Please explain with steps it is first order differential equation. Please note that I have find yy using Euler method.

Solution.

Using the Euler method, we could not find an exact solution. We find the solution with some error.

Use an integrating factor for solving our ODE. We have ODE in the form


y+P(x)y=Q(x)y' + P(x) \cdot y = Q(x)


and the integrating factor


μ(x)=exp(0xP(x)dx)\mu(x) = \exp\left(\int_{0}^{x} P(x') dx'\right)


Solve our linear equation


y+y=x+cosxy' + y = x + \cos x


Let


μ(x)=exp(0x1dx)=ex\mu(x) = \exp\left(\int_{0}^{x} 1 \cdot dx\right) = e^{x}


Multiply both sides by μ(x)\mu(x):


exy+(ex)y=(ex(xcosx))e^{x} y' + (e^{x})' y = -\left(e^{x}(-x - \cos x)\right)


Apply the product rule gf+fg=(fg)gf' + fg' = (fg)' to the left-hand side:


(exy)=(ex(xcosx))(e^{x} y)' = -\left(e^{x}(-x - \cos x)\right)


Integrate both sides with respect to xx:


ddx(exy)dx=[(ex(xcosx))]dx\int \frac{d}{dx} (e^{x} y) dx = \int \left[ -\left(e^{x}(-x - \cos x)\right) \right] dx


Evaluate the integrals:


exy(x)=12ex(2x+cosx+sinx2)+C,e^{x} y(x) = \frac{1}{2} e^{x}(2x + \cos x + \sin x - 2) + C,


where CC is an arbitrary constant.

Divide both sides by μ(x)=ex\mu(x) = e^{x}:


y(x)=12(2x+cosx+sinx+2Cex2)y(x) = \frac{1}{2} \left(2x + \cos x + \sin x + \frac{2C}{e^{x}} - 2\right)


Answer:


y(x)=x+cosx2+sinx2+Cex1y(x) = x + \frac{\cos x}{2} + \frac{\sin x}{2} + \frac{C}{e^{x}} - 1

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!
LATEST TUTORIALS
APPROVED BY CLIENTS