ReactionMechanismGenerator / RMG-Py

Python version of the amazing Reaction Mechanism Generator (RMG).
http://reactionmechanismgenerator.github.io/RMG-Py/
Other
397 stars 228 forks source link

Crashes after generating quintuplet [C] #1559

Closed ajuluc closed 1 year ago

ajuluc commented 5 years ago

Bug Description

After running for a while, my job DME.py crashes with:

After model enlargement:
    The model core has 131 species and 5391 reactions
    The model edge has 39356 species and 62279 reactions

Error: Couldn't find in radical thermo database:
Error: <Molecule "[C]">
Error: multiplicity 5
1 C u4 p0 c0

There are many different small CHx species with different multiplicites

23 is CH2 multiplicity 3 24 is CH multiplicity 2 27 is CH2 multiplicity 1 35 is C multiplicity 3 192 is CH multiplicity 4 (then C multiplicity 5 crashes)

There are many reactions with these species interchanging via H Abstraction

! Reaction index: Chemkin #5860; RMG #1228
! Template reaction: H_Abstraction
! Flux pairs: CH2(23), CH3(21); CH2(23), CH(192); 
! Estimated using template [Xbirad_H;Y_1centerbirad] for rate rule [CH2_triplet_H;CH2_triplet]
! Euclidian distance = 1.41421356237
! Multiplied by reaction path degeneracy 2.0
! family: H_Abstraction
CH2(23)+CH2(23)=CH(192)+CH3(21)                     3.400000e+08 1.500     52.074   

! Reaction index: Chemkin #487; RMG #1460
! Template reaction: H_Abstraction
! Flux pairs: CH2(S)(27), CH(24); CH2(23), CH3(21); 
! Estimated using template [Xbirad_H;Y_1centerbirad] for rate rule [CH2_singlet_H;CH2_triplet]
! Euclidian distance = 1.41421356237
! Multiplied by reaction path degeneracy 2.0
! family: H_Abstraction
CH2(23)+CH2(S)(27)=CH3(21)+CH(24)                   3.400000e+08 1.500     52.074   

! Reaction index: Chemkin #4710; RMG #1467
! Template reaction: H_Abstraction
! Flux pairs: CH2(23), CH3(21); CH(24), C(35); 
! Estimated using template [X_H_or_Xrad_H_Xbirad_H_Xtrirad_H;CH2_triplet] for rate rule [C_doublet_H;CH2_triplet]
! Euclidian distance = 2.0
! family: H_Abstraction
CH2(23)+CH(24)=CH3(21)+C(35)                        3.404229e+05 1.610     4.377    

! Reaction index: Chemkin #4713; RMG #1476
! Template reaction: H_Abstraction
! Flux pairs: CH(24), CH2(S)(27); CH(24), C(35); 
! Estimated using template [X_H_or_Xrad_H_Xbirad_H_Xtrirad_H;Y_1centertrirad] for rate rule [C_doublet_H;CH_doublet]
! Euclidian distance = 2.2360679775
! family: H_Abstraction
CH(24)+CH(24)=CH2(S)(27)+C(35)                      2.262742e+13 0.050     23.199   

! Reaction index: Chemkin #57246; RMG #112522
! Template reaction: H_Abstraction
! Flux pairs: CH(24), C(35); CH(192), CH2(23); 
! Estimated using template [X_H_or_Xrad_H_Xbirad_H_Xtrirad_H;Y_1centertrirad] for rate rule [C_doublet_H;CH_quartet]
! Euclidian distance = 2.2360679775
! family: H_Abstraction
CH(192)+CH(24)=CH2(23)+C(35)                        2.262742e+13 0.050     23.199   

Should some of these be forbidden? Should generating the C(quintuplet) be forbidden? Or should it be in a thermo library? How best to proceed without this crashing (and ideally, without inaccurate or inappropriate reactions)?

How To Reproduce

See input file above.

Expected Behavior

it wouldn't crash

Installation Information

Describe your installation method and system information.

ajuluc commented 5 years ago

is it normal/advisable to have a constraint like maximumRadicalElectrons=2, in the generatedSpeciesConstraints block?

mjohnson541 commented 5 years ago

Yes, unless you have nitrogen you should almost always set maximumRadicalElectrons=2 (or if you're confident birads aren't important to 1) It's ok to have these species if they're from libraries, but group additivity isn't very good even for multiplicity 3 let alone multiplicity 4.

rwest commented 5 years ago

Thanks Matt. Helpful advice. I feel that "out of the box" RMG should at least not crash. (Maybe put C(q) in radical tree?)

And/or the minimal examples and newbie instructions should guide people to the necessary settings. Like the couple of lines you just wrote.

ajuluc commented 5 years ago

Yes, unless you have nitrogen you should almost always set maximumRadicalElectrons=2 (or if you're confident birads aren't important to 1) It's ok to have these species if they're from libraries, but group additivity isn't very good even for multiplicity 3 let alone multiplicity 4.

Thanks Matt for the help. Just to clarify, group additivity isn't good for multiplicity 3. Thus we should always set the maximumRadicalElectrons=2 even when Nitrogen isn't present.

mjohnson541 commented 5 years ago

Yes, that probably wouldn't be very hard.

That's absolutely true, I'm pretty sure it's in the RMG Handbook now although we might consider distributing that better and we've been discussing updating the example files to be more modern RMG jobs, use modern libraries and run settings etc at the next hackathon.

So GAV is usually pretty bad for multiplicity 3, but occasionally larger molecules with two radical electrons (multiplicity 3) are important so we usually include multiplicity 3....however it's very rare to have multiplicity 4 or more molecules that are important...so we generally set maximumRadicalElectrons=2 unless Nitrogen is present...because I believe [N] can be important in some cases.

ajuluc commented 5 years ago

Thanks for the clarification. So in the case when Nitrogen is present although inert, what would be the recommended setting for the maximumRadicalElectrons? Since (multiplicity 4) 3 radical electrons is somewhat common can we have the maximumRadicalElectrons=3 for reactions involving Nitrogen?

mjohnson541 commented 5 years ago

If it's inert you can ignore it and set maximumRadicalElectrons=2. If you have nitrogen reacting in your system you should set maximumRadicalElectrons=3.

ajuluc commented 5 years ago

Thanks for that clarification. You did mention that these added instructions have been added to the RMG workbook right?

mjohnson541 commented 5 years ago

Yes, I'm pretty certain it's in there somewhere.

github-actions[bot] commented 1 year ago

This issue is being automatically marked as stale because it has not received any interaction in the last 90 days. Please leave a comment if this is still a relevant issue, otherwise it will automatically be closed in 30 days.