Skip to content

Commit

Permalink
Improved treatment of the X#C-O-X adsorbate
Browse files Browse the repository at this point in the history
This ensures that the correct resonance structure for gas-phase CO is used.
Might need to be revisited after sorting out resonance structures of adsorbates.
  • Loading branch information
kblondal authored and mjohnson541 committed Apr 26, 2021
1 parent 36ada6b commit 904b6e0
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions rmgpy/data/thermo.py
Original file line number Diff line number Diff line change
Expand Up @@ -1531,6 +1531,16 @@ def get_thermo_data_for_surface_species(self, species):
adsorbed_atoms[0].increment_radical()
adsorbed_atoms[1].decrement_lone_pairs()
adsorbed_atoms[1].increment_radical()
#For bidentate CO because we want C[-1]#O[+1] but not .C#O.
if (bond.order == 3 and adsorbed_atoms[0].radical_electrons and
adsorbed_atoms[1].radical_electrons and
(adsorbed_atoms[0].lone_pairs or adsorbed_atoms[1].lone_pairs)):
adsorbed_atoms[0].decrement_radical()
adsorbed_atoms[1].decrement_radical()
if adsorbed_atoms[0].lone_pairs:
adsorbed_atoms[1].increment_lone_pairs()
else:
adsorbed_atoms[0].increment_lone_pairs()

dummy_molecule.update_connectivity_values()
dummy_molecule.update()
Expand Down

0 comments on commit 904b6e0

Please sign in to comment.