HUNGAR~JOURNAL OF INDUS1RIAL CHEMIS1RY VESZPREM Vol. 29. pp. 81- 86 (2001) COMPUTER CONSTRUCTION OF CHEMICAL REACTION MECHANISMS B. V. ALEXEEV, N. I. KOLTSOV and F. J. KElL 1 (Department of Physical Chemistry of Chuvash State University, Moskovskii prospekt 15, 428015 Cheboksruy, RUSSIA 1Department of Chemical Engineering, Technical University of Hrunburg-Harburg, Eissendorfer Strasse 38, D-21073 Hrunburg, GERMANY) Received: Decernoer 28, 2000 A computer progrrun was developed which permits the design of all possible mechanisms of a certain class of chemical reactions proceeding according to a step scheme via intermediate components and a brutto-reaction. The application of the progrrun for concrete reactions is described. Keywords: chemical reaction, reaction mechanism, algorithm, intermidiate substances, Maple progrrun Introduction It is of great importance to find a mechanism of a chemical reaction in accordance with measurements. The solution of this problem is based on the formulation of all possible step schemes describing the experimental peculiarities of the reaction. It is based also on choosing a mechanism consisting of intermediate components in the various steps which is confirmed by the corresponding physico-chemical methods. In the publications [1-3] the systematization of all possible three- and four-step mechanisms of catalytic reactions is carried out. For these mechanisms the relaxation time [1] and autooscillations [2,3] were investigated. As a base for generating these mechanisms, transient steps of intermediate components on a catalyst surface are taken without referring to special chemical reactants. In the present paper a program for the automatic generation of stoichiometric factors of a certain class of reactions will be presented. The algorithm and the program The computer program which allows the design of step schemes of chemical reactions like (1) (i = l, ... ,sA; l = l, ... ,nA), is described in this paper. They proceed via the following steps L,.a;x i = L,.aijX i , d,; j (i = l, ... ,sx, j == l, ... ,nx; r = l, ... ,q ), (2) where A1 , X j are reactants and intermediate substances; nA, nx are the numbers of reactants and intermediate substances; sA, sx are the number of brutto-reactions (1) and steps (2) in the mechanism, respectively; a; 2 0 and c: 2 0 are stoichiometric coefficients; d,; > 0 are stoichiometric numbers of the i-th step in the r-th route (a route is a linear combination of elementary steps which lead to the final brutto reaction of the reactants); q is the number of routes. The goal of the program is to determine all possible mechanisms of step scheme (2) in the form 2);A1 + L,.a;x j "'l:h;A1 + L,.a;;x j (3) l j l j taking into account brutto-reactions of eq. (1). It is worth noting that the scheme {2) is supposed to be given and the program provides the selection of basic substances for this scheme. The program searches not only for the stoichiometric coefficients b1i , but also guarantees the satisfaction of the laws of conservation 82 Table 1 The block diagram of algorithm of the program Defining of stage scheme a*X=a_ *X and brutto-scheme c* A=c_ *A by lists of stages, written in a form of linear equations, connecting the symbols of intermediates and basic substances, respectively . • Calculating the matrix of stoichiometric numbers a-a_ and the vector of intermediates X on a stage scheme given. • Calculating the number and basis of conservation laws alpha of stage scheme, defined from the property, that they belong to right kernel of the matrix of stoichiometric numbers . • Calculating the number and basis of routes d of stage scheme, defined from the property, that they belong to left kernel of the matrix of stoichiometric numbers . • Calculating the matrix of stoichiometric numbers c-c_ and the vector of basic substances A by the given brutto-scheme. • Calculating the number and basis of conservation laws beta of brutto-scheme, defined from the property, that they belong to right kernel of the matrix of stoichiometric numbers. t Calculating the number and basis of routes r of brutto-scheme, defined from the property, that they belong to left kernel of the matrix of stoichiometric numbers. t Finding the matrix of stoichiometric coefficients b-b_ from the matrix equation d*{b-b_)=u*(c-c_). Usually, the solution is not unique, and may possess some arbitrary parameters v in addition to parameters u. As separate determinion of matrices of stoichiometric numbers b and b_ is impossible under approach .exploited here, the coefficients of the matrix b could be considered as arbitrary. When matrices u, v and b are selected, matrix b_ could be calculated uniquely. t Calculating the molecularities matrix gamma from the matrix equation {a-a_)*gamma=-{b-b_)*beta, this constitutes the second condition mentioned above. The solution might be non-unique, wich may cause the appearing of another arbitrary matrix w. t Printing the problem solution in a form of stages b*A+a*X=b_ *A+a_ *X of a mechanism and chemical formulas of intermediates lnX=alpha *lnZ+gamma *lnP and the basic substances lnA=beta*lnP. t for reactants and intermediate substances and the chemical formulas of the species Xi and reactants A1 • (5) The algorithm is as follows. The chemical formulas of intermediates X 1 are written in the form x1 =fiz:"'*llP!", where ai* are numbers of adsorption sites of catalyst atoms of type Z" where the intermediates X. are J (4) k k where Zt and lk are the types of catalyst and types of reactant atoms. The chemical formulas of the reactants "'* have the following form adsorbed; f3 ik are numbers of adsorbing reactants of type lk on the adsorbing sites zk ; r lk are the numbers which connect of numbers a Jk , fJ J< and the stoichiometric coefficients by the following relations L(a1; -aij)aik =0; j :LO then lprint('Routes matrix, d'); print(d); fi fi: # Step 5 Matrix c-c_ & vector A lprint('Brutto reaction step scheme given',BruttoScheme); Brutos:=nops(BruttoScheme ): I print(' Steps founded',Brutos); Species V ector:=transpose(matrix([[ op(indets(BruttoScheme))] ])): Species:=rowdim(SpeciesVector): lprint('Species founded',Species): lprint('Species vector'): print( Species Vector): if ( { op(Intermediates Vector)} intersect { op(SpeciesVector) })<>{} then ERROR('Intermediates vector' ,Intermediates Vector, 'of step scheme', StepScheme, 'and species vector',Species Vector,' ofbrutto reaction' ,Brutto, 'must have zero intersection', { op(Intermediates Vector)} intersect { op(Species Vector)}) fi; 'c-c_':=njatrix(Brutos,Species,[seq([seq(coeff(op(l, BruttoScheme[i])-op(2,BruttoScheme[i]), SpeciesVector[j,l]),j=l .. Species)],i=l .. Brutos)]): lprint('Stoichiometric matrix ofbrutto reaction step scheme, c-c_ '); print('c-c_ '); # Step 6 Conservation laws beta beta:=transpose(matrix([op(kernel('c-c_'))])): BruttoLaws:=coldim(beta): lprint('Brutto conservation laws founded' ,BruttoLaws ); if BruttoLaws>O then !print(' Conservation laws matrix, beta'); print(beta) fi: # Step 7 Routes r r:=matrix([op(kernel(transpose('c-c_ ')))]): BruttoRoutes:=rowdim(r): lprint('Brutto routes founded', BruttoRoutes); if BruttoRoutes>O then lprint('Brutto routes matrix'); print(r) fi; # Step 8 Stoichiometric matrix b-b_ RowSp:=matrix([ op(rowspan(' c-c_ ')) ]): u:=array(l .. Routes, l .. rowdim(RowSp) ): mu:=multiply(u,RowSp )~ 'b-b_ ':=linsolve( d,mu,'R','v'): lprint('Matrix b-b_ '): print('b-b_ '): !print(' Verification: matrix expression d*(b-b_)*beta'): 'd*(b-b_)*beta':=evalm(d &* 'b-b_' &* beta); print(' d*(b-b_)*beta '): I print(' must be zero matrix'): ifiszero('d*(b-b_)*beta') then lprint('Verification passed') else ERROR(' Matrix expression d*(b-b_)*beta must be zero matrix') fi; b:=array(l..Steps,l..Species): lprint('Matrix b'): print(b): b_:=matadd(b,'b-b_ ',1,-1): lprint('Matrix b_ '): print(b_): #Step 9 Matrix gamma gama:=linsolve('a-a_ ',evalm(-'b-b_" & * beta),'r2' ,'w'): I print(' Stoichiometric matrix, gama '); print(gama); Iprint('Verification: matrix expression (a-a_)*gama+(b- b_)*beta'); '(a-a_)*gama+(b-b_)*beta':=evalm('a-a_' &* gama+'b-b_' &*beta): print('(a-a_)*gama+(b-b_)*beta'); lprint('must be zero matrix'); if iszero('(a-a_}*gama+(b-b_)*beta ') then lprint('Verification passed') else ERROR('Matrix expression (a-a_)*gama+(b- b_)*beta must be zero matrix') fi; # Step 10 Print the solution lprint("Intennediates step scheme'): print(StepScheme): lprint('Brutto step scheme'): print(BruttoScheme ): Z:=['Z.i'$'i'=l..Laws]: P:=['P .i'$'i'= I .. BruttoLaws ]: m:=evalm(b &*Species Vector+ a&* Intermediates Vector): m_:=evalm(b_ &*Species Vector+ a_&* Intermediates Vector): eqs:=array(['['m[i.j]=m_[i,j]'$'i'= l .. rowdim(m) ]'$)'=I .. coidim( m_)J): lprint('Reaction mechanism'):print(eqs): m3:=evalm(alpha &* Z + gama &* P): ln:=[seq(IntermediatesVector[i,l]=m3[i],i=l . .Intennediates)]: lprint('Chemical formulas of intermediates~): print(In): m4:=evalm(beta &* P): Sp:=[seq(SpeciesVector[i,l]=m4[i],i=l .. Species)]: lprint('Chemical fonnulas of species'); print(Sp): Example 1. 85 For the reaction 2CO + 0 2 = 2C02 , proceeding in a four-step scheme 1. 2X1 = 2X 2 , 2. X 1 = X 3 , 3. X2 +X3 =2X 1 , 4. X2 =X1 , initial data was entered in a form StepScheme:=[2*x1=2 *x2,xl=x3,x2+x3=2*xl,x2=x 1]; BruttoScheme:=[2*C0+02=2 *C02]; The set of mechanisms of a reaction of carbon monoxide oxidation, which is found by the program, has the following form 1. b 11 CO + b 12 0 2 + bi3C02 + 2X1 = =(b 11 -4u 21 -2u 11 +2v 11 )CO+ +(blz -2uzl-ul! +2Vzr)02 + +(b 13 +2u 11 +4u 21 +2v31 )C02 +2X 2, 2. b 21 CO + b 22 0 2 + h 23C0 2 + xl = = (b 21 +2u 21 +v 12 -v 11 )C0+ +(b2I2 +u21 +Vzz -Vzi)Oz + +(b23 -2Uzt +v32 -v31)C0z +X3, 3. b:11Co + b 32 0 2 + b 33C0 2 + X 2 + x 3 = = (b31 -vtz)CO+(b32 -Vzz)Oz + +(b33 -v3z)COz +2Xl, 4. b 41CO+b 42 0 2 +b 43 C02 +X2 = =(b41 -vn)CO+(b42 -Vzt)Oz + + (b43- V31) COz + Xp (9) where bu, Uu, v u are free parameters. The chemical formulas of intermediate substances are determined by the relations where Z1 are free centres on a catalyst surface, ~ and P2 are atoms or atom complexes out of which the basic substances are fonned. w11 , w21 are free parameters. The chemical formulas of basic substances are determined by the program as CO= f;, 0 2 = F;- 2 P2 2 , C02 = P-:.. 86 li and ~ complexes in this model form oxide and Brutto step scheme carbon dioxide respectively. 2CO + 2NO = 2C02 + N 2 Reaction mechanism Example 2. 1. b11 CO +b12 C02 +b13 NO +b14 N 2 + 2X 1 = Three-step mechanism 1. 2X1 = X 2 + X3 , 2. X 2 =X1 , is supposed to be realized for the reaction 2CO + 2NO = 2C02 + N 2 . The initial data for the program will be StepScheme:=[2*xl=x2+x3,x2=xl ,x3=x2]; BruttoScheme:=[2*C0+2*N0=2*C02+N2]; The part of the program output is given below. Intermediates step scheme 2X1 = X 2 +X3, X 2 = X1, X3 = X2 = (b 11 - 2u11 + 2v11 + v12 )CO+ + (b12 + 2u11 + 2v21 + v22 )C02 + + (b13 - 2u11 + 2v31 + v32 )NO+ + (b14 + Uu + 2v 41 + v 42 )N 2 + X 2 + X 3' 2. h21 CO +h22 C02 +h23 NO +b24 N 2 + X 2 = = (b21 - v11 )CO + (b22 - v21 )C02 + (10) + (b23 -v31 )NO + (b24 - v41 )N2 + Xp 3. b31 CO+b32 C02 +b33 NO+b34 Nz +X3 = = (b31 - v12 )CO+ (b32 - v22 )C02 + + (b33 -v3z)NO + (b34- v42)N2 + Xz Chemical formulas of intermediates X - Z P. Wn P. w21 P. w31 I- 1 I 2 3 ' X _ z P.-v31-2v41+wn p_-v2I+2v4I+w2t R-vu-2v4I +w3I 2- I 1 2 3 ' X -z v-v32 -2v42 -2v4I-v3I +wu p -vzz-v2t+2v4t+2v42+w2t 3- tlJ ? .p-vt2-2v42 -vu-2v4I +w3I 3 Chemical formulas of species CO=?:,, C02 = P2 , NO= .Fi, N 2 = li 2 P2- 2 P3 2 • Page 85 Page 86 Page 87 Page 88 Page 89 Page 90