[Test] Move "negATest" to GTest suite

This commit is contained in:
Ray Speth
2015-06-16 15:01:15 -04:00
parent 60827267b7
commit e34b2739b2
9 changed files with 312 additions and 983 deletions

61
test/data/noxNeg.cti Normal file
View File

@@ -0,0 +1,61 @@
units(length = "cm", time = "s", quantity = "mol", act_energy = "cal/mol")
ideal_gas(name = "air",
elements = " O H N Ar ",
species = """ gri30: O O2 N NO NO2 N2O N2 NH H H2O NH2 AR """,
reactions = "all",
transport = "Mix",
initial_state = state(temperature = 900.0,
pressure = OneAtm, mole_fractions = 'O2:0.21, N2:0.78, AR:0.01') )
#-------------------------------------------------------------------------------
# Reeaction 77
# 10.5, 9 (a)
# Miller & Melius, 24th Symp. on Comb., 1992.
reaction( "NH + NO <=> N2O + H", [2.94000E+14, -0.4, 0],
options = ["duplicate"])
# Reaction 78
reaction( "NH + NO <=> N2O + H", [-2.16000E+13, -0.23, 0],
options = ["negative_A", "duplicate"])
# Second Reaction:
# Reaction 90
# 10.6, 9 (b)
# Glarborg et al., Int. J. Chem. Kinet., 26, 421, 1994.
reaction( "NH2 + NO <=> N2 + H2O", [1.30000E+16, -1.25, 0],
options = ["duplicate"])
# Reaction 91
reaction( "NH2 + NO <=> N2 + H2O", [-2.80000E+13, -0.55, 0],
options = ["negative_A", "duplicate"])
#-------------------------------------------------------------------------------
# Reaction 1
three_body_reaction( "2 O + M <=> O2 + M", [1.20000E+17, -1, 0],
efficiencies = " AR:0.83 ")
# Reaction 2
reaction( "N + NO <=> N2 + O", [2.70000E+13, 0, 355])
# Reaction 3
reaction( "N + O2 <=> NO + O", [9.00000E+09, 1, 6500])
# Reaction 4
reaction( "N2O + O <=> N2 + O2", [1.40000E+12, 0, 10810])
# Reaction 5
reaction( "N2O + O <=> 2 NO", [2.90000E+13, 0, 23150])
# Reaction 6
falloff_reaction( "N2O (+ M) <=> N2 + O (+ M)",
kf = [7.91000E+10, 0, 56020],
kf0 = [6.37000E+14, 0, 56640],
efficiencies = " AR:0.625 ")
# Reaction 7
three_body_reaction( "NO + O + M <=> NO2 + M", [1.06000E+20, -1.41, 0],
efficiencies = " AR:0.7 ")
# Reaction 8
reaction( "NO2 + O <=> NO + O2", [3.90000E+12, 0, -240])

199
test/data/noxNeg.xml Normal file
View File

@@ -0,0 +1,199 @@
<?xml version="1.0"?>
<ctml>
<validate reactions="yes" species="yes"/>
<!-- phase air -->
<phase dim="3" id="air">
<elementArray datasrc="elements.xml">O H N Ar </elementArray>
<speciesArray datasrc="gri30.xml#species_data">O O2 N NO NO2 N2O N2 NH H H2O NH2 AR </speciesArray>
<reactionArray datasrc="#reaction_data"/>
<state>
<temperature units="K">900.0</temperature>
<pressure units="Pa">101325.0</pressure>
<moleFractions>O2:0.21, N2:0.78, AR:0.01</moleFractions>
</state>
<thermo model="IdealGas"/>
<kinetics model="GasKinetics"/>
<transport model="Mix"/>
</phase>
<reactionData id="reaction_data">
<!-- reaction 0001 -->
<reaction duplicate="yes" reversible="yes" id="0001">
<equation>NH + NO [=] N2O + H</equation>
<rateCoeff>
<Arrhenius>
<A>2.940000E+11</A>
<b>-0.40000000000000002</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NH:1.0 NO:1</reactants>
<products>H:1 N2O:1.0</products>
</reaction>
<!-- reaction 0002 -->
<reaction duplicate="yes" reversible="yes" negative_A="yes" id="0002">
<equation>NH + NO [=] N2O + H</equation>
<rateCoeff>
<Arrhenius>
<A>-2.160000E+10</A>
<b>-0.23000000000000001</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NH:1.0 NO:1</reactants>
<products>H:1 N2O:1.0</products>
</reaction>
<!-- reaction 0003 -->
<reaction duplicate="yes" reversible="yes" id="0003">
<equation>NH2 + NO [=] N2 + H2O</equation>
<rateCoeff>
<Arrhenius>
<A>1.300000E+13</A>
<b>-1.25</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NO:1 NH2:1.0</reactants>
<products>N2:1.0 H2O:1</products>
</reaction>
<!-- reaction 0004 -->
<reaction duplicate="yes" reversible="yes" negative_A="yes" id="0004">
<equation>NH2 + NO [=] N2 + H2O</equation>
<rateCoeff>
<Arrhenius>
<A>-2.800000E+10</A>
<b>-0.55000000000000004</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NO:1 NH2:1.0</reactants>
<products>N2:1.0 H2O:1</products>
</reaction>
<!-- reaction 0005 -->
<reaction reversible="yes" type="threeBody" id="0005">
<equation>2 O + M [=] O2 + M</equation>
<rateCoeff>
<Arrhenius>
<A>1.200000E+11</A>
<b>-1</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
<efficiencies default="1.0">AR:0.83 </efficiencies>
</rateCoeff>
<reactants>O:2.0</reactants>
<products>O2:1.0</products>
</reaction>
<!-- reaction 0006 -->
<reaction reversible="yes" id="0006">
<equation>N + NO [=] N2 + O</equation>
<rateCoeff>
<Arrhenius>
<A>2.700000E+10</A>
<b>0</b>
<E units="cal/mol">355.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NO:1 N:1.0</reactants>
<products>N2:1.0 O:1</products>
</reaction>
<!-- reaction 0007 -->
<reaction reversible="yes" id="0007">
<equation>N + O2 [=] NO + O</equation>
<rateCoeff>
<Arrhenius>
<A>9.000000E+06</A>
<b>1</b>
<E units="cal/mol">6500.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>O2:1 N:1.0</reactants>
<products>O:1 NO:1.0</products>
</reaction>
<!-- reaction 0008 -->
<reaction reversible="yes" id="0008">
<equation>N2O + O [=] N2 + O2</equation>
<rateCoeff>
<Arrhenius>
<A>1.400000E+09</A>
<b>0</b>
<E units="cal/mol">10810.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>N2O:1.0 O:1</reactants>
<products>N2:1.0 O2:1</products>
</reaction>
<!-- reaction 0009 -->
<reaction reversible="yes" id="0009">
<equation>N2O + O [=] 2 NO</equation>
<rateCoeff>
<Arrhenius>
<A>2.900000E+10</A>
<b>0</b>
<E units="cal/mol">23150.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>N2O:1.0 O:1</reactants>
<products>NO:2.0</products>
</reaction>
<!-- reaction 0010 -->
<reaction reversible="yes" type="falloff" id="0010">
<equation>N2O (+ M) [=] N2 + O (+ M)</equation>
<rateCoeff>
<Arrhenius>
<A>7.910000E+10</A>
<b>0</b>
<E units="cal/mol">56020.000000</E>
</Arrhenius>
<Arrhenius name="k0">
<A>6.370000E+11</A>
<b>0</b>
<E units="cal/mol">56640.000000</E>
</Arrhenius>
<efficiencies default="1.0">AR:0.625 </efficiencies>
<falloff type="Lindemann"/>
</rateCoeff>
<reactants>N2O:1.0</reactants>
<products>N2:1.0 O:1</products>
</reaction>
<!-- reaction 0011 -->
<reaction reversible="yes" type="threeBody" id="0011">
<equation>NO + O + M [=] NO2 + M</equation>
<rateCoeff>
<Arrhenius>
<A>1.060000E+14</A>
<b>-1.4099999999999999</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
<efficiencies default="1.0">AR:0.7 </efficiencies>
</rateCoeff>
<reactants>O:1 NO:1.0</reactants>
<products>NO2:1.0</products>
</reaction>
<!-- reaction 0012 -->
<reaction reversible="yes" id="0012">
<equation>NO2 + O [=] NO + O2</equation>
<rateCoeff>
<Arrhenius>
<A>3.900000E+09</A>
<b>0</b>
<E units="cal/mol">-240.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>O:1 NO2:1.0</reactants>
<products>O2:1 NO:1.0</products>
</reaction>
</reactionData>
</ctml>

View File

@@ -144,6 +144,58 @@ TEST_F(FracCoeffTest, EquilibriumConstants)
EXPECT_NEAR(exp(-deltaG0_1/RT) * pow(pRef/RT, -0.5), Kc[1], 1e-13 * Kc[1]);
}
class NegativePreexponentialFactor : public testing::Test
{
public:
NegativePreexponentialFactor() {}
void setup(const std::string& infile) {
therm.reset(newPhase(infile));
std::vector<ThermoPhase*> phases;
phases.push_back(therm.get());
importKinetics(therm->xml(), phases, &kin);
therm->setState_TPX(2000, OneAtm,
"H2O:1.0, H:0.2, O2:0.3, NH:0.05, NO:0.05, N2O:0.05");
}
void testNetProductionRates() {
const double wdot_ref[] = {0.44705, -0.0021443, 0, -279.36, 0.0021432, 278.92, 0.4449, -279.36, 279.36, 0, 0, 0};
ASSERT_EQ(12, (int) therm->nSpecies());
ASSERT_EQ(12, (int) kin.nReactions());
vector_fp wdot(therm->nSpecies());
kin.getNetProductionRates(&wdot[0]);
for (size_t i = 0; i < therm->nSpecies(); i++) {
EXPECT_NEAR(wdot_ref[i], wdot[i], std::abs(wdot_ref[i])*2e-5 + 1e-9);
}
const double ropf_ref[] = {479.305, -128.202, 0, -0, 0, 0, 0, 0, 0, 0.4449, 0, 0};
const double ropr_ref[] = {97.94, -26.1964, 0, -0, 1.10334e-06, 0, 0, 0, 6.58592e-06, 0, 0, 0.00214319};
vector_fp ropf(kin.nReactions());
vector_fp ropr(kin.nReactions());
kin.getFwdRatesOfProgress(&ropf[0]);
kin.getRevRatesOfProgress(&ropr[0]);
for (size_t i = 0; i < kin.nReactions(); i++) {
EXPECT_NEAR(ropf_ref[i], ropf[i], std::abs(ropf_ref[i])*2e-5 + 1e-9);
EXPECT_NEAR(ropr_ref[i], ropr[i], std::abs(ropr_ref[i])*2e-5 + 1e-9);
}
}
shared_ptr<ThermoPhase> therm;
GasKinetics kin;
};
TEST_F(NegativePreexponentialFactor, fromCti)
{
setup("../data/noxNeg.cti");
testNetProductionRates();
}
TEST_F(NegativePreexponentialFactor, fromXml)
{
setup("../data/noxNeg.xml");
testNetProductionRates();
}
TEST(InterfaceReaction, CoverageDependency) {
IdealGasPhase gas("ptcombust.cti", "gas");
SurfPhase surf("ptcombust.cti", "Pt_surf");

View File

@@ -257,16 +257,6 @@ CompileAndTest('mixGasTransport',
CompileAndTest('multiGasTransport',
'multiGasTransport', 'multiGasTransport', 'output_blessed.txt')
negA = localenv.Program('negATest/negATest',
mglob(env, 'negATest', 'cpp'),
LIBS=cantera_libs)
negA_name = negA[0].name
Test('negA-xml', 'negATest', negA, 'negATest_blessed.out',
options='noxNeg_blessed.xml', artifacts=negA_name)
if haveConverters:
Test('negA-cti', 'negATest', negA, 'negATest_blessed.out',
options='noxNeg.cti', artifacts=negA_name)
CompileAndTest('pureFluid', 'pureFluidTest', 'testPureWater', 'output_blessed.txt')
if haveConverters:
CompileAndTest('rankine_democxx', 'rankine_democxx', 'rankine', 'output_blessed.txt')

View File

@@ -1,96 +0,0 @@
#include "cantera/kinetics.h"
#include <cstdio>
using namespace Cantera;
using namespace std;
int main(int argc, char** argv)
{
#ifdef _MSC_VER
_set_output_format(_TWO_DIGIT_EXPONENT);
#endif
try {
if (argc != 2) {
cout << "Error: no input file specified.\n"
"Choose either 'noxNeg.cti' or 'noxNeg_blessed.xml" << endl;
exit(-1);
}
std::string infile(argv[1]);
size_t i;
double x[20];
double cdot[20], ddot[20];
XML_Node* xc = get_XML_File(infile);
XML_Node* const xg = xc->findNameID("phase", "air");
ThermoPhase* gasTP = newPhase(*xg);
size_t nsp = gasTP->nSpecies();
cout << "Number of species = " << nsp << endl;
vector<ThermoPhase*> phaseList;
phaseList.push_back(gasTP);
GasKinetics* iKin_ptr = new GasKinetics();
importKinetics(*xg, phaseList, iKin_ptr);
size_t nr = iKin_ptr->nReactions();
cout << "Number of reactions = " << nr << endl;
size_t iH = gasTP->speciesIndex("H");
size_t iO2 = gasTP->speciesIndex("O2");
size_t iH2O = gasTP->speciesIndex("H2O");
size_t iNH = gasTP->speciesIndex("NH");
size_t iNO = gasTP->speciesIndex("NO");
size_t iN2O = gasTP->speciesIndex("N2O");
for (i = 0; i < nsp; i++) {
x[i] = 0.0;
}
x[iH2O] = 1.0 /2.0;
x[iH] = 0.2 /2.0;
x[iO2] = 0.3 /2.0;
x[iNH] = 0.05/2.0;
x[iNO] = 0.05/2.0;
x[iN2O] = 0.05/2.0;
double p = OneAtm;
gasTP->setState_TPX(2000., p, x);
double src[20];
for (i = 0; i < 20; i++) {
src[i] = 0.0;
}
iKin_ptr->getNetProductionRates(src);
for (i = 0; i < nsp; i++) {
string sSt = gasTP->speciesName(i);
printf("rop [ %.4d:%s ] = %.5g \n", (int) i, sSt.c_str(), src[i]);
}
size_t nReactions = iKin_ptr->nReactions();
cout << "number of reactions = " << nReactions << endl;
double fwd_rop[20];
double rev_rop[20];
iKin_ptr->getFwdRatesOfProgress(fwd_rop);
iKin_ptr->getRevRatesOfProgress(rev_rop);
for (i = 0; i < nReactions; i++) {
printf("fwd_rop[%3d] = %13g rev_rop[%3d] = %13g\n", (int) i,
fwd_rop[i], (int) i, rev_rop[i]);
}
iKin_ptr->getCreationRates(cdot);
iKin_ptr->getDestructionRates(ddot);
return 0;
} catch (CanteraError& err) {
std::cerr << err.what() << std::endl;
cerr << "program terminating." << endl;
return -1;
}
}

View File

@@ -1,27 +0,0 @@
Number of species = 12
Number of reactions = 12
rop [ 0:O ] = 0.447052
rop [ 1:O2 ] = -0.0021443
rop [ 2:N ] = 0
rop [ 3:NO ] = -279.361
rop [ 4:NO2 ] = 0.00214319
rop [ 5:N2O ] = 278.914
rop [ 6:N2 ] = 0.444906
rop [ 7:NH ] = -279.359
rop [ 8:H ] = 279.359
rop [ 9:H2O ] = 0
rop [ 10:NH2 ] = 0
rop [ 11:AR ] = 0
number of reactions = 12
fwd_rop[ 0] = 479.304 rev_rop[ 0] = 97.94
fwd_rop[ 1] = -128.201 rev_rop[ 1] = -26.1964
fwd_rop[ 2] = 0 rev_rop[ 2] = 0
fwd_rop[ 3] = -0 rev_rop[ 3] = -0
fwd_rop[ 4] = 0 rev_rop[ 4] = 1.10334e-06
fwd_rop[ 5] = 0 rev_rop[ 5] = 0
fwd_rop[ 6] = 0 rev_rop[ 6] = 0
fwd_rop[ 7] = 0 rev_rop[ 7] = 0
fwd_rop[ 8] = 0 rev_rop[ 8] = 6.58592e-06
fwd_rop[ 9] = 0.444906 rev_rop[ 9] = 0
fwd_rop[ 10] = 0 rev_rop[ 10] = 0
fwd_rop[ 11] = 0 rev_rop[ 11] = 0.00214319

View File

@@ -1,300 +0,0 @@
#
# Generated from file air.inp
# by ck2cti on Mon Aug 25 09:52:58 2003
#
# Transport data from file ../transport/gri30_tran.dat.
units(length = "cm", time = "s", quantity = "mol", act_energy = "cal/mol")
ideal_gas(name = "air",
elements = " O H N Ar ",
species = """ O O2 N NO NO2 N2O N2 NH H H2O NH2 AR """,
reactions = "all",
transport = "Mix",
initial_state = state(temperature = 900.0,
pressure = OneAtm, mole_fractions = 'O2:0.21, N2:0.78, AR:0.01') )
#-------------------------------------------------------------------------------
# Species data
#-------------------------------------------------------------------------------
species(name = "O",
atoms = " O:1 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 3.168267100E+00, -3.279318840E-03,
6.643063960E-06, -6.128066240E-09, 2.112659710E-12,
2.912225920E+04, 2.051933460E+00] ),
NASA( [ 1000.00, 3500.00], [ 2.569420780E+00, -8.597411370E-05,
4.194845890E-08, -1.001777990E-11, 1.228336910E-15,
2.921757910E+04, 4.784338640E+00] )
),
transport = gas_transport(
geom = "atom",
diam = 2.75,
well_depth = 80.00),
note = "L 1/90"
)
species(name = "O2",
atoms = " O:2 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 3.782456360E+00, -2.996734160E-03,
9.847302010E-06, -9.681295090E-09, 3.243728370E-12,
-1.063943560E+03, 3.657675730E+00] ),
NASA( [ 1000.00, 3500.00], [ 3.282537840E+00, 1.483087540E-03,
-7.579666690E-07, 2.094705550E-10, -2.167177940E-14,
-1.088457720E+03, 5.453231290E+00] )
),
transport = gas_transport(
geom = "linear",
diam = 3.46,
well_depth = 107.40,
polar = 1.60,
rot_relax = 3.80),
note = "TPIS89"
)
species(name = "N",
atoms = " N:1 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 2.500000000E+00, 0.000000000E+00,
0.000000000E+00, 0.000000000E+00, 0.000000000E+00,
5.610463700E+04, 4.193908700E+00] ),
NASA( [ 1000.00, 6000.00], [ 2.415942900E+00, 1.748906500E-04,
-1.190236900E-07, 3.022624500E-11, -2.036098200E-15,
5.613377300E+04, 4.649609600E+00] )
),
transport = gas_transport(
geom = "atom",
diam = 3.30,
well_depth = 71.40),
note = "L 6/88"
)
species(name = "NO",
atoms = " N:1 O:1 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 4.218476300E+00, -4.638976000E-03,
1.104102200E-05, -9.336135400E-09, 2.803577000E-12,
9.844623000E+03, 2.280846400E+00] ),
NASA( [ 1000.00, 6000.00], [ 3.260605600E+00, 1.191104300E-03,
-4.291704800E-07, 6.945766900E-11, -4.033609900E-15,
9.920974600E+03, 6.369302700E+00] )
),
transport = gas_transport(
geom = "linear",
diam = 3.62,
well_depth = 97.53,
polar = 1.76,
rot_relax = 4.00),
note = "RUS 78"
)
species(name = "NO2",
atoms = " N:1 O:2 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 3.944031200E+00, -1.585429000E-03,
1.665781200E-05, -2.047542600E-08, 7.835056400E-12,
2.896617900E+03, 6.311991700E+00] ),
NASA( [ 1000.00, 6000.00], [ 4.884754200E+00, 2.172395600E-03,
-8.280690600E-07, 1.574751000E-10, -1.051089500E-14,
2.316498300E+03, -1.174169500E-01] )
),
transport = gas_transport(
geom = "nonlinear",
diam = 3.50,
well_depth = 200.00,
rot_relax = 1.00),
note = "L 7/88"
)
species(name = "N2O",
atoms = " N:2 O:1 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 2.257150200E+00, 1.130472800E-02,
-1.367131900E-05, 9.681980600E-09, -2.930718200E-12,
8.741774400E+03, 1.075799200E+01] ),
NASA( [ 1000.00, 6000.00], [ 4.823072900E+00, 2.627025100E-03,
-9.585087400E-07, 1.600071200E-10, -9.775230300E-15,
8.073404800E+03, -2.201720700E+00] )
),
transport = gas_transport(
geom = "linear",
diam = 3.83,
well_depth = 232.40,
rot_relax = 1.00),
note = "L 7/88"
)
species(name = "N2",
atoms = " N:2 ",
thermo = (
NASA( [ 300.00, 1000.00], [ 3.298677000E+00, 1.408240400E-03,
-3.963222000E-06, 5.641515000E-09, -2.444854000E-12,
-1.020899900E+03, 3.950372000E+00] ),
NASA( [ 1000.00, 5000.00], [ 2.926640000E+00, 1.487976800E-03,
-5.684760000E-07, 1.009703800E-10, -6.753351000E-15,
-9.227977000E+02, 5.980528000E+00] )
),
transport = gas_transport(
geom = "linear",
diam = 3.62,
well_depth = 97.53,
polar = 1.76,
rot_relax = 4.00),
note = "121286"
)
species(name = "NH",
atoms = " N:1 H:1 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 3.492908500E+00, 3.117919800E-04,
-1.489048400E-06, 2.481644200E-09, -1.035696700E-12,
4.188062900E+04, 1.848327800E+00] ),
NASA( [ 1000.00, 6000.00], [ 2.783692800E+00, 1.329843000E-03,
-4.247804700E-07, 7.834850100E-11, -5.504447000E-15,
4.212084800E+04, 5.740779900E+00] )
),
transport = gas_transport(
geom = "linear",
diam = 2.65,
well_depth = 80.00,
rot_relax = 4.00),
note = "And94: Obtained from grimech"
)
species(name = "H",
atoms = " H:1 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 2.500000000E+00, 7.053328190E-13,
-1.995919640E-15, 2.300816320E-18, -9.277323320E-22,
2.547365990E+04, -4.466828530E-01] ),
NASA( [ 1000.00, 3500.00], [ 2.500000010E+00, -2.308429730E-11,
1.615619480E-14, -4.735152350E-18, 4.981973570E-22,
2.547365990E+04, -4.466829140E-01] )
),
transport = gas_transport(
geom = "atom",
diam = 2.05,
well_depth = 145.00),
note = "L 7/88"
)
species(name = "H2O",
atoms = " H:2 O:1 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 4.198640560E+00, -2.036434100E-03,
6.520402110E-06, -5.487970620E-09, 1.771978170E-12,
-3.029372670E+04, -8.490322080E-01] ),
NASA( [ 1000.00, 3500.00], [ 3.033992490E+00, 2.176918040E-03,
-1.640725180E-07, -9.704198700E-11, 1.682009920E-14,
-3.000429710E+04, 4.966770100E+00] )
),
transport = gas_transport(
geom = "nonlinear",
diam = 2.60,
well_depth = 572.40,
dipole = 1.84,
rot_relax = 4.00),
note = "L 8/89"
)
species(name = "NH2",
atoms = " N:1 H:2 ",
thermo = (
NASA( [ 200.00, 1000.00], [ 4.204002900E+00, -2.106138500E-03,
7.106834800E-06, -5.611519700E-09, 1.644071700E-12,
2.188591000E+04, -1.418424800E-01] ),
NASA( [ 1000.00, 6000.00], [ 2.834742100E+00, 3.207308200E-03,
-9.339080400E-07, 1.370295300E-10, -7.920614400E-15,
2.217195700E+04, 6.520416300E+00] )
),
transport = gas_transport(
geom = "nonlinear",
diam = 2.65,
well_depth = 80.00,
polar = 2.26,
rot_relax = 4.00),
note = "And89"
)
species(name = "AR",
atoms = " Ar:1 ",
thermo = (
NASA( [ 300.00, 1000.00], [ 2.500000000E+00, 0.000000000E+00,
0.000000000E+00, 0.000000000E+00, 0.000000000E+00,
-7.453750000E+02, 4.366000000E+00] ),
NASA( [ 1000.00, 5000.00], [ 2.500000000E+00, 0.000000000E+00,
0.000000000E+00, 0.000000000E+00, 0.000000000E+00,
-7.453750000E+02, 4.366000000E+00] )
),
transport = gas_transport(
geom = "atom",
diam = 3.33,
well_depth = 136.50),
note = "120186"
)
#-------------------------------------------------------------------------------
# Reeaction 77
# 10.5, 9 (a)
# Miller & Melius, 24th Symp. on Comb., 1992.
reaction( "NH + NO <=> N2O + H", [2.94000E+14, -0.4, 0],
options = ["duplicate"])
# Reaction 78
reaction( "NH + NO <=> N2O + H", [-2.16000E+13, -0.23, 0],
options = ["negative_A", "duplicate"])
# Second Reaction:
# Reaction 90
# 10.6, 9 (b)
# Glarborg et al., Int. J. Chem. Kinet., 26, 421, 1994.
reaction( "NH2 + NO <=> N2 + H2O", [1.30000E+16, -1.25, 0],
options = ["duplicate"])
# Reaction 91
reaction( "NH2 + NO <=> N2 + H2O", [-2.80000E+13, -0.55, 0],
options = ["negative_A", "duplicate"])
#-------------------------------------------------------------------------------
# Reaction 1
three_body_reaction( "2 O + M <=> O2 + M", [1.20000E+17, -1, 0],
efficiencies = " AR:0.83 ")
# Reaction 2
reaction( "N + NO <=> N2 + O", [2.70000E+13, 0, 355])
# Reaction 3
reaction( "N + O2 <=> NO + O", [9.00000E+09, 1, 6500])
# Reaction 4
reaction( "N2O + O <=> N2 + O2", [1.40000E+12, 0, 10810])
# Reaction 5
reaction( "N2O + O <=> 2 NO", [2.90000E+13, 0, 23150])
# Reaction 6
falloff_reaction( "N2O (+ M) <=> N2 + O (+ M)",
kf = [7.91000E+10, 0, 56020],
kf0 = [6.37000E+14, 0, 56640],
efficiencies = " AR:0.625 ")
# Reaction 7
three_body_reaction( "NO + O + M <=> NO2 + M", [1.06000E+20, -1.41, 0],
efficiencies = " AR:0.7 ")
# Reaction 8
reaction( "NO2 + O <=> NO + O2", [3.90000E+12, 0, -240])

View File

@@ -1,514 +0,0 @@
<?xml version="1.0"?>
<ctml>
<validate reactions="yes" species="yes"/>
<!-- phase air -->
<phase dim="3" id="air">
<elementArray datasrc="elements.xml">O H N Ar </elementArray>
<speciesArray datasrc="#species_data">O O2 N NO NO2 N2O N2 NH H H2O NH2 AR </speciesArray>
<reactionArray datasrc="#reaction_data"/>
<state>
<temperature units="K">900.0</temperature>
<pressure units="Pa">101325.0</pressure>
<moleFractions>O2:0.21, N2:0.78, AR:0.01</moleFractions>
</state>
<thermo model="IdealGas"/>
<kinetics model="GasKinetics"/>
<transport model="Mix"/>
</phase>
<!-- species definitions -->
<speciesData id="species_data">
<!-- species O -->
<species name="O">
<atomArray>O:1 </atomArray>
<note>L 1/90</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
3.168267100E+00, -3.279318840E-03, 6.643063960E-06, -6.128066240E-09,
2.112659710E-12, 2.912225920E+04, 2.051933460E+00</floatArray>
</NASA>
<NASA Tmax="3500.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.569420780E+00, -8.597411370E-05, 4.194845890E-08, -1.001777990E-11,
1.228336910E-15, 2.921757910E+04, 4.784338640E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">atom</string>
<LJ_welldepth units="K">80.000</LJ_welldepth>
<LJ_diameter units="A">2.750</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">0.000</polarizability>
<rotRelax>0.000</rotRelax>
</transport>
</species>
<!-- species O2 -->
<species name="O2">
<atomArray>O:2 </atomArray>
<note>TPIS89</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
3.782456360E+00, -2.996734160E-03, 9.847302010E-06, -9.681295090E-09,
3.243728370E-12, -1.063943560E+03, 3.657675730E+00</floatArray>
</NASA>
<NASA Tmax="3500.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
3.282537840E+00, 1.483087540E-03, -7.579666690E-07, 2.094705550E-10,
-2.167177940E-14, -1.088457720E+03, 5.453231290E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">linear</string>
<LJ_welldepth units="K">107.400</LJ_welldepth>
<LJ_diameter units="A">3.460</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">1.600</polarizability>
<rotRelax>3.800</rotRelax>
</transport>
</species>
<!-- species N -->
<species name="N">
<atomArray>N:1 </atomArray>
<note>L 6/88</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.500000000E+00, 0.000000000E+00, 0.000000000E+00, 0.000000000E+00,
0.000000000E+00, 5.610463700E+04, 4.193908700E+00</floatArray>
</NASA>
<NASA Tmax="6000.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.415942900E+00, 1.748906500E-04, -1.190236900E-07, 3.022624500E-11,
-2.036098200E-15, 5.613377300E+04, 4.649609600E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">atom</string>
<LJ_welldepth units="K">71.400</LJ_welldepth>
<LJ_diameter units="A">3.300</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">0.000</polarizability>
<rotRelax>0.000</rotRelax>
</transport>
</species>
<!-- species NO -->
<species name="NO">
<atomArray>O:1 N:1 </atomArray>
<note>RUS 78</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
4.218476300E+00, -4.638976000E-03, 1.104102200E-05, -9.336135400E-09,
2.803577000E-12, 9.844623000E+03, 2.280846400E+00</floatArray>
</NASA>
<NASA Tmax="6000.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
3.260605600E+00, 1.191104300E-03, -4.291704800E-07, 6.945766900E-11,
-4.033609900E-15, 9.920974600E+03, 6.369302700E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">linear</string>
<LJ_welldepth units="K">97.530</LJ_welldepth>
<LJ_diameter units="A">3.620</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">1.760</polarizability>
<rotRelax>4.000</rotRelax>
</transport>
</species>
<!-- species NO2 -->
<species name="NO2">
<atomArray>O:2 N:1 </atomArray>
<note>L 7/88</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
3.944031200E+00, -1.585429000E-03, 1.665781200E-05, -2.047542600E-08,
7.835056400E-12, 2.896617900E+03, 6.311991700E+00</floatArray>
</NASA>
<NASA Tmax="6000.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
4.884754200E+00, 2.172395600E-03, -8.280690600E-07, 1.574751000E-10,
-1.051089500E-14, 2.316498300E+03, -1.174169500E-01</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">nonlinear</string>
<LJ_welldepth units="K">200.000</LJ_welldepth>
<LJ_diameter units="A">3.500</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">0.000</polarizability>
<rotRelax>1.000</rotRelax>
</transport>
</species>
<!-- species N2O -->
<species name="N2O">
<atomArray>O:1 N:2 </atomArray>
<note>L 7/88</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.257150200E+00, 1.130472800E-02, -1.367131900E-05, 9.681980600E-09,
-2.930718200E-12, 8.741774400E+03, 1.075799200E+01</floatArray>
</NASA>
<NASA Tmax="6000.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
4.823072900E+00, 2.627025100E-03, -9.585087400E-07, 1.600071200E-10,
-9.775230300E-15, 8.073404800E+03, -2.201720700E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">linear</string>
<LJ_welldepth units="K">232.400</LJ_welldepth>
<LJ_diameter units="A">3.830</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">0.000</polarizability>
<rotRelax>1.000</rotRelax>
</transport>
</species>
<!-- species N2 -->
<species name="N2">
<atomArray>N:2 </atomArray>
<note>121286</note>
<thermo>
<NASA Tmax="1000.0" Tmin="300.0" P0="100000.0">
<floatArray name="coeffs" size="7">
3.298677000E+00, 1.408240400E-03, -3.963222000E-06, 5.641515000E-09,
-2.444854000E-12, -1.020899900E+03, 3.950372000E+00</floatArray>
</NASA>
<NASA Tmax="5000.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.926640000E+00, 1.487976800E-03, -5.684760000E-07, 1.009703800E-10,
-6.753351000E-15, -9.227977000E+02, 5.980528000E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">linear</string>
<LJ_welldepth units="K">97.530</LJ_welldepth>
<LJ_diameter units="A">3.620</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">1.760</polarizability>
<rotRelax>4.000</rotRelax>
</transport>
</species>
<!-- species NH -->
<species name="NH">
<atomArray>H:1 N:1 </atomArray>
<note>And94: Obtained from grimech</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
3.492908500E+00, 3.117919800E-04, -1.489048400E-06, 2.481644200E-09,
-1.035696700E-12, 4.188062900E+04, 1.848327800E+00</floatArray>
</NASA>
<NASA Tmax="6000.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.783692800E+00, 1.329843000E-03, -4.247804700E-07, 7.834850100E-11,
-5.504447000E-15, 4.212084800E+04, 5.740779900E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">linear</string>
<LJ_welldepth units="K">80.000</LJ_welldepth>
<LJ_diameter units="A">2.650</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">0.000</polarizability>
<rotRelax>4.000</rotRelax>
</transport>
</species>
<!-- species H -->
<species name="H">
<atomArray>H:1 </atomArray>
<note>L 7/88</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.500000000E+00, 7.053328190E-13, -1.995919640E-15, 2.300816320E-18,
-9.277323320E-22, 2.547365990E+04, -4.466828530E-01</floatArray>
</NASA>
<NASA Tmax="3500.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.500000010E+00, -2.308429730E-11, 1.615619480E-14, -4.735152350E-18,
4.981973570E-22, 2.547365990E+04, -4.466829140E-01</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">atom</string>
<LJ_welldepth units="K">145.000</LJ_welldepth>
<LJ_diameter units="A">2.050</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">0.000</polarizability>
<rotRelax>0.000</rotRelax>
</transport>
</species>
<!-- species H2O -->
<species name="H2O">
<atomArray>H:2 O:1 </atomArray>
<note>L 8/89</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
4.198640560E+00, -2.036434100E-03, 6.520402110E-06, -5.487970620E-09,
1.771978170E-12, -3.029372670E+04, -8.490322080E-01</floatArray>
</NASA>
<NASA Tmax="3500.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
3.033992490E+00, 2.176918040E-03, -1.640725180E-07, -9.704198700E-11,
1.682009920E-14, -3.000429710E+04, 4.966770100E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">nonlinear</string>
<LJ_welldepth units="K">572.400</LJ_welldepth>
<LJ_diameter units="A">2.600</LJ_diameter>
<dipoleMoment units="Debye">1.840</dipoleMoment>
<polarizability units="A3">0.000</polarizability>
<rotRelax>4.000</rotRelax>
</transport>
</species>
<!-- species NH2 -->
<species name="NH2">
<atomArray>H:2 N:1 </atomArray>
<note>And89</note>
<thermo>
<NASA Tmax="1000.0" Tmin="200.0" P0="100000.0">
<floatArray name="coeffs" size="7">
4.204002900E+00, -2.106138500E-03, 7.106834800E-06, -5.611519700E-09,
1.644071700E-12, 2.188591000E+04, -1.418424800E-01</floatArray>
</NASA>
<NASA Tmax="6000.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.834742100E+00, 3.207308200E-03, -9.339080400E-07, 1.370295300E-10,
-7.920614400E-15, 2.217195700E+04, 6.520416300E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">nonlinear</string>
<LJ_welldepth units="K">80.000</LJ_welldepth>
<LJ_diameter units="A">2.650</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">2.260</polarizability>
<rotRelax>4.000</rotRelax>
</transport>
</species>
<!-- species AR -->
<species name="AR">
<atomArray>Ar:1 </atomArray>
<note>120186</note>
<thermo>
<NASA Tmax="1000.0" Tmin="300.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.500000000E+00, 0.000000000E+00, 0.000000000E+00, 0.000000000E+00,
0.000000000E+00, -7.453750000E+02, 4.366000000E+00</floatArray>
</NASA>
<NASA Tmax="5000.0" Tmin="1000.0" P0="100000.0">
<floatArray name="coeffs" size="7">
2.500000000E+00, 0.000000000E+00, 0.000000000E+00, 0.000000000E+00,
0.000000000E+00, -7.453750000E+02, 4.366000000E+00</floatArray>
</NASA>
</thermo>
<transport model="gas_transport">
<string title="geometry">atom</string>
<LJ_welldepth units="K">136.500</LJ_welldepth>
<LJ_diameter units="A">3.330</LJ_diameter>
<dipoleMoment units="Debye">0.000</dipoleMoment>
<polarizability units="A3">0.000</polarizability>
<rotRelax>0.000</rotRelax>
</transport>
</species>
</speciesData>
<reactionData id="reaction_data">
<!-- reaction 0001 -->
<reaction duplicate="yes" reversible="yes" id="0001">
<equation>NH + NO [=] N2O + H</equation>
<rateCoeff>
<Arrhenius>
<A>2.940000E+11</A>
<b>-0.40000000000000002</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NH:1.0 NO:1</reactants>
<products>H:1 N2O:1.0</products>
</reaction>
<!-- reaction 0002 -->
<reaction duplicate="yes" reversible="yes" negative_A="yes" id="0002">
<equation>NH + NO [=] N2O + H</equation>
<rateCoeff>
<Arrhenius>
<A>-2.160000E+10</A>
<b>-0.23000000000000001</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NH:1.0 NO:1</reactants>
<products>H:1 N2O:1.0</products>
</reaction>
<!-- reaction 0003 -->
<reaction duplicate="yes" reversible="yes" id="0003">
<equation>NH2 + NO [=] N2 + H2O</equation>
<rateCoeff>
<Arrhenius>
<A>1.300000E+13</A>
<b>-1.25</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NO:1 NH2:1.0</reactants>
<products>N2:1.0 H2O:1</products>
</reaction>
<!-- reaction 0004 -->
<reaction duplicate="yes" reversible="yes" negative_A="yes" id="0004">
<equation>NH2 + NO [=] N2 + H2O</equation>
<rateCoeff>
<Arrhenius>
<A>-2.800000E+10</A>
<b>-0.55000000000000004</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NO:1 NH2:1.0</reactants>
<products>N2:1.0 H2O:1</products>
</reaction>
<!-- reaction 0005 -->
<reaction reversible="yes" type="threeBody" id="0005">
<equation>2 O + M [=] O2 + M</equation>
<rateCoeff>
<Arrhenius>
<A>1.200000E+11</A>
<b>-1</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
<efficiencies default="1.0">AR:0.83 </efficiencies>
</rateCoeff>
<reactants>O:2.0</reactants>
<products>O2:1.0</products>
</reaction>
<!-- reaction 0006 -->
<reaction reversible="yes" id="0006">
<equation>N + NO [=] N2 + O</equation>
<rateCoeff>
<Arrhenius>
<A>2.700000E+10</A>
<b>0</b>
<E units="cal/mol">355.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>NO:1 N:1.0</reactants>
<products>N2:1.0 O:1</products>
</reaction>
<!-- reaction 0007 -->
<reaction reversible="yes" id="0007">
<equation>N + O2 [=] NO + O</equation>
<rateCoeff>
<Arrhenius>
<A>9.000000E+06</A>
<b>1</b>
<E units="cal/mol">6500.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>O2:1 N:1.0</reactants>
<products>O:1 NO:1.0</products>
</reaction>
<!-- reaction 0008 -->
<reaction reversible="yes" id="0008">
<equation>N2O + O [=] N2 + O2</equation>
<rateCoeff>
<Arrhenius>
<A>1.400000E+09</A>
<b>0</b>
<E units="cal/mol">10810.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>N2O:1.0 O:1</reactants>
<products>N2:1.0 O2:1</products>
</reaction>
<!-- reaction 0009 -->
<reaction reversible="yes" id="0009">
<equation>N2O + O [=] 2 NO</equation>
<rateCoeff>
<Arrhenius>
<A>2.900000E+10</A>
<b>0</b>
<E units="cal/mol">23150.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>N2O:1.0 O:1</reactants>
<products>NO:2.0</products>
</reaction>
<!-- reaction 0010 -->
<reaction reversible="yes" type="falloff" id="0010">
<equation>N2O (+ M) [=] N2 + O (+ M)</equation>
<rateCoeff>
<Arrhenius>
<A>7.910000E+10</A>
<b>0</b>
<E units="cal/mol">56020.000000</E>
</Arrhenius>
<Arrhenius name="k0">
<A>6.370000E+11</A>
<b>0</b>
<E units="cal/mol">56640.000000</E>
</Arrhenius>
<efficiencies default="1.0">AR:0.625 </efficiencies>
<falloff type="Lindemann"/>
</rateCoeff>
<reactants>N2O:1.0</reactants>
<products>N2:1.0 O:1</products>
</reaction>
<!-- reaction 0011 -->
<reaction reversible="yes" type="threeBody" id="0011">
<equation>NO + O + M [=] NO2 + M</equation>
<rateCoeff>
<Arrhenius>
<A>1.060000E+14</A>
<b>-1.4099999999999999</b>
<E units="cal/mol">0.000000</E>
</Arrhenius>
<efficiencies default="1.0">AR:0.7 </efficiencies>
</rateCoeff>
<reactants>O:1 NO:1.0</reactants>
<products>NO2:1.0</products>
</reaction>
<!-- reaction 0012 -->
<reaction reversible="yes" id="0012">
<equation>NO2 + O [=] NO + O2</equation>
<rateCoeff>
<Arrhenius>
<A>3.900000E+09</A>
<b>0</b>
<E units="cal/mol">-240.000000</E>
</Arrhenius>
</rateCoeff>
<reactants>O:1 NO2:1.0</reactants>
<products>O2:1 NO:1.0</products>
</reaction>
</reactionData>
</ctml>

View File

@@ -1,36 +0,0 @@
#!/bin/sh
#
#
temp_success="0"
testName="negATest"
/bin/rm -f output.txt outputa.txt
#################################################################
#
#################################################################
CANTERA_DATA=${CANTERA_DATA:=../../data/inputs}; export CANTERA_DATA
CANTERA_BIN=${CANTERA_BIN:=../../bin}
./negATest noxNeg_blessed.xml > output.txt
retnStat=$?
if [ $retnStat != "0" ]
then
temp_success="1"
echo "$testName returned with bad status, $retnStat, check output"
fi
../../bin/exp3to2.sh output.txt > outputa.txt
diff -w outputa.txt negATest_blessed.out > diff_test.out
retnStat=$?
if [ $retnStat = "0" ]
then
echo "successful diff comparison on $testName test"
return 0
else
echo "unsuccessful diff comparison on $testName test"
echo "FAILED" > csvCode.txt
temp_success="1"
return 1
fi
#