Commit 52a1c54d authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

support QUIP wrapper API version query, relax hybrid restriction to allow...

support QUIP wrapper API version query, relax hybrid restriction to allow hybrid/overlay, update docs
parent fcf9607a
Loading
Loading
Loading
Loading
+12 −4
Original line number Diff line number Diff line
@@ -83,10 +83,18 @@ therefore should be used with LAMMPS metal "units"_units.html.
QUIP potentials are generally not designed to work with the scaling
factors set by the "special_bonds"_special_bonds.html command.  The
recommended setting in molecular systems is to include all
interactions, i.e. to use {special_bonds lj 1.0 1.0 1.0}.  The only
exception to this rule is if you know that your QUIP potential needs
to exclude bonded, 1-3, or 1-4 interactions and does not already do
this exclusion within QUIP.
interactions, i.e. to use {special_bonds lj/coul 1.0 1.0 1.0}. Scaling
factors > 0.0 will be ignored and treated as 1.0. The only exception
to this rule is if you know that your QUIP potential needs to exclude
bonded, 1-3, or 1-4 interactions and does not already do this exclusion
within QUIP. Then a factor 0.0 needs to be used which will remove such
pairs from the neighbor list. This needs to be very carefully tested,
because it may remove pairs from the neighbor list that are still
required.

Pair style {quip} cannot be used with pair style {hybrid}, only
with {hybrid/overlay} and only the {quip} substyle is applied to
all atom types.

[Related commands:]

+8 −2
Original line number Diff line number Diff line
@@ -214,8 +214,14 @@ void PairQUIP::compute(int eflag, int vflag)
void PairQUIP::settings(int narg, char **arg)
{
  if (narg != 0) error->all(FLERR,"Illegal pair_style command");
  if (strncmp(force->pair_style,"hybrid",6) == 0)
    error->all(FLERR,"Pair style quip is not compatible with hybrid styles");
  if (strcmp(force->pair_style,"hybrid") == 0)
    error->all(FLERR,"Pair style quip is only compatible with hybrid/overlay");

  // check if linked to the correct QUIP library API version
  // as of 2017-07-19 this is API_VERSION 1
  if (quip_lammps_api_version() != 1)
    error->all(FLERR,"QUIP LAMMPS wrapper API version is not compatible "
        "with this version of LAMMPS");
}

/* ----------------------------------------------------------------------
+3 −2
Original line number Diff line number Diff line
@@ -24,6 +24,7 @@ PairStyle(quip,PairQUIP)

extern "C"
{
  int quip_lammps_api_version();
  void quip_lammps_wrapper(int*, int*, int*, int*,
      int*, int*, int*,
      int*, int*, double*,