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

Add Filter option to RemoveDrift() #1829

Open
rskye144 opened this issue Jun 26, 2024 · 1 comment
Open

Add Filter option to RemoveDrift() #1829

rskye144 opened this issue Jun 26, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@rskye144
Copy link

Description

The function hoomd.update.RemoveDrift() currently updates the position of all particles in the simulation. I would like to be able to pass a subset of particles so that the center-of-mass calculation and position update applies only to the filtered particles. In particular, this is useful in the case where a system has "dummy" particles which are not part of the integrator.

Proposed solution

The function RemoveDrift() will take in a filter argument similarly to the integrator or writer functions.

Additional context

In particular, I'm implementing Frenkel-Ladd free energy calculations in MD, which is theoretically supported by RemoveDrift() (in the documentation here). However, the suggested method of creating a dummy lattice of reference particles to restrain the crystal has a systematic error if reference particles are moved by RemoveDrift()

@rskye144 rskye144 added the enhancement New feature or request label Jun 26, 2024
@joaander
Copy link
Member

Indeed. Feel free to submit a pull request that adds this functionality.

Alternately, you can use the Einstein molecule (https://doi.org/10.1063/1.2790426) approach which does not require RemoveDrift.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants