# Chapter 2 : Fluid statics¶

### example 2.1 page no : 40¶

In [1]:
# variables
g=32.2;                     #ft/s^2
rho_water=62.3;             #lbm/ft^3

# calculation
#specific weoight=(density)*(acceleration due to gravity)
specific_wt=rho_water*g;    #lbm.ft/ft^3.s^2

#1 lbf=32.2 lbm.ft/s^2
specific_wt=specific_wt/32.2;            #lbf/ft^3

# result
print "Specific weight of water is" ,specific_wt , "lbf/ft^3"

Specific weight of water is 62.3 lbf/ft^3


### example 2.2 page no : 40¶

In [2]:
# variables
d=304.9;                       #m
rho_water=1024.;               #Kg/m^3
g=9.81;                        #m/s^2
p_atm=101.3;                   #KPa

# calculation
#gauge pressure=(desity)*(acc. due to gravity)*(depth)
p_depth=p_atm+rho_water*g*d/1000.0;            #KPa

# result
print "pressure at the depth is" , (p_depth) , "KPa"

pressure at the depth is 3164.154656 KPa


### example 2.3 page no : 41¶

In [3]:
# variables
rho_oil=55.;                        #lbm/ft^3
g=32.2;                             #ft/s^2
d=60.;                              #ft (depth of oil cylinder)

# calculation and result
gauge_pressure=rho_oil*g*d/32.2;    #lbf/ft^2
print "Gauge pressure is",
print gauge_pressure,
print "lbf/ft^2"

#1 ft=12 in
gauge_pressure=gauge_pressure/144.0;        #lbf/in^2
print "Gauge pressure is",
print gauge_pressure,
print "lbf/in^2"

Gauge pressure is 3300.0 lbf/ft^2
Gauge pressure is 22.9166666667 lbf/in^2


### example 2.4 page no : 42¶

In [4]:
import math

# varirbles
#calc of density of air at a certain height
p_atm=14.7;                          #psia
T=289.;                              #K

#P2=P1*exp^(-(acc. due to gravity)*(mass of air)*(height)/(universal gas const.)/(temp.))
g=9.81;                              #m/s^2
R=8314;                              #N.m^2/Kmol/K

#for height of 1000 ft=304.8m
h=304.8;                             #m
p_1000=14.7*math.exp(-g*29*h/R/289);
print "pressure at 1000ft is",
print p_1000,
print "psia"

#for height of 10000 ft=3048m
h=3048.;                            #m
p_10000=p_atm*math.exp(-g*29.*h/R/289.);
print "pressure at 10000ft is",
print p_10000,
print "psia"

#for height of 100000 ft=30480m
h=30480.;                           #m
p_100000=14.7*math.exp(-g*29.*h/R/289.);
print "pressure at 100000ft is",
print p_100000,
print "psia",

pressure at 1000ft is 14.1789512072 psia
pressure at 10000ft is 10.2467246829 psia
pressure at 100000ft is 0.398102276652 psia


### example 2.5 page no : 42¶

In [5]:
# variables
p_atm=14.7;                        #psia
g=9.81;                            #m/s^2

#P2=P1*[1-(acc. due to gravity)*(mass of air)*(height)/(univ. gas const.)/(temp.)]
T=289.;                            #K
R=8314.                            #N.m^2/Kmol/K

# calculation and result
#for height of 1000ft=304.8m
h=304.8                            #m
p_1000=p_atm*(1-g*29*h/R/T)
print "pressure at 1000ft is",
print p_1000,
print "psia"

#for height of 10000ft=3048m
h=3048.                            #m
p_10000=p_atm*(1-g*29*h/R/T)
print "pressure at 10000ft is",
print p_10000,
print "psia"

#for height of 100000ft=30480m
h=30480.                           #m
p_100000=p_atm*(1-g*29*h/R/T)
print "pressure at 100000ft is",
print p_100000,
print "psia"

#NOTE that the pressure comes out to be negative at 100000ft justifying that density of air changes with altitude

pressure at 1000ft is 14.1694926079 psia
pressure at 10000ft is 9.39492607874 psia
pressure at 100000ft is -38.3507392126 psia


### example 2.6 page no : 45¶

In [6]:
import math

# variables
#calc atm pressure on a storage tank roof
p_atm=14.7;                    #psia

#diameter of roof is 120ft
d_roof=120.;                   #ft

# calculation
#force=(pressure)*(area)
f_roof=p_atm*(math.pi)*d_roof**2/4.*144;            #lbf ;144 because 1ft=12inch

# result
print "Force exerted by atmosphere on the roof is",
print f_roof,
print "lbf"

Force exerted by atmosphere on the roof is 23940443.9848 lbf


### example 2.7 page no : 45¶

In [7]:
import math

# variables
#calc atm pressure on a storage tank roof
p_atm=14.7;                             #psia

#diameter of roof is 120ft
d_roof=120.;                            #ft
#force=(atm. pressure + gauge pressure)*(area)
#gauge pressure=(desity)*(acc. due to gravity)*(depth)
rho_water=62.3                          #lbm/ft^3
g=32.2;                                 #ft/s^2

# calculation
#depth of water on roof=8 inch=o.667 ft
h=0.667;                                #ft
gauge_pressure=rho_water*g*h/32.2*(math.pi)*d_roof**2/4.;                 #lbf

# result
print gauge_pressure

469965.799032


### example 2.8 page no : 46¶

In [8]:
# variables
#lock gate has water on one side and air on the other at atm. pressure
w=20.;                       #m (width of the lock gate)
h=10.;                       #m (height of the lock gate)
p_atm=1.;                    #atm
rho_water=1000.;             #Kg/m^3
g=9.81                       #m/s^2

# calculation
#for a small strip of dx height at the depth of x on the lock gate
#net pressure on strip = (p_atm+(rho_water)*g*x) - p_atm
#thus, net pressure on strip = (rho_water)*g*x
#force on strip = (rho_water*g*x)*w.dx = (rho_water)*g*w*(x.dx)
#force on lock gate = integration of force on strip fromm h=0 to h=10
#integration(x.dx) = x^2/2
#for h=0 to h=10; integration (x.dx) = h^2/2
force_lockgate=(rho_water)*g*w*h**2/2;

# result
print "The net force on the lock gate is",force_lockgate/10**6,"MN"

The net force on the lock gate is 9.81 MN


### example 2.9 page no : 49¶

In [9]:
sigma_tensile=20000.                        #lbf/in^2 (tensile stress is normally 1/4 rupture stress)

#max pressure is observed at the bottom of the storage
p_max=22.9;                                 #lbf/in^2

#diameter of storaeg tank = 120ft =1440in
d=1440.;                                    #in

# calculation
t=(p_max)*d/sigma_tensile/2;                #in

# result
print "Thichness of the storage tank is",
print t,
print "in"

Thichness of the storage tank is 0.8244 in


### example 2.10 page no : 50¶

In [10]:
# variables
p_working=250.0;                          #lbf/in^2

#diameter of the cylinder = 10ft = 120in
d=120.0;                                   #in
sigma_tensile=20000.;                      #lbf/in^2

# calculation
t=p_working*d/sigma_tensile/2;             #in

# result
print "Thichness of the storage tank is",
print t,
print "in"

Thichness of the storage tank is 0.75 in


### example 2.11 page no : 53¶

In [11]:
import math

# variables
p_atm=1.;                      #atm
T=293.;                        #K
d=3.;                          #m (diameter of the balloon)

# calculation
#buoyant force=(density of air)*g*(volume of balloon)
#weight of balloon = (density of helium)*g*(volume of balloon)
#density for gases = PM/RT
#payload of balloon = buoyant force - weight
V_balloon=(math.pi)*d**3/6.;      #m^3
R=8.2*10**(-2);                   #m^3.atm/mol/K
M_air=29.;                        #Kg/Kmol
M_he=4.;                          #Kg/Kmol
g=9.81;                           #m/s^2

# result
print "Payload of the balloon is",
print "N"

Payload of the balloon is 144.307841185 N


### example 2.12 page no : 54¶

In [12]:
# variables
#calc fraction of block in water
SG_wood=0.96;                  #Specific gravity
SG_gasoline=0.72;

# calculation
#Let r be the ratio - V_water/V_wood
r=(SG_wood-SG_gasoline)/(1-SG_gasoline);

# result
print "Fraction of wood in water",
print r

Fraction of wood in water 0.857142857143


### example 2.13 page no : 54¶

In [13]:
# variables
#height of water above pt.C = 2.5ft
rho_water=62.3;                 #lbm/ft^3;
h1=2.5;                         #ft
rho_gas=0.1;                    #lbm/ft^3
h2=0.5;                         #ft (height of gas)
g=32.2;                         #ft/s^2

# calculation
gauge_pressure=((rho_water)*g*h1+(rho_gas)*g*h2)/144/32.2          #lbf/in^2

# result
print "Gauge pressure is",
print gauge_pressure,
print "lbf/in^2"

Gauge pressure is 1.08194444444 lbf/in^2


### example 2.14 page no : 56¶

In [14]:
rho_water=62.3;                       #lbm/ft^3
SG_oil=1.1;
rho_oil=SG_oil*(rho_water);
g=32.2;                               #ft/s^2
h1_1=1.;                              #ft
h1_2=2.;                              #ft
h2_1=2.;                              #ft
h2_2=1.;                              #ft

# calculation
p_diff=((rho_water)*g*(h1_1-h1_2)+(rho_oil)*g*(h2_1-h2_2))/32.2/144.0;        #lbf/in^2

# result
print "The pressure difference is",
print p_diff,
print "lbf/in^2"

The pressure difference is 0.0432638888889 lbf/in^2


### example 2.15 page no : 57¶

In [15]:
# variables
k=10000.;                      #N/m (spring constant)
x=0.025;                       #m (displacement in spring)
A=0.01;                        #m^2 (area of piston)

# calculation
gauge_pressure=k*x/A/1000.;    #KPa

# result
print "The gauge pressure is",
print gauge_pressure,
print "KPa"

The gauge pressure is 25.0 KPa


### example 2.16 page no : 60¶

In [16]:
# variables
g=32.2;                          #ft/s^2
h=20.;                           #ft (height of fireplace)
rho_air=0.075;                   #lbm/ft^3
T_air=293.0;                     #K (surrounding temperature)
T_fluegas=422.0;                 #K

# calculation
p_diff=g*h*(rho_air)*(1-(T_air/T_fluegas))/32.2/144;             #lbf/in^2

# result
print "The pressure difference is",
print p_diff,
print "lbf/in^2",

The pressure difference is 0.00318424170616 lbf/in^2


### example 2.17 page no : 64¶

In [17]:
# variables
rho_water=1000.                       #Kg/m^3
g=9.81;                               #m/s^2
h=5.;                                 #m (depth of water)

# calculation and result
#for elevator not accelerated
p_gauge=(rho_water)*g*h/1000.0;       #KPa
print "THe gauge pressure is",
print p_gauge,
print "KPa"

#for elevator accelerated at 5m/s^2 in upward direction
a=5.;                                 #m/s^2
p_gauge=(rho_water)*(g+a)*h/1000.0;   #KPa
print "THe gauge pressure is",
print p_gauge,
print "KPa"

#for elevator accelerated at 5m/s^2 in downward direction
a=5.;                                 #m/s^2
p_gauge=(rho_water)*(g-a)*h/1000.0;   #KPa
print "THe gauge pressure is",
print p_gauge,
print "KPa"

THe gauge pressure is 49.05 KPa
THe gauge pressure is 74.05 KPa
THe gauge pressure is 24.05 KPa


### example 2.18 page no : 65¶

In [18]:
import math

# variables
#angle free surface makes with the horizontal in an accelerated body
a=1.;                             #ft/s^2
g=32.2;                           #ft/s^2

# calculation
theta=theta*180./math.pi;         #degrees

# result
print "The angle made by free surface with the horizontal is",
print theta,
print "degrees"

The angle made by free surface with the horizontal is 1.77880031567 degrees


### example 2.19 page no : 66¶

In [19]:
import math
# variables
f=78/60.0;                      #rps
r=0.15;                         #m
g=9.81;                         #m/s^2

# calculation
#omega=2*(%pi)*f
z=((2*(math.pi)*f)**2)*r**2/2/g;             #m

# result
print "The liquid in the cylinder rises to a height of",
print z,
print "m"

The liquid in the cylinder rises to a height of 0.0765120708158 m


### example 2.20 page no : 67¶

In [20]:
import math

# variables
#Let difference between heights at bottom and top be d
d=20.;                        #in
r_a=14.;                      #in
f=1000/60.;                   #rps
g=32.2;                       #ft/s^2

# calculation
r_b=((r_a)**2-2*(d)*g*12/(2*(math.pi)*f)**2)**0.5;              #in

# result
print "The thickness of water strip at bottom of industrial centrifuge",
print r_b,
print "in"

The thickness of water strip at bottom of industrial centrifuge 13.9495728181 in

In [ ]: