Electricity and Magnetism
One of the great triumphs of 19th century science was the development of electromagnetic theory. Development of the theory began with Benjamin Franklin's experiments with static electricity in 1748 and culminated with Maxwell's four equations, derived in 1864, which explain all electromagnetic phenomena including electromagnetic waves.
For hundreds of years, electricity and magnetism were quite mysterious forces, thought to be separate. Beginning in the 18th century, several scientists experimented with electricity including Franklin, Coulomb, Volta, Ampere, Faraday, and Maxwell. In 1748, Franklin discovered that there were two types of electric charge, positive and negative, and that like charges repel and opposite charges attract. Coulomb made this law mathematically precise. In 1800, Volta discovered the principle behind the battery and was able to use them to produce electric currents. In 1819, Ampere discovered the first connection between electricity and magnetism with his discovery that an electric current produces a magnetic field. In 1831, Faraday extended this connection by discovering that a changing magnetic flux produces an electric current in a loop of wire.
In 1864, Maxwell tied the whole theory of electricity and magnetism together with four equations. Among other things, Maxwell's equations predict the existence of electromagnetic waves, oscillating electric and magnetic fields which propagate at the speed of light. In fact, light itself turns out to be an electromagnetic wave. In 1887, Hertz produced the first radio waves and in 1895, Marconi invented radio.
Electromagnetic theory eventually led to Einstein's discovery of relativity. As a teenager, Einstein asked himself what it would be like to ride on a beam of light. It was the consideration of this question which led him to stumble upon relativity.