Given xdxdy+2y=xcosx⇒(xdxdy+2y)×x1=xcosx×x1⇒dxdy+x2y=cosx⇒dxdy+(x2)y=cosx
This is a first order linear differential equation of the form
dxdy+Py=Q Here, P=x2 and Q=cosx
The integrating factor (I.F) of this differential equation is,
I. F =e∫Pdx⇒ I.F =e∫x2dx⇒ I.F =e2∫x1dx We have ∫x1dx=logx+c⇒ I.F =e2logx
[∵mloga=logam]∴I.F=x2[∵elogx=x]⇒I.F=elogx2
Hence, the solution of the differential equation is,
y(I.F)=⇒y(x2)=⇒yx2=⇒yx2= Recall ∫f(x)g(x)=f(x)[∫g(x)dx]⇒yx2=∫(Q×I.F)dx+c∫(cosx×x2)dx+c∫x2cosxdx+c∫(x2)×(cosx)dx+c−∫[f′(x)(∫g(x)dx)]dx+cx2[∫cosxdx]−∫[dxd(x2)(∫cosxdx)]dx+c
⇒yx2⇒yx2⇒yx2⇒yx2⇒yx2⇒yx2=x2sinx−2∫xsinxdx+c=x2sinx−2{x[∫sinxdx]−∫[dxd(x)(∫sinxdx)]dx}+c=x2sinx−2{x[−cosx]=x2sinx−2{−xcosx=x2sinx−2{−xcosx+sinx}+c=x2sinx+2xcosx−2sinx+c
y=sinx+x2cosx−x22sinx+x2c
Thus, the solution of the given differential equation is
y=sinx+x2cosx−x22sinx+x2c
Comments