How would lammps process the interaction if the box is small compared with the cutoff distance under p p p boundary?

Hi there,
I am trying to figure out how lammps process the p p p boundary condition.
Suppose that I try to model the bulk behavior of graphite through a 2-layer graphene with p p p b.c…
Atoms within the two layers are labeled by type 1 and 2 (shown in the picture below), respectively. The intralayer interation is modeled by rebo and interlayer by LJ, as

pair_style		hybrid lj/cut 10.    rebo rebo 
pair_coeff	* * rebo 1 CH.rebo  C NULL 
pair_coeff	* * rebo 2 CH.rebo  NULL C 
pair_coeff            1 2  lj/cut 0.00284  3.40

Here is my confusions:

  1. To process the ppp b.c., there is an imaginary box labeled by (‘). Would layer 1 and layer 1’ be different to lammps? In other words, would there be interaction between layer 1 and 1’, since only pair_coeff between layer 1 and layer 2 are specified?
  2. Would there be more imaginary boxes as needed, if I increase the cutoff distance of LJ, say, to 20? Under such circumstance, the cutoff distance would cross more than 2 boxes.


I suggest you first get some background info by studying the most recent LAMMPS paper or 4.4. Parallel algorithms — LAMMPS documentation

Ghost atoms have the same atom type than their original, so there will be interactions computed.

The largest cutoff determines also the ghost atom cutoff and that may be more than half the box dimension since LAMMPS is not subject to minimum image conventions. It uses real copies of the ghost atoms and updates their positions during the simulation and does not need to find the closes image during the force computation. The choice is already made during the neighbor list construction.


Thank you akohlmey for your reply.

This is just what confuse me.
If ‘ghost atoms have the same atom type than their original’, then atoms in layer 1 and layer 1’ have the same atom type 1. This would lead to no interactions between layer 1 and layer 1’, because there is no LJ pair_coeff specified between type 1 and type 1. Of course, the interactions between layer 1’ and layer 2 will be computed, since they have different atom type. Hence, to successfully model the bulk behavior, the box should contain enough layers such that the total thickness of all layers is not smaller than the cutoff distance.
Is this understanding correct?

I have this confusion, because I am trying to understand the layer-number-dependent total potential encountered in my simulation. Simply take the system above as an example, during shearing the box parallel to the graphene surface by ‘fix deform’, the total potential energy is calculated and then averaged by the number of layers n contained by the box, which is denoted by En. The above example containing 2 layers corresponds to E2. I find that En decreases sharply at first and soon becomes steady, as n increases from 2.
It appears that the above mentioned understanding about ppp b.c. processing might explain this odd phenomenon.

You do have the REBO potential set up for interactions between pairs of type 1 atoms and pairs of type 2 atoms. That is the model you have entered.

If you want a different behavior, you need to set up a larger system with more layers. Then each layer has a different atom type and you can apply Lennard-Jones to the inter-layer interactions.

I’m now clear about this. Really appreciate your help!