Given:(1+tany)(dx−dy)+2xdy=0
⇒dx+tanydx−dy−tanydy+2xdy=0
⇒dy(1+tany−2x)=(1+tany)dx
dydx=1+tany1−2x+tany
or dxdy=1−2x+tany1+tany
dxdy=1+tany1+tany−2x1+tany
I.F=siny+cosyey
x× I.F=∫Q× I.Fdy+c
xsiny+cosyey=∫1×siny+cosyeydy+c
xey(siny+cosy)=∫eysinydy+∫eycosydy+c
Consider ∫eysinydy is of the form
∫eaxsinbxdy=eaxa2+b2(asinbx−bcosbx)
Here a=1 and b=1
Hence ∫eycosydy=ey2(cosy+siny)
Now combining and substituting in the required solution we get
xey(siny+cosy)=ey2(siny−cosy)+ey2(siny+cosy)+c
xey(siny+cosy)=eysiny+c
Dividing throughout by ey we get
x(siny+cosy)=siny+ce−y