Difference between revisions of "Premix CH 4/Air flame with scheme GRI12"

From orch
Jump to: navigation, search
(DRGEP step)
 
(60 intermediate revisions by 2 users not shown)
Line 1: Line 1:
This test case concerns the reduction of the detailed scheme GRI12 for a premixed <math>CH_{4}</math>/air flame at P = 1 bar and initial temperature of the oxidizer and the methane at 300 K, for an equivalence ratio of 0.75. The target species are : <math>O_{2}</math>, <math>CO</math> and <math>CO_{2}</math>.
+
== '''Objectives''' ==
  
 +
The Stochastic_GRI12 test case describes a reduction of the GRI1.2 scheme for a 1D premixed flame. Starting with 32 species and 177 reactions, we reduce to 14 species and 26 reactions.
  
=== DRGEP species step ===
+
== '''Key parameters''' ==
  
Your terminal should display the following information :
 
  
<code>
+
The target species considered for this test case are O2, CO and CO2. The characteristics of the premixed flame are displayed below (part of the input_file.ini) :
  scheme : GRI12
+
 
number of species : 32  
+
//------Flame parameters------//
number of reaction : 177  
+
//Flame 0
  reference flame : flames/flame__Phi_0_75__P_100000__T_300.cantera
+
  Tf = 300
  Pressure : 1 bar
+
  To = 300
equivalence ration : 0.75  
+
  Pressure = 1E+05
Composition : <O2:0.202024>
+
  Equivalence_ratio = 0.75
                        <CH4:0.0379821>  
+
  Xf = CH4:1.0             
                        <N2:0.759994>  
+
  Xo = O2:0.21, N2:0.79
</code>
+
// the composition can also be added with mass fractions, for that replace "Xf" by "Yf" and "Xo" by "Yo" 
 +
  Initial_flame = flames/flame__Phi_0_75__P_100000__T_300.cantera
 +
  Final_flame = flames/flame
 +
//End
 +
 
 +
== '''Results''' ==
 +
 
 +
=== DRGEP step ===
 +
 
 +
While running the DRGEP species step (with <code>step = DRGEP_Species</code> in the "input_file.ini"), your terminal should display the following information :
 +
 
 +
  MECHANISM:------------------------------------------------------------------------------------------------------
 +
            Reading initial mechanism "mechanisms/gri12.xml" with description "gri12" ----------> OK
 +
              Number of species: 32
 +
              Number of reactions: 177
 +
 
 +
  PREMIXED FLAME:--------------------------------------------------------------
 +
  Reading initial flame "flames/flame__Phi_0_75__P_100000__T_300.cantera" with description "st_flame" ----------> description: test flame
 +
  OK
 +
              Pressure: 100000
 +
              Equivalence ratio: 0.75
 +
              Composition (mass fractions):  
 +
                                    <O2:0.223145>
 +
                                    <CH4:0.0419532>
 +
                                    <N2:0.734901>
 +
 
  
  
 
followed by the the species associated with their rank :
 
followed by the the species associated with their rank :
  
<code>
+
-------DRGEP coefficients-------
  4.17578965277519e-189 AR  
+
  --------------------------------
  1.81320667696424e-06  HCCOH  
+
1.37642e-15 AR
  3.33272520534669e-05  C2H  
+
  2.12795e-06  HCCOH
  0.000136594690602079 CH2CO  
+
  4.32935e-05  C2H
  0.000228724937160335 C  
+
  0.000157543 CH2CO
  0.00039194258246205 C2H2  
+
  0.000362521 C
  0.000909271897890726 HCCO  
+
  0.000444401 C2H2
  0.00324304055657054 CH
+
  0.00101888 HCCO
  0.00391278892730799 C2H3
+
  0.00357515 C2H3
  0.00395833642581853 CH3OH
+
  0.00398744 CH3OH
  0.00517918655958378 CH2OH  
+
  0.00409277 CH
  0.0158390004661296 C2H4  
+
  0.00543294 CH2OH
  0.0158390004661296 C2H5  
+
  0.0126485 C2H4
  0.0160151369051444 CH2(S)
+
  0.0126485 C2H5
  0.0209164664682532 C2H6
+
  0.0170844 CH2(S)
  0.0317122146887158 CH2  
+
  0.0190984 C2H6
  0.0395596174129288 H2O2
+
  0.0314311 CH2
  0.0796917798682698 H2  
+
  0.0362943 H2O2
  0.0949180222420726 CH3  
+
  0.0844714 H2
  0.108929211050051 HCO
+
  0.0862782 CH3
  0.123697044495215 CH2O
+
  0.105794 CH2O
  0.154156160901222 H2O  
+
  0.110349 HCO
  0.165970760424094 CH3O  
+
  0.141159 H2O
  0.222439341655666 O  
+
  0.150828 CH3O
  0.292243743837601 HO2  
+
  0.218864 O
  0.501413374426018 OH  
+
  0.294638 HO2
  0.501449580770414 H  
+
  0.48461 OH
  1  O2  
+
  0.48475 H
 +
  1  O2
 
  1  CH4
 
  1  CH4
  1  CO  
+
  1  CO
  1  CO2  
+
  1  CO2
 
  1  N2
 
  1  N2
</code>
+
 
 +
 
 +
 
 +
 
 +
From a detailed 32 species scheme, we obtain reduced schemes (31 to 14 species). and we choose the one with 14 species for the next step because the shape of the velocity and species are conserved (and Cantera is unable to converge the 13-species scheme. The code will therefore end with an error message. But it is fine). The following Figure 1 is available in the directory <code>outputs/Premixed/</code> with the file format of EPS.
 +
 
 +
[[File:DRGEPSpec_14Sp_42R_Premixed.png|900px|center]]
 +
 
 +
Fig1 : Comparison between the reference trajectories of the target species, the temperature and the flame speed  (in black), and the trajectories computed with the reduced mechanism with 14 transported species and 42 reactions, after a DRGEP species reduction  (in red).
 +
 
 +
 
 +
 
 +
From the reduced scheme with 14 species, we then perform the next DRGEP Reactions step by manually change the value of the "step" keyword in the "input_file.ini" as <code>step = DRGEP_Reactions</code>. Make sure the reference mechanism and trajectory are correctly set up (i.e., <code>mech_ref = mechanisms/gri12.xml; trajectory_ref = Ref_DRGEP_Species32</code>). The DRGEP Reactions step displays the associated 42 reactions (forward, reverse and global) with their rank :
 +
 
 +
 
 +
Reaction 22  9.23227e-06
 +
Reaction 1  2.08238e-05
 +
Reaction 11  2.29985e-05
 +
Reaction 2  5.30076e-05
 +
Reaction 12  0.00029274
 +
Reaction 18  0.00191785
 +
Reaction 6  0.00198407
 +
Reaction 36  0.00293471
 +
Reaction 38  0.00420356
 +
Reaction 31  0.00462285
 +
Reaction 34  0.00611017
 +
Reaction 7  0.00905302
 +
Reaction 10  0.00921383
 +
Reaction 32  0.0106164
 +
Reaction 37  0.0133867
 +
Reaction 8  0.0136681
 +
Reaction 25  0.0237175
 +
Reaction 24  0.0277978
 +
Reaction 29  0.0305413
 +
Reaction 13  0.0329515
 +
Reaction 9  0.0342601
 +
Reaction 3  0.0398655
 +
Reaction 5  0.0422524
 +
Reaction 14  0.0442348
 +
Reaction 19  0.0493222
 +
Reaction 35  0.102885
 +
Reaction 40  0.103946
 +
Reaction 26  0.111933
 +
Reaction 30  0.131232
 +
Reaction 23  0.159996
 +
Reaction 21  0.161005
 +
Reaction 20  0.180048
 +
Reaction 39  0.18465
 +
Reaction 42  0.19675
 +
Reaction 4  0.208145
 +
Reaction 15  0.215404
 +
Reaction 16  0.222982
 +
Reaction 27  0.274358
 +
Reaction 17  0.274617
 +
Reaction 33  0.403162
 +
Reaction 41  0.437888
 +
Reaction 28  0.438952
 +
 
 +
 
 +
After this step, by comparing the reference trajectories with the new ones, we choose to delete 16 reactions because after 17 reactions removed, the CO2 profile loose its initial shape.
 +
The next step is performed with 14 species and 26 reactions.
 +
 
 +
[[File:DRGEPR_14sp_26R_Premixed.png|900px|center]]
 +
 
 +
Fig2 : Comparison between the trajectories of the target species, the temperature and the flame speed computed with the reference 32-species 177-reaction mechanism (in black) , and the trajectories computed with the reduced mechanism with 14 transported species and 26 reactions after a DRGEP reaction reduction (in red).
 +
 
 +
=== QSS step ===
 +
 
 +
 
 +
The '''computeQSSCriteria''' step provides the QSS criteria of each species and the different links with the others species :
 +
 
 +
Species H  0.0752034
 +
Species O  0.0211171
 +
Species O2  0.33194
 +
Species OH  0.019287
 +
Species H2O  0.379235
 +
Species HO2  0.0113201
 +
Species CH3  0.107792
 +
Species CH4  0.79541
 +
Species CO  0.693792
 +
Species CO2  0.720209
 +
Species HCO  0.00321461
 +
Species CH2O  0.0817911
 +
Species CH3O  0.0360026
 +
Species N2  0
 +
 
 +
 
 +
Interactions with species H  with QSS Criteria 0.0752034
 +
HO2:2  CH3:1  CH2O:2  CH3O:1  N2:1 
 +
 
 +
Interactions with species O  with QSS Criteria 0.0211171
 +
OH:1  HO2:1  CH3:1  CH2O:1  CH3O:1 
 +
 
 +
Interactions with species OH  with QSS Criteria 0.019287
 +
O:1  OH:2  HO2:1  CH3:2  HCO:2  CH2O:1  CH3O:1 
 +
 
 +
Interactions with species HO2  with QSS Criteria 0.0113201
 +
H:2  O:1  OH:1  CH3:1  CH2O:1  N2:1 
 +
 
 +
Interactions with species CH3  with QSS Criteria 0.107792
 +
H:1  O:1  OH:2  HO2:1 
 +
 
 +
Interactions with species HCO  with QSS Criteria 0.00321461
 +
OH:2 
 +
 
 +
Interactions with species CH2O  with QSS Criteria 0.0817911
 +
H:2  O:1  OH:1  HO2:1 
 +
 
 +
Interactions with species CH3O  with QSS Criteria 0.0360026
 +
H:1  O:1  OH:1 
 +
 
 +
Interactions with species N2  with QSS Criteria 0
 +
H:1  HO2:1 
 +
 
 +
 
 +
 
 +
We choose to put the species CH3O and HCO in QSS hypothesis due to their low QSS coefficient. The species HO2 could have been a good candidate too but it is linked to himself (non linearity).
 +
 
 +
In order to obtain the trajectories of the 14-species 26-reaction reduced scheme with these 2 species in QSS hypothesis, we run the '''getQSSfile''' step and we obtain the following graphs.We observe that the final state and the shape of the trajectories are conserved. It is under these conditions that the optimisation step will be efficient.
 +
 
 +
We can note that the main target profiles are not impacted by the QSS hypothesis, nevertheless the fitness seems better. This is due to errors compensations by the other species not shown here (remind that the fitness is calculated for all species, velocity and temperature, the target just have a larger impact coefficient on the fitness).
 +
 
 +
[[File:QSS_12sp_Premixed.png|900px|center]]
 +
 
 +
Fig3 : Comparison between the reference trajectories of the target species, the temperature and the flame speed (in black), and the trajectories computed with the reduced mechanism with 12 transported species and 26 reactions after a DRGEp reaction reduction (in red).
 +
 
 +
=== Optimisation ===
 +
 
 +
The final step of the ORCh method, the genetic algorithm, enables to recover the trajectories of the target species. Firstly, we allowed a 10 % variation on the pre exponential factor, the temperature exposant and 6 % on the energy activation in order to find their optimal values (i.e., <code>AllowedVariation_A = 0.10; AllowedVariation_b = 0.10; AllowedVariation_E = 0.06</code>).
 +
 
 +
A population of 40 elements was used during 50 generations. The optimisation step supports running in parallel. For example, we can use 20 processors via <code>mpirun -np 20 mainprogram</code>. Just make sure that PopSize divided by the number of processes is an integer. This step may take a long time, like several hours, depending on how many processors are used. The optimised scheme is in <code>analytic_schemes/Ref/</code> while the corresponding EPS figures can be found in <code>analytic_schemes/PLOTS/</code>.
 +
 
 +
 
 +
The following trajectories of the temperature, the flame speed and the target species match perfectly the ones of the reference detailed scheme with only 12 transported species and 26 reactions.
 +
 +
[[File:Optim_PremixGRI12.png|900px|center]]
 +
 
 +
Fig4 : Comparison between the reference trajectories of the target species, the temperature and the flame speed (in black), and the trajectories computed with the reduced mechanism with 12 transported species and 26 reactions after optimisation (in red).
 +
 
 +
== '''Bibliography''' ==

Latest revision as of 16:17, 6 February 2019

Objectives

The Stochastic_GRI12 test case describes a reduction of the GRI1.2 scheme for a 1D premixed flame. Starting with 32 species and 177 reactions, we reduce to 14 species and 26 reactions.

Key parameters

The target species considered for this test case are O2, CO and CO2. The characteristics of the premixed flame are displayed below (part of the input_file.ini) :

//------Flame parameters------//
//Flame 0
 Tf = 300
 To = 300 
 Pressure = 1E+05
 Equivalence_ratio = 0.75 
 Xf = CH4:1.0               
 Xo = O2:0.21, N2:0.79
// the composition can also be added with mass fractions, for that replace "Xf" by "Yf" and "Xo" by "Yo"  
 Initial_flame = flames/flame__Phi_0_75__P_100000__T_300.cantera
 Final_flame = flames/flame
//End

Results

DRGEP step

While running the DRGEP species step (with step = DRGEP_Species in the "input_file.ini"), your terminal should display the following information :

MECHANISM:------------------------------------------------------------------------------------------------------
           Reading initial mechanism "mechanisms/gri12.xml" with description "gri12" ----------> OK
              Number of species: 32
              Number of reactions: 177
PREMIXED FLAME:--------------------------------------------------------------
 Reading initial flame "flames/flame__Phi_0_75__P_100000__T_300.cantera" with description "st_flame" ----------> description: test flame
OK
              Pressure: 100000
              Equivalence ratio: 0.75
              Composition (mass fractions): 
                                   <O2:0.223145>
                                   <CH4:0.0419532>
                                   <N2:0.734901>


followed by the the species associated with their rank :

-------DRGEP coefficients-------
--------------------------------
1.37642e-15  AR
2.12795e-06  HCCOH
4.32935e-05  C2H
0.000157543  CH2CO
0.000362521  C
0.000444401  C2H2
0.00101888  HCCO
0.00357515  C2H3
0.00398744  CH3OH
0.00409277  CH
0.00543294  CH2OH
0.0126485  C2H4
0.0126485  C2H5
0.0170844  CH2(S)
0.0190984  C2H6
0.0314311  CH2
0.0362943  H2O2
0.0844714  H2
0.0862782  CH3
0.105794  CH2O
0.110349  HCO
0.141159  H2O
0.150828  CH3O
0.218864  O
0.294638  HO2
0.48461  OH
0.48475  H
1  O2
1  CH4
1  CO
1  CO2
1  N2



From a detailed 32 species scheme, we obtain reduced schemes (31 to 14 species). and we choose the one with 14 species for the next step because the shape of the velocity and species are conserved (and Cantera is unable to converge the 13-species scheme. The code will therefore end with an error message. But it is fine). The following Figure 1 is available in the directory outputs/Premixed/ with the file format of EPS.

DRGEPSpec 14Sp 42R Premixed.png

Fig1 : Comparison between the reference trajectories of the target species, the temperature and the flame speed (in black), and the trajectories computed with the reduced mechanism with 14 transported species and 42 reactions, after a DRGEP species reduction (in red).


From the reduced scheme with 14 species, we then perform the next DRGEP Reactions step by manually change the value of the "step" keyword in the "input_file.ini" as step = DRGEP_Reactions. Make sure the reference mechanism and trajectory are correctly set up (i.e., mech_ref = mechanisms/gri12.xml; trajectory_ref = Ref_DRGEP_Species32). The DRGEP Reactions step displays the associated 42 reactions (forward, reverse and global) with their rank :


Reaction 22  9.23227e-06
Reaction 1  2.08238e-05
Reaction 11  2.29985e-05
Reaction 2  5.30076e-05
Reaction 12  0.00029274
Reaction 18  0.00191785
Reaction 6  0.00198407
Reaction 36  0.00293471
Reaction 38  0.00420356
Reaction 31  0.00462285
Reaction 34  0.00611017
Reaction 7  0.00905302
Reaction 10  0.00921383
Reaction 32  0.0106164
Reaction 37  0.0133867
Reaction 8  0.0136681
Reaction 25  0.0237175
Reaction 24  0.0277978
Reaction 29  0.0305413
Reaction 13  0.0329515
Reaction 9  0.0342601
Reaction 3  0.0398655
Reaction 5  0.0422524
Reaction 14  0.0442348
Reaction 19  0.0493222
Reaction 35  0.102885
Reaction 40  0.103946
Reaction 26  0.111933
Reaction 30  0.131232
Reaction 23  0.159996
Reaction 21  0.161005
Reaction 20  0.180048
Reaction 39  0.18465
Reaction 42  0.19675
Reaction 4  0.208145
Reaction 15  0.215404
Reaction 16  0.222982
Reaction 27  0.274358
Reaction 17  0.274617
Reaction 33  0.403162
Reaction 41  0.437888
Reaction 28  0.438952


After this step, by comparing the reference trajectories with the new ones, we choose to delete 16 reactions because after 17 reactions removed, the CO2 profile loose its initial shape. The next step is performed with 14 species and 26 reactions.

DRGEPR 14sp 26R Premixed.png

Fig2 : Comparison between the trajectories of the target species, the temperature and the flame speed computed with the reference 32-species 177-reaction mechanism (in black) , and the trajectories computed with the reduced mechanism with 14 transported species and 26 reactions after a DRGEP reaction reduction (in red).

QSS step

The computeQSSCriteria step provides the QSS criteria of each species and the different links with the others species :

Species H  0.0752034
Species O  0.0211171
Species O2  0.33194
Species OH  0.019287
Species H2O  0.379235
Species HO2  0.0113201
Species CH3  0.107792
Species CH4  0.79541
Species CO  0.693792
Species CO2  0.720209
Species HCO  0.00321461
Species CH2O  0.0817911
Species CH3O  0.0360026
Species N2  0


Interactions with species H  with QSS Criteria 0.0752034
HO2:2  CH3:1  CH2O:2  CH3O:1  N2:1  
Interactions with species O  with QSS Criteria 0.0211171
OH:1  HO2:1  CH3:1  CH2O:1  CH3O:1  
Interactions with species OH  with QSS Criteria 0.019287
O:1  OH:2  HO2:1  CH3:2  HCO:2  CH2O:1  CH3O:1  
Interactions with species HO2  with QSS Criteria 0.0113201
H:2  O:1  OH:1  CH3:1  CH2O:1  N2:1  
Interactions with species CH3  with QSS Criteria 0.107792
H:1  O:1  OH:2  HO2:1  
Interactions with species HCO  with QSS Criteria 0.00321461
OH:2  
Interactions with species CH2O  with QSS Criteria 0.0817911
H:2  O:1  OH:1  HO2:1  
Interactions with species CH3O  with QSS Criteria 0.0360026
H:1  O:1  OH:1  
Interactions with species N2  with QSS Criteria 0
H:1  HO2:1  


We choose to put the species CH3O and HCO in QSS hypothesis due to their low QSS coefficient. The species HO2 could have been a good candidate too but it is linked to himself (non linearity).

In order to obtain the trajectories of the 14-species 26-reaction reduced scheme with these 2 species in QSS hypothesis, we run the getQSSfile step and we obtain the following graphs.We observe that the final state and the shape of the trajectories are conserved. It is under these conditions that the optimisation step will be efficient.

We can note that the main target profiles are not impacted by the QSS hypothesis, nevertheless the fitness seems better. This is due to errors compensations by the other species not shown here (remind that the fitness is calculated for all species, velocity and temperature, the target just have a larger impact coefficient on the fitness).

QSS 12sp Premixed.png

Fig3 : Comparison between the reference trajectories of the target species, the temperature and the flame speed (in black), and the trajectories computed with the reduced mechanism with 12 transported species and 26 reactions after a DRGEp reaction reduction (in red).

Optimisation

The final step of the ORCh method, the genetic algorithm, enables to recover the trajectories of the target species. Firstly, we allowed a 10 % variation on the pre exponential factor, the temperature exposant and 6 % on the energy activation in order to find their optimal values (i.e., AllowedVariation_A = 0.10; AllowedVariation_b = 0.10; AllowedVariation_E = 0.06).

A population of 40 elements was used during 50 generations. The optimisation step supports running in parallel. For example, we can use 20 processors via mpirun -np 20 mainprogram. Just make sure that PopSize divided by the number of processes is an integer. This step may take a long time, like several hours, depending on how many processors are used. The optimised scheme is in analytic_schemes/Ref/ while the corresponding EPS figures can be found in analytic_schemes/PLOTS/.


The following trajectories of the temperature, the flame speed and the target species match perfectly the ones of the reference detailed scheme with only 12 transported species and 26 reactions.

Optim PremixGRI12.png

Fig4 : Comparison between the reference trajectories of the target species, the temperature and the flame speed (in black), and the trajectories computed with the reduced mechanism with 12 transported species and 26 reactions after optimisation (in red).

Bibliography