Skip to content
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
merged 40 commits into from
Mar 7, 2022

Conversation

prs513rosewood
Copy link
Contributor

Hi all,

Here's the start of my work on bonded interactions (pair bonds, angles, dihedrals). It is currently composed of two parts:

  • IO capabilities to read connectivity from lammps files. This is done with the LAMMPSData class in the io.lammps_data submodule.
  • Storing of connectivity information. Currently the Molecules class in the molecules 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.

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.
@prs513rosewood prs513rosewood marked this pull request as ready for review February 25, 2022 12:42
When calling neighbour_list with an integer cutoff, the previous behavior was to
raise a ValueError exception with an obscure error message.
Copy link
Collaborator

@pastewka pastewka left a 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 pastewka merged commit f535478 into libAtoms:master Mar 7, 2022
@pastewka
Copy link
Collaborator

pastewka commented Mar 7, 2022

Thanks for the contribution @prs513rosewood

@prs513rosewood prs513rosewood deleted the features/molecules branch March 8, 2022 08:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants