New Compute

Hello,

I am trying to monitor the local velocity and density of solvent particles around a colloid. Since regions cannot move with a group of particles, I think I will need to create a new compute command which determines these properties for only particles within a certain distance of the colloid particle.

Before proceeding with this method, I wanted to make sure that I was not creating a function that has already been made and I wanted to ask if you could recommend a compute that performs a similar task so that I could build my code beginning with that file.

Thank you so much in advance!

Jeanine Shea

Not entirely sure about the objective but I do want to clarify that groups of particles declared with a region do move out of the region (unless the dynamic keyword is used) used to originally specify them. Its basically a Lagrangian treatment of following those particles around once the group region style is used. Your restart files should naturally contain the group declarations on these particles to keep tracking them by their group id.

Adrian Diaz

Thank you so much for your quick response.

I do realize that the particles move out of a region based on their Lagrangian trajectory. My ultimate goal is to have a region which follows one particle in my simulation. However, the trajectory of the particle that I want to follow has forces exerted by both active particles and a thermal bath, so I don’t think it would be possible to use the dynamic keyword in this situation.

Thanks!

Jeanine Shea

Hello,

I am trying to monitor the local velocity and density of solvent particles around a colloid. Since regions cannot move with a group of particles, I think I will need to create a new compute command which determines these properties for only particles within a certain distance of the colloid particle.

Before proceeding with this method, I wanted to make sure that I was not creating a function that has already been made and I wanted to ask if you could recommend a compute that performs a similar task so that I could build my code beginning with that file.

compute coord/atom counts atoms within a given cutoff from individual atoms, so that could be a starting point.

axel.

You can try using a variable-based dynamic group for the computes, with the variable similar to:

variable mask atom (z-z[id])^2+(y-y[id])^2+(x-x[id])^2<r^2

Where “id” is the index of the particle and “r” - a radius of the sphere around the particle.

Michał