Tubular section or hollow cylinder
A pipe is a tubular section or hollow cylinder, usually but not necessarily of circular cross-section, used mainly to convey substances which can flow — liquids and gases (fluids), slurries, powders and masses of small solids. It can also be used for structural applications; a hollow pipe is far stiffer per unit weight than the solid members.
In common usage the words "pipe" and "tube" are usually interchangeable, but in industry and engineering, the terms are uniquely defined. Depending on the applicable standard to which it is manufactured, pipe is generally specified by a nominal diameter with a constant outside diameter (OD) and a schedule that defines the thickness. Tube is most often specified by the OD and wall thickness, but may be specified by any two of OD, inside diameter (ID), and wall thickness. Pipe is generally manufactured to one of several international and national industrial standards. While similar standards exist for specific industry application tubing, tube is often made to custom sizes and a broader range of diameters and tolerances. Many industrial and government standards exist for the production of pipe and tubing. The term "tube" is also commonly applied to non-cylindrical sections, i.e., square or rectangular tubing. In general, "pipe" is the more common term in most of the world, whereas "tube" is more widely used in the United States.
Both "pipe" and "tube" imply a level of rigidity and permanence, whereas a "hose" (or hosepipe) is usually portable and flexible. Pipe assemblies are almost always constructed with the use of fittings such as elbows, tees, and so on, while tube may be formed or bent into custom configurations. For materials that are inflexible, cannot be formed, or where construction is governed by codes or standards, tube assemblies are also constructed with the use of tube fittings.
Uses.
Additionally, pipes are used for many purposes that do not involve conveying fluid. Handrails, scaffolding, and support structures are often constructed from structural pipes, especially in an industrial environment.
History.
The first known use of pipes was in Ancient Egypt. The Pyramid of Sahure, completed around the 25th century BC, included a temple with an elaborate drainage system including more than of copper piping.
During the Napoleonic Wars Birmingham gunmakers tried to use rolling mills to make iron musket barrels. One of them, Henry Osborne, developed a relatively effective process in 1817 with which he started to make iron gas tubes ca. 1820, selling some to gas lighting pioneer Samuel Clegg.
When steel pipes were introduced in 19th century, they initially were riveted, and later clamped with H-shaped bars (even though methods for making weldless steel tubes were known already in the 1870s), until by the early 1930s these methods were replaced by welding, which is still widely used today.
Manufacture.
There are three processes for metallic pipe manufacture. Centrifugal casting of hot alloyed metal is one of the most prominent process. Ductile iron pipes are generally manufactured in such a fashion. 
Seamless pipe (SMLS) is formed by drawing a solid billet over a piercing rod to create the hollow shell in a process called rotary piercing. As the manufacturing process does not include any welding, seamless pipes are perceived to be stronger and more reliable. Historically, seamless pipe was regarded as withstanding pressure better than other types, and was often more available than welded pipe.
Advances since the 1970s, in materials, process control, and non-destructive testing, allow correctly specified welded pipe to replace seamless in many applications. Welded pipe is formed by rolling plate and welding the seam (usually by Electric resistance welding ("ERW"), or Electric Fusion Welding ("EFW")). The weld flash can be removed from both inner and outer surfaces using a scarfing blade. The weld zone can also be heat-treated to make the seam less visible. Welded pipe often has tighter dimensional tolerances than the seamless type, and can be cheaper to manufacture.
There are a number of processes that may be used to produce ERW pipes. Each of these processes leads to coalescence or merging of steel components into pipes. Electric current is passed through the surfaces that have to be welded together; as the components being welded together resist the electric current, heat is generated which forms the weld. Pools of molten metal are formed where the two surfaces are connected as a strong electric current is passed through the metal; these pools of molten metal form the weld that binds the two abutted components.
ERW pipes are manufactured from the longitudinal welding of steel. The welding process for ERW pipes is continuous, as opposed to welding of distinct sections at intervals. ERW process uses steel coil as feedstock.
The High Frequency Induction Technology (HFI) welding process is used for manufacturing ERW pipes. In this process, the current to weld the pipe is applied by means of an induction coil around the tube. HFI is generally considered to be technically superior to "ordinary" ERW when manufacturing pipes for critical applications, such as for usage in the energy sector, in addition to other uses in line pipe applications, as well as for casing and tubing.
Large-diameter pipe ( or greater) may be ERW, EFW, or Submerged Arc Welded ("SAW") pipe. There are two technologies that can be used to manufacture steel pipes of sizes larger than the steel pipes that can be produced by seamless and ERW processes. The two types of pipes produced through these technologies are longitudinal-submerged arc-welded (LSAW) and spiral-submerged arc-welded (SSAW) pipes. LSAW are made by bending and welding wide steel plates and most commonly used in oil and gas industry applications. Due to their high cost, LSAW pipes are seldom used in lower value non-energy applications such as water pipelines. SSAW pipes are produced by spiral (helicoidal) welding of steel coil and have a cost advantage over LSAW pipes, as the process uses coils rather than steel plates. As such, in applications where spiral-weld is acceptable, SSAW pipes may be preferred over LSAW pipes. Both LSAW pipes and SSAW pipes compete against ERW pipes and seamless pipes in the diameter ranges of 16”-24”.
Tubing for flow, either metal or plastic, is generally extruded.
Materials.
Pipe is made out of many types of material including ceramic, glass, fiberglass, many metals, concrete and plastic. In the past, wood and lead (Latin "plumbum", from which comes the word 'plumbing') were commonly used.
Typically metallic piping is made of steel or iron, such as unfinished, black (lacquer) steel, carbon steel, stainless steel, galvanized steel, brass, and ductile iron. Iron based piping is subject to corrosion if used within a highly oxygenated water stream. Aluminum pipe or tubing may be utilized where iron is incompatible with the service fluid or where weight is a concern; aluminum is also used for heat transfer tubing such as in refrigerant systems. Copper tubing is popular for domestic water (potable) plumbing systems; copper may be used where heat transfer is desirable (i.e. radiators or heat exchangers). Inconel, chrome moly, and titanium steel alloys are used in high temperature and pressure piping in process and power facilities. When specifying alloys for new processes, the known issues of creep and sensitization effect must be taken into account.
Lead piping is still found in old domestic and other water distribution systems, but is no longer permitted for new potable water piping installations due to its toxicity. Many building codes now require that lead piping in residential or institutional installations be replaced with non-toxic piping or that the tubes' interiors be treated with phosphoric acid. According to a senior researcher and lead expert with the Canadian Environmental Law Association, "[...] there is no safe level of lead [for human exposure]". In 1991 the US EPA issued the Lead and Copper Rule, a federal regulation which limits the concentration of lead and copper allowed in public drinking water, as well as the permissible amount of pipe corrosion occurring due to the water itself. In the US it is estimated that 6.5 million lead service lines (pipes that connect water mains to home plumbing) installed before the 1930s are still in use.
Plastic tubing is widely used for its light weight, chemical resistance, non-corrosive properties, and ease of making connections. Plastic materials include polyvinyl chloride (PVC), chlorinated polyvinyl chloride (CPVC), fibre reinforced plastic (FRP), reinforced polymer mortar (RPMP), polypropylene (PP), polyethylene (PE), cross-linked high-density polyethylene (PEX), polybutylene (PB), and acrylonitrile butadiene styrene (ABS), for example. In many countries, PVC pipes account for most pipe materials used in buried municipal applications for drinking water distribution and wastewater mains.
Pipe may be made from concrete or ceramic, usually for low-pressure applications such as gravity flow or drainage. Pipes for sewage are still predominantly made from concrete or vitrified clay. Reinforced concrete can be used for large-diameter concrete pipes. This pipe material can be used in many types of construction, and is often used in the gravity-flow transport of storm water. Usually such pipe will have a receiving bell or a stepped fitting, with various sealing methods applied at installation.
Traceability and positive material identification (PMI).
When the alloys for piping are forged, metallurgical tests are performed to determine material composition by % of each chemical element in the piping, and the results are recorded in a material test report, also known as a Mill Test Report (MTR). These tests can be used to prove that the alloy conforms to various specifications (e.g. 316 SS). The tests are stamped by the mill's QA/QC department and can be used to trace the material back to the mill by future users, such as piping and fitting manufacturers. Maintaining the traceability between the alloy material and associated MTR is an important quality assurance issue. QA often requires the heat number to be written on the pipe. Precautions must also be taken to prevent the introduction of counterfeit materials. As a backup to etching/labeling of the material identification on the pipe, positive material identification (PMI) is performed using a handheld device; the device scans the pipe material using an emitted electromagnetic wave (x-ray fluorescence/XRF) and receives a reply that is spectrographically analyzed.
Sizes.
Pipe sizes can be confusing because the terminology may relate to historical dimensions. For example, a half-inch iron pipe does not have any dimension that is a half inch. Initially, a half inch pipe did have an inner diameter of —but it also had thick walls. As technology improved, thinner walls became possible, but the outside diameter stayed the same so it could mate with existing older pipe, increasing the inner diameter beyond half an inch. The history of copper pipe is similar. In the 1930s, the pipe was designated by its internal diameter and a wall thickness. Consequently, a copper pipe had a outside diameter. The outside diameter was the important dimension for mating with fittings. The wall thickness on modern copper is usually thinner than , so the internal diameter is only "nominal" rather than a controlling dimension. Newer pipe technologies sometimes adopted a sizing system as its own. PVC pipe uses the Nominal Pipe Size.
Pipe sizes are specified by a number of national and international standards, including API 5L, ANSI/ASME B36.10M and B36.19M in the US, BS 1600 and BS EN 10255 in the United Kingdom and Europe.
There are two common methods for designating pipe outside diameter (OD). The North American method is called NPS ("Nominal Pipe Size") and is based on inches (also frequently referred to as NB ("Nominal Bore")). The European version is called DN ("Diametre Nominal" / "Nominal Diameter") and is based on millimetres. Designating the outside diameter allows pipes of the same size to be fit together no matter what the wall thickness.
Since the outside diameter is fixed for a given pipe size, the inside diameter will vary depending on the wall thickness of the pipe. For example, 2" Schedule 80 pipe has thicker walls and therefore a smaller inside diameter than 2" Schedule 40 pipe.
Steel pipe has been produced for about 150 years. The pipe sizes that are in use today in PVC and galvanized were originally designed years ago for steel pipe. The number system, like Sch 40, 80, 160, were set long ago and seem a little odd. For example, Sch 20 pipe is even thinner than Sch 40, but same OD. And while these pipes are based on old steel pipe sizes, there is other pipe, like cpvc for heated water, that uses pipe sizes, inside and out, based