19th century. Design principles When on the move, a steam locomotive requires steam to enter the cylinder at precise times relative to the piston's position. This entails controlling the admission and exhaust of steam to and from the cylinders with a valve linked to the motion of the piston. For timing and dimensioning of slide or piston valves where the valve opens and closes the steam and exhaust ports, a consideration of the "lap" and "lead" is required. Lap Lap is the amount by which the valve overlaps each port at the middle position of each valve. There are two different types of lap. The first kind is the steam lap, which is the amount by which the valve overlaps the steam port on the live steam side of the piston or slide valve (i.e. the distance the valve needs to move to just begin to uncover the port). Secondly, the exhaust lap, which is the amount by which the valve overlaps the exhaust port on the exhaust side of the piston or slide valve. Exhaust lap is generally given to slow-running locomotives. This is because it allows the steam to remain in the cylinder for the longest possible amount of time before being expended as exhaust, therefore increasing efficiency. shunter locomotives tended to be equipped with this addition. Negative exhaust lap, also commonly known as exhaust clearance, is the amount the port is open to exhaust when the valve is in mid-position, and is used on many fast-running locomotives to give a free exhaust. The cylinder on both sides of the piston is open to exhaust at the same time when the valve is passing through the mid-position, which is only momentary when running. Lead Lead is the amount by which a port is open when the piston is at front or back "dead centre". In the case of the steam port this allows admission of steam to fill the clearance space between the cylinder and piston and ensures maximum cylinder pressure before the commencement of the stroke. This both cushions and assists the mass of the piston to slow down and change direction. At slow speeds no lead is ideal. For engines with pistons of 24 inches plus and masses of over 5 kilos and pressures under 500 psi then cushioning is beneficial. Lead is necessary on locomotives designed for high speeds. Calculating valve events Given the valve's