Differential equations/Exact differential equations

Definition
A differential equation of is said to be exact if it can be written in the form $$M(x,y) dx + N(x,y) dy = 0$$ where $$M$$ and $$N$$ have continuous partial derivatives such that $$\frac {\partial M}{\partial y} = \frac {\partial N}{\partial x}$$.

Solution
Solving the differential equation consists of the following steps:


 * 1) Create a function $$f(x,y) := \int M(x,y) dx$$. While integrating, add a constant function $$g(y)$$ that is a function of $$y$$. This is a term that becomes zero if function $$f(x,y)$$ is differentiated with respect to $$x$$.
 * 2) Differentiate the function $$f(x,y)$$ with respect to $$\frac {\partial f}{\partial y}$$. Set $$\frac {\partial f}{\partial y} = N(x,y)$$. Solve for the function $$g(y)$$.