217k views
1 vote
Solve the differential equation
(1+yx)x dy + (1-yx)y dx= 0

1 Answer

6 votes
Let
v(x)=xy(x), so that
\frac yx=\frac v{x^2}, and
(\mathrm dv)/(\mathrm dx)=x(\mathrm dy)/(\mathrm dx)+y, or
(\mathrm dy)/(\mathrm dx)=\frac1x(\mathrm dv)/(\mathrm dx)-\frac v{x^2}.

So the ODE is


(1+yx)x\,\mathrm dy+(1-yx)y\,\mathrm dx=0\iff(\mathrm dy)/(\mathrm dx)=-((1-yx)y)/((1+yx)x)

\implies \frac1x(\mathrm dv)/(\mathrm dx)-\frac v{x^2}=-(1-v)/(1+v)\frac v{x^2}

\implies (\mathrm dv)/(\mathrm dx)=\frac vx\left(1-(1-v)/(1+v)\right)

\implies(\mathrm dv)/(\mathrm dx)=(2v)/(x(1+v))

This ODE is separable, so you can write


(1+v)/(2v)\,\mathrm dv=\frac{\mathrm dx}x

and integrating both sides yields


\displaystyle\int(1+v)/(2v)\,\mathrm dv=\int \frac{\mathrm dx}x

\frac12\left(v+\ln|v|\right)=\ln|x|+C

v+\ln|v|=2\ln|x|+C

Replace
v=xy and you end up with


xy-\ln|xy|=2\ln|x|+C
User Greysteil
by
8.4k points