I found two different expressions for the magnetostatic energy density stored in magnetic materials. Avoiding vectorial notation, these read as:

  1. $dU=H dB $
  2. $dU=-B dM$

It appears that the two are incompatible. If I use $dB=\mu_0 (dH+dM)$ and substitute into (1), I get

$$ dU=\mu_0 H dH + \mu_0 H dM .$$

The first term can be associated to the vacuum energy, but what about the second one? $\mu_0 H dM$ is not the same as $-B dM$. What am I missing? Which one of the two are correct and under what conditions?

  • 2
    $\begingroup$ Almost the answer: physics.stackexchange.com/questions/787202/… $\endgroup$ Dec 12, 2023 at 21:54
  • 1
    $\begingroup$ These are differential expressions, that is, changes of some energy density, not energy density itself. Which is right depends on what your definition of $U$ is. Does $U$ cover all Poynting EM energy, including the contribution that does not depend on the material medium? Or does it cover only that part of it we associate with magnetized material medium, excluding "vacuum energy" that would be present even without the medium? You have to decide which energy you want the $U$ to denote, then proceed to derive what $dU$ looks like. $\endgroup$ Dec 13, 2023 at 3:40
  • 1
    $\begingroup$ The choice of what particular expression to use for the magnetic energy in thermodynamics is still being fought over. Whether to use H or B and/or M is up to the choice of any author. You will be able to find people using any possible combination of these. It is a tremendous mess, and you have to be rather careful when comparing results. $\endgroup$ Dec 13, 2023 at 4:01

1 Answer 1


Each form calculates a different work. I'll give two possible derivations of these expressions.

The first expression calculates the total work done on the free current. The free currents are what you usually control experimentally (electromagnet etc.), so intuitively it's the work you'll need to supply to your electromagnet to vary the fields. Recall that Maxwell's equations in matter give: $$ \nabla\times H = j_f \\ $$ The work on the free currents are: $$ \delta W = \int j_f\cdot \delta E d^3x $$ with $\delta E$ the electric field (times small increment of time) induced by the variation of the free current: $$ \nabla\times \delta E = -\delta B $$ Using integration by parts: $$ \delta W = -\int H\cdot \delta B d^3x $$ this is why the corresponding energy density increment is: $$ dU = H\cdot dB $$

For the second expression, you can view it as the Legendre transform of: $$ dF = MdB $$ The latter expression is work done on the bound currents by the same argument as before using: $$ \nabla\times M = j_b $$ It's typically useful in statistical mechanics since you can apply the variational principle on this potential to get the equilibrium magnetisation.

Hope this helps.

  • $\begingroup$ is the work done on bound currents $MdB$ or $M dH$? $\endgroup$
    – Botond
    Dec 15, 2023 at 11:44
  • 1
    $\begingroup$ By the same reasoning, the work done on bound currents is $dF = MdB$. Your work $-BdM$ is the Legendre transform of the former. $\endgroup$
    – LPZ
    Dec 15, 2023 at 13:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.