The theory of electromagnetism was developed by physicist James Clerk Maxwell. According to his theory, an alternating current would set…