Hello All,

I am using a pair potential (AI-REBO), and at every timestep I would like to output the number of pairs in the system. This data seems available, since at the end of a run the log outputs the max, min and average number of neighbors.

I know that “compute pair/local” or “compute property/local” can output arrays whose length is the total number of interactions, but I would like to know if there was a way to simply output that number as a scalar.

Any suggestions?

As always, thank you for your help!

-Emil

Hello All,

I am using a pair potential (AI-REBO), and at every timestep I would like to

output the number of pairs in the system. This data seems available, since

at the end of a run the log outputs the max, min and average number of

neighbors.

those are two different properties. how do you define "a pair"?

by the non-bonded force cutoff? the neighbor lists are only "potential pairs".

axel.

Axel- thanks,

I would like to count the number of atoms within the non-bounded force

cutoff throughout the run.

-Emil

You can't do this via pair airebo, or some tallying within it.

Nor via any other pair style. As Axel said, the neighbor list

is different than the force list (i.e. which atoms are within

the cutoff distance). You might look at compute coord/atom.

If you set that cutoff to the force cutoff, then I think you will

get "neighbors" of each atom. If you sum the result via

compute reduce, you will have total # of interacting pairs (if

you divide by 2).

Steve

You can't do this via pair airebo, or some tallying within it.

Nor via any other pair style. As Axel said, the neighbor list

is different than the force list (i.e. which atoms are within

the cutoff distance). You might look at compute coord/atom.

If you set that cutoff to the force cutoff, then I think you will

get "neighbors" of each atom. If you sum the result via

compute reduce, you will have total # of interacting pairs (if

you divide by 2).

an alternative would be compute the radial distribution function

_and__ the number integral. you can easily do that in postprocessing,

e.g. using VMD: http://www.ks.uiuc.edu/Research/vmd/plugins/gofrgui/

the number integral gives you the average number of neighbors

atoms in the first selected group of atoms has from the group of

atoms selected for the second group (those can be the same, of course)

up to the distance r.

cheers,

axel.