NUMERICAL SIMULATION OF CHEMICAL REACTIONS

INSIDE A SHOCK-TUBE BY THE SPACE-TIME

CONSERVATION ELEMENT AND SOLUTION ELEMENT

METHOD

MASTER’S THESIS

Presented in Partial Fulfillment of the Requirements for the Degree Masters of Science in the Graduate School of the Ohio State University

By,

David L. Bilyeu, B.S.

*****

The Ohio State University 2008 Thesis Committee:

Professor Sheng-Tao John Yu, Advisor Approved by

Dr. Douglas Davis

Professor Jeffrey A. Sutton ______

Adviser Mechanical Engineering Graduate Program

Copyrighted By

David L. Bilyeu

2008

ABSTRACT

The goal of this master’s project is to develop and test a numerical tool to simulate the fluid physics and chemical reactions inside of a shock tube. The one- dimensional Euler equations for chemically reacting flow are employed to model the fluid flows and detailed finite-rate chemistry models are used to simulate chemical reactions. The CESE method is used to solve the Euler equation. The implicit trapezoidal method with sub-time steps is used to solve the stiff ODEs for chemical reactions. The newly developed code has been validated by (i) zero-dimensional calculations for testing the chemistry solver (ii) Calculation of the ignition delay in a shock tube. The results were compared with the ignition time from shock tube experiments. The new shock-tube tool will be used (i) to study the lean-blow-out in scramjet engines and (ii) to assess the required mesh and time resolution for 2/3- dimensional simulation of chemically reacting flows.

ii

DEDICATION

To My Family

iii

ACKNOWLEDGMENTS

I would like to thank my advisor, Professor Sheng-Tao John Yu, for his knowledge and experience in numerical simulations, his constant encouragement and enthusiasm.

I am grateful to Dr. Douglas Davis at for his insight into computational chemistry.

I would also like to thank Andrew Naples for his insight into the workings of

CHEMKINTM and M.S. Word. I would also like to thank Yung-Yu Chen for setting up and managing the cluster used to do most of the computational work.

This research was supported by a fellowship from The Dayton Area Graduate

Studies Institute.

iv

VITA

May 04, 1984 ...... Born in California, USA

June 2006 ...... B.S., Aerospace Engineering, California State Polytechnic University, Pomona, CA, USA

2006 – Present ...... Graduate Research Assistant, Department of Mechanical Engineering, The Ohio State University, USA

FIELDS OF STUDY

Major Field: Mechanical Engineering

v

Table of Contents Abstract ...... ii Dedication ...... iii Acknowledgments ...... iv Vita ...... v List of Figures ...... ix List Of Tables ...... xii Nomenclature ...... xiii Chapter 1 Introduction ...... 1 1.1. Objectives ...... 1

1.2. Numerical Methods ...... 2

1.3. Organization ...... 3

Chapter 2 Thermodynamics ...... 5 2.1. General Properties of Mixed ...... 5

2.2. Thermodynamic Properties for Mixed Gases ...... 9

Chapter 3 Combustion Modeling ...... 17 3.1. Chemical Rate of Progress ...... 17

3.2. Chemical Reaction Rate ...... 20

3.3. Numerical Procedure for Zero-Dimensional Combustion ...... 26

3.4. Validation ...... 34

3.4.1. The Li H2/O2 Mechanism ...... 39

3.4.2. The GRI Mechanism ...... 42 vi

3.4.3. The UCSD Mechanism ...... 46

3.5. Future Improvements ...... 49

Chapter 4 Model Equation ...... 51 4.1. One-Dimension Euler Equations ...... 51

4.2. One-Dimension Euler Equations for Reacting Flows ...... 52

4.3. The Non-Conservative Form ...... 54

4.4. Calculating ∂p/∂x ...... 56

4.5. The Jacobian Matrix ...... 60

Chapter 5 The CESE Method ...... 66 5.1. Introduction ...... 66

5.2. CESE Scheme for the Euler Equation ...... 67

5.3. CESE Scheme for the Chemically Reacting Euler Equation ...... 72

5.4. Boundary Conditions ...... 75

Chapter 6 Shock Tube ...... 77 6.1. Introduction ...... 77

6.2. General Layout ...... 77

6.3. Analytical Solution ...... 80

6.4. Numerical Method for the Shock Tube ...... 89

vii

6.5. Validation ...... 103

Chapter 7 Conclusion ...... 111 7.1. Future Improvements ...... 111

Bibliography ...... 114

viii

LIST OF FIGURES

Figure 3.1: Numerical procedure for zero dimension combustion analysis ...... 28

Figure 3.2: The time history of temperature and time steps for constant-volume combustion of stoichiometric CH4-O2 mixture diluted with 76.1% Ar. The initial temperature is 1500 K and the initial pressure is 3.0 atm...... 30

Figure 3.3: Time vs. iteration number for the combustion of constant-volume stoichiometric combustion of CH4-O2 diluted with 76.1% Ar. The initial temperature and pressure are 1500 K and 3.0 atm ...... 32

Figure 3.4: Comparison of induction times for constant volume combustion of stoichiometric H2/O2 mixture diluted with 70% Ar. The initial pressure for all cases is 1.3 atm. These results are from an old version of Gaskin...... 36

Figure 3.5: Comparison of final temperature for constant volume combustion of stoichiometric H2/O2 diluted with 70% Ar. The initial pressure for all cases is 1.3 atm. These results are from a previous version of Gaskin...... 37

Figure 3.6: Induction time calculations given different maximum time steps. Combustion is done at constant volume with a stoichiometric coefficient of 1.5, an initial pressure of 0.5 atm diluted with 76.1% Ar. The triangle corresponds with the left y axis while the square and diamond are associated with the right y axis .... 38

Figure 3.7: Induction time percentage difference between Gaskin and CHEMKINTM for H2 combustion with 76.1% Ar at various initial temperature and pressures at a stoichiometric coefficient of 1.5...... 41

TM Figure 3.8: Final temperature percent difference between Gaskin and CHEMKIN for H2 /O2 combustion diluted with 76.1% Ar at various initial temperatures and pressures and at an equivalence ratio of 1.5...... 42

TM Figure 3.9: Induction time percent difference between Gaskin and CHEMKIN for CH4 combustion diluted with 76.1% Ar at various temperature and pressures and an equivalence ratio of 1.5...... 43

Figure 3.10: Final temperature percent difference between Gaskin and CHEMKINTM for CH4 combustion with 76.1% Ar at various initial temperatures, pressures and a stoichiometric coefficient of 1.5 ...... 45

ix

Figure 3.11: The predicted induction time percent difference between Gaskin and CHEMKINTM for propane combustion diluted with 76.1% Ar at various temperature and pressures and a equivalence ratio of 1.5...... 47

Figure 3.12: The predicted final temperature percentage difference between Gaskin and CHEMKINTM for propane combustion diluted with 76.1% Ar at various initial temperatures and pressures and an equivalence ratio of 1.5 ...... 48

Figure 5.1: The grid set up for the CESE method ...... 68

Figure 5.2: Space-time integration over an arbitrary region...... 69

Figure 6.1: Wave dynamics in a shock tube experiment...... 78

Figure 6.2: A flow chart of the computer program GASKIN...... 90

Figure 6.3: The calculated temperature profile before the incident passes into the test section...... 91

Figure 6.4: The calculated temperature profile after the shock wave passes into the test section...... 92

Figure 6.5: The flow chart of logic for determining if it is necessary to run the chemistry calculation in the shock-tube code, i.e., GASKIN...... 95

Figure 6.6: The calculated temperatures in the shock-tube simulation showing the temperature history at a location 2 mm from the end wall when the initial temperature is uniform at 700 K...... 96

Figure 6.7: Shock tube simulation showing the temperature history at a location 2 mm from the end wall when the initial temperature is uniform at 750 K...... 98

Figure 6.8: Shock-tube simulation showing the mole fractions and temperature at a time 0.79031 msec...... 99

Figure 6.9: The calculated time history of the maximum sum of mass fraction and the temperature at 2 mm from the end wall inside of a 1 meter long shock tube. The fuel is stoichmetric H2/O2 diluted with Ar at 70%...... 101

Figure 6.10: Plot of temperature (semi-log) and CPU time (log-log) vs. dx with chemistry turned off. The initial conditions are listed in Test 1 in Table 6.4...... 106

Figure 6.11: Plot of induction time (semi-log) and CPU time (log-log) vs. dx for the conditions listed in Test 2 in Table 6.4...... 107 x

Figure 6.12: Plot of the calculated induction time (semi-log) and CPU time (log-log) vs. dx for the conditions listed in Test 3 in Table 6.4...... 108

Figure 6.13: Shock tube study for constant-volume CH4 /O2 reactions diluted with Ar at various initial pressures and temperatures and the equivalence ratios...... 109

xi

LIST OF TABLES

Table 6.1: Comparison between analytical and CFD solution for Air with specific heat equaling 1.4 as both Driver and Driven gas...... 87

Table 6.2: Comparison between analytical and CFD solution for Air with specific heat of 1.3283 as both driver and driven gas...... 88

Table 6.3: Comparison between the induction times calculated using a zero- dimensional simulation and the time it takes from the time on which the gas starts to combust inside a shock tube simulation...... 100

Table 6.4: Different shock tube setups to find an optimum dx...... 105

xii

NOMENCLATURE af frozen m/s th 3 ro-1 Ak pre factor of the k species in the Arrhenius equation (m /kmole) th Cpi specific heat at constant pressure of the i species J/kmole K

Cp specific heat at constant pressure of the mixture J/kmole K th Cvi specific heat at constant volume of the i species J/kmole K

Cv specific heat at constant volume of the mixture J/kmole K th cpi specific heat at constant pressure of the i species J/kg K Cp specific heat at constant pressure of the mixture J/kg K th cvi specific heat at constant volume of the i species J/kg K cv specific heat at constant volume of the mixture J/kg K E total specific energy J/kg th Ek activation energy in the k reaction calories/mol E specific internal energy J/kg G Gibbs energy J/kmole go Gibbs energy at standard pressure J/kg 0 Gibbs energy of the ith species at standard pressure J/kg gi H enthalpy of the mixture J/kmole th Hi enthalpy of the i species J/kmole H enthalpy of the mixture J/kg th hi enthalpy of the i species J/kg 3 ro Ko low pressure limit forward reaction rate (m /kmole) 3 ro-1 K∞ high pressure limit forward reaction rate (m /kmole) th 3 ro-1 Kfk forward rate constant of the k reaction (m /kmole) th 3 ro-1 Krk backwards rate constant of the k reaction (m /kmole)

xiii

th 3 ro-1 Kck equilibrium constant in concentration of the k reaction (m /kmole) th 3 ro-1 Kpk equilibrium constant in pressure of the k reaction (m /kmole) th Mi molecular weight of the i species kg/kmole

Mm molecular weight of the mixture kg/kmole th ni number of moles for the i species kmole th nk temperature exponent for the k reaction nt total number of moles kmole

Ns total number of species

Nr total number of reaction R specific Gas Constant J/kg K th Ri specific gas constant for the i species J/kg K

Rc universal Gas Constant for combustion 1.9858 cal/mol K

Ro universal Gas Constant (8314) J/kmole K p pressure Pa (N/m2) 2 po standard pressure (1 atm, 101325 Pa) Pa (N/m ) ro reaction order S0 entropy at standard conditions J/kmole K 0 entropy at standard conditions of the kth species J/kmole K Sk S entropy of the mixture J/kmole K th Si entropy of the i species J/kmole K s entropy of the mixture J/kg K th si entropy of the i species J/kg K T temperature K V volume m3 th Yi mass fraction of the i species th Xi mole fraction of the i species

xiv

th 3 [Xi] molar concentration of the i species kmole/m

αki enhanced third body efficiency ρ density kg/m3 γ ratio of specific heat

ν'ki stoichiometric coefficients of the reactants

ν‖ki stoichiometric coefficients of the products

xv

CHAPTER 1

INTRODUCTION

1.1. Objectives

There has been ongoing research by scientists in US government agencies for scramjet engines (Curran, Heiser and Pratt 1996). One of the most public projects was the X-43 aka Hyper X which has reached a speed over Mach 5 (NASA 2004).

Unlike the ramjet engine, one major difficulty of the scramjet engines is to maintain combustion at supersonic speeds. In general, there is limited time for the fuel to mix with the high-speed airstream for combustion. As such, the scramjet engines suffer from lean-blow-out phenomena. It is imperative for the design engineers to identify a window of operation for scramjet engines in terms of flow conditions and the associated fuel/air ratios.

In order to reproduce the flow conditions inside of the combustion chamber of a scramjet engine, a shock tube is typically used to study the combustion chemistry. A shock tube is a long cylinder with high pressure gas on one side of a diaphragm and low pressure gas on the other. When the diaphragm is removed, a shock wave moves from the high pressure gas to the low-pressure gas, increasing the temperature, pressure and density behind it. This makes the shock tube an ideal tool to study the

1 ignition delay of combustible mixtures because it provides instant heating, via shock heating, to the fuel/oxidizer mixture without changing the concentration of the gas mixture.

When a shock tube is used to test simple fuels, e.g., H2 and CH4, the induction time, i.e., the time that it takes for the fuel/oxidizer mixture to combust is much shorter than the dwelling time, i.e., the time for the gas in the test section to cool down due to the reflected expansion waves and/or heat transfer. For more complex fuels, such C3H8 and aviation gases, the induction time may be longer than the dwelling time. As such, the measured data for ignition delays could be affected by the expansion wave. This will make the interpretation of the measured data and the experiment setup problematic.

The goal of this research project is to develop a numerical tool, which is capable of modeling chemically reacting flows inside of a shock tube. Detailed simulation of wave dynamics is necessary to provide accurate assessment of the dwelling time in the shock tube experiments. The newly developed computer program, Gaskin, is a general solver for reacting flows with comprehensive models, including the multiple- species Euler equations for fluid physics, detailed finite rate chemistry for chemical reactions, and comprehensive thermodynamics models for the gas mixtures.

1.2. Numerical Methods

This system of the model equations contains two different types of differential equations: (i) hyperbolic partial differential equations (pde’s) for the Euler equations, 2 and (ii) a set of stiff ordinary differential equations (ode’s) for the law of mass action. The pde’s are solved by using the space-time Conservation Element Solution

Element (CESE) method, which is a novel and robust solver for complex hyperbolic systems. The CESE method has been used previously to solve multiple hyperbolic problems in different fields, including but not limited to chemically reacting flow in one, two and three spatial dimensions (Im and Yu 2003) (He, Yu and Zhang 2005), wave propagation in solids (Cai, Yu and Zhang 2006), and Magneto-Hydro-

Dynamics (MHD) equations (Zhang, et al. 2006).

The ode’s are integrated by using the first-order Euler implicit method and the second-order implicit trapezoidal method. There are several other different ODE integrators that are more efficient, but the Euler-implicit and the trapezoidal methods are used in the present thesis for robustness. Other choices for ODE integrators include the explicit Runge-Kutta method and the implicit Adam-Moulton method.

The Runge-Kutta scheme is more efficient than the implicit methods because there is no matrix inversion. However, it is a poor choice because all explicit schemes are highly unstable when dealing with stiff ode’s. The Adam-Moulton method allows for a larger time step, which would require fewer matrix inversions. However, it is less stable than the first-order Euler implicit method and the trapezoidal method.

1.3. Organization

This thesis is organized in following. Chapter 2 presents the derivations of the thermodynamic properties of the gas mixtures. Chapter 3 illustrates the model

3 equations that govern the chemical kinetics and the associated numerical methods for solution. Chapter 4 outlines the derivation of the Euler equations for reacting flows used to simulate the fluid physics. Chapter 5 explains the CESE method for solving the multiple-species Euler equations. Chapter 6 presents the numerical results of the shock-tube flows as well as analytical solutions. I then offer the concluding remarks and provide the cited references.

4

CHAPTER 2

THERMODYNAMICS

2.1. General Gas Properties of Mixed Gases

The ideal gas equation is used as the equation of state of the combustion systems.

Since there are multiple species, we first apply the perfect gas law to a single species i :

pi  iRT i (2.1)

where pi, ρi and Ri are the pressure, density and the gas constant of gaseous species i and T is the temperature. Since thermal equilibrium is assumed among all chemical species, there is only one temperature. When dealing with gas mixtures, it is assumed that the pressure and the volume of each species are governed by Dalton law. Dalton’s law states that the pressure of a gas mixture is equal to the sum of the partial pressures of all gaseous species if that species existed alone at the temperature and volume of the gas mixture (Sutton and Biblarz 2001).

Ns pp  i (2.2) i1

We also define

5

NS   i (2.3) i1

It is also defined that

Ns i RR  i (2.4) i1 

where R is the specific gas constant of the gas mixture and ρ is the density of the mixture. The perfect gas law can be derived from Equation (2.1), (2.4) and by summing up all of the partial pressures of individual species based on Dalton’s law, we have

p  RT (2.5)

A quantity that is convenient to use is the mass fraction, which is equal to the ratio of the mass of a single gaseous species to the total mass of the mixture:

 Y  i (2.6) i 

where Yi is the mass fraction. One property of the mass fraction is that the sum over

Ns all species equates to 1 e.g. Yi 1. i1

As was found by Petersen et al. (Petersen, Rohrig, et al. 1996), the ideal gas law is an excellent assumption for a wide range of thermodynamic state. For

6 pressures less than 90 atm and temperature of 1800 K, the error in the estimated temperature by the ideal gas law is less than 7 K. The assumption that the gas can be treated by the ideal gas law is crucial because it allows the thermodynamic properties, internal energy, enthalpy, and specific heats, to be functions of temperature only. This will allow successful derivation of an analytical form of the

Jacobian matrix in the Euler equation for reacting flows.

In most engineering systems it is common to treat quantities in terms of mass but in chemistry it is more advantageous to treat quantities in terms of moles. The ideal gas law can be rewritten in a molar base to take the form of

pV nto R T (2.7)

and

pVi n i R o T (2.8)

where V is the total volume nt is the total number of moles in the mixture. ni is

th the number of moles of the i species and Ro is the universal gas constant which is equal to 8314 J/k-mole K. An important quantity is the mole fraction, Xi, defined by the number of moles of a single species divided by the total number of moles of the mixture.

ni X i  (2.9) nt

7

th In Equation (2.9), ni is the number of moles for the i species. Since multiple species are present, the total molecular weight of the gas mixture is not a constant and it is calculated by Equation (2.10):.

Ns MXMm  i i (2.10) i1

where Mm is the molecular weight of the mixture. This equation can be derived by dividing Equation (2.1) by Equation (2.5) and summing up the species.

By equating Equation (2.7) and (2.5) a relationship between the universal gas constant and the specific gas constant for the mixture can be obtained

R R  o (2.11) M m

In order to access the existing data base in CHEMKIN, it is more convenient to work with units that are mole-based than the mass-based units. Since different parts of the program works in different units, Equation (2.12) can be used to convert mole fractions into mass fractions as seen below.

M i Yii X (2.12) M m

n The molar concentration defined by X   i is used by the law of mass action i V and can be calculated from both a mole and mass base as seen below

8

p  X i  X i Y i (2.13) RToiM

Equation (2.12) can be rearranged to form

YX ii (2.14) MMim

Apply the sum from i = 1 to Ns on both sides yields

NS 11 Yi  (2.15) i1 MMi m

2.2. Thermodynamic Properties for Mixed Gases

Since it is assumed that the gas mixture adheres to the ideal gas law, the specific heats are a function of temperature only. The relationship between specific heat and temperature was determined experimentally and a least squares fit is used to represent the data as a fourth order polynomial. It can also be shown that the other thermodynamic properties are only a function of one state variable and not two. For example take enthalpy of a specific species, hi, and let it be equal to a function of temperature and pressure only then taking the total differential yields,

hhii dhii dT dp (2.16) Tp p i T

9

h Using the definition of constant pressure specific heat, c  i , Equation (2.16) pi  T p can be rewritten as,

hi dhic p dT dp i (2.17) i p i T

By differentiating the Tds equation (Sears and Salinger 1975, 155) with respect to

h pressure, a new expression for i can be found, p i T

dhi Tds i dp i

hsii    (2.18)  T    i pp TT   where ν = 1/ρ is specific volume. Substituting Equation (2.18) into Equation (2.17), we get

 si dhi c pdT i T dp i (2.19) i p i T

Applying the Maxwell relations, and evaluating the partial derivative using the ideal gas law, Equation (2.19) can be reduced to

 dh c dT   Ti dp i pi  i i T p  c dT T i dp (2.20) pi  i i T  c dT pi 10

A similar process can be done to entropy, in a molar base, to yield

C pi Ro dSii dT d p (2.21) Tpi

Integrating Equation (2.21) from its reference state to the current state yields

T dT pi dp SSC  R i (2.22) i pi Tp o ref Tpref o i

Unlike enthalpy and internal energy, entropy is affected by a change in pressure. It is convenient to separate the pressure and temperature effects for entropy by defining

T dT SCSo  (2.23) i pi T ref Tref

When Equation (2.23) is substituted into Equation (2.22)

o  pi  SSRi i o ln  (2.24) po

It is more useful to express entropy in terms of total pressure and mole fraction;

p since the mole fraction can also be expressed as X  i Equation (2.24) can be i p rewritten as

o p Si SR i oln X i  R o ln  (2.25)  po 

11

When calculating the chemical equilibrium, Section 3.1, the entropy and enthalpy are calculate at a pressure of 1 atm which allows for the use of Equation (2.23) and not

(2.25). (Kee and Rupley 1989). The entropy calculated in Equation (2.21) through

(2.25) is done in a molar base and it is necessary to divide by either the molecular weight of an individual species or the mixture to convert to a mass base. Since specific heat is only a function of temperature then entropy and enthalpy are also functions of temperature for the standard-state properties.

The thermodynamic properties are calculated using a fourth order polynomial fit to the specific heat from which enthalpy and entropy are calculated. In order to cover the temperature ranges that occur during combustion the polynomial coefficients are split up into at least two temperature ranges. Seven coefficients are needed with five being used for the calculation of specific heat and the six and seventh being the integration constants associated with enthalpy and entropy respectively.

Since the internal energy and not temperature is used in the CFD scheme, the temperature has to be calculated through the relationship between internal energy and enthalpy. This involves the use of a root finding routine, such as Newton, bisection or a combination, but if the current temperature is close to the dividing point between two regions the root finding scheme can fail since the function is not always smooth. In order to avoid this three different methods were developed, the first was to alter the thermodynamic coefficients slightly so that there is a smoother transitions between the two temperature ranges. The second method tried was to 12 create a single set of thermodynamic coefficients using a least squares so there would not be any discontinuities. One downside is that the values are not as accurate at the extremes. This method worked well producing the same results as other programs for calculating temperature. The third method tried was to use a subroutine created by another program to calculate the temperature, the other program used is Cantera

(D. G. Goodwin, Cantera 2008) and the results matched those of the second method.

Although this does require a link to a program written in C++ calling the subroutine from Gaskin did not cause any noticeable increase in CPU time.

Equations for specific heat, enthalpy and entropy are given below. The coefficients provided in the thermodynamic database have units of 1/Tn which when multiplied out by its corresponding temperature provides a unitless number. This makes it simple to calculate the thermodynamic properties in either mole or mass base by multiplying it by either the universal gas constant or the specific gas constant respectively.

c pi aa T a T2  a T 3  a T 4 (2.26) R 0i 1 i 2 i 3 i 4 i

th cpi is the specific heat in mass of the i species and the a0i-a4i are the polynomial coefficients used to calculate cp.

T

h cp dT (2.27) i  i Tref

13

th hi is the enthalpy of the i species calculated by taking the integral from a reference temperature Tref to T.

h aaa a a iaT 1 i 2 iTTT2  3 i 3 4 i 4  5 i (2.28) RT 0i 2 3 45T

The terms a0i-a4i are the same values from before and a5i term is the integration constant.

T cp so  i dT (2.29) i  T Tref

so a aa i a lnTaaT 2iii T2 3 T 3 4 T 4 (2.30) R 0i 1 i2 34 6 i

th In the two equations above the si term is the entropy of the i species in mass units and the last coefficient a6i is the integration constant.

goo h Ts (2.31) iii

gsooh iii (2.32) RT RT R

th gi is the Gibbs free energy of the i species in mass units. Equation (2.31) is normalized by RT so that it can be more easily calculated through the equations above which results in Equations (2.33). It should be noted that a change in pressure does not affect enthalpy but so the superscript is not needed.

g o a a a a a i a(1  lnT ) 1i T  2 i T2  3 i T 3  4 i T 4  5 i  a (2.33) RT06ii2 6 12 20 T

14

Equations (2.26), (2.28), (2.30) and (2.33) are the specific heat, enthalpy, entropy and Gibbs free energy respectively for any given species in the mixture. Those same quantities need to be calculated for the mixture as a whole. This is done by

NS  Yii  (2.34) i1

where ψi is any of the above mentioned thermodynamic quantities on a mass basis.

Ψ is the value for the gas mixture on a mass basis. The mass fraction can be replaced with the mole fraction if a mole based quantity is needed instead of mass based.

e h RT (2.35)

Equation (2.35) gives the formulation for specific internal energy, e, this equation is important because temperature, which is used in the in the chemistry calculations, is not a flow variable and thus needs to be calculated from known quantities. It is through this equation that temperature is calculated by the use of a root finding numerical method since R is known by the species composition and enthalpy is a function of temperature and species composition.

The numerical method used to handle the chemical kinetics uses one less species than what is given in the chemical mechanism, the reason for this is explained in

Chapter 3. This is possible because the sum of the mole or mass fraction must be 1 and thus the omitted species mass fraction can be calculated through Equation (2.36).

NS 1 YY1 (2.36) Nis  i1

15

It can be beneficial to rewrite Equation (2.35) using only a summation from i=1,…,Ns-1.

NS 1 e e Y e  e (2.37) NisS iN  i1

16

CHAPTER 3

COMBUSTION MODELING

3.1. Chemical Rate of Progress

A one-step stoichiometric reaction can be expressed as

NssN i' XX i  ' i'  i  (3.1) i11i

where  i' and  i'' are the stoichiometric coefficients of the reactants and products respectively.

The rate at which a particular species is created or destroyed is governed by the law of mass action which states that the rate at which a species is destroyed is proportional to the product of the molar concentration of the reacting species to the power of their stoichiometric coefficient (Glassman 1996). In order to become more useful the law of mass action can be rewritten to include the reverse reaction rate.

Since the CFD solver uses mass conservations it can be convenient to change the units to a mass base by multiplying by the molecular weight. This can be mathematically expressed as

17

'"ll NR NNSS di  l    l  MKKi ni f  b   (3.2) dt  n MMn n1 l11l l l 

where NR is the number of reaction in the current mechanism Kfr and Kbr are the forward and backwards reaction rates respectively and derived in Section 3.2. νni is

ni "' ni  ni (3.3)

The change in species can be linearized to take the form below

UUUk k   k (3.4)

T T where Uk  k,  k ,...,  k and Uk1 k  1,  k  1 ,...,  k  1 and U is the  12 NS   12 NS  change in density of the species.

In order to update the molar concentrations of each species the source term needs to be integrated. There are different options when integrating the source term but for this program it was decided to use the trapezoidal rule shown below,

t2 ktc k k1 uii S( u) dt   S  Si  (3.5)  2 t1

where t1 and t2 are the starting and ending time respectively, Δtc is the allowed time step used to approximate moving from t1 to t2 and Δui is the quantity that is changing in time, for this problem it is density. S(u) is the source term which is equal to dX  i and u is the density of each species. The result of using the trapezoidal dt

18 method is that an implicit method is needed to find Sk+1 which requires a matrix inversion. In order to find the term Sk+1 the first order forward difference finite difference approximation is used.

k1 kS k S Su   (3.6) u

When Equation (3.6) is substituted into Equation (3.5) and solved for uk the first order implicit Euler method is derived

IS1  kk u  S (3.7) tc 2 u

The bracketed term in Equation (3.7) is a matrix of size Ns-1 by Ns-1 that needs to be inverted where I is the identity matrix.

There are several other higher order schemes that are more efficient at integrating the source term from t1 to t2 but these methods are more unstable then the

Euler method, derived above, and for this reason is not used in this program.

Explicit schemes are also not used because the ODE formed is stiff and it has been found that explicit schemes are not a viable method to solve stiff ODEs. The term

―stiff‖ does not have a solid definition but in this case the system is stiff because the characteristic time of each reaction varies by several orders of magnitude (Toro

1999).

The jacobian matrix in Equation (3.7) can be expressed as with ρ being substituted for u 19

'll" NRE NNSS Si dd  l   l   MKKi ni f   b   (3.8)  rrd MMd  k r1 ll11 k  l  k  l 

The derivative of the product in Equation (3.2) can be expressed as

''l  'L k ddNNSS    lk L   ,lk ddMMM klL11 l  L k  k 

 'L  NS     '  'k L k k ,lk   'k   L1 MML k k  (3.9)  'L  'k NS    '  L k k ,l  k  MM L1 L  k k

 'l ' NS   k l ,lk k l1  M l 

With the result from equation an explicit form of the jacobian found in Equation

(3.7) can be expressed as

NN'"rl rl  NRE '"KKSS     Sil frr l l b l  Mi ri      (3.10)  M  M kk r1 l11 lk l  l 

3.2. Chemical Reaction Rate

In the above equations, Kfk and Kbk represent the forward and backward reaction rates for the kth reaction. The basic equation that governs the forward and backwards

20 reaction rates is formulated based on the exponential activation energy from statistical thermodynamics and is called the Arrhenius rate equation:

E f k n RT KT A fk ec (3.11) ffkk

Here Afk is the prefactor, nfk is the temperature exponent and Efk is the activation energy. Convention states that the units for activation energy are given in cal/mole, which requires the universal gas constant to be in calories and not joules. The temperature must be in Kelvin.

The number of reactions varies depending on the fuel and oxidizer being used.

For example, the chemistry model for H2-O2 combustion has about 30 reactions. The

CH4-air reaction model has about 300 reactions. A typical propane-air mechanism has about 700 reactions. An example reaction is shown in Equation (3.12) where

HO2 and H combine to form H2 and O2.

HO2+H H 2+ O 2 1.66E+13 0.00 823.0 (3.12)

The three numbers following the reaction are the coefficients Afk, nfk, Efk. The units for the nfk and Efk are unchanged for every reaction but the units for Afk vary depending on how many species are in the reaction. This reaction is reversible, which means that the products, H2 and O2, can also combine to form the reactants,

HO2 and H.

My program uses the SI system i.e. m-kg-s, but the standard CHEMKINTM input uses the CGS system i.e., cm-g-sec. The units for the exponential and pre-factor 21 terms must be changed. The units for the exponential term Efi are cal/mol instead of changing the units to J/kmol the value is divided by the universal gas constant Rc which has the units cal/mol K. The units for the prefactor Afk are more complicated since it depends on the number of reactants in the reaction. The simplest way to determine its units is to use Equation (3.13). Its units are constant and in the CGS

3 system they are moles/cm sec. Knowing the units of frk and the products of the

3 ro molar concentration which is (moles/cm ) , the units of Kfk are found to be

(cm3/mol)ro-1/sec. This is the units provided by CHEMKINTM mechanism input file,

ro-1 in order to convert into the SI system the value Afi needs to be divided by 1000 .

The variable ro is called the reaction order and its value is the total number of reactants in the reaction, for the reaction 2H+O=H2O ro=3, with H counted twice.

N s  'ki f K[] X (3.13) rk f i i1

qik fr (3.14)

th where qi is the full reaction rate for the i reaction. When more terms are defined the definition of qi will have to be expanded upon.

Generally, only the forward rate coefficients in the finite rate chemical mechanism are given in the literature. The reverse or backwards reaction, Krk, must be calculated through chemical equilibrium.

G K  exp i (3.15) Pk   RTo 

22

The ∆Gi is not the change in Gibbs energy from one temperature to another but rather the change in Gibbs energy between the products and the reactant. With the addition of the backwards reaction Equation (3.14) would have to be modified to take into account the effects of this reaction as seen in Equation (3.19).

NS ik po i1 KKCP  (3.16) k k RT

where νik is defined in Equation (3.3)

K K  fk (3.17) rk K ck

Ns Gk  kiG i (3.18) i1

q fb (3.19) irrkk

N s "ki bX K (3.20) rrkk i  i1

The brk term is similar to frk from Equation (3.13) except that it uses the reverse reaction rate and the exponent references the species coefficients from the products side and not the reaction side.

There are some reactions that will only take place if there are another species present to give or take energy from the reaction. These reactions are called three- body reactions. An example of a three-body reaction is given by Equation (3.21).

This changes the formulation of Equation (3.13) as well as the reaction order. The

23 reaction order would now include the third bodies present in the reaction denoted by

M, which will cause the reaction order for Equation (3.12) to be 3.

O+H+M OH+M (3.21) H2/2.5/ H2O/12/ AR/0.75/

In Equation (3.21) there are three species have enhanced values given, they are

H2, H2O and Ar. It is also possible for a single species, such as N2, to be the sole three-body effecting a particular reaction this is denoted by the species name to be surrounded by parentheses i.e. (N2). The addition of the third body effects how qi is calculated. The updated form is shown in Equation (3.22).

NN '' ss 'ki ki q[]MK K[] X X  (3.22) k kfkkiri i11i

M where  k  is defined as

Ns []MXk  ki i  (3.23) i1

If no enhanced three-body efficiencies are declared for a particular reaction then it is assumed that they are all one, i.e. αik = 1

NS P nt []M k X k   (3.24) k1 RTo V

Pressure can also affect the rate at which some reaction take place.

CHEMKINTM was designed to handle this through pressure-dependent fall-off 24 reactions. Three different approaches to calculate the effects that pressure has on the reaction have been included in the CHEMKINTM program and they are Lindemann,

Troe, and SRI. An example reaction in CHEMKINTM format is shown in Equation

(3.25). The three methods noted above handle the calculation of pressure in a similar manner in that they use two different sets of Arrhenius equations one at a lower pressure, Ko, and the other at a higher pressure, K∞. They differ is in how they blend the two equations together. The method developed by Lindemann set F in Equation

(3.27) to unity.

H+O22 (+M) HO (+M) (3.25)

k M  PR  o (3.26) k

 PR  k k  F (3.27) 1 PR

Troe defines F through Equation (3.28), where a, T***, T* and T** are constants defined in the chemistry mechanism. The last constant T** is not always defined, in

T ** this case the last term in Fcent, exp, is set to 0. T

25

2 1 log PR c logFF 110 log n d log PR c 10 cent  10 

c  0.4  0.67log10 Fcent

n 0.75 1.27log10 Fcent (3.28) d  0.14 TTT     ** Fcent (1  a )exp***   a exp  *   exp TTT     

The SRI method further modifies F found in Equation (3.27) by using Equation

(3.29):

X bT    e F aexp  exp   d T Tc     (3.29) 1 X  2 1 log10 PR

where a, b, c, d, and e are all constants defined in the mechanism.

3.3. Numerical Procedure for Zero-Dimensional Combustion

A zero-dimensional simulation makes a good test case because the results only depend on the chemical mechanism and not the flow field. If any problems are found during this analysis, the problem has to be with the chemistry subroutine and not the CFD scheme used. To summarize the numerical approach needed to solve a zero dimensional, ZeroD, combustion problem, Figure 3.1 provides a flow chart detailing each major section of the program. The program has been split up into eight different steps to be completed with steps II through VIII repeating at each time step. 26

Step I is used to take the initial conditions, i.e. temperature and gas composition and determine the enthalpy and internal energy through the use of

Equations (2.28), (2.34) and (2.35).

Step II is then used to back out the temperature of the mixture given the internal energy and mole fractions by using Equation (2.35) and a root finding schemed such as Newton’s method or bisection. It should be noted that this step does not have to be run during the first iteration since no combustion has taken place but is required all future iterations.

The purpose of step III is to calculate the forward and backwards reaction rates through the use of equations outline in Section 3.1. Originally steps II and III were performed through my own code but in attempts to make the program more flexible, Gaskin is now linked with a free open source chemical kinetics code called

Cantera. Cantera handles all of the error checking and input of the chemical mechanisms, reaction rate constants, and thermodynamic data. Cantera is also used to calculate the temperature from internal energy and forward and backwards reaction rates. This program allowed for more mechanisms to be imported and had previously been shown to produce the same results as CHEMKINTM does with no additional computational time (D. Goodwin 2004). Cantera can also handle the

Shomate form, which is used by the NIST chemistry Webbook (D. G. Goodwin

2003, 33). This form allows for a larger temperature range than the NASA format.

27

Figure 3.1: Numerical procedure for zero dimension combustion analysis

28

Step IV uses Equation (3.10) to calculate the Jacobian matrix needed for the implicit Euler equation.

Step V uses the Euler explicit method to find determine a good value for the time step.

un1 u n   tS n (3.30)

Since the ODE system is stiff, explicit ODE integrators are notorious for being unstable. In general an explicit scheme cannot be used to calculate the change in species compositions. A suitable time step is calculated based on limiting the maximum decrease of a species

 n dtc If dtc min S  umin  dtc   u (3.31) min If dtc min Sn u  n    min  min S 

where Δumin is the maximum allowed decrease of a species. Normal values for Δumin are on the order of -1x10-4 to -1x10-6. If the maximum destruction of all of the species is lower than the allowed amount, the time step is held constant for the current iteration. If the maximum destruction of any one species is found to be higher than the allowed amount, the time step is lowered as per Equation (3.31). A typical time history for the time step used in a zero dimensional combustion problem is shown in Figure 3.2, where the chemical time step is shown in red and the current temperature is shown in green. In order to retain numerical accuracy, the time step 29 decreases rapidly to about one ten thousandth of the initial value. From Figure 3.3, it can be seen that the majority of the computational time is spent during the small period of simulation time i.e., 3.8x10-4 until 4.8x10-4 seconds. It happens right after the induction time of 3.437x10-4 seconds.

Figure 3.2: The time history of temperature and time steps for constant-volume combustion of stoichiometric CH4-O2 mixture diluted with 76.1% Ar. The initial temperature is 1500 K and the initial pressure is 3.0 atm.

30

This is to be expected since the initial increase in temperature is due to the decomposition of the fuel into its constituents and the time step chosen is a function of the maximum decomposition of a species. As it can be seen in Figure 3.2 the time step reaches a minimum value of about 1.0x10-10 s. If this time step is kept constant, the program would take a long time to finish. In order to decrease the number of iterations the time step is allowed to increase as long as the ignition conditions have been meet and the maximum destruction of the species is less than the allowed amount. Through repeated simulations it was found that allowing the time step to double and setting a maximum value of ten times the original value produced good results.

31

Figure 3.3: Time vs. iteration number for the combustion of constant-volume stoichiometric combustion of CH4-O2 diluted with 76.1% Ar. The initial temperature and pressure are 1500 K and 3.0 atm

Step VI solves Equation (3.7), which produces a set of linear equations that is solved using LU decomposition. The linear algebra subroutines known as LAPACK

(LAPACK -- Linear Algebra PACkage 2008) was also used in the program and was found to give the same results as the LU decomposition but the CPU time increased by a factor of about 1.2. It should be noted that the compiler flags used to compile

LAPACK were the same as the ones used by the main program. Many operating systems have their own versions of LAPACK, which has been specifically compiled

32 to run faster on that machine and operating system combination. If this option is used, it is possible that the result may be improved. Steps IV-VI represents the most

CPU intensive part of the program, since it involves calculating the Jacobian and inverting the matrix. The number of equations that needs to be solved is equal to the one less than the number of species present in the mechanisms.

Step VII updates the mole fractions with the results from the step VI.

Step VII checks to see if the ignition criteria has been reached, for all of the

ZeroD test cases a temperature rise of 20 K is used to define the ignition. There are many other methods such as detecting the inflection points in the temperature and pressure history and/or the maximum concentration of various radicals e.g. OH or

CH (Petersen, Kalitan, et al. 2007). A temperature rise was chosen because it was the simplest to implement into the program. It is also an option used by

CHEMKINTM to automatically calculate induction times. When the induction time is found, the end time is also chosen to be 6 times the induction time. This allows for the gases to finish combusting and reach the chemical equilibrium. Since the time step is increasing rapidly during this phase, less iterations are needed as simulation time progresses. For the test case used in Figure 3.2, the lowest multiple of the induction time that produced a final temperature that was close to the equilibrium temperature was about 1.55, which produced a temperature of 3154 K, which is close to the steady temperature of 3157 K. The difference in CPU time between a final time of 6 and 1.55 times the induction time was 2.12 seconds which is about 10% longer. Similar results for a mechanism with more species once the temperature 33 reached equilibrium the CPU time required for additional simulation time went down.

3.4. Validation

When validating Gaskin, it is possible to either compare the results with experimental results or the results produced by another chemical kinetics program.

The advantage with the first method is that the results from Gaskin will be compared with experimental and not simulated results. The problem with the first method is that the quality of the chemical mechanisms chosen will have a large impact on the quality of the results. The second method, where the results from Gaskin are compared with another program, has the advantage in that both codes should produces the same results, i.e. the same induction time and final species composition.

The problem with comparing with another program is that there could be an error in the other program and not with Gaskin. In the end, it was decided that the second method would be most applicable to validate the chemistry solver in Gaskin. The deciding factor was that even if the chemical mechanism has errors in it, they should affect both programs in a similar manner. CHEMKINTM IV was the other program that was used to compare the results with, this program has been in development since the late 1970s and has become a worldwide standard for chemical kinetics calculations.

34

For the validation process three different mechanisms where selected. The first is a H2-O2 mechanism by (Li, et al. 2004). The second one is the GRI-MECH 3.0, a

CH4-air mechanism by (Smith, et al. n.d.). The third one is a propane model compiled by (Williams n.d.). For future reference, these mechanisms will be known as Li H2/O2, GRI and UCSD respectively. The validation will be based on the difference between two separate parameters (i) the thermal induction time based on a temperature rise of 20 K, and (ii) the temperature of the combusted gas after a set amount of time has passed. There are several methods to calculate the induction some based on temperature and pressure or their temporal derivatives. Other methods are based on the concentration of certain intermediate species e.g. OH, CH,

CH3. According to (Spadaccini and Colket III 1994), all of these methods produce similar results. Since the purpose of these simulations is to validate Gaskin, a 20 degree rise in temperature was selected because its calculation is trivial and is a method used by default in CHEMKINTM. The induction time is influenced by both the thermodynamics solver, i.e., the root finding for calculating temperature, and the chemical kinetics, but the kinetics plays a larger role this quantity. This was evident in an earlier version of Gaskin, where an error in the calculating the forward and backwards reactions rates lead to a difference in the induction time of about 40% but only had a marginal, 0.01%, effect on the final temperature. These results can be seen in Figure 3.4 and Figure 3.5. This error disappeared after the calculation of the forward and backwards reaction rates was managed by Cantera but the temperature calculations were performed using Gaskin.

35

Figure 3.4: Comparison of induction times for constant volume combustion of stoichiometric H2/O2 mixture diluted with 70% Ar. The initial pressure for all cases is 1.3 atm. These results are from an old version of Gaskin.

36

Figure 3.5: Comparison of final temperature for constant volume combustion of stoichiometric H2/O2 diluted with 70% Ar. The initial pressure for all cases is 1.3 atm. These results are from a previous version of Gaskin.

37

Figure 3.6: Induction time calculations given different maximum time steps. Combustion is done at constant volume with a stoichiometric coefficient of 1.5, an initial pressure of 0.5 atm diluted with 76.1% Ar. The triangle corresponds with the left y axis while the square and diamond are associated with the right y axis

Another problem that was encountered during testing was that the default time step used by CHEMKINTM IV, which did not always produce accurate induction time as seen in Figure 3.6. Since the reactions become quicker as the initial temperature increases, there is less time to decrease the time step that will produce an accurate induction time. In Gaskin the time step can be changed by a factor of over 10,000 from the initial time step to its minimum time step. The problem with this method is that the CPU time required to finish the simulation increases significantly. For example, in the simulation represented by Figure 3.6, the time required to reach a simulation time of 0.01 seconds went from a CPU time of 18 seconds when the maximum time step was 1.0x10-5 to 40 seconds when the 38 maximum time step was 1.0x10-6 seconds. Furthermore the CPU time went was 4 minutes and 32 seconds when the maximum time step was 1.0x10-7. The results when the maximum allowed dtc was 1.0x10-7 seconds were not used because no significant difference in values were found when the results are compared to that of

1.0x10-6 seconds.

The time step and temperature progression are shown in Figure 3.2, in this figure it can be seen that the time step quickly drops from its initial value of 2.0x10-6 seconds to 1.0x10-10 seconds. To my knowledge CHEMKINTM IV does not have an option to save the local time step used at each iteration. Thus no direct comparison can be made between Gaskin and CHEMKINTM IV. Never the less I would expect similar results.

Originally, the steady state temperature was selected to be the second quantity used to validate. Problems arose when it took too long for some cases to reach a steady temperature. In most cases, the temperature listed was the steady- state temperature. In some cases the temperature after combustion was so high that the products continued to break down which in turn would lower the temperature. In these cases, the temperature used was at a time much higher than the ignition time, such as 0.01 seconds.

3.4.1. The Li H2/O2 Mechanism

The Li H2/O2 mechanism contains 13 species and 25 reactions and no nitrogen chemistry. The model is incapable of modeling true H2-air reaction. The advantage 39 of this model is that it is small. Thus it, does not take a long time to calculate making it a good candidate for testing Gaskin. In order to validate Gaskin, this mechanism was run under various initial conditions, with temperatures ranging from

1000 to 1300 K pressure ranging from 0.5 to 8.0 atm. The equivalence ratio used were 0.5, 1.0 and 1.5. The largest percentage difference in induction time is about

0.40% and the largest percentage difference in the final temperature is about 0.04%.

40

Figure 3.7: Induction time percentage difference between Gaskin and TM CHEMKIN for H2 combustion with 76.1% Ar at various initial temperature and pressures at a stoichiometric coefficient of 1.5.

The 0.4% difference in induction time is equivalent to a time of 2.7x10-6 seconds, which is about 10 times of the maximum time step allowed by CHEMKINTM during this run and 1000 times of the time step allowed by Gaskin.

41

Figure 3.8: Final temperature percent difference between Gaskin and CHEMKINTM for H2 /O2 combustion diluted with 76.1% Ar at various initial temperatures and pressures and at an equivalence ratio of 1.5.

The error in final temperature is small and could be explained by either round off error or the allowed error in the root-finding method used to determine the temperature of the reacting gas mixture.

3.4.2. The GRI Mechanism

The GRI mechanism is a more complex mechanism for CH4-air reactions. This mechanism contains 54 species and 325 reactions which is much larger than the Li

H2/O2 mechanism. The advantage of this mechanism is that it can handle nitrogen 42 decomposition which allows for the study of fuel-air reactions rather than only fuel- oxygen reactions. As with the Li H2/O2 mechanisms the GRI mechanism was run under various temperatures, pressures and equivalence ratios. In this case the temperature, pressure and equivalence ratio ranged from 1300 to 1800 K, 0.5 to 8.0 atm, and 0.5 to 1.5, respectively.

Figure 3.9: Induction time percent difference between Gaskin and CHEMKINTM for CH4 combustion diluted with 76.1% Ar at various temperature and pressures and an equivalence ratio of 1.5.

As seen in Figure 3.9, the largest difference between Gaskin and CHEMKNIN for induction time is about 0.71%. This error is quite small and considering that the

43 induction time at an initial temperature and pressure of 1800 k and 8.0 atm respectively is 1.4 x10-5 seconds. This translates to a difference of 9.6 x10-9 seconds, which is smaller than the time step used by Gaskin. The other two figures for a equivalent ratios of 0.5 and 1.0 have the same trend, but the percent difference between the two results are smaller in magnitude. The difference could be reduced if the Gaskin and CHEMKINTM are forced to use a smaller time step, but this also increases the CPU time required to finish the case.

44

Figure 3.10: Final temperature percent difference between Gaskin and CHEMKINTM for CH4 combustion with 76.1% Ar at various initial temperatures, pressures and a stoichiometric coefficient of 1.5

Figure 3.10 shows the maximum difference between Gaskin and CHEMKINTM for the final equilibrium temperature is 0.016%. The plots for CH4-air combustion when the equivalence ratio is 0.5 and 1.0 are not shown because they follow the same general trend with even smaller errors.

45

3.4.3. The UCSD Mechanism

The third mechanism is for propane oxidation. This model contains 46 species and 235 reactions. This mechanism is smaller than the GRI mechanism. It does not contain any nitrogen chemistry. The publishers of this mechanism also produced a separate mechanism that models nitrogen chemistry if needed. This nitrogen oxidation model contains 13 new species and 53 new reactions. A combined model contains 59 species and 288 reactions. There are other propane mechanisms, which tend to be much larger. For example a propane mechanism created at Lawrence

Livermore (Marinov, et al. 1998) contains 126 species and 638 reactions.

46

Figure 3.11: The predicted induction time percent difference between Gaskin and CHEMKINTM for propane combustion diluted with 76.1% Ar at various temperature and pressures and a equivalence ratio of 1.5.

The maximum difference between Gaskin and CHEMKINTM for the predicted induction time is about 0.3%. Since the induction time is on the order of 2.0x10-6 seconds, this translates to a difference of about 6.0x10-9 seconds which is about 100 times smaller than the maximum time step allowed by CHEMKINTM. This could be related to the same error seen in Figure 3.6, where the maximum allowed time step has an effect on the induction time.

47

Figure 3.12: The predicted final temperature percentage difference between Gaskin and CHEMKINTM for propane combustion diluted with 76.1% Ar at various initial temperatures and pressures and an equivalence ratio of 1.5

The maximum difference in the computed equilibrium temperature was 0.02% and occurred when the initial pressure was 8.0 atm and the initial temperature was

1300 K. The final temperature was 3364.6 K which corresponds to a difference of about half a degree K.

48

3.5. Future Improvements

The results were shown to be in good agreement with CHEMKIN. Future development of the ODE should focus on the making the program run faster. Most methods that can be used to make the ODE integrator faster also make it more unstable.

The first method that can be used is to reuse the inverted Jacobian matrix along with Newton’s method. This method may or may not be quicker than the current method because it requires that that the matrix me inverted completely and not just solved using back substitution. This method can also lead to errors if the Jacobian matrix is reused too many times and the chemical composition has changed so much that it is no longer valid.

The second method is a higher order backwards difference scheme such e.g., the three-point backwards difference, which would result in second-order accuracy.

Another choice is to use a multistep algorithm, e.g., the Adams-Moulton method

(Kreyszig 1999, 954). This is an implicit scheme with a predictor-corrector method.

One downfall of this method is that it is not ―self-starting‖. In other words, it uses data from previous time steps. Thus another method will have to be used until enough previous data is calculated.

The third would be to use a prebuilt ODE integrator such as LSODE

(Radhakrishnan and Hindmarsh 1993) or Sundials (L.L.N.L. 2008). Both of these numerical packages were designed to handle stiff and non-stiff ODE’s and has been 49 successfully used with chemical kinetics codes. LSODE was used by LSENSE which is a chemical kinetics code developed at the NASA Lewis Research Center.

Sundials have been used by Cantera which is currently being used to calculate the thermodynamic properties and the forward and backwards reaction rates. One benefit of using these prebuilt integrators is that they have been extensively tested to be accurate and has its own logic to determine the best time step to maximize efficiency.

50

CHAPTER 4

MODEL EQUATION

4.1. One-Dimension Euler Equations

The one-dimensional Euler equation in one spatial dimension can be expressed in vector form:

UF 0, (4.1) tx

where the vectors are expressed in Equations (4.2) and (4.3). Here ρ, u, E, P and

γ are density, velocity, total specific energy, pressure and the ratio of the specific heats, respectively.

u1   U u v (4.2) 2    u3  E

  u f v 2 1 2  2 3 u FFfP v or u (  1) u 2 (4.3) 23 m  2 2 u1 f vE Pv 3  3  uu  1 u 23 2 2 u11 2  u

51

The total specific energy is related to specific internal energy by,

1 Eev (4.4) 2

To proceed, we apply the chain rule to equation (4.1) to obtain Equation (4.5). In order to derive the Jacobian matrix, A, the flux variables fm needs to be expressed in terms of the flow variables um.

UU A 0 (4.5) tx

  0 1 0 2 F 3  uu22 A   2 31   (4.6) U 2 u1 u1 32 u uu u u u 2 32 3 3 2 2   11 3    u1u1 u 12 u 1 u 1

 0 10    3 A  vv2 3  1 (4.7) 2 3 vE  11 v32  E     v  v 2

4.2. One-Dimension Euler Equations for Reacting Flows

The multiple species Euler equations are more complex due to the inclusion of the source term and the additional species densities. In vector form, the multiple

52 species Euler equation in conservative form is similar to that regular Euler equation with the addition of the source term, S(U), and the multiple species.

UF S()u (4.8) tx m

UF AS()u (4.9) txm

The first three terms are the same as in the regular Euler equation. The fourth through the last terms represent the density of all but the last chemical species in the mixture. Since the total mass is conserved through the continuity equation, the

N 1 density of the final species can be calculated though Ni   . The source i1 term represents the creation or destruction of mass for each species. As with the mass, the final source term can be calculated by knowing that the sum of the source

Ns 1 terms must be zero, since the total mass of the system cannot change,  . NiS  i1

u1  v  0   2    u2 v v p  0  u E vE pv  0  3      UFSu4  1,   1vu , ( m )   1  (4.10) u  v     5 2 2   2            u  v   Ns 2 NNNs1 s  1   s  1 

The conservative form of the multiple species Euler equation is more difficult to calculate because pressure is also a function of the species composition. Unlike the

53 implementation of a typical CFD code, the model equation is not non- dimensionalized due to the inclusion of the finite rate chemistry.

4.3. The Non-Conservative Form

To facilitate the derivation of the Jacobin matrix, the differential equations are expanded and the above equations are transformed into the non-conservative form.

  v v   0 (4.11) t  x  x

 v  v   p v  20vv 2   (4.12) t  t  x  x  x

 E  E  v   v  p E   v   E  vE  p  v  0 (4.13) t  x  x  x  x  x  x

v iiv   iN 1,..., 1 (4.14) xxix i S

Aided by Equation (4.11), Equation (4.12) can be simplified to yield,

vp  1  v   0 (4.15) x  x  x

In the last term in Equation (4.15) pressure is not a flow variable. Pressure is a function of the flow variables. In Section 4.4, we will explicitly derive the relationship. Equation (4.13) can be simplified by substituting Equation (4.11) multiplied by E and by expanding E through Equation (4.4) resulting in,

e  e P  v v   0 (4.16) t  x  x 54

Equations (4.11), (4.14), (4.15), and (4.16) can be rewritten in vector form yielding,

UU AS()u (4.17) xxm

  where US and are

u1   0     u2  v  0 u e 0 3     U u4 1,Sum    1 (4.18) u   5 2 2     u   Ns 2  NNss11   

and the Jacobian is

v  0 0 0 0  p p p p p  v e 12 N1       p 0v 0 0 0 A   (4.19)  00001 v  0 0 0v  0 2       0 0 0 0 v N 1

Where pρ, pe and pρi are partial derivates of pressure derived in Section 4.4.

55

4.4. Calculating ∂p/∂x

The definition of the partial derivative of pressure with respect to x is more difficult since the partial derivatives need to be functions of the flow variables.

Using the chain rule the partial of pressure can be expressed as:

pe   Ns 1  p  p  p i (4.20) e  i x  x  xi1  x

Where pρ, pe and pρi are equal to:

p p , iN 1, ,s -1   e,i p pes  , iN 1, , -1 (4.21) e , i p p , j 1, , N -1, j i i  s i  ,,e j

Based on the Ideal gas law, pressure can be represented in terms of density, temperature and species densities:

N Ns 1  i  11 pRT Roi T Ro T     (4.22) i1 M MMi1 M i Nss i N

Since pressure is not an unknown, the calculation of ∂p/∂x is more involved.

Equation (4.22) will be used to derive ∂p/∂x in the momentum equation. Essentially,

Equation (4.22) shows that p=p(ρ,ρi,T) and thus 56

pp Ns 1 p dp d  dT   d i (4.23)  T , i1  i T ,i i ,,T j

In this equation j = 1,…,Ns-1 and j≠i. The partial derivatives in Equation (4.23) can be calculated by using Equation (4.22) as seen below.

 p  RTo    (4.24)  M T ,i Ns

p  R (4.25) T , i

p 11  R T  (4.26)  o  iNMMi ,,T j s

In Equations (4.24)-(4.26) the subscript i and j have the same definition as in

Equation (4.23). These equations can then be substituted back into Equation (4.23), which will lead to the derivation of the partial derivatives in Equation (4.21).

Ns 1 RTo 11 dp  d  RdT  Roi T     d  (4.27) M i1  M M  Nss i N 

To find the term pρ, Equation (4.27) can be divided by dρ to yield

pT RT  Ns 111    oiR  RT     o     MMMN  i1 i N    e,,,   e iis   e  (4.28) RTo T  R 0 M  Ns  e,i

57

In Equation (4.28) i is defined the same as it is in Equation (4.23). To find

(∂T/∂ρ)e,ρide is expanded using the chain rule in terms of T and ρ and by keeping e constant:

ee de  d  dT =0 (4.29)  T T 

Te  1        (4.30)  e, CV  T

Finally (∂e/∂ρ)T can be expressed in terms of ρ, ρi and ei as

e Ns 1  i ee    iNs   i1  T  (4.31) 1 Ns 1  ee 2  i i Ns   i1

Combining Equations (4.31), (4.30), and (4.28), an expression for pρ can be found:

pRRT Ns 1   oiee (4.32)    iNs  MCi1 e,i NVs

To find pe Equation (4.27) is divided by de and through the use of the definition of specific volume, we have

pT RT       Ns 11 1  oiR RT        o   e ,,,  MN   e      e    i1 M i M N   e iss i i , i (4.33) T 0  R 0 e , i

58

R Pe  (4.34) CV

The last partial derivative to be calculated is pρi. This is done by dividing

Equation (4.27) by dρi:

Ns 1 pT RToi       11      R  RoT     MMM    i1   i e,, Ns  i  e,,   i  e   i N  i  e  (4.35) T 11 0 R  RTo   MM ie,  i Ns

(∂T/∂ρi) is derived in the same manner that (∂T/∂ρ) was in Equations (4.29) to

(4.31).

NS 1ee de di dT (4.36)   T i1 i T i

T  1 NS 1  e       di (4.37) iVC i1 i  ,,e j  T

NS 1e 1 ee (4.38)    iNs  i1 i ,,e j

In Equations (4.36) to (4.38) i=1,Ns-1 and j=1,Ns-1, j≠i, by combining these equations pρi can be expressed as

R 11 p  e e  R T   (4.39) is i N o C V MM iNs

59

4.5. The Jacobian Matrix

Directly calculating the Jacobian matrix listed in Equation (4.9) would be difficult. Instead, the Jacobian matrix in Equation (4.17) will be derived and then manipulated so that the original conservative equation can be used in the CFD method. In order to get Equation (4.17) back to the original form, the entire equation is pre-multiplied by (∂U/∂ U ) and the flux term is multiplied by one in the form of

UU  inserted in between the Jacobian and the flux term:  U U

UUUUUUU      F ()u               m S()u                  m UUUUU tx       U           (4.40)

The above equation can be rewritten as:

UU F ()u   T Tm T1 T TS()u (4.41)     m tx  U   

where

1 0 0 0 0 0  v  0 0 0 0 Ev0 0 0 U  T   0 0 0 1 0 0 (4.42) U  0 0 0 0 1 0         0 0 0 0 0 1

60

1 0 0 0 0 0 v 1  0 0 0 0   v2  E v 1 U  0 0 0 T1    (4.43) U  0 0 0 1 0 0 0 0 0 0 1 0         0 0 0 0 0 0 1

This Jacobian is in terms of u . Refer back to Equation (4.40) the true Jacobian matrix from the conservative form can be found because A TAT 1 :

0 1 0 0 0 0  2 pe e  p e  p e vv1  pp   eN 2  p 1 p  2 p   1 2       S  22 v e v pe vH  p  pe  p e H p e v1   vp 1 vp  2 vp  N  1 2    S  v  A  1  1 0u 0 0   

 v 2    2 0 0u  0                 v NS 1   N 1 0 0 0 u  S  (4.44)

It can further be shown that F is a homogenous function of U of the first order.

U This can be shown by taking the product of A with should yield F from x

Equation (4.8). 61

v  v Ns 1 vp2  p   vp2 pp       ii  1 1 NN 1 1 i1 N 1 v Epp   p  S   1 1 NN 1 1     vEpp  ii   AU    i1 (4.45) v1    v  v1  1    v1       vN 1     vN 1

Using Equation (4.32) and (4.39), Equation (4.45) can be simplified to be

v  Ns 1  2  11 v  RTo  i  MMMi1  Nss i N   Ns 1 11 vE  R T    AU  o  i   (4.46) MMMi1  Nssi N v 1 v1     vN 1

Equation (4.46) can be simplified further by Equation (4.22), to get back to the original definition for F found in Equation (4.8):

62

v 2 v  p vpE    AUF  v1 (4.47)  v 1     vN 1

Since the CESE method is explicit, it is important to keep track of the CFL number. The CFL number is a dimensionless number for determining the stability of

at the numerical method and is equal to CFL  , where a is the maximum x eigenvalue number from the Jacobian matrix A. The derivation of the eigenvalue is shown below.

det AI 0 1 Ns 1  p 2 (4.48)  u p  pi  p ,,,,u u u  ie2 i1  

The first two terms in the prentices can be reduced to p/ρ through a similar method as done from Equations (4.45) to (4.47) and the pe term can be expanded by using Equation (4.34) yielding

1 1 p p R2  p p 2 uu2  (  1)  CV    (4.49) 1 p 2 uu     a f   

63

where af is the frozen speed of sound. It is called this because it is assumed that the species composition is constant and is defined by:

2 p a f   (4.50)  s,,, Y Y 1 NS

In this case it is practical to model pressure as a function of ρ, e, and ρi and applying the chain rule to get a value for dp.

p  pNs 1  p dp  d de  d i  e   e,,, , iN,,  1 i1 i ,,ej1,, N 1, j i iNS 1 S j s (4.51) Ns 1 pdd  p de  p ei i i1

Substituting Equations (4.32), (4.34) and (4.39) into Equation (4.51). differentiating with respect to ρ and keeping entropy and mass fractions constant yields

p RT RNS 1   R  e   oiee       iNS    MCCi1    s,,,,, Yi Y N11NVVS   s Y Y N sS (4.52) NS 1 11R  RT   e  e i  o i Ns   i1 MMCi N V  s,,, Y Y s 1 Ns

In order to find the partial of e with respect to ρ, the Tds equation,

Tds de pdv , is used and the result is

ep    2 (4.53)  s, Y, ..., Y 1 Ns

64

To find the partial of ρi with respect to ρ the definition of mass fraction is used yielding

ii    (4.54)  sY, ,...,Y 1 Ns

Aided by Equations(4.53), (4.54) and simplifying yields

p R p 1NS 1  1 1  RYT   (4.55)  2 oi  s,, Y Y CMMv Ni1 iM N iNs1  

Using Equation (2.15) and rearranging yields

2 pR af   RT 1    RT (4.56)   s,,, Y Y C v 1 NS

65

CHAPTER 5

THE CESE METHOD

5.1. Introduction

The Conservation Element and Solution Element, CESE, is a relatively new approach to solve the nonlinear hyperbolic systems of equations. This scheme is explicit and its stability is a function of the CFL number only (S.-C. Chang 1995) .

The CESE method does not use extrapolation or interpolation when calculating the fluxes. This leads to the ability to capture shocks without using Riemann solvers (S.-

C. Chang 2006). The CESE scheme is numerically inexpensive. In dealing with multiple species, the number of governing equations is equal to the number of species plus two. This relates to anywhere from a dozen to over a hundred equations. If an implicit scheme was used, a set of linear equations would have to be solved at each time step and grid point. The CESE method defines the Conservation

Element, (CE), and Solution Element, (SE), separately. They are both non- overlapping space-time domains. The definition deviates when it comes to flux conservation, discontinuities and how they fill up the computational domain. The union of all CEs covers the entire computational domain whereas the SEs do not.

66

Inside a CE, flow discontinuities are allowed. Flux conservation is enforced over each CE. A SE does not have to coincide with a CE. The flow variables and fluxes are assumed continuous and approximated by a first-order Taylor series in a SE.

Refer to Figure 5.1 for a layout of the CEs and SEs.

5.2. CESE Scheme for the Euler Equation

For one dimensional flow the model equation is

uf 0 (5.1) tx

Where u is the unknown variable and f is the flux. Applying the Gauss divergence theorem to Equation (5.1) yields,

hsd  0 (5.2) SR()

Where R is the space-time region in the two-dimensional Euclidean space, S(R) is the boundary of the region, and ds = dσ n where dσ and n are the area and outward normal vector of a differentiable piece of the surface element. Refer to Figure 5.2 for a diagram of the integration.

67

Figure 5.1: The grid set up for the CESE method

68

Figure 5.2: Space-time integration over an arbitrary region.

The flow variables are considered to be continues inside a SE and are represented by a first order Taylor series. For all (x,t)  SE(j,n) , u(x,t), f(x,t) and h(x,t) will be approximated by u*(x,t), f*(x,t) and h*(x,t) respectively. Thus,

u(,;,) x t j n uunnnnx x  u t t (5.3) j x jj j  t   

n Where (xj,t ) is the mesh point (j,n) at the center of SE(j,n), ux is ∂u/∂x, ut is

∂u/∂t. The same can be done with the flux terms. Refer to Figure 5.1 for the stencil used in the CESE method.

f(,;,) x t j n f nnfnn x x f t  t (5.4) j x jj j  t   

As before fx and ft are equivalent to ∂f/∂x and ∂f/∂t at (j,n). A useful value is

f  n  fu/ , here ∂f/∂u represent the differential of f with respect to u. If f and u   j

69 are vectors,  f  is a Jacobian matrix. With this assumption, fx and ft can be rewritten as,

n n n  ffxx   ' u  j j j (5.5) ffn ' nu n  tt j  j  j

Because h=h(u,f) then,

h***(,;,)xtjn ( uxtjn (,;,), f (,;,)) xtjn (5.6)

Since u=u*(x,t;j,n) and f=f*(x,t:j,n) it can be assumed that for any (x,t)  SE(j,n) that,

u**(,;,)(,;,) x t j n f x t j n 0 (5.7) tx

Aided by Equations (5.3) and (5.4) Equation (5.7) can be rewritten as

u nn f (5.8)  tx jj 

Using Equation (5.5) is can be seen that f n is only a function of u n and u n  x  j j  x  j

. Equation (5.8) states that u n is a function of . Therefore, the only  t  j independent variables are and .

To proceed, we perform space-time integration over the CE to derive the equations necessary to update the flow variables. Each grid point is associated with a single CE. The flux conservation is imposed by calculating the flux at the 70 boundaries of CEs. It is assumed that both u n and u n are known at the previous j  x  j time step, i.e. un1/2 and u n1/2 are known for each mesh node (j,n). The flux j1/2  x  j1/2 conservation formula is the same as Equation (5.2) where S(R) = S(CE(j,n)),

hs* d  0 (5.9) S( CE ( j , n ))

After applying flux conservation

n n1/2 n  1/2 n  1/2 n  1/2 u j u j1/2 u j  1/2 s j  1/2 s j  1/2  /2 (5.10)

where

2 xnn  t  t snn u  f  f  (5.11) j44 xjjxx j t

In order to solve u n at (j,n), a modified central differencing average is used.  x  j

The modification is used so that it can handle discontinuities better.

n nn ux   u x   u x  (5.12) j jj

with

 nn2 uux   j1/2 u j  , (5.13) x

and

71

t n1/2 uunnu  (5.14) j1/2 j 1/2 2 t j1/2

Since the flow could have discontinuities, i.e. shock wave, a re-weighting procedure is needed to suppress overshoot. This is done by adding artificial damping in the form of reweighting.

un  W u,,, u   x j  x  x    (5.15) xxxx    W(,,) x x    xx

α ≥ 0 is a constant. As the value of α increases, W approaches the smaller of x- and x+. Normal values for α are 1 or 2.

5.3. CESE Scheme for the Chemically Reacting Euler Equation

The scheme shown above is modified to solve the one-dimensional Euler equation for chemically reacting flows with a source term. The model equation is now

uf mmŞ (5.16) ttm

Where m=1,…,Ns+2 and the source term, Ş , is a function of um. Using the

Gauss divergence theorem produces

h ds Ş dR (5.17) SR()R m m

72

For any (x,t)  SE(j,n), um(x,t), fm(x,t) and hm(x,t) can be approximated by u*(x,t;j,n), f*(x,t;j,n) and h*(x,t;j,n), respectively. Using the first order Taylor series,

* a value for um can be found to be

u* (,;,) x t j n un u nx x  u n t  t n (5.18) m m j mx j j  mt  j  

It is necessary to express f as a function of u , to do this we let f n and m m  m  j

n n f represent the value of fm and fu/ for m,k = 1,…,Ns+2. Let u be  mk,  j mk  m  j equal to um. Since

fNs 2  f  u m m k x  u  x k 1 k (5.19) fNs 2  f  u m  m k tk 1  uk  t

 f n  f n the terms mx j and mt j can be rewritten as

Ns 2 fn f n u n , mN 1,2,...,  2 (5.20)  mx j  mk j kx j S k1

and

Ns 2 fn f n u n , mN 1,2,...,  2 (5.21)  mt j  mk j kt j S k1

f n and f n is the numerical counterpart of ∂f /∂x and ∂f /∂t, respectively.  mx  j  mt  j m m

This leads to the equation 73

f*(,;,) x t j n fn f nx x  f n t  t n (5.22) m m j mx j j  mt  j  

Since hm is a function of both fm and um, it can be stated that

*** hm(,;,)xtjn ( u m (,;,), xtjn f m (,;,)) xtjn (5.23)

f n f n  m  j  mk  j As with the previous scheme for any m =1,…,Ns+2 all flux terms , ,

 f n  f n u n u n u n mx j , and mt j are functions of m j , mx j and mt j only. For all (x,t) 

* * * SE(j,n), um =um (,;,)x t j n , fm = fm (,;,)x t j n and Şm = Şm (,;,)x t j n it must satisfy

Equation (5.16) such that

u**(,;,)(,;,) x t j n f x t j n mmŞ(,;,)* x t j n (5.24) ttm

If it is assumed that Şm is constant within a SE, Equation (5.24) can be rewritten as

ufn  n  Ş n  mt j mx j m  j (5.25)

As stated above all flux terms are functions of um and its time and space derivatives. Aided by Equation (5.25) all flux terms can be written as functions of

and .

In order to solve for the flow variables at the new time step the flux over time- space CE(j,n) needs to be calculated, resulting in

74

hs* dŞ dR (5.26) S( CE ( j , n ))m CE ( j , n ) m

The result of which is

nnt u  Ş  mmjj4 (5.27) 1 n1/2 n  1/2tt n  1/2 n  1/2 n  1/2 n  1/2 um  u m ŞŞ m  m   s m   s m  2j1/2 j  1/2 4 j  1/2 4 j  1/2 j  1/2 j  1/2

where

2 nx n  t n  t n s  u  f   f  (5.28) mj44 mx jxx m j mt j

All values on the right hand side of Equation (5.27) are calculated based on

solution at the previous time step. The source term Şm can be calculated through

chemical kinetics as outlined in Chapter 3.2. Now um can be calculated at all grid

nodes at time t. The calculation of umx is carried out in the same manner as described by Equations (5.12) through (5.15).

5.4. Boundary Conditions

The Boundary conditions for the one-dimensional code are relatively straight forward. Since the goal is to model an actual shock tube, a reflecting boundary condition is used at both ends. Since the CESE method uses a zig-zag mesh, the boundary conditions are only computed at every other time half time step. The boundary conditions are applied through the use of a ghost cell, where the values in the ghost cell are specified so that the velocity at the boundary is zero. All other 75 quantities (density and energy in the ghost cell) are the same as that in the immediate interior node. A ghost cell is a cell that exists outside of the domain and its value is chosen so that the correct boundary conditions are applied. This is done by setting

the um, ghost associated with velocity to the negative value and the umx, ghost term to the

same value, for the Euler equation this is u2 and u2x . All other um, ghost terms are set to the same value and the term is set to the negative value.

76

CHAPTER 6

SHOCK TUBE

6.1. Introduction

This chapter illustrates the basics of a shock tube, the shock tube setup, and the basic equations of the shock-tube flow, and why it is used to study combustion.

6.2. General Layout

A shock tube is a long cylinder, generally greater than 6 meters. Initially, a shock-tube is divided into two different regions by a diaphragm. On one side, there is a high pressure gas called the driver gas. On the other side, there is a low pressure gas called the driven gas. The driver gas is usually a noble gas, e.g., He, Ar or a combination of inert gases. The driven gas is a mixture of the intended fuel, oxidizer and a bath gas. Typically the bath gas makes up 80% - 95% of the gas mixture by mole fraction. The bath gas can either be a non-reacting gas such as Ar or a reacting gas such as N2.

The experiment starts when the diaphragm is broken either through material failure or a mechanical valve. A shock wave moves through driven gas and an expansion wave propagates through the driver gas. The initial shock waves create 77 four regions: (1) the driven gas, (2) the shocked gas, (3) the expansion wave, and (4) the driven gas. A fifth region is formed when the shock wave moving through the driven gas and reflects off the end wall. The initial set up can be seen in the top diagram of

Figure 6.1. As the shock wave moves through the driven gas, creating section 2, the temperature, density and pressure increases. After the shock wave reflects the temperature, density and pressure are increases again by the reflected shock wave creating section 5. Refer to

Figure 6.1.

Figure 6.1: Wave dynamics in a shock tube experiment.

78

The arrows show the moving direction of the shock and expansion wave in the shock tube. The shock waves are denoted by thick black lines, the contact discontinuity is shown by a thinner vertical line, and the expansion wave is shown as a series of lines that gradually become further apart. The number of lines is inconsequential to the strength of the expansion wave. Typically, combustion experiments start in section five after the reflected shock wave is formed. This is because the incident shock wave produces a temperature that is too low to start the combustion process. In Figure 6.1, the reflected shock wave moves towards the left, while the expansion wave reflected off from the other end is heading to the right.

As seen in Figure 6.1, the reflected shock wave moves towards the left while the contact discontinuity moves towards the right. The interaction between these two waves has two results: (1) the reflected shock reflects off the contact discontinuity and move towards the right, just like the original shock waves. This one will increase the temperature, pressure and density of the gas mixture behind it. (2) The shock wave will move through the discontinuity again raising the fluid properties behind it. The right moving shock wave could causes ignition if the gasses have not had a chance to fully combust.

On the other side of the diaphragm, the expansion wave decreases the temperature density and pressure in its wake while moving towards the left. When the head of the expansion wave hits the left wall, it will reflect and interact with the original expansion wave which is moving towards the left. This interaction now lets the fluid temperature and pressure to decrease further. The expansion wave will 79 continue to move towards the right and pass through the reflected shock wave resulting in a decrease in the flow properties behind the reflected shock wave. This typically marks the end of the shock tube experiment because the expansion wave will lower the temperature of the combustible gases.

6.3. Analytical Solution

One advantage of using a shock tube is that the analytical solution exists if there are no chemical reactions and the gas is calorically perfect. This model is helpful in setting up a shock tube experiment since it can be used to give a first order estimate for the flow variables in regions 3 and 5 given the initial conditions. Since the temperature in section 3 is normally below the temperature needed for ignition to occur, it is safe to assume that the species are in a frozen state, i.e., no chemical reactions taking place. As long as the value for the specific heat is chosen at a temperature close to that in Section 3 then the results should be reasonable. One improvement that can be made is to assume that the specific heat is not constant across the shock wave. The improvement comes at a cost in that the calculation of the post shock states are no longer analytical and require a root finding method.

The equations for the relationship of the state variables across a moving shock wave are the same as those across a stationary shock tube. A summary of the shock relation equations from (Anderson 2003) are shown below.

2 2  1 M s  2 (6.1) 1 21  M s 80

p2 2 2 11 M s   (6.2) p1  1

Tp   2  2  1  (6.3) Tp1 1  2 

where MS is the of the incident shock wave. Once the shock reflects off of the far end, the reflected shock Mach number, MR, can be used instead of Ms in Equation (6.2) to determine ρ5/ρ2, p5/p2 and T5/T2. If only the initial pressure ratio, p4/p1, is known then p2/p1 will have to be calculated from:

2 4  4 1 ap    11 12 4    pp42 ap41   1 (6.4) pp11  p2 212  1   1  1 1  p 1

This equation cannot be explicitly solved for p2/p1 so Newton’s method is used to solve for p2/p1. Once p2/p1 is calculated Equation (6.2) is used to find MS. The next step is to calculate the post reflected shock conditions, which are a function of the

MR. MR is only a function of the specific heat and the incident shock strength as seen below:

M R M S 21   2 1 2 21 2 M S 1  2 (6.5) MMMRSS11 1  

81

This along with the equation for the speed of sound will provide an estimate for the post shock conditions as well as the initial conditions that are required to produce these quantities.

These equations can be rearranged so that it is possible to start with the post reflected shock conditions and work backwards to get the initial conditions, which is a more practical approach since the post reflected shock conditions are the test conditions for combustion. Equation (6.5) can be solved for MS such that

2 2 2 2 M RRRMM21  M S  2, 2 2 (6.6) 2M RRR 1 MM2  

There are four possible solutions to this equation, but the only physically possible solution is when MS is a positive real number greater than MR. In order to determine which of these solutions is physically possible the limit of Equation (6.5) is taken as

M S . The result of which is

2 M 2  (6.7) R  1

2 If this solution to M R is substituted into Equation (6.6), the results should be infinity. Equation (6.6) now becomes

21    1 M S  ,  (6.8) 31  0

82

The first two solutions are not possible because the equation did not go to infinity. This leaves two possible solutions

2 1  2M R M S  22 (6.9) 2MMRR2

Since MS must be a positive real number, the negative root is invalid. Therefore the solution must be

2 1  2M R M S  22 (6.10) 2M RR2 M

Another useful value that can be obtained is the time that it takes for the contact discontinuity to reach the reflected shock wave. This is important because the interaction between the two waves will results in shock waves moving in both directions. The right moving shock will increase the flow variables in the test section. The equation used to determine the speed of the contact discontinuity, up, can be found in (Anderson 2003),

1/2 2 ap 1 u  121  (6.11) p p  1  p1 2  p1  1

Another important aspect is the dwell time (Kahadawala, et al. 2006), defined as the time period that starts when the incident shock wave reflects off of the far end and ends when the expansion wave starts to cool down the hot gas in the test zone.

83

The equations that govern driver gas are based on the method of characteristics and the Riemann invariants. The eigenvalues of the Jacobian matrix which for the one dimensional Euler equation are u, u+a and u-a. The Riemann invariants are constants of lines along the characteristic lines. For a calorically perfect gas the

Riemann invariants are

2a Ju  (6.12)   1

2a Ju  (6.13)   1

where J+ and J- are the right and left Riemann invariants, respectively. u is the local speed a is the local speed of sound and γ is the specific heat (Anderson 2003).

Equations (6.12) and (6.13) can be solved for u and a in terms of J+ and J-

 1 a  J  J  (6.14) 4 

1 u  JJ  (6.15) 2 

The flow properties can be determined by looking at the right running Riemann invariant since they are constant Equation (6.12) can be written as

22a a u 44 0   constant (6.16) 4 11

Combining Equations (6.12) and (6.16) yields

84

au 1 1  (6.17) aa442  

By using the definition for the speed of sound and the isentropic relations

Equation (6.17) can be used to find the local temperature, pressure and density:

2 Tu 1 1  (6.18) T4 a 4 a 4

2 pu 1  1 1  (6.19) p4 a 4 a 4

2 u 1  1 1  (6.20) 4aa 4 4

All of these equations are still a function of the known properties from Section 4, and the fluid velocity which is unknown. In order to find what the velocity is at a particular location, x, the first derivative of location with respect to time, dx/dt is to be set equal to the velocity of the left running wave or

dx ua (6.21) dt

x  u at xd (6.22)

In this equation xd is the location of the diaphragm that separates the driven and driver gasses. This equation can be combined with Equation (6.17) to form

85

 1 xua4  u t (6.23) 2

Or solving for velocity

2 x u  a4   (6.24)  1 t 

This equation gives an expression for u as a function of x and t in the driven gas.

Since the local properties, p, T and ρ are functions of u these function can now be expressed as functions of x and t as well. The system becomes more difficult after the fastest wave reflects from the end wall and starts to head back to the right because of the interactions between the two waves. When a left running wave collides with a right running wave new values for velocity and speed of sound needs to be calculated from these two new values for J+ and J- have to calculate as well.

Equations (6.14) and (6.15) are used to determine new values for speed of sound and velocity respectively these new values in turn allows for the calculation of both J+ and J- leaving a point. Up until now the flow variables can be calculated without the aid of a computer, but the calculation of the properties inside of the non-simple region require the use of a computer. Table 6.1 shows a comparison between the analytical and CFD solutions for a shock tube that has a 3 meter long driver section and a 6 meter driven shock tube. All of the percent difference for the flow properties between the analytical and CFD solution are less than 1%, it should be noted that the solutions from the CFD solution assumed that there were no chemical reactions taking place. This is a valid assumption since O2 and N2 are inert under the given

86 conditions and the amount of dissociation at this temperate is inconsequential. The difference in the dwell time is about 10 percent. The large difference could be caused by an assumption made in the analytical solution. The speed of the reflected shock wave does not change when it passes through the contact discontinuity.

Initial Conditions Analytical Solution CFD CESE Solution Driver Driven Incident Reflected Incident Reflected (3 meters) (6 meters) Pressure 0.5 0.1 0.2128 0.4195 0.21264 0.41869 (atm) Temperature 300 300 376.9 461.7 379.48 460.95 (K) Shock wave N/A N/A 486.9 327.3 486.18 324.7 speed (m/s) Dwell time N/A N/A 8.277 9.099 (m sec)

Table 6.1: Comparison between analytical and CFD solution for Air with specific heat equaling 1.4 as both Driver and Driven gas.

87

Initial Conditions Analytical Solution CFD CESE Solution Driver Driven Incident Reflected Incident Reflected (3 meters) (6 meters) Pressure 0.5 0.1 0.2139 0.4276 0.21295 0.42199 (atm) Temperature 800 800 976.9 1169.7 981.98 1173.3 (K) Shock wave N/A N/A 780.7 500.0 784.0 505.0 speed (m/s) Dwell time N/A N/A 6.343 5.761 (m sec)

Table 6.2: Comparison between analytical and CFD solution for Air with specific heat of 1.3283 as both driver and driven gas.

The percentage difference between the analytical and CFD method is a little higher, when the initial temperature is increased from 300 to 800 K. In this case, the highest percentage error is between the reflected pressures and is about -1.3 %. The value for specific heat ratio in this case is 1.3283, which is the value for air at 1100.0

K and 0.25 atm. The temperature and pressure were selected because they are close the average value between the incident and reflected temperatures and pressures.

The large difference between analytical and calculated dwell time can be explained by the assumption that the speed of the reflected shock wave does not change much when it passes through the contact discontinuity. Even though the percentage differences are higher in this case, the results are reasonable at the elevated temperatures. This shows that if the proper specific heat is chosen, the analytical model is a good tool to use.

88

Another source of error in the analytical solution is that it uses the same value for specific heat throughout the program. It would be more accurate if the program used different values of specific heat based on the local temperature of the gas that the shock wave propagates into.

6.4. Numerical Method for the Shock Tube

The main goal of this thesis is the development of a numerical tool to model a chemically reacting flow inside of shock-tube. In order to understand how this is accomplished the program has been split up into eight different tasks with step II through VIII repeating throughout the execution of the program. These tasks as well as when and under what conditions they are applied are shown in Figure 6.2.

During Step I the required data is imported, including (i) the chemical mechanism, (ii) the time and space steps, (iii) the shock tube set up, and (iv) the thermodynamic coefficients. In order to make the program more flexible, all arrays are dynamically allocated, i.e., the size of each array is specified when the program is executed and not when it is compiled. Another important task performed during

Step I is that the initial space derivatives are calculated using the Equations (5.12) through (5.15). This task is important because it will reduce the error around discontinuities at the beginning of the program. Generally, this step is not needed because the shock wave that is generated around the partition between the driver and driven gases would overwhelm the initial error.

89

Figure 6.2: A flow chart of the computer program GASKIN. 90

This is needed when a discontinuity in density exists. This situation is encountered between the driven and test sections if different gases are used. In order to fix this problem, the concentration of the interfacial gas was gradually changed using a sine function until no driven gas remained. It is in this regime that the du/dx term is more important since there is no shock wave to negate the numerical error.

Figure 6.3: The calculated temperature profile before the incident shock wave passes into the test section.

91

Figure 6.4: The calculated temperature profile after the shock wave passes into the test section.

In Figure 6.3 and Figure 6.4 the sold red line is the solution where dissipation was added to the interface in between the driven and test section. The green symbol

+ is the solution in which no dissipation was added in between the two sections. Ar is used as the driver. The driven gas is composed of H2 and O2 at the stoichmetric ratio and diluted by Ar at 70%. The pressure is 1.0 and 0.1 atm for the drive and driven, respectively. The temperature is uniform at 850K. What is important in

Figure 6.4 is that the error is present after the shock wave passes through.

92

Step II retrieves the current array of flow variables from the larger two- dimensional array and calculates flow properties, including density, total and specific internal energy. The temperature is calculated through a root finding method described earlier. This step is also responsible for calculating the flux terms found in

Equation (4.10) represented by the one dimensional array F. During this step the

Jacobian matrix represented by the two dimensional array A in Equation (4.9) is calculated. The last task that needs to be completed is the calculation of the CFL number.

During step III the partial derivatives df/dx, du/dt and df/dt are calculated and then are used in Equation (5.28) to find sm. After step III, the program has to determine whether or not the current gas mixture is going to be affected by the chemical kinetics subroutine. Currently, the program can only determine whether or not the chemistry needs to run. The decision is currently based on the current temperature and the chemical species in the gas mixture in the cell.

Figure 6.5 shows the process employed to determine whether or not it is necessary to run the chemical kinetics part of the program. It works by initially assuming that chemistry needs to be run and then tries to find a reason to skip it. It first checks to see if the percentage of nonreacting gas is greater than 99%. If it is, the subroutine ends and the chemical kinetics are not calculated. On the other hand, if it is less than 99%, the subroutine continues. The non-reactive gases are chosen by the user in the input file. Typical species that are included in this group is Ar, and

N2, if the mechanism employed does not include nitrogen chemistry. The second test 93 is simpler. It only tests to see if the current temperature is greater than a critical temperature designated by the user. If the current temperature is found to be greater than the critical temperature, the chemistry part of the program is run. If the temperature is found be less than the critical temperature, the chemistry is skipped for this current iteration. A typical temperate to pick is in between the temperatures of the incident shock and the reflected shock, as will be discussed later this is not always a safe assumption to make. What this does is to keep the gas composition frozen until after the normal shock reflects off from the closed end of the tube. The purpose of this is to decrease the CPU time required to complete the simulation.

This time saving feature can have an impact on the efficiency of the simulation.

94

Figure 6.5: The flow chart of logic for determining if it is necessary to run the chemistry calculation in the shock-tube code, i.e., GASKIN.

95

Figure 6.6: The calculated temperatures in the shock-tube simulation showing the temperature history at a location 2 mm from the end wall when the initial temperature is uniform at 700 K.

Figure 6.6 shows a shock-tube simulation where the driver section is Ar at a pressure of 1.0 atm and the driven section is a mixture of H2, O2 and Ar with a mole fraction of 0.2, 0.1 and 0.7, respectively. The initial temperature was constant throughout at 700 K. The total length of the shock tube is 1 meter long with the driver section taking up 45% of the length. This length is smaller than most research shock tubes but was kept to a smaller size to decrease the amount of CPU time required to complete the simulation. The red + symbols represent a simulation where combustion was not started until after the reflected shock. The green x is a 96 simulation where the combustion subroutine was never skipped for the driven gas.

In this case, the two results are identical which means that the assumption of a frozen gas state before the reflected shock was accurate. This is opposite to the results seen if Figure 6.7, which has the same set up of Figure 6.6 but with the initial temperature at 750 K. In this simulation, the temperature after the incident shock wave was high enough to start the combustion process. If the shock tube was longer than 1 meter the combusting gas could overtake the shock wave. In the actual combustion process, when the initial temperature was 700 K, the ignition would occur behind the wake of the incident shock wave as seen in Figure 6.8. However, it did not finish before the deflagration wave reached the edge of Section 2.

97

Figure 6.7: Shock tube simulation showing the temperature history at a location 2 mm from the end wall when the initial temperature is uniform at 750 K.

98

Figure 6.8: Shock-tube simulation showing the mole fractions and temperature at a time 0.79031 msec.

The Reason for this can be seen when the induction time from a zero dimension simulation is compared to the time it takes for the fuel to start to combust.

These results are tabulated in Table 6.3. The figure corresponds to an initial temperature of 650 K is not shown in this thesis because it does not contain any information that is not provided by Figure 6.6. The time that separates the induction time predicted by the zero-dimension simulation and the time that it takes for the incident shock wave to reach the far end are 4.5x10-5, 1.2x10-3 and over a second when the initial temperature is 750, 700 and 650 K respectively. This means that the 99

ZeroD model predicts that the shock wave will reach the closed end before the combustible gas starts to ignite.

Initial Temperature (K) 650 700 750

Pressure (atm) 0.39 0.39 0.39

Incident Temperature (K) 832 900 960

Induction time ZeroD (sec) 1.175 1.98 x10-3 7.947x10-4

Induction time shock-tube not 9.2x10-4 8.3x10-4 7.3x10-4 frozen (sec) Time until reflected shock frozen 8.1x10-4 7.8x10-4 7.5x10-4 (sec)

Table 6.3: Comparison between the induction times calculated using a zero- dimensional simulation and the time it takes from the time on which the gas starts to combust inside a shock tube simulation.

Step IV is the part of the program that the chemical calculations are performed, the numerical procedure is similar to that one outlined in Section 3.3.

The main difference between Step IV and the numerical method for the zero- dimensional simulation is that the chemical time step, dtc, is not allowed to change.

This makes the selection of the chemical time step more difficult because a value that is too large will lead to an incorrect solution. On the other hand, a value that is

100 too small will cause the program to take a long time to complete. Attempts were made to include a variable chemical time step, but the early results produced a simulation that took longer to finish with similar results as those without a variable chemistry time step.

Figure 6.9: The calculated time history of the maximum sum of mass fraction and the temperature at 2 mm from the end wall inside of a 1 meter long shock tube. The fuel is stoichmetric H2/O2 diluted with Ar at 70%.

101

Figure 6.9 show the time history of the maximum sum of mass fractions and the temperature at a distance of 2 mm from the end wall. The length of the shock tube is

1 meter long and the initial temperature was at 650 K. The pressure ratio across the diaphragm was 5. This figure shows that the sum of mass fractions reaches a maximum value of about 1.006 at the initiation of combustion but then goes back down to 1.0015 after the fuel has combusted.

During Step V the flow variables represented by U in Equation (4.10) are calculated using Equation (5.27). The spatial derivative, dq/dx, is calculated during step V; this is done by using Equations (5.12) through (5.15).

After step V the program needs to check if it necessary to implement boundary conditions, since the CESE method uses a staggered mesh the boundary conditions are only applied on the even time iterations. If boundary conditions are needed then step VII is ran and the boundary conditions are applied using the equations outlined in Section 5.4.

In step VII the current working array is placed back into the main working array.

With the completion of this step the program has to check if it is in the last cell and needs to increase the time count or to continue on with the next grid point in the current time step. Before going onto the next time step the program checks to see if enough time has elapsed and it is time to write a data file which contains information such as the temperature, mole fractions, pressure and other useful data. During every data writing session information is saved to the files necessary to create the contour

102 and temperature/pressure plots. In an effort to decrease the size of the output files and the time necessary to complete the post processing some spatial points and time steps are skipped when creating the data files needed for the animated plots. These decisions are made by the user in the input file.

Step VIII is the last step to be completed and its job it to change the physical time step, dt, in order to reach the desired CFL number. Since the CESE method is an explicit scheme the CFL number needs to stay below 1 but due the rapid increase in temperature after the reflected shock and after the start of combustion it is necessary to optimize the CFL number to a value lower than 1. For most of the runs made the optimum CFL number was around 0.6. At this value there is a large enough buffer that the program will not go unstable when the temperature and or speed increases rapidly. If chemistry is turned off completely than the value can be increased to about 0.8. The CESE scheme that is currently used is a CFL sensitive scheme which means that if the CFL number is lower than 1 the results becomes smeared.

6.5. Validation

In order to validate the shock-tube part of the Gaskin experimental data will be used as the main source of validation. This is done because the model that

CHEMKINTM uses to simulate a shock-tube experiment is different from the way it is done in Gaskin. According to (R. J. Kee, et al. 2006) the conditions behind a shock tube are determined through a modified version provided earlier in this chapter. The modification that CHEMKINTM makes is that does not assume constant

103 thermodynamic properties, i.e. cp, cv, γ, across a shock wave the simulation can also take into account the effects caused by the boundary layer. The boundary layer effect is taken into account empirically because the model used is one dimensional.

With the post shock conditions calculated CHEMKINTM calculates the properties behind the shock wave using the steady state conservation equations. This changes the problem for a PDE to an ODE which CHEMKINTM integrates numerically.

Another problem with using CHEMKINTM to validate Gaskin is that is uses constant pressure combustion to calculate the end properties but Gaskin uses a constant volume assumption.

Before multiple Gaskin simulations are performed values for the maximum spatial, dx, and chemistry time steps, dtc, must be determined. The optimum chemical time step can be estimated from the zero dimensional simulations. By looking at Figure 3.2 it can be seen that the minimum chemical time step is about

1.x10-10. At this value the program would require a long time to finish. The optimum dx is found by running the same shock-tube simulation at various dx and then locating the point at which the critical values start to deviate. A summary of the different set ups are listed below.

104

Test 1: Li H /O Chemical Mechanism 2 2 Test 2: Li H /O Test 3: GRI No combustion 2 2 Po (atm) 1.0 1.0 43.91

To (K) 650.0 650.0 300.0

Driver Length (meters) 0.5 0.5 5.26 Ar Ar Ar Species 1.0 1.0 1.0 Po (atm) 0.1 0.1 0.27

To (K) 650.0 650.0 427.6

Driven Length (meters) 0.5 0.5 10.52 H /O /Ar CH /O /Ar Species 2 2 H /O /Ar 0.2/0.1/0.7 4 2 0.2/0.1/0.7 2 2 0.035/0.070/0.895

Table 6.4: Different shock tube setups to find an optimum dx.

It can be seen that the CPU time required to finish the simulation decreases rapidly as the spatial increment is increased. From Figure 6.10 it can be seen that the maximum reported temperature stays constant until a dx of 0.01 meters at which the temperature starts to fluctuate before decreasing rapidly. In addition it can be seen that when dx increases by a factor of ten the CPU time decrease by about a factor of one hundred.

105

Figure 6.10: Plot of temperature (semi-log) and CPU time (log-log) vs. dx with chemistry turned off. The initial conditions are listed in Test 1 in Table 6.4.

For test two and three the induction time is used as an indicator as to find when dx becomes too large and no longer produces accurate results. The induction time starts when the shock reflects off of the end wall and ends when there is a spike in the pressure at a distance of 4 cm from the end wall for the Li H2/O2 mechanism and

2 mm for the GRI mechanism. If the value for dx was larger than the distance from the end wall then a value of 1.5 times the value of dx was selected. The results are shown in Figure 6.11 and Figure 6.12. The results are not easily seen in Figure 6.11 since all of the induction times are within ±1.0x10-5 s of the average value but the

106

-3 maximum dx for the Li H2/O2 mechanism is about 4.0x10 . The reason for this is that this resolution is not fine enough to capture the spike in pressure that has been used for all dx smaller than 4.0x10-3. When the dx became larger than 4.0x10-3 an inflection point, it the pressure vs. time plot, was chosen instead.

Figure 6.11: Plot of induction time (semi-log) and CPU time (log-log) vs. dx for the conditions listed in Test 2 in Table 6.4.

107

Figure 6.12: Plot of the calculated induction time (semi-log) and CPU time (log-log) vs. dx for the conditions listed in Test 3 in Table 6.4.

The maximum dx for the GRI mechanism was found to be 0.01 meters. The induction when the dx was in between 0.001 and 0.01 where nearly constant so no simulations where run with dx less than 0.001 meters. The induction estimated at the post reflected shock properties was 5.67x10-4 s.

In order to validate the shock tube model the induction time was compared to an experimental best fit line from (Spadaccini and Colket III 1994)

14 22659 1.05 0.33 tinduction  2.21 10 exp O24  CH  (6.25) T 108

The estimation for induction time was determined by collecting data from over 500 different experiments for CH4 O2 reactions.

Figure 6.13: Shock tube study for constant-volume CH4 /O2 reactions diluted with Ar at various initial pressures and temperatures and the equivalence ratios.

The aggrement between the experimental and computational results are reasonable as seen in Figure 6.13. The numerical constantly predicted a longer induction time than the experimental results but this is to be expected since

Spadaccini et.al states that when the temperature is less than 1800 K the induction time is under predicted. The definition for the induction time is the same one used to find the optimum dx. Over all the average percentage difference between the

109 experimental and computational results where about 17%, 59%, and 46% for an equivalence ratio of 0.45, 1.0 and 1.25 respectively.

110

CHAPTER 7

CONCLUSION

The present thesis reports the development of a high-fidelity numerical tool to model shock tube experiments. The overall goal is to aid in the shock-tube experiments for studying chemical reactions in the combustor of scramjet engines.

The space-time CESE method in conjunction with ODE solvers are employed to solve the Euler equations for chemically reacting flows with detailed finite-rate chemistry. Extensive input/output mechanism has been developed to retrieve existing chemistry data in CHEMKIN format and Cantera format. The simulated ignition delays of methane/air mixtures have been reported. Multiple species with complex reaction steps have been directly incorporated into the calculations. Systematic use of the present shock tube tool will establish a data base for the flammability of fuel/air mixtures for a wide range of stochiometric ratios and flow conditions, leading to identifying a window of operation for a dual-mode scramjet engine.

7.1. Future Improvements

The above results showed that the present shock-tube simulation tool is capable of providing relatively accurate results for the ignition delays for complex

111 hydrocarbon reactions in shock tube experiments. Favorable comparison was found between the calculated results and the measured data.

Therefore, the main focus for the future work will be improvement of the efficiency by decreasing the CPU time. There are several different ways to accomplish this goal, including (i) implementation of non-uniform mesh for flow solver, (ii) more efficient ode integrator for integrating the chemistry models, and

(iii) parallelization in computation based on domain decomposition.

A non-uniform mesh would increase the space in between points where higher resolution is not needed, e.g., the driver section, and increase the number of mesh points where high resolution is paramount, e.g., the combustion zone and the area around the shock wave and the contact discontinuity. Switching to a non-uniform mesh will also increase the variation of the CFL numbers in the flow field. The chosen time step is limited by the region with the smallest dx. In areas where dx is large, the CFL will be small leading to more smeared solution due to too much artificial dissipation. One immediate improvement of the present shock-tube code is to implement the CFL-insensitive scheme so that the accuracy of the numerical solution will not be affected by the local CFL number.

The accuracy of the version of the CESE scheme employed in the present work is influenced by the CFL number. The re-weighting method, Equation (5.15), needs to be modified so that the CESE method will become CFL insensitive. The new re-

112 weighting scheme has already been designed, (Chang and Wang 2003) and it will be incorporated into the present tool in the near future.

Along with the non-uniform mesh, we also plan to implement a non-uniform time step algorithm into the new shock tube tool. Essentially, the computational domain could be divided into many zones with uniform mesh and time step in each zone. The integration of the model equations at the interface between neighboring zones will be based on the flux conservation.

In Chapter 3 Section 5, discussions were provided about increasing the accuracy and efficiency of the ODE integrator. One possibility is to increase the efficiency of the chemical subroutine without changing the ODE integrator is to design better logic to determine when the chemical subroutines should and should not be called.

For example, if the combustible gases have already been depleted and the products have been formed, the species concentration could be considered frozen and the chemistry subroutine could be skipped.

The last approach that could be used to increase the computational speed of the new computer program is to parallelize the program through domain decomposition.

113

BIBLIOGRAPHY

Anderson, John D. Modern . Third. New York: McGraw-Hill, 2003.

Cai, Minghao, S.-T. John Yu, and Moujin Zhang. "Theoretical and Numerical Solutions of LInear and Nonlinear Elastic Waves in a Thin Rod." 42nd AIAA/ASME/SAE/ASEE Join Propulsion Conference and Exhibit. Scramento: AIAA, 2006.

Chang, S.C., and X.Y. Wang. "Multi-Dimensional Courant Number Insensitice CE/SE Euler Solvers for Applicatoins Involving Highly Nonuniform Meshes." 39th AIAA/ASME/SAE/ASEE Joint Propulsion Conference & Exhibit . Huntsville: AIAA, 2003.

Chang, Sin-Chung. On Space-Time Inversion Invariance and its Relation to Non- Dissipatedness of a CESE Core Scheme. NASA/TM, Glenn Research Center, Cleveland, OH: NASA, 2006.

Chang, Sin-Chung. "The Method of Space-Time Conservtion Element and Solution Elemet-A New Approach for Solving the Navier-Stokes and Euler Equatoins." (Computational Physics) 119 (1995): 296-324.

Curran, E. T., W. H. Heiser, and D. T. Pratt. "Fluid Phenomena in Scramjet Combustion Systems." Annual Review Fluid Mechanics 28 (1996): 323-60.

Glassman, Irving. Combustion. Third. San Diego: Academic Press, Inc., 1996.

Goodwin, D. "Cantera Documentaion." SourceForge.net:Files. July 25, 2004. http://sourceforge.net/project/showfiles.php?group_id=78833&package_id=80581 (accessed June 12, 2008). 114

Goodwin, David G. Cantera. 2008. http://www.cantera.org/ (accessed may 22, 2008).

—. "Defining Phases and Interfaces Cantera 1.5." Pasadena, CA, August 14, 2003.

He, Hao, S.-T. John Yu, and Zen-Chan Zhang. "Direct Calculations of One-, Two-, and Three-Dimensional Detonations by the CESE Method." Reno: AIAA, 2005.

Im, Kyoung-Su, and S.-T. John Yu Yu. "Analyses of Direct Detonation Initiation with Realistics Finite-Rate Chemistry." 41th Aerospace Science Meeting & Exhibit. Reno: AIAA, 2003.

Kahadawala, Moshan S.P., Shehan A. P. Corera, Skip Williams, Campbell D. Carter, and Sukh S. Sidhu. "Investigation of Kinetics of Iso-Octane Ignition under Scramjet Conditions." International Journal of Chemical Kinetics 38, no. 3 (2006): 194-201.

Kee, R. J., et al. "CHEMKIN Release 4.1 ." San Diego, CA: Reaction Design, 2006.

Kee, Robert J., and Fran M. Rupley. CHEMKIN-II: A FORTRAN CHEMICAL KINETICS PACKAGE FOR THE ANALYSIS OF GAS-PHASE CHEMICAL KINETICS. SAND89-8009, Livermore, CA: Sandia National Laboratories, 1989.

Kreyszig, Erwin. Advance Engineering Mathematics. 8th. New York: John Wiley & Sons, Inc., 1999.

L.L.N.L. SUNDIALS. June 03, 2008. https://computation.llnl.gov/casc/sundials/main/html (accessed June 03, 2008).

[email protected]. LAPACK -- Linear Algebra PACkage. May 22, 2008. http://www.netlib.org/lapack/ (accessed May 22, 2008).

Li, J., Z. Zhao, A. Kazakov, and F. L. Dryer. "An Updated Comprehensive Kinetic Model for H2 Combustion." Fall Technical Meeting of the Eastern States 115

Section of the Combustion Institute. Penn State University, University Park, PA, 2004.

Marinov, N. M., W. J. Pitz, C. K. Westbrook, and N. Matsunaga. "An Experimental and Kinetic Calculation of the Promotion Effect of Hydrocarbons on the NO-NO2 conversion in a FLow Reactor." Proceedings of the Combustion Insititute 27 (1998): 389-396.

NASA. "NASA Hyper-X Program Demonstrates Scramjet Technologies." NASAFacts, October 20, 2004.

Petersen, Eric L., Danielle M. Kalitan, Stefanie Simmons, Gilles Bourque, Henry J. Curran, and John M. Simmie. "Methane/Propane Oxidation at High Pressures: Experimentla and Detailed Chemical Kinetics Modeling." Proceddings of the Combustion Institute, 2007: 447-454.

Petersen, Eric L., Michael Rohrig, David F. Davidson, Ronald K. Hanson, and Craig T. Bowman. "High-Pressure Methane Oxidation Behind Reflected Shock Waves." The Combustion Institute, 1996.

Radhakrishnan, Krishnan, and Alan C. Hindmarsh. "Description and Use of LSODE, the Livermore Solver for Ordinary Differential Equations." NASA Reference Publication, Lawrence Livermore National Laboratory, 1993.

Sears, and Salinger. Thermodynamics, Kinetics Theory, and Statistical Thermodynamics. 3rd. Reading: Addison-Wesley Publishing Company, 1975.

Smith, Gregory P., et al. GRI-MECH 3.0. UC Berkely. http://www.me.berkeley.edu/gri-mech/version30/text30.html (accessed May 09, 2008).

Spadaccini, L. J., and M. B. Colket III. "Ignition Delay Characteristics of Methane Fuels." Progress in Energy Combustion Science 20 (1994): 431-460.

Sutton, Georege P., and Oscar Biblarz. Rocket Propulsion Elements. John Wiley& Sons, INC., 2001.

116

Toro, E. F. "Riemann Solvers and Numerical Methods for A Practical Introdcution." In Riemann Solvers and Numerical Methods for Fluid Dynamics A Practical Introdcution, by E. F. Toro, 533-544. Berlin: Springer-Verlag , 1999.

Williams, F. A. San Diego Mechanism. UCSD. http://maeweb.ucsd.edu/~combustion/cermech/ (accessed May 09, 2008).

Zhang, Moujin, S.-T. John Yu, Sin-Chung Chang, and Isaiah Blankson. "Solving the MHD Equation by the Space-Time CESE Method ." AIAA Science Meeting. Reno: AIAA, 2006.

117