import matplotlib.pyplot as plt
import numpy as np
import math
def f(x):
e=0.025;
p=701;
mu=0.51e-3;
D=14.64;
tf=e/D;
fp=0.023
return
1/np.sqrt(fp)+2*np.log(tf/3.7065-5.0452*np.log((tf**1.3098)/2.8257+5.8506*(x**(-0.8981)))/x);
def fun(x):
e=0.025;
p=701;
mu=0.51e-3;
D=14.64;
tf=e/D;
yy=-2*np.log(tf/3.7065-5.0452*np.log((tf**1.3098)/2.8257+5.8506*(x**(-0.8981)))/x);
return 1.0/(yy*yy);
def secant(x1, x2, E):
n = 0; xm = 0; x0 = 0; c = 0;
if (f(x1) * f(x2) < 0):
while True:
# calculate the intermediate value
x0 = ((x1 * f(x2) - x2 * f(x1)) /
(f(x2) - f(x1)));
# check if x0 is root of
# equation or not
c = f(x1) * f(x0);
# update the value of interval
x1 = x2;
x2 = x0;
# update number of iteration
n += 1;
# if x0 is the root of equation
# then break the loop
if (c == 0):
break;
xm = ((x1 * f(x2) - x2 * f(x1)) /
(f(x2) - f(x1)));
if(abs(xm - x0) < E):
break;
print("Reynolds number =",
round(x0, 6));
print("No. of iterations = ", n);
else:
print("Can not find a root in ",
"the given inteval");
return x0;
# Driver code
# initializing the values
x1 = 10;
x2 = 1000;
E = 0.001e-2;
Re=secant(x1, x2, E);
Re=np.linspace(3000,500000);
ff=fun(Re);
plt.plot(ff,Re);
plt.show();
In fluid flow problems, the flow velocity in a long horizontal pipe depends on the pipe...
In fluid flow problems, the flow velocity in a long horizontal pipe depends on the pipe material, pipe geometry and fluid properties in addition to the pump power. For a horizontal pipe with a pump, the friction factor can be obtained from many correlations such as Colebrook-White Equation: 1.1098 :-2 log 3.7065 r) 5.0452 -log Re +5.8506 (Re) -0.8981 -) 2.8257 (1) In which, fis the friction factor and is the roughness ratio given by: given by: PDV Re Where...
use python program In fluid flow problems, the flow velocity in a long horizontal pipe depends on the pipe material, pipe geometry and fluid properties in addition to the pump power. For a horizontal pipe with a pump, the friction factor can be obtained from many correlations such as Colebrook-White Equation: 1.1090 7--2109 C 5.0452 3.7065 Re log +5.8506 (Re) -6.8901 (1) 2.8257 In which, f is the friction factor and r is the roughness ratio given by: given by:...
solve using paython In fluid flow problems, the flow velocity in a long horizontal pipe depends on the pipe material, pipe geometry and fluid properties in addition to the pump power. For a horizontal pipe with a pump, the friction factor can be obtained from many correlations such as Colebrook-White Equation: 1.1998 5.0452 (6) log Re 28257 -)} (1) 3.7065 7--2 log +58506 (Re)-0.3981 In which, f is the friction factor and is the roughness ratio given by: given by:...
Engineering economy In fluid flow problems, the flow velocity in a long horizontal pipe depends on the pipe material, pipe geometry and fluid properties in addition to the pump power. For a horizontal pipe with a pump, the friction factor can be obtained from many correlations such as Colebrook-White Equation: 2.100 =-2 logo 5.0452 Re log + 5.8506 (Re)-a) (1) 3.7065 2.4257 In which, fis the friction factor and ris the roughness ratio given by: given by: pDV Where is...
anbox (31184010sents * Microsoft Word - 1-friction facto X Downloads/midcomp.pdf In fluid flow problems, the flow velocity in a long horizontal pipe depends on the pipe material, pipe geometry and fluid properties in addition to the pump power. For a horizontal pipe with a pump, the friction factor can be obtained from many correlations such as Colebrook-White Equation: 5.0452 Re IOR 2.8257 PDV 1 = -2 108 3.7065 +5.8506 (Re)-0.0001 (1) In which, fis the friction factor and pris the...
Please help with the following matlab code and please show all work. Thank you! Viscous losses in a pipe are expressed in terms of a friction factor, f. It is important to know the frictional forces in pipe flow because they result in pressure loss which must be accounted for in the piping system. For turbulent low in pipes, the friction factor is caleulated using the Colebrook e/D 2.51 where e is the roughness height, D is the pipe diameter...
Please solve a,b,c,d,e,f 1) A water fountain is to be installed at a remote location by attaching a cast iron pipe directly to a water main through which water is flowing. The entrance to the pipe is sharp-edged 15m (K-0.5), and the 15m long piping system involves three 90 bends without vanes (K1.1), a fully open gate valve (K.-0.2), and a fully open angle valve (K-5). If the diameter of the pipe is 2 em and the system is to...
3. (a) For the flow of a real fluid (p, u) in a rough (e measures losses lead to a pressure gradient along the pipe - Ap/L. Determine an expression for the pressure roughness) horizontal pipe energy Ap ( L pV2 gradient for a pipe of diameter - d, flowing with a mean velocity - V. pVd'd d (b) If for a 75mm diameter pipe flowing with water at 0.25m/s the measured pressure drop is 120Pa/m What will be the...
A 1-mile long 12-inch diameter asphalt dipped cast iron pipe (e = 0.00085 ft) conveys 60°F water at 3 cfs. Determine (a) friction factor f using the Moody Diagram, (b) f using the Colebrook equation, (c) head loss over the 1 mile distance, (d) slope of the EGL. Problem 2 A 1-mile long 12-inch diameter asphalt dipped cast iron pipe (e = 0.00085 ft) conveys 60℉ water at 3 cfs Determine (a) friction factor fusing the Moody Diagram, (b) fusing...
Use the moody diagram provided. You have riveted circular steel pipe that is 1.5ft in diameter. The roughness is ε=0.003ft. Water at T=60oF flowing through the pipe. What is the relative roughness, ε/D, of the pipe? What is the kinematic viscosity of the water in ft2/s? What is the velocity for the Reynold’s number to be Re=1000? Ans 0.00811ft/s What is the velocity needed for the Reynold’s number to be Re=30,000? Ans 0.243ft/s What is the velocity for the Reynold’s...