Rotating magnetic fields are used in both electric motors and generators .
The electric field and the magnetic field are components of the electromagnetic field .