In [2]:

```
print "Principles of Heat Transfer, 7th Ed. Frank Kreith et. al Chapter - 4 Example # 4.1 "
# Temperature of air in C is given as:
Tinfinity = 20;
# Temperature of surface in C is given as:
Ts = 100;
# Therefore avaerage temperature in degree C would be:
Ta = (Ts+Tinfinity)/2;
# From fig. 4.2 on page 232, it can be easily seen that (deltaT/deltaY) at
# y=0 is -66.7 K/mm
# From Table 28 in Appendix 2, at average temperature of air, thermal
# conductivity in W/m-K is
k = 0.028;
#Therefore from eq. 4.1
print "The heat transfer coefficient is given by, as per Eq. 4.1, in W/m2K"
# 1000 is added to convert from mm to m
#heat transfer coefficient in W/m2K
hc = ((-k*(-66.7))/(Ts-Tinfinity))*1000
print round(hc,1)
```

In [3]:

```
print "Principles of Heat Transfer, 7th Ed. Frank Kreith et. al Chapter - 4 Example # 4.3 "
# Width of the collector plate in ft is given:
b = 1.0;
# Surface temperature in F is given:
Ts = 140.0;
# Air temperature in F is given:
Tinfinity = 60.0;
# Air velocity in ft/sec is given as:
Uinfinity = 10.0;
# Average temperature in degree F is given as:
T = (Ts+Tinfinity)/2;
# Properties of air at average temperature are as follows
Pr = 0.72; #Prandtl number
k = 0.0154; # Thermal conductivity in Btu/h ft °F
mu = 1.285*10-5; #Viscosity in lbm/ft s
cp = 0.24; #Specific heat in Btu/lbm °F
rho = 0.071; #Density in lbm/ft3
# Reynold''s number at x=1ft is
Re1 = ((Uinfinity*rho)*1)/mu;
# Reynold''s number at x=9ft is
Re9 = ((Uinfinity*rho)*1)/mu;
# Assuming that the critical Reynolds number is 5*10**5, the critical distance is
#Critical Reynolds number
Rec = 5.0*(10**5);
#Critical distance in ft
xc = (Rec*mu)/(Uinfinity*rho);
# From Eq. 4.28, and using the data obtained, we get for part a:
print "Delta at x=1ft to be 0.0213ft and at x=9ft to be 0.0638ft"
# From Eq. 4.30, and using the data obtained, we get for part b:
print "Cfx at x=1ft to be 0.00283 and at x=9ft to be 0.000942"
# From Eq. 4.31, and using the data obtained, we get for part c:
print "Cfbar at x=1ft to be 0.00566 and at x=9ft to be 0.00189"
# From Eq. 4.29, and using the data obtained, we get for part d:
print "Tau at x=1ft to be 3.12*10**-4 lb/ft**2 and at x=9ft to be 1.04*10**-4 lb/ft**2"
# From Eq. 4.32, and using the data obtained, we get for part e:
print "DeltaTH at x=1ft to be 0.0237ft and at x=9ft to be 0.0712ft"
# From Eq. 4.36, and using the data obtained, we get for part f:
print "hcx at x=1ft to be 1.08Btu/hft**2°F and at x=9ft to be 0.359Btu/hft**2°F"
# From Eq. 4.39, and using the data obtained, we get for part g:
print "hcbar at x=1ft to be 2.18Btu/hft**2°F and at x=9ft to be 0.718Btu/hft**2°F"
# From Eq. 4.35, and using the data obtained, we get for part h:
print "q at x=1ft to be 172 Btu/h and at x=9ft to be 517 Btu/h"
```

In [10]:

```
print "Principles of Heat Transfer, 7th Ed. Frank Kreith et. al Chapter - 4 Example # 4.4 "
# Length of the crankcase in m is given as
L = 0.6;
# Width of the crankcase in m is given as
b = 0.2;
# Depth of the crankcase in m is given as
d = 0.1;
# Surface temperature in K is given as
Ts = 350.0;
# Air temperature in K is given as
Tinfinity = 276.0;
# Air velocity in m/sec is given as
Uinfinity = 30.0;
# It is stated that boundary layer is turbulent over the entire surface
#Average air temperature in degree K is
T = (Ts+Tinfinity)/2;
# At this average temperature, we get the following for air
rho = 1.092;#density in kg/m**3
mu = 0.000019123;#vismath.cosity in SI units
Pr = 0.71;#Prandtl number
k = 0.0265;#Thermal conductivity in W/m-K
# Reynold''s number is therefore given as
ReL = ((rho*Uinfinity)*L)/mu;
#From eq. 4.82, average nusselt number could be given as
Nu = (0.036*(Pr**(1/3.0)))*(ReL**0.8);
#We can write from the basic math.expression, Nu=hc*L/k, that
#Heat transfer coefficient in W/m**2-K
hc = (Nu*k)/L;
# The surface area that dissipates heat is 0.28 m2
print "Total heat loss from the surface in W is therefore"
#Heat loss from the surface in W
q = (hc*0.28)*(Ts-Tinfinity)
print round(q)
```