A magnetic field is characterised by the energy parameter. If we turn the switch S to position 2 (Figure 33), the current in the circuit will not disappear, because there are still some additional currents in the circuit due to the self-inductance phenomena. This means that some part of the charge will be moved along the circuit.
This will partially be characterised by the energy stored in the circuit. The fragment of work is
So the energy stored in the magnetic field is
Magnetic field energy is represented through the magnetic field. B is
V is a solenoid volume.
Energy of the fragment of space within the magnetic field is
(Figure 34). The magnetic field inside of the solenoid is uniform, so
Wm is the volume energy density of the magnetic field. In case of a non-uniform field you can use this formula to determine the volume energy of the fragment of the field. In the case of a magnetic field as a function, if the coordinates is known then we can determine the volume energy for any fragment of the space Ω: