Chapter 1 : Fundamentals¶

Example 1.1 Page No : 8¶

In :
# variables
T = 80.;		#temperature of chlorine gas in degree F
p = 100.;		#pressure in psia
W = 2*35.45;		#molecular weight of chlorine

# calculations
R = 1545/W;		#specific gas constant in ft-lb/lb-degreeR
gam = p*(144/R)*(1/(460+T));		#specific weight of chlorine in lb/cuft
Spec_vol = 1/gam;		#specific volume in cuft/lb
rho = gam/32.2;		#density of chlorine in slug/cuft

# results
print 'Specific weight = %.3f lb/cuft \nSpecific volume = %.3f cuft/lb \ndensity = %.4f slug/cuft'%(gam,Spec_vol,rho);
Specific weight = 1.224 lb/cuft
Specific volume = 0.817 cuft/lb
density = 0.0380 slug/cuft

Example 1.2 Page No : 12¶

In :
import math

# variables
gamma = 1.4;
T1 = 60.;		#temperature of air in degree F
p1 = 14.7;		#pressure in psia
k = 0.5;		#(final volume/initial volume) = k
R = 53.3;		#Engineering gas constant

# calculations
gam1 = p1*(144/R)*(1/(460+T1));		#lb/cuft
gam2 = gam1/k;		#lb/cuft
p2 = (p1/(gam1**(gamma)))*(gam2**(gamma));		# in psia
T2 = p2*(144/R)*(1/gam2);		#in degree F
a1 = math.sqrt(gamma*32.2*R*(460+T1));		# in fps
a2 = math.sqrt(gamma*32.2*R*(T2));		# in fps

# results
print 'Final pressure = %.1f psia \
\nFinal temperature = %d degreeR  \
\nSonic velocity before compression = %d fps \
\nSonic velocity after compression = %.f fps'%(p2,T2,a1,a2);

#the answers differ due to rounding-off errors
0.152749314475
Final pressure = 38.8 psia
Final temperature = 686 degreeR
Sonic velocity before compression = 1117 fps
Sonic velocity after compression = 1284 fps

Example 1.3 Page No : 17¶

In :
import math

# variables
r1 = 0.25;		# radius of cylinder in feet
l = 2.;	    	#length of cylnider in feet
r2 = 0.30;		# radius of co-axial cylinder in feet
mu = 0.018;		#lb-sec/ft**2
torque = 0.25;		# in ft-lb

# calculations
def f4(r):
return -torque/(4*math.pi*mu*r**2)

rpm1 = V1*60/(2*math.pi*r1);
V2 = torque*(r2-r1)/(4*math.pi*mu*r1**2);		#in fps
rpm2 = V2*60/(2*math.pi*r1);
hp = 2*math.pi*r1*(rpm1/(550*60));

# results
print 'Velocity gradient at the inner cylinder wall is %.1f fps/ft and at the outer cylinder wall is %.1f fps/ft'%(dv_dy1,dv_dy2);
print 'rpm = %.1f  and approximate rpm = %.1f,  hp = %.5f '%(rpm1,rpm2,hp);
Velocity gradient at the inner cylinder wall is 17.7 fps/ft and at the outer cylinder wall is 12.3 fps/ft
rpm = 28.1  and approximate rpm = 33.8,  hp = 0.00134

Example 1.4 Page No : 20¶

In :
# variables
T = 70.     		#degreeF
del_p = 0.1;		# in psi
sigma = 0.00498;		# lb/ft

# calculations
R = (sigma*2)/(del_p*144);		#in ft
d = 12*2*R;		# in inches

# results
print 'Diameter of the droplet of water = %.4f in'%(d);
Diameter of the droplet of water = 0.0166 in

Example 1.5 Page No : 20¶

In :
import math

# variables
l = 12.;		# length of the cylinder
T = 150.;		#temperature of water in degreeF
p1 = 14.52;		#atmospheric pressure in psia
p2 = 3.72;		#the pressure on the inside of the piston in psia

# calculations
F = 0.25*(p1-p2)*math.pi*l**2;		#Force on the piston in lb

# results
print 'Minimum force on the piston to be applied is, F = %d lb'%(F);