# Variables
C = 0.88; #Fraction of carbon in coal
H = 0.042; #Fraction of Hydrogen in coal
w_f = 0.848; #gm
w_fw = 0.027; #gm
w = 1950.; #gm
w_e = 380.; #gm
dt = 3.06; #0C; Observed temperature rise
tc = 0.017; #0C
dt1 = dt+tc; #Corrected temperature rise
Cal = 6700.; #J/gm; Calorific value of fuse wire
# Calculations
Q_received = (w+w_e)*4.18*dt1; #Heat received by water
Q_rejected = w_fw*Cal; #Heat given out by fuse wire
Q_produced = Q_received - Q_rejected;
HCV = Q_produced/w_f;
# Results
print ("Higher calorific value = %.3f")% (HCV), ("kJ/kg")
LCV = HCV - 2465*9*H;
print ("Lower Calorific value = %.3f")% (LCV), ("kJ/kg")
# Variables
p1 = 75.882; #cm of Hg
T1 = 286.; #K
V1 = 0.08; #m**3
p2 = 76.; #cm of Hg
T2 = 288.; #K
# Calculations
V2 = p1*V1*T2/p2/T1;
m = 28.; #kg
c = 4.18;
t2 = 23.5; #0C
t1 = 10.; #0C
Q_received = m*c*(t2-t1);
HCV = Q_received/V2;
# Results
print ("Higher calorific value = %.3f")% (HCV), ("kJ/m**3")
amt = 0.06/0.08; #Amount of vapour formed per m**3 of gas burnt
LCV = HCV-2465*amt;
print ("Lower calorific value = %.3f")% (LCV), ("kJ/kg")
# Variables
C = 0.85; #Weight of Carbon present
H2 = 0.06; #Weight of Hydrogen present
O2 = 0.06; #Weight of Oxygen present
# Calculations
w_required = C*8./3 + H2*8; #Weight of O2 required
w_needed = w_required-O2; #Weight of O2 to be supplied
w_air = w_needed*100./23;
# Results
print ("Weight of air needed = %.3f")% (w_air), ("kg")
# Variables
C = 0.848; #kg
H2 = 0.152; #kg
O2_used = C*8./3 + H2*8;
# Calculations and Results
print ("(i) Minimum weight of air needed for combustion")
w_min = O2_used*100/23.;
print ("Minimum weight of air needed for combustion = %.3f")%(w_min), ("kg")
w_excess = w_min*0.15; #Excess air supplied
w_O2 = w_excess*23/100; #Weight of O2 in excess air
w_total = w_min + w_excess; #Total air supplied for combustion
w_N2 = w_total*77/100; #Weight of N2 in flue gases
print ("(ii) the volumetric composition of the products of combustion")
#For CO2
x1 = 3.109;
y1 = 44.;
z1 = x1/y1;
#For O2
x2 = w_O2;
y2 = 32.;
z2 = x2/y2;
#For N2
x3 = w_N2;
y3 = 28.;
z3 = x3/y3;
z = z1+z2+z3;
#For CO2
V1 = z1/z*100;
print ("volume of CO2 = %.3f")% (V1), ("%")
#For O2
V2 = z2/z*100;
print ("volume of O2 = %.3f")% (V2), ("%")
#For CO2
V3 = z3/z*100;
print ("volume of N2 = %.3f")% (V3), ("%")
import math
# Variables
C=0.78;
H2=0.06;
O2=0.03;
w_O2=C*8./3 + H2*8;
w_min=(w_O2-O2)*100./23; #Minimum wt. of air needed for combustion
#For CO2
x1=0.104;
y1=44.;
z1=x1*y1;
#For CO
x2=0.002;
y2=28.;
z2=x2*y2;
#For N2
x3=0.816;
y3=28.;
z3=x3*y3;
#For O2
x4=0.078;
y4=32.;
z4=x4*y4;
z=z1+z2+z3+z4;
# Calculations
W_CO2=z1/z; #Weight per kg of flue gas
W_CO=z2/z; #Weight per kg of flue gas
W_N2=z3/z; #Weight per kg of flue gas
W_O2=z4/z; #Weight per kg of flue gas
amt=3./11*W_CO2 + 3./7*W_CO;
W=C/amt; #Weight of dry flue gas per kg of fuel
# Results
print ("(i)Weight of dry flue gas per kg of fuel = %.3f")% (W), ("kg")
m_O2=W_O2-4/7*W_CO; #Weight of excess oxygen per kg of flue gas
m_excess=W*m_O2; #Weight of excess O2 per kg of fuel
w_excess=m_excess*100/23; #Weight of excess air per kg of fuel
print ("(ii)Weight of excess air per kg of fuel= %.3f")% (w_excess), ("kg")
# Variables
v_CO = 0.05;
v_CO2 = 0.10;
v_H2 = 0.50;
v_CH4 = 0.25;
v_N2 = 0.10;
V_fuel = 1.;
# Calculations
V_O2 = v_CO/2+v_H2/2+2*v_CH4; #Volume of O2 needed
V_air = V_O2*100./21; #Volume of air required
V_N2 = V_air*79./100; #Volume of nitrogen in the air
V = v_CO + v_CO2 + v_CH4 + v_N2 + V_N2; #Dry combustion products
O2 = 6.;
V_excess = O2*V/(21-O2);
V_total = V_air+V_excess;
ratio = V_total/V_fuel;
# Results
print ("Air fuel ratio = %.f")%(ratio)
import math
# Variables
C = 0.85;
H2 = 0.15;
#For CO2
x1 = 0.115;
y1 = 44;
z1 = x1*y1;
#For CO
x2 = 0.012;
y2 = 28;
z2 = x2*y2;
#For O2
x3 = 0.009;
y3 = 32;
z3 = x3*y3;
#For N2
x4 = 0.86;
y4 = 28;
z4 = x4*y4;
# Calculations
z = z1+z2+z3+z4;
W_CO2 = z1/z; #Weight per kg of flue gas
W_CO = z2/z; #Weight per kg of flue gas
W_O2 = z3/z; #Weight per kg of flue gas
W_N2 = 4/z; #Weight per kg of flue gas
W_C = 3./11*W_CO2 + 3./7*W_CO; #Weight of carbon per kg of flue gas
W = C/W_C; #Weight of dry flue gas per kg of fuel
Vapour = 1.35; #kg; Vapour of combustion
W_total = W+Vapour; #Total weight of gas
W_air = W_total-1; #Air supplied
ratio = W_air/1;
# Results
print ("Ratio of air to petrol = %.3f")% (ratio)
S_air = (C*8./3 + H2*8)*100./23; #Stoichiometric air
W_excess = W_air-S_air; #Excess air
Excess = W_excess/S_air*100; #Percentage excess air
print ("Percentage excess air %.3f")% (Excess),
print ("%")
# Variables
C = 0.86;
H2 = 0.08;
S = 0.03;
O2 = 0.02;
# Calculations and Results
W_O2 = C*8./3 + H2*8 + S*1;
A = W_O2-O2; #Weight of oxygen to be supplied per kg of fuel
W_min = A*100./23;
r_correct = 1./W_min/1; #“correct” fuel-air ratio
r_actual = 1./12;
print ("(i) Mixture strength")
s = r_actual/r_correct*100; #Mixture strength
richness = s-100;
print ("richness = %.3f")% (richness), ("%")
print ("This show that mixture is 6.5% rich.")
D = 1/r_correct-1/r_actual;
CO = 0.313; #kg
CO2 = 2.662; #kg
N2 = 9.24; #kg
SO2 = 0.06; #kg
print ("(ii) The percentage composition of dry flue gases")
#For CO
x1 = 0.313; #kg
y1 = 28.;
z1 = x1/y1;
#For CO2
x2 = 2.662; #kg
y2 = 44;
z2 = x2/y2;
#For N2
x3 = 9.24; #kg
y3 = 28;
z3 = x3/y3;
#For SO2
x4 = 0.06; #kg
y4 = 64;
z4 = x4/y4;
z = z1+z2+z3+z4;
#Let percentage volume be denoted by V
V_CO = z1/z*100;
print ("Percentage volume of CO = %.3f")% (V_CO), ("%")
V_CO2 = z2/z*100;
print ("Percentage volume of CO2 = %.3f")% (V_CO2), ("%")
V_N2 = z3/z*100;
print ("Percentage volume of N2 = %.3f")% (V_N2), ("%")
V_SO2 = z4/z*100;
print ("Percentage volume of SO2 = %.3f")% (V_SO2), ("%")
import math
# Variables
A = 992./284*100./23; #Air required for complete combustion
B = 13.; #kg/kg of fuel; Air actually supplied
D = A-B; #Deficiency of air
# Calculations
W_CO2 = 0.466*11./3;
W_CO = 0.379*7./3;
W_H2O = 22./142*9;
W_N2 = 13.*0.77;
#For CO2
x1 = W_CO2
y1 = 44.;
z1 = x1/y1;
#For CO
x2 = W_CO;
y2 = 28.;
z2 = x2/y2;
#For H2O
x3 = W_H2O;
y3 = 18.;
z3 = x3/y3;
#For N2
x4 = W_N2;
y4 = 28.;
z4 = x4/y4;
z = z1+z2+z3+z4;
CO2 = z1/z*100;
# Results
print ("Percentage of CO2 = %.3f")% (CO2), ("%")
CO = z2/z*100;
print ("Percentage of CO = %.3f")% (CO), ("%")
H2O = z3/z*100;
print ("Percentage of H2O = %.3f")% (H2O), ("%")
N2 = z4/z*100;
print ("Percentage of N2 = %.3f")% (N2), ("%")
# Variables
C = 80.;
#Analysis of gas entering the economiser
CO2_1 = 8.3;
CO_1 = 0.;
O2_1 = 11.4;
N2_1 = 80.3;
#Analysis of gas leaving the economiser
CO2_2 = 7.9;
CO_2 = 0.;
O2_2 = 11.5;
N2_2 = 80.6;
# Calculations and Results
A1 = N2_1*C/33./(CO2_1 + CO_1); #Air supplied on the basis of conditions at entry to the economiser
A2 = N2_2*C/33./(CO2_2 + CO_2); #Air applied on the basis of conditions at exit
leakage = A2-A1; #Air leakage
print ("Air leakege = %.3f")% (leakage), ("kg of air per kg of fuel")
W_fuel = 0.85; #kg; Weight of fuel pasmath.sing up the chimney
c = 1.05;
T2 = 410.;
T1 = 0.;
W = A1+W_fuel; #Total weight of products
Q1 = W*c*(T2-T1); #Heat in flue gases per kg of coal
Q2 = leakage*1.005*(20-0); #Heat in leakage air
t = (Q1+Q2)/(1.005*leakage + W*1.05);
dT = T2-t;
print ("Fall in temperature as a result of the air leakage into the economiser %.3f")%(dT),("C")
# Variables
w_O2 = 3.*32./46*100./23; #For complete combustion of 1 kg of C2H6O, oxygen required
# Calculations and Results
ratio = w_O2;
print ("A:F ratio = %.3f")%(ratio)
w1 = 88.; #kg
w2 = 54.; #kg
w = w1+w2; #kg
W = 46.; #kg
w_CO2 = w1/W*100;
print ("CO2 produced by fuel %.3f")% (w_CO2), ("%")
w_H2O = w2/W*100;
print ("H2O produced by fuel %.3f")% (w_H2O), ("%")
# C2H2+xO2---->aCO2+bH2O
# Calculations
Amount = 3.076 + 10.12;
# Results
print ("Hence amount of theoretical air required for combustion of 1 kg acetylene = "), (Amount), ("kg")
# C2H2+2.5O2+2.5*(79/21)N2 --> 2CO2+H2O+2.5*(79/21)N2
# Variables
m_CO2 = 3.38; #kg
m_H2O = 0.69; #kg
m_O2 = 3.07; #kg
m_N2 = 20.25; #kg
# Calculations
m_total = m_CO2+m_H2O+m_O2+m_N2;
CO2 = m_CO2/m_total*100;
H2O = m_H2O/m_total*100;
O2 = m_O2/m_total*100;
N2 = m_N2/m_total*100;
# Results
print ("Hence the gravimetric analysis of the complete combustion is : ")
print ("CO2 = %.3f")%(CO2), ("%")
print ("H2O = %.3f")%(H2O), ("%")
print ("O2 = %.3f")% (O2), ("%")
print ("N2 = %.3f")%(N2), ("%")
# Calculations
AF_mole = (12.5+12.5*(79./21))/1;
AF_mass = AF_mole*28.97/(8.*12+1*18);
# Results
print ("Air fuel ratio = %.3f")%(AF_mass), ("kg air/kg fuel")
# C8H18+12.5*O2+12.5*(79/21)N2 --> 8CO2+9H2O+12.5*(79/21)*N2
# C8H18 + (2) (12.5) O2 + (2) (12.5)*(79/21)N2-->8CO2 + 9H2O + (1) (12.5) O2 + (2) (12.5)*(79/21)*N2
# Calculations and Results
m_fuel = 1*(8*12+1*18);
m_air = 2*12.5*(1+79./21)*28.97;
AF = m_air/m_fuel;
print ("(i) Air-fuel ratio = %.3f")%(AF)
print ("(ii) Dew point of the products")
n = 8+9+12.5+2*12.5*(79./21);
x = 9./n;
p = 100.*x;
#Hence
t_dp = 39.7; #0C
print ("t_dp = %.3f")%(t_dp),("°C")
# C2H6 + 3.5O2 → 2CO2 + 3H2O
# Calculations
n = 1.3+0.7+0.9*3.5*(79./21);
CO2 = 1.3/n*100;
CO = 0.7/n*100;
N2 = 11.85/n*100;
# Results
print ("Volumetric analysis of dry products of combustion is as follows ")
print ("CO2 = %.3f")% (CO2), ("%")
print ("CO = %.3f")% (CO), ("%")
print ("N2 = %.3f")% (N2), ("%")
print ("(i) Combustion equation")
# Variables
z = 87.1;
y = z*(79/21.);
x = 10+0.53;
a = 2*x;
#10.53 CH4 + 23.16 O2 + 87.1 N2 → 10.0 CO2 + 0.53 CO + 2.37 O2 + 21.06 H2O + 87.1 N2
print ("CH4 + 2.2 O2 + 8.27 N2 → 0.95 CO2 + 0.05 CO + 2H2O + 0.225 O2 + 8.27 N2")
print ("(ii) Air-fuel ratio ")
AF_mole = 2.2+8.27;
print ("air-fuel ratio on a mole basis = "), (AF_mole), ("moles air/mole fuel")
AF_mass = AF_mole*28.97/(12+1*4);
print ("air-fuel ratio on a mass basis = %.3f")%(AF_mass), ("air/kg fuel")
# CH4 + 2O2 + 2*(79/21)N2 → CO2 + 2H2O + (2)*(79/21)N2
AF_theor = (2+2*(79./21))*28.97/(12+1*4);
print ("theoretical air-fuel ratio = %.3f")% (AF_theor), ("kg air/kg fuel")
theo = AF_mass/AF_theor*100;
print ("(iii) Percent theoretical air = %.3f")%(theo), ("%")
print ("(i) The stoichiometric A/F ratio")
# Variables
a = 0.82/12; # Carbon balance
b = 0.10/2; #Hydrogen balance
x = (2*a+b)/2; # Oxygen balance
# Calculations and Results
Stoichiometric_AF_ratio = 2.976/0.233;
print ("Stoichiometric AF ratio = %.3f")%(Stoichiometric_AF_ratio)
n = a+b+3.76*x;
CO2 = 0.068/n*100;
H2 = 0.05/n*100;
N2 = 3.76*0.093/n*100;
print ("the analysis of the products is")
print ("CO2 = %.3f")%(CO2),("%")
print ("H2 = %.3f")%(H2),("%")
print ("N2 = %.3f")%(N2),("%")
import math
# C + O2 → CO2
# 2H2 + O2 → 2H2O
# S + O2 → SO2
# Variables
O2_req = 2.636; #kg
# Calculations and Results
AF = O2_req/0.233;
print ("The stoichiometric A/F ratio = %.3f")%(AF)
AF_act = AF+0.3*AF;
print ("(i) Actual A/F ratio = %.3f")%(AF_act)
print ("(ii) Wet and dry analyses of products of combustion by volume")
n_wet = 0.5208;
n_dry = 0.5008;
print ("Analysis of wet products is as follows :")
CO2 = 0.0734/n_wet*100;
print ("CO2 = %.3f")%(CO2), ("%")
H2O = 0.0200/n_wet*100;
print ("H2O = %.3f")%(H2O), ("%")
SO2 = 0.0002/n_wet*100;
print ("SO2 = %.3f")% (SO2), ("%")
O2 = 0.0244/n_wet*100;
print ("O2 = %.3f")% (O2), ("%")
N2 = 0.4028/n_wet*100;
print ("N2 = %.3f")%(N2), ("%")
print ("Analysis of dry products is as follows :")
CO2 = 0.0734/n_dry*100;
print ("CO2 = %.3f")% (CO2), ("%")
SO2 = 0.0002/n_dry*100;
print ("SO2 = %.3f")% (SO2), ("%")
O2 = 0.0244/n_dry*100;
print ("O2 = %.3f")%(O2),("%")
N2 = 0.4028/n_dry*100;
print ("N2 = %.3f")%(N2),("%")
# Variables
n_O2 = 0.853; #total moles of O2
# Calculations and Results
AF = n_O2/0.21;
print ("(i) Stoichiometric A/F ratio = %.3f")%(AF)
print ("(ii) Wet and dry analyses of the products of combustion if the actual mixture is 30% weak :")
AF_act = AF+0.3*AF;
n_N2 = 0.79*AF_act;
O2_excess = 0.21*AF_act-n_O2;
n_wet = 5.899;
n_dry = 4.915;
print ("Analysis by volume of wet products is as follows :")
CO2 = 0.490/n_wet*100;
print ("CO2 = %.3f")%(CO2),("%")
H2O = 0.984/n_wet*100;
print ("H2O = %.3f")%(H2O),("%")
O2 = O2_excess/n_wet*100;
print ("O2 = %.3f")%(O2), ("%")
N2 = n_N2/n_wet*100;
print ("N2 = %.3f")%(N2),("%")
print ("Analysis by volume of dry products is as follows :")
CO2 = 0.490/n_dry*100;
print ("CO2 = %.3f")%(CO2), ("%")
O2 = O2_excess/n_dry*100;
print ("O2 = %.3f")%(O2), ("%")
N2 = n_N2/n_dry*100;
print ("N2 = %.3f")%(N2), ("%")
# Calculations and Results
O2_req = 3*32./46;
AF = O2_req/0.233;
print ("Stoichiometric A/F ratio = %.3f")% (AF)
mix = 0.8; #mixture strength
AF_actual = AF/mix;
print ("Actual A/F ratio = %.3f")%(AF_actual),
# C2H6O + 1.25*(3 O2 + 3*79/21 N2) → 2CO2 + 3H2O + 0.25*3O2 + 1.25*3*79/21 N2
n = 2+3+0.75+14.1;
print ("Hence wet analysis is")
CO2 = 2/n*100.;
print ("CO2 = %.3f")%(CO2), ("%")
H2O = 3/n*100.;
print ("H2O = %.3f")%(H2O),("%")
O2 = 0.75/n*100;
print ("O2 = %.3f")%(O2), ("%")
N2 = 14.1/n*100;
print ("N2 = %.3f")%(N2),("%")
nd = 2+0.75+14.1; #total dry moles
print ("Hence dry analysis is : ")
CO2 = 2/nd*100.;
print ("CO2 = %.3f")%(CO2),("%")
O2 = 0.75/nd*100;
print ("O2 = %.3f")%(O2),("%")
N2 = 14.1/nd*100;
print ("N2 = %.3f")% (N2), ("%")
mix = 1.3;
AF_act = AF/mix;
print ("Actual A/F ratio = %.3f")% (AF_act)
print "Hence wet analysis is :"
CO2 = .614/13.678 * 100
print "CO2 = %.2f %%"%CO2
CO = 1.386/13.678 * 100
print "CO = %.2f %%" %CO
H2O = 3/13.678 * 100
print "H2O = %.2f %%" %H2O
N2 = 8.678/13.678 * 100
print "N2 = %.2f %%" %N2
print "Hence dry analysis is :"
CO2 = .614/10.678 * 100
print "CO2 = %.2f %%"%CO2
CO = 1.386/10.678 * 100
print "CO = %.2f %%" %CO
N2 = 8.678/10.678 * 100
print "N2 = %.2f %%" %N2
# C2H6O + 3O2 + 3*79/21 N2 → 2CO2 + 3H2O + 3*79/21 N2
# Variables
R0 = 8.314*10**3; #kJ/kg K
m = 46.; #kg
print ("(i) Volume of reacmath.tants per kg of fuel ")
n = 1+3+3*79./21;
T = 323.; #K
p = 1.013*10**5; #Pa
# Calculations
V = n*R0*T/p;
Vr = V/m;
print ("Vr = %.3f")% (Vr), ("m**3")
print ("(ii) Volume of products per kg of fuel")
n = 2+3+3*79./21;
T = 403.; #K
p = 1*10.**5; #Pa
V = n*R0*T/p;
Vp = V/m;
print ("Vp = %.3f")% (Vp), ("m**3")
# 0.506H2 + 0.1CO + 0.26CH4 + 0.04C4H8 + 0.004O2 + 0.03CO2 + 0.06N2 + 0.21 × 7O2 + 0.79 × 7N2 → a CO2 + b H2O + c O2 + d N2
# Variables
a = 0.1*0.26+4*0.04+0.03;
b = (2*0.506+4*0.26+8*0.04)/2;
c = (0.1+2*0.004+2*0.03+0.21*7*2-2*a-b)/2;
d = (2*0.06+2*0.79*7)/2;
n = 0.55+0.411+5.59;
# Calculations and Results
print ("analysis by volume is")
CO2 = 0.55/n*100;
print ("CO2 = %.3f")%(CO2), ("%")
O2 = 0.411/n*100;
print ("O2 = %.3f")%(O2), ("%")
N2 = 5.59/n*100;
print ("N2 = %.3f")%(N2), ("%")
# C_aH_bO_cN_dS_e
# Variables
a = 60./12;
b = 20.;
c = 5./16;
d = 10./14;
e = 5./32;
p = 5;
q = 20./2;
# Calculations
r = 0.1562;
x = (2*p+q+2*r-0.3125)/2;
s = (0.7143+2*x*79./21)/2;
air = (9.92*32+x*79./21*28)/100;
# Results
print ("Stoichiometric air required = %.3f")%(air), ("kg/kg of fuel")
# C_aH_bO_cN_d
# Variables
a = 84./12;
b = 10.;
c = 3.5/16;
d = 1.5/14;
# C7 H10 O0.218 N0.107 + x O2 + x*(79/21)N2 → p CO2 + q H2O + r N2
p = 7.;
q = 10./2;
x = (2*p+q-c)/2.;
r = (d+2*x*(79./21))/2;
# Calculations and Results
AF = (x*32+x*79/21*28)/100;
print ("(i)Stoichiometric A/F ratio = %.3f")% (AF)
# C7H10O0.218N0.107 + (1.2)(9.39) O2 + (1.2)(9.39)*(79/21)N2 → 7CO2 + 5H2O + (0.2)(9.39) O2 + (1.2)(35.4) N2
n = 7+0.2*9.39+1.2*35.4;
print ("(ii)Percentage composition of dry flue gases by volume is as follows :")
CO2 = 7/n*100.;
print ("CO2 = %.3f")% (CO2), ("%")
O2 = 1.878/n*100;
print ("O2 = %.3f")% (O2), ("%")
N2 = 42.48/n*100;
print ("N2 = %.3f")% (N2), ("%")
# a C + b H + c O2 + (79/21)*c N2 = 8CO2 + 0.5CO + 6.3O2 + x H2O + 85.2N2
# Variables
a = 8+0.5;
c = 85.2/(79./21);
x = 2*(c-8-0.5/2-6.3);
b = 2*x;
# Calculations and Results
AF = (c*32+(79./21)*c*28)/(a*12+b*1);
print ("(i) Air-fuel ratio = %.3f")% (AF), ("kg of air/kg of fuel")
mf_C = 12*a/(12.*a+b);
mf_H2 = b*1/(12.*a+b);
air = mf_C*8./3*100./23.3 + mf_H2*8*100/23.3; #air required for complete combustion
percent = AF/air*100.;
print ("(ii)Per cent theoretical air required for combustion = %.3f")% (percent), ("%")
print ("(i) By a carbon balance")
# Calculations and Results
# a C8H18 + 78.1N2 + 78.1*(21/79)O2 → 8.9CO2 + 8.2CO + 4.3H2 + 0.5CH4 + 78.1N2 + x H2O
a = (8.9+8.2+0.5)/8;
AF1 = (78.1*28+78.1*21./79*32)/a/(8*12+1*18);
print ("Air fuel ratio = %.3f")% (AF1)
print ("(ii) By a hydrogen-oxygen balance ")
# a C8H18 + b O2 + b*(79/21)N2 → 8.9CO2 + 8.2CO + 4.3H2 + 0.5CH4 + b*(79/21)N2 + x*H2O
a = (8.9+8.2+0.5)/8;
x = (18*a-4.3*2-4*0.5)/2;
b = (8.9*2+8.2+x)/2;
AF2 = (b*32+b*(79./21.)*28.)/a/(8.*12+1*18);
print ("Air fuel ratio = %.3f")% (AF2)
# X(0.88/12 C + 0.12/2 H2) + Y O2 + 79/21*Y N2 → 0.12CO2 + a O2 + (0.88 – a) N2 + b H2O
# Variables
X = 0.12/(0.88/12);
b = 0.06*X;
a = 0.0513;
Y = 0.2203;
# Calculations
Air_supplied = 0.2203*32/0.233;
AF = Air_supplied/X;
# Results
print ("A/F ratio = %.3f")% (AF)
# X*(x/12 C + y/2 H2) + Y O2 + 79/21*Y/N2 → 0.15CO2 + 0.03CO + 0.03CH4 + 0.01H2 + 0.02O2 + a H2O + 0.76N2
# Variables
Y = 0.76/(79./21);
a = 2*(Y-0.15-0.03/2-0.02);
Xx = 12*(0.15+0.03+0.03);
Xy = 2*(2*0.03+0.01+a);
# Calculations
ratio = Xx/Xy;
# Results
print ("Ratio of C to H2 in fuel = %.3f")% (ratio)
# Variables
h_fg0 = 2441.8; #kJ/kg
m = 3.*18;
dH0_liq = -3301000.; #kJ/mole
# Calculations
dH0_vap = dH0_liq+m*h_fg0;
# Results
print ("dH0_vapour = %.3f")% (dH0_vap), ("kJ/mole")
# Variables
# C6H6 + 7.5O2 → 6CO2 + 3H2O (vapour)
dH0 = -3169100.; #kJ
n_R = 1+7.5;
n_P = 6+3;
R0 = 8.314;
T0 = 298.; #K
# Calculations
dU0 = (dH0-(n_P-n_R)*R0*T0)/(6*12+1*6);
# Results
print ("dU0 = %.3f")% (dU0), ("kJ/kg")
# CO+1/2 O2 → CO2
import math
# Variables
H_R0 = 1*9705+1/2*9696; #kJ
H_RT = 1*94080+1/2*99790; #kJ
H_P0 = 1*10760; #kJ
H_PT = 1*149100; #kJ
# Calculations
dH_T = -(285200+(143975-14553)-(149100-10760));
# Results
print ("dH_T = "), (dH_T), ("kJ/mole")
print ("(i) Higher heating value at consmath.tant pressure")
# Variables
m = 4.*18;
h_fg = 2443.; #kJ/kg
LHVp = 2044009.; #kJ/kg
R0 = 8.3143; #kJ/kg K
T = 298.; #K
# Calculations and Results
HHVp = LHVp+m*h_fg;
print ("HHVp = "), (HHVp), ("kJ/kg")
print ("(ii) Higher heating value at consmath.tant volume")
dn = 3-(1+5.);
HHVv = HHVp+dn*R0*T;
print ("HHVv = "), (HHVv), ("kJ/kg")
# Variables
HHV = 5494977.; #kJ/kg
m = 9.*18;
u_fg = 2305.; #kJ/kg
# Calculations
LHVv = HHV-m*u_fg;
# Results
print ("LHVv = "), (LHVv), ("kJ/kg")
print ("(i) Air and benzene vapour ")
# C6H6(g) + 7.5O2(g) + 7.5*(79/21)N2(g) = 6CO2(g) + 3H2O(g) + 7.5*(79/21)*N2(g)
# Variables
LHVp = 3169500.; #kJ/mole
m = 54.; #kg/kg mole of fuel
h_fg = 2442.; #kJ/kg
# Calculations and Results
LHVv = round(LHVp/((12*6+6*1)+(7.5*32)+7.5*(79./21)*28))
print ("LHVv per kg of mixture = %d")% (LHVv), ("kJ/kg")
HHVp = (LHVp+m*h_fg)/(78+240+790);
print ("HHVp per kg of mixture = %.0f")% (HHVp), ("kJ/kg")
print ("(ii) Air and octane vapour ")
LHVp = 5116200.; #kJ/mole of C8H18
# C8H18(g) + 12.5O2(g) → 8CO2(g) + 9H2O(g) + 12.5*(79/21)N2(g)
LHVp1 = LHVp/((12*8+18*1)+12.5*32+12.5*79./21*28);
print ("LHVp per kg of mixture = %d")% (LHVp1), ("kJ/kg")
m = 9*18.;
HHVp = LHVp+m*h_fg;
HHVp1 = HHVp/(114.+400+1317);
print ("HHVp per kg of mixture = %d")% (HHVp1), ("kJ/kg")
# Variables
m_CO2 = 44./12*0.88; #kg
m_H2O = 18/2*0.12; #kg
u_fg = 2304.; #kJ/kg
h_fg = 2442.; #kJ/kg
HHVv = 45670.; #kJ/kg
R0 = 8.3143; #kJ/kg K
T = 298.; #K
# Calculations and Results
LHVv = HHVv-m_H2O*u_fg;
print ("(i) (LHV)v = "), (LHVv), ("kJ/kg")
print ("(ii) (HHV)p, (LHV)p")
#1 mole fuel+x/32 O2-->3.23/44 CO2 + 1.08/18 H2O
x = 32*(m_CO2/44+m_H2O/18./2.);
# 1 kg fuel + 3.31 kg O2 = 3.23CO2 + 1.08H2O
dn = (m_CO2/44-x/32);
HHVp = HHVv-dn*R0*T;
print ("HHVp = %.3f")% (HHVp), ("kJ/kg")
LHVp = HHVp-m_H2O*h_fg;
print ("LHVp = %.3f")% (LHVp), ("kJ/kg")