DC MOTOR: It is an electrical machine which converts electrical energy into mechanical energy.
Principle: It is based on the fact that a current carrying coil placed in the magnetic field experiences a torque.
On passing current through the coil, all sides of coil experiences a force due to the field of the bar magnet. As it can be found out using fleming's rule, the force exerted on the two sides AB and CD will be opposite in direction causing rotation of the coil. There is a shaft connected to the coil which starts rotating along with the coil.