diff --git a/src/USER-MISC/pair_edip.cpp b/src/USER-MISC/pair_edip.cpp index b29f499de8..12390ba69d 100644 --- a/src/USER-MISC/pair_edip.cpp +++ b/src/USER-MISC/pair_edip.cpp @@ -46,7 +46,7 @@ using namespace LAMMPS_NS; // max number of interaction per atom for f(Z) environment potential -#define leadDimInteractionList 64 +static constexpr int leadDimInteractionList = 64; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-MISC/pair_edip_multi.cpp b/src/USER-MISC/pair_edip_multi.cpp index 811f80abfc..9d36db7041 100644 --- a/src/USER-MISC/pair_edip_multi.cpp +++ b/src/USER-MISC/pair_edip_multi.cpp @@ -32,13 +32,11 @@ #include "error.h" #include "citeme.h" - using namespace LAMMPS_NS; #define MAXLINE 1024 #define DELTA 4 - static const char cite_pair_edip[] = "@article{cjiang2012\n" " author = {Jian, Chao and Morgan, Dane, and Szlufarska, Izabella},\n" @@ -56,7 +54,9 @@ static const char cite_pair_edip[] = " year = {2010},\n" "}\n\n"; +// max number of interaction per atom for f(Z) environment potential +static constexpr int leadDimInteractionList = 64; /* ---------------------------------------------------------------------- */ @@ -94,7 +94,6 @@ PairEDIPMulti::~PairEDIPMulti() memory->destroy(cutsq); delete [] map; -//XXX deallocateGrids(); deallocatePreLoops(); } } diff --git a/src/USER-MISC/pair_edip_multi.h b/src/USER-MISC/pair_edip_multi.h index 26433a66fa..5120ece5d2 100644 --- a/src/USER-MISC/pair_edip_multi.h +++ b/src/USER-MISC/pair_edip_multi.h @@ -36,17 +36,17 @@ class PairEDIPMulti : public Pair { protected: struct Param { - double A, B;//coefficients for pair interaction I-J - double cutoffA;//cut-off distance for pair interaction I-J - double cutoffC;//lower cut-off distance for calculating Z_I - double alpha;//coefficient for calculating Z_I - double beta;//attractive term for pair I-J - double sigma;//cut-off coefficient for pair I-J - double rho;//pair I-J - double gamma;//coefficient for three-body interaction I-J-K - double eta, lambda;//coefficients for function h(l,Z) - double mu, Q0;//coefficients for function Q(Z) - double u1, u2, u3, u4;//coefficients for function tau(Z) + double A, B; // coefficients for pair interaction I-J + double cutoffA; // cut-off distance for pair interaction I-J + double cutoffC; // lower cut-off distance for calculating Z_I + double alpha; // coefficient for calculating Z_I + double beta; // attractive term for pair I-J + double sigma; // cut-off coefficient for pair I-J + double rho; // pair I-J + double gamma; // coefficient for three-body interaction I-J-K + double eta, lambda; // coefficients for function h(l,Z) + double mu, Q0; // coefficients for function Q(Z) + double u1, u2, u3, u4; // coefficients for function tau(Z) double cutsq; int ielement,jelement,kelement; }; @@ -62,10 +62,6 @@ class PairEDIPMulti : public Pair { int maxparam; // max # of parameter sets Param *params; // parameter set for an I-J-K interaction - // max number of interaction per atom for f(Z) environment potential - - static const int leadDimInteractionList = 64; - void allocate(); void allocatePreLoops(void); void deallocatePreLoops(void); diff --git a/src/USER-OMP/pair_edip_omp.cpp b/src/USER-OMP/pair_edip_omp.cpp index 2eb8384113..106d038743 100644 --- a/src/USER-OMP/pair_edip_omp.cpp +++ b/src/USER-OMP/pair_edip_omp.cpp @@ -28,7 +28,7 @@ using namespace LAMMPS_NS; // max number of interaction per atom for f(Z) environment potential -#define leadDimInteractionList 64 +static constexpr int leadDimInteractionList = 64; /* ---------------------------------------------------------------------- */