$$\require{cancel}$$
We are familiar with the idea that an electric field $$\textbf{E}$$ can be expressed as minus the gradient of a potential function $$V$$. That is
$\textbf{E} = −\textbf{grad} V = −\nabla V.\label{9.1.1}$
Note that $$V$$ is not unique, because an arbitrary constant can be added to it. We can define a unique $$V$$ by assigning a particular value of $$V$$ to some point (such as zero at infinity).
Can we express the magnetic field $$\textbf{B}$$ in a similar manner as the gradient of some potential function ψ, so that, for example, $$\textbf{B} = −\textbf{grad}\, ψ = −\nabla ψ$$ ? Before answering this, we note that there are some differences between $$\textbf{E}$$ and $$\textbf{B}$$ . Unlike $$\textbf{E}$$, the magnetic field $$\textbf{B}$$ is sourceless; there are no sources or sinks; the magnetic field lines are closed loops. The force on a charge $$q$$ in an electric field is $$q\textbf{E}$$, and it depends only on where the charge is in the electric field – i.e. on its position. Thus the force is conservative, and we understand from any study of classical mechanics that only conservative forces can be expressed as the derivative of a potential function. The force on a charge $$q$$ in a magnetic field is $$q\textbf{v} \times \textbf{B}$$. This force (the Lorentz force) does not depend only on the position of the particle, but also on its velocity (speed and direction). Thus the force is not conservative. This suggests that perhaps we cannot express the magnetic field merely as the gradient of a scalar potential function – and this is correct; we cannot.