Home plumbing is installed according to a variety of building codes. The National Plumbing Code, Standard Plumbing Code and the One and Two Family Dwelling Code are examples of regulations that local authorities adopt and modify for their own use. The codes are written to provide a safe environment for anyone who uses water to wash, eat or dispose of items down the sewer. If a washbasin drain is not up to code, the home inspector will not approve it.
Washbasin drains are considered to be gravity-fed drains because they do not require assistance from any outside source to move the water from the basin. The plumbing underneath the drain is standardized in size and type of material. This makes it easy to install and easy to judge the correctness of the installation. A common method of installation runs the pipes through the wall behind the sink, where they connect with another drainage pipe at the floor level.
Water leaves the basin and flows downward through the drain. If you look at the drain system under the sink you'll see a pipe, usually made from white ABS plastic in newer homes and lead in older homes, running directly down from the basin above. The pipe descends about 24 inches and then loops back up about 6 inches, making a U-shape in the pipe known as the U-bend trap. At the top of the loop it travels horizontally though the wall where it connects to another pipe that travels downward, connecting to a horizontal pipe that leads to the sewer. The actual height at which the U-bend is installed depends upon the height of the piping behind the wall.
The U-bend trap in the pipe is crucial for safety. When you drain water down the pipe, the last cup or two of water is trapped in the U shape because the water pressure from above is not great enough to force it through. This leftover water acts as a stopper that prevents noxious sewer gas from coming up into the room. If this water evaporates because the basin is unused, nothing prevents the flow of the gas upwards.