1 in - physbamphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w,...

39

Upload: others

Post on 23-Sep-2020

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

Simpli�ed Discretization of Systems of HyperbolicConservation Laws Containing Advection EquationsRonald P. FedkiwBarry MerrimanStanley Osher �August 24, 1999AbstractThe high speed ow of complex materials can often be modeled by thecompressible Euler Equations coupled to (possibly many) additionaladvection equations. Traditionally, good computational results havebeen obtained by writing these systems in fully conservative form andapplying the general methodology of shock-capturing schemes for sys-tems of hyperbolic conservation laws. In this paper, we show how toobtain the bene�ts of these schemes without the usual complexity offull characteristic decomposition or the restrictions imposed by fullyconservative di�erencing. Instead, under certain conditions de�ned insection 2, the additional advection equations can be discretized indi-vidually with a nonconservative scheme while the remaining systemis discretized using a fully conservative approach, perhaps based ona characteristic �eld decomposition. A simple extension of the Lax-Wendro� Theorem is presented to show that under certain veri�ablehypothesis, our nonconservative schemes converge to weak solutions ofthe fully conservative system. Then this new technique is applied tosystems of equations from compressible multiphase ow, chemically re-acting ow, and explosive materials modeling. In the last instance, the exibility introduced by this approach is exploited to change a weaklyhyperbolic system into an equivalent strictly hyperbolic system, andto remove certain nonphysical modeling assumptions.�Research supported in part by ONR N00014-97-1-0027, ONR N00014-97-1-09681

Page 2: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

1 IntroductionIt is widely believed that numerical methods for discretizing the Euler equa-tions should have discrete conservation of mass, momentum, and energyas well as an entropy �x for low viscosity schemes. Conservative schemeshave limit solutions which are weak solutions of the Euler equations yieldingaccurate representation of the shock speeds and jumps. In contrast, noncon-servative schemes generally give limit solutions which have incorrect shockspeeds and/or jumps, e.g. see [15]. Note that the work in [13] derived andused special viscosity terms that mimic the Navier-Stokes viscosity in orderto reduce these types of nonconservative errors.As models become richer in physics and mathematics, more and moreequations are added. Some common examples are the addition of mass frac-tion equations for chemically reacting ow [7] and the addition of the level setequation for compressible gas ow [18]. Another example is the Baer Nun-ziato (BN) two phase model for solid explosives and propellants [1], wherea second set of Euler equations is added for the solid phase, and a volumefraction equation is added to close the system. In addition, the chemicalsource terms of the BN model require the addition of many more equations,not all of which are known or agreed upon by the community [10, 2]. Asnew conservation laws are added to the Euler equations, the Jacobian matrixrequired for upwind schemes grows accordingly, usually becoming large andunwieldy.For a given system one can often identify a minimal conservative systemthat contains the truly nonlinear �elds. In the chemically reacting owmodel and the level set model the Euler equations are the minimal systemcontaining the sound waves. It will be shown that both the mass fractionequations and the level set equation can be written in advection form andupwinded separately according to the particle velocity without degradingthe quality of the numerical solution. In fact, the resulting solution is asgood, if not better than the fully conservative method. In the BN model, theminimal conservative system consists of the two sets of Euler equations whichcontain the truly nonlinear �elds for both the gas sound waves and the solidsound waves. The volume fraction equation and the extra equations addedfor chemical source terms will be put into advection form and upwindedseparately according to the appropriate particle velocity (gas or solid). Note2

Page 3: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

that the BN system di�ers from the �rst two examples, where the minimalsystem was only the Euler equations and all added equations were put intoadvection form. The reason for this di�erence is that the second set of Eulerequations, added to model the solid, contains quantities which have jumpsthat are not advected along streamlines, e.g. shock waves in the solid.One often adds new advection equations of the formZt + uZx = 0 (1)to the minimal system. The continuity equation is�t + (�u)x = 0 (2)where � is the density and u is the velocity. Multiplying equation 1 by � andadding it to Z times equation 2 results in(�Z)t + (�Zu)x = 0 (3)as a new equation in conservation form. If the correct Rankine-Hugoniotjump conditions of the full system are such that discontinuities in Z areadvected along streamlines then the technique introduced in this paper ap-plies. This is the case for the mass fraction equations, the level set equation,and the volume fraction equation of the BN model, but not the case for thesecond set of Euler equations in the BN model which must be added to theminimal system. As a further illustration, considerSt + uSx = 0 (4)where S is the entropy per unit mass. While this equation is valid away fromshocks, discontinuities in S are not necessarily advected along streamlinesand the technique introduced in this paper does not apply. The advection ofdiscontinuities in Z along streamlines can be made more precise by consider-ing a discontinuity moving with speed D. The well known jump conditionsfor equations 2 and 3 are�left(uleft �D) = �right(uright �D) (5)and �leftZleft(uleft �D) = �rightZright(uright �D) (6)which can be combined to obtain�right(Zleft � Zright)(uright �D) = 0 (7)3

Page 4: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

illustrating that Z must be continuous, unless uright = D = uleft. That is,discontinuities of Z move with the particle velocity. MoreoverZ is continuousacross shocks. Note that these statements are generally not true for theentropy.There are two distinct kinds of advection equations which may be addedto a minimal system. The �rst kind advects quantities that the minimal sys-tem depends on, examples include dependence of the pressure on the massfractions, the level set function, or the volume fraction. The left and righteigenvectors of the Jacobian matrix are needed in order to use an upwindscheme. These types of advection equations dictate an increase in the size ofthe left eigenvector, since information is needed from these variables to ac-curately project into the characteristic �elds. However, the right eigenvectorremains the length of the minimal system, since only the minimal systemis updated using the characteristic �elds, while the advection equations areupdated individually. The second kind of advection equation advects thosequantities that the minimal system does not depend on, even though thenew equations may be dependent on the minimal system for their charac-teristic velocity. These types of equations occur in newer models such asthe BN equations where the advected quantities have been added in orderto model the chemical source terms. These advection equations have no ef-fect on the hyperbolic part of the minimal system and do not change theeigensystem at all, i.e. neither the right nor left eigenvector of the associ-ated Jacobian matrix of the minimal system changes. Here the savings insimplicity of scheme design and programming e�ort are enormous using ourtechnique rather than standard conservation form discretizations, becauseone only needs to discretize simple additional advection equations. Thereare also signi�cant gains in execution time.In section 5, a conservative equation that introduces a weak hyperbolic-ity in the BN model (which implies that the problem is mildly ill-posed) isdiscussed. In this instance, the identi�cation of a quantity with discontinu-ities that advect along streamlines is extremely useful since the conservativeequation is equivalent to advecting a quantity which blows up analyticallyas the reaction proceeds to completion. This problem is easily �xed by ad-vecting an equivalent quantity which goes to zero as the reaction proceedsto completion. Furthermore, putting this well behaved advection equationinto conservative form and solving in the usual way removes the weak hy-perbolicity for the full conservation form as well.Once the advection equations are isolated from the minimal conservativesystem, greater exibility in scheme design can be exploited. If the advected4

Page 5: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

quantity is continuous, e.g. the level set function, then one can use highorder essentially nonoscillatory (ENO) Hamilton-Jacobi methods which gainan order of accuracy at extrema over the conservative ENO ux method andare also somewhat easier to implement [21, 11]. If the advected quantity isdiscontinuous, our theoretical and numerical results indicate that nonconser-vative ux form is preferable. That is, we recommend that the spatial termof Zt + uZx = 0 (8)be approximated as uZx � ui�Zi+ 12 � Zi�12 �4x (9)where Zi+ 12 can be viewed as a numerical ux function consistent with Z. Fordiscontinuous advected quantities, the contact discontinuities can be sharp-ened with arti�cial compression methods [22]. In fact, isolating the advectionequations in a ux form that allows nonconservative ux di�erencing opensup new research avenues such as the pursuit of a fully multidimensional ar-ti�cial compression method, which could not be carried out as easily withconservative numerical methods.5

Page 6: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

2 Theoretical Justi�cationThe general theorem concerns the following system of equations in R3 �R+qt +r � ~f (q; Z) = 0 (10)Zt + ~u � rZ = 0 (11)where ~f = (f; g; h) and ~u = (u; v; w). Note that q, f , g, and h are all ` vectorswhile Z is an m vector. In regions of smoothness, we assume that equations10 and 11 are equivalent to a conservative system having ` +m dependentvariables and that the jump conditions for the conservative system are[~f � ~N ] = D[q] (12)[Z] �~u � ~N �D� = 0 (13)where ~N is the unit normal to the surface of discontinuity, and D is the localdiscontinuity speed in the normal direction. For simplicity of exposition onlywe consider R2 �R+ in the following.We approximate the system using conservation form for the \q" variablesand nonconservative ux based form for the \Z" variables. Thus we haveqn+1i;j = qni;j � �t�x h�Fni+ 12 ;j � Fni� 12 ;j�+ �Gni;j+12 �Gni;j�12�i (14)where Fni� 12 ;j and Gni;j�12 are Lipschitz continuous numerical ux functionsconsistent with f(q; Z) and g(q; Z) respectively. We also haveZn+1i;j = Zni;j � �t�x huni;j �Zni+ 12 ;j � Zni� 12 ;j�+ vni;j �Zi;j+ 12 � Zi;j�12�i (15)where Zni� 12 ;j and Zni;j�12 are Lipschitz continuous ux functions consistentwith Z.We make the following assumptions: Suppose, as �t;�x;�y ! 0, asubsequence of the approximate solutions generated by equations 14 and15 is bounded a.e. convergent to a piecewise di�erentiable limit, (q; Z), forwhich Z has jumps only where ~u is di�erentiable. In addition we assume that6

Page 7: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

the �rst divided di�erences in x and y of these approximations uni;j and vni;jare uniformly bounded by an integrable function in any compact set � R2for which the limit solution (u; v) is di�erentiable, i.e. uni;j and vni;j are eachuniformly bounded in W 1;1(), and that similar statements are true for Zni;jin any compact set 0 � R2 for which the limit solution Z is di�erentiable.Then we have the following result:Theorem 1. The piecewise di�erentiable limit (q; Z) is a weak solutionof equations 10 and 11, i.e. it is a classical solution when it is di�erentiableand it satis�es equations 12 and 13 at jumps.Remark 1. Our assumptions are considerably stronger than those ofthe classical Lax-Wendro� theorem [14] which requires only bounded a.e.convergence. Nevertheless, in our calculations in this paper (and elsewhere)using this method, we have observed that our assumptions were valid. Infact the divided di�erences of the approximations to ~u were always uniformlybounded away from the discontinuities of the limiting ~u in our calculations,and similarly for Z.Remark 2. The content of our Theorem is along the lines: convergenceplus consistency implies the limit solution satis�es the original di�erentialequation. Here, this amounts to showing that the jump conditions in equa-tions 12 and 13 are satis�ed and that equations 10 and 11 are true in regionsof smoothness.Remark 3. The Lax-Wendro� Theorem states that a converged solutionis a weak solution. Thus one has to believe their results have or will con-verge with further grid re�nement. Our Theorem requires this as well asthe requirement that Z has jumps only where ~u is di�erentiable and thatthe approximations to ~u are uniformly bounded in W 1;1 wherever ~u is di�er-entiable, with similar requirements on Z and its approximations. One hasto believe that no singularities will appear and violate these hypothesis asthe grid is re�ned. This is in the spirit of the Lax-Wendro� Theorem, i.e.if it has not happened on the �nest computational grid (lack of apparentconvergence, or in our case, singularities in the wrong places), then one canquote the appropriate theorem to justify convergence.Remark 4. For an arbitrary system of conservation laws to have thedecomposition in equations 10 to 13, it is necessary that one of the eigenval-ues of the Jacobian matrix in each dimension be (u; v; w) respectively, eachrepeated at least m times. This is, of course, only a necessary condition.Remark 5. Our main theorem may appear to contradict some prevailingwisdom. For example in [16] the authors state that the advection equation11 \does not hold �a priori across a shock". This is, of course, generally true,7

Page 8: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

but we have proven that it does hold in our sense if Z remains continuousthere.Proof. Let '(x; y; t) be a C10 (R2 �R+) function. We multiply equations14 and 15 by '(xi; yj; tn) and use the summation-by-parts idea in the proofof the LW theorem, arriving atXi;j;n�t�x�yhqni;j '(xi; yj; tn)� '(xi; yj; tn�1)�t !+Fni+ 12 ;j �'(xi+1; yj; tn)� '(xi; yj; tn)�x �+Gni;j+ 12 �'(xi; yj+1; tn)� '(xi; yj; tn)�y �i = 0 (16)and Xi;j;n�t�x�yhZni;j '(xi; yj; tn)� '(xi; yj; tn�1)�t !+Zni+ 12 ;j �uni+1;j'(xi+1; yj; tn)� uni;j'(xi; yj; tn)�x �+Zni;j+12 �vni;j+1'(xi; yj+1; tn)� vni;j'(xi; yj; tn)�y �i = 0 (17)We let �t;�x;�y ! 0 for the converging subsequence. From equation16, exactly as in the proof of the Lax-Wendro� theorem (which uses theLebesgue dominated convergence theorem, the Lipschitz continuity of the ux functions, consistency, and the fact thatlimh!0 �(x+ h) = �(x) (18)a.e. for bounded measurable functions �), we haveZR2�R+ q't + f'x + g'y = 0 (19)8

Page 9: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

for any such test function '. This, of course, implies that q is a classicalsolution of equation 10 wherever q and Z are smooth and that q and Z satisfyequation 12 at jumps.Next we use the identityuni+1;j'(xi+1; yj; tn)� uni;j'(xi; yj; tn)�x =uni+1;j �'(xi+1; yj; tn)� '(xi; yj; tn)�x �+ �uni+1;j � uni;j�x �'(xi; yj; tn) (20)and the analogous identity involving \y" divided di�erences. Choose ' tohave support in a region in which ~u is di�erentiable. We let �x;�y;�t!0 along the converging subsequence. Using equations 17 and 20, the Lebesguedominated convergence theorem and the usual Lax-Wendro� argument wearrive at ZR2�R+ Z't + Z (~u � r') + Z (r � ~u)' = 0 (21)If Z is di�erentiable in , a simple integration by parts gives us:Z' (Zt + ~u � rZ) = 0 (22)for any such ', hence Z is a classical solution of 11 in . If Z has a jump wetake to be a sphere centered at a point of discontinuity. We then let theradius of the sphere go to zero in equation 21 and obtain the jump conditionsin equation 13 in a standard fashion.We may prove Z is a classical solution when u jumps with the help of thedominated convergence theorem arriving at equation 22 in a straightforwardfashion.9

Page 10: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

3 Level Set Equation for Compressible FlowConsider the one dimensional Euler equations with the level set equation inconservation form 0BBB@ ��uE�� 1CCCAt + 0BBB@ �u�u2 + p(E + p)u�u� 1CCCAx = 0 (23)where � is the density, u is the velocity, E is the total energy per unitvolume, p is the pressure, and � is the level set function. Another alternative,as suggested in [18], is to replace the conservative level set equation (4thequation) with the level set equation in quasilinear or advection form�t + u�x = 0 (24)noting that � is valid in advection form since the values of � are meant toadvect with the particle velocity u, i.e. along streamlines.3.1 Projection into Characteristic FieldsModern shock capturing schemes are often based on projection into char-acteristic �elds. Usually the value of the left eigenvector of the Jacobianmatrix is frozen and used to locally decompose the system. Consider theEuler equations with the level set equation in advection form. Projection bya left eigenvector, L = (l1; l2; l3; l4), leads to26664(l1; l2; l3; l4)0BBB@ ��uE� 1CCCA37775t + 264(l1; l2; l3)0B@ �u�u2 + p(E + p)u 1CA375x + l4u�x = 0 (25)where it is obvious that the spatial part of this equation cannot be writtenin conservation form. In order to obtain conservation form for the projectedequation one needs to use the conservative version of the level set equation10

Page 11: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

so that projection by a left eigenvector leads to26664(l1; l2; l3; l4)0BBB@ ��uE�� 1CCCA37775t + 26664(l1; l2; l3; l4)0BBB@ �u�u2 + p(E + p)u�u� 1CCCA37775x = 0 (26)in conservation form. For this reason, the level set equation is written inconservation form when formulating the Jacobian matrix and the associatedeigensystem.3.2 Conservative EigensystemThe total energy is the sum of the internal energy and the kinetic energy,E = �e + �u22 (27)where e is the internal energy per unit mass. The pressure can be writtenas p = p(�; e; �) with partial derivatives p�, pe, and p�. Alternatively, con-sidering the pressure as p = p(�; �u; E; ��) allows one to write the partialderivatives of the pressure with respect to the conserved variables as@p@� = H � �p�� ; H = c2 � �(H � u2) (28)@p@(�u) = ��u; @p@E = � (29)@p@(��) = p�� (30)where the Gruneisen coe�cient, the sound speed, and the total mixtureenthalpy are de�ned by � = pe� ; c = sp� + �p� (31)H = E + p� (32)11

Page 12: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

The partial derivatives of the pressure are used to obtain the Jacobianmatrix 0BBB@ 0 1 0 0�u2 + H � �p�� 2u� �u � p���uH + uH � u�p�� H � �u2 u+ �u up���u� � 0 u 1CCCA (33)and the associated eigensystem~R1 = 0BBB@ 1u� cH � uc� 1CCCA ; ~R2 = 0BBB@ 1uH � 1b1� 1CCCA (34)~R3 = 0BBB@ 1u+ cH + uc� 1CCCA ; ~R4 = 0BBB@ 00� p���1 1CCCA (35)~L1 = �b22 + u2c � �p�2�c2 ; �b1u2 � 12c ; b12 ; p�2�c2� (36)~L2 = �1� b2 + �p��c2 ; b1u;�b1;� p��c2� (37)~L3 = �b22 � u2c � �p�2�c2 ; �b1u2 + 12c ; b12 ; p�2�c2� (38)~L4 = (��; 0; 0; 1) (39)where b1 = pe�c2 ; b2 = 1+ b1u2 � b1H: (40)12

Page 13: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

3.3 Numerical MethodWhen discretizing along the lines of [22], the left eigenvectors are used toproject into the characteristic �elds, the scalar ux in each characteristic�eld is discretized based on the associated eigenvalue in that �eld, and theright eigenvectors are used to project out of the characteristic �elds. Thenthe contributions from each characteristic �eld are added together to producethe total vector ux at a cell interface. These vector uxes are di�erencedin the usual manner resulting in a fully conservative numerical method.In order to correctly project into the characteristic �elds, the full lefteigenvector is always used. However, since conservation form is not requiredfor the last equation, i.e. the level set equation, only the �rst three compo-nents of the right eigenvectors are used to project out of the characteristic�elds. The level set equation is discretized independently in advection form,noting that its characteristic information is determined by u and that noth-ing about it need be conserved.Consider the Ghost Fluid Method, developed in [5], where p� is identi-cally zero. The minimal system no longer depends on the level set equa-tion and only the �rst three components of the �rst three left and righteigenvectors are needed to update the minimal system. That is, the onedimensional Euler equations can be discretized with a standard conservativescheme while the level set equation is independently discretized in advectionform. For both one and two dimensional computational results along withcomparisons to the exact solutions, see [5].13

Page 14: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

4 Chemically Reacting FlowConsider the two dimensional thermally perfect Euler Equations for multi-species ow with a total of N species,~Ut + [ ~F (~U)]x + [ ~G(~U)]y = 0; (41)~U = 0BBBBBBBBBB@ ��u�vE�Y1...�YN�1 1CCCCCCCCCCA ; ~F (~U) = 0BBBBBBBBBB@ �u�u2 + p�uv(E + p)u�uY1...�uYN�1 1CCCCCCCCCCA ; ~G(~U) = 0BBBBBBBBBB@ �v�uv�v2 + p(E + p)v�vY1...�vYN�1; 1CCCCCCCCCCA(42)E = �p+ �(u2 + v2)2 + � NXi=1 Yihi! ; hi(T ) = hfi + Z T0 cp;i(s)ds(43)where t is time, x and y are the spatial dimensions, � is the density, u andv are the velocities, E is the energy per unit volume, Yi is the mass fractionof species i, hi is the enthalpy per unit mass of species i, hfi is the heat offormation of species i (enthalpy at 0K), cp;i is the speci�c heat at constantpressure of species i, and p is the pressure [7]. Note that YN = 1�PN�1i=1 Yi.The pressure is a function of the density, internal energy per unit mass, andthe mass fractions, p = p(�; e; Y1; � � � ; YN�1), with partial derivatives p�; peand pYi where E = �e + �(u2+v2)2 de�nes the internal energy per unit mass.The eigenvalues and eigenvectors for the Jacobian matrix of ~F (~U) areobtained by setting A = 1 and B = 0 in the following formulas, while thosefor the Jacobian matrix of ~G(~U) are obtained by setting A = 0 and B = 1.The eigenvalues are �1 = u� c; �N+3 = u+ c (44)�2 = � � �= �N+2 = u: (45)14

Page 15: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

where u is repeated (N + 1) times.The standard construction of upwind di�erence schemes requires the fulleigensystem of the Jacobian matrix of ~F evaluated as some intermediatevalue of ~U . When this Jacobian matrix has a repeated eigenvalue, this in-volves �nding a basis for the associated eigenspace which can be complicatedfor systems with high multiplicity. The Complementary Projection Method(CPM) is an alternative approach where full upwinding is accomplished with-out the use of the eigenvectors in the repeated eigenvalue �eld. Suppose the�rst p eigenvalues are repeated, then the corresponding p dimensional char-acteristic subspace is the span of (~L1; : : : ; ~Lp). The remaining left and righteigenvectors can be used to de�nefK = ~LK � ~F (46)and write ~F = ~F + nXk=p+1 fK ~RK (47)where the vector ~F can be upwinded according to the sign of the repeatedeigenvalue �1 = �2 : : : = �p, and no basis need be chosen for ~F . For moredetails on the CPM, see [6].The CPM requires the �rst and (N +3)-rd left and right eigenvectors forthe chemically reacting ow example considered here. In addition, since theminimal conservative system is the two dimensional Euler equations, onlythe �rst four entries of the right eigenvectors are needed. The necessary leftand right eigenvectors are~L1 = �b22 + u2c + b32 ;�b1u2 � A2c ;�b1v2 � B2c ; b12 ; �b1z12 ; � � � ; �b1zN�12 � (48)~LN+3 = �b22 � u2c + b32 ;�b1u2 + A2c ;�b1v2 + B2c ; b12 ; �b1z12 ; � � � ; �b1zN�12 �(49)~R1 = 0BBB@ 1u�Acv �BcH � uc 1CCCA ; ~RN+3 = 0BBB@ 1u+Acv + BcH + uc 1CCCA (50)15

Page 16: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

where the unnecessary terms in the right eigenvectors have been omitted forbrevity and q2 = u2 + v2; u = Au+Bv (51)c = rp� + ppe�2 ; H = E + p� ; (52)b1 = pe�c2 ; b2 = 1+ b1q2 � b1H; (53)b3 = b1 N�1Xi=1 Yizi; zi = �pYipe : (54)4.1 Numerical MethodThe two left eigenvectors are used to project into the two nonlinear �elds,while only the �rst four entries of the right eigenvectors are used to projectout of these �elds. The CPM is used to construct the complementary sub-space ~F = 0BBB@ �u�u2 + p�uv(E + p)u 1CCCA� ~L1 ~F (~U)~R1 � ~LN+3 ~F (~U)~RN+3 (55)where ~F has length four and each of its component can be upwind di�erencedin the upwind direction determined by u. The resulting ux is combinedwith the ux contributions from the two nonlinear �elds to yield the netnumerical ux for the �rst four entries of ~F (~U). These uxes are di�erencedin the usual manner to get the proper upwind conservative discretization forthe �rst four equations, i.e. for the minimal system. For a dimension bydimension discretization, the same procedure is applied to the ux in theother spatial dimension, and then the total spatial contribution can be usedwith a TVD Runge Kutta method to update the �rst four equations of the16

Page 17: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

system, i.e. to update the minimal system. The advection equations for themass fractions0B@ Y1...YN�1 1CAt + u0B@ Y1...YN�1 1CAx + v0B@ Y1...YN�1; 1CAy = 0 (56)are discretized independently in an equation by equation fashion noting thatthe characteristic information for the x and y derivatives is determined by uand v respectively and that nothing need be conserved.4.2 ExamplesSeveral of the examples from [4] and [7] were recomputed using the noncon-servative ux based method outlined in this paper. Overall, the calculationsusing the new technique agreed well with the old calculations. One particu-larly di�cult example from [7] is repeated here.Consider a :12m domain with a shock wave located a x = :06m travelingfrom right to left in a 2=1=7 molar ratio of H2=O2=Ar where all gases areassumed to be thermally perfect and a full chemical reaction mechanism isemployed as discussed in [7]. The initial data for the shock wave consistsof � = :072 kgm3 , u = 0ms and p = 7173Pa on the left with � = :18075 kgm3 ,u = �487:34ms , and p = 35594Pa on the right. A solid wall boundarycondition is applied at x = 0m and the shock wave re ects o� this wallchanging its direction of travel. As this shock wave passes over the gas asecond time, the gas is heated enough to initiate chemical reactions. After asuitable induction time, a chemical combustion wave forms at the wall andtravels to the right eventually overtaking the shock wave resulting in theformation of three waves. From left to right, there is a rarefaction wave, acontact discontinuity, and a detonation wave.Figure 1 shows the solution at 230�s with 400 uniform grid cells and 2300equal time steps using the fully conservative ENO-RF method outlined in[7]. Figure 2 shows the same calculation using the nonconservative ux basedENO method (outlined in the appendix) for the mass fraction equations. TheCPM [6] was used in both calculations. In [7], this was shown to be a verysensitive problem, and the good agreement of the two methods is promising.The only major di�erence is in the height of the HO2 peak, although thisseems to have no e�ect on the rest of the solution.17

Page 18: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

A grid re�nement study was carried out with 100, 200, 400, 800, and1600 grid cells using 575, 1150, 2300, 4600, and 9200 time steps respectively.Figure 3 shows the results with the fully conservative scheme while �gure 4shows the results with the nonconservative ux based method for the massfraction equations. The position of the lead detonation wave converges with�rst order accuracy for both numerical algorithms. In addition, the peaks inthe HO2 mass fraction seem to converge more uniformly (i.e. monotonically)for the nonconservative ux based method. Figures 5, 6, and 7 compare thetwo methods with 100, 400, and 1600 grid points respectively. The fullyconservative method is plotted with x's while the nonconservative ux basedmethod is plotted with o's.

18

Page 19: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

0 0.05 0.1

0.2

0.3

0.4

0.5

0.6den

0 0.05 0.1−500

0

500

x−vel

0 0.05 0.1

1

2

3

x 105 press

0 0.05 0.1

1

2

3

4

5

x 105 energy

0 0.05 0.1

1000

1500

2000

2500

3000temp

0 0.05 0.11.3

1.4

1.5

1.6

gamma

0 0.05 0.10

0.5

1

1.5

2

x 10−3 H mf

0 0.05 0.10

0.005

0.01

O mf

0 0.05 0.10

0.005

0.01

H2 mf

0 0.05 0.10

0.05

0.1

O2 mf

0 0.05 0.10

0.005

0.01

0.015

OH mf

0 0.05 0.10

0.02

0.04

0.06

0.08

H2O mf

0 0.05 0.10

1

2

x 10−5 HO2 mf

0 0.05 0.10

0.5

1x 10

−5 H2O2 mf

0 0.05 0.10

0.2

0.4

0.6

0.8

Ar mfFigure 1: Fully conservative method19

Page 20: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

0 0.05 0.1

0.2

0.3

0.4

0.5

0.6den

0 0.05 0.1−500

0

500

x−vel

0 0.05 0.1

1

2

3

x 105 press

0 0.05 0.1

1

2

3

4

5

x 105 energy

0 0.05 0.1

1000

1500

2000

2500

3000temp

0 0.05 0.11.3

1.4

1.5

1.6

gamma

0 0.05 0.10

0.5

1

1.5

2

x 10−3 H mf

0 0.05 0.10

0.005

0.01

O mf

0 0.05 0.10

0.005

0.01

H2 mf

0 0.05 0.10

0.05

0.1

O2 mf

0 0.05 0.10

0.005

0.01

0.015

OH mf

0 0.05 0.10

0.02

0.04

0.06

0.08

H2O mf

0 0.05 0.10

1

2

3

x 10−5 HO2 mf

0 0.05 0.10

0.5

1x 10

−5 H2O2 mf

0 0.05 0.10

0.2

0.4

0.6

0.8

Ar mfFigure 2: Nonconservative ux based algorithm20

Page 21: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

0 0.02 0.04 0.06 0.08 0.1

0.2

0.25

0.3

0.35

0.4

0.45

0.5

0.55

0.6

0.65den

0 0.02 0.04 0.06 0.08 0.10

0.002

0.004

0.006

0.008

0.01

0.012

0.014

0.016OH mf

0 0.02 0.04 0.06 0.08 0.10

0.01

0.02

0.03

0.04

0.05

0.06

0.07

0.08

0.09H2O mf

0 0.02 0.04 0.06 0.08 0.10

1

2

3

4

5x 10

−5 HO2 mf

Figure 3: Fully conservative method21

Page 22: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

0 0.02 0.04 0.06 0.08 0.1

0.2

0.25

0.3

0.35

0.4

0.45

0.5

0.55

0.6

0.65den

0 0.02 0.04 0.06 0.08 0.10

0.002

0.004

0.006

0.008

0.01

0.012

0.014

0.016OH mf

0 0.02 0.04 0.06 0.08 0.10

0.01

0.02

0.03

0.04

0.05

0.06

0.07

0.08

0.09H2O mf

0 0.02 0.04 0.06 0.08 0.10

1

2

3

4

5x 10

−5 HO2 mf

Figure 4: Nonconservative ux based algorithm22

Page 23: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

0 0.02 0.04 0.06 0.08 0.1

0.2

0.25

0.3

0.35

0.4

0.45

0.5

0.55

0.6

0.65den

0 0.02 0.04 0.06 0.08 0.10

0.002

0.004

0.006

0.008

0.01

0.012

0.014

0.016OH mf

0 0.02 0.04 0.06 0.08 0.10

0.01

0.02

0.03

0.04

0.05

0.06

0.07

0.08

0.09H2O mf

0 0.02 0.04 0.06 0.08 0.10

1

2

3

4

5x 10

−5 HO2 mf

Figure 5: 100 grid cells, x-conservative, o-nonconservative23

Page 24: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

0 0.02 0.04 0.06 0.08 0.1

0.2

0.25

0.3

0.35

0.4

0.45

0.5

0.55

0.6

0.65den

0 0.02 0.04 0.06 0.08 0.10

0.002

0.004

0.006

0.008

0.01

0.012

0.014

0.016OH mf

0 0.02 0.04 0.06 0.08 0.10

0.01

0.02

0.03

0.04

0.05

0.06

0.07

0.08

0.09H2O mf

0 0.02 0.04 0.06 0.08 0.10

1

2

3

4

5x 10

−5 HO2 mf

Figure 6: 400 grid cells, x-conservative, o-nonconservative24

Page 25: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

0 0.02 0.04 0.06 0.08 0.1

0.2

0.25

0.3

0.35

0.4

0.45

0.5

0.55

0.6

0.65den

0 0.02 0.04 0.06 0.08 0.10

0.002

0.004

0.006

0.008

0.01

0.012

0.014

0.016OH mf

0 0.02 0.04 0.06 0.08 0.10

0.01

0.02

0.03

0.04

0.05

0.06

0.07

0.08

0.09H2O mf

0 0.02 0.04 0.06 0.08 0.10

1

2

3

4

5x 10

−5 HO2 mf

Figure 7: 1600 grid cells, x-conservative, o-nonconservative25

Page 26: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

5 BN Two Phase Explosives ModelConsider a simpli�ed version of the one-dimensional Baer-Nunziato (BN) twophase explosives model [1, 3, 10, 2] that ignores nozzling and source terms0BBBBBBBBBB@ �g�g�gug�gEg�g�s�s�sus�sEs�s�s 1CCCCCCCCCCAt + 0BBBBBBBBBB@ �gug�g(�gu2g + pg)�g(Eg + pg)ug�g�sus�s(�su2s + ps)�s(Es + ps)us�s�sus 1CCCCCCCCCCAx = 0 (57)where t is time, x is the spatial dimension, �g , ug , Eg , pg, and �g are thedensity, velocity, energy per unit volume, pressure, and volume fraction ofthe gas, and �s, us, Es, ps, and �s are the density, velocity, energy per unitvolume, pressure, and volume fraction of the solid. The seventh equation isthe compaction equation which is used to close the system along with thesaturation condition, �s + �g = 1. Assuming that neither phase has anymaterial strength, the pressure of each phase is a function of the densityand internal energy per unit mass of that phase, pg = pg(�g ; eg) and ps =ps(�s; es), with partial derivatives (ps)�s, (ps)es, (pg)�g , and (pg)eg whereEg = �geg + �gu2g2 and Es = �ses + �su2s2 de�ne the internal energies per unitmass. In addition, assume that the equations of state are de�ned in a mannerconsistent with (pg)�g = pg�g and (ps)�s = ps�s as identities. A more detailedversion of the model is considered in [8].Under the above assumptions, the eigenvalues are ug � cg , ug, ug + cg ,us � cs, us, us + cs, and us, with corresponding left and right eigenvectors~L1 = �b2g2 + ug2cg ; �b1gug2 � 12cg ; b1g2 ; 0; 0; 0; 0� (58)~L2 = (1� b2g; b1gug;�b1g; 0; 0; 0; 0) (59)~L3 = �b2g2 � ug2cg ; �b1gug2 + 12cg ; b1g2 ; 0; 0; 0; 0� (60)26

Page 27: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

~L4 = �0; 0; 0; b2s2 + us2cs ; �b1sus2 � 12cs ; b1s2 ; 0� (61)~L5 = (0; 0; 0; 1� b2s; b1sus;�b1s; 0) (62)~L6 = �0; 0; 0; b2s2 � us2cs ; �b1sus2 + 12cs ; b1s2 ; 0� (63)~L7 = (0; 0; 0;�1; 0; 0; �s) (64)~R1 = 0BBBBBBBBBB@ 1ug � cgHg � ugcg0000 1CCCCCCCCCCA ; ~R2 = 0BBBBBBBBBB@ 1ugHg � 1b1g0000 1CCCCCCCCCCA ; ~R3 = 0BBBBBBBBBB@ 1ug + cgHg + ugcg0000 1CCCCCCCCCCA(65)~R4 = 0BBBBBBBBBB@ 0001us � csHs � uscs1�s 1CCCCCCCCCCA ; ~R5 = 0BBBBBBBBBB@ 0001usHs � 1b1s1�s 1CCCCCCCCCCA ; ~R6 = 0BBBBBBBBBB@ 0001us + csHs + uscs1�s 1CCCCCCCCCCA(66)~R7 = 0BBBBBBBBBB@ 0000001�s 1CCCCCCCCCCA (67)�g = (pg)eg�g ; cg = s(pg)�g + �gpg�g (68)27

Page 28: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

�s = (ps)es�s ; cs = s(ps)�s + �sps�s (69)Hg = Eg + pg�g ; Hs = Es + ps�s (70)b1g = �gc2g ; b2g = 1+ b1gu2g � b1gHg (71)b1s = �sc2s ; b2s = 1 + b1su2s � b1sHs (72)5.1 Numerical MethodThe seven left eigenvectors are used to project into the characteristic �elds,while only the �rst six entries of the seven right eigenvectors are used toproject out of these �elds, since the minimal system consists of the �rst sixequations. This avoids the common division by zero problem introduced bythe seventh term in the right eigenvectors, i.e. the 1�s term. This term blowsup when a chemical reaction depletes �s to zero and has forced unphysicalmodeling, e.g. solid cores [10], to avoid the problem. (Another method usedto avoid this problem involves the use of central schemes [17, 19].) In [8],a priori knowledge that the seventh entry of the right eigenvectors couldbe discarded motivated manipulation of the eigensystem in a manner thatforces this division by zero problem into that location eliminating it entirely.The volume fraction evolution equation(�s)t + us(�s)x = 0 (73)is an advection equation, and it can be discretized independently noting thatthe characteristic information is determined by us and that nothing need beconserved. 28

Page 29: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

5.2 ExamplesIn [10], a conservation law for the number of particles per unit volument + (usn)x = 0 (74)was added to the one dimensional BN model. Inclusion of equation 74 leadsto a new weak hyperbolicity when �s = 0 due to the \blow-up" of theresulting n�s�s term in the eigensystem. See [10] for details.Using the continuity equation for the solid, equation 74 can be rewrittenin advection form � n�s�s�t + us� n�s�s�x = 0 (75)where the advected quantity is the number or particles per unit mass. Thisquantity blows up as the chemical reaction proceeds to completion, i.e. as�s ! 0. Since n is de�ned as the volume fraction divided by the particlevolume n = �sVp (76)equation 75 is equivalent to� 1�sVp�t + us� 1�sVp�x = 0 (77)which blows up when Vp ! 0.The problem with equations 74, 75, and 77 is that they are all derivedby advecting a quantity that blows up as the reaction proceeds to comple-tion. This can trivially be avoided by advecting an equivalent quantity thatvanishes as the reaction proceeds to completion. As the number of particlesper unit mass blows up, the mass per particle vanishes. Replacing equation75 with (�sVp)t + us (�sVp)x = 0 (78)and solving this equation in advection form removes the weak hyperbolicity.All that remains are some decoding errors that occur when computing nfrom equation 76, although n is no longer needed to solve the system. Ifconservation form is preferred, then equation 78 can be combined with thecontinuity equation of the solid to obtain��2s�sVp�t + �us�2s�sVp�x = 0 (79)29

Page 30: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

which can be substituted in place of equation 74 resulting in an eigensystemthat contains a well behaved �sVp term instead of a poorly behaved n�s�sterm.In �gure 8 we repeat a simple shock tube calculation from [10] usingequation 78 for the mass per particle to replace the conservation equationfor n. We use a 10m domain with 200 grid cells and a �nal time of :006seconds. Initially, �g = �s = 10 kgm3 and pg = ps = 1:0 � 106Pa on the left,while �g = �s = 1 kgm3 and pg = ps = 1:0� 105Pa on the right. In addition,ug = us = 0ms , �s = :7, and n = 1:19 � 1011 particlesm3 everywhere. Boththe solid and the gas phase are assumerd to obey p = �RT and e = cvTwith Rg = Rs = 287 JkgK , (cv)g = 718 JkgK , and (cv)s = 239 JkgK . The resultscompare well with those from [10] where the conservation equation for n wasused. Note that the solution for the mass per particle variable only containsa simple contact discontinuity propagating to the right, while the solutionsfor the particle volume variable and the number of particle per unit volumevariable both contain shocks and rarefactions.

30

Page 31: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

−5 0 5

2

4

6

8

10

den(g)

−5 0 50

100

200

300

vel(g)

−5 0 5

0.5

1

1.5

2

2.5

x 106 ene(g)

−5 0 5

2

4

6

8

10

x 105 press(g)

−5 0 5

300

400

500

temp(g)

−5 0 5

0.28

0.3

0.32

phi(g)

−5 0 5

2

4

6

8

10

den(s)

−5 0 50

100

200

vel(s)

−5 0 5

2

4

6

8

x 105 ene(s)

−5 0 5

2

4

6

8

10

x 105 press(s)

−5 0 5

200

300

400

500

600

temp(s)

−5 0 5

0.65

0.7

0.75

phi(s)

−5 0 50.60.8

11.21.41.61.8

x 1011 n

−5 0 54

6

8

10

x 10−12 Vp

−5 0 5

2

4

6x 10

−11den(s) * VpFigure 8: BN calculation31

Page 32: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

A Central SchemesThe examples in this paper were discussed based on an upwind discretizationwith eigenvector projections. In this appendix, a central discretization isbrie y discussed. See [17] and [19] for examples of central schemes.Consider the one dimensional Euler equations with Z satisfying the fol-lowing advection equation Zt + uZx = 0 (80)which can be placed into conservation form along with the Euler equations0BBB@ ��uE�Z 1CCCAt +0BBB@ �u�u2 + p(E + p)u�uZ 1CCCAx = 0 (81)and discretized equation by equation with a central scheme. The new tech-nique presented in this paper would not alter the central discretization ofthe Euler equations, but equation 80 would be discretized in nonconserva-tive form instead of (�Z)t + (�uZ)x = 0 (82)in conservation form. Equation 82 requires arti�cial numerical dissipationproportional to the maximum of ju + cj and ju� cj when discretizing witha central scheme since it includes the continuity equation by construction.Moreover, shocks and rarefactions can occur in �Z. In contrast, equation 80does not require this (possibly large) numerical dissipation and there are noshocks or rarefactions in Z.32

Page 33: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

B Advection Equation DiscretizationConsider an advection equation of the formZt + uZx + vZy = 0 (83)where Z is the advected quantity and u and v are the particle velocities inthe x and y direction respectfully. Nonconservative ux based discretizationsfor Zx are given below. Zy is discretized in a similar fashion and then thesetwo terms are combined with u and v at each grid node before applying a3rd order TVD Runge Kutta method [9, 22] for time integration.B.1 Nonconservative Flux Based ENO DiscretizationA nonconservative extension of the ENO-Roe discretization is used, sincethere are no nonlinear waves such as shocks and rarefactions [9, 22].The numerical ux function F is de�ned through the relation(Zx)i = Fi+ 12 � Fi� 124x (84)where the Fi� 12 are the values of the numerical ux function at the cell walls.The numerical ux function is constructed at the cell walls by consideringthe primitive function H of another function h, where h is identical to thenumerical ux function F at the cell walls.H is calculated at the cell walls with polynomial interpolation. Thezeroth order divided di�erences, D0i+ 12 , and all higher order even divideddi�erences of H exist at the cell walls and have the subscript i� 12 . The �rstorder divided di�erences D1i and all higher order odd divided di�erences ofH exist at the grid points and have the subscript i. Note that, the zerothorder divided di�erences of H vanish with di�erentiation and are not needed.The �rst order divided di�erences of H are,D1iH = Zi (85)and the higher divided di�erences are,D2i+ 12H = 12D1i+ 12Z; D3iH = 13D2iZ (86)33

Page 34: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

Consider a speci�c grid point i0. If ui0 = 0, then setting (Zx)i0 = 0will be algorithmically correct since (uZx)i0 = 0 is desired, otherwise ui0determines the upwind direction.The associated numerical ux function Fi0+ 12 is de�ned as follows: Ifui0 > 0, then k = i0. If ui0 < 0, then k = i0 + 1. De�neQ1(x) = (D1kH)(x� xi0+ 12 ) (87)If jD2k�12H j � jD2k+ 12H j, then c = D2k� 12H and k? = k � 1. Otherwise,c = D2k+ 12H and k? = k. De�neQ2(x) = c(x� xk�12 )(x� xk+ 12 ) (88)If jD3k?H j � jD3k?+1H j, then c? = D3k?H . Otherwise, c? = D3k?+1H . De�neQ3(x) = c?(x� xk?� 12 )(x� xk?+ 12 )(x� xk?+ 32 ) (89)Then Fi0+ 12 =D1kH + c (2(i0 � k) + 1)4x+ c? �3(i0 � k?)2 � 1� (4x)2 (90)Likewise, the associated numerical ux function Fi0� 12 is de�ned as fol-lows: If ui0 > 0, then k = i0 � 1. If ui0 < 0, then k = i0. De�neQ1(x) = (D1kH)(x� xi0� 12 ) (91)If jD2k�12H j � jD2k+ 12H j, then c = D2k� 12H and k? = k � 1. Otherwise,c = D2k+ 12H and k? = k. De�neQ2(x) = c(x� xk�12 )(x� xk+ 12 ) (92)If jD3k?H j � jD3k?+1H j, then c? = D3k?H . Otherwise, c? = D3k?+1H . De�neQ3(x) = c?(x� xk?� 12 )(x� xk?+ 12 )(x� xk?+ 32 ) (93)Then Fi0� 12 =D1kH + c (2(i0 � 1� k) + 1)4x+ c? �3(i0 � 1� k?)2 � 1� (4x)2 (94)Finally, (Zx)i0 is given by equation 84.34

Page 35: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

B.2 Nonconservative Flux Based WENO DiscretizationConsider a 5th order WENO scheme with the parameter � [12]. Large val-ues of � cause the stencil to be biased toward central di�erencing (causingoscillations), while small values of � cause the stencil to be biased toward3rd order ENO (lowering the order). To get a stencil biased toward the �fthorder ux � is de�ned as� = 10�6maxfv21; v22; v23; v24; v25g+ 10�99 (95)where 10�99 is used to avoid division by zero and should be much smallerthan the �rst term in most regions of the domain.Consider a speci�c grid point i0. If ui0 = 0, then setting (Zx)i0 = 0will be algorithmically correct since (uZx)i0 = 0 is desired, otherwise ui0determines the upwind direction.The associated numerical ux function Fi0+ 12 is de�ned as follows: Ifui0 > 0, then v1 = Zi0�2, v2 = Zi0�1, v3 = Zi0 , v4 = Zi0+1, and v5 = Zi0+2.If ui0 < 0, then v1 = Zi0+3, v2 = Zi0+2, v3 = Zi0+1, v4 = Zi0 , and v5 = Zi0�1.De�ne the smoothnessS1 = 1312(v1 � 2v2 + v3)2 + 14(v1 � 4v2 + 3v3)2 (96)S2 = 1312(v2 � 2v3 + v4)2 + 14(v2 � v4)2 (97)S3 = 1312(v3 � 2v4 + v5)2 + 14(3v3 � 4v4 + v5)2 (98)and the weights a1 = 110 1(�+ S1)2 ; w1 = a1a1 + a2 + a3 (99)a2 = 610 1(�+ S2)2 ; w2 = a2a1 + a2 + a3 (100)a3 = 310 1(�+ S3)2 ; w3 = a3a1 + a2 + a3 (101)35

Page 36: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

to get the ux Fi0+ 12 =w1(v13 � 7v26 + 11v36 ) + w2(�v26 + 5v36 + v43 ) + w3(v33 + 5v46 � v56 ) (102)Likewise, the associated numerical ux function Fi0� 12 is de�ned as fol-lows: If ui0 > 0, then v1 = Zi0�3, v2 = Zi0�2, v3 = Zi0�1, v4 = Zi0 , andv5 = Zi0+1. If ui0 < 0, then v1 = Zi0+2, v2 = Zi0+1, v3 = Zi0 , v4 = Zi0�1,and v5 = Zi0�2.Then the smoothness, weights, and ux are de�ned exactly as aboveyielding Fi0� 12 =w1(v13 � 7v26 + 11v36 ) + w2(�v26 + 5v36 + v43 ) + w3(v33 + 5v46 � v56 ) (103)Finally, (Zx)i0 = Fi0+ 12 � Fi0� 124x (104)

36

Page 37: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

References[1] M. Baer and J. Nunziato, A Two-Phase Mixture Theory for the the De- agration to Detonation Transition (DDT) in Reactive Granular Mate-rials, Int. J. Multiphase Flow, Vol. 12, No. 6, pp. 861-889, (1986).[2] J.B. Bdzil, R. Meniko�, S.F. Son, A.K. Kapila, and D.S. Stewart, Two-phase modeling of de agration-to-detonation transition in granular ma-terials: A critical examination of modeling issues, Phys. Fluids 11, 378-402 (1999).[3] J.B. Bdzil and S.F. Son, Engineering Models of De agration to Detona-tion Transition, LA-12794-MS, 1994.[4] Fedkiw, Ronald P., A Survey of Chemically Reacting, CompressibleFlows, UCLA (Dissertation), 1996.[5] Fedkiw, R., Aslam, T., Merriman, B., and Osher, S., A Non-OscillatoryEulerian Approach to Interfaces in Multimaterial Flows (The GhostFluid Method), J. Computational Physics, vol. 152, n. 2, 457-492 (1999).[6] Fedkiw, R., Merriman, B., and Osher, S., E�cient characteristic projec-tion in upwind di�erence schemes for hyperbolic systems (The Comple-mentary Projection Method), J. Computational Physics, vol. 141, 22-36(1998).[7] Fedkiw, R., Merriman, B., and Osher, S., High accuracy numericalmethods for thermally perfect gas ows with chemistry, J. Computa-tional Physics 132, 175-190 (1997).[8] Fedkiw, R., Merriman, B., and Osher, S., A high order e�cient numer-ical approach to the BN two phase explosives model, (in preparation).[9] Fedkiw, R., Merriman, B., Donat, R., and Osher, S., The PenultimateScheme for Systems of Conservation Laws: Finite Di�erence ENO withMarquina's Flux Splitting, Progress in Numerical Solutions of PartialDi�erental Equations, Arachon, France, edited by M. Hafez, July 1998.37

Page 38: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

[10] Gonthier, Keith Alan, A Numerical Investigation of the Evolution ofSelf-Propagating Detonation in Energetic Granular Solids, Universityof Notre Dame (Dissertation), 1996.[11] G.-S. Jiang and D. Peng, Weighted ENO Schemes for Hamilton Ja-cobi Equations, UCLA CAM Report 97-29, June 1997, SIAM J. Num.Analysis (to appear).[12] G.-S. Jiang and C.-W. Shu, E�cient Implementation of Weighted ENOSchemes, J. Computational Physics, v126, 202-228, (1996).[13] Karni, S., Viscous shock pro�les and primitive formulations, SIAM J.Numer. Anal., 29 (1992), pp. 1592-1609.[14] Lax, P.D. and Wendro�, B., Systems of Conservation Laws, Comm.Pure Appl. Math, v. 13 (1960) pp. 217-237.[15] Leveque, R.J., Numerical Methods for Conservation Laws, Birkauser-Verlag, Basel, (1992), p. 123.[16] Larrouturou, B. and Fezoui, L. On the Equations of Multi-ComponentPerfect of Real Gas Inviscid Flow, Lecture Notes in Mathematics, v.1402, p. 69, Springer Verlag, Heidelberg, 1988.[17] Liu, X-D., and S. Osher, Convex ENO High Order Schemes With-out Field-by-Field Decomposition or Staggered Grids, J. Comput Phys,v142, pp 304-330, (1998).[18] Mulder, W., Osher, S., and Sethian, J.A., Computing Interface Mo-tion in Compressible Gas Dynamics, J. Comput. Phys., v. 100, 209-228(1992).[19] H. Nessyahu and E. Tadmor, Nonoscillatory Central Di�erencing forHyperbolic Conservation Laws, J. Computational Physics, v87, (1990),pp408-448.[20] S. Osher, J.A. Sethian, Fronts Propagating with Curvature DependentSpeed. Algorithms Based on Hamilton-Jacobi Formulations, J. Compu-tational Physics, V 79, (1988), pp 121-49.[21] S. Osher, C.W. Shu, High Order Essentially Non-Oscillatory Schemesfor Hamilton-Jacobi Equations, Siam J. Numer. Anal., Vol 28, 1991, pp902-921. 38

Page 39: 1 In - PhysBAMphysbam.stanford.edu/~fedkiw/papers/cam1998-16.pdf · w, c hemically re-acting o w, and explosiv e materials mo deling. In the last instance, the exibilit y in tro duced

[22] Shu, C.W. and Osher, S., E�cient Implementation of Essentially Non-Oscillatory Shock Capturing Schemes II (two), Journal of Computa-tional Physics; Volume 83, (1989), pp 32-78.

39