Electromagnets
An electromagnet is composed of a cylindrical core of ferromagnetic material with N turns of wire wrapped around it, carrying I.
Relay and Contractors
A relay has a moveable arm which once a coil is energized, the N.O contacts are closed and the N.C contacts are open which occurs due to the following force
Where is a permeability constant
Then, the two pieces get attracted to each other. Once the core is demagnetized, the spring moves the arm back to its original position.