# What is the “energy associated with torque?”

I'm told that when a magnetic dipole is placed in a magnetic field $$\vec{B}$$, it experiences a torque $$\vec{\tau} = \vec\mu \times \vec{B}$$ and an associated energy $$H = -\vec{\mu} \cdot \vec{B}$$, where $$\vec{\mu}$$ is the magnetic dipole moment, pointing in the same direction as how the dipole is oriented in space.

I thought at first the associated energy might be the total amount of work you'd have to do to spin the dipole from equilibrium to whatever orientation you care about, but this doesn't agree with the math. If $$\vec{\mu}$$ points in the same direction as $$\vec{B}$$, you get a non zero value. What on earth does this associated energy actually mean?