# Why are Electric Fields an exact differential?

{$$\vec E$$ - Electric Field Vector ; $$x^2$$ is $$x$$ raised to the power $$2$$}

When finding the Potential Difference between two points in a non uniform electric field, the equation of $$\vec E$$ given in the question is something like this

$$\vec E = 2xydx + (x^2)dy$$

Upon integrating (to find the potential difference) the $$x$$ and $$y$$ components separately, we get $$(x^2)y$$ as the result in both the cases and thus the potential is $$(x^2)y$$ and the function in $$\vec E$$ is an exactly differential.

The book I am referring says that the any function in $$\vec E$$ will be exactly differentiable as $$\vec E$$ is an conservative field and exact differentiability is a property of all conservative fields.

My question is : What if the question is a function in $$\vec E$$ which is not an exactly differential? If it is, then does it mean that such an $$\vec E$$ cannot exist? and thus is the potential difference also zero?

Also, Why are electric field functions an exact differential? I have some faint understanding relating to the fact that electrostatic forces are conservative forces and thus the work done by them does not depend on the path followed. I am not really satisfied with this explanation of mine though.

In electrostatics, the electric field is the gradient of some potential $$V(\vec{r})$$. It's fairly straightforward to prove that if a continuously-differentiable field is the gradient of a scalar field, then that vector field is an exact differential.
Consider the two-dimensional case for clarity of notation. We have an electric field $$\vec{E}=M\hat{x}+N\hat{y}$$, and we also know that $$\vec{E}=-\nabla V$$, so $$M=-\frac{\partial V}{\partial x}$$ and $$N=-\frac{\partial V}{\partial y}$$. Therefore:
$$\frac{\partial M}{\partial y}=-\frac{\partial^2 V}{\partial y\partial x}$$
$$\frac{\partial N}{\partial x}=-\frac{\partial^2 V}{\partial x\partial y}$$
We have assumed that $$\vec{E}$$ is continuously differentiable, so the partial derivatives are continuous, meaning that by Clairaut's theorem, the two right-hand sides are equal. Therefore, $$\vec{E}$$ is an exact differential of $$V$$.