# How do you solve xy'+2y=4x^2 given y(1)=0?

How do you solve $xy\prime +2y=4{x}^{2}$ given y(1)=0?
You can still ask an expert for help

• Questions are typically answered in as fast as 30 minutes

Solve your problem for the price of one coffee

• Math expert for every subject
• Pay only if we can solve it

Corbin Hanson
We have:

$xy\prime +2y=4{x}^{2}$

Which we can write as:

We can use an integrating factor when we have a First Order Linear non-homogeneous Ordinary Differential Equation of the form;

$\frac{dy}{dx}+P\left(x\right)y=Q\left(x\right)$

Then the integrating factor is given by;

$IF={e}^{\int P\left(x\right)dx}$

$\phantom{\rule{1ex}{0ex}}\text{}\phantom{\rule{1ex}{0ex}}=\mathrm{exp}\left(2\mathrm{ln}x\right)$
$\phantom{\rule{1ex}{0ex}}\text{}\phantom{\rule{1ex}{0ex}}={e}^{{\mathrm{ln}x}^{2}}$
$\phantom{\rule{1ex}{0ex}}\text{}\phantom{\rule{1ex}{0ex}}={x}^{2}$

And if we multiply the DE [1] by this Integrating Factor, IF, we will have a perfect product differential;

$y\prime +\frac{2}{x}y=4x$

$\therefore {x}^{2}y\prime +2xy=4{x}^{3}$

$\therefore \frac{d}{dx}\left({x}^{2}y\right)=4{x}^{3}$

Which we can directly integrate to get:

$\therefore {x}^{2}y={x}^{4}+C$

Applying the initial condition, y(1)=0, we get:

$1\cdot 0=1+C⇒C=-1$

Thus the solution is:

$\therefore y={x}^{2}-\frac{1}{{x}^{2}}$