![\underbrace{y(7xy^2+6)}_{M(x,y)}\,\mathrm dx+\underbrace{x(xy^2-1)}_{N(x,y)}\,\mathrm dy=0](https://tex.z-dn.net/?f=%5Cunderbrace%7By%287xy%5E2%2B6%29%7D_%7BM%28x%2Cy%29%7D%5C%2C%5Cmathrm%20dx%2B%5Cunderbrace%7Bx%28xy%5E2-1%29%7D_%7BN%28x%2Cy%29%7D%5C%2C%5Cmathrm%20dy%3D0)
For the ODE to be exact, we require that
![M_y=N_x](https://tex.z-dn.net/?f=M_y%3DN_x)
, which we'll verify is not the case here.
![M_y=21xy^2+6](https://tex.z-dn.net/?f=M_y%3D21xy%5E2%2B6)
![N_x=2xy^2-1](https://tex.z-dn.net/?f=N_x%3D2xy%5E2-1)
So we distribute an integrating factor
![i(x,y)](https://tex.z-dn.net/?f=i%28x%2Cy%29)
across both sides of the ODE to get
![iM\,\mathrm dx+iN\,\mathrm dy=0](https://tex.z-dn.net/?f=iM%5C%2C%5Cmathrm%20dx%2BiN%5C%2C%5Cmathrm%20dy%3D0)
Now for the ODE to be exact, we require
![(iM)_y=(iN)_x](https://tex.z-dn.net/?f=%28iM%29_y%3D%28iN%29_x)
, which in turn means
![i_yM+iM_y=i_xN+iN_x\implies i(M_y-N_x)=i_xN-i_yM](https://tex.z-dn.net/?f=i_yM%2BiM_y%3Di_xN%2BiN_x%5Cimplies%20i%28M_y-N_x%29%3Di_xN-i_yM)
Suppose
![i(x,y)=x^ry^s](https://tex.z-dn.net/?f=i%28x%2Cy%29%3Dx%5Ery%5Es)
. Then substituting everything into the PDE above, we have
![x^ry^s(19xy^2+7)=rx^{r-1}y^s(x^2y^2-x)-sx^ry^{s-1}(7xy^3+6y)](https://tex.z-dn.net/?f=x%5Ery%5Es%2819xy%5E2%2B7%29%3Drx%5E%7Br-1%7Dy%5Es%28x%5E2y%5E2-x%29-sx%5Ery%5E%7Bs-1%7D%287xy%5E3%2B6y%29)
![19x^{r+1}y^{s+2}+7x^ry^s=rx^{r+1}y^{s+2}-rx^ry^s-7sx^{r+1}y^{s+2}-6sx^ry^s](https://tex.z-dn.net/?f=19x%5E%7Br%2B1%7Dy%5E%7Bs%2B2%7D%2B7x%5Ery%5Es%3Drx%5E%7Br%2B1%7Dy%5E%7Bs%2B2%7D-rx%5Ery%5Es-7sx%5E%7Br%2B1%7Dy%5E%7Bs%2B2%7D-6sx%5Ery%5Es)
![19x^{r+1}y^{s+2}+7x^ry^s=(r-7s)x^{r+1}y^{s+2}-(r+6s)x^ry^s](https://tex.z-dn.net/?f=19x%5E%7Br%2B1%7Dy%5E%7Bs%2B2%7D%2B7x%5Ery%5Es%3D%28r-7s%29x%5E%7Br%2B1%7Dy%5E%7Bs%2B2%7D-%28r%2B6s%29x%5Ery%5Es)
![\implies\begin{cases}r-7s=19\\r+6s=-7\end{cases}\implies r=5,s=-2](https://tex.z-dn.net/?f=%5Cimplies%5Cbegin%7Bcases%7Dr-7s%3D19%5C%5Cr%2B6s%3D-7%5Cend%7Bcases%7D%5Cimplies%20r%3D5%2Cs%3D-2)
so that our integrating factor is
![i(x,y)=x^5y^{-2}](https://tex.z-dn.net/?f=i%28x%2Cy%29%3Dx%5E5y%5E%7B-2%7D)
. Our ODE is now
![(7x^6y+6x^5y^{-1})\,\mathrm dx+(x^7-x^6y^{-2})\,\mathrm dy=0](https://tex.z-dn.net/?f=%287x%5E6y%2B6x%5E5y%5E%7B-1%7D%29%5C%2C%5Cmathrm%20dx%2B%28x%5E7-x%5E6y%5E%7B-2%7D%29%5C%2C%5Cmathrm%20dy%3D0)
Renaming
![M(x,y)](https://tex.z-dn.net/?f=M%28x%2Cy%29)
and
![N(x,y)](https://tex.z-dn.net/?f=N%28x%2Cy%29)
to our current coefficients, we end up with partial derivatives
![M_y=7x^6-6x^5y^{-2}](https://tex.z-dn.net/?f=M_y%3D7x%5E6-6x%5E5y%5E%7B-2%7D)
![N_x=7x^6-6x^5y^{-2}](https://tex.z-dn.net/?f=N_x%3D7x%5E6-6x%5E5y%5E%7B-2%7D)
as desired, so our new ODE is indeed exact.
Next, we're looking for a solution of the form
![\Psi(x,y)=C](https://tex.z-dn.net/?f=%5CPsi%28x%2Cy%29%3DC)
. By the chain rule, we have
![\Psi_x=7x^6y+6x^5y^{-1}\implies\Psi=x^7y+x^6y^{-1}+f(y)](https://tex.z-dn.net/?f=%5CPsi_x%3D7x%5E6y%2B6x%5E5y%5E%7B-1%7D%5Cimplies%5CPsi%3Dx%5E7y%2Bx%5E6y%5E%7B-1%7D%2Bf%28y%29)
Differentiating with respect to
![y](https://tex.z-dn.net/?f=y)
yields
![\Psi_y=x^7-x^6y^{-2}=x^7-x^6y^{-2}+\dfrac{\mathrm df}{\mathrm dy}](https://tex.z-dn.net/?f=%5CPsi_y%3Dx%5E7-x%5E6y%5E%7B-2%7D%3Dx%5E7-x%5E6y%5E%7B-2%7D%2B%5Cdfrac%7B%5Cmathrm%20df%7D%7B%5Cmathrm%20dy%7D)
![\implies\dfrac{\mathrm df}{\mathrm dy}=0\implies f(y)=C](https://tex.z-dn.net/?f=%5Cimplies%5Cdfrac%7B%5Cmathrm%20df%7D%7B%5Cmathrm%20dy%7D%3D0%5Cimplies%20f%28y%29%3DC)
Thus the solution to the ODE is