Skip to content

rajdeep13-coder/pipe-flow

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pipe Flow Energy Efficiency — Laminar to Turbulent Transition

Computational study of how flow regime transition affects energy loss in water pipe systems, using Reynolds number, Poiseuille's Law, and the Darcy–Weisbach equation.

Python License: MIT ResearchGate


Overview

This repository contains the complete, reproducible Python simulation used in the paper:

"How the Laminar-to-Turbulent Transition Affects Energy Efficiency in Water Pipe Systems: A Computational Study Using Reynolds Number, Poiseuille's Law, and the Darcy–Weisbach Equation"

Rajdeep Paul — Academy Of Technology 📄 Full Paper on ResearchGate https://doi.org/10.13140/RG.2.2.35092.26243

Key Finding

Increasing pipe diameter from 2 cm → 20 cm (at fixed flow rate Q = 0.01 m³/s) reduces:

  • Head loss from 2,889 m → 0.05 m — a reduction of > 99.99%
  • Required pumping power from 283 kW → 5 W

Physics Background

The energy efficiency of a water pipe system is governed by three core principles:

1. Reynolds Number — determines the flow regime:

Re = ρvD / μ

  Re < 2,300   →  Laminar      (smooth, ordered flow)
  2300–4000    →  Transitional (unstable, avoid in design)
  Re > 4,000   →  Turbulent    (chaotic eddies, high energy loss)

2. Darcy–Weisbach Equation — universal head loss formula:

hf = f × (L/D) × (v²/2g)

  Laminar:    f = 64/Re                   (exact)
  Turbulent:  f = 0.316 × Re^(-0.25)     (Blasius, smooth pipe)

3. Pumping Power:

P = ρ g Q hf   [Watts]

In turbulent flow, hf ∝ v^1.75 — doubling velocity increases head loss by ~3.4×, not 2×.


Repository Structure

pipe-flow-energy-efficiency/
│
├── pipe_flow_simulation.py      ← Main simulation script (run this)
│
├── outputs/                     ← Generated automatically on first run
│   ├── sim1_velocity_results.csv
│   ├── sim2_diameter_results.csv
│   ├── fig1_velocity_vs_headloss.png
│   ├── fig2_diameter_vs_headloss.png
│   ├── fig3_moody_friction.png
│   └── fig4_pumping_power.png
│
├── figures/                     ← Pre-generated figures for this README
│   └── *.png
│
├── README.md
└── LICENSE

Installation & Usage

Requirements

pip install numpy pandas matplotlib

Python 3.7 or higher required. No other dependencies.

Run the simulation

git clone https://github.com/rajdeep13-coder/pipe-flow.git
cd pipe-flow-energy-efficiency
python pipe_flow_simulation.py

All outputs are automatically saved to the outputs/ folder.


Simulation Scenarios

Scenario A — Fixed Diameter, Varying Velocity

Parameters: D = 0.05 m, L = 100 m

Velocity (m/s) Reynolds No. Regime f hf (m) Power (W)
0.01 500 Laminar 0.12800 0.0013 0.0
0.05 2,500 Transitional N/A N/A N/A
0.10 5,000 Turbulent 0.03758 0.0383 0.07
0.50 25,000 Turbulent 0.02513 0.6404 6.17
1.00 50,000 Turbulent 0.02113 2.154 41.5
2.00 100,000 Turbulent 0.01777 7.246 279.1
5.00 250,000 Turbulent 0.01413 36.01 3,469

Scenario B — Fixed Flow Rate, Varying Diameter

Parameters: Q = 0.01 m³/s, L = 100 m

Diameter (m) Velocity (m/s) Reynolds No. hf (m) Power (W)
0.02 31.83 636,620 2,888.6 283,372
0.05 5.09 254,648 37.19 3,649
0.10 1.27 127,324 1.382 135.6
0.15 0.57 84,883 0.201 19.8
0.20 0.32 63,662 0.051 5.0

Figures

Figure Description
Fig 1 Fig 1 — Head loss vs. velocity (log–log). Regime transitions clearly marked.
Fig 2 Fig 2 — Head loss vs. diameter (semi-log). Dramatic reduction with larger pipe.
Fig 3 Fig 3 — Moody-style friction factor diagram for smooth pipe.
Fig 4 Fig 4 — Pumping power vs. diameter. 283 kW → 5 W by increasing D from 2 cm to 20 cm.

Design Recommendations

Based on simulation results:

  1. Target flow velocity: 0.5–2.0 m/s — keeps Re in lower turbulent range
  2. Use the largest practical pipe diameter — hf scales as D^(-4.75) at fixed Q
  3. Avoid the transitional regime (Re 2,300–4,000) — unstable and inefficient
  4. Use smooth-bore materials (PVC, HDPE) to stay on the Blasius curve
  5. Economic optimum typically lies where pipe CAPEX ≈ NPV of pumping energy savings

Extending the Model

The current model assumes smooth pipes. To add roughness (Colebrook–White equation):

import scipy.optimize as opt

def friction_factor_rough(Re, epsilon, D):
    """
    Colebrook–White equation for rough pipes (implicit, solved iteratively).
    epsilon : absolute roughness [m] (e.g. 0.046e-3 for commercial steel)
    """
    def colebrook(f):
        return 1/f**0.5 + 2.0*np.log10(epsilon/(3.7*D) + 2.51/(Re*f**0.5))
    f0 = 0.02  # initial guess
    return opt.fsolve(colebrook, f0)[0]

Other natural extensions:

  • Pipe network analysis (Hardy Cross method)
  • Seasonal temperature variation (μ changes with T)
  • CFD validation using OpenFOAM
  • Economic optimization (minimize CAPEX + NPV of OPEX)

Citation

If you use this code or data in your research, please cite:

@article{yourname2024pipeflow,
  title   = How the Laminar-to-Turbulent Transition Affects Energy Efficiency
             in Water Pipe Systems,
  author  = Rajdeep Paul,
  year    = 2026,
  journal = Preprint — ResearchGate,
  url     = https://doi.org/10.13140/RG.2.2.35092.26243
}

References

Fundamental Theory & Flow Regimes

  1. Reynolds, O. (1883). An experimental investigation of the circumstances which determine whether the motion of water shall be direct or sinuous, and of the law of resistance in parallel channels. Philosophical Transactions of the Royal Society of London, 174, 935–982. https://doi.org/10.1098/rstl.1883.0029

  2. Darcy, H. (1857). Recherches expérimentales relatives au mouvement de l'eau dans les tuyaux. Mallet-Bachelier.

  3. Weisbach, J. (1845). Lehrbuch der Ingenieur- und Maschinen-Mechanik [Textbook of engineering and machine mechanics]. Vieweg.

  4. Nikuradse, J. (1933). Strömungsgesetze in rauhen Rohren [Flow laws in rough pipes] (VDI-Forschungsheft 361). VDI-Verlag.

  5. Colebrook, C. F. (1939). Turbulent flow in pipes, with particular reference to the transition region between the smooth and rough pipe laws. Journal of the Institution of Civil Engineers, 11(4), 133–156. https://doi.org/10.1680/ijoti.1939.13150

  6. Moody, L. F. (1944). Friction factors for pipe flow. Transactions of the ASME, 66(8), 671–684.

Modern Textbooks & Comprehensive References

  1. Munson, B. R., Young, D. F., Okiishi, T. H., & Huebsch, W. W. (2013). Fundamentals of fluid mechanics (7th ed.). Wiley.

  2. White, F. M. (2016). Fluid mechanics (8th ed.). McGraw-Hill Education.

Recent Empirical & Friction Factor Studies

  1. Avci, A., & Karagoz, I. (2019). A new explicit friction factor formula for laminar, transition and turbulent flows in smooth and rough pipes. European Journal of Mechanics - B/Fluids, 78, 182–191. https://doi.org/10.1016/j.euromechflu.2019.07.007

Energy Efficiency & Optimization

  1. Bolognesi, A., et al. (2014). Energy efficiency optimization in water distribution systems. Procedia Engineering, 70, 181–190. https://doi.org/10.1016/j.proeng.2014.02.021

  2. Gessler, J., & Walski, T. M. (1985). Water distribution system optimization (Technical Report EL-85-11). U.S. Army Engineer Waterways Experiment Station.

  3. Pang, Y., et al. (2022). Synchronization optimization of pipe diameter and pump operation frequency in irrigation systems. Agriculture, 12(5), Article 673. https://doi.org/10.3390/agriculture12050673

Contemporary & Applied Resources

  1. Engineering Toolbox. (2024). Laminar, transitional and turbulent flow. https://www.engineeringtoolbox.com/laminar-transitional-turbulent-flow-d_577.html

  2. Michael Smith Engineers. (2023). Pipe flow velocity recommendations. https://www.michael-smith-engineers.co.uk

  3. Fiorillo, F., et al. (2024). New insights into turbulent and laminar flow regimes in drainage systems. Water, 16(10), Article 1452. https://doi.org/10.3390/w16101452

  4. Wikipedia. (2024). Darcy–Weisbach equation. https://en.wikipedia.org/wiki/Darcy–Weisbach_equation

    Note: Wikipedia is acceptable for quick reference or definition in student and preprint work but should be supplemented with primary sources in formal journal submissions.


License

MIT License — see LICENSE for details. Free to use, modify, and distribute with attribution.

About

This study investigates the impact of flow regime transition on energy efficiency using the Reynolds number (Re), the Navier–Stokes equations, Poiseuille's law for laminar flow, and the Darcy–Weisbach equation for the general case.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages