The differential equation is dxdy−xy=2logex
This is a linear differential equation of the form dxdy+P(x)⋅y=Q(x) where P(x)=−x1 and Q(x)=2logex.
The integrating factor is given by IF=e∫P(x)dx
IF=e∫−x1dx
IF=e−logex
IF=elogex−1
IF=x−1
IF=x1
Multiplying the entire equation by x1:
x1⋅dxdy−x1⋅xy=x1⋅2logex
x1dxdy−x2y=x2logex
The left side is the derivative of xy by the quotient rule:
dxd(xy)=x2xdxdy−y⋅1=x1dxdy−x2y
The equation becomes:
dxd(xy)=x2logex
Integrating both sides:
xy=∫x2logexdx
Let u=logex, then dxdu=x1:
∫x2logexdx=∫2udu
=2⋅2u2+C
=u2+C
=(logex)2+C
Therefore:
xy=(logex)2+C
y=x((logex)2+C)
where C is an arbitrary constant.