Sei sulla pagina 1di 33

PROJECT REPORT

ON
Development of multizone constant volume
premixed Combustion Model

M.Tech (Thermal Engineering)


Dept. of Mechanical Engineering
IIT DELHI

Submitted by : GAURAV PUNDIR Supervisor: Dr. ANJAN RAY


(2018MET2273) Co- Supervisor: Dr. MR RAVI

1
ABSTRACT

Laminar Burning Velocity is an important property of a combustible mixture. Due to its


importance, different methods have been developed and used to measure the Laminar
Burning Velocity for Spark Ignition engines, burners, explosions and the calibration of
chemical kinetics based models of flame propagation. Constant volume combustion vessel is
also in common use due to its various advantages, and has two distinct methods of use: either
the imaging of flame front propagation at conditions of constant pressure, or the measurement
of the pressure rise combined with a constant volume combustion model.
Constant volume combustion vessels are used for producing spherically propagating flames
by central ignition, usually spark ignition via a pair of electrodes results in a spherical flame
propagating outwards through the unburned mixture. A multiple burned gas zone model has
to be used to determine the temperature distribution, pressure rise with mass fraction burned.
A constant volume experimental facility is available for generating data for the fuels such as
methane, ethane, and propane.
The existing data in the literature are not adequate/accurate for high pressure, high
temperature conditions. The constant volume combustion method have inaccuracies in model
and lack of stretch correction .In this project both these aspects will be looked into.

KEY WORDS: Laminar Burning Velocity (LBV) · Constant-volume combustion method ·


Spherical flame · Multiple Burned Gas zone model.

2
Contents
Abstract……………………………………………………………………………………………… 2
List of symbols........................................................................................................................................ 4
Subscripts ............................................................................................................................................ 4
INTRODUCTION .................................................................................................................................. 5
METHOD ............................................................................................................................................... 7
Methodology of Combustion Properties Measurements ..................................................................... 7
Theoretical Model ............................................................................................................................... 8
BOMB program inputs: ................................................................................................................ 10
BOMB program output: ................................................................................................................ 10
DISCUSSION ....................................................................................................................................... 12
Calculation of Combustion Properties .............................................................................................. 12
Modelling .............................................................................................................................................. 11
MATLab Programs ........................................................................................................................... 11
Work done......................................................................................................................................... 11
Results ................................................................................................................................................... 14
.............................................................................................................................................................. 14
.............................................................................................................................................................. 14
CONCLUSION ..................................................................................................................................... 16
Appendix A ........................................................................................................................................... 17
MATLab programs : ..................................................................................................................... 17
REFERENCES ..................................................................................................................................... 33

3
List of symbols
A inside surface area of the vessel
B inside diameter of the vessel
cp specific heat
e specific internal energy
E internal energy
h specific enthalpy
h heat transfer coefficient
K stretch rate
m mass
P pressure
Q heat transfer
r radius
S entropy
Su burning velocity
T temperature
v specific volume
V volume
x mass fraction burned

Subscripts

b burned
o,I initial condition
u unburned condition
w wall

4
INTRODUCTION

Experiments involving constant volume combustion vessels date back to the work of
Hopkinson [1], who measured the pressure rise during combustion. Hopkinson also identified
the temperature gradient in the burned gas (about 500 K), though only recently has the pressure
rise method taken account of the temperature gradient in the burned gas. Early examples of
constant pressure flame speed measurements include the soap bubble method used by Stevens
[2], in which a flammable mixture was ignited within a boundary which was free to move,
preventing compression of the unburned gas ahead of the flame front as the flame propagates
ahead of the expanding burned gas. By maintaining constant pressure, the flame speed can be
evaluated using photography of the flame front.

The burning velocity, Su, is more precisely defined as the velocity at which unburned gases move
through the combustion wave in the direction normal to the wave surface. Laminar burning velocity
data are of great significance and are used in various combustion science such as in heat release
rates, explosion predictions, and burner design. They also play an important role in determining
aspects of the combustion process in Spark Ignition (SI) engines such as ignition delay, the
minimum ignition energy etc. Also, developments in engine technology requires the
understanding of combustion performance of fuels, to provide input parameters for models
used in technological development.

The laminar burning velocity is a fundamental property of a propagating premixed fuel-air


flame that primarily depends on the mixture temperature, pressure, equivalence ratio and fuel
compositions. Insight to the properties such as propagation rates, emission characteristics can
also be given by the knowledge of Laminar Burning Velocity. Also, in internal combustion
engines the initial combustion is laminar, so again there is a need for the laminar burning velocity.

Majorly there are two aspects of this project, one is to produce accurate experimental data on
laminar premixed flames and the other is to generate a computer code based on the energy and
volume conservation for the calculation of Burning velocity. Although the majority of fuel is
probably burnt in turbulent combustion, laminar burning velocity data are still needed as inputs
to many turbulent combustion models.

There are several competing methods for determination a laminar burning velocity. These
methods are divided into two classes: stationary and non-stationary flame methods. The
constant volume method is considered to be one of the prominent method. The constant-volume
bomb method uses a spherical vessel with central ignition and relies on measurements taken
after the early stages of flame propagation, during which there is a significant pressure rise.
The advantage of measuring the burning velocity using the closed vessel over other methods
is that, from a single test, burning velocities can be calculated over a wide range of temperatures
and pressures. Lewis and von Elbe [4] were first to derive burning velocities from pressure

5
measurements alone, by using a linear assumption between mass fractions burned and pressure
rise, so as to estimate the radius of the flame during combustion.

Metghalchi and Keck [5] developed a subsequent model based on the mass burning rate, and
introduced a two zone numerical model in which the gas in the vessel is divided into burned
and unburned gas zones separated by a thin flame front, and the equations of conservation of
energy and volume are solved numerically. Of all the models Lewis and von Elbe’s (1934) [4]
method is the most simple and Metghalchi and Keck’s (1980) [5] is the most comprehensive.
Significant work in this field is also done by Dr. Khizer Saeed [6], University of Oxford. In the
early stage of this project understanding toward the subject is developed primarily by his work.

6
METHOD

Methodology of Combustion Properties Measurements

In multi zone model, the mass inside the vessel is initially divided into a number of zones,
which can be of either equal radius or equal mass. Each zone is then divided further into a
number of elemental shells. The total number of elemental shells in the vessel corresponds to
the number of time-steps chosen in one simulation, with flame front propagation seen as the
consecutive consumption of the elemental shells. The equations of conservation of volume and
internal energy are solved as first order differential equations of the pressure and unburned gas
temperature in the vessel. The formulation is based upon the approach of Ferguson [7], and
Raine et al. [8].

This model then allow the determination of burning velocities from the pressure record over
the range of pressures and temperatures encountered during combustion. Advantages of the
constant volume vessel technique include the ability to obtain data over an increased range of
temperatures and pressures, as well as the ability to obtain a large number of data points from
a single experiment. These advantages led Rallis and Garforth [9] to describe the constant
volume technique as “the most versatile and accurate” of the propagating flame methods. The
ability to obtain such quantities of data also lends itself well to the fitting of burning velocity
correlations. However, there are commonly objections to the technique, because the effects of
flame stretch are ignored, and that without optical access, it becomes difficult to determine the
onset of any flame front instabilities, (which violates the assumption of a smooth flame front
and invalidates calculations of the burning velocity). Thus flame stretch is to be considered on
later stages of this project.

Fig 2: Radial distribution of the multiple zones inside a spherical vessel. (a) Equal mass model (EQM);
(b) Equal radius model (EQR) (Hatched portion indicates the position of the flame front at a particular
instant). [11]

7
Theoretical Model

The combustion experiments with the constant-volume test facility provide P vs. t (pressure
vs time) data for the fuel-air mixture. However, determination of the key combustion properties
by utilizing the obtained P vs t data from the experiments requires a comprehensive theoretical
model that represents the combustion process inside the test-cell.

In this project, a novel multiple-zones model developed by Saeed and Stone has to be
implemented to determine the Laminar Burning Velocity from closed-vessel combustion and
also mass fraction burned, flame growth rate, unburned temperature, etc. will be determined.
In the multiple-zones model, flame propagation is seen as the consecutive consumption of the
unburned mixture within the zones, as shown in Figure 3. Before ignition, the mass in the
spherical vessel is divided into N zones (‘N’ may vary depending on the required accuracy and
computational time). At the time when combustion has just begun in the test cell, the flame
front will consume zone one first therefore, the temperature and hence pressure of zone one
will increase, thereby compressing the rest of the unburned gas (considered as a single entity)
and increasing the pressure inside the closed vessel. After the consumption of the first zone,
combustion of the second and subsequent zones will take place at a higher pressure than initial
pressure. As a result temperature and density gradient is established in the burned gas region.

The multiple-zones model assumes outward propagation of a smooth, spherical flame front
separating the unburned and burned gas, and, using the conservation of volume and energy in
the vessel, a set of ordinary differential equations for the rate of change of pressure, burned,
and unburned gas temperatures for a multiple-zones model were derived:

………………. (1)

... (2)

Where P is the pressure, t is the time, T is the temperature, Cp,u is the specific heat, x is the
mass fraction burned, V is the total volume, v is the specific volume, h is the heat transfer
coefficient, and m is the mass.

8
Fig 3: Multiple zones model used determination of Laminar Burning Velocity for constant volume
combustion. [10]

.. (3)

………………………. (a)

………………………………………………… (b)

………………………………… (c)

…………………….. (d)

9
Subscripts u, b, i, and w indicate the unburned, burned, individual burned zones, and wall,
respectively. The above model has to be solved computationally.

In the BOMB program, since the burnt gas in each zone will be at a different temperature, it
will have a different composition. The equilibrium combustion calculations are solved by
minimization of the Gibbs free energy.

BOMB program inputs:

The BOMB program takes the following input:

 Fuel type.
 Composition of air.
 Number of zones.
 Initial temperature.
 Pressure.
 Equivalence ratio.
 Humidity.
 Residual or diluents.

BOMB program output:

The BOMB program outputs the following for each step of mass fraction burned:

 Pressure.
 Unburned and burned gas temperature in each zone.
 Volume and radius of individual zones.
 Burned gas products in each zone.
 Flame radius

The above outputs are used to determine the experimental values of various
combustion characteristics.

10
Modelling
The time-based experimental data of Pressure obtained from the test experiments and the mass
fraction burned based outputs of the multiple-zones model from the BOMB program are input
into the specially developed post-processing program. This program integrates the given inputs
and calculates outputs for the time-dependent measurements of mass fraction burned, pressure,
flame radius, flame growth rate, laminar burning velocity, burned and unburned gas
temperature.
Saeed and Stone [6] developed program BURNVEL for the purpose. Although these programs
are not commercially viable and development of these programs is an important aspect of this
project. So, my objective for this project is to develop a program for the solution of the
differential equations obtained by the energy and volume conservation.

MATLab Programs

In the program, since the burnt gas and unburnt gas are at different temperatures, they each
have a different composition. At each temperature the composition of the gases is solved for
equilibrium among the following species:
CO, CO2, H2O, H2, H, OH, O, N2, NO, and O2.
These equilibrium calculations are solved by using Equilibrium Constant Method, using the
data from Gordon and McBride [12].
The gases are assumed to behave as semi perfect gases, and the internal energy, entropy, and
specific heat capacities are calculated from the polynomial functions for the specific heat
capacity at different temperatures.

Work done

The assumptions and a mathematical derivation of the time-dependent first order ordinary
differential equations for the pressure and burned and unburned gas temperatures are presented
previously for the two-burned-gas-zone model, and the detailed derivation was provided.

Modelling for a two burned zone combustion model is done, although, experimental setup is
not ready yet, so correlations for Pressure – time data is used. Four sub programs, required for
the Burned mass fraction vs time (x-t) , Burned zone temperature vs time (Tb – t ) and Unburned
gas temperature vs time (Tu - t) relations , which from further processing can give the Laminar
burning velocity and other key relations of constant volume bomb combustion. The post
processing of these obtained results is to be done in future.
Programs are listed in Appendix A.

11
DISCUSSION

Calculation of Combustion Properties

Determination of the combustion characteristics of the premixed flame inside the


spherical closed vessel will be done by filling it with a homogeneous combustible
mixture. Primarily methane, ethane and propane is selected as the fuel in this project.
At time t = 0, the mixture is ignited at the center, and a spherical flame front is
established instantaneously, which begins to propagate outwardly to reach the wall as
shown in Figure 4. Considering an elemental shell of thickness dri at radius ri, if, during
the travel of the flame through the vessel, the burned gas had not expanded, then an
element dri would be the thickness of a shell at the temperature Ti, and pressure Pi,
which is then traversed by the wave with the laminar burning velocity S u in the time
element dt. This expansion results in the radius of the shell increasing from ri to rb, with
the pressure changing to P and the temperature of the shell becoming Tu. The values of
Su, x, ri, rb, vb as a function of time were determined by the equations proposed above

…………… (B)

…………………. (e)

Fig 4: Position of the elemental shell (a) before burning and (b) after burning. [6]

12
Pressure, mass fraction burned, burning velocity,
burned/unburned gas temperature etc.

Fig 5: Schematic representation of the method used for the determination of combustion
properties. [10]

13
Results

Fig 6 : Burn Fraction (X) vs Time (t) plot.

Fig 7 : Pressure (P) vs Time (t) plot.

14
Fig 8 : Unburned Gas Temperature (Tu) vs Time (t) plot.

Fig 9 : Burned Gas temperature (Tb) vs Time (t) plot.

15
CONCLUSION
The laminar burning velocity is one of the fundamental properties of a reacting
premixed mixture and its reliable data are constantly needed for combustion
applications. So far, several techniques for measuring the laminar burning velocity have
been used, and for a wide range of temperature, pressure, and fuel rather accurate
measurements have been obtained. In this project, a spherical combustion vessel has
been used with systems for fuel injection, ignition, experiment control, data acquisition
and high speed schlieren photography. Conservation Equation of mass and energy
needed to be solved simultaneously, to get the desired variation of temperature and
pressure with respect to time and their post processing will lead to the determination of
laminar burning velocity.

This study focuses on the accurate determination of the laminar burning velocities of
fuels using multi zone model. Literature review of those techniques is done, focusing
primarily on the Constant Volume vessel method. Two zone model partial
programming is done, and understanding of multi zone model is also developed.

16
Appendix A

MATLab programs :

1. Fuel.m (computes the fuel properties)

function [ alpha, beta, h, cp, mw, Fs, q ] = fuel( id, T )

% id - 1=Methane
% T - Temperature (K) at which to eval 300<T<1000 K

% Outputs
% alpha - # carbon
% beta - # hydrogen
% h - specific enthalpy (kJ/kg)
% s - specific entropy (kJ/kgK)
% cp - specific heat (kJ/kgK)
% mw - molecular weight (kg/kmol)
% Fs - stoichiometric fuel-air ratio
% q - heat of combustion (kJ/kg)

% curve fit coefficients for thermodynamic properties of selected fuels


% a1 a2 a3 a6
FuelProps = [ 1.971324, 7.871586e-3, -1.048592e-06, -9.930422e+3
]; ... % Methane

% Fuel chemical formula


% C H
% alpha beta
FuelInfo = [ 1 4 ]; ... % Methane

% stoichiometric fuel-air ratio


FSv = [ 0.0582 ];
% available energy of combustion ac
ac = [ 52420 ];

% stoichiometric fuel-air ratio


Fs = FSv(id);

% available energy
q = ac(id);

% Get fuel composition


alpha = FuelInfo(id, 1);
beta = FuelInfo(id, 2);

% compute fuel properties


ao = FuelProps(id, 1);
bo = FuelProps(id, 2);
co = FuelProps(id, 3);
do = FuelProps(id, 4);

17
% compute thermodynamic properties
h = ao + bo/2*T +co/3*T^2 +do/T;

cp = ao + bo*T + co*T^2;

% Calculate molecular weight of fuel


mw = 12*alpha + 1*beta ;

2. Farg.m (computes unburnt mixture’s properties)

function [Y, h, u, v, R, Cp, MW, dvdT, dvdP] = farg( T, P, phi, fuel_id )

% T - temperature (K)
% P - pressure (kPa)
% phi - equivalence ratio
% fuel_id - 1=Methane
%
% outputs:
% y - mole fraction of constituents
% y(1) : CO2
% y(2) : H2O
% y(3) : N2
% y(4) : O2
% y(5) : CO
% y(6) : H2
% dvdt - (dv/dT) at const P, m3/kg per K
% dvdp - (dv/dP) at const T, m3/kg per kPa

[ alpha, beta, h_fuel, cp_fuel, m_fuel ] = fuel( fuel_id, T );

% curve fit coefficients for thermodynamic properties 300 < T < 1000 K

A = [ [ 0.24007e+1, 0.8735e-2, -0.6607e-5, 0.2002e-8, 0.63274039e-15,


-0.4837e+5, 0.96951457e+1 ]; ... % CO2

[ 0.40701e+1, -0.11084e-2, 0.4152e-5, -0.296374e-8, 0.80702e-12,


-0.30279722e+5, -0.32270046 ]; ... % H2O

[ 0.36748e+1, -0.12081e-2, 0.23240e-5, -0.63217e-9, -0.2257e-12,


-0.1061e+4, 0.23580e+1 ]; ... % N2

[ 0.3625e+1, -0.1878e-2, 0.70554e-5, -0.676351e-8, 0.21555993e-11,


-0.10475226e+4, 0.43052778e+1 ]; ... % O2

[ 0.37100928e+1, -0.161909e-2, 0.369235e-5, -0.203196e-8,


0.23953e-12, -0.143563e+5, 0.2955e+1 ]; ... % CO

[ 0.30574e+1, 0.2676e-2, -0.58099162e-5, 0.55210391e-8, -


0.1812273e-11, -0.98890474e+3, -0.229970e+1 ] ]; % H2

% molar mass of constituents


% CO2 H2O N2 O2 CO H2
Mi = [ 44, 18, 28, 32, 28, 2 ];

18
% stoichiometric molar air-fuel ratio
a_s = alpha + beta/4 ;

% mole fraction of fuel, O2, N2


y_1 = 1 / (1 + 4.76*a_s/phi); % mole fraction for one mole of reactant
y_fuel = y_1; % assuming 1 mole fuel
y_O2 = a_s/phi * y_1; % a_s/phi moles O2
y_N2 = a_s/phi*3.76 * y_1; % a_s/phi * 3.76 moles N2

Y = zeros(6,1);

Y(3) = Y(3) + y_N2*(1);


Y(4) = Y(4) + y_O2*(1);

% compute properties of mixture


h = h_fuel*y_fuel;

Cp = cp_fuel*y_fuel;

MW = m_fuel*y_fuel;

% compute component properties according to curve fits


cpo = zeros(6,1);
ho = zeros(6,1);

for i=1:6
cpo(i) = A(i,1) + A(i,2)*T + A(i,3)*T^2 + A(i,4)*T^3 + A(i,5)*T^4;
ho(i) = A(i,1) + A(i,2)/2*T + A(i,3)/3*T^2 + A(i,4)/4*T^3 +A(i,5)/5*T^4
+ A(i,6)/T;

end

for i=1:6
if(Y(i)>1.e-25)
h = h + ho(i)*Y(i);

Cp = Cp+cpo(i)*Y(i);
MW = MW + Y(i)*Mi(i);
end
end

R = 8.31434/MW; % compute mixture gas constant


h = R*T*h; % curve fit for h is h/rt
u = h-R*T;
v = R*T/P;
Cp = R*Cp; % curve fit for cp is cp/r
dvdT = v/T;
dvdP = -v/P;

19
3. ECP.m (Equilibrium composition calculator, computes burned gas properties)
function [ierr, Y, h, u, v, R, Cp, MW, dvdT, dvdP] = ecp( T, P, phi, ifuel
)
% Equilibrium Combustion Products
%
% inputs:
% T - temperature (K) [ 600 --> 3500 ]
% P - pressure (kPa) [ 20 --> 30000 ]
% phi - equivalence ratio [ 0.01 --> 3 ]
% ifuel - 1=Methane
%
% outputs:
% ierr - Error codes:
% 0 = success
% 1 = singular matrix
% 2 = maximal pivot error in gaussian elimination
% 3 = no solution in maximum number of iterations
% 4 = result failed consistency check sum(Y)=1

% 7 = maximum iterations reached in initial guess solution


% 8 = temperature out of range
% 9 = pressure out of range
% 10 = equivalence ratio too lean
% 11 = equivalence ratio too rich, solid carbon will be formed
for given fuel
%
% y - mole fraction of constituents
% y(1) : CO2
% y(2) : H2O
% y(3) : N2
% y(4) : O2
% y(5) : CO
% y(6) : H2
% y(7) : H
% y(8) : O
% y(9) : OH
% y(10) : NO

% initialize outputs
Y = zeros(10,1);
h = 0;
u = 0;
v = 0;
R = 0;
Cp = 0;
MW = 0;
dvdT = 0;
dvdP = 0;

% solution parameters
prec = 1e-3;
MaxIter = 20;

% square root of pressure (used many times below)


PATM = P/101.325;
sqp = sqrt(PATM);

if ( T < 600 || T > 3500 )


ierr = 8;

20
return;
end

if ( P < 20 || P > 30000 )


ierr = 9;
return;
end

if ( phi < 0.01 )


ierr = 10;
return;
end

% Get fuel composition information


[ alpha, beta ] = fuel( ifuel, T );

% Equilibrium constant curve fit coefficients.


% Valid in range: 600 K < T < 4000 K
% Ai Bi Ci Di Ei
Kp = [ [ 0.432168, -0.112464e+5, 0.267269e+1, -0.745744e-4,
0.242484e-8 ]; ...
[ 0.310805, -0.129540e+5, 0.321779e+1, -0.738336e-4,
0.344645e-8 ]; ...
[ -0.141784, -0.213308e+4, 0.853461, 0.355015e-4, -
0.310227e-8 ]; ...
[ 0.150879e-1, -0.470959e+4, 0.646096, 0.272805e-5, -
0.154444e-8 ]; ...
[ -0.752364, 0.124210e+5, -0.260286e+1, 0.259556e-3, -
0.162687e-7 ]; ...
[ -0.415302e-2, 0.148627e+5, -0.475746e+1, 0.124699e-3, -
0.900227e-8 ] ];

K = zeros(6,1);
for i=1:6
log10ki = Kp(i,1)*log(T/1000) + Kp(i,2)/T + Kp(i,3) + Kp(i,4)*T +
Kp(i,5)*T*T;
K(i) = 10^log10ki;
end

c1 = K(1)/sqp;
c2 = K(2)/sqp;
c3 = K(3);
c4 = K(4);
c5 = K(5)*sqp;
c6 = K(6)*sqp;

[ ierr, y3, y4, y5, y6 ] = guess( T, phi, alpha, beta, c5, c6 );

if ( ierr ~= 0 )
return;
end

a_s = alpha + beta/4 ;

21
D1 = beta/alpha;
D2 = 2*a_s/(alpha*phi);
D3 = 2*3.7619047619*a_s/(alpha*phi);
A = zeros(4,4);

final = 0;

for jj=1:MaxIter

sqy6 = sqrt(y6);
sqy4 = sqrt(y4);
sqy3 = sqrt(y3);

y7= c1*sqy6;
y8= c2*sqy4;
y9= c3*sqy4*sqy6;
y10= c4*sqy4*sqy3;
y2= c5*sqy4*y6;
y1= c6*sqy4*y5;

d76 = 0.5*c1/sqy6;
d84 = 0.5*c2/sqy4;
d94 = 0.5*c3*sqy6/sqy4;
d96 = 0.5*c3*sqy4/sqy6;
d103 = 0.5*c4*sqy4/sqy3;
d104 = 0.5*c4*sqy3/sqy4;
d24 = 0.5*c5*y6/sqy4;
d26 = c5*sqy4;
d14 = 0.5*c6*y5/sqy4;
d15 = c6*sqy4;

% form the Jacobian matrix


A = [ [ 1+d103, d14+d24+1+d84+d104+d94, d15+1, d26+1+d76+d96 ]; ...
[ 0, 2.*d24+d94-D1*d14, -D1*d15-D1, 2*d26+2+d76+d96;
]; ...
[ d103, 2*d14+d24+2+d84+d94+d104-D2*d14, 2*d15+1-D2*d15-D2,
d26+d96 ]; ...
[ 2+d103, d104-D3*d14, -D3*d15-D3,0 ] ];

if ( final )
break;
end

B = [ -(y1+y2+y3+y4+y5+y6+y7+y8+y9+y10-1); ...
-(2.*y2 + 2.*y6 + y7 + y9 -D1*y1 -D1*y5); ...
-(2.*y1 + y2 +2.*y4 + y5 + y8 + y9 + y10 -D2*y1 -D2*y5); ...
-(2.*y3 + y10 -D3*y1 -D3*y5) ];

[ B, ierr ] = gauss( A, B );
if ( ierr ~= 0 )
return;
end

y3 = y3 + B(1);
y4 = y4 + B(2);
y5 = y5 + B(3);
y6 = y6 + B(4);

nck = 0;

22
if ( abs(B(1)/y3) > prec )
nck = nck+1;
end
if ( abs(B(2)/y4) > prec )
nck = nck+1;
end
if ( abs(B(3)/y5) > prec )
nck = nck+1;
end
if ( abs(B(4)/y6) > prec )
nck = nck+1;
end

if( nck == 0 )

final = 1;
continue;
end
end

if (jj>=MaxIter)
ierr = 3;
return;
end

Y = [ y1 y2 y3 y4 y5 y6 y7 y8 y9 y10 ];

% consistency check
if( abs( sum(Y)-1 ) > 0.0000001 )
ierr = 4;
return;
end

% constants for partial derivatives of properties


dkdt = zeros(6,1);
for i=1:6
dkdt(i) = 2.302585*K(i)*( Kp(i,1)/T - Kp(i,2)/(T*T) + Kp(i,4)
+2*Kp(i,5)*T );
end

dcdt = zeros(6,1);
dcdt(1) = dkdt(1)/sqp;
dcdt(2) = dkdt(2)/sqp;
dcdt(3) = dkdt(3);
dcdt(4) = dkdt(4);
dcdt(5) = dkdt(5)*sqp;
dcdt(6) = dkdt(6)*sqp;

dcdp = zeros(6,1);
dcdp(1) = -0.5*c1/P;
dcdp(2) = -0.5*c2/P;
dcdp(5) = 0.5*c5/P;
dcdp(6) = 0.5*c6/P;

x1 = Y(1)/c6;
x2 = Y(2)/c5;
x7 = Y(7)/c1;

23
x8 = Y(8)/c2;
x9 = Y(9)/c3;
x10 = Y(10)/c4;

dfdt(1) = dcdt(6)*x1 + dcdt(5)*x2 + dcdt(1)*x7 +dcdt(2)*x8 +dcdt(3)*x9 +


dcdt(4)*x10;
dfdt(2) = 2.*dcdt(5)*x2 + dcdt(1)*x7 + dcdt(3)*x9 -D1*dcdt(6)*x1;
dfdt(3) = 2.*dcdt(6)*x1 + dcdt(5)*x2 + dcdt(2)*x8 +dcdt(3)*x9 + dcdt(4)*x10
- D2*dcdt(6)*x1;
dfdt(4) = dcdt(4)*x10 -D3*dcdt(6)*x1;

dfdp(1) = dcdp(6)*x1 + dcdp(5)*x2 + dcdp(1)*x7 +dcdp(2)*x8;


dfdp(2) = 2.*dcdp(5)*x2 + dcdp(1)*x7 -D1*dcdp(6)*x1;
dfdp(3) = 2.*dcdp(6)*x1 + dcdp(5)*x2 + dcdp(2)*x8 - D2*dcdp(6)*x1;
dfdp(4) = -D3*dcdp(6)*x1;

% solve matrix equations for independent temperature derivatives


b = -1.0 .* dfdt'; %element by element mult.
[b, ierr] = gauss(A,b);% solve for new b with t derivatives
if ( ierr ~= 0 )
return;
end
dydt(3) = b(1);
dydt(4) = b(2);
dydt(5) = b(3);
dydt(6) = b(4);
dydt(1) = sqrt(Y(4))*Y(5)*dcdt(6) + d14*dydt(4) + d15*dydt(5);
dydt(2) = sqrt(Y(4))*Y(6)*dcdt(5) + d24*dydt(4) + d26*dydt(6);
dydt(7) = sqrt(Y(6))*dcdt(1) + d76*dydt(6);
dydt(8) = sqrt(Y(4))*dcdt(2) + d84*dydt(4);
dydt(9) = sqrt(Y(4)*Y(6))*dcdt(3) + d94*dydt(4) + d96*dydt(6);
dydt(10) = sqrt(Y(4)*Y(3))*dcdt(4) + d104*dydt(4) + d103*dydt(3);

% solve matrix equations for independent pressure derivatives


b = -1.0 .* dfdp';
[b,ierr] = gauss(A,b);
if ( ierr~=0 )
return;
end
dydp(3) = b(1);
dydp(4) = b(2);
dydp(5) = b(3);
dydp(6) = b(4);
dydp(1) = sqrt(Y(4))*Y(5)*dcdp(6) + d14*dydp(4) + d15*dydp(5);
dydp(2) = sqrt(Y(4))*Y(6)*dcdp(5) + d24*dydp(4) + d26*dydp(6);
dydp(7) = sqrt(Y(6))*dcdp(1) + d76*dydp(6);
dydp(8) = sqrt(Y(4))*dcdp(2) + d84*dydp(4);
dydp(9) = d94*dydp(4) + d96*dydp(6);
dydp(10)= d104*dydp(4) + d103*dydp(3);

% molecular weights of constituents (g/mol)


% CO2 H2O N2 O2 CO H2 H O
OH NO
Mi = [ 44, 18, 28, 32, 28, 2, 1, 16,
17, 30];

24
if ( T > 1000 )
% high temp curve fit coefficients for thermodynamic properties 1000 <
T < 3000 K
AAC = [ ...
[.446080e+1,.309817e-2,-.123925e-5,.227413e-9, -.155259e-13,-
.489614e+5,-.986359 ]; ...
[.271676e+1,.294513e-2,-.802243e-6,.102266e-9, -.484721e-14,-
.299058e+5,.663056e+1 ]; ...
[.289631e+1,.151548e-2,-.572352e-6,.998073e-10,-.652235e-14,-
.905861e+3,.616151e+1 ]; ...
[.362195e+1,.736182e-3,-.196522e-6,.362015e-10,-.289456e-14,-
.120198e+4,.361509e+1 ]; ...
[.298406e+1,.148913e-2,-.578996e-6,.103645e-9, -.693535e-14,-
.142452e+5,.634791e+1 ]; ...
[.310019e+1,.511194e-3, .526442e-7,-.349099e-10,.369453e-14,-
.877380e+3,-.196294e+1 ]; ...
[.25e+1,0,0,0,0,.254716e+5,-.460117 ]; ...
[.254205e+1,-.275506e-4,-.310280e-8,.455106e-11,-.436805e-
15,.292308e+5,.492030e+1 ]; ...
[.291064e+1,.959316e-3,-.194417e-6,.137566e-10,.142245e-
15,.393538e+4,.544234e+1 ]; ...
[.3189e+1 ,.133822e-2,-.528993e-6,.959193e-10,-.648479e-
14,.982832e+4,.674581e+1 ]; ];
end

% compute cp,h,s
% initialize h, etc to zero
MW = 0;
Cp = 0;
h = 0;
dMWdT = 0;
dMWdP = 0;

for i=1:10
cpo = AAC(i,1) + AAC(i,2)*T + AAC(i,3)*T^2 + AAC(i,4)*T^3 +
AAC(i,5)*T^4;
ho = AAC(i,1) + AAC(i,2)/2*T + AAC(i,3)/3*T^2 + AAC(i,4)/4*T^3
+AAC(i,5)/5*T^4 + AAC(i,6)/T;

h = h + ho*Y(i); % h is h/rt here


MW = MW + Mi(i)*Y(i);
dMWdT = dMWdT + Mi(i)*dydt(i);
dMWdP = dMWdP + Mi(i)*dydp(i);
Cp = Cp+Y(i)*cpo + ho*T*dydt(i);

end

R = 8.31434/MW;
v = R*T/P;
Cp = R*(Cp - h*T*dMWdT/MW);
h = h*R*T;
u=h-R*T;
dvdT = v/T*(1 - T*dMWdT/MW);
dvdP = v/P*(-1 + P*dMWdP/MW);

ierr = 0;
return;

25
function [ierr, y3, y4, y5, y6] = guess( T, phi, alpha, beta, c5, c6 )
ierr = 0;
y3 = 0;
y4 = 0;
y5 = 0;
y6 = 0;

% estimate number of total moles produced, N


n = zeros(6,1);

% Calculate stoichiometric molar air-fuel ratio


a_s = alpha + beta/4;

if ( phi <= 1 )
% lean combustion
n(1) = alpha;
n(2) = beta/2;
n(3) = 3.76*a_s/phi;
n(4) = a_s*(1/phi - 1);
else
% rich combustion
d1 = 2*a_s*(1-1/phi);
z = T/1000;
KK = exp( 2.743 - 1.761/z - 1.611/z^2 + 0.2803/z^3 );

aa = 1-KK;
bb = beta/2 + alpha*KK - d1*(1-KK);
cc = -alpha*d1*KK;
n(5) = (-bb + sqrt(bb^2 - 4*aa*cc))/(2*aa);

n(1) = alpha - n(5);


n(2) = beta/2 - d1 + n(5);
n(3) = 3.76*a_s/phi;
n(6) = d1 - n(5);
end

% total product moles per 1 mole fuel


N = sum(n);

% try to get close to a reasonable value of ox mole fraction


ox = 1;
nIterMax=40;
for ii=1:nIterMax
f = 2*N*ox - (2*a_s)/phi + (alpha*(2*c6*ox^(1/2) +
1))/(c6*ox^(1/2) + 1) + (beta*c5*ox^(1/2))/(2*c5*ox^(1/2) + 2);
if ( f < 0 )
break;
else
ox = ox*0.1;
if ( ox < 1e-37 )
ierr = 5;
return;
end
end
end

26
% now zero in on the actual ox mole fraction using Newton-Raphson
iteration
for ii=1:nIterMax
f = 2*N*ox - (2*a_s)/phi + (alpha*(2*c6*ox^(1/2) +
1))/(c6*ox^(1/2) + 1) + (beta*c5*ox^(1/2))/(2*c5*ox^(1/2) + 2);
df = 2*N - (beta*c5^2)/(2*c5*ox^(1/2) + 2)^2 +
(alpha*c6)/(ox^(1/2)*(c6*ox^(1/2) + 1)) +
(beta*c5)/(2*ox^(1/2)*(2*c5*ox^(1/2) + 2)) - (alpha*c6*(2*c6*ox^(1/2) +
1))/(2*ox^(1/2)*(c6*ox^(1/2) + 1)^2);
dox = f/df;
ox = ox - dox;
if ( ox < 0.0 )
ierr = 6;
return;
end
if ( abs(dox/ox) < 0.001 )
break;
end
end

if( ii == nIterMax )
ierr = 7;
return;
end

y3 = 0.5*( a_s/phi*2*3.76)/N;
y4 = ox;
y5 = alpha/N/(1+c6*sqrt(ox));
y6 = beta/2/N/(1+c5*sqrt(ox));

end

function [B, IERQ] = gauss( A, B )


% maximum pivot gaussian elimination routine adapted from Oikara’s
program.

IERQ = 0;

for N=1:3
NP1=N+1;
BIG = abs( A(N,N) );
if ( BIG < 1.0e-05)
IBIG=N;

for I=NP1:4
if( abs(A(I,N)) <= BIG )
continue;
end
BIG = abs(A(I,N));
IBIG = I;
end

if(BIG <= 0.)


IERQ=2;
return;
end

if( IBIG ~= N)

27
for J=N:4
TERM = A(N,J);
A(N,J) = A(IBIG,J);
A(IBIG,J) = TERM;
end

TERM = B(N);
B(N) = B(IBIG);
B(IBIG) = TERM;
end
end

for I=NP1:4
TERM = A(I,N)/A(N,N);

for J=NP1:4
A(I,J) = A(I,J)-A(N,J)*TERM;
end

B(I) = B(I)-B(N)*TERM;
end
end

if( abs(A(4,4)) > 0.0 )


B(4) = B(4)/A(4,4);
B(3) = (B(3)-A(3,4)*B(4))/A(3,3);
B(2) = (B(2)-A(2,3)*B(3)-A(2,4)*B(4))/A(2,2);
B(1) = (B(1)-A(1,2)*B(2)-A(1,3)*B(3)-A(1,4)*B(4))/A(1,1);
else
IERQ=1; % singular matrix
return;
end
end

end

28
4. Homogenous.m (simultaneously solve the ODE’s using ode23 MATLab function)
function [] = Homogeneous(varargin)

% Two Zone Combustion Cycle

S = 0.16; % Diameter (m)

HEAT = 500; % Heat transfer coefficient

TIMES = 0; % Start of ignition


TIMEB = 60; % Burn period
PHI = 1; % Equivalence ratio

TW = 400; % Wall temperature


fuel_type = 1; % methane

T1 = 300;
P1 = 100; %() (kPa)

TIME = 0;
DTIME = 1;
TIMEE = TIME+DTIME;

[ VOL, X] = auxiliary( TIME );


NNOX = TIMEB/DTIME;
NY = 6+NNOX;
Y = zeros(NY,1);
Y(1) = P1;
Y(2) = nan;
Y(3) = T1;

[~, ~, ~, vU, ~, ~, ~, ~, ~] = farg( Y(3), Y(1), PHI , fuel_type );

M = VOL/vU;

NN = 36*10;
SAVE.TIME = zeros( NN, 1 );
SAVE.VOL = zeros( NN, 1 );
SAVE.T = zeros(NN, 1 );
SAVE.P = zeros( NN, 1 );
SAVE.MDOTFI = zeros( NN, 1 );

fprintf( 'THETA VOLUME BURN FRAC PRESSURE BURN TEMP UNBURNED


T\n' );
fprintf( ' deg cm^3 -- kPa K K \n'
);

fprintf('%7.1f %6.1f %3.3f %6.1f %6.1f %6.1f \n',


...
TIME, VOL*1000000, X, Y(1), Y(2), Y(3) );

29
II = 1;
for III=1:36
for JJJ=1:10

[ Y ] = integrate( TIME, TIMEE, Y );


[ VOL, X] = auxiliary( TIME );

TIME=TIMEE;
TIMEE=TIME+DTIME;

% save data for plotting later


SAVE.TIME(II) = TIME;
SAVE.VOL(II) = VOL;
SAVE.P(II) = Y(1);
SAVE.TB(II) = Y(2);
SAVE.TU(II) = Y(3);
SAVE.X(II) = X;

II=II+1;

if ( TIMES >= TIME && TIMES < TIMEE )


Y(2) = tinitial( Y(1), Y(3), PHI );
end

if ( TIME > TIMES + TIMEB )


Y(3) = nan;
end
end

fprintf('%7.1f %6.1f %3.3f %6.1f %6.1f %6.1f


\n', ...
TIME, VOL*1000000, X, Y(1), Y(2), Y(3) );

end

if ( nargin == 0 )

% generate some plots

figure;
plot( SAVE.TIME, SAVE.X, 'linewidth',2 );
set(gca,'fontsize',18,'linewidth',2,'Xlim',[0 60]);
xlabel( 'time','fontsize',18);
ylabel('burn fraction','fontsize',18);

figure;
plot( SAVE.TIME, SAVE.P,'linewidth',2 );
set(gca,'fontsize',18,'linewidth',2,'Xlim',[0 60]);
xlabel( 'time','fontsize',18);
ylabel('pressure (kPa)','fontsize',18);

30
figure;
plot( SAVE.TIME, SAVE.TU, '-','linewidth',2 );
set(gca,'fontsize',18,'linewidth',2,'Xlim',[0 60]);
xlabel( 'time','fontsize',18);
ylabel( 'temperature (K)', 'fontsize',18);
legend('Unburned', 'Location', 'NorthWest');

figure;
plot( SAVE.TIME, SAVE.TB,'-','linewidth',2 );
set(gca,'fontsize',18,'linewidth',2,'Xlim',[0 60]);
xlabel( 'time','fontsize',18);
ylabel( 'temperature (K)', 'fontsize',18);
legend('Burned', 'Location', 'SouthEast');
end

function [ TB ] = tinitial( P, TU, PHI)


TB = 2000;
[~, HU,~, ~, ~, ~, ~, ~, ~] = farg( TU, P, PHI, fuel_type );
for ITER=1:50
[ierr, ~, HB,~, ~, ~, CP, ~, ~, ~] = ecp( TB, P, PHI, fuel_type );
if ( ierr ~= 0 )
fprintf('Error in ECP(%g, %g, %g): %d\n', TB, P, PHI, ierr )
end
DELT = +(HU-HB)/CP;
TB = TB + DELT;
if ( abs(DELT/TB) < 0.001 )
break;
end
end
end

function [ VOL, X, EM ] = auxiliary( TIME )


VOL = pi/4*S^2*S; % m3

X = 0.5*(1-cos(pi*(TIME-TIMES)/TIMEB));
if ( TIME <= TIMES )
X = 0;
end
if ( TIME >= TIMES+TIMEB )
X = 1;
end
EM = 1;
end

function [Y] = integrate( TIME, TIMEE, Y )

[TT, YY ] = ode23( @rates, [ TIME, TIMEE ], Y );


for J=1:NY
Y(J) = YY(length(TT),J);
end

function [ YPRIME ] = rates( THETA, Y )


YPRIME = zeros(NY,1);

[ VOL, X, EM ] = auxiliary( THETA );


M = EM*MNOT;

31
C1 = HEAT*(pi*B^2/2 + 4*VOL/B)/(2*pi*TIME);
C0 = sqrt(X);

P = Y(1);
TB = Y(2);
TU = Y(3);

% ODE input for simultaneous solution

if ( 0.001 < X && X < 1 )

[~, HU, ~, VU, ~ , CPU, ~, DVDTU, DVDPU] = farg( TU, P, PHI,


fuel_type );
[ierr, ~, HB, ~, VB, ~, CPB, ~, DVDTB, DVDPB] = ecp( TB, P,
PHI, fuel_type );
if ( ierr ~= 0 )
fprintf('Error in ECP(%g, %g, %g): %d\n', TB, P, PHI, ierr
);
end
AA = ((VU/CPU)*(TU/VU)*(DVDTU))* C1*(1-C0)*(1-TW/TU);

DX = 0.5*sin( pi*(THETA-TIMES)/TIMEB )*180/TIMEB;


BB = ((VU-VB)+VB/(CPB*TB)*(HB-HU))* DX;
CC = X*(VB^2/(CPB*TB)*((TB/VB)*(DVDTB))^2)+(DVDPB);
DD = (1-X)*(VU^2/(CPU*TU)*((TU/VU)*(DVDTU))^2)+(DVDPU);

% HL = (1-X^2)*HU + X^2*HB;

YPRIME(1) = (AA + BB )/(CC + DD );


YPRIME(2) = -C1/CPB/C0*(TB-TW) + 1/CPB*TB*DVDTB*YPRIME(1) +
(HU-HB)/CPB*(DX/X);
YPRIME(3) = -C1/CPU/(1+C0)*(TU-TW) + 1/CPU*TU*DVDTU*YPRIME(1);

end

YPRIME(5) = 0;
if ( ~isnan(TB) )
YPRIME(5) = YPRIME(5) + C1*M*C0*(TB-TW);
end
if ( ~isnan(TU) )
YPRIME(5) = YPRIME(5) + C1*M*(1-C0)*(TU-TW);
end

end
end

end

32
REFERENCES

1. B. Hopkinson, Explosions of Coal and Gas and Air. Philos. Trans. R. Soc. London, Ser.
A 77 (1906) 387-413.
2. F.W. Stevens, The rate of flame propagation in gaseous explosive reactions. J. Am.
Chem. Soc. 48 (1926) 1896-1906.
3. E.F. Fiock, C.F. Marvin Jr, F.R. Caldwell, C.H. Roeder, Flame speeds and energy
considerations for explosions in a spherical bomb, Natl. Advisory Comm. Aeronaut.,
Rep, 1940.
4. B. Lewis, G. von Elbe, Combustion, Flames and Explosions of Gases Academic Press
Inc. London, UK 1961.
5. M. Metghalchi, J.C. Keck, Laminar Burning Velocity of Propane-Air Mixtures and
High Temperature and Pressure, Combus. Flame 38 (1980) 143-145.
6. K. Saeed, C.R. Stone, The modelling of premixed laminar combustion in a closed vessel
Combust. Theory Modelling, 8 (2004) 721-743.
7. C.R. Ferguson, Internal combustion engines, p168-80 Wiley, New York 1985.
8. R.R. Raine, C.R. Stone, J. Gould, Modelling of Nitric Oxide Formation in Spark
Ignition Engines with a Multi-zone Burned Gas, Combust. Flame 102 (1995) 241-255.
9. C.J. Rallis, A.M. Garforth, The Determination of Laminar Burning Velocity, Prog.
Energy Combust. Sci. 6 (1980) 303-329.
10. Khizer Saeed (2013) Measurements of the Combustion Characteristics of Early
Premixed Flames Inside Closed-Vessel Combustion, Combustion Science and
Technology, 185:1, 37-61, DOI: 10.1080/00102202.2012.708069
11. http://www2.eng.ox.ac.uk/engines/papers/KhizerCombFlame.pdf
12. S. Gordon, B. McBride, NASA SP-273, 1971.

33

Potrebbero piacerti anche