TALK=T;RUN( 1, 1) ** LOAD(x205) from the x Input Library DISPLAY 1DZ Laminar Premixed Burner-Stabilised H2-Air Flame ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This case is identical to library case C204 except that the calculation is performed in the z direction. ENDDIS GROUP 1. Run title and other preliminaries TEXT(CHEMKIN - 1DZ Premixed H2-Air Flame TITLE AUTOPLOT USE file PHI 5 clear d 1 MH2;d 1 MO2;d 1 MH2O;d 1 TEM1; mult y 0.0001 4 plot 1 3;col3 4;colf 4;blb3 3;scale x 0. 0.2 msg H2, O2, H2O mole-fraction & Temp(/1000) profiles msg Pressto continue pause clear d 1 MH;d 1 MO;d 1 MOH;d 1 MHO2 mult y 10. 2;mult y 10. 3;mult y 1000. 4 col3 1 4;col6 2;col9 3;colf 4;scale x 0. 0.2 msg H, O(*10), OH (*10) & HO2(*1000) mole fraction profiles msg Press to continue pause clear msg Heat-release rate profile in erg/s/cm**3 d 1 QDOT;scale x 0. 0.2;plot 1;blb1 1 enduse BOOLEAN(TWOPNT,FICK);CHAR(CHSO) REAL(YLEN,TIN,SUMY,MDOT,YH2IN,YO2IN) MESG( Enter required method of solution for chemistry MESG( Default: CHEMKIN Point-by-Point solver MESG( The alternative is: MESG( Enter PBP for PHOENICS Point-by-Point solver READVDU(CHSO,CHAR,CHS) CASE :CHSO: OF WHEN PBP,3 + TWOPNT=F + MESG(PHOENICS Point-by-point Solver + MESG(2500 sweeps taking 1 hour on 486 PC 75MHz WHEN CHS,3 + TWOPNT=T + MESG(CHEMKIN Point-by-Point Solver + MESG(350 sweeps taking 9 mins on 486 PC 75MHz ENDCASE GROUP 5. Z-direction grid specification YLEN=0.6;GRDPWR(Z,40,YLEN,1.6) GROUP 7. Variables stored, solved & named SOLVE(P1,W1,TEM1);SOLUTN(TEM1,P,P,P,P,P,N) TERMS(TEM1,N,P,P,P,Y,N) There are 8 species in the chemical scheme, and N2 is stored while the remainder are solved. CHEMKIN(SPECIES,...) also sets CHSOB=C1=16 and LSG61=T. CHSOB defines the PHOENICS variable that corresponds with the first CHEMKIN species. CHEMKIN(SPECIES,H2,H,O2,O,OH,HO2,H2O,N2) INTEGER(KK,JJ);KK=8 DO II=1, KK-1 + JJ=CHSOB+II-1 + SOLUTN(:JJ:,P,P,P,P,P,N) ENDDO IF(TWOPNT) THEN ** Sets CHSOA=GRND9 & RESREF's to -1.E-6 + CHEMKIN(REACT,TWOPNT,TEM1) ELSE ** Sets CHEMK1 GRND9 Patches & covals for TEM1 & species + CHEMKIN(REACT,PHOENICS,TEM1) ENDIF STORE(VISL,DEN1,QDOT,ENTH,KOND,SPH1) Store variables for the elemental and mole composition STORE(ELH,PRPS,ELO,ELN,MH2,MO2,MH2O,MOH,MH,MO,MHO2) DIFCUT=0. GROUP 9. Properties of the medium (or media) Activate the CHEMKIN physical property calculations REAL(PROPGR);PROPGR=GRND9 ENUL=PROPGR;CP1=PROPGR; RHO1=PROPGR PRNDTL(TEM1)=-PROPGR ** NB: Only Ficks Law should be used at present due to an error in the Curtis-Hirschfelder species-diffusion model (mrm 08/02/95) FICK=T IF(.NOT.FICK) THEN * Select the Curtis-Hirschfelder formulation for species diffusion + ENULA=GRND9 * Select thermal-diffusion (Soret Effect) terms in the transport equations (if using the Curtiss-Hirschfelder formulation ) + ENULB=GRND9 + DO II=1,KK + JJ=CHSOB+II-1 + PRNDTL(:JJ:)=-GRND9 + ENDDO MESG(WARNING! Curtis-Hirschfelder implementation in error ENDIF ** Sets the stem of the names for the CKLINK and TPLINK files (CSG4='ho11') and the reference pressure CHSOC in Atmospheres. CHEMKIN(PROP,ho11,1.0) CSG10='q1' FIINIT(PRPS)=71 MATFLG=T;NMAT=1 71 GRND9 GRND9 GRND9 GRND9 0. 0.0 0.0 0.0 0.0 GROUP 11. Initialization of variable or porosity fields ARRAY(CIN,REAL,KK) FIINIT(W1)=120. DO II=1,KK + JJ=CHSOB+II-1 + FIINIT(:JJ:)=1.E-4;CIN(:II:)=0.0 ENDDO ** Set the inlet mass-fractions of H2 & O2 and then calculate N2 from overall continuity. SUMY=0.0;YH2IN=0.028522;YO2IN=0.226364 CIN(1)=YH2IN;CIN(2)=0.0;CIN(3)=YO2IN FIINIT(H)=1.E-3; FIINIT(O)=0.02; FIINIT(OH)=0.015 FIINIT(H2O)=18*(CIN(1)/2-CIN(2)-CIN(3)/32-CIN(4)/16-CIN(5)/17) DO II=1,KK + JJ=CHSOB+II-1 + SUMY=SUMY+FIINIT(:JJ:) ENDDO FIINIT(N2)=1.-SUMY ** Initialise temperature to final flame temperature FIINIT(TEM1)=2250. Initiallise the density to a value consistent with the other gas properties INIADD=F PATCH(ICHEMK1,INIVAL,1,NX,1,NY,1,NZ,1,1) INIT(ICHEMK1,DEN1,0.0,GRND1) GROUP 13. Boundary conditions and special sources ** Mass inflow boundary condition Set the inflowing mass-flux to the inflow density*inflow speed, and use NOCPCK... PATCHes to set up the inlet conditions where the inflow speed is derived from the mass flux and density, and the inflowing thermal enthalpy is derived from the gas compostion and temperature . INLET(NOCPCK1,LOW,1,NX,1,NY,1,1,1,LSTEP) VALUE(NOCPCK1,P1,GRND9); VALUE(NOCPCK1,W1,120.) DO II=1,KK + JJ=CHSOB+II-1 + COVAL(NOCPCK1,:JJ:,ONLYMS,CIN(:II:)) ENDDO ** Define inlet temperature via SPEDAT for NOCPCK1 ( earlier versions of CHEMKIN used TMP1A=298, which is still supported ). TIN=298.0 SPEDAT(SET,NOCPCK1,TINLET,R,TIN) COVAL(NOCPCK1,TEM1,ONLYMS,GRND9) ** Allow heat loss to porous plug for flame stabilisation PATCH(FLUXIN,LWALL,1,NX,1,NY,1,1,1,LSTEP) COVAL(FLUXIN,TEM1,1.0,TIN) ** Outflow boundary OUTLET(OUT1,HIGH,1,NX,1,NY,NZ,NZ,1,LSTEP) VALUE(OUT1,P1,0.0) GROUP 15. Termination of sweeps DO II=1,KK + JJ=CHSOB+II-1 + ENDIT(:JJ:)=1.E-6 ENDDO ENDIT(TEM1)=1.E-6 GROUP 16. Termination of iterations GROUP 17. Under-relaxation devices Under-relaxation needs to be fairly tight for the mass-fractions and temperature IF(TWOPNT) THEN + LSWEEP=300;NPLT=5 + CHEMKIN(RELAX,5.E-2) + RELAX(DEN1,LINRLX,0.3) + RELAX(TEM1,FALSDT,1.E-5); RELAX(W1,FALSDT,2.E-5) + SPEDAT(SET,CHEM,BYPASS,L,T) DO II=1,KK + JJ=CHSOB+II-1 + RESREF(:JJ:)=1.E-6 ENDDO + RESREF(TEM1)=1.E-6 ELSE + LSWEEP=2500;NPLT=100; RESFAC=1.E-4 + CHEMKIN(RELAX,1.E-4) + RELAX(TEM1,FALSDT,1.E-6); RELAX(W1,FALSDT,5.E-5) + RELAX(DEN1,LINRLX,0.01) ENDIF GROUP 18. Limits on variables or increments to them ** Prevent TEM1 falling below reference temperature of 0 C. VARMIN(TEM1)=273. GROUP 19. Data communicated by satellite to GROUND GROUP 21. Print-out of variables Only a 1D case so look at all cells; print every 50 sweeps NZPRIN=1;NPRINT=LSWEEP OUTPUT(QDOT,Y,Y,Y,Y,Y,Y); OUTPUT(ENTH,Y,Y,Y,Y,Y,Y) GROUP 22. Spot-value print-out TSTSWP=-1;IZMON=NZ-1;ITABL=3 GROUP 23. Field print-out and plot control Generate 3 plots of fuel & oxidant, of temp. & products, and of radicals PATCH(PROFSZ,PROFIL,NX/2+1,NX/2+1,NY/2+1,NY/2+1,1,NZ,1,LSTEP) COVAL(PROFSZ,H2,0.0,0.0);COVAL(PROFSZ,O2,0.0,0.0) PATCH(PROFSZB,PROFIL,NX/2+1,NX/2+1,NY/2+1,NY/2+1,1,NZ,1,LSTEP) COVAL(PROFSZB,TEM1,0.0,0.0);COVAL(PROFSZB,N2,0.0,0.0) PATCH(PROFSZA,PROFIL,NX/2+1,NX/2+1,NY/2+1,NY/2+1,1,NZ,1,LSTEP) COVAL(PROFSZA,H,0.0,0.0);COVAL(PROFSZA,O,0.0,0.0) COVAL(PROFSZA,OH,0.0,0.0);COVAL(PROFSZA,HO2,0.0,0.0) COVAL(PROFSZA,H2O,0.0,0.0) DISTIL=T GROUP 24. Dumps for restarts LIBREF = 205 IF(TWOPNT) THEN EX(W1 )=5.944E+02 EX(OH )=2.686E-03 EX(HO2 )=2.698E-06 EX(H2O )=1.633E-01 EX(N2 )=7.878E-01 EX(MHO2)=4.065E-06 EX(MH )=1.053E-02 EX(MOH )=5.958E-02 EX(MH2O)=2.036E-01 EX(ELN )=7.878E-01 EX(ELO )=2.264E-01 EX(PRPS)=7.100E+01 EX(ELH )=2.852E-02 EX(SPH1)=1.135E+07 EX(KOND)=1.524E+04 EX(VISL)=3.765E+00 EX(TEM1)=1.727E+03 EX(P1 )=1.702E+01 EX(H2 )=7.266E-03 EX(H )=4.786E-04 EX(O2 )=3.962E-02 EX(O )=7.364E-04 EX(MO )=1.003E-03 EX(MO2 )=2.614E-02 EX(MH2 )=7.759E-02 EX(ENTH)=8.856E+04 EX(QDOT)=6.997E+09 EX(DEN1)=2.294E-04 ENDIF STOP