darryw said:
ok thank you, but i am still confused as to how to actually get the integrating factor? (to make an equation exact)??
In your problem, we have:
M = (x+2)\sin y
M_y = (x+2)\cos y
N = x\cos y
N_x = \cos y
Clearly, we have M_y \neq N_x and we need to multiply the equation by an integrating factor to proceed further.
The theory behind integrating factors is as follows: take your DE and multiply by an integrating factor p:
pMdx + pNdy = 0
We then proceed identically as before, that is to say, we look for a p such that:
\frac{\partial}{\partial y}\left(pM\right) = \frac{\partial}{\partial x}\left(pN\right)
p_y M + p M_y = p_x N + p N_x
The last equation is a result of the Chain Rule. Suppose that p is a function of x alone (not y), then p_y = 0, and the last equation reduces to:
p\left(M_y - N_x\right) = p_x N
\frac{M_y - N_x}{N}dx = \frac{dp}{p}
Let F(x) = \left(M_y - N_x\right)/N, and the above equation becomes:
F(x)dx = \frac{dp}{p}
\ln(p) = \int F(x)dx
p(x) = e ^{\int F(x)dx}
This has already been posted (in essence), but I thought it's useful to understand where the equations come from, and how they are derived, rather than just memorizing arcane equations by "rote", so to speak..
The integrating factor you derived should be correct for your problem.