openforcefield / openff-interchange

A project (and object) for storing, manipulating, and converting molecular mechanics data.
https://docs.openforcefield.org/projects/interchange
MIT License
71 stars 23 forks source link

PotentialKey id should be allowed to be a tuple of integers. #130

Closed umesh-timalsina closed 1 month ago

umesh-timalsina commented 3 years ago

Related to #114. Currently, I store the Bond, Angle and Dihedral parameters based on atom_indices. It might be nice to be able to support the PotentialKey type to be a tuple of atom indices.

mattwthompson commented 3 years ago

I would rather avoid this, as it muddies the defined structure of the core object model; atom indices do not define interactions in force fields, other definitions associated with the typing procedures do. There may be situation in which keys needs to be generated on the fly, but it would be better for these keys to represent something in the force field, i.e. bond parameters having keys like "CT-CT" for aliphatic carbons in OPLS-AA.

mattwthompson commented 1 month ago

We've done okay smooshing together things into messy strings, which isn't the beset solution but works