# Chapter 3 : Material and Energy Balances¶

### example 3.1 page number 90¶

In :

import math

# Variables
w_C = 0.6;   #amount of carbon in coal
N2_content = 40.   #in m3 per 100m3 air

# Calculations
air_consumed = N2_content/0.79;
weight_air = air_consumed*(28.8/22.4);
O2_content = air_consumed*32*(0.21/22.4);    #in kg

H2_content = 20.   #in m3

steam_consumed = H2_content*(18/22.4);

C_consumption1 = (12./18)*steam_consumed;   #in reaction 1
C_consumption2 = (24./32)*O2_content;    #in reaction 2

total_consumption = C_consumption1+C_consumption2;
coal_consumption = total_consumption/w_C;

# Results
print "coal consumption = %f kg"%(coal_consumption)

coal consumption = 36.844485 kg


### example 3.2 page number 91¶

In :

import math

# Variables
NH3_required = (17./63)*1000;    #NH3 required for 1 ton of nitric acid
NO_consumption = 0.96;
HNO3_consumption = 0.92;

# Calculations and Results
NH3_consumed = NH3_required/(NO_consumption*HNO3_consumption);
volume_NH3 = NH3_consumed*(22.4/17);
print "volume of ammonia consumed= %f cubic metre/h"%(volume_NH3)

NH3_content = 11.   #% by volume
air_consumption = volume_NH3*((100-11)/11.);
print "volume of air consumed = %f cubic metre/h"%(air_consumption)

volume of ammonia consumed= 402.576490 cubic metre/h
volume of air consumed = 3257.209779 cubic metre/h


### example 3.3 page number 91¶

In :

import math

# Variables
HCl_production = 500.   #required to be produced in kg
NaCl_required = (117./73)*HCl_production;
yield_ = 0.92;
purity_NaCl= 0.96;

# Calculations and Results
actual_NaCl = NaCl_required/(purity_NaCl*yield_);
print "amount of NaCl required = %f kg"%(actual_NaCl)

purity_H2SO4 = 0.93;
H2SO4_consumption = (98./73)*(HCl_production/(yield_*purity_H2SO4));
print "amount of H2SO4 consumed = %f kg"%(H2SO4_consumption)

Na2SO4_produced = (142/73.)*HCl_production;
print "amount of Na2SO4 produced = %f kg"%(Na2SO4_produced)

amount of NaCl required = 907.348124 kg
amount of H2SO4 consumed = 784.517154 kg
amount of Na2SO4 produced = 972.602740 kg


### example 3.4 page number 92¶

In :

import math

# Variables
C2H2_produced = (1./64)*0.86;   #in kmol
volume_C2H2 = C2H2_produced*22.4*1000;    #in l

# Calculations
#assuming ideal behaviour,
volume = (100/101.3)*(273./(273+30));
time = (volume_C2H2/volume)*(1./60);

# Results
print "time of service = %f hr"%(time)

time of service = 5.640332 hr


### example 3.5 page number 92¶

In :

import math

# Variables
xv = 0.88;
xf = 0.46;
xl = 0.32;
F= 100.   #in kg

# Calculations and Results
L = (F*(xf-xv))/(xl-xv);
V = F-L;
print "L = %f Kg V = %f Kg"%(L,V)
Eo = (V*xv)/(F*xf);

print " effectiveness based on oversized partices = %f "%(Eo)
Eu = (L*(1-xl))/(F*(1-xf));

print "effectiveness based on undersized partices = %f"%(Eu)
E=Eu*Eo;

print "overall effectiveness = %f"%(E)

L = 75.000000 Kg V = 25.000000 Kg
effectiveness based on oversized partices = 0.478261
effectiveness based on undersized partices = 0.944444
overall effectiveness = 0.451691


### example 3.6 page number 94¶

In :

import math

# Variables
G1 = 3600.   #in m3/h
P = 106.6    #in kPa
T = 40   #in degree C

# Calculations and Results
q = G1*(P/101.3)*(273./((273+T)));   #in m3/s
m = q/22.4;   #in kmol/h
y1 = 0.02;
Y1 = y1/(1-y1);

print "mole ratio of benzene = %f kmol benzene/kmol dry gas"%(Y1)

Gs = m*(1-y1);
print "moles of benzene free gas = %f kmol drygas/h"%(Gs)

#for 95% removal
Y2 = Y1*(1-0.95);
print "final mole ratio of benzene = %f kmol benzene/kmol dry gas"%(Y2)

x2 = 0.002
X2 = 0.002/(1-0.002);

#at equilibrium y* = 0.2406X
#part 1
#for oil rate to be minimum the wash oil leaving the absorber must be in equilibrium with the entering gas

y1 = 0.02;
x1 = y1/(0.2406);
X1 = x1/(1-x1);
min_Ls = Gs*((Y1-Y2)/(X1-X2));
print "minimum Ls required = %f kg/h"%(min_Ls*260)

#for 1.5 times of the minimum
Ls = 1.5*min_Ls;
print "flow rate of wash oil = %f kg/h"%(Ls*260)
X1 = X2 + (Gs*((Y1-Y2)/Ls));
print "concentration of benzene in wash oil = %f kmol benzene/kmol wash oil"%(X1)

mole ratio of benzene = 0.020408 kmol benzene/kmol dry gas
moles of benzene free gas = 144.559497 kmol drygas/h
final mole ratio of benzene = 0.001020 kmol benzene/kmol dry gas
minimum Ls required = 8219.216789 kg/h
flow rate of wash oil = 12328.825184 kg/h
concentration of benzene in wash oil = 0.061109 kmol benzene/kmol wash oil


### example 3.7 page number 95¶

In :

from scipy.optimize import fsolve
import math

# Variables
xf = 0.01
Xf = xf/(1-xf);
Feed = 100   #feed in kg

# Calculations and Results
c_nicotine = Feed*Xf;   #nicotine conc in feed
c_water = Feed*(1-Xf)    #water conc in feed

#part 1
def  F1(x):
return  (x/150.)-0.9*((1-x)/99.);

#initial guess
x = 10.;
y = fsolve(F1,x)
print "amount of nicotine removed N = %f kg"%(y)
#part 2
def F2(x):
return  (x/50.)-0.9*((1-x)/99.);

#initial guess
x = 10.;
N1 = fsolve(F2,x)
print "amount of nicotine removed in stage 1, N1 = %f kg"%(N1)
def F3(x):
return  (x/50.)-0.9*((1-x-N1)/99.);

#initial guess
x = 10.;
N2 = fsolve(F3,x)
print "amount of nicotine removed in stage 2, N2 = %f kg"%(N2)
def F4(x):
return (x/50.)-0.9*((1-x-N2-N1)/99.);

#initial guess
x = 10.;
N3 = fsolve(F4,x)

print "amount of nicotine removed in stage 3, N3 = %f kg"%(N3)
N = N1+N2+N3;
print "total amount of nicotine removed = %f kg"%(N)

amount of nicotine removed N = 0.576923 kg
amount of nicotine removed in stage 1, N1 = 0.312500 kg
amount of nicotine removed in stage 2, N2 = 0.214844 kg
amount of nicotine removed in stage 3, N3 = 0.147705 kg
total amount of nicotine removed = 0.675049 kg


### example 3.8 page number 96¶

In :

import math

# Variables
vp_water = 31.06   #in kPa
vp_benzene = 72.92   #in kPa

P = vp_water +vp_benzene;
x_benzene = vp_benzene/P;
x_water = vp_water/P;

# Calculations
initial_water = 50./18;   #in kmol of water
initial_benzene = 50./78   #in kmol of benzene
water_evaporated = initial_benzene*(x_water/x_benzene);
water_left = (initial_water - water_evaporated);

# Results
print "amount of water left in residue = %f kg"%(water_left*18)

amount of water left in residue = 45.085236 kg


### example 3.9 page number 97¶

In :

import math
# Variables
po_D = 4.93   #in kPa
po_W = 96.3   #in kPa
n = 0.75   #vaporization efficiency

# Calculations and Results
P = n*po_D+po_W;
print "P = %f kPa"%(P)

x_water = 96.3/100;
x_dimethylanaline = 1-x_water;
wt_dimethylanaline = (x_dimethylanaline*121)/(x_dimethylanaline*121+x_water*18);
print "weight of dimethylanaline in water = %f"%(wt_dimethylanaline*100)

#part 1
n = 0.8;
po_D = 32   #in kPa
actual_vp = n*po_D;
p_water = 100 - actual_vp;
steam_required = (p_water*18)/(actual_vp*121);
print "amount of steam required = %f kg steam/kg dimethylanaline"%(steam_required)

#part 2
x_water = p_water/100.;
wt_water = x_water*18./(x_water*18+(1-x_water)*121.);
print "weight of water vapor = %f weight of dimethylanaline =%f"%(wt_water*100,100*(1-wt_water))

P = 99.997500 kPa
weight of dimethylanaline in water = 20.526340
amount of steam required = 0.432335 kg steam/kg dimethylanaline
weight of water vapor = 30.183916 weight of dimethylanaline =69.816084


### example 3.10 page number 98¶

In :

import math
# Variables
xf = 0.15;
xl = (114.7)/(114.7+1000);
xc = 1;

# Calculations
K2Cr2O7_feed = 1000*0.15;   #in kg

n = 0.8;
C = n*K2Cr2O7_feed;
V = (K2Cr2O7_feed-120 - 880*0.103)/(-0.103);

# Results
print "amount of water evaporated = %f kg"%(V)

amount of water evaporated = 588.737864 kg


### example 3.11 page number 98¶

In :

import math
# Variables
xc = round(106./286,3);
xf = 0.25;
xl = round(27.5/127.5,3);

# Calculations
water_present = 100*(1-xf);    #in kg
V = 0.15*75;   #in kg
C = (100*xf - 88.7*xl)/(xc-xl);
Na2CO3_feed = 25./xc;

yield_ = (C/Na2CO3_feed)*100;

# Results
print "yield = %.1f %%"%(yield_)

yield = 55.9 %


### example 3.12 page number 99¶

In :

import math
# Variables
r = 50.   #weight of dry air passing through drier
w1 = 1.60   #in kg per kg dry solid
w2 = 0.1    #in kg/kg dry solid
H0 = 0.016  #in kg water vapor/kg dry air
H2 = 0.055  #in kg water vapor/kg dry air

# Calculations and Results
y = 1 - (w1-w2)/(r*(H2-H0));
print "fraction of air recirculated = %f"%(y)

H1 = H2 - (w1-w2)/r;
print "humidity of air entering the drier = %f kg water vapor/kg kg dry air"%(H1)

#check
H11 = H2*y+H0*(1-y);
if H1 == H11:
print "fraction of air recirculated = %f  verified"%(y)

fraction of air recirculated = 0.230769
humidity of air entering the drier = 0.025000 kg water vapor/kg kg dry air
fraction of air recirculated = 0.230769  verified


### example 3.13 page number 100¶

In :

import math
# Variables
Hf = 0.012;
Hi = 0.033;
H1 = 0.0075;

# Calculations and Results
water_vapor = Hf/18.;   #in kmol of water vapor
dry_air = 1/28.9;  #in kmol
total_mass = water_vapor+dry_air;

volume = 22.4*(298./273)*total_mass;
weight = 60/volume;
print "weight of dry air handled per hr = %f kg"%(weight)

#part 1
inlet_watervapor = 0.033/18;    #in kmol of water vapor
volume_inlet = 22.4*(308./273)*(inlet_watervapor+dry_air);
print "volumetric flow rate of inlet air = %f cubic meter"%(volume_inlet*weight)

#part 2
y = (Hf - Hi)/(H1 - Hi);
print "fraction of inlet air passing through cooler = %f"%(y)

weight of dry air handled per hr = 69.576029 kg
volumetric flow rate of inlet air = 64.064786 cubic meter
fraction of inlet air passing through cooler = 0.823529


### example 3.14 page number 102¶

In :

import math

# Variables
#x- moles of N2 and H2 recycled; y - moles of N2 H2 purged
Ar_freshfeed = 0.2;
#argon in fresh feed is equal to argon in purge

# Calculations and Results
y = 0.2/0.0633;   #argon in purge = 0.0633y
x = (0.79*100 - y)/(1-0.79);
print "y = %f kmolx = %f kmol"%(y,x)

#part 1
fraction = y/x;
print "fration of recycle that is purged = %f"%(fraction)

#part 2
yield_ = 0.105*(100+x);
print "overall yield of ammonia = %f kmol"%(yield_)

y = 3.159558 kmolx = 361.144964 kmol
fration of recycle that is purged = 0.008749
overall yield of ammonia = 48.420221 kmol


### example 3.15 page number 107¶

In :

import math
# Variables
H0_CH4 = -74.9   #in kJ
H0_CO2 = -393.5   #in kJ
H0_H2O = -241.8   #in kJ

# Calculations
delta_H0 = H0_CO2+2*H0_H2O-H0_CH4;

# Results
print "change in enthalpy = %f kJ"%(delta_H0)

change in enthalpy = -802.200000 kJ


### example 3.16 page number 107¶

In :

import math
# Variables
H0_glucose = -1273  #in kJ
H0_ethanol = -277.6  #in kJ
H0_CO2 = -393.5  #in kJ
H0_H2O = -285.8   #in kJ

# Calculations and Results
#for reaction 1
delta_H1 = 2*H0_ethanol+2*H0_CO2-H0_glucose;
print "enthalpy change in reaction 1 = %f KJ"%(delta_H1)

#for reaction 2
delta_H2 = 6*H0_H2O+6*H0_CO2-H0_glucose;
print "enthalpy change in reaction 2 = %f kJ"%(delta_H2)

if delta_H1>delta_H2:
print  "reaction 2 supplies more energy"
else:
print  "reaction 1 supplies more energy"

enthalpy change in reaction 1 = -69.200000 KJ
enthalpy change in reaction 2 = -2802.800000 kJ
reaction 2 supplies more energy


### example 3.17 page number 108¶

In :

import math
# Variables
delta_H2 = 11.7   #in kJ/mol
m_CuSO4 = 16  #in gm
m_H2O = 384   #in gm

# Calculations
delta_H3 = -((m_CuSO4+m_H2O)*4.18*3.95*159.6)/(16*10**3)
delta_H1 = delta_H3 - delta_H2;

# Results
print "enthalpy of formation = %f kJ/mol"%(delta_H1)

enthalpy of formation = -77.578890 kJ/mol


### example 3.18 page number 108¶

In :

import math
# Variables
H_combustion = 1560000    #in kJ/kmol
H0_CO2 = 54.56   #in kJ/kmol
H0_O2 = 35.2   #in kJ/kmol
H0_steam = 43.38   #in kJ/kmol
H0_N2 = 33.32   #in kJ/kmol

# Calculations
t = H_combustion/(2*H0_CO2+3*H0_steam+0.875*H0_O2+16.46*H0_N2);

# Results
print "theoritical temperature of combustion = %f degree C"%(t)

theoritical temperature of combustion = 1905.908708 degree C


### example 3.19 page number 109¶

In :

import math
# Variables
H_NaCl = 410.9   #in MJ/kmol
H_H2SO4 = 811.3   #in MJ/kmol
H_Na2SO4 = 1384   #in MJ/kmol
H_HCl = 92.3   #in MJ/kmol

# Calculations and Results
Q = H_Na2SO4 + 2*H_HCl -2*H_NaCl-H_H2SO4;
print "heat of reaction = %f MJ"%(Q)

heat_required = 64.5*(500./73);
coke_consumption = heat_required/19
print "amount of coke oven gas consumed = %f cubic meter"%(coke_consumption)

heat of reaction = -64.500000 MJ
amount of coke oven gas consumed = 23.251622 cubic meter


### example 3.20 page number 109¶

In :

import math
# Variables
cp_water = 146.5   #in kj/kg
cp_steam = 3040   #in kJ/kg
d = 0.102  #in m
u = 1.5  #in m/s
density = 1000   #in kg/m3

# Calculations
m = (3.14/4)*d**2*u*density;
Q = m*(cp_steam-cp_water);

# Results
print "rate of heat flow = %f kW"%(Q)

rate of heat flow = 35447.429385 kW


### example 3.22 page number 110¶

In :

import math
# Variables
wt_C = 0.75   #in kg
wt_H2 = 0.05   #in kg
wt_O2 = 0.12   #in kg
wt_N2 = 0.03   #in kg
wt_S = 0.01    #in kg
wt_ash = 0.04  #in kg

# Calculations and Results
O2_C = wt_C*(32./12);  #in kg
O2_H2 = wt_H2*(16./2);   #in kg
O2_S = wt_S*(32./32);   #in kg
O2_required = O2_C+O2_H2+O2_S;

oxygen_supplied = O2_required - wt_O2;
air_needed = oxygen_supplied/0.23;
print "amount of air required = %f kg"%(air_needed)

volume = (22.4/28.8)*air_needed;
print "volume of air needed = %f cubic meter"%(volume)

air_supplied = 1.20*air_needed;
N2_supplied = air_supplied*0.77;
total_N2 = N2_supplied+wt_N2;

O2_fluegas = air_supplied*0.23 - oxygen_supplied;

wt_CO2 = wt_C+O2_C;
wt_SO2 = wt_S+O2_S;

moles_CO2 = wt_CO2/44;
moles_SO2 = wt_SO2/64;
moles_N2 = total_N2/28;
moles_O2 = O2_fluegas/32;
total_moles = moles_CO2+moles_SO2+moles_N2+moles_O2;

x_CO2 = moles_CO2/total_moles;
x_SO2 = moles_SO2/total_moles;
x_N2 = moles_N2/total_moles;
x_O2 = moles_O2/total_moles;

print "CO2 = %f %%"%(x_CO2*100)
print "SO2 = %f %%"%(x_SO2*100)
print "N2 = %f %%"%(x_N2*100)
print "O2 = %f %%"%(x_O2*100)

# Note : answers are slightly different because of rounding error.

amount of air required = 9.956522 kg
volume of air needed = 7.743961 cubic meter
CO2 = 15.365264 %
SO2 = 0.076826 %
N2 = 81.039264 %
O2 = 3.518645 %


### example 3.23 page number 110¶

In :

import math
# Variables
C = 0.8   #in kg
H2 = 0.05   #in kg
S = 0.005   #in kg
ash = 0.145  #in kg

# Calculations and Results
#required oxygen in kg
C_O2 = C*(32./12);
H2_O2 = H2*(16./2);
S_O2 = S*(32./32);
O2_supplied = C_O2+S_O2+H2_O2;
print "amount of O2 supplied = %f kg"%(O2_supplied)

wt_air = O2_supplied*(100./23);
wt_airsupplied = 1.25*wt_air;
print "amount of air supplied = %f kg"%(wt_airsupplied)

#flue gas composition
m_N2 = wt_airsupplied*0.77;   #in kg
mole_N2 = m_N2/28.;

m_O2 = (wt_airsupplied-wt_air)*0.23;   #in kg
mole_O2 = m_O2/32.;

m_CO2 = C*(44/12.);   #in kg
mole_CO2 = m_CO2/44.;

m_H2O = H2*(18/2.);   #in kg
mole_H2O = m_H2O/18.;

m_SO2 = S*(64/32.);   #in kg
mole_SO2 = m_SO2/64.;

m = m_N2+m_O2+m_CO2+m_H2O+m_SO2

#percent by weight
w_N2 = m_N2/m;
print "percentage of N2 by weight = %f"%(w_N2*100)

w_O2 = m_O2/m;
print "percentage of O2 by weight = %f"%(w_O2*100)

w_CO2 = m_CO2/m;
print "percentage of CO2 by weight = %f"%(w_CO2*100)

w_H2O = m_H2O/m;
print "percentage of H2O by weight = %f"%(w_H2O*100)

w_SO2 = m_SO2/m;
print "percentage of SO2 by weight = %f"%(w_SO2*100)

m1 = mole_N2+mole_O2+mole_CO2+mole_H2O+mole_SO2

#percent by mole
x_N2 = mole_N2/m1;
print "percentage of N2 by mole = %f"%(x_N2*100)

x_O2 = mole_O2/m1;
print "percentage of O2 by mole = %f"%(x_O2*100)

x_CO2 = mole_CO2/m1;
print "percentage of CO2 by mole = %f"%(x_CO2*100)

x_H2O = mole_H2O/m1;
print "percentage of H2O by mole = %f"%(x_H2O*100)

x_SO2 = mole_SO2/m1;
print "percentage of SO2 by mole = %f"%(x_SO2*100)

amount of O2 supplied = 2.538333 kg
amount of air supplied = 13.795290 kg
percentage of N2 by weight = 72.506232
percentage of O2 by weight = 4.331541
percentage of CO2 by weight = 20.022357
percentage of H2O by weight = 3.071612
percentage of SO2 by weight = 0.068258
percentage of N2 by mole = 77.261067
percentage of O2 by mole = 4.038647
percentage of CO2 by mole = 13.577066
percentage of H2O by mole = 5.091400
percentage of SO2 by mole = 0.031821


### example 3.24 page number 112¶

In :

import math
# Variables
wt_H2 = 0.15;
wt_C = 0.85;
O2_H2 = wt_H2*(16./2);
O2_C = wt_C*(32./12);

# Calculations and Results
total_O2 = O2_H2+O2_C;
wt_air = total_O2/0.23;
air_supplied = 1.15*(wt_air);
N2_supplied = 0.77*air_supplied/28.;
O2_supplied = 0.23*(air_supplied-wt_air)/32.;
moles_CO2 = 0.85/12;

print "moles of CO2 = %f kmol"%(moles_CO2)
print "moles of N2 = %f kmol "%(N2_supplied)
print "moles of O2 = %f kmol"%(O2_supplied)

total_moles = N2_supplied+O2_supplied+moles_CO2;

print "percentage of CO2 = %f"%((moles_CO2/total_moles)*100)
print "percentage of N2 = %f"%((N2_supplied/total_moles)*100)
print "percentage of O2 = %f"%((O2_supplied/total_moles)*100)

moles of CO2 = 0.070833 kmol
moles of N2 = 0.476667 kmol
moles of O2 = 0.016250 kmol
percentage of CO2 = 12.564671
percentage of N2 = 84.552846
percentage of O2 = 2.882483


### example 3.25 page number 113¶

In :

import math
# Variables
N2 = 80.5   #in m3
air_supplied = N2/0.79   #in m3
volume_O2 = air_supplied*0.21;  #in m3
O2_fluegas = 6.1   #in m3

# Calculations
O2_used = volume_O2 - O2_fluegas;
excess_air_supplied = (O2_fluegas/O2_used)*100;

# Results
print "percentage of excess air supplied = %f"%(excess_air_supplied)

percentage of excess air supplied = 39.872580


### example 3.26 page number 114¶

In :

import math
# Variables
q_NTP = 10*(200/101.3)*(273./313);
m_CO2 = 44*(q_NTP/22.4);
s_CO2 = 0.85   #in kJ/kg K

# Calculations
Q = m_CO2*s_CO2*(40-20)   #Q = ms*delta_T

d0 = 0.023   #in mm
A0 = (3.14/4)*d0**2;
di = 0.035   #in mm
Ai = (3.14/4)*di**2;

A_annular = Ai-A0;
u = 0.15   #in m/s
m_water = A_annular*(u*3600)*1000   #in kg/hr

s_water = 4.19    #in kJ/kg K
t = 15+(Q/(m_water*s_water));

# Results
print "exit water temperature = %f degree C"%(t)

exit water temperature = 15.465164 degree C


### example 3.27 page number 114¶

In :

import math
# Variables
F = 1000   #in kg
xF = 0.01

# Calculations and Results
solid_feed = F*xF;
water_feed = F - solid_feed;

tF = 40  #in degree C
hF = 167.5   #in kJ/kg
xL = 0.02;

solid_liquor = 10  #in kg
L = solid_liquor/xL;
tL = 100  #in degree C
hL = 418.6   #in kJ/kg

V = F -L;

tv = 100  #in degree C
Hv = 2675   #in kJ/kg
ts = 108.4  #in degree C
Hs = 2690  #in kJ/kg
tc = 108.4  #in degree C
hc = 454   #in kJ/kg

#applying heat balance
S = (F*hF-V*Hv-L*hL)/(hc-Hs);
print "weight of steam required = %f kg/hr"%(S)

Q = S*(Hs-hc);
U = 1.4   #in kW/m2K
delta_t = ts-tL;
A = 383.2/(U*delta_t);
print "area of heating surface = %f square meter"%(A)

weight of steam required = 616.860465 kg/hr
area of heating surface = 32.585034 square meter


### example 3.28 page number 115¶

In :

import math
# Variables
hF = 171  #in kJ/kg
hD = 67   #in kJ/kg
hL = hD;

hW = 200  #in kJ/kg
H = 540  #in kJ/kg

print ('part 1')
F = 1000   #in kg/h
xF = 0.40
xW = 0.02;
xD = 0.97;

# Calculations and Results
D = F*(xF-xW)/(xD-xW);
W = F-D;

print "bottom product = %f kg/hr"%(W)
print "top product = %f kg/hr"%(D)

print ('part 2')
L = 3.5*D;
V = L+D;
Qc = V*H-L*hL-D*hD;
print "condenser duty = %f KJ/hr"%(Qc)

print ('part 3')
Qr = Qc - 24200;
print "rate of heat input to reboiler = %f kJ/hr"%(Qr)

part 1
bottom product = 600.000000 kg/hr
top product = 400.000000 kg/hr
part 2
condenser duty = 851400.000000 KJ/hr
part 3
rate of heat input to reboiler = 827200.000000 kJ/hr


### example 3.29 page number 117¶

In :

import math
# Variables
F = 1000.;    #in kg
V = 0.05*F;   #in kg
xF = 0.48;
xL = 75./(100+75);
xC = 1.;

# Calculations and Results
C = (F*xF-950*xL)/(1-0.429);
print  "rate of crystal formation = %f kg"%(C)

L = F-C-V;

#cooling water
W = (F*2.97*(85-35)+126.9*75.2-V*2414)/(4.19*11);
print "rate of cooling water = %f kg"%(W)

delta_T1 = 56.;
delta_T2 = 17.;
delta_Tm = (delta_T1-delta_T2)/(math.log(delta_T1/delta_T2))
U = 125;

A=(F*2.97*(85-35)+126.9*75.2-V*2414)/(U*delta_Tm*3.6);
print "area = %f square meter"%(A)

rate of crystal formation = 127.595697 kg
rate of cooling water = 810.216533 kg
area = 2.536631 square meter


### example 3.30 page number 118¶

In :

import math
# Variables
delta_n = 10-12.;  #mole per mole napthanlene

#basis 1g
moles_napthalene = (1./128);

# Calculations and Results
print ('part 1')
Qv = 40.28   #in kJ
Qp = Qv-(delta_n*moles_napthalene*8.3144*298./1000);
print "heat of combustion = %f kJ"%(Qp)

print ('part 2')
delta_H = 44.05   #in kJ/gmol
water_formed = 4./128;   #in g mol
Qp1 = Qp - (delta_H*water_formed);
print "heat of combustion = %f kJ"%(Qp1)

part 1
heat of combustion = 40.318714 kJ
part 2
heat of combustion = 38.942151 kJ

In [ ]: