Unverified Commit 9afbc718 authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

only check for consistent cutoff and return it when flagged as kspace compatible

parent 66271448
Loading
Loading
Loading
Loading
+11 −7
Original line number Diff line number Diff line
@@ -1033,6 +1033,9 @@ void *PairTable::extract(const char *str, int &dim)
  if (strcmp(str,"cut_coul") != 0) return NULL;
  if (ntables == 0) error->all(FLERR,"All pair coeffs are not set");

  // only check for cutoff consistency if claiming to be KSpace compatible

  if (ewaldflag || pppmflag || msmflag || dispersionflag || tip4pflag) {
    double cut_coul = tables[0].cut;
    for (int m = 1; m < ntables; m++)
      if (tables[m].cut != cut_coul)
@@ -1040,4 +1043,5 @@ void *PairTable::extract(const char *str, int &dim)
                   "Pair table cutoffs must all be equal to use with KSpace");
    dim = 0;
    return &tables[0].cut;
  } else return NULL;
}