Why did the frog cross the rail? Because it was there! In railroading and railroad modeling a ‘frog’ refers to the part of the system where the curved rail from a diverging line crosses the line of the main rail. It is technically and more usually referred to as a ‘crossing’ in fact, and got the nickname because the divergence allows a train to ‘hop’ to another track.
Frogs are a small section of a crossing, which consists of a series of components such as the guard rail, switch motors, points levers (or ground throw levers) which activate the linkages manually etc. you can learn more about these components online at Answer.com and on various railroad switch and crossing sites if you desire. For details on creating model railroad turnouts and switches several resources exist including a wonderful FAQ on Trains.com
The points of a crossing are the movable rail sections that guide train wheels to the diverging track, and are sharpened on most switches save for the ‘stub switch’ where they have square ends. Most Frogs are made from appropriately cut or shaped pieces of a single casting, and on heavy lines often a ‘movable point frog’ is used in which there is a second set of points located at the frog to minimize the gap in the rail that occurs at the frog … but this technique requires two switch engines and is thus more expensive.
The guard rail is the piece of rail alongside the main rail opposite the frog, and assures that the wheels follow the appropriate flangeway or track and thus doesn’t derail – normally there are two per each frog by the outer rails.
The switch motors are normally electric although some pneumatic systems also exist and typically are controlled remotely although manual control via the points lever, ground throw or ‘switchstand’ can occur. Such manual controls are normally attached to a long pair of sleepers which extend from the switch at the points and can sometimes be found in place of switch motors on a rarely used switching system.
Frogs are referred to by a ‘number’ which reflects the number of inches it takes for the diverging rail to move once inch away from the original path – for instance a #5 frog would diverge 1 inch away from the original track after traveling 5 inches, and would be a sharper curve then a #7 which does the same distance in 7 inches.
A good resource for details on frogs, crossings and planning tracks is a book by John Armstrong called “Track Planning for Realistic Operation" and can be found available from many hobby shops, in your local library and online.