Unverified Commit b9727e0d authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

add support for single() and r-RESPA to pair style zero

parent f3b2ec80
Loading
Loading
Loading
Loading
+18 −1
Changes for src/pair_zero.cpp: 18 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -31,6 +31,8 @@ using namespace LAMMPS_NS;
PairZero::PairZero(LAMMPS *lmp) : Pair(lmp) {
  coeffflag=1;
  writedata=1;
  single_enable=1;
  respa_enable=1;
}

/* ---------------------------------------------------------------------- */
@@ -49,10 +51,16 @@ PairZero::~PairZero()
void PairZero::compute(int eflag, int vflag)
{
 ev_init(eflag,vflag);

 if (vflag_fdotr) virial_fdotr_compute();
}

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

void PairZero::compute_outer(int eflag, int vflag)
{
 ev_init(eflag,vflag);
}

/* ----------------------------------------------------------------------
   allocate all arrays
------------------------------------------------------------------------- */
@@ -227,4 +235,13 @@ void PairZero::write_data_all(FILE *fp)
      fprintf(fp,"%d %d %g\n",i,j,cut[i][j]);
}

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

double PairZero::single(int /*i*/, int /*j*/, int /* itype */, int /* jtype */,
                        double /* rsq */, double /*factor_coul*/,
                        double /* factor_lj */, double &fforce)
{
  fforce = 0.0;
  return 0.0;
}
+2 −0
Changes for src/pair_zero.h: 2 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -39,6 +39,7 @@ class PairZero : public Pair {
  PairZero(class LAMMPS *);
  virtual ~PairZero();
  virtual void compute(int, int);
  virtual void compute_outer(int, int);
  void settings(int, char **);
  void coeff(int, char **);
  double init_one(int, int);
@@ -48,6 +49,7 @@ class PairZero : public Pair {
  void read_restart_settings(FILE *);
  void write_data(FILE *);
  void write_data_all(FILE *);
  double single(int, int, int, int, double, double, double, double &);

 protected:
  double cut_global;