Sizing pipes correctly, the practical engineer's guide.
When a plumber does their job right no one will notice; when they do it wrong, everything gets full of shit.
The driver for a properly sized pipe is velocity. Velocity is the speed limit that a fluid can move and is normally expressed in meters per second (m/s).
When I say fluid I mean anything that flows be it liquid, gas or a more exotic phase of matter.
The maximum speed limit for liquids is 2.5m/s.
For gasses the maximum speed limit is 40m/s, some firms think that 60m/s is fine too.
Undersized plumbing results in excessively high pressure drops, noise, and vibration. All of these are bad in the world of fluid systems as they lead to leaks, underperformance, even a need for additional PPE in the environment where the pipes are designed wrong.
Here is how you figure out how big your pipe is supposed to be:
Determine your volumetric flow rate. How much am I moving from point A to point B over what period of time. Liquids are non-compressible, gasses are compressible. So pressure plays a very important role if you are calculating flow of a gas. If the gas flow rate is expressed in "Standard Liters" or "Standard Cubic feet" that means the gas volume is expressed as the volume the gas will be at one atmosphere. Use the ideal gas law to convert your volumetric flow rate into moles; then convert the molar flow rate into the volumetric flow rate at your design line pressure.
Convert your volumetric flow rate from whatever units it might be expressed in such as liters per minute (l/m) or disgusting imperial units like cubic feet per minute (cfm) into cubic meters per second (m3/s). Pro tip: Google is excessively good at this.
Divide the volumetric flow rate (m3/s) by your maximum allowed velocity (m/s). The resulting number will be (m2) or the cross sectional area of the pipe required.
Work A=πr^2 backwards. Take your m2 and divide by π then square root the result and multiply by 2000. The result will be the minimum inside diameter needed for piping success expressed in mm. Round this number up to the next available industry size available. For instance if your minimum ID is 32mm then you will likely use a 40mm tube because there is no infrastructure for a 32mm ID tube, but there is for a 40mm tube.
Pat yourself on the back. You have now done more than 90% of the engineers being overpaid to underdeliver.