Chapter 7 : Flow Through Pipes

Example 7.1 Page No : 209

In [1]:
import math 


# Calculations and Results
print ("Part(i)");
print ("Absolute unit of viscosity(in C.G.S) is Poise.");
print ("Poise = 1 dyne-sec/cm**2");
print ("Gravitational unit of viscosity is 1 gm-sec/cm**2.");
print ("On equating we get, 1 gm  =  981 dyne");
#Let x = 1kg-sec/m**2
x = 1*10.**3/10**4;			#g-sec/cm**2
x = x*981;			#dyne-sec/cm**2 or Poise(Putting 1gm = 981 dyne)
print "1 kg-sec/m**2  =  ",(x)," Poise"
one_Poise = 1./x;			#kg-sec/m**2
one_Poise = 1/x*9.81;			#N-sec/m**2 or Pa-sec(as 1Pa = 1N/m**2)
print "1 Poise  =  ",(one_Poise)," N-sec/m**2 or Pa-sec"
print ("Part(ii)");
print ("Kinematic viscosity  =  viscosity/specific_gravity");
print ("Kinematic viscosity C.G.S unit is cm**2/sec. 1cm**2/sec = 1stoke");
print ("Kinematic viscosity M.K.S unit is m**2/sec");
			#let x = 1;			#m**2/sec
x = 1.;			#m**2/sec
x = x*10**4;			#cm**2/sec or stokes
print "1 m**2/sec  =  ",(x)," cm**2/sec or stoke"
one_stoke = 1/x;			#m**2/sec
print "1 stoke  =  ",(one_stoke)," m**2/sec"
print ("1 stoke  =  100 centi-stokes");
Part(i)
Absolute unit of viscosity(in C.G.S) is Poise.
Poise = 1 dyne-sec/cm**2
Gravitational unit of viscosity is 1 gm-sec/cm**2.
On equating we get, 1 gm  =  981 dyne
1 kg-sec/m**2  =   98.1  Poise
1 Poise  =   0.1  N-sec/m**2 or Pa-sec
Part(ii)
Kinematic viscosity  =  viscosity/specific_gravity
Kinematic viscosity C.G.S unit is cm**2/sec. 1cm**2/sec = 1stoke
Kinematic viscosity M.K.S unit is m**2/sec
1 m**2/sec  =   10000.0  cm**2/sec or stoke
1 stoke  =   0.0001  m**2/sec
1 stoke  =  100 centi-stokes

Example 7.2 Page No : 210

In [2]:
import math 
			
# Variables :
mu = 0.009;			#kg-sec/m**2
rho = 0.89;			#sp. gravity
Q = 4.*10**-3;			#m**3/sec
d = 30./1000;			#meter

# Calculations and Results
v = mu/rho;			#m**2/s
print "Kinematic viscosity in m**2/sec : %.4f"%v
A = math.pi*d**2/4;			#m**2
vm = Q/A;			#m/s
Rn = vm*d/v;			#Reynolds no.
print "Reynolds number for flow  : %.1f"%Rn
print ("This is laminar flow because Rn no. is less than 2000.");
Kinematic viscosity in m**2/sec : 0.0101
Reynolds number for flow  : 16.8
This is laminar flow because Rn no. is less than 2000.

Example 7.3 Page No : 211

In [3]:
import math 
			
# Variables :
d = 200./1000;			#meter
Q = 40.*10**-3;			#m**3/sec
A = math.pi*d**2/4;			#m**2
vm = Q/A;			#m/s
v = 0.25*10**-4;			#m**2/s

# Calculations and Results
Rn = vm*d/v;			#Reynolds no.
print "Reynolds number for flow  : %.f"%Rn
print ("This is turbulent flow because Rn no. is greater than 4000.");
print "New Reynolds number for flow  : %.f"%(Rn/8)
print ("This is laminar flow because Rn no. is less than 2000.");
Reynolds number for flow  : 10186
This is turbulent flow because Rn no. is greater than 4000.
New Reynolds number for flow  : 1273
This is laminar flow because Rn no. is less than 2000.

Example 7.4 Page No : 218

In [4]:
import math 
			
# Variables :
D = 30./100;			#meter
L = 100.;			#meter
v = 0.01*10**-4;			#m**2/s
a = 3.;			#m/s
g = 9.81;			#gravity consmath.tanty
Rn = a*D/v;			#Reynolds no.

# Calculations
f = 0.079/Rn**(1./4);			#umath.sing blasius formula 
hf = 4*f*L/D*a**2/2/g;			#meter

# Results
print "Head lost in meter : %.2f"%hf

#Answer in the book is wrong.
Head lost in meter : 1.57

Example 7.5 Page No : 219

In [5]:
import math 
			
# Variables :
D = 30./100;			#meter
L = 500.;			#meter
Q = 300.*10**-3;			#m**2/sec
f = 0.0008;			#coeff. of friction

# Calculations
v = Q/(math.pi/4*D**2);			#m/s
g = 9.81;			#gravity consmath.tanty
hf = 4*f*L*v**2/D/2/g;			#meter

# Results
print "Difference in elevation in meter : %.2f"%hf

#Answer in the book is wrong.
Difference in elevation in meter : 4.90

Example 7.6 Page No : 219

In [6]:
import math 
			
# Variables :
D = 20./100;			#meter
v = 3.;			#m/s
v1 = 0.01*10**-3;			#m**2/sec
Re = D*v/v1;			#Reynolds number
f = 0.002+0.09/Re**0.3;			#coeff. of friction
L = 5.;			#meter
g = 9.81;			#gravity consmath.tanty

# Calculations
hf = 4*f*L*v**2/D/2/g;			#meter

# Results
print "Head lost due to friction in meter : %.3f"%hf
Head lost due to friction in meter : 0.244

Example 7.7 Page No : 230

In [7]:
import math 
			
# Variables :
D = 80./1000;			#meter
Q = 600.*10**-3/60;			#m**3/sec
L = 1.*10**3;			#meter
f = 0.02;			#coefficient of friction

# Calculations
v = Q/(math.pi/4*D**2);			#m/s
g = 9.81;			#gravity consmath.tanty
hf = 4*f*L*v**2/D/2/g;			#meter

# Results
print "Head lost due to friction in meter : %.3f"%hf

#Answer is wrong in the book.
Head lost due to friction in meter : 201.726

Example 7.8 Page No : 230

In [8]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tanty
f = 0.02;			#coefficient of friction
Cc = 0.62;			#coefficient of contraction

# Calculations
#Portion AB
Q1 = 50.*10**-3;			#m**3/sec
D1 = 150./1000;			#meter
v1 = Q1/(math.pi/4*D1**2);			#m/s
hr = 0.5*v1**2/2/g;			#meter
L1 = 200.;			#meter
hf1 = 4*f*L1*v1**2/2/g/D1;			#meter
D2 = 200./1000;			#meter
v2 = Q1/(math.pi/4*D2**2);			#m/s
hc1 = (v1-v2)**2/2/g;			#meter
L2 = 500.;			#meter
hf2 = 4*f*L2*v2**2/2/g/D2;			#meter
d = 75./1000;			#meter
ho = ((math.pi/4*D2**2)/Cc/((math.pi/4*D2**2)-(math.pi/4*d**2))-1)**2*v2**2/2/g;			#meter
D3 = 120./1000;			#meter
v3 = Q1/(math.pi/4*D3**2);			#m/s
hc2 = v3**2/2/g*(1/Cc-1)**2;			#meter
L3 = 500.;			#meter
hf3 = 4*f*L3*v3**2/2/g/D3;			#meter
Kb = 0.25;			#assumed
hb1 = Kb*v3**2/2/g;			#meter
D4 = 120./1000;			#meter
v4 = Q1/(math.pi/4*D4**2);			#m/s
L4 = 500.;			#meter
hf4 = 4*f*L4*v4**2/2/g/D4;			#meter
hb2 = Kb*v3**2/2/g;			#meter
L5 = 500.;			#meter
hf5 = 4*f*L5*v4**2/2/g/D4;			#meter
h_outlet = v3**2/2/g;			#meter
h_total = hr+hf1+hc1+hf2+ho+hc2+hf3+hb1+hf4+hb2+hf5+h_outlet;			#meter

# Results
print "Total loss of head in meter : %.f"%h_total
Total loss of head in meter : 1068

Example 7.9 Page No : 233

In [9]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tanty
Cc = 0.62;			#coefficient of contraction
D1 = 150./1000;			#meter
D2 = 100./1000;			#meter
Q = 2.7/60;			#m**3/sec
p1 = 0.8*10**4;			#kg/m**2

# Calculations
v1 = Q/(math.pi/4*D1**2);			#m/s
v2 = Q/(math.pi/4*D2**2);			#m/s
hc = v2**2/2/g*(1/Cc-1)**2;			#meter
w = 1000;			#kg/m**3
p2 = (v1**2/2/g+p1/w-v2**2/2/g-hc)*w;			#kg/m**2(Z1 = Z2)
p2 = p2*10**-4;			#kg/cm**2

# Results
print "Intensity of pressure in kg/cm**2 : %.4f"%p2
Intensity of pressure in kg/cm**2 : 0.6029

Example 7.10 Page No : 238

In [10]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tanty
L = 3.*1000;			#meter
hf = 20.;			#meter
Q = 1.;			#m**3/sec
f = 0.02;			#coeff. of friction

# Calculations
#v = math.sqrt(hf*2*g/4/f/L/D);			#it is v**2*D
D2v = Q/(math.pi/4);			#it is D**2*v
D = (Q/(math.pi/4)/math.sqrt(hf*2*g/4/f/L))**(2./5);			#meter
D = D*1000;			#mm

# Results
print "Diameter of pipe in mm   : %.f"%D
Diameter of pipe in mm   : 998

Example 7.11 Page No : 238

In [11]:
import math 

# Variables :
g = 9.81;			#gravity consmath.tanty
D1 = 100./1000;			#meter
D2 = 200./1000;			#meter
PQ = 100.;			#meter
QR = 100.;			#meter
slope = 1./100;			#upward slope
Q = 0.02;			#cumec
p1 = 2.;			#kg/cm**2(Pressure in 100 mm dia pipe)
f = 0.02;			#unitless
Q_P = 100./100;			#meter(Point Q hight respect to point P)
Q_R = 200./100;			#meter(Point Q hight respect to point R)

# Calculations and Results
v1 = Q/(math.pi/4*D1**2);			#m/sec
v2 = Q/(math.pi/4*D2**2);			#m/sec
hf1 = 4*f*PQ*v1**2/(2*g*D1);			#meter
hf2 = 4*f*QR*v2**2/(2*g*D2);			#meter
hse = (v1-v2)**2/2/g;			#meter(loss due to sudden enlargement)
#Section PQ
Z1P = 0;			#meter(Datum Head)
H1P = v1**2/2/g;			#meter(velocity Head)
p1BYw = p1*10**4/1000;			#meter(Pressure Head at P)
Z1Q = 1;			#meter(Datum Head)
H1Q = v2**2/2/g;			#meter(velocity Head)
#Applying bernaullis theorem
p2BYw = Z1P+p1BYw+H1P-Z1Q-H1Q-hf1;			#meter(Pressure Head at Q)

print "Pressure Head at point P(m)",p1BYw
print "Velocity Head at point P(m) %.3f"%H1P
print "Pressure Head at point Q(m) : %.3f"%p2BYw

#Section QR
#Applying bernaullis theorem
p2dashBYw = p2BYw+H1P-H1Q-hse;			#meter(Pressure Head at Q)
Z2 = 1;			#meter(Datum Head)
H1Q = v2**2/2/g;			#meter(velocity Head)
Z3 = 2;			#meter(Datum Head at R)
H1R = v2**2/2/g;			#meter(velocity Head at R)

#Applying bernaullis theorem
p3BYw = Z2+p2dashBYw+H1Q-Z3-H1R-hf2;			#meter(Pressure Head at R)
print "Velocity Head at point Q after enlargemant(m) : %.2f"%H1Q
print "Pressure Head at point Q after enlargemant(m) : %.3f"%p2dashBYw
print "Pressure Head at point R(m) : %.3f"%p3BYw
print "Velocity Head at point R(m) : %.3f"%H1R


#Answer in the book is wrong for some calculations.
Pressure Head at point P(m) 20.0
Velocity Head at point P(m) 0.331
Pressure Head at point Q(m) : -7.131
Velocity Head at point Q after enlargemant(m) : 0.02
Pressure Head at point Q after enlargemant(m) : -7.007
Pressure Head at point R(m) : -8.833
Velocity Head at point R(m) : 0.021

Example 7.12 Page No : 246

In [12]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tanty
D1 = 400./1000;			#meter
D2 = 300./1000;			#meter
D3 = 200./1000;			#meter
v1 = 3;			#m/s
v2 = 2;			#m/s

# Calculations and Results
A1 = math.pi/4*D1**2;			#m**2
A2 = math.pi/4*D2**2;			#m**2
A3 = math.pi/4*D3**2;			#m**2
Q1 = A1*v1;			#cumec
print "Discharge in pipe 1 in cumec : %.4f"%Q1

Q2 = A2*v2;			#cumec
Q3 = Q1-Q2;			#cumec
v3 = Q3/A3;			#m/s
print "Velocity of water in 200mm pipe in m/s : ",v3
Discharge in pipe 1 in cumec : 0.3770
Velocity of water in 200mm pipe in m/s :  7.5

Example 7.13 Page No : 247

In [13]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tanty
D1 = 100./1000;			#meter
D2 = 300./1000;			#meter

# Calculations
Q1 = 0.01;			#m**3/sec
A1 = math.pi/4*D1**2;			#m**2
A2 = math.pi/4*D2**2;			#m**2
			#hf1 = hf2
Q2 = math.sqrt(D2/(D1)*(Q1/A1)**2*A2**2);			#cumec

# Results
print "Discharge throough 300mm pipe in cumec : %.3f"%Q2
Discharge throough 300mm pipe in cumec : 0.156

Example 7.14 Page No : 248

In [14]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tanty
f = 0.02;			#coeff. of friction
PQ = 500.;			#meter
QR = 1000.;			#meter
RS = 500.;			#meter

# Calculations
hf = 10+PQ/62.5+QR/125-RS/100-2;			#meter
l = 500+1000+500;			#/meter
D = 250./1000;			#meter
v = math.sqrt(hf*2*g*D/4/f/l);			#m/s
Q = math.pi/4*D**2*v;			#m**3/sec
Q = Q*1000;			#litres/sec

# Results
print "Discharge in pipe line in litres/sec : %.f"%Q
Discharge in pipe line in litres/sec : 37

Example 7.15 Page No : 249

In [15]:
import math 

# Variables :
g = 9.81;			#gravity consmath.tant
slope = 1./125;			#slope
hA = 12.;			#meter(level of water in reservoir A)
hB = 1.5;			#meter(level of water in reservoir B)
L1 = 500.;			#meter
D1 = 250./1000;			#meter
L2 = 1000.;			#meter
D2 = 200./1000;			#meter
L3 = 500.;			#meter
D3 = 150./1000;			#meter

# Calculations
f = 0.02;			#coeff. of friction
fall_level = (L1+L2+L3)*slope;			#meter
H = hA+fall_level-hB;			#meter(Head available for flow)
v2BYv1 = (D1/D2)**2;
v3BYv1 = (D1/D3)**2;
#H = hf = hf1+hf2+hf3
#H = (4*f*L1*v1**2/(2*g*D1)+4*f*L2*v2**2/(2*g*D2)+4*f*L3*v3**2/(2*g*D3))
v1 = math.sqrt(H/(4*f*L1/(2*g*D1)+4*f*L2*v2BYv1**2/(2*g*D2)+4*f*L3*v3BYv1**2/(2*g*D3)));			#m/s
Q = math.pi*D1**2/4*v1;			#m**3/sec
Q = Q*1000;			#litres/sec

# Results
print "Discharge in pipe line in litres/sec : %.1f"%Q
Discharge in pipe line in litres/sec : 19.8

Example 7.16 Page No : 250

In [16]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tant
l = 4.;			#km
n = 5000.;			#habimath.tants
Ch = 200.;			#litres/day(habimath.tant capacity)
t = 10.;			#hour(daiy supply time)
hf = 20.;			#meter(Head loss)
f = 0.008;			#coeff. of friction

# Calculations
Qty = n*Ch/2;			#litres(Water supplied in 10 hours)
Q = Qty/(t*60*60);			#litres/sec
Q = Q/1000;			#m**3/sec
d = (f*l*1000*Q**2/3.0257/hf)**(1./5);			#meter

# Results
print "Diameter of pipe(mm) : %.f"%(d*1000)
Diameter of pipe(mm) : 159

Example 7.17 Page No : 251

In [17]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tant
D1 = 50./1000;			#meter
D2 = 100./1000;			#meter
l1 = 100.
l2 = 100.;			#meter
hf1 = 10.;			#meter(level difference)
f = 0.008;			#coeff. of friction

# Calculations and Results
Q2BYQ1 = math.sqrt((l1/l2)*(D2/D1)**5);			#as hf1 = hf2
Q1 = math.sqrt(hf1/f/l1*(3.0257*D1**5));			#m**3/sec
Q2 = Q2BYQ1*Q1;			#m**3/sec or cumec
print "Rate of flow of pipe 1(m**3/sec) : %.2e"%Q1
print "Rate of flow of pipe 2(m**3/sec) : %.3f"%Q2

Q = Q1+Q2;			#m**3/sec(Total Discharge)
d = (f*l1*Q**2/3.0257/hf1)**(1./5);			#meter
print "Diameter of math.single pipe(mm) : %.1f"%(d*1000)


#Answer in the book is not accurate.
Rate of flow of pipe 1(m**3/sec) : 3.44e-03
Rate of flow of pipe 2(m**3/sec) : 0.019
Diameter of math.single pipe(mm) : 106.7

Example 7.18 Page No : 252

In [18]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tant
D = 30./100;			#meter
l = 400.;			#meter
Q = 300.;			#litres/sec
f = 0.008;			#coeff. of friction
Q = Q*10**-3;			#m**3/sec

# Calculations
A = math.pi*D**2/4;			#m**2
v = Q/A;			#m/s(velocity of flow)
h1 = 0.5*v**2/2/g;			#meter(Head loss at entrance to a pipe)
h2 = 4*f*l*v**2/(2*g*D);			#meter(Head loss due to friction)
h3 = v**2/2/g;			#meter(Head loss at entrance of reservoir)
H = h1+h2+h3;			#meter(Difference of water level)

# Results
print "Difference of water level between two reservoir(meter) : %.3f"%H

#Answer in the book is not accurate as h2 is calculated wrong.
Difference of water level between two reservoir(meter) : 40.548

Example 7.19 Page No : 254

In [19]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tant
D = 150./1000;			#meter
l = 70.;			#meter
H = 2.6;			#meter(head of water)
f = 0.01;			#coeff. of friction

# Calculations
#Applyong Bernoullis theorem
v = math.sqrt(H*(2/g*(1+0.5+4*f*l/D))/4);			#m/s
Q = math.pi*D**2/4*v;			#m**3/sec
Q = Q*1000;			#litres/sec

# Results
print "Discharge through the pipe(litres/sec) : %.1f"%Q
Discharge through the pipe(litres/sec) : 28.9

Example 7.20 Page No : 255

In [20]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tant
Cv = 0.97;			#coeffiecient of velocity
Cc = 0.95;			#coeffiecient
Dn = 50./1000;			#meter(Nozzle diameter)
D = 100./1000;			#meter(Pipe diameter)
p = 6.867;			#N/cm**2(Pressure at the base of nozzle)

# Calculations and Results
Hb = p*10**4/(g*1000)			#meter(Head at the base of nozzle)
v = Cv*math.sqrt(2*g*Hb);			#m/s(velocty of jet)
print "Velocity in the jet(m/s) : %.2f"%v
A = math.pi/4*Dn**2;			#m**2(Cross sction of jet)
Q = Cc*A*v;			#m**3/sec(Discharge)
Q = Q*1000;			#litres/sec
print "Rate of discharge(litres/second) : %.2f"%Q
E = g*1000*Q/1000*Hb/1000;			#kW(Energy transmitted)
print "Energy per second n the jet(kW) : %.2f"%E

#Answer in the book is not accurate.
Velocity in the jet(m/s) : 11.37
Rate of discharge(litres/second) : 21.20
Energy per second n the jet(kW) : 1.46

Example 7.21 Page No : 258

In [22]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tant
D = 100./1000;			#meter(Pipe diameter)
L = 700.;			#meter(Total length)
Lin = 300.;			#meter(inlet length)
hf = 10.;			#meter(Available head)
h = 1.4;			#meter(height)
f = 0.02;			#coefficient of friction

# Calculations and Results
v = math.sqrt(hf*2*g*D/4/f/L);			#m/s
Q = math.pi*D**2/4*v*1000;			#litres/sec
print "Discharge in pipe(litres/second) : %.2f"%Q

#Applying Brnaullis theorem
p1 = 0
v1 = 0
Z1 = 0;			#(Neglecting minor losses)
v2 = v;			#m/s
Z2 = h;			#meter
hf = 4*f*Lin*v**2/(2*g*D);			#meter
p2BYw = -v2**2/2/g-Z2-hf;			#meter of water
hatm = 10.3;			#meter(Atmospheric pressure head)
habs = p2BYw+hatm;			#meter(Absolute pressure head)
print "Pressure at the summit of siphon(meter) : %.3f"%habs
Discharge in pipe(litres/second) : 4.65
Pressure at the summit of siphon(meter) : 4.596

Example 7.22 Page No : 263

In [24]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tant
D = 150./1000;			#meter(Pipe diameter)
Q = 40.;			#litres/sec(rate of discharge)
l = 500.;			#meter(valve dismath.tance)
T = 0.5;			#second

# Calculations
v = Q/1000/(math.pi/4*D**2);			#m/s(velocity of flow)
pi = 1000/g*(l*v/T);			#kg/m**2

# Results
print "Increase in pressure intensity(kg/m**2) : %.3e"%pi
Increase in pressure intensity(kg/m**2) : 2.307e+05

Example 7.23 Page No : 266

In [25]:
import math 
			
# Variables :
g = 9.81;			#gravity consmath.tant
l = 10000.;			#meter(length of pipe line)
D = 0.2;			#meter(Diameter of pipe)
p = 60.*10**5;			#N/m**2
f = 0.007;			#coefficient of friction
w = g*1000.;			#N/m**3

# Calculations
H = p/w;			#meter
hf = H/3;			#meter(friction head loss is 1/3rd)
v = math.sqrt(hf*2*g*D/4/f/l);			#m/s
P = w*math.pi*D**2/4*v*(H-hf)/1000;			#kW

# Results
print "Maximum power(kW) : %.3f"%P
Maximum power(kW) : 212.410