High Quality Content by WIKIPEDIA articles! In plumbing, a trap is a U-, S-, or J-shaped pipe located below or within a plumbing fixture. An S-shaped trap is also known as the S-bend invented by Alexander Cummings in 1775 but this was subsequently replaced with the "U-bend" following the introduction of the U-shaped trap by Thomas Crapper in 1880. The new "U-bend" could not jam so it did not need an overflow, common to the "S-bend". The bend is used to prevent sewer gases from entering buildings. In refinery applications, it also prevents hydrocarbons and other dangerous gases from escaping outside through drains.