Here, we compute the friction factor versus the Reynolds number for pipes with a specific relative roughness using the Colebrook - White implicit equation (Ref. 1). Our method is based on the arc-length continuation technique.The Colebrook-White Equation is used to approximate the Darcy friction factor for turbulent flow in full flowing pipes. This equation is given below:The friction factor, f, is required to calculate the pressure drop or head loss due to wall roughness using the Darcy - Weisbach equation.Our results are checked against the Moody chart first given in Ref. 2.
Moody Chart from the Web ( https://www.tec-science.com/mechanics/gases-and-liquids/moody-chart-diagram/ )
In[]:=
IMG=
;
In[]:=
Show[IMG,ImageSize{450,450}]
Selected values of the relative roughness.
In[]:=
relepsilon={510^-2,410^-2,310^-2,210^-2,110^-2,510^-3,210^-3,110^-3,510^-4,210^-4,110^-4,510^-5,210^-5}//N;
Application of the arc-length continuation in order to compute the friction factor, f, versus the Reynolds number for various values of the pipe relative roughness
Two coupled equations are to be solved using NDSolve:
1st equation is the Colebrook and White equation
2nd equation is the auxiliary equation
Two coupled equations are to be solved using NDSolve:
1st equation is the Colebrook and White equation
2nd equation is the auxiliary equation
In[]:=
eq1[i_]:=1/Sqrt[f]-2.0Log[10,relepsilon[[i]]/3.7+2.51/(REYNOLDSSqrt[f])]/.ff[s]/.REYNOLDSREYNOLDS[s]
In[]:=
auxeq=REYNOLDS'[s]^2+f'[s]^21;
In[]:=
sol[i_]:=Quiet@NDSolve[{eq1[i],auxeq,f[0]0.0045,REYNOLDS[0]510^3,f'[0]-0.1,REYNOLDS'[0]0.1},{f,REYNOLDS},{s,-10000,10^8},AccuracyGoal5]
In[]:=
SOL=Table[sol[i],{i,1,Length[relepsilon]}];
In[]:=
data[i_]:=Flatten[Table[{REYNOLDS[j],f[j]}/.SOL[[i]],{j,0,10^7,10000}],1];
Comparison between our results (colored dashed lines) and their counterparts given in the Moody Chart.
Legend gives the values of the relative roughness.
Legend gives the values of the relative roughness.
In[]:=
ListLogLogPlot[Table[data[i],{i,1,Length[relepsilon]}],JoinedTrue,PlotStyleTable[{Hue[i/20],Dashed,Thickness[0.0035]},{i,1,Length[relepsilon]}],PlotLegends->Placed[SwatchLegend[Table[Hue[i/20],{i,1,Length[relepsilon]}],Table[Style[relepsilon[[i]],14]//ScientificForm,{i,1,Length[relepsilon]}],LegendMarkersGraphics[{EdgeForm[Black],Opacity[0.9],Rectangle[]}],LegendFunction(Framed[#,RoundingRadius5]&),LegendMargins10],Right],GridLinesAutomatic,FrameTrue,PlotRange{{1000,10^7},{0.0099,0.1}},AspectRatio0.75,ImageSize{500,500},Prolog{Raster[ImageData[IMG,DataReversedTrue],{Scaled[{0.0,0.0}],Scaled[{1,1}]}]}]
References
References
◼
[1] Colebrook C. F. and White C. M., Experiments with fluid friction in roughened pipes, Proc. R. Soc. Lond. A, Vol. 161, pp. 367–381, 1937.
http://doi.org/10.1098/rspa.1937.0150
http://doi.org/10.1098/rspa.1937.0150
◼
[2] L. Moody, Friction Factors for pipe flow, Trans. ASME, Vol. 66, Issue 8, pp. 671-684, 1944.
https://doi.org/10.1115/1.4018140
https://doi.org/10.1115/1.4018140
CITE THIS NOTEBOOK
CITE THIS NOTEBOOK
Moody Diagram versus Colebrook - White Equation using Arc-Length Continuation
by Housam Binous and Ahmed Bellagi
Wolfram Community, STAFF PICKS, January 18, 2024
https://community.wolfram.com/groups/-/m/t/3105217
by Housam Binous and Ahmed Bellagi
Wolfram Community, STAFF PICKS, January 18, 2024
https://community.wolfram.com/groups/-/m/t/3105217