A rail gun is basically a large electric circuit, made up of three parts: a power source, a pair of parallel rails and a moving armature. Let's look at each of these parts in more detail.
This content is not compatible on this device.
The power supply is simply a source of electric current. Typically, the current used in medium- to large-caliber rail guns is in the millions of amps.
The rails are lengths of conductive metal, such as copper. They can range from four to 30 feet (9 meters) long.
The armature bridges the gap between the rails. It can be a solid piece of conductive metal or a conductive sabot -- a carrier that houses a dart or other projectile. Some rail guns use a plasma armature. In this set-up a thin metal foil is placed on the back of a non-conducting projectile. When power flows through this foil it vaporizes and becomes a plasma, which carries the current.
Here's how the pieces work together:
An electric current runs from the positive terminal of the power supply, up the positive rail, across the armature, and down the negative rail back to the power supply.
Current flowing in any wire creates a magnetic field around it -- a region where a magnetic force is felt. This force has both a magnitude and a direction. In a rail gun, the two rails act like wires, with a magnetic field circulating around each rail. The force lines of the magnetic field run in a counterclockwise circle around the positive rail and in a clockwise circle around the negative rail. The net magnetic field between the rails is directed vertically.
Like a charged wire in an electric field, the projectile experiences a force known as the Lorentz force (after the Dutch physicist Hendrik A. Lorentz). The Lorentz force is directed perpendicularly to the magnetic field and to the direction of the current flowing across the armature. You can see how this works in the diagram below.
Notice that the Lorentz force is parallel to the rails, acting away from the power supply. The magnitude of the force is determined by the equation F = (i)(L)(B), where F is the net force, i is the current, L is the length of the rails and B is the magnetic field. The force can be boosted by increasing either the length of the rails or the amount of current.
Because long rails pose design challenges, most rail guns use strong currents -- on the order of a million amps -- to generate tremendous force. The projectile, under the influence of the Lorentz force, accelerates to the end of the rails opposite the power supply and exits through an aperture. The circuit is broken, which ends the flow of current.