Eliminated obvious but hard to find error in neighbor list request
This commit is contained in:
@ -58,4 +58,6 @@ pair_style sna/grid grid ${ngrid} ${ngrid} ${ngrid} &
|
||||
quadraticflag ${quad} switchflag ${switch}
|
||||
pair_coeff * * Al
|
||||
|
||||
neighbor 0.0 nsq
|
||||
|
||||
run 0
|
||||
|
||||
@ -56,17 +56,14 @@ PairSNAGrid::~PairSNAGrid()
|
||||
|
||||
void PairSNAGrid::init_style()
|
||||
{
|
||||
if (force->pair == nullptr)
|
||||
error->all(FLERR,"Pair sna/grid requires a pair style be defined");
|
||||
if (force->newton_pair == 0)
|
||||
error->all(FLERR,"Pair style sna/grid requires newton pair on");
|
||||
|
||||
// need an occasional full neighbor list
|
||||
// need a full neighbor list
|
||||
|
||||
int irequest = neighbor->request(this,instance_me);
|
||||
neighbor->requests[irequest]->pair = 0;
|
||||
neighbor->requests[irequest]->compute = 1;
|
||||
neighbor->requests[irequest]->half = 0;
|
||||
neighbor->requests[irequest]->full = 1;
|
||||
neighbor->requests[irequest]->occasional = 1;
|
||||
|
||||
snaptr = new SNA(lmp, rfac0, twojmax,
|
||||
rmin0, switchflag, bzeroflag,
|
||||
|
||||
@ -60,6 +60,7 @@ PairGrid::~PairGrid()
|
||||
|
||||
void PairGrid::setup()
|
||||
{
|
||||
printf("Inside PairGrid::setup()\n");
|
||||
printf("Hello, world! C\n");
|
||||
// deallocate_grid();
|
||||
printf("Hello, world! D\n");
|
||||
@ -317,6 +318,7 @@ void PairGrid::coeff(int narg, char **arg)
|
||||
|
||||
double PairGrid::init_one(int i, int j)
|
||||
{
|
||||
printf("Inside PairGrid::init_one()\n");
|
||||
printf("i = %d j = %d setflag = %d\n", i, j, setflag[i][j]);
|
||||
if (setflag[i][j] == 0) error->all(FLERR,"All pair coeffs are not set");
|
||||
printf("PairGrid cutmax = %g\n",cutmax);
|
||||
|
||||
Reference in New Issue
Block a user