Documente Academic
Documente Profesional
Documente Cultură
When you construct the block of 400 atoms each atom has two coordinates (in plane)
plus a number identifying the atom. When considering the possible interactions
between all atoms you would calculate 0.5x400x399 interaction energies or forces,
which is 79,800 interactions. Out of this 99% will be zeros since most of the atoms
are further apart than the cut-off radius of the potential. Obviously, it would be an
enormous waste of calculations to carry out evaluation of interactions (distances)
between all atoms. (Imagine that you have a million atoms what this would mean).
What you obviously want is to limit the number of interactions that you have to
evaluate only to those atoms that are within the cut-off of their interactions. In fact
one always includes a few more atoms, for example all those at 1.5xrcut, since during
relaxation the atoms may come closer or further apart. For this purpose one always
prepares the map of neighbors that for each atom lists those atoms with which a given
atom may really interact. Lets look at the picture below.
Consider atom number 91. The red circle defines the distance up to which possible
interacting neighbors are to be taken into account. The radius of this circle is close
but somewhat larger than rcut. Now, for the atom 91 we just produce the list of the
atoms that are within this circle and this list is the map of interacting neighbors. The
atoms belonging to this group are listed above and in calculation only those atoms
will be included when evaluating the interactions of the atom 91 with the rest of the
atoms in the block.
When you have the block of atoms prepared and all atoms are numbered you generate
the neighbor list by creating the following two arrays:
NEIGHBORS(N,K)
and
NOFNEIGHBORS(N)
N=1, , 400
K=1, , Kmax, where Kmax is the maximum number of neighbors
expected.
Also
store
the
value
in
Very first time you have to try for all the atoms in the block if they
are neighbors of the atom j. But, when the list of neighbors has
been established you will only consider interaction of the atom j
with those atoms that are in its neighbor map. This will save an
enormous amount of time compared with testing all possible
interactions all the time.