Anda di halaman 1dari 1

Sol.

1 (B) Matlab Code:


format long;

hf_CO=-110541;%enthalpy of formation of CO at 298 K


hf_CO2=-393546;%enthalpy of formation of CO2 at 298 K

a=[.02275724e2 .09922072e-1 -.10409113e-4 .06866686e-7 -.02117280e-10;


.04453623e2 .03140168e-1 -.12784105e-5 .02393996e-8 -.16690333e-13];
% curve fit coefficients of specific heat constant for CO2

b=[.03298677e2 .14082404e-2 -.03963222e-4 .05641515e-7 -.02444854e-10;


.02926640e2 .14879768e-2 -.05684760e-5 .10097038e-9 -.06753351e-13];
% curve fit coefficients of specific heat constant for N2

syms T Tad

cp_dT_CO2 = 8.314*(int(a(1,1)+(a(1,2)*T)+(a(1,3)*T^(2))+(a(1,4)*T^(3))+(a(1,5)*T^(4)), 298,


1000)+int(a(2,1)+(a(2,2)*T)+(a(2,3)*T^(2))+(a(2,4)*T^(3))+(a(2,5)*T^(4)), 1000, Tad));
% integrating cp first from 298 to 1000 and then from 1000 to Tad for CO2

cp_dT_N2 = 8.314*(int(b(1,1)+(b(1,2)*T)+(b(1,3)*T^(2))+(b(1,4)*T^(3))+(b(1,5)*T^(4)), 298,


1000)+int(b(2,1)+(b(2,2)*T)+(b(2,3)*T^(2))+(b(2,4)*T^(3))+(b(2,5)*T^(4)), 1000, Tad));
% integrating cp first from 298 to 1000 and then from 1000 to Tad for N2

H_reac=hf_CO;

H_prod=hf_CO2+cp_dT_CO2+1.88*cp_dT_N2;

eqn1=H_reac-H_prod;

eqn2=H_reac-H_prod-(8.314*(3.38*298-2.88*Tad));

Tad_constpressure=solve(eqn1==0)
%Adiabatic Flame temperature for constant pressure condition

Tad_constvolume=solve(eqn2==0)
%Adiabatic Flame temperature for constant volume condition

Output:
Tad_constpressure= 2663.474469
Tad_constvolume= 3178.078240

Anda mungkin juga menyukai