Calculate the water flow capacity based on pipe diameter and velocity.
Flow Rate (GPM):0.00
Flow Rate (Gallons Per Hour):0.00
Flow Rate (Cubic Feet Per Sec):0.00
Cross-Sectional Area (Sq. In):0.00
How to Calculate Pipe Flow Rate
Understanding how much fluid can pass through a pipe is critical for plumbing, irrigation, and industrial process design. The flow rate is determined by the internal cross-sectional area of the pipe and the velocity at which the fluid is moving.
The fundamental formula used in this calculator is the Continuity Equation:
Q = A × v
Where:
Q: Flow rate
A: Cross-sectional area of the pipe (π × r²)
v: Fluid velocity
Common Velocity Standards
Choosing the right velocity is vital. If velocity is too high, you risk "Water Hammer" and pipe erosion. If it is too low, solids may settle in the pipe. General guidelines for water include:
Application
Recommended Velocity (FPS)
General Water Service
4 – 8 FPS
Suction Lines (Pumps)
2 – 4 FPS
Gravity Drains
2 – 3 FPS
Pressure Main Lines
5 – 10 FPS
Calculation Example
If you have a 2-inch (inside diameter) pipe and the water is moving at 5 feet per second:
Calculate the area: Radius = 1 inch. Area = π × (1)² = 3.14159 square inches.
Convert area to square feet: 3.14159 / 144 = 0.0218 sq ft.
Calculate CFS: 0.0218 sq ft × 5 fps = 0.109 Cubic Feet per Second.
Convert to GPM: 0.109 × 448.83 = 48.92 Gallons Per Minute.
Factors Affecting Flow
While this calculator provides the theoretical flow based on velocity, real-world flow is affected by:
Pipe Friction: Rougher pipe materials (like old cast iron) slow down fluid more than smooth materials (like PVC).
Pipe Length: Longer runs create more pressure drop (head loss).
Fittings: Elbows, tees, and valves add turbulence and restriction.
Viscosity: Thicker liquids (like oil) flow differently than water.
function calculatePipeFlow() {
var diameter = parseFloat(document.getElementById('pipeDiameter').value);
var velocity = parseFloat(document.getElementById('flowVelocity').value);
if (isNaN(diameter) || diameter <= 0 || isNaN(velocity) || velocity <= 0) {
alert("Please enter valid positive numbers for diameter and velocity.");
return;
}
// 1. Calculate Area in square inches
// Area = Pi * r^2
var radiusInches = diameter / 2;
var areaSqIn = Math.PI * Math.pow(radiusInches, 2);
// 2. Convert Area to square feet for CFS calculation
// 144 square inches in a square foot
var areaSqFt = areaSqIn / 144;
// 3. Calculate Cubic Feet per Second (CFS)
// Q = Area (sq ft) * Velocity (ft/sec)
var flowCFS = areaSqFt * velocity;
// 4. Convert CFS to Gallons Per Minute (GPM)
// 1 CFS is approximately 448.831 GPM
var flowGPM = flowCFS * 448.831;
// 5. Calculate Gallons Per Hour (GPH)
var flowGPH = flowGPM * 60;
// Display Results
document.getElementById('resGPM').innerText = flowGPM.toLocaleString(undefined, {minimumFractionDigits: 2, maximumFractionDigits: 2});
document.getElementById('resGPH').innerText = flowGPH.toLocaleString(undefined, {minimumFractionDigits: 2, maximumFractionDigits: 2});
document.getElementById('resCFS').innerText = flowCFS.toLocaleString(undefined, {minimumFractionDigits: 4, maximumFractionDigits: 4});
document.getElementById('resArea').innerText = areaSqIn.toLocaleString(undefined, {minimumFractionDigits: 3, maximumFractionDigits: 3});
document.getElementById('psResult').style.display = 'block';
}