This is a homogeneous differential equation. We can solve this by substituting y=vx. Then y′=v+xdxdv. Substituting into the differential equation:
v+xdxdv=x+vxx−vx=x(1+v)x(1−v)=1+v1−v xdxdv=1+v1−v−v=1+v1−v−v(1+v)=1+v1−v−v−v2=1+v1−2v−v2 Now we separate variables:
1−2v−v21+vdv=x1dx Integrate both sides:
∫1−2v−v21+vdv=∫x1dx Let u=1−2v−v2, then du=(−2−2v)dv=−2(1+v)dv, so (1+v)dv=−21du ∫1−2v−v21+vdv=∫u−21du=−21∫u1du=−21ln∣u∣+C1=−21ln∣1−2v−v2∣+C1 ∫x1dx=ln∣x∣+C2 Therefore,
−21ln∣1−2v−v2∣=ln∣x∣+C ln∣1−2v−v2∣=−2ln∣x∣−2C ln∣1−2v−v2∣=ln∣x−2∣+C′ 1−2v−v2=eln∣x−2∣+C′=eC′x−2=Ax−2 where A=eC′ 1−2v−v2=x2A Substituting back v=xy, 1−2(xy)−(xy)2=x2A 1−x2y−x2y2=x2A x2−2xy−y2=A