Commit 994fd2af authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

move enum{NSQ,BIN,MULTI} to the Neighbor class in neighbor.h

parent d8138a5b
Loading
Loading
Loading
Loading
+0 −2
Original line number Diff line number Diff line
@@ -23,8 +23,6 @@

using namespace LAMMPS_NS;

enum{NSQ,BIN,MULTI};       // also in Neighbor

#define SMALL 1.0e-6
#define CUT2BIN_RATIO 100

+0 −2
Original line number Diff line number Diff line
@@ -17,8 +17,6 @@

using namespace LAMMPS_NS;

enum{NSQ,BIN,MULTI};

/* ---------------------------------------------------------------------- */

template<class Device>
+2 −4
Original line number Diff line number Diff line
@@ -33,8 +33,6 @@

using namespace LAMMPS_NS;

enum{NSQ,BIN,MULTI};     // also in neigh_list.cpp

/* ---------------------------------------------------------------------- */

NeighborKokkos::NeighborKokkos(LAMMPS *lmp) : Neighbor(lmp),
@@ -98,7 +96,7 @@ void NeighborKokkos::init_cutneighsq_kokkos(int n)

void NeighborKokkos::create_kokkos_list(int i)
{
  if (style != BIN)
  if (style != Neighbor::BIN)
    error->all(FLERR,"KOKKOS package only supports 'bin' neighbor lists");

  if (requests[i]->kokkos_device) {
@@ -300,7 +298,7 @@ void NeighborKokkos::build_kokkos(int topoflag)
  // if bin then, atoms may have moved outside of proc domain & bin extent,
  //   leading to errors or even a crash

  if (style != NSQ) {
  if (style != Neighbor::NSQ) {
    for (int i = 0; i < nbin; i++) {
      neigh_bin[i]->bin_atoms_setup(nall);
      neigh_bin[i]->bin_atoms();
+1 −3
Original line number Diff line number Diff line
@@ -55,8 +55,6 @@ using namespace FixConst;
#endif
#endif

enum{NSQ,BIN,MULTI};

/* ---------------------------------------------------------------------- */

FixIntel::FixIntel(LAMMPS *lmp, int narg, char **arg) :  Fix(lmp, narg, arg)
@@ -353,7 +351,7 @@ void FixIntel::init()

void FixIntel::setup(int vflag)
{
  if (neighbor->style != BIN)
  if (neighbor->style != Neighbor::BIN)
    error->all(FLERR,
            "Currently, neighbor style BIN must be used with Intel package.");
  if (neighbor->exclude_setting() != 0)
+1 −3
Original line number Diff line number Diff line
@@ -22,8 +22,6 @@

using namespace LAMMPS_NS;

enum{NSQ,BIN,MULTI};       // also in Neighbor

#define SMALL 1.0e-6
#define CUT2BIN_RATIO 100

@@ -94,7 +92,7 @@ void NBinStandard::setup_bins(int style)

  double binsize_optimal;
  if (binsizeflag) binsize_optimal = binsize_user;
  else if (style == BIN) binsize_optimal = 0.5*cutneighmax;
  else if (style == Neighbor::BIN) binsize_optimal = 0.5*cutneighmax;
  else binsize_optimal = 0.5*cutneighmin;
  if (binsize_optimal == 0.0) binsize_optimal = bbox[0];
  double binsizeinv = 1.0/binsize_optimal;
Loading