-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Molecules connectivity + compatibility with manybody interactions #91
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Added LAMMPSData class that handles the input/output to LAMMPS data text files to/from numpy arrays, and a Molecules class that (so far) provides access to the connectivity and types for bonds/angles/dihedrals.
Currently only computes potential energies for bonds, angles and dihedrals.
The classes CutoffNeighbourhood wraps around the neighbour_list and triplet_list functions. MolecularNeighbourhood mimics CutoffNeighbourhood in the quantities it returns, but takes pair information from the connectivity defined by the Molecules class.
The C extension functions only accept int32 types.
Out of plane components of the Hessian should be 0, but for short bond lengths the analytical expression of the Hessian accumulates floating point errors. There may be an optimal implementation of the analytical expression to minimze floating point error.
When calling neighbour_list with an integer cutoff, the previous behavior was to raise a ValueError exception with an obscure error message.
pastewka
requested changes
Mar 5, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. A couple of minor comments. Please also add yourself to the AUTHORS file as we use that information and the git log to update the copyright information on top of the files.
pastewka
approved these changes
Mar 7, 2022
Thanks for the contribution @prs513rosewood |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi all,
Here's the start of my work on bonded interactions (pair bonds, angles, dihedrals). It is currently composed of two parts:
LAMMPSData
class in theio.lammps_data
submodule.Molecules
class in themolecules
submodule, which also provides convenience functions for geometry calculations.I also added a few simple calculators (mainly for testing), but I'll end up removing them once I get the manybody calculator to play nice with molecule connectivity. For that, I think I'll create a class with an interface that abstracts away whether pairs and triplets come from neighbor lists or a prescribed connectivity. Any feedback welcome.