Mathwords logoMathwords

Exact Differential — Definition, Formula & Examples

An exact differential is an expression of the form Mdx+NdyM\,dx + N\,dy that is the total differential of some function F(x,y)F(x,y), meaning dF=Mdx+NdydF = M\,dx + N\,dy. When a differential equation Mdx+Ndy=0M\,dx + N\,dy = 0 has this property, it can be solved by finding FF directly.

The expression M(x,y)dx+N(x,y)dyM(x,y)\,dx + N(x,y)\,dy is an exact differential on a simply connected region if and only if MM and NN have continuous first partial derivatives and satisfy the condition My=Nx\dfrac{\partial M}{\partial y} = \dfrac{\partial N}{\partial x}. In that case, there exists a scalar function F(x,y)F(x,y) such that Fx=M\dfrac{\partial F}{\partial x} = M and Fy=N\dfrac{\partial F}{\partial y} = N.

Key Formula

My=Nx\frac{\partial M}{\partial y} = \frac{\partial N}{\partial x}
Where:
  • MM = Function of x and y multiplying dx
  • NN = Function of x and y multiplying dy

How It Works

To solve an exact equation Mdx+Ndy=0M\,dx + N\,dy = 0, first verify exactness by checking My=Nx\frac{\partial M}{\partial y} = \frac{\partial N}{\partial x}. Then integrate MM with respect to xx to get F(x,y)=Mdx+g(y)F(x,y) = \int M\,dx + g(y), where g(y)g(y) is an unknown function of yy alone. Differentiate FF with respect to yy and set it equal to NN to determine g(y)g(y). The implicit solution is F(x,y)=CF(x,y) = C.

Worked Example

Problem: Solve the differential equation (2xy + 3) dx + (x² + 4y) dy = 0.
Test for exactness: Identify M = 2xy + 3 and N = x² + 4y. Compute the partial derivatives.
My=2x,Nx=2x\frac{\partial M}{\partial y} = 2x, \quad \frac{\partial N}{\partial x} = 2x
Integrate M with respect to x: Since the equation is exact, integrate M to begin finding F(x,y).
F(x,y)=(2xy+3)dx=x2y+3x+g(y)F(x,y) = \int (2xy + 3)\,dx = x^2 y + 3x + g(y)
Determine g(y): Differentiate F with respect to y and set equal to N.
Fy=x2+g(y)=x2+4y    g(y)=4y    g(y)=2y2\frac{\partial F}{\partial y} = x^2 + g'(y) = x^2 + 4y \implies g'(y) = 4y \implies g(y) = 2y^2
Write the solution: Combine to form the implicit solution.
x2y+3x+2y2=Cx^2 y + 3x + 2y^2 = C
Answer: The general solution is x2y+3x+2y2=Cx^2 y + 3x + 2y^2 = C.

Why It Matters

Exact differential equations appear throughout physics and engineering whenever a conserved quantity (like energy or potential) exists. Recognizing exactness lets you solve first-order ODEs algebraically instead of relying on more complex techniques. The concept also underpins line-integral path independence in multivariable calculus.

Common Mistakes

Mistake: Forgetting the arbitrary function g(y) when integrating M with respect to x.
Correction: Since you integrate with respect to x only, any pure function of y acts like a constant. Always include g(y) and determine it using the condition ∂F/∂y = N.