print"\t example 11.1 \t"
print"\t approximate values are mentioned in the book \t"
T1=340.; # inlet hot fluid,F
T2=240.; # outlet hot fluid,F
t1=200.; # inlet cold fluid,F
t2=230.; # outlet cold fluid,F
W=29800; # lb/hr
w=103000; # lb/hr
from math import log10
print"\t 1.for heat balance \t"
print"\t for straw oil \t"
c=0.58; # Btu/(lb)*(F)
Q=((W)*(c)*(T1-T2)); # Btu/hr
print"\t total heat required for straw oil is : Btu/hr \t",Q
print"\t for naphtha \t"
c=0.56; # Btu/(lb)*(F)
Q=((w)*(c)*(t2-t1)); # Btu/hr
print"\t total heat required for naphtha is : Btu/hr \t",Q
delt1=T2-t1; #F
delt1=40.;
delt2=T1-t2; # F
delt2=110.
print"\t delt1 is : F \t",delt1
print"\t delt2 is : F \t",delt2
LMTD=((delt2-delt1)/((2.3)*(log10(delt2/delt1))));
print"\t LMTD is F \t",LMTD
R=((T1-T2)/(t2-t1));
print"\t R is : \t",R
S=((t2-t1)/(T1-t1));
print"\t S is : \t",S
print"\t FT is 0.885 \t" # from fig 18
delt=(0.885*LMTD); # F
print"\t delt is : F \t",delt
X=((delt1)/(delt2));
print"\t ratio of two local temperature difference is : \t",X
L=16;
Fc=0.405; # from fig.17
Kc=0.23; # crude oil controlling
Tc=((T2)+((Fc)*(T1-T2))); # caloric temperature of hot fluid,F
print"\t caloric temperature of hot fluid is : F \t",Tc
tc=((t1)+((Fc)*(t2-t1))); # caloric temperature of cold fluid,F
print"\t caloric temperature of cold fluid is : F \t",tc
UD1=70; # assume, from table 8a
A1=((Q)/((UD1)*(delt)));
print"\t A1 is : ft**2 \t",A1
a1=0.1963; # ft**2/lin ft
N1=(A1/(16*a1));
print"\t number of tubes are :\t",N1
N2=124; # assuming two tube passes, from table 9
A2=(N2*L*a1); # ft**2
print"\t total surface area is : ft**2 \t",A2
UD=((Q)/((A2)*(delt)));
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD
print"\t hot fluid:shell side,straw oil \t"
ID=15.25; # in
C=0.25; # clearance
B=3.5; # minimum baffle spacing,from eq 11.4,in
PT=1;
As=((ID*C*B)/(144*PT)); # flow area,from eq 7.1,ft**2
print"\t flow area is : ft**2 \t",As
Gs=(W/As); # mass velocity,from eq 7.2,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gs
mu1=3.63; # at 280.5F,lb/(ft)*(hr), from fig.14
De=0.95/12; # from fig.28,ft
Res=((De)*(Gs)/mu1); # reynolds number
print"\t reynolds number is : \t",Res
jH=46; # from fig.28
Z=0.224; # Z=(K*(c*mu3/k)**(1/3)),Btu/(hr)(ft**2)(F/ft), at mu3=1.5cp and 35 API
Ho=((jH)*(1/De)*(Z)); # H0=(h0/phya),using eq.6.15,Btu/(hr)*(ft**2)*(F)
print"\t individual heat transfer coefficient is : Btu/(hr)*(ft**2)*(F) \t",Ho
phys=1;
ho=(Ho)*(phys); # from eq.6.36
print"\t Correct h0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",ho
print"\t cold fluid:inner tube side,naphtha \t"
Nt=124;
n=2; # number of passes
L=16; #ft
at1=0.302; # flow area, in**2
at=((Nt*at1)/(144*n)); # total area,ft**2,from eq.7.48
print"\t flow area is : ft**2 \t",at
Gt=(w/(at)); # mass velocity,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gt
mu2=1.31; # at 212F,lb/(ft)*(hr)
D=0.0517; # ft
Ret=((D)*(Gt)/mu2); # reynolds number
print"\t reynolds number is : \t",Ret
jH=102; # from fig.24
Z=0.167; # Z=(K*(c*mu3/k)**(1/3)),Btu/(hr)(ft**2)(F/ft), at mu4=0.54cp and 48 API
Hi=((jH)*(1/D)*(Z)); #Hi=(hi/phyp),using eq.6.15a,Btu/(hr)*(ft**2)*(F)
print"\t Hi is : Btu/(hr)*(ft**2)*(F) \t",Hi
ID=0.62; # ft
OD=0.75; #ft
Hio=((Hi)*(ID/OD)); #Hio=(hio/phyp), using eq.6.5
print"\t Correct Hi0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",Hio
phyt=1;
hio=(Hio)*(phyt); # from eq.6.37
print"\t Correct hi0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",hio
print"\t pressure drop for annulus \t"
f=0.00225; # friction factor for reynolds number 7000, using fig.29
s=0.76; # for reynolds number 7000,using fig.6
Ds=15.25/12; # ft
N=(12*L/B); # number of crosses,using eq.7.43
print"\t number of crosses are : \t",N
delPs=((f*(Gs**2)*(Ds)*(N))/(5.22*(10**10)*(De)*(s)*(phys))); # using eq.7.44,psi
print"\t delPs is : psi \t",delPs
print"\t pressure drop for inner pipe \t"
f=0.0002; # friction factor for reynolds number 31300, using fig.26
s=0.72;
delPt=((f*(Gt**2)*(L)*(n))/(5.22*(10**10)*(D)*(s)*(phyt))); # using eq.7.45,psi
print"\t delPt is : psi \t",delPt
Uc=((hio)*(ho)/(hio+ho)); # clean overall coefficient,Btu/(hr)*(ft**2)*(F)
print"\t clean overall coefficient is : %.1f Btu/(hr)*(ft**2)*(F) \t",Uc
Rd=((Uc-UD)/((UD)*(Uc))); # (hr)*(ft**2)*(F)/Btu
print"\t actual Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd
print"\t The first trial is disqualified because of failure to meet the required dirt factor \t"
print"\t Proceeding as above and carrying the viscosity correction and pressure drops to completion the new summary is given using a 17.25in. ID shell with 166 tubes on two passes and a 3.5in. baffle space \t"
UD1=60; # assumption for 2 tube passes,3.5 baffle spacing and 17.25in ID
UC1=74.8;
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UC1
UD2=54.2;
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD2
Rd1=0.005;
print"\t actual Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd1
delPs1=4.7;
print"\t delPs is : psi \t",delPs1
delPt1=2.1;
print"\t delPt is : psi \t",delPt1
#end
print"\t example 11.2 \t"
print"\t approximate values are mentioned in the book \t"
T1=350.; # inlet hot fluid,F
T2=160.; # outlet hot fluid,F
t1=100.; # inlet cold fluid,F
t2=295.; # outlet cold fluid,F
W=84438; # lb/hr
w=86357; # lb/hr
from math import log10
print"\t 1.for heat balance \t"
print"\t for lean oil \t"
c=0.56; # Btu/(lb)*(F)
Qh=((W)*(c)*(T1-T2)); # Btu/hr
print"\t total heat required for lean oil is : Btu/hr \t",Qh
print"\t for rich oil \t"
c=0.53; # Btu/(lb)*(F)
Qc=((w)*(c)*(t2-t1)); # Btu/hr
print"\t total heat required for rich oil is : Btu/hr \t",Qc
Q=(Qh+Qc)/(2);
print"\t Q is : V \t",Q
delt1=T2-t1; #F
delt2=T1-t2; # F
print"\t delt1 is : F \t",delt1
print"\t delt2 is : F \t",delt2
LMTD=((delt2-delt1)/((2.3)*(log10(delt2/delt1))));
print"\t LMTD is : F \t",LMTD
R=((T1-T2)/(t2-t1));
print"\t R is : \t",R
S=((t2-t1)/(T1-t1));
print"\t S is : \t",S
print"\t FT is 0.875 \t"# for 4-8 exchanger,from fig 21
delt=(0.875*LMTD); # F
print"\t delt is : F \t",delt
X=((delt1)/(delt2));
print"\t ratio of two local temperature difference is : \t",X
Fc=0.48; # from fig.17
Kc=0.32; # crude oil controlling
Tc=((T2)+((Fc)*(T1-T2))); # caloric temperature of hot fluid,F
print"\t caloric temperature of hot fluid is : F \t",Tc
tc=((t1)+((Fc)*(t2-t1))); # caloric temperature of cold fluid,F
print"\t caloric temperature of cold fluid is : \t",tc
UD1=50; # assume, from table 8a
A1=((Q)/((UD1)*(delt)));
print"\t A1 is : ft**2 \t",A1
a1=0.1963; # ft**2/lin ft
N1=(A1/(16*a1*2)); # 2-4 exchanger in series
print"\t number of tubes are : \t",N1
N2=580; # assuming six tube passes,31in ID, from table 9
A2=(N2*16*a1*2); # ft**2
print"\t total surface area is : ft**2 \t",A2
UD=((Q)/((A2)*(delt)));
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD
print"\t hot fluid:inner tube side,lean oil \t"
Nt=580;
n=6; # number of passes
L=16; #ft
at1=0.302; # flow area, in**2
at=((Nt*at1)/(144*n)); # total area,ft**2,from eq.7.48
print"\t flow area is : ft**2 \t",at
Gt=(W/(at)); # mass velocity,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gt
mu2=2.13; # at 212F,lb/(ft)*(hr)
D=0.0517; # ft
Ret=((D)*(Gt)/mu2); # reynolds number
print"\t reynolds number is : \t",Ret
jH=36.5; # from fig.24
Z=0.185; # Z=(K*(c*mu3/k)**(1/3)),Btu/(hr)(ft**2)(F/ft), at mu4=0.88cp and 35 API
Hi=((jH)*(1/D)*(Z)); #Hi=(hi/phyp),using eq.6.15a,Btu/(hr)*(ft**2)*(F)
print"\t Hi is : Btu/(hr)*(ft**2)*(F) \t",Hi
ID=0.62; # ft
OD=0.75; #ft
Hio=((Hi)*(ID/OD)); #Hio=(hio/phyp), using eq.6.5
print"\t Correct Hi0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",Hio
phyt=1;
hio=(Hio)*(phyt); # from eq.6.37
print"\t Correct hi0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",hio
print"\t cold fluid:shell side,rich oil \t"
ID=31; # in
C=0.25; # clearance
B=12; # minimum baffle spacing,from eq 11.4,in
PT=1;
As=((ID*C*B)/(144*PT))/(2); # flow area,from eq 7.1,ft**2
print"\t flow area is : ft**2 \t",As
Gs=(w/As); # mass velocity,from eq 7.2,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gs
mu1=3.15; # at 193.5F,lb/(ft)*(hr), from fig.14
De=0.95/12; # from fig.28,ft
Res=((De)*(Gs)/mu1); # reynolds number
print"\t reynolds number is : \t",Res
jH=45; # from fig.28
Z=0.213; # Z=(K*(c*mu3/k)**(1/3)),Btu/(hr)(ft**2)(F/ft), at mu3=1.3cp and 35 API
Ho=((jH)*(1/De)*(Z)); # H0=(h0/phya),using eq.6.15,Btu/(hr)*(ft**2)*(F)
print"\t individual heat transfer coefficient is : Btu/(hr)*(ft**2)*(F) \t",Ho
phys=1;
ho=(Ho)*(phys); # from eq.6.36
print"\t Correct h0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",ho
print"\t pressure drop for inner pipe \t"
f=0.00027; # friction factor for reynolds number 10100, using fig.26
s=0.77;
delPt=((2*f*(Gt**2)*(L)*(n))/(5.22*(10**10)*(D)*(s)*(phyt))); # using eq.7.45,psi
print"\t delPt is : psi \t",delPt
X1=0.024; # X1=((V**2)/(2*g)), for Gt 1060000,using fig.27
delPr=((4*2*n*X1)/(s)); # using eq.7.46,psi
print"\t delPr is : psi \t",delPr
delPT=delPt+delPr; # using eq.7.47,psi
print"\t delPT is : psi \t",delPT
print"\t allowable delPT is 10 psi \t"
print"\t pressure drop for annulus \t"
f=0.0023; # friction factor for reynolds number 6720, using fig.29
s=0.79; # for reynolds number 6720,using fig.6
Ds=31/12; # ft
De=0.0792;
N=(4*12*L/B); # number of crosses,using eq.7.43
print"\t number of crosses are : \t",N
delPs=((f*(Gs**2)*(Ds)*(N))/(5.22*(10**10)*(De)*(s)*(phys))); # using eq.7.44,psi
print"\t delPs is : psi \t",delPs
print"\t allowable delPa is 10 psi \t"
Uc=((hio)*(ho)/(hio+ho)); # clean overall coefficient,Btu/(hr)*(ft**2)*(F)
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",Uc
Rd=((Uc-UD)/((UD)*(Uc))); # (hr)*(ft**2)*(F)/Btu
print"\t actual Rd is : %.4f (hr)*(ft**2)*(F)/Btu \t",Rd
print"\t The initial assumptions have provided an exchanger which very nearly meets all the requirements. Eight-pass units would meet the heat-transfer requirement but would give a tube-side pressure drop of 14 psi. The trial exchanger will be somewhat less suitable when the value of Q, is also taken into account. If the minimum dirt factor of 0.0040 is to be taken literally, it will be necessary to try the next size shell \t"
print"\t Assume a 33 in. ID shell with six1 tube passes and baffies spaced 12-in. apart, since the pressure drop increases with the diameter of the shell for a given mass velocity. \t"
UC1=52.3;
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UC1
UD2=42;
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD2
Rd1=0.0047;
print"\t calculated Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd1
Rd2=0.004;
print"\t actual Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd2
delPs1=4.4;
print"\t delPs is : psi \t",delPs1
delPT1=7.9;
print"\t delPt is : psi \t",delPT1
#end
print"\t example 11.3 \t"
print"\t approximate values are mentioned in the book \t"
T1=190.; # inlet hot fluid,F
T2=120.; # outlet hot fluid,F
t1=80.; # inlet cold fluid,F
t2=120.; # outlet cold fluid,F
W=100000; # lb/hr
w=154000; # lb/hr
from math import log10
print"\t 1.for heat balance \t"
print"\t for caustic \t"
c=0.88; # Btu/(lb)*(F)
Q=((W)*(c)*(T1-T2)); # Btu/hr
print"\t total heat required for caustic is : Btu/hr \t",Q
print"\t for water \t"
c=1; # Btu/(lb)*(F)
Q=((w)*(c)*(t2-t1)); # Btu/hr
print"\t total heat required for water is : Btu/hr \t",Q
delt1=T2-t1; #F
delt2=T1-t2; # F
print"\t delt1 is : F \t",delt1
print"\t delt2 is : F \t",delt2
LMTD=((delt2-delt1)/((2.3)*(log10(delt2/delt1))));
print"\t LMTD is : F \t",LMTD
R=((T1-T2)/(t2-t1));
print"\t R is : \t",R
S=((t2-t1)/(T1-t1));
print"\t S is : \t",S
print"\t FT is 0.815 \t" # for 4-8 exchanger,from fig 21
delt=(0.815*LMTD); # F
print"\t delt is : F \t",delt
Tc=((T2)+(T1))/(2); # caloric temperature of hot fluid,F
print"\t caloric temperature of hot fluid is : F \t",Tc
tc=((t1)+(t2))/(2); # caloric temperature of cold fluid,F
print"\t caloric temperature of cold fluid is : \t",tc
UD1=250; # assume, from table 8
A1=((Q)/((UD1)*(delt)));
print"\t A1 is : ft**2 \t",A1
a1=0.2618; # ft**2/lin ft
L=16;
N1=(A1/(16*a1));
print"\t number of tubes are : \t",N1
N2=140; # assuming four tube passes,19.25in ID, from table 9
A2=(N2*L*a1); # ft**2
print"\t total surface area is : ft**2 \t",A2
UD=((Q)/((A2)*(delt)));
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD
print"\t hot fluid:shell side,caustic \t"
ID=19.25; # in
C=0.25; # clearance
B=7; # minimum baffle spacing,from eq 11.4,in
PT=1.25;
As=((ID*C*B)/(144*PT)); # flow area,from eq 7.1,ft**2
print"\t flow area is : ft**2 \t",As
Gs=(W/As); # mass velocity,from eq 7.2,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gs
mu1=1.84; # at 155F,lb/(ft)*(hr), from fig.14
De=0.72/12; # from fig.28,ft
Res=((De)*(Gs)/mu1); # reynolds number
print"\t reynolds number is : \t",Res
jH=75; # from fig.28
Z=0.575; # Z=(K*(c*mu3/k)**(1/3)),Btu/(hr)(ft**2)(F/ft)
Ho=((jH)*(1/De)*(Z)); # H0=(h0/phya),using eq.6.15,Btu/(hr)*(ft**2)*(F)
print"\t individual heat transfer coefficient is : Btu/(hr)*(ft**2)*(F) \t",Ho
phys=1; # low viscosity
ho=(Ho)*(phys); # from eq.6.36
print"\t Correct h0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",ho
print"\t cold fluid:inner tube side,water \t"
Nt=140;
n=4; # number of passes
L=16; #ft
at1=0.546; # flow area, in**2
at=((Nt*at1)/(144*n)); # total area,ft**2,from eq.7.48
print"\t flow area is : ft**2 \t",at
Gt=(w/(at)); # mass velocity,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gt
V=Gt/(3600*62.5);
print"\t V is fps \t",V
mu2=1.74; # at 100F,lb/(ft)*(hr)
D=0.0695; # ft
Ret=((D)*(Gt)/mu2); # reynolds number
print"\t reynolds number is : \t",Ret
hi=1240*0.94; # from fig 25
print"\t Hi is : Btu/(hr)*(ft**2)*(F) \t",hi
ID=0.834; # ft
OD=1; #ft
hio=((hi)*(ID/OD)); #Hio=(hio/phyp), using eq.6.5
print"\t Correct hi0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",hio
print"\t pressure drop for annulus \t"
f=0.0019; # friction factor for reynolds number 17400, using fig.29
s=1.115; # for reynolds number 17400,using fig.6
Ds=19.25/12; # ft
De=0.06;
N=(12*L/B)+1; # number of crosses,using eq.7.43
print"\t number of crosses are : %.0f \t",N
delPs=((f*(Gs**2)*(Ds)*(N))/(5.22*(10**10)*(De)*(s)*(phys))); # using eq.7.44,psi
print"\t delPs is : psi \t",delPs
print"\t allowable delPa is 10 psi \t"
print"\t pressure drop for inner pipe \t"
f=0.00018; # friction factor for reynolds number 46300, using fig.26
s=1;
phyt=1;
delPt=((f*(Gt**2)*(L)*(n))/(5.22*(10**10)*(D)*(s)*(phyt))); # using eq.7.45,psi
print"\t delPt is : psi \t",delPt
X1=0.18; # X1=((V**2)/(2*g)), for Gt 1060000,using fig.27
delPr=((4*n*X1)/(s)); # using eq.7.46,psi
print"\t delPr is : psi \t",delPr
delPT=delPt+delPr; # using eq.7.47,psi
print"\t delPT is : psi \t",delPT
print"\t allowable delPa is 10 psi \t"
Uc=((hio)*(ho)/(hio+ho)); # clean overall coefficient,Btu/(hr)*(ft**2)*(F)
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",Uc
Rd=((Uc-UD)/((UD)*(Uc))); # (hr)*(ft**2)*(F)/Btu
print"\t actual Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd
print"\t Adjustment of the baffie space to use the full 10 psi will still not permit the exchanger to make the 0.002 dirt factor. The value of UD has been assumed too high \t"
print"\t Try a 21.25 in ID shell with four tube passes and a 6 in baffie space This corresponds to 170 tubes \t"
UC1=39
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UC1
UD2=200;
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD2
Rd1=0.0024;
print"\t calculated Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd1
Rd2=0.002;
print"\t actual Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd2
delPs1=9.8;
print"\t delPs is : psi \t",delPs1
delPT1=4.9;
print"\t delPt is : psi \t",delPT1
#end
print"\t example 11.4 \t"
print"\t approximate values are mentioned in the book \t"
T1=225.; # inlet hot fluid,F
T2=225.; # outlet hot fluid,F
t1=80.; # inlet cold fluid,F
t2=200.; # outlet cold fluid,F
W=10350; # lb/hr
w=115000; # lb/hr
from math import log10
print"\t 1.for heat balance \t"
print"\t for steam \t"
l=962; # Btu/(lb)
Qh=((W)*(l)); # Btu/hr
print"\t total heat required for steam is : Btu/hr \t",Qh
print"\t for alcohol \t"
c=0.72; # Btu/(lb)*(F)
Qc=((w)*(c)*(t2-t1)); # Btu/hr
print"\t total heat required for alcohol is : Btu/hr \t",Qc
Q=(Qh+Qc)/(2);
print"\t Q is : V \t",Q
delt1=T2-t1; #F
delt2=T1-t2; # F
print"\t delt1 is : F \t",delt1
print"\t delt2 is : F \t",delt2
LMTD=((delt2-delt1)/((2.3)*(log10(delt2/delt1))));
print"\t LMTD is : F \t",LMTD
Tc=((T2)+(T1)); # caloric temperature of hot fluid,F
print"\t caloric temperature of hot fluid is : F \t",Tc
tc=((t1)+(t2)); # caloric temperature of cold fluid,F
print"\t caloric temperature of cold fluid is : \t",tc
L=12;
UD1=200; # assume, from table 8
A1=((Q)/((UD1)*(LMTD)));
print"\t A1 is :f ft**2 \t",A1
a1=0.2618; # ft**2/lin ft
N1=(A1/(12*a1));
print"\t number of tubes are : \t",N1
N2=232; # assuming two tube passes,23.25in ID, from table 9
A2=(N2*L*a1); # ft**2
print"\t total surface area is : ft**2 \t",A2
UD=((Q)/((A2)*(LMTD)));
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD
print"\t hot fluid:inner tube side,steam \t"
Nt=232;
n=2; # number of passes
L=12; #ft
at1=0.546; # flow area, in**2
at=((Nt*at1)/(144*n)); # total area,ft**2,from eq.7.48
print"\t flow area is : ft**2 \t",at
Gt=(W/(at)); # mass velocity,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gt
mu2=0.0314; # at 225F,lb/(ft)*(hr)
D=0.0695; # ft
Ret=((D)*(Gt)/mu2); # reynolds number
print"\t reynolds number is : \t",Ret
hio=1500; # condensation of steam
print"\t Correct hi0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",hio
print"\t cold fluid:shell side,alcohol \t"
ID=23.25; # in
C=0.25; # clearance
B=7; # minimum baffle spacing,from eq 11.4,in
PT=1.25;
As=((ID*C*B)/(144*PT)); # flow area,from eq 7.1,ft**2
print"\t flow area is : ft**2 \t",As
Gs=(w/As); # mass velocity,from eq 7.2,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gs
mu1=1.45; # at 193.5F,lb/(ft)*(hr), from fig.14
De=0.72/12; # from fig.28,ft
Res=((De)*(Gs)/mu1); # reynolds number
print"\t reynolds number is : \t",Res
jH=83; # from fig.28
Z=0.195; # Z=(K*(c*mu3/k)**(1/3)),Btu/(hr)(ft**2)(F/ft)
Ho=((jH)*(1/De)*(Z)); # H0=(h0/phya),using eq.6.15,Btu/(hr)*(ft**2)*(F)
print"\t individual heat transfer coefficient is : Btu/(hr)*(ft**2)*(F) \t",Ho
phys=1;
ho=(Ho)*(phys); # from eq.6.36
print"\t Correct h0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",ho
print"\t pressure drop for inner pipe \t"
f=0.000175; # friction factor for reynolds number 52000, using fig.26
s=0.00076;
delPt=((f*(Gt**2)*(L)*(n))/(5.22*(10**10)*(D)*(s)*(1)))/(2); # using eq.7.45,psi
print"\t delPt is : psi \t",delPt
print"\t delPr is negligible \t"
print"\t allowable delPa is negligible \t"
print"\t pressure drop for annulus \t"
f=0.0018; # friction factor for reynolds number 21000, using fig.29
s=0.78; # for reynolds number 21000,using fig.6
Ds=1.94; # ft
De=0.06;
N=(12*L/B); # number of crosses,using eq.7.43
print"\t number of crosses are : \t",N
delPs=((f*(Gs**2)*(Ds)*(N))/(5.22*(10**10)*(De)*(s)*(phys))); # using eq.7.44,psi
print"\t delPs is : psi \t",delPs
print"\t allowable delPa is 10 psi \t"
Uc=((hio)*(ho)/(hio+ho)); # clean overall coefficient,Btu/(hr)*(ft**2)*(F)
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",Uc
Rd=((Uc-UD)/((UD)*(Uc))); # (hr)*(ft**2)*(F)/Btu
print"\t actual Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd
print"\t This is clearly an instance in which UD was assumed too high.It is now a question of how much too high. With the aid of the summary it is apparent thatin a larger shell a clean overall coefficient of about 200 may be expected \t"
print"\t Assume a 27in. ID shell with 2 tube passes,334 tubes and baffies spaced 7in. apart, since the pressure drop increases with the diameter of the shell for a given mass velocity. \t"
UC1=214;
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UC1
UD2=138.5;
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD2
Rd1=0.0025;
print"\t calculated Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd1
Rd2=0.002;
print"\t actual Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd2
delPs1=0.23;
print"\t delPs is : psi \t",delPs1
delPT1=7.1;
print"\t delPt is : psi \t",delPT1
#end
print"\t example 11.5 \t"
print"\t approximate values are mentioned in the book \t"
T1=250.; # inlet hot fluid,F
T2=125.; # outlet hot fluid,F
t1=80.; # inlet cold fluid,F
t2=100.; # outlet cold fluid,F
W=41300.; # lb/hr
w=64500.; # lb/hr
from math import log10
print"\t 1.for heat balance \t"
print"\t for gas \t"
c=0.25; # Btu/(lb)*(F)
Q=((W)*(c)*(T1-T2)); # Btu/hr
print"\t total heat required for gas is : Btu/hr \t",Q
print"\t for water \t"
c=1; # Btu/(lb)*(F)
Q=((w)*(c)*(t2-t1)); # Btu/hr
print"\t total heat required for water is : Btu/hr \t",Q
delt1=T2-t1; #F
delt2=T1-t2; # F
print"\t delt1 is : F \t",delt1
print"\t delt2 is : F \t",delt2
LMTD=((delt2-delt1)/((2.3)*(log10(delt2/delt1))));
print"\t LMTD is : F \t",LMTD
R=((T1-T2)/(t2-t1));
print"\t R is : \t",R
S=((t2-t1)/(T1-t1));
print"\t S is : \t",S
print"\t FT is 0.935 \t" # from fig 18
delt=(0.935*LMTD); # F
print"\t delt is : F \t",delt
Tc=((T2)+(T1))/(2); # caloric temperature of hot fluid,F
print"\t caloric temperature of hot fluid is : F \t",Tc
tc=((t1)+(t2))/(2); # caloric temperature of cold fluid,F
print"\t caloric temperature of cold fluid is : F \t",tc
UD1=14.8; # assume, from table 8
A1=((Q)/((UD1)*(delt)));
print"\t A1 is : ft**2 \t",A1
a1=0.2618; # ft**2/lin ft
N1=(A1/(12*a1));
print"\t number of tubes are : \t",N1
N2=358; # assuming 12 tube passes, from table 9
L=12;
A2=(N2*L*a1); # ft**2
print"\t total surface area is : ft**2 \t",A2
UD=((Q)/((A2)*(delt)));
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD
print"\t When solved in a manner identical with the preceding examples and using the smallest integral number of bundle crosses (five) corresponding to a 28.8 in spacing \t"
UC1=22.7;
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UC1
UD2=14;
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD2
Rd1=0.027;
print"\t calculated Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd1
Rd1=0.005;
print"\t required Rd is : (hr)*(ft**2)*(F)/Btu \t",Rd1
delPs1=5.2;
print"\t delPs is : psi \t",delPs1
delPt1=1.0;
print"\t delPt is : psi \t",delPt1
print"\t The first trial is disqualified because of failure to meet the required dirt factor and the the pressure drop is five times greater than the allowable \t"
print"\t This would be unsatisfactory, since gases require large inlet connections and the flow distribution on the first and third bundle crosses would be poor and the conditions of allowable pressure drop would still not be met \t"
UD1=15; # assume, from table 8
A1=((Q)/((UD1)*(delt)));
print"\t A1 is : ft**2 \t",A1
a1=0.2618; # ft**2/lin ft
N1=(A1/(12*a1));
print"\t number of tubes are : %. \t",N1
N2=340; # assuming eight tube passes, from table 9
A2=(N2*L*a1); # ft**2
print"\t total surface area is : ft**2 \t",A2
UD=((Q)/((A2)*(delt)));
print"\t correct design overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",UD
print"\t hot fluid:shell side,gas \t"
ID=31; # in
C=0.25; # clearance
B=24; # baffle spacing,in
PT=1.25;
As=((ID*C*B)/(144*PT)); # flow area,from eq 7.1,ft**2
print"\t flow area is : ft**2 \t",As
Gs=(W/As)/(2); # mass velocity,from eq 7.2,lb/(hr)*(ft**2)
print"\t mass velocity is : lb/(hr)*(ft**2) \t",Gs
mu1=0.050; # at 187.5F,lb/(ft)*(hr), from fig.15
De=0.99/12; # from fig.28,ft
Res=((De)*(Gs)/mu1); # reynolds number
print"\t reynolds number is : \t",Res
jH=105; # from fig.28
k=0.015; # Btu/(hr)(ft**2)( degree F/ft)
Z=0.94; # Z=((c*mu3/k)**(1/3)),Btu/(hr)(ft**2)(F/ft)
Ho=((jH)*(k/De)*(Z)); # H0=(h0/phya),using eq.6.15,Btu/(hr)*(ft**2)*(F)
print"\t individual heat transfer coefficient is : Btu/(hr)*(ft**2)*(F) \t",Ho
phys=1;
ho=(Ho)*(phys); # from eq.6.36
print"\t Correct h0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",ho
print"\t cold fluid:inner tube side,crude oil \t"
Nt=340;
n=12; # number of passes
L=12; #ft
at1=0.546; # flow area, in**2
at=((Nt*at1)/(144*n)); # total area,ft**2,from eq.7.48
print"\t flow area is : ft**2 \t",at
Gt=(w/(at)); # mass velocity,lb/(hr)*(ft**2)
print"\t mass velocity is : %lb/(hr)*(ft**2) \t",Gt
V=(Gt/(3600*62.5));
print"\t V is : fps \t",V
mu2=1.96; # at 90F,lb/(ft)*(hr)
D=0.0695; # ft
Ret=((D)*(Gt)/mu2); # reynolds number
print"\t reynolds number is : \t",Ret
hi=667; #Btu/(hr)*(ft**2)*(F)
print"\t hi is : Btu/(hr)*(ft**2)*(F) \t",hi
ID=0.83; # ft
OD=1; #ft
hio=((hi)*(ID/OD)); #Hio=(hio/phyp), using eq.6.5
print"\t Correct hi0 to the surface at the OD is : Btu/(hr)*(ft**2)*(F) \t",hio # calculation mistake
phyt=1;
print"\t pressure drop for annulus \t"
f=0.0017; # friction factor for reynolds number 33000, using fig.29
s=0.0012; # for reynolds number 33000,using fig.6
Ds=31/12; # ft
N=(3); # number of crosses,using eq.7.43
print"\t number of crosses are : \t",N
delPs=((f*(Gs**2)*(Ds)*(N))/(5.22*(10**10)*(De)*(s)*(phys))); # using eq.7.44,psi
print"\t delPs is : psi \t",delPs
print"\t pressure drop for inner pipe \t"
f=0.00022; # friction factor for reynolds number 21300, using fig.26
s=1;
delPt=((f*(Gt**2)*(L)*(n))/(5.22*(10**10)*(D)*(s)*(phyt))); # using eq.7.45,psi
print"\t delPt is : psi \t",delPt
X1=0.052; # X1=((V**2)/(2*g)), for Gt 1060000,using fig.27
delPr=((4*n*X1)/(s)); # using eq.7.46,psi
print"\t delPr is : psi \t",delPr
delPT=delPt+delPr; # using eq.7.47,psi
print"\t delPT is : psi \t",delPT
Uc=((hio)*(ho)/(hio+ho)); # clean overall coefficient,Btu/(hr)*(ft**2)*(F)
print"\t clean overall coefficient is : Btu/(hr)*(ft**2)*(F) \t",round(Uc,1)
Rd=-1*(((Uc-UD)/((UD)*(Uc)))-0.02); # (hr)*(ft**2)*(F)/Btu
print"\t actual Rd is : (hr)*(ft**2)*(F)/Btu \t",round(Rd,4)
# end