# Find the general solution by using an integrating factor:

Find the particular solution(arbitrary constant determined) y'+2xy=5x given that y(0)=1 i got e^-x2 *5e^x2/2+c1

dy/dx + 2y = e^-x
[Note you can only determine the general solution here (arbitrary constant remains unknown)]
i got e^-x(e^x+c) is that final answer right

Last edited:

#### Wander

Hello.

$$\displaystyle \frac{dy}{dx} + 2xy = 5x$$

The integrating factor is $$\displaystyle e^{\int 2x~dx} = e^{x^2}$$, neglecting the constant of integration.

Multiply through by it:

$$\displaystyle e^{x^2}\frac{dy}{dx} + 2xye^{x^2} = 5xe^{x^2}$$

Then, we have:

$$\displaystyle \dfrac{d}{dx}\big[ye^{x^2}\big] = 5xe^{x^2}$$

$$\displaystyle \Rightarrow ye^{x^2} = \int 5xe^{x^2}~dx$$

Making the substitution $$\displaystyle u=x^2$$ to solve the integral eventually gives:

$$\displaystyle ye^{x^2} = \frac{5e^{x^2}}{2} + C$$

$$\displaystyle \Rightarrow y = \frac{5}{2} + C e^{-x^2}$$

Then, $$\displaystyle y(0) = 1 \Rightarrow 1 = \frac{5}{2} + C$$

So, we have that $$\displaystyle C = \frac{-3}{2}$$ and the particular solution is given by:

$$\displaystyle y = \frac{5}{2} - \frac{3e^{-x^2}}{2}$$

Your answer for the other question is not quite right (but it's close). Could you post your working?