How to solve these two ODE's?

83 Views Asked by At

For each one of them $y=y\left(x\right)$

$\text{(1) }\left(2x-y^{2}\right)\cdot y'=2y$

$\text{(2) }\left(x^{3}+e^{y}\right)\cdot y'=3x^{2}$

I suspect they might be "of the same kind".

What I tried is looking on this

$\left(y\cdot\left(2x-y^{2}\right)\right)'=y'\cdot\left(2x-y^{2}\right)+y\left(2-2y\cdot y'\right)=\underset{\text{=0 for a sol}}{\underbrace{y'\cdot\left(2x-y^{2}\right)-2y}}+2y\left(2-y\cdot y'\right)$

and this

$\left(y\cdot\left(x^{3}+e^{y}\right)\right)'=y'\cdot\left(x^{3}+e^{y}\right)+y\cdot\left(3x^{2}+e^{y}\cdot y'\right)$

But i don't really know if that helps

Any suggestions?

Thanks in advance

2

There are 2 best solutions below

0
On BEST ANSWER

For the first equation $$\text{(1) }\left(2x-y^{2}\right)\cdot y'=2y$$ It's far easier to use $x'=\frac {dx}{dy}$ instead

$$\left(2x-y^{2}\right)\frac {dy}{dx}=2y \implies \left(2x-y^{2}\right)=2y\frac {dx}{dy}$$ $$(2x-y^{2})=2yx'$$ $$yx'-x=-\frac 12y^2$$ $$\frac {yx'-x}{y^2}=-\frac 12$$ $$(\frac xy)'=-\frac 12$$ Integrate simply $$(\frac xy)=-\frac 12\int dy$$ $$\frac xy=-\frac 12y+K$$ $$\boxed {x(y)=-\frac 12y^2+Ky}$$


First equation can also be solved easily this way : $$(2x-y^{2})y'=2y$$ $$2(xy'-y)=y^{2}y' \implies y-xy'=-\frac 12y^{2}y'$$ $$ \left (\frac xy\right )'=-\frac 12y'$$ Integrate $$ \left (\frac xy\right )=-\frac 12y+K$$ Therefore $$ x(y)=-\frac 12y^2+Ky$$


For the second equation $$\text{(2) }\left(x^{3}+e^{y}\right)\cdot y'=3x^{2}$$ $$\left(x^{3}+e^{y}\right)\frac {dy}{dx}=3x^{2} \implies \left(x^{3}+e^{y}\right)=3x^{2}\frac {dx}{dy}$$ $$x^{3}+e^{y}=3x^{2}x'$$ $$x^{3}+e^{y}=(x^3)'$$ Substitute $z=x^3$ $$z+e^{y}=z' \implies z'-z=e^y$$ Multiply both sides by $e^{-y}$ $$(ze^{-y})'=1$$ $$\boxed {x^3e^{-y}-y=K}$$

2
On

Wr6titing your first equation in the form

$$-2y(x)+(2x-y(x)^2)y'(x)=0$$ we need an integrating factor $$\mu(y)$$ and we get

$$2y\frac{d\mu(y)}{dx}-2\mu(y)=2\mu(y)$$ from here we get $$\mu(y)=\frac{1}{y^2}$$

multiplying our equation by $\mu(y)$

$$-\frac{2}{y(x)}+\left(\frac{2x}{\mu(x)^2}-1\right)\frac{dy(x)}{dx}=0$$

so

$$f(x,y)=\int \frac{2}{y}dx=-\frac{2x}{y}+g(y)$$

to compute $g(y)$

$$\frac{\partial f(x,y)}{\partial y}=\frac{2x}{y(x)^2}+\frac{dg(y)}{dy}$$

so $$g(y)=-\int dy=-y$$

and we get

$$y=\frac{1}{2}\left(-\sqrt{-8x+C_1^2}-C_1\right)$$ or

$$y=\frac{1}{2}\left(\sqrt{-8x+C_1^2}-C_1\right)$$

to Your second equation

writing

$$-3x^2+(e^{y(x)}+x^3)\frac{dy}{dx}=0$$

computing an integrating factor

$$-3\frac{d\mu(y)}{dy}x^2=3\mu(y)x^2$$

so $$\mu(y)=e^{\mu(y)}$$ and we get

$$-3e^{-y(x)}x^2+(e^{y(x)}x^3+1)\frac{dy(x)}{dx}=0$$

the equation is exact:

$$f(x,y)=\int -3e^{-y}x^2dx=e^{-y}x^3+g(y)$$

computing $g(y)$

$$\frac{\partial f(x,y)}{\partial y}=\frac{\partial}{\partial y}(-e^{-y}x^3+g(y))=e^{-y}x^3+\frac{dg(y)}{dy}$$

so

$$g(y)=y$$ and

$$f(x,y)=-e^{-y}x^3+y$$

and the solution is given by

$$-e^{-y}x^3+y=C_1$$