diff --git a/doc/src/Developer_notes.rst b/doc/src/Developer_notes.rst index e58dec94ac..2b3375265f 100644 --- a/doc/src/Developer_notes.rst +++ b/doc/src/Developer_notes.rst @@ -7,6 +7,15 @@ typically document what a variable stores, what a small section of code does, or what a function does and its input/outputs. The topics on this page are intended to document code functionality at a higher level. +Available topics are: + +- `Reading and parsing of text and text files`_ +- `Requesting and accessing neighbor lists`_ +- `Fix contributions to instantaneous energy, virial, and cumulative energy`_ +- `KSpace PPPM FFT grids`_ + +---- + Reading and parsing of text and text files ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -64,6 +73,149 @@ when converting "12.5", while the ValueTokenizer class will throw an :cpp:func:`ValueTokenizer::next_int() ` is called on the same string. +Requesting and accessing neighbor lists +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +LAMMPS uses Verlet-style neighbor lists to avoid having to loop over +*all* pairs of *all* atoms when computing pairwise properties with a +cutoff (e.g. pairwise forces or radial distribution functions). There +are three main algorithms that can be selected by the :doc:`neighbor +command `: `bin` (the default, uses binning to achieve linear +scaling with system size), `nsq` (without binning, quadratic scaling), +`multi` (with binning, optimized for varying cutoffs or polydisperse +granular particles). In addition to how the neighbor lists are +constructed a number of different variants of neighbor lists need to be +created (e.g. "full" or "half") for different purposes and styles and +those may be required in every time step ("perpetual") or on some steps +("occasional"). + +The neighbor list creation is managed by the ``Neighbor`` class. +Individual classes can obtain a neighbor list by creating an instance of +a ``NeighRequest`` class which is stored in a list inside the +``Neighbor`` class. The ``Neighbor`` class will then analyze the +various requests and apply optimizations where neighbor lists that have +the same settings will be created only once and then copied, or a list +may be constructed by processing a neighbor list from a different +request that is a superset of the requested list. The neighbor list +build is then :doc:`processed in parallel `. + +The most commonly required neighbor list is a so-called "half" neighbor +list, where each pair of atoms is listed only once (except when the +:doc:`newton command setting ` for pair is off; in that case +pairs straddling sub-domains or periodic boundaries will be listed twice). +Thus these are the default settings when a neighbor list request is created in: + +.. code-block:: C++ + + void Pair::init_style() + { + neighbor->add_request(this); + } + + void Pair::init_list(int /*id*/, NeighList *ptr) + { + list = ptr; + } + +The ``this`` pointer argument is required so the neighbor list code can +access the requesting class instance to store the assembled neighbor +list with that instance by calling its ``init_list()`` member function. +The optional second argument (omitted here) contains a bitmask of flags +that determines the kind of neighbor list requested. The default value +used here asks for a perpetual "half" neighbor list. + +Non-default values of the second argument need to be used to adjust a +neighbor list request to the specific needs of a style an additional +request flag is needed. The :doc:`tersoff ` pair style, +for example, needs a "full" neighbor list: + +.. code-block:: C++ + + void PairTersoff::init_style() + { + // [...] + neighbor->add_request(this, NeighConst::REQ_FULL); + } + +When a pair style supports r-RESPA time integration with different cutoff regions, +the request flag may depend on the corresponding r-RESPA settings. Here an example +from pair style lj/cut: + +.. code-block:: C++ + + void PairLJCut::init_style() + { + int list_style = NeighConst::REQ_DEFAULT; + + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; + } + neighbor->add_request(this, list_style); + // [...] + } + +Granular pair styles need neighbor lists based on particle sizes and not cutoff +and also may require to have the list of previous neighbors available ("history"). +For example with: + +.. code-block:: C++ + + if (use_history) neighbor->add_request(this, NeighConst::REQ_SIZE | NeighConst::REQ_HISTORY); + else neighbor->add_request(this, NeighConst::REQ_SIZE); + +In case a class would need to make multiple neighbor list requests with different +settings each request can set an id which is then used in the corresponding +``init_list()`` function to assign it to the suitable pointer variable. This is +done for example by the :doc:`pair style meam `: + +.. code-block:: C++ + + void PairMEAM::init_style() + { + // [...] + neighbor->add_request(this, NeighConst::REQ_FULL)->set_id(1); + neighbor->add_request(this)->set_id(2); + } + void PairMEAM::init_list(int id, NeighList *ptr) + { + if (id == 1) listfull = ptr; + else if (id == 2) listhalf = ptr; + } + +Fixes may require a neighbor list that is only build occasionally (or +just once) and this can also be indicated by a flag. As an example here +is the request from the ``FixPeriNeigh`` class which is created +internally by :doc:`Peridynamics pair styles `: + +.. code-block:: C++ + + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); + +It is also possible to request a neighbor list that uses a different cutoff +than what is usually inferred from the pair style settings (largest cutoff of +all pair styles plus neighbor list skin). The following is used in the +:doc:`compute rdf ` command implementation: + +.. code-block:: C++ + + if (cutflag) + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL)->set_cutoff(mycutneigh); + else + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); + +The neighbor list request function has a slightly different set of arguments +when created by a command style. In this case the neighbor list is +*always* an occasional neighbor list, so that flag is not needed. However +for printing the neighbor list summary the name of the requesting command +should be set. Below is the request from the :doc:`delete atoms ` +command: + +.. code-block:: C++ + + neighbor->add_request(this, "delete_atoms", NeighConst::REQ_FULL); + Fix contributions to instantaneous energy, virial, and cumulative energy ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/src/ASPHERE/pair_gayberne.cpp b/src/ASPHERE/pair_gayberne.cpp index 39cb88f81b..d1770894e2 100644 --- a/src/ASPHERE/pair_gayberne.cpp +++ b/src/ASPHERE/pair_gayberne.cpp @@ -348,7 +348,7 @@ void PairGayBerne::init_style() avec = (AtomVecEllipsoid *) atom->style_match("ellipsoid"); if (!avec) error->all(FLERR,"Pair gayberne requires atom style ellipsoid"); - neighbor->request(this,instance_me); + neighbor->add_request(this,NeighConst::REQ_DEFAULT); // per-type shape precalculations // require that atom shapes are identical within each type diff --git a/src/ASPHERE/pair_line_lj.cpp b/src/ASPHERE/pair_line_lj.cpp index 07b3ea4e9f..a543bac09b 100644 --- a/src/ASPHERE/pair_line_lj.cpp +++ b/src/ASPHERE/pair_line_lj.cpp @@ -405,7 +405,7 @@ void PairLineLJ::init_style() avec = (AtomVecLine *) atom->style_match("line"); if (!avec) error->all(FLERR,"Pair line/lj requires atom style line"); - neighbor->request(this,instance_me); + neighbor->add_request(this,NeighConst::REQ_DEFAULT); } /* ---------------------------------------------------------------------- diff --git a/src/ASPHERE/pair_resquared.cpp b/src/ASPHERE/pair_resquared.cpp index 23ec79fa98..3dfe09d801 100644 --- a/src/ASPHERE/pair_resquared.cpp +++ b/src/ASPHERE/pair_resquared.cpp @@ -320,7 +320,7 @@ void PairRESquared::init_style() avec = (AtomVecEllipsoid *) atom->style_match("ellipsoid"); if (!avec) error->all(FLERR, "Pair resquared requires atom style ellipsoid"); - neighbor->request(this, instance_me); + neighbor->add_request(this,NeighConst::REQ_DEFAULT); // per-type shape precalculations // require that atom shapes are identical within each type diff --git a/src/ASPHERE/pair_tri_lj.cpp b/src/ASPHERE/pair_tri_lj.cpp index 6ed422f7a4..0cb08c41b3 100644 --- a/src/ASPHERE/pair_tri_lj.cpp +++ b/src/ASPHERE/pair_tri_lj.cpp @@ -470,7 +470,7 @@ void PairTriLJ::init_style() avec = (AtomVecTri *) atom->style_match("tri"); if (!avec) error->all(FLERR,"Pair tri/lj requires atom style tri"); - neighbor->request(this,instance_me); + neighbor->add_request(this,NeighConst::REQ_DEFAULT); } /* ---------------------------------------------------------------------- diff --git a/src/ATC/fix_atc.cpp b/src/ATC/fix_atc.cpp index e6be648c86..a7c0cf5ade 100644 --- a/src/ATC/fix_atc.cpp +++ b/src/ATC/fix_atc.cpp @@ -18,7 +18,6 @@ #include "comm.h" #include "error.h" #include "group.h" -#include "neigh_request.h" #include "neighbor.h" #include "ATC_Method.h" @@ -558,11 +557,7 @@ int FixATC::modify_param(int narg, char** arg) void FixATC::init() { // Guarantee construction of full neighborlist - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); // create computes, if necessary atc_->init_computes(); diff --git a/src/AWPMD/pair_awpmd_cut.cpp b/src/AWPMD/pair_awpmd_cut.cpp index 15cd316f12..0c95801421 100644 --- a/src/AWPMD/pair_awpmd_cut.cpp +++ b/src/AWPMD/pair_awpmd_cut.cpp @@ -26,7 +26,6 @@ #include "memory.h" #include "min.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -513,45 +512,18 @@ void PairAWPMDCut::init_style() if (!atom->q_flag || !atom->spin_flag || !atom->eradius_flag || !atom->erforce_flag ) // TO DO: adjust this to match approximation used - error->all(FLERR,"Pair awpmd/cut requires atom attributes " - "q, spin, eradius, erforce"); - - /* - if (vflag_atom) { // can't compute virial per atom - //warning-> - error->all(FLERR,"Pair style awpmd can't compute per atom virials"); - }*/ + error->all(FLERR,"Pair awpmd/cut requires atom attributes q, spin, eradius, erforce"); // add hook to minimizer for eradius and erforce if (update->whichflag == 2) int ignore = update->minimize->request(this,1,0.01); - // make sure to use the appropriate timestep when using real units - - /*if (update->whichflag == 1) { - if (force->qqr2e == 332.06371 && update->dt == 1.0) - error->all(FLERR,"You must lower the default real units timestep for pEFF "); - }*/ - - // need a half neigh list and optionally a granular history neigh list - - //int irequest = neighbor->request(this,instance_me); - - //if (atom->tag_enable == 0) - // error->all(FLERR,"Pair style reax requires atom IDs"); - - //if (force->newton_pair == 0) - //error->all(FLERR,"Pair style awpmd requires newton pair on"); - - //if (strcmp(update->unit_style,"real") != 0 && comm->me == 0) - //error->warning(FLERR,"Not using real units with pair reax"); - - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->newton = 2; + neighbor->add_request(this, NeighConst::REQ_NEWTON_OFF); if (force->e_mass==0. || force->hhmrr2e==0. || force->mvh2r==0.) - error->all(FLERR,"Pair style awpmd requires e_mass and conversions hhmrr2e, mvh2r to be properly set for unit system"); + error->all(FLERR,"Pair style awpmd requires e_mass and conversions " + "hhmrr2e, mvh2r to be properly set for unit system"); wpmd->me=force->e_mass; wpmd->h2_me=force->hhmrr2e/force->e_mass; diff --git a/src/BODY/pair_body_nparticle.cpp b/src/BODY/pair_body_nparticle.cpp index c3e146aff0..e893350c3e 100644 --- a/src/BODY/pair_body_nparticle.cpp +++ b/src/BODY/pair_body_nparticle.cpp @@ -422,7 +422,7 @@ void PairBodyNparticle::init_style() error->all(FLERR,"Pair body/nparticle requires body style nparticle"); bptr = (BodyNparticle *) avec->bptr; - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/BODY/pair_body_rounded_polygon.cpp b/src/BODY/pair_body_rounded_polygon.cpp index 14f305e7d4..aa3a86a821 100644 --- a/src/BODY/pair_body_rounded_polygon.cpp +++ b/src/BODY/pair_body_rounded_polygon.cpp @@ -427,7 +427,7 @@ void PairBodyRoundedPolygon::init_style() error->all(FLERR,"Pair body/rounded/polygon requires " "ghost atoms store velocity"); - neighbor->request(this); + neighbor->add_request(this); // find the maximum enclosing radius for each atom type diff --git a/src/BODY/pair_body_rounded_polyhedron.cpp b/src/BODY/pair_body_rounded_polyhedron.cpp index 6deb06aafb..8136e82fd8 100644 --- a/src/BODY/pair_body_rounded_polyhedron.cpp +++ b/src/BODY/pair_body_rounded_polyhedron.cpp @@ -406,7 +406,7 @@ void PairBodyRoundedPolyhedron::init_style() error->all(FLERR,"Pair body/rounded/polyhedron requires " "ghost atoms store velocity"); - neighbor->request(this); + neighbor->add_request(this); // find the maximum enclosing radius for each atom type diff --git a/src/CG-SDK/pair_lj_sdk_coul_long.cpp b/src/CG-SDK/pair_lj_sdk_coul_long.cpp index 0fd0d2d30a..e1d79789b8 100644 --- a/src/CG-SDK/pair_lj_sdk_coul_long.cpp +++ b/src/CG-SDK/pair_lj_sdk_coul_long.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -19,17 +18,17 @@ #include "pair_lj_sdk_coul_long.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" -#include "neigh_list.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include #define LMP_NEED_SDK_FIND_LJ_TYPE 1 #include "lj_sdk_common.h" @@ -37,13 +36,13 @@ using namespace LAMMPS_NS; using namespace LJSDKParms; -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 /* ---------------------------------------------------------------------- */ @@ -86,19 +85,25 @@ PairLJSDKCoulLong::~PairLJSDKCoulLong() void PairLJSDKCoulLong::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); if (evflag) { if (eflag) { - if (force->newton_pair) eval<1,1,1>(); - else eval<1,1,0>(); + if (force->newton_pair) + eval<1, 1, 1>(); + else + eval<1, 1, 0>(); } else { - if (force->newton_pair) eval<1,0,1>(); - else eval<1,0,0>(); + if (force->newton_pair) + eval<1, 0, 1>(); + else + eval<1, 0, 0>(); } } else { - if (force->newton_pair) eval<0,0,1>(); - else eval<0,0,0>(); + if (force->newton_pair) + eval<0, 0, 1>(); + else + eval<0, 0, 0>(); } if (vflag_fdotr) virial_fdotr_compute(); @@ -106,29 +111,28 @@ void PairLJSDKCoulLong::compute(int eflag, int vflag) /* ---------------------------------------------------------------------- */ -template -void PairLJSDKCoulLong::eval() +template void PairLJSDKCoulLong::eval() { - int i,ii,j,jj,jtype,itable; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double fraction,table; - double r,rsq,r2inv,forcecoul,forcelj,factor_coul,factor_lj; - double grij,expm2,prefactor,t,erfc; + int i, ii, j, jj, jtype, itable; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double fraction, table; + double r, rsq, r2inv, forcecoul, forcelj, factor_coul, factor_lj; + double grij, expm2, prefactor, t, erfc; - const double * const * const x = atom->x; - double * const * const f = atom->f; - const double * const q = atom->q; - const int * const type = atom->type; + const double *const *const x = atom->x; + double *const *const f = atom->f; + const double *const q = atom->q; + const int *const type = atom->type; const int nlocal = atom->nlocal; - const double * const special_coul = force->special_coul; - const double * const special_lj = force->special_lj; + const double *const special_coul = force->special_coul; + const double *const special_lj = force->special_lj; const double qqrd2e = force->qqrd2e; - double fxtmp,fytmp,fztmp; + double fxtmp, fytmp, fztmp; const int inum = list->inum; - const int * const ilist = list->ilist; - const int * const numneigh = list->numneigh; - const int * const * const firstneigh = list->firstneigh; + const int *const ilist = list->ilist; + const int *const numneigh = list->numneigh; + const int *const *const firstneigh = list->firstneigh; // loop over neighbors of my atoms @@ -139,10 +143,10 @@ void PairLJSDKCoulLong::eval() xtmp = x[i][0]; ytmp = x[i][1]; ztmp = x[i][2]; - fxtmp=fytmp=fztmp=0.0; + fxtmp = fytmp = fztmp = 0.0; const int itype = type[i]; - const int * const jlist = firstneigh[i]; + const int *const jlist = firstneigh[i]; const int jnum = numneigh[i]; for (jj = 0; jj < jnum; jj++) { @@ -156,26 +160,26 @@ void PairLJSDKCoulLong::eval() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; const int ljt = lj_type[itype][jtype]; if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (EFLAG) ecoul = prefactor*erfc; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (EFLAG) ecoul = prefactor * erfc; if (factor_coul < 1.0) { - forcecoul -= (1.0-factor_coul)*prefactor; - if (EFLAG) ecoul -= (1.0-factor_coul)*prefactor; + forcecoul -= (1.0 - factor_coul) * prefactor; + if (EFLAG) ecoul -= (1.0 - factor_coul) * prefactor; } } else { union_int_float_t rsq_lookup; @@ -183,15 +187,14 @@ void PairLJSDKCoulLong::eval() itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = qtmp*q[j] * table; - if (EFLAG) ecoul = qtmp*q[j] * - (etable[itable] + fraction*detable[itable]); + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = qtmp * q[j] * table; + if (EFLAG) ecoul = qtmp * q[j] * (etable[itable] + fraction * detable[itable]); if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = qtmp*q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; - if (EFLAG) ecoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = qtmp * q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; + if (EFLAG) ecoul -= (1.0 - factor_coul) * prefactor; } } } @@ -199,30 +202,27 @@ void PairLJSDKCoulLong::eval() if (rsq < cut_ljsq[itype][jtype]) { if (ljt == LJ12_4) { - const double r4inv=r2inv*r2inv; - forcelj = r4inv*(lj1[itype][jtype]*r4inv*r4inv - - lj2[itype][jtype]); + const double r4inv = r2inv * r2inv; + forcelj = r4inv * (lj1[itype][jtype] * r4inv * r4inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r4inv*(lj3[itype][jtype]*r4inv*r4inv - - lj4[itype][jtype]) - offset[itype][jtype]; + evdwl = r4inv * (lj3[itype][jtype] * r4inv * r4inv - lj4[itype][jtype]) - + offset[itype][jtype]; } else if (ljt == LJ9_6) { - const double r3inv = r2inv*sqrt(r2inv); - const double r6inv = r3inv*r3inv; - forcelj = r6inv*(lj1[itype][jtype]*r3inv - - lj2[itype][jtype]); + const double r3inv = r2inv * sqrt(r2inv); + const double r6inv = r3inv * r3inv; + forcelj = r6inv * (lj1[itype][jtype] * r3inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r6inv*(lj3[itype][jtype]*r3inv - - lj4[itype][jtype]) - offset[itype][jtype]; + evdwl = + r6inv * (lj3[itype][jtype] * r3inv - lj4[itype][jtype]) - offset[itype][jtype]; } else if (ljt == LJ12_6) { - const double r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv*(lj1[itype][jtype]*r6inv - - lj2[itype][jtype]); + const double r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r6inv*(lj3[itype][jtype]*r6inv - - lj4[itype][jtype]) - offset[itype][jtype]; + evdwl = + r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; } forcelj *= factor_lj; if (EFLAG) evdwl *= factor_lj; @@ -230,17 +230,16 @@ void PairLJSDKCoulLong::eval() fpair = (forcecoul + forcelj) * r2inv; - fxtmp += delx*fpair; - fytmp += dely*fpair; - fztmp += delz*fpair; + fxtmp += delx * fpair; + fytmp += dely * fpair; + fztmp += delz * fpair; if (NEWTON_PAIR || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } - if (EVFLAG) ev_tally(i,j,nlocal,NEWTON_PAIR, - evdwl,ecoul,fpair,delx,dely,delz); + if (EVFLAG) ev_tally(i, j, nlocal, NEWTON_PAIR, evdwl, ecoul, fpair, delx, dely, delz); } } f[i][0] += fxtmp; @@ -249,7 +248,6 @@ void PairLJSDKCoulLong::eval() } } - /* ---------------------------------------------------------------------- allocate all arrays ------------------------------------------------------------------------- */ @@ -257,33 +255,33 @@ void PairLJSDKCoulLong::eval() void PairLJSDKCoulLong::allocate() { allocated = 1; - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); - memory->create(lj_type,n+1,n+1,"pair:lj_type"); - for (int i = 1; i <= n; i++) { - for (int j = i; j <= n; j++) { + memory->create(setflag, np1, np1, "pair:setflag"); + memory->create(lj_type, np1, np1, "pair:lj_type"); + for (int i = 1; i < np1; i++) { + for (int j = i; j < np1; j++) { setflag[i][j] = 0; lj_type[i][j] = LJ_NOT_SET; } } - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, np1, np1, "pair:cutsq"); - memory->create(cut_lj,n+1,n+1,"pair:cut_lj"); - memory->create(cut_ljsq,n+1,n+1,"pair:cut_ljsq"); - memory->create(epsilon,n+1,n+1,"pair:epsilon"); - memory->create(sigma,n+1,n+1,"pair:sigma"); + memory->create(cut_lj, np1, np1, "pair:cut_lj"); + memory->create(cut_ljsq, np1, np1, "pair:cut_ljsq"); + memory->create(epsilon, np1, np1, "pair:epsilon"); + memory->create(sigma, np1, np1, "pair:sigma"); - memory->create(lj1,n+1,n+1,"pair:lj1"); - memory->create(lj2,n+1,n+1,"pair:lj2"); - memory->create(lj3,n+1,n+1,"pair:lj3"); - memory->create(lj4,n+1,n+1,"pair:lj4"); + memory->create(lj1, np1, np1, "pair:lj1"); + memory->create(lj2, np1, np1, "pair:lj2"); + memory->create(lj3, np1, np1, "pair:lj3"); + memory->create(lj4, np1, np1, "pair:lj4"); - memory->create(offset,n+1,n+1,"pair:offset"); + memory->create(offset, np1, np1, "pair:offset"); - memory->create(rminsq,n+1,n+1,"pair:rminsq"); - memory->create(emin,n+1,n+1,"pair:emin"); + memory->create(rminsq, np1, np1, "pair:rminsq"); + memory->create(emin, np1, np1, "pair:emin"); } /* ---------------------------------------------------------------------- @@ -292,16 +290,18 @@ void PairLJSDKCoulLong::allocate() void PairLJSDKCoulLong::settings(int narg, char **arg) { - if (narg < 1 || narg > 2) error->all(FLERR,"Illegal pair_style command"); + if (narg < 1 || narg > 2) error->all(FLERR, "Illegal pair_style command"); - cut_lj_global = utils::numeric(FLERR,arg[0],false,lmp); - if (narg == 1) cut_coul = cut_lj_global; - else cut_coul = utils::numeric(FLERR,arg[1],false,lmp); + cut_lj_global = utils::numeric(FLERR, arg[0], false, lmp); + if (narg == 1) + cut_coul = cut_lj_global; + else + cut_coul = utils::numeric(FLERR, arg[1], false, lmp); // reset cutoffs that have been explicitly set if (allocated) { - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) if (setflag[i][j]) cut_lj[i][j] = cut_lj_global; @@ -314,27 +314,25 @@ void PairLJSDKCoulLong::settings(int narg, char **arg) void PairLJSDKCoulLong::coeff(int narg, char **arg) { - if (narg < 5 || narg > 6) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg < 5 || narg > 6) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); - int lj_type_one = find_lj_type(arg[2],lj_type_list); - if (lj_type_one == LJ_NOT_SET) - error->all(FLERR,"Cannot parse LJ type flag."); + int lj_type_one = find_lj_type(arg[2], lj_type_list); + if (lj_type_one == LJ_NOT_SET) error->all(FLERR, "Cannot parse LJ type flag."); - double epsilon_one = utils::numeric(FLERR,arg[3],false,lmp); - double sigma_one = utils::numeric(FLERR,arg[4],false,lmp); + double epsilon_one = utils::numeric(FLERR, arg[3], false, lmp); + double sigma_one = utils::numeric(FLERR, arg[4], false, lmp); double cut_lj_one = cut_lj_global; - if (narg == 6) cut_lj_one = utils::numeric(FLERR,arg[5],false,lmp); + if (narg == 6) cut_lj_one = utils::numeric(FLERR, arg[5], false, lmp); int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { lj_type[i][j] = lj_type_one; epsilon[i][j] = epsilon_one; sigma[i][j] = sigma_one; @@ -344,7 +342,7 @@ void PairLJSDKCoulLong::coeff(int narg, char **arg) } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -353,22 +351,20 @@ void PairLJSDKCoulLong::coeff(int narg, char **arg) void PairLJSDKCoulLong::init_style() { - if (!atom->q_flag) - error->all(FLERR,"Pair style lj/cut/coul/long requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/coul/long requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables (no rRESPA support yet) - if (ncoultablebits) init_tables(cut_coul,nullptr); + if (ncoultablebits) init_tables(cut_coul, nullptr); } /* ---------------------------------------------------------------------- @@ -378,29 +374,28 @@ void PairLJSDKCoulLong::init_style() double PairLJSDKCoulLong::init_one(int i, int j) { if (setflag[i][j] == 0) - error->all(FLERR,"No mixing support for lj/sdk/coul/long. " + error->all(FLERR, + "No mixing support for lj/sdk/coul/long. " "Coefficients for all pairs need to be set explicitly."); const int ljt = lj_type[i][j]; - if (ljt == LJ_NOT_SET) - error->all(FLERR,"unrecognized LJ parameter flag"); + if (ljt == LJ_NOT_SET) error->all(FLERR, "unrecognized LJ parameter flag"); - double cut = MAX(cut_lj[i][j],cut_coul); + double cut = MAX(cut_lj[i][j], cut_coul); cut_ljsq[i][j] = cut_lj[i][j] * cut_lj[i][j]; - lj1[i][j] = lj_prefact[ljt] * lj_pow1[ljt] * epsilon[i][j] * - pow(sigma[i][j],lj_pow1[ljt]); - lj2[i][j] = lj_prefact[ljt] * lj_pow2[ljt] * epsilon[i][j] * - pow(sigma[i][j],lj_pow2[ljt]); - lj3[i][j] = lj_prefact[ljt] * epsilon[i][j] * pow(sigma[i][j],lj_pow1[ljt]); - lj4[i][j] = lj_prefact[ljt] * epsilon[i][j] * pow(sigma[i][j],lj_pow2[ljt]); + lj1[i][j] = lj_prefact[ljt] * lj_pow1[ljt] * epsilon[i][j] * pow(sigma[i][j], lj_pow1[ljt]); + lj2[i][j] = lj_prefact[ljt] * lj_pow2[ljt] * epsilon[i][j] * pow(sigma[i][j], lj_pow2[ljt]); + lj3[i][j] = lj_prefact[ljt] * epsilon[i][j] * pow(sigma[i][j], lj_pow1[ljt]); + lj4[i][j] = lj_prefact[ljt] * epsilon[i][j] * pow(sigma[i][j], lj_pow2[ljt]); if (offset_flag && (cut_lj[i][j] > 0.0)) { double ratio = sigma[i][j] / cut_lj[i][j]; - offset[i][j] = lj_prefact[ljt] * epsilon[i][j] * - (pow(ratio,lj_pow1[ljt]) - pow(ratio,lj_pow2[ljt])); - } else offset[i][j] = 0.0; + offset[i][j] = + lj_prefact[ljt] * epsilon[i][j] * (pow(ratio, lj_pow1[ljt]) - pow(ratio, lj_pow2[ljt])); + } else + offset[i][j] = 0.0; cut_ljsq[j][i] = cut_ljsq[i][j]; cut_lj[j][i] = cut_lj[i][j]; @@ -415,20 +410,19 @@ double PairLJSDKCoulLong::init_one(int i, int j) const double eps = epsilon[i][j]; const double sig = sigma[i][j]; - const double rmin = sig*exp(1.0/(lj_pow1[ljt]-lj_pow2[ljt]) - *log(lj_pow1[ljt]/lj_pow2[ljt]) ); - rminsq[j][i] = rminsq[i][j] = rmin*rmin; + const double rmin = + sig * exp(1.0 / (lj_pow1[ljt] - lj_pow2[ljt]) * log(lj_pow1[ljt] / lj_pow2[ljt])); + rminsq[j][i] = rminsq[i][j] = rmin * rmin; - const double ratio = sig/rmin; - const double emin_one = lj_prefact[ljt] * eps * (pow(ratio,lj_pow1[ljt]) - - pow(ratio,lj_pow2[ljt])); + const double ratio = sig / rmin; + const double emin_one = + lj_prefact[ljt] * eps * (pow(ratio, lj_pow1[ljt]) - pow(ratio, lj_pow2[ljt])); emin[j][i] = emin[i][j] = emin_one; // compute I,J contribution to long-range tail correction // count total # of atoms of type I and J via Allreduce - if (tail_flag) - error->all(FLERR,"Tail flag not supported by lj/sdk/coul/long pair style"); + if (tail_flag) error->all(FLERR, "Tail flag not supported by lj/sdk/coul/long pair style"); return cut; } @@ -441,15 +435,15 @@ void PairLJSDKCoulLong::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - fwrite(&setflag[i][j],sizeof(int),1,fp); + fwrite(&setflag[i][j], sizeof(int), 1, fp); if (setflag[i][j]) { - fwrite(&lj_type[i][j],sizeof(int),1,fp); - fwrite(&epsilon[i][j],sizeof(double),1,fp); - fwrite(&sigma[i][j],sizeof(double),1,fp); - fwrite(&cut_lj[i][j],sizeof(double),1,fp); + fwrite(&lj_type[i][j], sizeof(int), 1, fp); + fwrite(&epsilon[i][j], sizeof(double), 1, fp); + fwrite(&sigma[i][j], sizeof(double), 1, fp); + fwrite(&cut_lj[i][j], sizeof(double), 1, fp); } } } @@ -463,23 +457,23 @@ void PairLJSDKCoulLong::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); if (setflag[i][j]) { if (me == 0) { - utils::sfread(FLERR,&lj_type[i][j],sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&epsilon[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&sigma[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_lj[i][j],sizeof(double),1,fp,nullptr,error); + utils::sfread(FLERR, &lj_type[i][j], sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &epsilon[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &sigma[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_lj[i][j], sizeof(double), 1, fp, nullptr, error); } - MPI_Bcast(&lj_type[i][j],1,MPI_INT,0,world); - MPI_Bcast(&epsilon[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&sigma[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_lj[i][j],1,MPI_DOUBLE,0,world); + MPI_Bcast(&lj_type[i][j], 1, MPI_INT, 0, world); + MPI_Bcast(&epsilon[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&sigma[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_lj[i][j], 1, MPI_DOUBLE, 0, world); } } } @@ -490,13 +484,13 @@ void PairLJSDKCoulLong::read_restart(FILE *fp) void PairLJSDKCoulLong::write_restart_settings(FILE *fp) { - fwrite(&cut_lj_global,sizeof(double),1,fp); - fwrite(&cut_coul,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); - fwrite(&tail_flag,sizeof(int),1,fp); - fwrite(&ncoultablebits,sizeof(int),1,fp); - fwrite(&tabinner,sizeof(double),1,fp); + fwrite(&cut_lj_global, sizeof(double), 1, fp); + fwrite(&cut_coul, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); + fwrite(&tail_flag, sizeof(int), 1, fp); + fwrite(&ncoultablebits, sizeof(int), 1, fp); + fwrite(&tabinner, sizeof(double), 1, fp); } /* ---------------------------------------------------------------------- @@ -506,21 +500,21 @@ void PairLJSDKCoulLong::write_restart_settings(FILE *fp) void PairLJSDKCoulLong::read_restart_settings(FILE *fp) { if (comm->me == 0) { - utils::sfread(FLERR,&cut_lj_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&tail_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&ncoultablebits,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&tabinner,sizeof(double),1,fp,nullptr,error); + utils::sfread(FLERR, &cut_lj_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &tail_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &ncoultablebits, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &tabinner, sizeof(double), 1, fp, nullptr, error); } - MPI_Bcast(&cut_lj_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); - MPI_Bcast(&tail_flag,1,MPI_INT,0,world); - MPI_Bcast(&ncoultablebits,1,MPI_INT,0,world); - MPI_Bcast(&tabinner,1,MPI_DOUBLE,0,world); + MPI_Bcast(&cut_lj_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&tail_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&ncoultablebits, 1, MPI_INT, 0, world); + MPI_Bcast(&tabinner, 1, MPI_DOUBLE, 0, world); } /* ---------------------------------------------------------------------- @@ -529,7 +523,8 @@ void PairLJSDKCoulLong::read_restart_settings(FILE *fp) void PairLJSDKCoulLong::write_data(FILE *) { - error->one(FLERR, "Pair style lj/sdk/coul/* requires using " + error->one(FLERR, + "Pair style lj/sdk/coul/* requires using " "write_data with the 'pair ij' option"); } @@ -541,37 +536,35 @@ void PairLJSDKCoulLong::write_data_all(FILE *fp) { for (int i = 1; i <= atom->ntypes; i++) for (int j = i; j <= atom->ntypes; j++) - fprintf(fp,"%d %d %s %g %g %g\n",i,j,lj_type_list[lj_type[i][j]], - epsilon[i][j],sigma[i][j],cut_lj[i][j]); + fprintf(fp, "%d %d %s %g %g %g\n", i, j, lj_type_list[lj_type[i][j]], epsilon[i][j], + sigma[i][j], cut_lj[i][j]); } /* ---------------------------------------------------------------------- */ -double PairLJSDKCoulLong::single(int i, int j, int itype, int jtype, - double rsq, - double factor_coul, double factor_lj, - double &fforce) +double PairLJSDKCoulLong::single(int i, int j, int itype, int jtype, double rsq, double factor_coul, + double factor_lj, double &fforce) { - double r2inv,r,grij,expm2,t,erfc,prefactor; - double fraction,table,forcecoul,forcelj,phicoul,philj; + double r2inv, r, grij, expm2, t, erfc, prefactor; + double fraction, table, forcecoul, forcelj, phicoul, philj; int itable; forcecoul = forcelj = phicoul = philj = 0.0; - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = force->qqrd2e * atom->q[i]*atom->q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - phicoul = prefactor*erfc; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = force->qqrd2e * atom->q[i] * atom->q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + phicoul = prefactor * erfc; if (factor_coul < 1.0) { - forcecoul -= (1.0-factor_coul)*prefactor; - phicoul -= (1.0-factor_coul)*prefactor; + forcecoul -= (1.0 - factor_coul) * prefactor; + phicoul -= (1.0 - factor_coul) * prefactor; } } else { union_int_float_t rsq_lookup_single; @@ -579,15 +572,15 @@ double PairLJSDKCoulLong::single(int i, int j, int itype, int jtype, itable = rsq_lookup_single.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup_single.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = atom->q[i]*atom->q[j] * table; - table = etable[itable] + fraction*detable[itable]; - phicoul = atom->q[i]*atom->q[j] * table; + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = atom->q[i] * atom->q[j] * table; + table = etable[itable] + fraction * detable[itable]; + phicoul = atom->q[i] * atom->q[j] * table; if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = atom->q[i]*atom->q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; - phicoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = atom->q[i] * atom->q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; + phicoul -= (1.0 - factor_coul) * prefactor; } } } @@ -596,27 +589,22 @@ double PairLJSDKCoulLong::single(int i, int j, int itype, int jtype, const int ljt = lj_type[itype][jtype]; if (ljt == LJ12_4) { - const double r4inv=r2inv*r2inv; - forcelj = r4inv*(lj1[itype][jtype]*r4inv*r4inv - - lj2[itype][jtype]); + const double r4inv = r2inv * r2inv; + forcelj = r4inv * (lj1[itype][jtype] * r4inv * r4inv - lj2[itype][jtype]); - philj = r4inv*(lj3[itype][jtype]*r4inv*r4inv - - lj4[itype][jtype]) - offset[itype][jtype]; + philj = + r4inv * (lj3[itype][jtype] * r4inv * r4inv - lj4[itype][jtype]) - offset[itype][jtype]; } else if (ljt == LJ9_6) { - const double r3inv = r2inv*sqrt(r2inv); - const double r6inv = r3inv*r3inv; - forcelj = r6inv*(lj1[itype][jtype]*r3inv - - lj2[itype][jtype]); - philj = r6inv*(lj3[itype][jtype]*r3inv - - lj4[itype][jtype]) - offset[itype][jtype]; + const double r3inv = r2inv * sqrt(r2inv); + const double r6inv = r3inv * r3inv; + forcelj = r6inv * (lj1[itype][jtype] * r3inv - lj2[itype][jtype]); + philj = r6inv * (lj3[itype][jtype] * r3inv - lj4[itype][jtype]) - offset[itype][jtype]; } else if (ljt == LJ12_6) { - const double r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv*(lj1[itype][jtype]*r6inv - - lj2[itype][jtype]); - philj = r6inv*(lj3[itype][jtype]*r6inv - - lj4[itype][jtype]) - offset[itype][jtype]; + const double r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + philj = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; } forcelj *= factor_lj; philj *= factor_lj; @@ -632,18 +620,18 @@ double PairLJSDKCoulLong::single(int i, int j, int itype, int jtype, void *PairLJSDKCoulLong::extract(const char *str, int &dim) { dim = 2; - if (strcmp(str,"epsilon") == 0) return (void *) epsilon; - if (strcmp(str,"sigma") == 0) return (void *) sigma; - if (strcmp(str,"lj_type") == 0) return (void *) lj_type; - if (strcmp(str,"lj1") == 0) return (void *) lj1; - if (strcmp(str,"lj2") == 0) return (void *) lj2; - if (strcmp(str,"lj3") == 0) return (void *) lj3; - if (strcmp(str,"lj4") == 0) return (void *) lj4; - if (strcmp(str,"rminsq") == 0) return (void *) rminsq; - if (strcmp(str,"emin") == 0) return (void *) emin; + if (strcmp(str, "epsilon") == 0) return (void *) epsilon; + if (strcmp(str, "sigma") == 0) return (void *) sigma; + if (strcmp(str, "lj_type") == 0) return (void *) lj_type; + if (strcmp(str, "lj1") == 0) return (void *) lj1; + if (strcmp(str, "lj2") == 0) return (void *) lj2; + if (strcmp(str, "lj3") == 0) return (void *) lj3; + if (strcmp(str, "lj4") == 0) return (void *) lj4; + if (strcmp(str, "rminsq") == 0) return (void *) rminsq; + if (strcmp(str, "emin") == 0) return (void *) emin; dim = 0; - if (strcmp(str,"cut_coul") == 0) return (void *) &cut_coul; + if (strcmp(str, "cut_coul") == 0) return (void *) &cut_coul; return nullptr; } @@ -655,13 +643,13 @@ double PairLJSDKCoulLong::memory_usage() int n = atom->ntypes; // setflag/lj_type - bytes += (double)2 * (n+1)*(n+1)*sizeof(int); + bytes += (double) 2 * (n + 1) * (n + 1) * sizeof(int); // lj_cut/lj_cutsq/epsilon/sigma/offset/lj1/lj2/lj3/lj4/rminsq/emin - bytes += (double)11 * (n+1)*(n+1)*sizeof(double); + bytes += (double) 11 * (n + 1) * (n + 1) * sizeof(double); if (ncoultablebits) { - int ntable = 1<whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this, instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); // set rRESPA cutoffs diff --git a/src/CLASS2/pair_lj_class2_coul_cut.cpp b/src/CLASS2/pair_lj_class2_coul_cut.cpp index 844c979994..c78d9a99e3 100644 --- a/src/CLASS2/pair_lj_class2_coul_cut.cpp +++ b/src/CLASS2/pair_lj_class2_coul_cut.cpp @@ -259,7 +259,7 @@ void PairLJClass2CoulCut::init_style() { if (!atom->q_flag) error->all(FLERR, "Pair style lj/class2/coul/cut requires atom attribute q"); - neighbor->request(this, instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/CLASS2/pair_lj_class2_coul_long.cpp b/src/CLASS2/pair_lj_class2_coul_long.cpp index 79773d6408..1b1cc9c5a9 100644 --- a/src/CLASS2/pair_lj_class2_coul_long.cpp +++ b/src/CLASS2/pair_lj_class2_coul_long.cpp @@ -21,7 +21,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "respa.h" #include "update.h" @@ -670,21 +669,14 @@ void PairLJClass2CoulLong::init_style() // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this, instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); cut_coulsq = cut_coul * cut_coul; diff --git a/src/COLLOID/pair_brownian.cpp b/src/COLLOID/pair_brownian.cpp index 0640ae3e73..5782586654 100644 --- a/src/COLLOID/pair_brownian.cpp +++ b/src/COLLOID/pair_brownian.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -18,26 +17,26 @@ #include "pair_brownian.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "domain.h" -#include "update.h" -#include "modify.h" +#include "error.h" #include "fix.h" #include "fix_wall.h" +#include "force.h" #include "input.h" -#include "variable.h" -#include "random_mars.h" #include "math_const.h" #include "math_special.h" #include "memory.h" -#include "error.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "random_mars.h" +#include "update.h" +#include "variable.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -45,7 +44,7 @@ using namespace MathSpecial; // same as fix_wall.cpp -enum{EDGE,CONSTANT,VARIABLE}; +enum { EDGE, CONSTANT, VARIABLE }; /* ---------------------------------------------------------------------- */ @@ -73,12 +72,12 @@ PairBrownian::~PairBrownian() void PairBrownian::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,fx,fy,fz,tx,ty,tz; - double rsq,r,h_sep,radi; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, fx, fy, fz, tx, ty, tz; + double rsq, r, h_sep, radi; + int *ilist, *jlist, *numneigh, **firstneigh; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -91,19 +90,18 @@ void PairBrownian::compute(int eflag, int vflag) double vxmu2f = force->vxmu2f; double randr; double prethermostat; - double xl[3],a_sq,a_sh,a_pu,Fbmag; - double p1[3],p2[3],p3[3]; + double xl[3], a_sq, a_sh, a_pu, Fbmag; + double p1[3], p2[3], p3[3]; int overlaps = 0; // This section of code adjusts R0/RT0/RS0 if necessary due to changes // in the volume fraction as a result of fix deform or moving walls double dims[3], wallcoord; - if (flagVF) // Flag for volume fraction corrections - if (flagdeform || flagwall == 2) { // Possible changes in volume fraction + if (flagVF) // Flag for volume fraction corrections + if (flagdeform || flagwall == 2) { // Possible changes in volume fraction if (flagdeform && !flagwall) - for (j = 0; j < 3; j++) - dims[j] = domain->prd[j]; + for (j = 0; j < 3; j++) dims[j] = domain->prd[j]; else if (flagwall == 2 || (flagdeform && flagwall == 1)) { double wallhi[3], walllo[3]; for (int j = 0; j < 3; j++) { @@ -115,31 +113,32 @@ void PairBrownian::compute(int eflag, int vflag) int side = wallfix->wallwhich[m] % 2; if (wallfix->xstyle[m] == VARIABLE) { wallcoord = input->variable->compute_equal(wallfix->xindex[m]); - } - else wallcoord = wallfix->coord0[m]; - if (side == 0) walllo[dim] = wallcoord; - else wallhi[dim] = wallcoord; + } else + wallcoord = wallfix->coord0[m]; + if (side == 0) + walllo[dim] = wallcoord; + else + wallhi[dim] = wallcoord; } - for (int j = 0; j < 3; j++) - dims[j] = wallhi[j] - walllo[j]; + for (int j = 0; j < 3; j++) dims[j] = wallhi[j] - walllo[j]; } - double vol_T = dims[0]*dims[1]*dims[2]; - double vol_f = vol_P/vol_T; + double vol_T = dims[0] * dims[1] * dims[2]; + double vol_f = vol_P / vol_T; if (flaglog == 0) { - R0 = 6*MY_PI*mu*rad*(1.0 + 2.16*vol_f); - RT0 = 8*MY_PI*mu*cube(rad); + R0 = 6 * MY_PI * mu * rad * (1.0 + 2.16 * vol_f); + RT0 = 8 * MY_PI * mu * cube(rad); //RS0 = 20.0/3.0*MY_PI*mu*pow(rad,3)*(1.0 + 3.33*vol_f + 2.80*vol_f*vol_f); } else { - R0 = 6*MY_PI*mu*rad*(1.0 + 2.725*vol_f - 6.583*vol_f*vol_f); - RT0 = 8*MY_PI*mu*cube(rad)*(1.0 + 0.749*vol_f - 2.469*vol_f*vol_f); + R0 = 6 * MY_PI * mu * rad * (1.0 + 2.725 * vol_f - 6.583 * vol_f * vol_f); + RT0 = 8 * MY_PI * mu * cube(rad) * (1.0 + 0.749 * vol_f - 2.469 * vol_f * vol_f); //RS0 = 20.0/3.0*MY_PI*mu*pow(rad,3)*(1.0 + 3.64*vol_f - 6.95*vol_f*vol_f); } } // scale factor for Brownian moments - prethermostat = sqrt(24.0*force->boltz*t_target/update->dt); - prethermostat *= sqrt(force->vxmu2f/force->ftm2v/force->mvv2e); + prethermostat = sqrt(24.0 * force->boltz * t_target / update->dt); + prethermostat *= sqrt(force->vxmu2f / force->ftm2v / force->mvv2e); inum = list->inum; ilist = list->ilist; @@ -159,13 +158,13 @@ void PairBrownian::compute(int eflag, int vflag) // FLD contribution to force and torque due to isotropic terms if (flagfld) { - f[i][0] += prethermostat*sqrt(R0)*(random->uniform()-0.5); - f[i][1] += prethermostat*sqrt(R0)*(random->uniform()-0.5); - f[i][2] += prethermostat*sqrt(R0)*(random->uniform()-0.5); + f[i][0] += prethermostat * sqrt(R0) * (random->uniform() - 0.5); + f[i][1] += prethermostat * sqrt(R0) * (random->uniform() - 0.5); + f[i][2] += prethermostat * sqrt(R0) * (random->uniform() - 0.5); if (flaglog) { - torque[i][0] += prethermostat*sqrt(RT0)*(random->uniform()-0.5); - torque[i][1] += prethermostat*sqrt(RT0)*(random->uniform()-0.5); - torque[i][2] += prethermostat*sqrt(RT0)*(random->uniform()-0.5); + torque[i][0] += prethermostat * sqrt(RT0) * (random->uniform() - 0.5); + torque[i][1] += prethermostat * sqrt(RT0) * (random->uniform() - 0.5); + torque[i][2] += prethermostat * sqrt(RT0) * (random->uniform() - 0.5); } } @@ -178,7 +177,7 @@ void PairBrownian::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { @@ -186,7 +185,7 @@ void PairBrownian::compute(int eflag, int vflag) // scalar resistances a_sq and a_sh - h_sep = r - 2.0*radi; + h_sep = r - 2.0 * radi; // check for overlaps @@ -194,35 +193,34 @@ void PairBrownian::compute(int eflag, int vflag) // if less than minimum gap, use minimum gap instead - if (r < cut_inner[itype][jtype]) - h_sep = cut_inner[itype][jtype] - 2.0*radi; + if (r < cut_inner[itype][jtype]) h_sep = cut_inner[itype][jtype] - 2.0 * radi; // scale h_sep by radi - h_sep = h_sep/radi; + h_sep = h_sep / radi; // scalar resistances if (flaglog) { - a_sq = 6.0*MY_PI*mu*radi*(1.0/4.0/h_sep + 9.0/40.0*log(1.0/h_sep)); - a_sh = 6.0*MY_PI*mu*radi*(1.0/6.0*log(1.0/h_sep)); - a_pu = 8.0*MY_PI*mu*cube(radi)*(3.0/160.0*log(1.0/h_sep)); + a_sq = 6.0 * MY_PI * mu * radi * (1.0 / 4.0 / h_sep + 9.0 / 40.0 * log(1.0 / h_sep)); + a_sh = 6.0 * MY_PI * mu * radi * (1.0 / 6.0 * log(1.0 / h_sep)); + a_pu = 8.0 * MY_PI * mu * cube(radi) * (3.0 / 160.0 * log(1.0 / h_sep)); } else - a_sq = 6.0*MY_PI*mu*radi*(1.0/4.0/h_sep); + a_sq = 6.0 * MY_PI * mu * radi * (1.0 / 4.0 / h_sep); // generate the Pairwise Brownian Force: a_sq - Fbmag = prethermostat*sqrt(a_sq); + Fbmag = prethermostat * sqrt(a_sq); // generate a random number - randr = random->uniform()-0.5; + randr = random->uniform() - 0.5; // contribution due to Brownian motion - fx = Fbmag*randr*delx/r; - fy = Fbmag*randr*dely/r; - fz = Fbmag*randr*delz/r; + fx = Fbmag * randr * delx / r; + fy = Fbmag * randr * dely / r; + fz = Fbmag * randr * delz / r; // add terms due to a_sh @@ -230,31 +228,33 @@ void PairBrownian::compute(int eflag, int vflag) // generate two orthogonal vectors to the line of centers - p1[0] = delx/r; p1[1] = dely/r; p1[2] = delz/r; - set_3_orthogonal_vectors(p1,p2,p3); + p1[0] = delx / r; + p1[1] = dely / r; + p1[2] = delz / r; + set_3_orthogonal_vectors(p1, p2, p3); // magnitude - Fbmag = prethermostat*sqrt(a_sh); + Fbmag = prethermostat * sqrt(a_sh); // force in each of the two directions - randr = random->uniform()-0.5; - fx += Fbmag*randr*p2[0]; - fy += Fbmag*randr*p2[1]; - fz += Fbmag*randr*p2[2]; + randr = random->uniform() - 0.5; + fx += Fbmag * randr * p2[0]; + fy += Fbmag * randr * p2[1]; + fz += Fbmag * randr * p2[2]; - randr = random->uniform()-0.5; - fx += Fbmag*randr*p3[0]; - fy += Fbmag*randr*p3[1]; - fz += Fbmag*randr*p3[2]; + randr = random->uniform() - 0.5; + fx += Fbmag * randr * p3[0]; + fy += Fbmag * randr * p3[1]; + fz += Fbmag * randr * p3[2]; } // scale forces to appropriate units - fx = vxmu2f*fx; - fy = vxmu2f*fy; - fz = vxmu2f*fz; + fx = vxmu2f * fx; + fy = vxmu2f * fy; + fz = vxmu2f * fz; // sum to total force @@ -279,15 +279,15 @@ void PairBrownian::compute(int eflag, int vflag) // location of the point of closest approach on I from its center - xl[0] = -delx/r*radi; - xl[1] = -dely/r*radi; - xl[2] = -delz/r*radi; + xl[0] = -delx / r * radi; + xl[1] = -dely / r * radi; + xl[2] = -delz / r * radi; // torque = xl_cross_F - tx = xl[1]*fz - xl[2]*fy; - ty = xl[2]*fx - xl[0]*fz; - tz = xl[0]*fy - xl[1]*fx; + tx = xl[1] * fz - xl[2] * fy; + ty = xl[2] * fx - xl[0] * fz; + tz = xl[0] * fy - xl[1] * fx; // torque is same on both particles @@ -303,19 +303,19 @@ void PairBrownian::compute(int eflag, int vflag) // torque due to a_pu - Fbmag = prethermostat*sqrt(a_pu); + Fbmag = prethermostat * sqrt(a_pu); // force in each direction - randr = random->uniform()-0.5; - tx = Fbmag*randr*p2[0]; - ty = Fbmag*randr*p2[1]; - tz = Fbmag*randr*p2[2]; + randr = random->uniform() - 0.5; + tx = Fbmag * randr * p2[0]; + ty = Fbmag * randr * p2[1]; + tz = Fbmag * randr * p2[2]; - randr = random->uniform()-0.5; - tx += Fbmag*randr*p3[0]; - ty += Fbmag*randr*p3[1]; - tz += Fbmag*randr*p3[2]; + randr = random->uniform() - 0.5; + tx += Fbmag * randr * p3[0]; + ty += Fbmag * randr * p3[1]; + tz += Fbmag * randr * p3[2]; // torque has opposite sign on two particles @@ -330,15 +330,14 @@ void PairBrownian::compute(int eflag, int vflag) } } - if (evflag) ev_tally_xyz(i,j,nlocal,newton_pair, - 0.0,0.0,-fx,-fy,-fz,delx,dely,delz); + if (evflag) + ev_tally_xyz(i, j, nlocal, newton_pair, 0.0, 0.0, -fx, -fy, -fz, delx, dely, delz); } } } int print_overlaps = 0; - if (print_overlaps && overlaps) - printf("Number of overlaps=%d\n",overlaps); + if (print_overlaps && overlaps) printf("Number of overlaps=%d\n", overlaps); if (vflag_fdotr) virial_fdotr_compute(); } @@ -350,17 +349,16 @@ void PairBrownian::compute(int eflag, int vflag) void PairBrownian::allocate() { allocated = 1; - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); - for (int i = 1; i <= n; i++) - for (int j = i; j <= n; j++) - setflag[i][j] = 0; + memory->create(setflag, np1, np1, "pair:setflag"); + for (int i = 1; i < np1; i++) + for (int j = i; j < np1; j++) setflag[i][j] = 0; - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, np1, np1, "pair:cutsq"); - memory->create(cut,n+1,n+1,"pair:cut"); - memory->create(cut_inner,n+1,n+1,"pair:cut_inner"); + memory->create(cut, np1, np1, "pair:cut"); + memory->create(cut_inner, np1, np1, "pair:cut_inner"); } /* ---------------------------------------------------------------------- @@ -369,24 +367,25 @@ void PairBrownian::allocate() void PairBrownian::settings(int narg, char **arg) { - if (narg != 7 && narg != 9) error->all(FLERR,"Illegal pair_style command"); + if (narg != 7 && narg != 9) error->all(FLERR, "Illegal pair_style command"); - mu = utils::numeric(FLERR,arg[0],false,lmp); - flaglog = utils::inumeric(FLERR,arg[1],false,lmp); - flagfld = utils::inumeric(FLERR,arg[2],false,lmp); - cut_inner_global = utils::numeric(FLERR,arg[3],false,lmp); - cut_global = utils::numeric(FLERR,arg[4],false,lmp); - t_target = utils::numeric(FLERR,arg[5],false,lmp); - seed = utils::inumeric(FLERR,arg[6],false,lmp); + mu = utils::numeric(FLERR, arg[0], false, lmp); + flaglog = utils::inumeric(FLERR, arg[1], false, lmp); + flagfld = utils::inumeric(FLERR, arg[2], false, lmp); + cut_inner_global = utils::numeric(FLERR, arg[3], false, lmp); + cut_global = utils::numeric(FLERR, arg[4], false, lmp); + t_target = utils::numeric(FLERR, arg[5], false, lmp); + seed = utils::inumeric(FLERR, arg[6], false, lmp); flagHI = flagVF = 1; if (narg == 9) { - flagHI = utils::inumeric(FLERR,arg[7],false,lmp); - flagVF = utils::inumeric(FLERR,arg[8],false,lmp); + flagHI = utils::inumeric(FLERR, arg[7], false, lmp); + flagVF = utils::inumeric(FLERR, arg[8], false, lmp); } if (flaglog == 1 && flagHI == 0) { - error->warning(FLERR,"Cannot include log terms without 1/r terms; " + error->warning(FLERR, + "Cannot include log terms without 1/r terms; " "setting flagHI to 1"); flagHI = 1; } @@ -394,7 +393,7 @@ void PairBrownian::settings(int narg, char **arg) // initialize Marsaglia RNG with processor-unique seed delete random; - random = new RanMars(lmp,seed + comm->me); + random = new RanMars(lmp, seed + comm->me); // reset cutoffs that have been explicitly set @@ -414,33 +413,32 @@ void PairBrownian::settings(int narg, char **arg) void PairBrownian::coeff(int narg, char **arg) { - if (narg != 2 && narg != 4) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg != 2 && narg != 4) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); double cut_inner_one = cut_inner_global; double cut_one = cut_global; if (narg == 4) { - cut_inner_one = utils::numeric(FLERR,arg[2],false,lmp); - cut_one = utils::numeric(FLERR,arg[3],false,lmp); + cut_inner_one = utils::numeric(FLERR, arg[2], false, lmp); + cut_one = utils::numeric(FLERR, arg[3], false, lmp); } int count = 0; for (int i = ilo; i <= ihi; i++) - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { cut_inner[i][j] = cut_inner_one; cut[i][j] = cut_one; setflag[i][j] = 1; count++; } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -449,18 +447,15 @@ void PairBrownian::coeff(int narg, char **arg) void PairBrownian::init_style() { - if (!atom->sphere_flag) - error->all(FLERR,"Pair brownian requires atom style sphere"); + if (!atom->sphere_flag) error->all(FLERR, "Pair brownian requires atom style sphere"); // if newton off, forces between atoms ij will be double computed // using different random numbers if (force->newton_pair == 0 && comm->me == 0) - error->warning(FLERR, - "Pair brownian needs newton pair on for " - "momentum conservation"); + error->warning(FLERR, "Pair brownian needs newton pair on for momentum conservation"); - neighbor->request(this,instance_me); + neighbor->add_request(this); // insure all particles are finite-size // for pair hybrid, should limit test to types using the pair style @@ -469,17 +464,15 @@ void PairBrownian::init_style() int nlocal = atom->nlocal; for (int i = 0; i < nlocal; i++) - if (radius[i] == 0.0) - error->one(FLERR,"Pair brownian requires extended particles"); + if (radius[i] == 0.0) error->one(FLERR, "Pair brownian requires extended particles"); // require monodisperse system with same radii for all types double radtype; for (int i = 1; i <= atom->ntypes; i++) { - if (!atom->radius_consistency(i,radtype)) - error->all(FLERR,"Pair brownian requires monodisperse particles"); - if (i > 1 && radtype != rad) - error->all(FLERR,"Pair brownian requires monodisperse particles"); + if (!atom->radius_consistency(i, radtype)) + error->all(FLERR, "Pair brownian requires monodisperse particles"); + if (i > 1 && radtype != rad) error->all(FLERR, "Pair brownian requires monodisperse particles"); rad = radtype; } @@ -496,15 +489,13 @@ void PairBrownian::init_style() flagdeform = flagwall = 0; for (int i = 0; i < modify->nfix; i++) { - if (strcmp(modify->fix[i]->style,"deform") == 0) + if (strcmp(modify->fix[i]->style, "deform") == 0) flagdeform = 1; - else if (strstr(modify->fix[i]->style,"wall") != nullptr) { - if (flagwall) - error->all(FLERR, - "Cannot use multiple fix wall commands with pair brownian"); - flagwall = 1; // Walls exist + else if (strstr(modify->fix[i]->style, "wall") != nullptr) { + if (flagwall) error->all(FLERR, "Cannot use multiple fix wall commands with pair brownian"); + flagwall = 1; // Walls exist wallfix = (FixWall *) modify->fix[i]; - if (wallfix->xflag) flagwall = 2; // Moving walls exist + if (wallfix->xflag) flagwall = 2; // Moving walls exist } } @@ -512,7 +503,8 @@ void PairBrownian::init_style() // vol_T = total volumeshearing = flagdeform = flagwall = 0; double vol_T, wallcoord; - if (!flagwall) vol_T = domain->xprd*domain->yprd*domain->zprd; + if (!flagwall) + vol_T = domain->xprd * domain->yprd * domain->zprd; else { double wallhi[3], walllo[3]; for (int j = 0; j < 3; j++) { @@ -528,31 +520,33 @@ void PairBrownian::init_style() wallcoord = input->variable->compute_equal(wallfix->xindex[m]); } - else wallcoord = wallfix->coord0[m]; + else + wallcoord = wallfix->coord0[m]; - if (side == 0) walllo[dim] = wallcoord; - else wallhi[dim] = wallcoord; + if (side == 0) + walllo[dim] = wallcoord; + else + wallhi[dim] = wallcoord; } - vol_T = (wallhi[0] - walllo[0]) * (wallhi[1] - walllo[1]) * - (wallhi[2] - walllo[2]); + vol_T = (wallhi[0] - walllo[0]) * (wallhi[1] - walllo[1]) * (wallhi[2] - walllo[2]); } // vol_P = volume of particles, assuming mono-dispersity // vol_f = volume fraction - vol_P = atom->natoms*(4.0/3.0)*MY_PI*cube(rad); + vol_P = atom->natoms * (4.0 / 3.0) * MY_PI * cube(rad); - double vol_f = vol_P/vol_T; + double vol_f = vol_P / vol_T; // set isotropic constants if (!flagVF) vol_f = 0; if (flaglog == 0) { - R0 = 6*MY_PI*mu*rad*(1.0 + 2.16*vol_f); - RT0 = 8*MY_PI*mu*cube(rad); // not actually needed + R0 = 6 * MY_PI * mu * rad * (1.0 + 2.16 * vol_f); + RT0 = 8 * MY_PI * mu * cube(rad); // not actually needed } else { - R0 = 6*MY_PI*mu*rad*(1.0 + 2.725*vol_f - 6.583*vol_f*vol_f); - RT0 = 8*MY_PI*mu*cube(rad)*(1.0 + 0.749*vol_f - 2.469*vol_f*vol_f); + R0 = 6 * MY_PI * mu * rad * (1.0 + 2.725 * vol_f - 6.583 * vol_f * vol_f); + RT0 = 8 * MY_PI * mu * cube(rad) * (1.0 + 0.749 * vol_f - 2.469 * vol_f * vol_f); } } @@ -563,8 +557,8 @@ void PairBrownian::init_style() double PairBrownian::init_one(int i, int j) { if (setflag[i][j] == 0) { - cut_inner[i][j] = mix_distance(cut_inner[i][i],cut_inner[j][j]); - cut[i][j] = mix_distance(cut[i][i],cut[j][j]); + cut_inner[i][j] = mix_distance(cut_inner[i][i], cut_inner[j][j]); + cut[i][j] = mix_distance(cut[i][i], cut[j][j]); } cut_inner[j][i] = cut_inner[i][j]; @@ -580,13 +574,13 @@ void PairBrownian::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - fwrite(&setflag[i][j],sizeof(int),1,fp); + fwrite(&setflag[i][j], sizeof(int), 1, fp); if (setflag[i][j]) { - fwrite(&cut_inner[i][j],sizeof(double),1,fp); - fwrite(&cut[i][j],sizeof(double),1,fp); + fwrite(&cut_inner[i][j], sizeof(double), 1, fp); + fwrite(&cut[i][j], sizeof(double), 1, fp); } } } @@ -600,19 +594,19 @@ void PairBrownian::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); if (setflag[i][j]) { if (me == 0) { - utils::sfread(FLERR,&cut_inner[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut[i][j],sizeof(double),1,fp,nullptr,error); + utils::sfread(FLERR, &cut_inner[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut[i][j], sizeof(double), 1, fp, nullptr, error); } - MPI_Bcast(&cut_inner[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut[i][j],1,MPI_DOUBLE,0,world); + MPI_Bcast(&cut_inner[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut[i][j], 1, MPI_DOUBLE, 0, world); } } } @@ -623,17 +617,17 @@ void PairBrownian::read_restart(FILE *fp) void PairBrownian::write_restart_settings(FILE *fp) { - fwrite(&mu,sizeof(double),1,fp); - fwrite(&flaglog,sizeof(int),1,fp); - fwrite(&flagfld,sizeof(int),1,fp); - fwrite(&cut_inner_global,sizeof(double),1,fp); - fwrite(&cut_global,sizeof(double),1,fp); - fwrite(&t_target,sizeof(double),1,fp); - fwrite(&seed,sizeof(int),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); - fwrite(&flagHI,sizeof(int),1,fp); - fwrite(&flagVF,sizeof(int),1,fp); + fwrite(&mu, sizeof(double), 1, fp); + fwrite(&flaglog, sizeof(int), 1, fp); + fwrite(&flagfld, sizeof(int), 1, fp); + fwrite(&cut_inner_global, sizeof(double), 1, fp); + fwrite(&cut_global, sizeof(double), 1, fp); + fwrite(&t_target, sizeof(double), 1, fp); + fwrite(&seed, sizeof(int), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); + fwrite(&flagHI, sizeof(int), 1, fp); + fwrite(&flagVF, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -644,57 +638,56 @@ void PairBrownian::read_restart_settings(FILE *fp) { int me = comm->me; if (me == 0) { - utils::sfread(FLERR,&mu,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&flaglog,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&flagfld,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_inner_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&t_target, sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&seed, sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&flagHI,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&flagVF,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &mu, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &flaglog, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &flagfld, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_inner_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &t_target, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &seed, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &flagHI, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &flagVF, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&mu,1,MPI_DOUBLE,0,world); - MPI_Bcast(&flaglog,1,MPI_INT,0,world); - MPI_Bcast(&flagfld,1,MPI_INT,0,world); - MPI_Bcast(&cut_inner_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&t_target,1,MPI_DOUBLE,0,world); - MPI_Bcast(&seed,1,MPI_INT,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); - MPI_Bcast(&flagHI,1,MPI_INT,0,world); - MPI_Bcast(&flagVF,1,MPI_INT,0,world); + MPI_Bcast(&mu, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&flaglog, 1, MPI_INT, 0, world); + MPI_Bcast(&flagfld, 1, MPI_INT, 0, world); + MPI_Bcast(&cut_inner_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&t_target, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&seed, 1, MPI_INT, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&flagHI, 1, MPI_INT, 0, world); + MPI_Bcast(&flagVF, 1, MPI_INT, 0, world); // additional setup based on restart parameters delete random; - random = new RanMars(lmp,seed + comm->me); + random = new RanMars(lmp, seed + comm->me); } /* ----------------------------------------------------------------------*/ -void PairBrownian::set_3_orthogonal_vectors(double p1[3], - double p2[3], double p3[3]) +void PairBrownian::set_3_orthogonal_vectors(double p1[3], double p2[3], double p3[3]) { double norm; - int ix,iy,iz; + int ix, iy, iz; // find the index of maximum magnitude and store it in iz if (fabs(p1[0]) > fabs(p1[1])) { - iz=0; - ix=1; - iy=2; + iz = 0; + ix = 1; + iy = 2; } else { - iz=1; - ix=2; - iy=0; + iz = 1; + ix = 2; + iy = 0; } - if (iz==0) { + if (iz == 0) { if (fabs(p1[0]) < fabs(p1[2])) { iz = 2; ix = 0; @@ -710,21 +703,21 @@ void PairBrownian::set_3_orthogonal_vectors(double p1[3], // set p2 arbitrarily such that it's orthogonal to p1 - p2[ix]=1.0; - p2[iy]=1.0; - p2[iz] = -(p1[ix]*p2[ix] + p1[iy]*p2[iy])/p1[iz]; + p2[ix] = 1.0; + p2[iy] = 1.0; + p2[iz] = -(p1[ix] * p2[ix] + p1[iy] * p2[iy]) / p1[iz]; // normalize p2 - norm = sqrt(p2[0]*p2[0] + p2[1]*p2[1] + p2[2]*p2[2]); + norm = sqrt(p2[0] * p2[0] + p2[1] * p2[1] + p2[2] * p2[2]); - p2[0] = p2[0]/norm; - p2[1] = p2[1]/norm; - p2[2] = p2[2]/norm; + p2[0] = p2[0] / norm; + p2[1] = p2[1] / norm; + p2[2] = p2[2] / norm; // Set p3 by taking the cross product p3=p2xp1 - p3[0] = p1[1]*p2[2] - p1[2]*p2[1]; - p3[1] = p1[2]*p2[0] - p1[0]*p2[2]; - p3[2] = p1[0]*p2[1] - p1[1]*p2[0]; + p3[0] = p1[1] * p2[2] - p1[2] * p2[1]; + p3[1] = p1[2] * p2[0] - p1[0] * p2[2]; + p3[2] = p1[0] * p2[1] - p1[1] * p2[0]; } diff --git a/src/COLLOID/pair_brownian_poly.cpp b/src/COLLOID/pair_brownian_poly.cpp index 0c3b9f1ed0..2edbbadc0f 100644 --- a/src/COLLOID/pair_brownian_poly.cpp +++ b/src/COLLOID/pair_brownian_poly.cpp @@ -19,24 +19,24 @@ #include "pair_brownian_poly.h" -#include -#include #include "atom.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "domain.h" -#include "update.h" -#include "modify.h" +#include "error.h" #include "fix.h" #include "fix_wall.h" +#include "force.h" #include "input.h" -#include "variable.h" -#include "random_mars.h" #include "math_const.h" #include "math_special.h" -#include "error.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "random_mars.h" +#include "update.h" +#include "variable.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -340,9 +340,7 @@ void PairBrownianPoly::init_style() if (radius[i] == 0.0) error->one(FLERR,"Pair brownian/poly requires extended particles"); - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); // set the isotropic constants that depend on the volume fraction // vol_T = total volume diff --git a/src/COLLOID/pair_colloid.cpp b/src/COLLOID/pair_colloid.cpp index 2c9887e8a5..891aae9233 100644 --- a/src/COLLOID/pair_colloid.cpp +++ b/src/COLLOID/pair_colloid.cpp @@ -18,7 +18,6 @@ #include "pair_colloid.h" -#include #include "atom.h" #include "comm.h" #include "force.h" @@ -27,6 +26,7 @@ #include "memory.h" #include "error.h" +#include using namespace LAMMPS_NS; using namespace MathSpecial; diff --git a/src/COLLOID/pair_lubricate.cpp b/src/COLLOID/pair_lubricate.cpp index 526f12e54c..c2117cf1ad 100644 --- a/src/COLLOID/pair_lubricate.cpp +++ b/src/COLLOID/pair_lubricate.cpp @@ -19,24 +19,24 @@ #include "pair_lubricate.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "domain.h" -#include "modify.h" +#include "error.h" #include "fix.h" #include "fix_deform.h" #include "fix_wall.h" +#include "force.h" #include "input.h" -#include "variable.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "variable.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -536,7 +536,7 @@ void PairLubricate::init_style() if (comm->ghost_velocity == 0) error->all(FLERR,"Pair lubricate requires ghost atoms store velocity"); - neighbor->request(this,instance_me); + neighbor->add_request(this); // require that atom radii are identical within each type // require monodisperse system with same radii for all types diff --git a/src/COLLOID/pair_lubricateU.cpp b/src/COLLOID/pair_lubricateU.cpp index 499e998b85..3d4fbcbc7d 100644 --- a/src/COLLOID/pair_lubricateU.cpp +++ b/src/COLLOID/pair_lubricateU.cpp @@ -18,24 +18,24 @@ #include "pair_lubricateU.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "domain.h" -#include "update.h" -#include "math_const.h" -#include "modify.h" +#include "error.h" #include "fix.h" #include "fix_wall.h" +#include "force.h" #include "input.h" -#include "variable.h" +#include "math_const.h" #include "memory.h" -#include "error.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "update.h" +#include "variable.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -1769,7 +1769,7 @@ void PairLubricateU::init_style() if (comm->ghost_velocity == 0) error->all(FLERR,"Pair lubricateU requires ghost atoms store velocity"); - neighbor->request(this,instance_me); + neighbor->add_request(this); // require that atom radii are identical within each type // require monodisperse system with same radii for all types diff --git a/src/COLLOID/pair_lubricateU_poly.cpp b/src/COLLOID/pair_lubricateU_poly.cpp index a778cf6d15..0aed0df97f 100644 --- a/src/COLLOID/pair_lubricateU_poly.cpp +++ b/src/COLLOID/pair_lubricateU_poly.cpp @@ -20,23 +20,23 @@ #include "pair_lubricateU_poly.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "domain.h" -#include "modify.h" +#include "error.h" #include "fix.h" #include "fix_wall.h" +#include "force.h" #include "input.h" -#include "variable.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "variable.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -1235,7 +1235,5 @@ void PairLubricateUPoly::init_style() RS0 = 20.0/3.0*MY_PI*mu*(1.0 + 3.64*vol_f - 6.95*vol_f*vol_f); } - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } diff --git a/src/COLLOID/pair_lubricate_poly.cpp b/src/COLLOID/pair_lubricate_poly.cpp index 2d921debfe..97aa6bf6ff 100644 --- a/src/COLLOID/pair_lubricate_poly.cpp +++ b/src/COLLOID/pair_lubricate_poly.cpp @@ -20,23 +20,23 @@ #include "pair_lubricate_poly.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "domain.h" -#include "modify.h" +#include "error.h" #include "fix.h" #include "fix_deform.h" #include "fix_wall.h" +#include "force.h" #include "input.h" -#include "variable.h" #include "math_const.h" -#include "error.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "variable.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -445,9 +445,7 @@ void PairLubricatePoly::init_style() if (radius[i] == 0.0) error->one(FLERR,"Pair lubricate/poly requires extended particles"); - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); // set the isotropic constants that depend on the volume fraction // vol_T = total volume diff --git a/src/COLLOID/pair_yukawa_colloid.cpp b/src/COLLOID/pair_yukawa_colloid.cpp index 323390169a..67b518fe70 100644 --- a/src/COLLOID/pair_yukawa_colloid.cpp +++ b/src/COLLOID/pair_yukawa_colloid.cpp @@ -124,14 +124,13 @@ void PairYukawaColloid::init_style() if (!atom->sphere_flag) error->all(FLERR,"Pair yukawa/colloid requires atom style sphere"); - neighbor->request(this,instance_me); + neighbor->add_request(this); // require that atom radii are identical within each type for (int i = 1; i <= atom->ntypes; i++) if (!atom->radius_consistency(i,rad[i])) - error->all(FLERR,"Pair yukawa/colloid requires atoms with same type " - "have same radius"); + error->all(FLERR,"Pair yukawa/colloid requires atoms with same type have same radius"); } /* ---------------------------------------------------------------------- diff --git a/src/DIELECTRIC/fix_polarize_functional.cpp b/src/DIELECTRIC/fix_polarize_functional.cpp index d631447d89..15140e7d58 100644 --- a/src/DIELECTRIC/fix_polarize_functional.cpp +++ b/src/DIELECTRIC/fix_polarize_functional.cpp @@ -40,7 +40,6 @@ #include "memory.h" #include "msm_dielectric.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair_coul_cut_dielectric.h" #include "pair_coul_long_dielectric.h" @@ -265,12 +264,7 @@ void FixPolarizeFunctional::init() // need a full neighbor list w/ Newton off and ghost neighbors // built whenever re-neighboring occurs - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 0; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); if (force->kspace) g_ewald = force->kspace->g_ewald; diff --git a/src/DIELECTRIC/pair_coul_cut_dielectric.cpp b/src/DIELECTRIC/pair_coul_cut_dielectric.cpp index 9596ce5be2..7e3602967f 100644 --- a/src/DIELECTRIC/pair_coul_cut_dielectric.cpp +++ b/src/DIELECTRIC/pair_coul_cut_dielectric.cpp @@ -24,7 +24,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -166,9 +165,7 @@ void PairCoulCutDielectric::init_style() avec = (AtomVecDielectric *) atom->style_match("dielectric"); if (!avec) error->all(FLERR, "Pair coul/cut/dielectric requires atom style dielectric"); - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/DIELECTRIC/pair_coul_long_dielectric.cpp b/src/DIELECTRIC/pair_coul_long_dielectric.cpp index 4bf7d48c2b..66a4473bfc 100644 --- a/src/DIELECTRIC/pair_coul_long_dielectric.cpp +++ b/src/DIELECTRIC/pair_coul_long_dielectric.cpp @@ -25,7 +25,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -211,9 +210,7 @@ void PairCoulLongDielectric::init_style() avec = (AtomVecDielectric *) atom->style_match("dielectric"); if (!avec) error->all(FLERR, "Pair coul/long/dielectric requires atom style dielectric"); - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); cut_coulsq = cut_coul * cut_coul; diff --git a/src/DIELECTRIC/pair_lj_cut_coul_cut_dielectric.cpp b/src/DIELECTRIC/pair_lj_cut_coul_cut_dielectric.cpp index 3e840459b7..94ecdac578 100644 --- a/src/DIELECTRIC/pair_lj_cut_coul_cut_dielectric.cpp +++ b/src/DIELECTRIC/pair_lj_cut_coul_cut_dielectric.cpp @@ -24,7 +24,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -194,9 +193,7 @@ void PairLJCutCoulCutDielectric::init_style() avec = (AtomVecDielectric *) atom->style_match("dielectric"); if (!avec) error->all(FLERR, "Pair lj/cut/coul/cut/dielectric requires atom style dielectric"); - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/DIELECTRIC/pair_lj_cut_coul_debye_dielectric.cpp b/src/DIELECTRIC/pair_lj_cut_coul_debye_dielectric.cpp index 5220be7b62..8858a444a8 100644 --- a/src/DIELECTRIC/pair_lj_cut_coul_debye_dielectric.cpp +++ b/src/DIELECTRIC/pair_lj_cut_coul_debye_dielectric.cpp @@ -24,7 +24,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -198,9 +197,7 @@ void PairLJCutCoulDebyeDielectric::init_style() avec = (AtomVecDielectric *) atom->style_match("dielectric"); if (!avec) error->all(FLERR, "Pair lj/cut/coul/debye/dielectric requires atom style dielectric"); - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/DIELECTRIC/pair_lj_cut_coul_long_dielectric.cpp b/src/DIELECTRIC/pair_lj_cut_coul_long_dielectric.cpp index b256dd5a6c..22a725d045 100644 --- a/src/DIELECTRIC/pair_lj_cut_coul_long_dielectric.cpp +++ b/src/DIELECTRIC/pair_lj_cut_coul_long_dielectric.cpp @@ -25,7 +25,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -248,9 +247,7 @@ void PairLJCutCoulLongDielectric::init_style() avec = (AtomVecDielectric *) atom->style_match("dielectric"); if (!avec) error->all(FLERR, "Pair lj/cut/coul/long/dielectric requires atom style dielectric"); - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); cut_coulsq = cut_coul * cut_coul; diff --git a/src/DIELECTRIC/pair_lj_cut_coul_msm_dielectric.cpp b/src/DIELECTRIC/pair_lj_cut_coul_msm_dielectric.cpp index b729abef8b..751f4d509a 100644 --- a/src/DIELECTRIC/pair_lj_cut_coul_msm_dielectric.cpp +++ b/src/DIELECTRIC/pair_lj_cut_coul_msm_dielectric.cpp @@ -25,7 +25,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -356,9 +355,7 @@ void PairLJCutCoulMSMDielectric::init_style() avec = (AtomVecDielectric *) atom->style_match("dielectric"); if (!avec) error->all(FLERR, "Pair lj/cut/coul/msm/dielectric requires atom style dielectric"); - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); cut_coulsq = cut_coul * cut_coul; diff --git a/src/DIELECTRIC/pair_lj_long_coul_long_dielectric.cpp b/src/DIELECTRIC/pair_lj_long_coul_long_dielectric.cpp index 25a533632b..3fd86587e9 100644 --- a/src/DIELECTRIC/pair_lj_long_coul_long_dielectric.cpp +++ b/src/DIELECTRIC/pair_lj_long_coul_long_dielectric.cpp @@ -25,7 +25,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -75,9 +74,7 @@ void PairLJLongCoulLongDielectric::init_style() avec = (AtomVecDielectric *) atom->style_match("dielectric"); if (!avec) error->all(FLERR, "Pair lj/long/coul/long/dielectric requires atom style dielectric"); - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/DIPOLE/pair_lj_cut_dipole_cut.cpp b/src/DIPOLE/pair_lj_cut_dipole_cut.cpp index 0f8a7317c6..6f0ed58520 100644 --- a/src/DIPOLE/pair_lj_cut_dipole_cut.cpp +++ b/src/DIPOLE/pair_lj_cut_dipole_cut.cpp @@ -14,17 +14,17 @@ #include "pair_lj_cut_dipole_cut.h" -#include -#include #include "atom.h" -#include "neighbor.h" -#include "neigh_list.h" #include "comm.h" +#include "error.h" #include "force.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" #include "update.h" +#include +#include using namespace LAMMPS_NS; @@ -362,7 +362,7 @@ void PairLJCutDipoleCut::init_style() if (!atom->q_flag || !atom->mu_flag || !atom->torque_flag) error->all(FLERR,"Pair dipole/cut requires atom attributes q, mu, torque"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DIPOLE/pair_lj_cut_dipole_long.cpp b/src/DIPOLE/pair_lj_cut_dipole_long.cpp index b13e48b808..6d6ddb748a 100644 --- a/src/DIPOLE/pair_lj_cut_dipole_long.cpp +++ b/src/DIPOLE/pair_lj_cut_dipole_long.cpp @@ -14,19 +14,19 @@ #include "pair_lj_cut_dipole_long.h" -#include -#include #include "atom.h" #include "comm.h" -#include "neighbor.h" -#include "neigh_list.h" +#include "error.h" #include "force.h" #include "kspace.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" #include "update.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -454,7 +454,7 @@ void PairLJCutDipoleLong::init_style() cut_coulsq = cut_coul * cut_coul; - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DIPOLE/pair_lj_long_dipole_long.cpp b/src/DIPOLE/pair_lj_long_dipole_long.cpp index 0d94d7116d..76dc487528 100644 --- a/src/DIPOLE/pair_lj_long_dipole_long.cpp +++ b/src/DIPOLE/pair_lj_long_dipole_long.cpp @@ -235,7 +235,7 @@ void PairLJLongDipoleLong::init_style() if (!atom->mu_flag || !atom->torque_flag) error->all(FLERR,"Pair lj/long/dipole/long requires atom attributes mu, torque"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; diff --git a/src/DIPOLE/pair_lj_sf_dipole_sf.cpp b/src/DIPOLE/pair_lj_sf_dipole_sf.cpp index 7d88513910..f32f50461c 100644 --- a/src/DIPOLE/pair_lj_sf_dipole_sf.cpp +++ b/src/DIPOLE/pair_lj_sf_dipole_sf.cpp @@ -37,12 +37,6 @@ static int warn_single = 0; /* ---------------------------------------------------------------------- */ -PairLJSFDipoleSF::PairLJSFDipoleSF(LAMMPS *lmp) : Pair(lmp) -{ -} - -/* ---------------------------------------------------------------------- */ - PairLJSFDipoleSF::~PairLJSFDipoleSF() { if (allocated) { @@ -418,7 +412,7 @@ void PairLJSFDipoleSF::init_style() if (!atom->q_flag || !atom->mu_flag || !atom->torque_flag) error->all(FLERR,"Pair dipole/sf requires atom attributes q, mu, torque"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DIPOLE/pair_lj_sf_dipole_sf.h b/src/DIPOLE/pair_lj_sf_dipole_sf.h index 22b9320d8a..809d352472 100644 --- a/src/DIPOLE/pair_lj_sf_dipole_sf.h +++ b/src/DIPOLE/pair_lj_sf_dipole_sf.h @@ -26,7 +26,7 @@ namespace LAMMPS_NS { class PairLJSFDipoleSF : public Pair { public: - PairLJSFDipoleSF(class LAMMPS *); + PairLJSFDipoleSF(class LAMMPS *_lmp) : Pair(_lmp) {}; ~PairLJSFDipoleSF() override; void compute(int, int) override; void settings(int, char **) override; diff --git a/src/DPD-BASIC/pair_dpd.cpp b/src/DPD-BASIC/pair_dpd.cpp index dec016706e..caa8161573 100644 --- a/src/DPD-BASIC/pair_dpd.cpp +++ b/src/DPD-BASIC/pair_dpd.cpp @@ -18,17 +18,17 @@ #include "pair_dpd.h" -#include #include "atom.h" #include "comm.h" -#include "update.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "random_mars.h" -#include "memory.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "random_mars.h" +#include "update.h" +#include using namespace LAMMPS_NS; @@ -257,10 +257,10 @@ void PairDPD::init_style() // if newton off, forces between atoms ij will be double computed // using different random numbers - if (force->newton_pair == 0 && comm->me == 0) error->warning(FLERR, - "Pair dpd needs newton pair on for momentum conservation"); + if (force->newton_pair == 0 && comm->me == 0) + error->warning(FLERR, "Pair dpd needs newton pair on for momentum conservation"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DPD-BASIC/pair_dpd_ext.cpp b/src/DPD-BASIC/pair_dpd_ext.cpp index 82e0cde0d6..5e45790913 100644 --- a/src/DPD-BASIC/pair_dpd_ext.cpp +++ b/src/DPD-BASIC/pair_dpd_ext.cpp @@ -326,10 +326,10 @@ void PairDPDExt::init_style() // if newton off, forces between atoms ij will be double computed // using different random numbers - if (force->newton_pair == 0 && comm->me == 0) error->warning(FLERR, - "Pair dpd needs newton pair on for momentum conservation"); + if (force->newton_pair == 0 && comm->me == 0) + error->warning(FLERR, "Pair dpd needs newton pair on for momentum conservation"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DPD-BASIC/pair_dpd_tstat.cpp b/src/DPD-BASIC/pair_dpd_tstat.cpp index 71c9151856..502241db73 100644 --- a/src/DPD-BASIC/pair_dpd_tstat.cpp +++ b/src/DPD-BASIC/pair_dpd_tstat.cpp @@ -14,15 +14,15 @@ #include "pair_dpd_tstat.h" -#include #include "atom.h" -#include "update.h" +#include "comm.h" +#include "error.h" #include "force.h" #include "neigh_list.h" -#include "comm.h" #include "random_mars.h" -#include "error.h" +#include "update.h" +#include using namespace LAMMPS_NS; diff --git a/src/DPD-MESO/pair_edpd.cpp b/src/DPD-MESO/pair_edpd.cpp index 836ea27e8b..ddbbd05085 100644 --- a/src/DPD-MESO/pair_edpd.cpp +++ b/src/DPD-MESO/pair_edpd.cpp @@ -375,10 +375,10 @@ void PairEDPD::init_style() // if newton off, forces between atoms ij will be double computed // using different random numbers - if (force->newton_pair == 0 && comm->me == 0) error->warning(FLERR, - "Pair tdpd needs newton pair on for momentum conservation"); + if (force->newton_pair == 0 && comm->me == 0) + error->warning(FLERR, "Pair tdpd needs newton pair on for momentum conservation"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DPD-MESO/pair_mdpd.cpp b/src/DPD-MESO/pair_mdpd.cpp index 1b490aa190..053d322f00 100644 --- a/src/DPD-MESO/pair_mdpd.cpp +++ b/src/DPD-MESO/pair_mdpd.cpp @@ -287,10 +287,10 @@ void PairMDPD::init_style() // if newton off, forces between atoms ij will be double computed // using different random numbers - if (force->newton_pair == 0 && comm->me == 0) error->warning(FLERR, - "Pair mdpd needs newton pair on for momentum conservation"); + if (force->newton_pair == 0 && comm->me == 0) + error->warning(FLERR, "Pair mdpd needs newton pair on for momentum conservation"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DPD-MESO/pair_mdpd_rhosum.cpp b/src/DPD-MESO/pair_mdpd_rhosum.cpp index 4501adf4f4..b44ca94c4e 100644 --- a/src/DPD-MESO/pair_mdpd_rhosum.cpp +++ b/src/DPD-MESO/pair_mdpd_rhosum.cpp @@ -27,7 +27,6 @@ #include "error.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -67,9 +66,7 @@ void PairMDPDRhoSum::init_style() error->all(FLERR,"Pair style mdpd/rhosum requires atom attribute rho"); // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/DPD-MESO/pair_tdpd.cpp b/src/DPD-MESO/pair_tdpd.cpp index 70168c0e2a..35f440426e 100644 --- a/src/DPD-MESO/pair_tdpd.cpp +++ b/src/DPD-MESO/pair_tdpd.cpp @@ -328,10 +328,9 @@ void PairTDPD::init_style() // using different random numbers if (force->newton_pair == 0 && comm->me == 0) - error->warning(FLERR,"Pair tdpd needs newton pair on " - "for momentum conservation"); + error->warning(FLERR,"Pair tdpd needs newton pair on for momentum conservation"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DPD-REACT/fix_rx.cpp b/src/DPD-REACT/fix_rx.cpp index bdc28e743f..dd8eacccc7 100644 --- a/src/DPD-REACT/fix_rx.cpp +++ b/src/DPD-REACT/fix_rx.cpp @@ -25,7 +25,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair_dpd_fdt_energy.h" #include "update.h" @@ -521,9 +520,9 @@ void FixRX::initSparse() } if (comm->me == 0 && Verbosity > 1) { - for (int i = 1; i < nu_bin.size(); ++i) - if (nu_bin[i] > 0) - printf("nu_bin[%d] = %d\n", i, nu_bin[i]); + for (int i = 1; i < (int)nu_bin.size(); ++i) + if ((nu_bin[i] > 0) && screen) + fprintf(screen, "nu_bin[%d] = %d\n", i, nu_bin[i]); for (int i = 0; i < nreactions; ++i) { std::string pstr, rstr; @@ -559,8 +558,8 @@ void FixRX::initSparse() pstr += atom->dvname[k]; } } - if (comm->me == 0 && Verbosity > 1) - printf("rx%3d: %s %s %s\n", i, rstr.c_str(), /*reversible[i]*/ (false) ? "<=>" : "=", pstr.c_str()); + if (comm->me == 0 && Verbosity > 1 && screen) + fprintf(screen,"rx%3d: %s %s %s\n", i, rstr.c_str(), /*reversible[i]*/ (false) ? "<=>" : "=", pstr.c_str()); } // end for nreactions } @@ -595,9 +594,7 @@ void FixRX::init() // need a half neighbor list // built whenever re-neighboring occurs - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; + neighbor->add_request(this); } /* ---------------------------------------------------------------------- */ diff --git a/src/DPD-REACT/fix_shardlow.cpp b/src/DPD-REACT/fix_shardlow.cpp index e6368676d3..02a8af888e 100644 --- a/src/DPD-REACT/fix_shardlow.cpp +++ b/src/DPD-REACT/fix_shardlow.cpp @@ -45,7 +45,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "npair.h" #include "npair_half_bin_newton_ssa.h" @@ -134,12 +133,8 @@ int FixShardlow::setmask() void FixShardlow::init() { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->ghost = 1; - neighbor->requests[irequest]->ssa = 1; - neighbor->requests[irequest]->newton = 1; // SSA requires newton on + // SSA requires newton on + neighbor->add_request(this, NeighConst::REQ_GHOST|NeighConst::REQ_NEWTON_ON|NeighConst::REQ_SSA); } /* ---------------------------------------------------------------------- */ diff --git a/src/DPD-REACT/pair_dpd_fdt.cpp b/src/DPD-REACT/pair_dpd_fdt.cpp index 1205ddc94c..a39198710d 100644 --- a/src/DPD-REACT/pair_dpd_fdt.cpp +++ b/src/DPD-REACT/pair_dpd_fdt.cpp @@ -314,7 +314,7 @@ void PairDPDfdt::init_style() error->all(FLERR,"Pair dpd/fdt requires ghost atoms store velocity"); splitFDT_flag = false; - neighbor->request(this,instance_me); + neighbor->add_request(this); for (int i = 0; i < modify->nfix; i++) if (utils::strmatch(modify->fix[i]->style,"^shardlow")) { splitFDT_flag = true; diff --git a/src/DPD-REACT/pair_dpd_fdt_energy.cpp b/src/DPD-REACT/pair_dpd_fdt_energy.cpp index 01f9ea19d7..02396a07f1 100644 --- a/src/DPD-REACT/pair_dpd_fdt_energy.cpp +++ b/src/DPD-REACT/pair_dpd_fdt_energy.cpp @@ -407,7 +407,7 @@ void PairDPDfdtEnergy::init_style() error->all(FLERR,"Pair dpd/fdt/energy requires ghost atoms store velocity"); splitFDT_flag = false; - neighbor->request(this,instance_me); + neighbor->add_request(this); for (int i = 0; i < modify->nfix; i++) if (utils::strmatch(modify->fix[i]->style,"^shardlow")) { splitFDT_flag = true; diff --git a/src/DPD-SMOOTH/pair_sdpd_taitwater_isothermal.cpp b/src/DPD-SMOOTH/pair_sdpd_taitwater_isothermal.cpp index 1e797938f9..f5ccb15eac 100644 --- a/src/DPD-SMOOTH/pair_sdpd_taitwater_isothermal.cpp +++ b/src/DPD-SMOOTH/pair_sdpd_taitwater_isothermal.cpp @@ -309,10 +309,9 @@ void PairSDPDTaitwaterIsothermal::coeff (int narg, char **arg) { void PairSDPDTaitwaterIsothermal::init_style() { if ((!atom->rho_flag) || (atom->drho == nullptr)) - error->all(FLERR,"Pair style dpd/taitwater/isothermal requires atom " - "attributes rho and drho"); + error->all(FLERR,"Pair style dpd/taitwater/isothermal requires atom attributes rho and drho"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DRUDE/pair_coul_tt.cpp b/src/DRUDE/pair_coul_tt.cpp index c3e97b49da..1e3892c414 100644 --- a/src/DRUDE/pair_coul_tt.cpp +++ b/src/DRUDE/pair_coul_tt.cpp @@ -291,7 +291,7 @@ void PairCoulTT::init_style() if (ifix == modify->nfix) error->all(FLERR, "Pair coul/tt requires fix drude"); fix_drude = (FixDrude *) modify->fix[ifix]; - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/DRUDE/pair_lj_cut_thole_long.cpp b/src/DRUDE/pair_lj_cut_thole_long.cpp index 3cf085a723..53e95c087e 100644 --- a/src/DRUDE/pair_lj_cut_thole_long.cpp +++ b/src/DRUDE/pair_lj_cut_thole_long.cpp @@ -18,21 +18,21 @@ #include "pair_lj_cut_thole_long.h" -#include -#include -#include "fix_drude.h" #include "atom.h" #include "comm.h" +#include "domain.h" +#include "error.h" +#include "fix_drude.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" - #include "modify.h" -#include "domain.h" +#include "neigh_list.h" +#include "neighbor.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -366,7 +366,7 @@ void PairLJCutTholeLong::init_style() error->all(FLERR, "Pair style lj/cut/thole/long requires fix drude"); fix_drude = (FixDrude *) modify->fix[ifix]; - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; diff --git a/src/DRUDE/pair_thole.cpp b/src/DRUDE/pair_thole.cpp index 97a3f48343..126e611fcf 100644 --- a/src/DRUDE/pair_thole.cpp +++ b/src/DRUDE/pair_thole.cpp @@ -14,20 +14,20 @@ #include "pair_thole.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" +#include "domain.h" #include "error.h" - #include "fix.h" #include "fix_drude.h" -#include "domain.h" +#include "force.h" +#include "memory.h" #include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" + +#include +#include using namespace LAMMPS_NS; @@ -260,7 +260,7 @@ void PairThole::init_style() if (ifix == modify->nfix) error->all(FLERR, "Pair thole requires fix drude"); fix_drude = (FixDrude *) modify->fix[ifix]; - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/EFF/pair_eff_cut.cpp b/src/EFF/pair_eff_cut.cpp index af781b1404..a6a33c4972 100644 --- a/src/EFF/pair_eff_cut.cpp +++ b/src/EFF/pair_eff_cut.cpp @@ -16,23 +16,22 @@ Contributing author: Andres Jaramillo-Botero ------------------------------------------------------------------------- */ - -#include - -#include #include "pair_eff_cut.h" #include "pair_eff_inline.h" -#include "atom.h" -#include "update.h" -#include "min.h" -#include "domain.h" -#include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" -#include "error.h" +#include "atom.h" +#include "comm.h" +#include "domain.h" +#include "error.h" +#include "force.h" +#include "memory.h" +#include "min.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -889,9 +888,9 @@ void PairEffCut::init_style() if (flagall && !ecp_found) error->all(FLERR,"Need to specify ECP type on pair_style command"); - // need a half neigh list and optionally a granular history neigh list + // need a half neigh list - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/EXTRA-COMPUTE/compute_ackland_atom.cpp b/src/EXTRA-COMPUTE/compute_ackland_atom.cpp index dc55167dc5..2a16db638f 100644 --- a/src/EXTRA-COMPUTE/compute_ackland_atom.cpp +++ b/src/EXTRA-COMPUTE/compute_ackland_atom.cpp @@ -27,7 +27,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -86,12 +85,7 @@ void ComputeAcklandAtom::init() { // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); int count = 0; for (int i = 0; i < modify->ncompute; i++) diff --git a/src/EXTRA-COMPUTE/compute_adf.cpp b/src/EXTRA-COMPUTE/compute_adf.cpp index 0cfed0cd80..c33edab502 100644 --- a/src/EXTRA-COMPUTE/compute_adf.cpp +++ b/src/EXTRA-COMPUTE/compute_adf.cpp @@ -336,16 +336,8 @@ void ComputeADF::init() // (until next reneighbor), so it needs to contain atoms further // than maxouter apart, just like a normal neighbor list does - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; - if (mycutneigh > 0.0) { - neighbor->requests[irequest]->cut = 1; - neighbor->requests[irequest]->cutoff = mycutneigh; - } + auto req = neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); + if (mycutneigh > 0.0) req->set_cutoff(mycutneigh); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-COMPUTE/compute_ave_sphere_atom.cpp b/src/EXTRA-COMPUTE/compute_ave_sphere_atom.cpp index 7238e7bbf3..d65b5b1d38 100644 --- a/src/EXTRA-COMPUTE/compute_ave_sphere_atom.cpp +++ b/src/EXTRA-COMPUTE/compute_ave_sphere_atom.cpp @@ -17,13 +17,13 @@ #include "comm.h" #include "error.h" #include "force.h" +#include "math_const.h" #include "memory.h" #include "neigh_list.h" #include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" -#include "math_const.h" #include @@ -103,16 +103,8 @@ void ComputeAveSphereAtom::init() // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; - if (cutflag) { - neighbor->requests[irequest]->cut = 1; - neighbor->requests[irequest]->cutoff = cutoff; - } + auto req = neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); + if (cutflag) req->set_cutoff(cutoff); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-COMPUTE/compute_basal_atom.cpp b/src/EXTRA-COMPUTE/compute_basal_atom.cpp index eacb3cf267..aad949530e 100644 --- a/src/EXTRA-COMPUTE/compute_basal_atom.cpp +++ b/src/EXTRA-COMPUTE/compute_basal_atom.cpp @@ -17,20 +17,21 @@ Copyright (C) 2013 ------------------------------------------------------------------------- */ +#include "compute_basal_atom.h" + +#include "atom.h" +#include "comm.h" +#include "error.h" +#include "force.h" +#include "memory.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "pair.h" +#include "update.h" + #include #include -#include "compute_basal_atom.h" -#include "atom.h" -#include "update.h" -#include "modify.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "force.h" -#include "pair.h" -#include "comm.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; @@ -70,17 +71,9 @@ void ComputeBasalAtom::init() { // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); - int count1 = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"basal/atom") == 0) count1++; - if (count1 > 1 && comm->me == 0) + if ((modify->get_compute_by_style("basal/atom").size() > 1) && (comm->me == 0)) error->warning(FLERR,"More than one compute basal/atom"); } diff --git a/src/EXTRA-COMPUTE/compute_cnp_atom.cpp b/src/EXTRA-COMPUTE/compute_cnp_atom.cpp index a056b4c991..1f74188c06 100644 --- a/src/EXTRA-COMPUTE/compute_cnp_atom.cpp +++ b/src/EXTRA-COMPUTE/compute_cnp_atom.cpp @@ -24,19 +24,19 @@ #include "compute_cnp_atom.h" -#include -#include #include "atom.h" -#include "update.h" -#include "modify.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "force.h" -#include "pair.h" #include "comm.h" -#include "memory.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "pair.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -111,12 +111,7 @@ void ComputeCNPAtom::init() error->warning(FLERR,"More than one compute cnp/atom defined"); // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-COMPUTE/compute_entropy_atom.cpp b/src/EXTRA-COMPUTE/compute_entropy_atom.cpp index ac53bf1e7f..20de069d50 100644 --- a/src/EXTRA-COMPUTE/compute_entropy_atom.cpp +++ b/src/EXTRA-COMPUTE/compute_entropy_atom.cpp @@ -27,7 +27,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -110,8 +109,7 @@ ComputeEntropyAtom::~ComputeEntropyAtom() void ComputeEntropyAtom::init() { if (force->pair == nullptr) - error->all(FLERR,"Compute entropy/atom requires a pair style be" - " defined"); + error->all(FLERR,"Compute entropy/atom requires a pair style be defined"); if ((cutoff+cutoff2) > (force->pair->cutforce + neighbor->skin)) { @@ -126,23 +124,16 @@ void ComputeEntropyAtom::init() if (count > 1 && comm->me == 0) error->warning(FLERR,"More than one compute entropy/atom"); - // Request neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + // Request a full neighbor list + int list_flags = NeighConst::REQ_FULL; if (avg_flag) { - // need a full neighbor list with neighbors of the ghost atoms - neighbor->requests[irequest]->occasional = 0; - neighbor->requests[irequest]->ghost = 1; + // need neighbors of the ghost atoms + list_flags |= NeighConst::REQ_GHOST; } else { - // need a regular full neighbor list - // can build it occasionally - neighbor->requests[irequest]->occasional = 1; - neighbor->requests[irequest]->ghost = 0; + // may build it occasionally + list_flags |= NeighConst::REQ_OCCASIONAL; } - + neighbor->add_request(this, list_flags); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-COMPUTE/compute_hexorder_atom.cpp b/src/EXTRA-COMPUTE/compute_hexorder_atom.cpp index 4fd4dc34a0..c2ccb3ca47 100644 --- a/src/EXTRA-COMPUTE/compute_hexorder_atom.cpp +++ b/src/EXTRA-COMPUTE/compute_hexorder_atom.cpp @@ -17,21 +17,22 @@ ------------------------------------------------------------------------- */ #include "compute_hexorder_atom.h" -#include -#include -#include + #include "atom.h" -#include "update.h" -#include "modify.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "force.h" -#include "pair.h" #include "comm.h" -#include "memory.h" #include "error.h" +#include "force.h" #include "math_const.h" +#include "memory.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "pair.h" +#include "update.h" + +#include +#include +#include #ifdef DBL_EPSILON #define MY_EPSILON (10.0*DBL_EPSILON) @@ -109,22 +110,13 @@ void ComputeHexOrderAtom::init() error->all(FLERR,"Compute hexorder/atom requires a pair style be defined"); if (cutsq == 0.0) cutsq = force->pair->cutforce * force->pair->cutforce; else if (sqrt(cutsq) > force->pair->cutforce) - error->all(FLERR, - "Compute hexorder/atom cutoff is longer than pairwise cutoff"); + error->all(FLERR, "Compute hexorder/atom cutoff is longer than pairwise cutoff"); // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); - int count = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"hexorder/atom") == 0) count++; - if (count > 1 && comm->me == 0) + if ((modify->get_compute_by_style("hexorder/atom").size() > 1) && (comm->me == 0)) error->warning(FLERR,"More than one compute hexorder/atom"); } diff --git a/src/EXTRA-COMPUTE/compute_hma.cpp b/src/EXTRA-COMPUTE/compute_hma.cpp index 7c7a9d6226..23dbb07aa8 100644 --- a/src/EXTRA-COMPUTE/compute_hma.cpp +++ b/src/EXTRA-COMPUTE/compute_hma.cpp @@ -62,7 +62,6 @@ https://doi.org/10.1103/PhysRevE.92.043303 #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -178,10 +177,7 @@ void ComputeHMA::init() { error->all(FLERR,"Pair style does not support compute hma cv"); } - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); } void ComputeHMA::init_list(int /* id */, NeighList *ptr) diff --git a/src/EXTRA-COMPUTE/compute_stress_cartesian.cpp b/src/EXTRA-COMPUTE/compute_stress_cartesian.cpp index 182a961738..329d18901b 100644 --- a/src/EXTRA-COMPUTE/compute_stress_cartesian.cpp +++ b/src/EXTRA-COMPUTE/compute_stress_cartesian.cpp @@ -22,7 +22,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" @@ -181,10 +180,7 @@ void ComputeStressCartesian::init() error->all(FLERR, "Pair style does not support compute stress/cartesian"); // need an occasional half neighbor list. - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-COMPUTE/compute_stress_cylinder.cpp b/src/EXTRA-COMPUTE/compute_stress_cylinder.cpp index c829871ccd..e4c246b469 100644 --- a/src/EXTRA-COMPUTE/compute_stress_cylinder.cpp +++ b/src/EXTRA-COMPUTE/compute_stress_cylinder.cpp @@ -23,7 +23,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -214,10 +213,7 @@ void ComputeStressCylinder::init() } // need an occasional half neighbor list - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); for (int zzz = 0; zzz < nzbins; zzz++) binz[zzz] = (((double) zzz) + 0.5) * bin_width + zlo; } diff --git a/src/EXTRA-COMPUTE/compute_stress_mop.cpp b/src/EXTRA-COMPUTE/compute_stress_mop.cpp index ad98374201..883321bf2b 100644 --- a/src/EXTRA-COMPUTE/compute_stress_mop.cpp +++ b/src/EXTRA-COMPUTE/compute_stress_mop.cpp @@ -18,20 +18,19 @@ #include "compute_stress_mop.h" +#include "atom.h" +#include "domain.h" +#include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "pair.h" +#include "update.h" + #include #include -#include "atom.h" -#include "update.h" -#include "domain.h" -#include "neighbor.h" -#include "force.h" -#include "pair.h" -#include "neigh_request.h" -#include "neigh_list.h" -#include "error.h" -#include "memory.h" - using namespace LAMMPS_NS; enum{X,Y,Z}; @@ -199,10 +198,7 @@ void ComputeStressMop::init() } // need an occasional half neighbor list - int irequest = neighbor->request((void *) this); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-COMPUTE/compute_stress_mop_profile.cpp b/src/EXTRA-COMPUTE/compute_stress_mop_profile.cpp index 9f70cfb723..fc01903aa1 100644 --- a/src/EXTRA-COMPUTE/compute_stress_mop_profile.cpp +++ b/src/EXTRA-COMPUTE/compute_stress_mop_profile.cpp @@ -18,20 +18,19 @@ #include "compute_stress_mop_profile.h" -#include -#include - #include "atom.h" #include "update.h" #include "domain.h" #include "neighbor.h" #include "force.h" #include "pair.h" -#include "neigh_request.h" #include "neigh_list.h" #include "error.h" #include "memory.h" +#include +#include + using namespace LAMMPS_NS; enum{X,Y,Z}; @@ -200,10 +199,7 @@ void ComputeStressMopProfile::init() // need an occasional half neighbor list - int irequest = neighbor->request((void *) this); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-COMPUTE/compute_stress_spherical.cpp b/src/EXTRA-COMPUTE/compute_stress_spherical.cpp index 2210bc61a7..18165513f9 100644 --- a/src/EXTRA-COMPUTE/compute_stress_spherical.cpp +++ b/src/EXTRA-COMPUTE/compute_stress_spherical.cpp @@ -142,10 +142,7 @@ void ComputeStressSpherical::init() for (int bin = 0; bin < nbins; bin++) invV[bin] = 0.75 / (MY_PI * (cube((bin + 1) * bin_width) - cube(bin * bin_width))); - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-FIX/fix_electron_stopping.cpp b/src/EXTRA-FIX/fix_electron_stopping.cpp index 5bb3831d46..a61cedcf27 100644 --- a/src/EXTRA-FIX/fix_electron_stopping.cpp +++ b/src/EXTRA-FIX/fix_electron_stopping.cpp @@ -27,7 +27,6 @@ #include "force.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "region.h" @@ -139,12 +138,7 @@ void FixElectronStopping::init() SeLoss = 0.0; // need an occasional full neighbor list - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/EXTRA-PAIR/pair_born_coul_dsf.cpp b/src/EXTRA-PAIR/pair_born_coul_dsf.cpp index 3fac9a79c9..84bfed6908 100644 --- a/src/EXTRA-PAIR/pair_born_coul_dsf.cpp +++ b/src/EXTRA-PAIR/pair_born_coul_dsf.cpp @@ -280,7 +280,7 @@ void PairBornCoulDSF::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style born/coul/dsf requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; double erfcc = erfc(alpha*cut_coul); diff --git a/src/EXTRA-PAIR/pair_born_coul_wolf.cpp b/src/EXTRA-PAIR/pair_born_coul_wolf.cpp index 2fe4316011..54eaed1dc2 100644 --- a/src/EXTRA-PAIR/pair_born_coul_wolf.cpp +++ b/src/EXTRA-PAIR/pair_born_coul_wolf.cpp @@ -283,7 +283,7 @@ void PairBornCoulWolf::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style born/coul/wolf requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; } diff --git a/src/EXTRA-PAIR/pair_cosine_squared.cpp b/src/EXTRA-PAIR/pair_cosine_squared.cpp index 77bb7dc326..1e61142c0b 100644 --- a/src/EXTRA-PAIR/pair_cosine_squared.cpp +++ b/src/EXTRA-PAIR/pair_cosine_squared.cpp @@ -175,17 +175,6 @@ void PairCosineSquared::coeff(int narg, char **arg) error->all(FLERR, "Incorrect args for pair coefficients (none set)"); } -/* ---------------------------------------------------------------------- - init specific to this pair style (unnecessary) -------------------------------------------------------------------------- */ - -/* -void PairCosineSquared::init_style() -{ - neighbor->request(this,instance_me); -} -*/ - /* ---------------------------------------------------------------------- init for one type pair i,j and corresponding j,i ------------------------------------------------------------------------- */ diff --git a/src/EXTRA-PAIR/pair_coul_diel.cpp b/src/EXTRA-PAIR/pair_coul_diel.cpp index 4f45858725..fb110eed84 100644 --- a/src/EXTRA-PAIR/pair_coul_diel.cpp +++ b/src/EXTRA-PAIR/pair_coul_diel.cpp @@ -17,15 +17,15 @@ #include "pair_coul_diel.h" -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include using namespace LAMMPS_NS; @@ -218,7 +218,7 @@ void PairCoulDiel::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style coul/diel requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/EXTRA-PAIR/pair_coul_exclude.cpp b/src/EXTRA-PAIR/pair_coul_exclude.cpp index 74890bcf08..efd612d1d6 100644 --- a/src/EXTRA-PAIR/pair_coul_exclude.cpp +++ b/src/EXTRA-PAIR/pair_coul_exclude.cpp @@ -182,7 +182,7 @@ void PairCoulExclude::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style coul/exclude requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/EXTRA-PAIR/pair_coul_slater_long.cpp b/src/EXTRA-PAIR/pair_coul_slater_long.cpp index 605305a7ef..d30d346fa0 100644 --- a/src/EXTRA-PAIR/pair_coul_slater_long.cpp +++ b/src/EXTRA-PAIR/pair_coul_slater_long.cpp @@ -241,7 +241,7 @@ void PairCoulSlaterLong::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style coul/slater/long requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; diff --git a/src/EXTRA-PAIR/pair_e3b.cpp b/src/EXTRA-PAIR/pair_e3b.cpp index 3af8e754c0..f09a3bcae2 100644 --- a/src/EXTRA-PAIR/pair_e3b.cpp +++ b/src/EXTRA-PAIR/pair_e3b.cpp @@ -458,7 +458,7 @@ void PairE3B::init_style() if (typeO < 1 || typeO > atom->ntypes) error->all(FLERR, "Invalid Otype: out of bounds"); // need a half neighbor list - neighbor->request(this, instance_me); + neighbor->add_request(this); if (!force->pair_match("tip4p", false, 0)) if (comm->me == 0) diff --git a/src/EXTRA-PAIR/pair_lj96_cut.cpp b/src/EXTRA-PAIR/pair_lj96_cut.cpp index a762e7de6b..28038ea396 100644 --- a/src/EXTRA-PAIR/pair_lj96_cut.cpp +++ b/src/EXTRA-PAIR/pair_lj96_cut.cpp @@ -25,7 +25,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "respa.h" #include "update.h" @@ -485,21 +484,14 @@ void PairLJ96Cut::init_style() { // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); // set rRESPA cutoffs diff --git a/src/EXTRA-PAIR/pair_lj_cut_coul_dsf.cpp b/src/EXTRA-PAIR/pair_lj_cut_coul_dsf.cpp index 79afd1ebeb..9782844c26 100644 --- a/src/EXTRA-PAIR/pair_lj_cut_coul_dsf.cpp +++ b/src/EXTRA-PAIR/pair_lj_cut_coul_dsf.cpp @@ -19,17 +19,17 @@ #include "pair_lj_cut_coul_dsf.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" -#include "math_const.h" #include "error.h" +#include "force.h" +#include "math_const.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -273,7 +273,7 @@ void PairLJCutCoulDSF::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style lj/cut/coul/dsf requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; double erfcc = erfc(alpha*cut_coul); diff --git a/src/EXTRA-PAIR/pair_lj_cut_coul_wolf.cpp b/src/EXTRA-PAIR/pair_lj_cut_coul_wolf.cpp index a0b6e6587b..aa0875f11c 100644 --- a/src/EXTRA-PAIR/pair_lj_cut_coul_wolf.cpp +++ b/src/EXTRA-PAIR/pair_lj_cut_coul_wolf.cpp @@ -18,16 +18,16 @@ #include "pair_lj_cut_coul_wolf.h" -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -270,9 +270,7 @@ void PairLJCutCoulWolf::init_style() cut_coulsq = cut_coul * cut_coul; - // request regular or rRESPA neighbor list - - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/EXTRA-PAIR/pair_lj_expand_coul_long.cpp b/src/EXTRA-PAIR/pair_lj_expand_coul_long.cpp index 2791c28747..5d5ceff1e5 100644 --- a/src/EXTRA-PAIR/pair_lj_expand_coul_long.cpp +++ b/src/EXTRA-PAIR/pair_lj_expand_coul_long.cpp @@ -18,21 +18,20 @@ #include "pair_lj_expand_coul_long.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "respa.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -686,21 +685,14 @@ void PairLJExpandCoulLong::init_style() // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); cut_coulsq = cut_coul * cut_coul; diff --git a/src/EXTRA-PAIR/pair_lj_gromacs.cpp b/src/EXTRA-PAIR/pair_lj_gromacs.cpp index 83bf099649..c5b23d24d9 100644 --- a/src/EXTRA-PAIR/pair_lj_gromacs.cpp +++ b/src/EXTRA-PAIR/pair_lj_gromacs.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -18,14 +17,14 @@ #include "pair_lj_gromacs.h" -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neigh_list.h" -#include "memory.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include using namespace LAMMPS_NS; @@ -67,14 +66,14 @@ PairLJGromacs::~PairLJGromacs() void PairLJGromacs::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r6inv,forcelj,factor_lj; - double r,t,fswitch,eswitch; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r6inv, forcelj, factor_lj; + double r, t, fswitch, eswitch; + int *ilist, *jlist, *numneigh, **firstneigh; evdwl = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -107,43 +106,42 @@ void PairLJGromacs::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (rsq > cut_inner_sq[itype][jtype]) { r = sqrt(rsq); t = r - cut_inner[itype][jtype]; - fswitch = r*t*t*(ljsw1[itype][jtype] + ljsw2[itype][jtype]*t); + fswitch = r * t * t * (ljsw1[itype][jtype] + ljsw2[itype][jtype] * t); forcelj += fswitch; } - fpair = factor_lj*forcelj*r2inv; + fpair = factor_lj * forcelj * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (newton_pair || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } if (eflag) { - evdwl = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]); + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); evdwl += ljsw5[itype][jtype]; if (rsq > cut_inner_sq[itype][jtype]) { - eswitch = t*t*t*(ljsw3[itype][jtype] + ljsw4[itype][jtype]*t); + eswitch = t * t * t * (ljsw3[itype][jtype] + ljsw4[itype][jtype] * t); evdwl += eswitch; } evdwl *= factor_lj; } - if (evflag) ev_tally(i,j,nlocal,newton_pair, - evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally(i, j, nlocal, newton_pair, evdwl, 0.0, fpair, delx, dely, delz); } } } @@ -158,29 +156,28 @@ void PairLJGromacs::compute(int eflag, int vflag) void PairLJGromacs::allocate() { allocated = 1; - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); - for (int i = 1; i <= n; i++) - for (int j = i; j <= n; j++) - setflag[i][j] = 0; + memory->create(setflag, np1, np1, "pair:setflag"); + for (int i = 1; i < np1; i++) + for (int j = i; j < np1; j++) setflag[i][j] = 0; - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, np1, np1, "pair:cutsq"); - memory->create(cut,n+1,n+1,"pair:cut"); - memory->create(cut_inner,n+1,n+1,"pair:cut_inner"); - memory->create(cut_inner_sq,n+1,n+1,"pair:cut_inner_sq"); - memory->create(epsilon,n+1,n+1,"pair:epsilon"); - memory->create(sigma,n+1,n+1,"pair:sigma"); - memory->create(lj1,n+1,n+1,"pair:lj1"); - memory->create(lj2,n+1,n+1,"pair:lj2"); - memory->create(lj3,n+1,n+1,"pair:lj3"); - memory->create(lj4,n+1,n+1,"pair:lj4"); - memory->create(ljsw1,n+1,n+1,"pair:ljsw1"); - memory->create(ljsw2,n+1,n+1,"pair:ljsw2"); - memory->create(ljsw3,n+1,n+1,"pair:ljsw3"); - memory->create(ljsw4,n+1,n+1,"pair:ljsw4"); - memory->create(ljsw5,n+1,n+1,"pair:ljsw5"); + memory->create(cut, np1, np1, "pair:cut"); + memory->create(cut_inner, np1, np1, "pair:cut_inner"); + memory->create(cut_inner_sq, np1, np1, "pair:cut_inner_sq"); + memory->create(epsilon, np1, np1, "pair:epsilon"); + memory->create(sigma, np1, np1, "pair:sigma"); + memory->create(lj1, np1, np1, "pair:lj1"); + memory->create(lj2, np1, np1, "pair:lj2"); + memory->create(lj3, np1, np1, "pair:lj3"); + memory->create(lj4, np1, np1, "pair:lj4"); + memory->create(ljsw1, np1, np1, "pair:ljsw1"); + memory->create(ljsw2, np1, np1, "pair:ljsw2"); + memory->create(ljsw3, np1, np1, "pair:ljsw3"); + memory->create(ljsw4, np1, np1, "pair:ljsw4"); + memory->create(ljsw5, np1, np1, "pair:ljsw5"); } /* ---------------------------------------------------------------------- @@ -189,18 +186,18 @@ void PairLJGromacs::allocate() void PairLJGromacs::settings(int narg, char **arg) { - if (narg != 2) error->all(FLERR,"Illegal pair_style command"); + if (narg != 2) error->all(FLERR, "Illegal pair_style command"); - cut_inner_global = utils::numeric(FLERR,arg[0],false,lmp); - cut_global = utils::numeric(FLERR,arg[1],false,lmp); + cut_inner_global = utils::numeric(FLERR, arg[0], false, lmp); + cut_global = utils::numeric(FLERR, arg[1], false, lmp); if (cut_inner_global <= 0.0 || cut_inner_global > cut_global) - error->all(FLERR,"Illegal pair_style command"); + error->all(FLERR, "Illegal pair_style command"); // reset cutoffs that have been explicitly set if (allocated) { - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) if (setflag[i][j]) { @@ -216,30 +213,29 @@ void PairLJGromacs::settings(int narg, char **arg) void PairLJGromacs::coeff(int narg, char **arg) { - if (narg != 4 && narg != 6) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg != 4 && narg != 6) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); - double epsilon_one = utils::numeric(FLERR,arg[2],false,lmp); - double sigma_one = utils::numeric(FLERR,arg[3],false,lmp); + double epsilon_one = utils::numeric(FLERR, arg[2], false, lmp); + double sigma_one = utils::numeric(FLERR, arg[3], false, lmp); double cut_inner_one = cut_inner_global; double cut_one = cut_global; if (narg == 6) { - cut_inner_one = utils::numeric(FLERR,arg[4],false,lmp); - cut_one = utils::numeric(FLERR,arg[5],false,lmp); + cut_inner_one = utils::numeric(FLERR, arg[4], false, lmp); + cut_one = utils::numeric(FLERR, arg[5], false, lmp); } if (cut_inner_one <= 0.0 || cut_inner_one > cut_one) - error->all(FLERR,"Incorrect args for pair coefficients"); + error->all(FLERR, "Incorrect args for pair coefficients"); int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { epsilon[i][j] = epsilon_one; sigma[i][j] = sigma_one; cut_inner[i][j] = cut_inner_one; @@ -249,7 +245,7 @@ void PairLJGromacs::coeff(int narg, char **arg) } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -259,37 +255,36 @@ void PairLJGromacs::coeff(int narg, char **arg) double PairLJGromacs::init_one(int i, int j) { if (setflag[i][j] == 0) { - epsilon[i][j] = mix_energy(epsilon[i][i],epsilon[j][j], - sigma[i][i],sigma[j][j]); - sigma[i][j] = mix_distance(sigma[i][i],sigma[j][j]); - cut_inner[i][j] = mix_distance(cut_inner[i][i],cut_inner[j][j]); - cut[i][j] = mix_distance(cut[i][i],cut[j][j]); + epsilon[i][j] = mix_energy(epsilon[i][i], epsilon[j][j], sigma[i][i], sigma[j][j]); + sigma[i][j] = mix_distance(sigma[i][i], sigma[j][j]); + cut_inner[i][j] = mix_distance(cut_inner[i][i], cut_inner[j][j]); + cut[i][j] = mix_distance(cut[i][i], cut[j][j]); } - cut_inner_sq[i][j] = cut_inner[i][j]*cut_inner[i][j]; - lj1[i][j] = 48.0 * epsilon[i][j] * pow(sigma[i][j],12.0); - lj2[i][j] = 24.0 * epsilon[i][j] * pow(sigma[i][j],6.0); - lj3[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j],12.0); - lj4[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j],6.0); + cut_inner_sq[i][j] = cut_inner[i][j] * cut_inner[i][j]; + lj1[i][j] = 48.0 * epsilon[i][j] * pow(sigma[i][j], 12.0); + lj2[i][j] = 24.0 * epsilon[i][j] * pow(sigma[i][j], 6.0); + lj3[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j], 12.0); + lj4[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j], 6.0); - double r6inv = 1.0/pow(cut[i][j],6.0); - double r8inv = 1.0/pow(cut[i][j],8.0); + double r6inv = 1.0 / pow(cut[i][j], 6.0); + double r8inv = 1.0 / pow(cut[i][j], 8.0); double t = cut[i][j] - cut_inner[i][j]; - double t2inv = 1.0/(t*t); - double t3inv = t2inv/t; - double t3 = 1.0/t3inv; - double a6 = (7.0*cut_inner[i][j] - 10.0*cut[i][j])*r8inv*t2inv; - double b6 = (9.0*cut[i][j] - 7.0*cut_inner[i][j])*r8inv*t3inv; - double a12 = (13.0*cut_inner[i][j] - 16.0*cut[i][j])*r6inv*r8inv*t2inv; - double b12 = (15.0*cut[i][j] - 13.0*cut_inner[i][j])*r6inv*r8inv*t3inv; - double c6 = r6inv - t3*(6.0*a6/3.0 + 6.0*b6*t/4.0); - double c12 = r6inv*r6inv - t3*(12.0*a12/3.0 + 12.0*b12*t/4.0); + double t2inv = 1.0 / (t * t); + double t3inv = t2inv / t; + double t3 = 1.0 / t3inv; + double a6 = (7.0 * cut_inner[i][j] - 10.0 * cut[i][j]) * r8inv * t2inv; + double b6 = (9.0 * cut[i][j] - 7.0 * cut_inner[i][j]) * r8inv * t3inv; + double a12 = (13.0 * cut_inner[i][j] - 16.0 * cut[i][j]) * r6inv * r8inv * t2inv; + double b12 = (15.0 * cut[i][j] - 13.0 * cut_inner[i][j]) * r6inv * r8inv * t3inv; + double c6 = r6inv - t3 * (6.0 * a6 / 3.0 + 6.0 * b6 * t / 4.0); + double c12 = r6inv * r6inv - t3 * (12.0 * a12 / 3.0 + 12.0 * b12 * t / 4.0); - ljsw1[i][j] = lj1[i][j]*a12 - lj2[i][j]*a6; - ljsw2[i][j] = lj1[i][j]*b12 - lj2[i][j]*b6; - ljsw3[i][j] = -lj3[i][j]*12.0*a12/3.0 + lj4[i][j]*6.0*a6/3.0; - ljsw4[i][j] = -lj3[i][j]*12.0*b12/4.0 + lj4[i][j]*6.0*b6/4.0; - ljsw5[i][j] = -lj3[i][j]*c12 + lj4[i][j]*c6; + ljsw1[i][j] = lj1[i][j] * a12 - lj2[i][j] * a6; + ljsw2[i][j] = lj1[i][j] * b12 - lj2[i][j] * b6; + ljsw3[i][j] = -lj3[i][j] * 12.0 * a12 / 3.0 + lj4[i][j] * 6.0 * a6 / 3.0; + ljsw4[i][j] = -lj3[i][j] * 12.0 * b12 / 4.0 + lj4[i][j] * 6.0 * b6 / 4.0; + ljsw5[i][j] = -lj3[i][j] * c12 + lj4[i][j] * c6; cut_inner[j][i] = cut_inner[i][j]; cut_inner_sq[j][i] = cut_inner_sq[i][j]; @@ -314,15 +309,15 @@ void PairLJGromacs::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - fwrite(&setflag[i][j],sizeof(int),1,fp); + fwrite(&setflag[i][j], sizeof(int), 1, fp); if (setflag[i][j]) { - fwrite(&epsilon[i][j],sizeof(double),1,fp); - fwrite(&sigma[i][j],sizeof(double),1,fp); - fwrite(&cut_inner[i][j],sizeof(double),1,fp); - fwrite(&cut[i][j],sizeof(double),1,fp); + fwrite(&epsilon[i][j], sizeof(double), 1, fp); + fwrite(&sigma[i][j], sizeof(double), 1, fp); + fwrite(&cut_inner[i][j], sizeof(double), 1, fp); + fwrite(&cut[i][j], sizeof(double), 1, fp); } } } @@ -336,23 +331,23 @@ void PairLJGromacs::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); if (setflag[i][j]) { if (me == 0) { - utils::sfread(FLERR,&epsilon[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&sigma[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_inner[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut[i][j],sizeof(double),1,fp,nullptr,error); + utils::sfread(FLERR, &epsilon[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &sigma[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_inner[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut[i][j], sizeof(double), 1, fp, nullptr, error); } - MPI_Bcast(&epsilon[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&sigma[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_inner[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut[i][j],1,MPI_DOUBLE,0,world); + MPI_Bcast(&epsilon[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&sigma[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_inner[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut[i][j], 1, MPI_DOUBLE, 0, world); } } } @@ -363,10 +358,10 @@ void PairLJGromacs::read_restart(FILE *fp) void PairLJGromacs::write_restart_settings(FILE *fp) { - fwrite(&cut_inner_global,sizeof(double),1,fp); - fwrite(&cut_global,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); + fwrite(&cut_inner_global, sizeof(double), 1, fp); + fwrite(&cut_global, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -377,15 +372,15 @@ void PairLJGromacs::read_restart_settings(FILE *fp) { int me = comm->me; if (me == 0) { - utils::sfread(FLERR,&cut_inner_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &cut_inner_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&cut_inner_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); + MPI_Bcast(&cut_inner_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); } /* ---------------------------------------------------------------------- @@ -394,8 +389,7 @@ void PairLJGromacs::read_restart_settings(FILE *fp) void PairLJGromacs::write_data(FILE *fp) { - for (int i = 1; i <= atom->ntypes; i++) - fprintf(fp,"%d %g %g\n",i,epsilon[i][i],sigma[i][i]); + for (int i = 1; i <= atom->ntypes; i++) fprintf(fp, "%d %g %g\n", i, epsilon[i][i], sigma[i][i]); } /* ---------------------------------------------------------------------- @@ -406,37 +400,35 @@ void PairLJGromacs::write_data_all(FILE *fp) { for (int i = 1; i <= atom->ntypes; i++) for (int j = i; j <= atom->ntypes; j++) - fprintf(fp,"%d %d %g %g %g %g\n",i,j, - epsilon[i][j],sigma[i][j],cut_inner[i][j],cut[i][j]); + fprintf(fp, "%d %d %g %g %g %g\n", i, j, epsilon[i][j], sigma[i][j], cut_inner[i][j], + cut[i][j]); } /* ---------------------------------------------------------------------- */ -double PairLJGromacs::single(int /*i*/, int /*j*/, int itype, int jtype, - double rsq, - double /*factor_coul*/, double factor_lj, - double &fforce) +double PairLJGromacs::single(int /*i*/, int /*j*/, int itype, int jtype, double rsq, + double /*factor_coul*/, double factor_lj, double &fforce) { - double r2inv,r6inv,forcelj,philj; - double r,t,fswitch,phiswitch; + double r2inv, r6inv, forcelj, philj; + double r, t, fswitch, phiswitch; - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (rsq > cut_inner_sq[itype][jtype]) { r = sqrt(rsq); t = r - cut_inner[itype][jtype]; - fswitch = r*t*t*(ljsw1[itype][jtype] + ljsw2[itype][jtype]*t); + fswitch = r * t * t * (ljsw1[itype][jtype] + ljsw2[itype][jtype] * t); forcelj += fswitch; } - fforce = factor_lj*forcelj*r2inv; + fforce = factor_lj * forcelj * r2inv; - philj = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]); + philj = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); philj += ljsw5[itype][jtype]; if (rsq > cut_inner_sq[itype][jtype]) { - phiswitch = t*t*t*(ljsw3[itype][jtype] + ljsw4[itype][jtype]*t); + phiswitch = t * t * t * (ljsw3[itype][jtype] + ljsw4[itype][jtype] * t); philj += phiswitch; } - return factor_lj*philj; + return factor_lj * philj; } diff --git a/src/EXTRA-PAIR/pair_lj_gromacs_coul_gromacs.cpp b/src/EXTRA-PAIR/pair_lj_gromacs_coul_gromacs.cpp index 96b8985b6b..71911169cf 100644 --- a/src/EXTRA-PAIR/pair_lj_gromacs_coul_gromacs.cpp +++ b/src/EXTRA-PAIR/pair_lj_gromacs_coul_gromacs.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -18,14 +17,15 @@ #include "pair_lj_gromacs_coul_gromacs.h" -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" + +#include using namespace LAMMPS_NS; @@ -64,14 +64,14 @@ PairLJGromacsCoulGromacs::~PairLJGromacsCoulGromacs() void PairLJGromacsCoulGromacs::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - double r,tlj,tc,fswitch,fswitchcoul,eswitch,ecoulswitch; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + double r, tlj, tc, fswitch, fswitchcoul, eswitch, ecoulswitch; + int *ilist, *jlist, *numneigh, **firstneigh; evdwl = ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -109,69 +109,72 @@ void PairLJGromacsCoulGromacs::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cut_bothsq) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; // skip if qi or qj = 0.0 since this potential may be used as // coarse-grain model with many uncharged atoms if (rsq < cut_coulsq && qtmp != 0.0 && q[j] != 0.0) { - forcecoul = qqrd2e * qtmp*q[j]*sqrt(r2inv); + forcecoul = qqrd2e * qtmp * q[j] * sqrt(r2inv); if (rsq > cut_coul_innersq) { r = sqrt(rsq); tc = r - cut_coul_inner; - fswitchcoul = qqrd2e * qtmp*q[j]*r*tc*tc*(coulsw1 + coulsw2*tc); + fswitchcoul = qqrd2e * qtmp * q[j] * r * tc * tc * (coulsw1 + coulsw2 * tc); forcecoul += fswitchcoul; } - } else forcecoul = 0.0; + } else + forcecoul = 0.0; if (rsq < cut_ljsq) { - r6inv = r2inv*r2inv*r2inv; + r6inv = r2inv * r2inv * r2inv; jtype = type[j]; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (rsq > cut_lj_innersq) { r = sqrt(rsq); tlj = r - cut_lj_inner; - fswitch = r*tlj*tlj*(ljsw1[itype][jtype] + - ljsw2[itype][jtype]*tlj); + fswitch = r * tlj * tlj * (ljsw1[itype][jtype] + ljsw2[itype][jtype] * tlj); forcelj += fswitch; } - } else forcelj = 0.0; + } else + forcelj = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forcelj) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (newton_pair || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } if (eflag) { if (rsq < cut_coulsq) { - ecoul = qqrd2e * qtmp*q[j] * (sqrt(r2inv) - coulsw5); + ecoul = qqrd2e * qtmp * q[j] * (sqrt(r2inv) - coulsw5); if (rsq > cut_coul_innersq) { - ecoulswitch = tc*tc*tc * (coulsw3 + coulsw4*tc); - ecoul += qqrd2e*qtmp*q[j]*ecoulswitch; + ecoulswitch = tc * tc * tc * (coulsw3 + coulsw4 * tc); + ecoul += qqrd2e * qtmp * q[j] * ecoulswitch; } ecoul *= factor_coul; - } else ecoul = 0.0; + } else + ecoul = 0.0; if (rsq < cut_ljsq) { - evdwl = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]); + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); evdwl += ljsw5[itype][jtype]; if (rsq > cut_lj_innersq) { - eswitch = tlj*tlj*tlj * (ljsw3[itype][jtype] + ljsw4[itype][jtype]*tlj); + eswitch = tlj * tlj * tlj * (ljsw3[itype][jtype] + ljsw4[itype][jtype] * tlj); evdwl += eswitch; } evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally(i,j,nlocal,newton_pair,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally(i, j, nlocal, newton_pair, evdwl, ecoul, fpair, delx, dely, delz); } } } @@ -186,26 +189,25 @@ void PairLJGromacsCoulGromacs::compute(int eflag, int vflag) void PairLJGromacsCoulGromacs::allocate() { allocated = 1; - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); - for (int i = 1; i <= n; i++) - for (int j = i; j <= n; j++) - setflag[i][j] = 0; + memory->create(setflag, np1, np1, "pair:setflag"); + for (int i = 1; i < np1; i++) + for (int j = i; j < np1; j++) setflag[i][j] = 0; - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, np1, np1, "pair:cutsq"); - memory->create(epsilon,n+1,n+1,"pair:epsilon"); - memory->create(sigma,n+1,n+1,"pair:sigma"); - memory->create(lj1,n+1,n+1,"pair:lj1"); - memory->create(lj2,n+1,n+1,"pair:lj2"); - memory->create(lj3,n+1,n+1,"pair:lj3"); - memory->create(lj4,n+1,n+1,"pair:lj4"); - memory->create(ljsw1,n+1,n+1,"pair:ljsw1"); - memory->create(ljsw2,n+1,n+1,"pair:ljsw2"); - memory->create(ljsw3,n+1,n+1,"pair:ljsw3"); - memory->create(ljsw4,n+1,n+1,"pair:ljsw4"); - memory->create(ljsw5,n+1,n+1,"pair:ljsw5"); + memory->create(epsilon, np1, np1, "pair:epsilon"); + memory->create(sigma, np1, np1, "pair:sigma"); + memory->create(lj1, np1, np1, "pair:lj1"); + memory->create(lj2, np1, np1, "pair:lj2"); + memory->create(lj3, np1, np1, "pair:lj3"); + memory->create(lj4, np1, np1, "pair:lj4"); + memory->create(ljsw1, np1, np1, "pair:ljsw1"); + memory->create(ljsw2, np1, np1, "pair:ljsw2"); + memory->create(ljsw3, np1, np1, "pair:ljsw3"); + memory->create(ljsw4, np1, np1, "pair:ljsw4"); + memory->create(ljsw5, np1, np1, "pair:ljsw5"); } /* ---------------------------------------------------------------------- @@ -214,23 +216,21 @@ void PairLJGromacsCoulGromacs::allocate() void PairLJGromacsCoulGromacs::settings(int narg, char **arg) { - if (narg != 2 && narg != 4) - error->all(FLERR,"Illegal pair_style command"); + if (narg != 2 && narg != 4) error->all(FLERR, "Illegal pair_style command"); - cut_lj_inner = utils::numeric(FLERR,arg[0],false,lmp); - cut_lj = utils::numeric(FLERR,arg[1],false,lmp); + cut_lj_inner = utils::numeric(FLERR, arg[0], false, lmp); + cut_lj = utils::numeric(FLERR, arg[1], false, lmp); if (narg == 2) { cut_coul_inner = cut_lj_inner; cut_coul = cut_lj; } else { - cut_coul_inner = utils::numeric(FLERR,arg[2],false,lmp); - cut_coul = utils::numeric(FLERR,arg[3],false,lmp); + cut_coul_inner = utils::numeric(FLERR, arg[2], false, lmp); + cut_coul = utils::numeric(FLERR, arg[3], false, lmp); } - if (cut_lj_inner <= 0.0 || cut_coul_inner < 0.0) - error->all(FLERR,"Illegal pair_style command"); + if (cut_lj_inner <= 0.0 || cut_coul_inner < 0.0) error->all(FLERR, "Illegal pair_style command"); if (cut_lj_inner > cut_lj || cut_coul_inner > cut_coul) - error->all(FLERR,"Illegal pair_style command"); + error->all(FLERR, "Illegal pair_style command"); } /* ---------------------------------------------------------------------- @@ -239,19 +239,19 @@ void PairLJGromacsCoulGromacs::settings(int narg, char **arg) void PairLJGromacsCoulGromacs::coeff(int narg, char **arg) { - if (narg != 4) error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg != 4) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); - double epsilon_one = utils::numeric(FLERR,arg[2],false,lmp); - double sigma_one = utils::numeric(FLERR,arg[3],false,lmp); + double epsilon_one = utils::numeric(FLERR, arg[2], false, lmp); + double sigma_one = utils::numeric(FLERR, arg[3], false, lmp); int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { epsilon[i][j] = epsilon_one; sigma[i][j] = sigma_one; setflag[i][j] = 1; @@ -259,7 +259,7 @@ void PairLJGromacsCoulGromacs::coeff(int narg, char **arg) } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -269,16 +269,15 @@ void PairLJGromacsCoulGromacs::coeff(int narg, char **arg) void PairLJGromacsCoulGromacs::init_style() { if (!atom->q_flag) - error->all(FLERR, - "Pair style lj/gromacs/coul/gromacs requires atom attribute q"); + error->all(FLERR, "Pair style lj/gromacs/coul/gromacs requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_lj_innersq = cut_lj_inner * cut_lj_inner; cut_ljsq = cut_lj * cut_lj; cut_coul_innersq = cut_coul_inner * cut_coul_inner; cut_coulsq = cut_coul * cut_coul; - cut_bothsq = MAX(cut_ljsq,cut_coulsq); + cut_bothsq = MAX(cut_ljsq, cut_coulsq); } /* ---------------------------------------------------------------------- @@ -288,48 +287,47 @@ void PairLJGromacsCoulGromacs::init_style() double PairLJGromacsCoulGromacs::init_one(int i, int j) { if (setflag[i][j] == 0) { - epsilon[i][j] = mix_energy(epsilon[i][i],epsilon[j][j], - sigma[i][i],sigma[j][j]); - sigma[i][j] = mix_distance(sigma[i][i],sigma[j][j]); + epsilon[i][j] = mix_energy(epsilon[i][i], epsilon[j][j], sigma[i][i], sigma[j][j]); + sigma[i][j] = mix_distance(sigma[i][i], sigma[j][j]); } - double cut = MAX(cut_lj,cut_coul); + double cut = MAX(cut_lj, cut_coul); - lj1[i][j] = 48.0 * epsilon[i][j] * pow(sigma[i][j],12.0); - lj2[i][j] = 24.0 * epsilon[i][j] * pow(sigma[i][j],6.0); - lj3[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j],12.0); - lj4[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j],6.0); + lj1[i][j] = 48.0 * epsilon[i][j] * pow(sigma[i][j], 12.0); + lj2[i][j] = 24.0 * epsilon[i][j] * pow(sigma[i][j], 6.0); + lj3[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j], 12.0); + lj4[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j], 6.0); - double r6inv = 1.0/pow(cut_lj,6.0); - double r8inv = 1.0/pow(cut_lj,8.0); + double r6inv = 1.0 / pow(cut_lj, 6.0); + double r8inv = 1.0 / pow(cut_lj, 8.0); double t = cut_lj - cut_lj_inner; - double t2inv = 1.0/(t*t); - double t3inv = t2inv/t; - double t3 = 1.0/t3inv; - double a6 = (7.0*cut_lj_inner - 10.0*cut_lj)*r8inv*t2inv; - double b6 = (9.0*cut_lj - 7.0*cut_lj_inner)*r8inv*t3inv; - double a12 = (13.0*cut_lj_inner - 16.0*cut_lj)*r6inv*r8inv*t2inv; - double b12 = (15.0*cut_lj - 13.0*cut_lj_inner)*r6inv*r8inv*t3inv; - double c6 = r6inv - t3*(6.0*a6/3.0 + 6.0*b6*t/4.0); - double c12 = r6inv*r6inv - t3*(12.0*a12/3.0 + 12.0*b12*t/4.0); + double t2inv = 1.0 / (t * t); + double t3inv = t2inv / t; + double t3 = 1.0 / t3inv; + double a6 = (7.0 * cut_lj_inner - 10.0 * cut_lj) * r8inv * t2inv; + double b6 = (9.0 * cut_lj - 7.0 * cut_lj_inner) * r8inv * t3inv; + double a12 = (13.0 * cut_lj_inner - 16.0 * cut_lj) * r6inv * r8inv * t2inv; + double b12 = (15.0 * cut_lj - 13.0 * cut_lj_inner) * r6inv * r8inv * t3inv; + double c6 = r6inv - t3 * (6.0 * a6 / 3.0 + 6.0 * b6 * t / 4.0); + double c12 = r6inv * r6inv - t3 * (12.0 * a12 / 3.0 + 12.0 * b12 * t / 4.0); - ljsw1[i][j] = lj1[i][j]*a12 - lj2[i][j]*a6; - ljsw2[i][j] = lj1[i][j]*b12 - lj2[i][j]*b6; - ljsw3[i][j] = -lj3[i][j]*12.0*a12/3.0 + lj4[i][j]*6.0*a6/3.0; - ljsw4[i][j] = -lj3[i][j]*12.0*b12/4.0 + lj4[i][j]*6.0*b6/4.0; - ljsw5[i][j] = -lj3[i][j]*c12 + lj4[i][j]*c6; + ljsw1[i][j] = lj1[i][j] * a12 - lj2[i][j] * a6; + ljsw2[i][j] = lj1[i][j] * b12 - lj2[i][j] * b6; + ljsw3[i][j] = -lj3[i][j] * 12.0 * a12 / 3.0 + lj4[i][j] * 6.0 * a6 / 3.0; + ljsw4[i][j] = -lj3[i][j] * 12.0 * b12 / 4.0 + lj4[i][j] * 6.0 * b6 / 4.0; + ljsw5[i][j] = -lj3[i][j] * c12 + lj4[i][j] * c6; - double r3inv = 1.0/pow(cut_coul,3.0); + double r3inv = 1.0 / pow(cut_coul, 3.0); t = cut_coul - cut_coul_inner; - t2inv = 1.0/(t*t); - t3inv = t2inv/t; - double a1 = (2.0*cut_coul_inner - 5.0*cut_coul) * r3inv*t2inv; - double b1 = (4.0*cut_coul - 2.0*cut_coul_inner) * r3inv*t3inv; + t2inv = 1.0 / (t * t); + t3inv = t2inv / t; + double a1 = (2.0 * cut_coul_inner - 5.0 * cut_coul) * r3inv * t2inv; + double b1 = (4.0 * cut_coul - 2.0 * cut_coul_inner) * r3inv * t3inv; coulsw1 = a1; coulsw2 = b1; - coulsw3 = -a1/3.0; - coulsw4 = -b1/4.0; - coulsw5 = 1.0/cut_coul - t*t*t*(a1/3.0 + b1*t/4.0); + coulsw3 = -a1 / 3.0; + coulsw4 = -b1 / 4.0; + coulsw5 = 1.0 / cut_coul - t * t * t * (a1 / 3.0 + b1 * t / 4.0); lj1[j][i] = lj1[i][j]; lj2[j][i] = lj2[i][j]; @@ -352,13 +350,13 @@ void PairLJGromacsCoulGromacs::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - fwrite(&setflag[i][j],sizeof(int),1,fp); + fwrite(&setflag[i][j], sizeof(int), 1, fp); if (setflag[i][j]) { - fwrite(&epsilon[i][j],sizeof(double),1,fp); - fwrite(&sigma[i][j],sizeof(double),1,fp); + fwrite(&epsilon[i][j], sizeof(double), 1, fp); + fwrite(&sigma[i][j], sizeof(double), 1, fp); } } } @@ -372,19 +370,19 @@ void PairLJGromacsCoulGromacs::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); if (setflag[i][j]) { if (me == 0) { - utils::sfread(FLERR,&epsilon[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&sigma[i][j],sizeof(double),1,fp,nullptr,error); + utils::sfread(FLERR, &epsilon[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &sigma[i][j], sizeof(double), 1, fp, nullptr, error); } - MPI_Bcast(&epsilon[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&sigma[i][j],1,MPI_DOUBLE,0,world); + MPI_Bcast(&epsilon[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&sigma[i][j], 1, MPI_DOUBLE, 0, world); } } } @@ -395,12 +393,12 @@ void PairLJGromacsCoulGromacs::read_restart(FILE *fp) void PairLJGromacsCoulGromacs::write_restart_settings(FILE *fp) { - fwrite(&cut_lj_inner,sizeof(double),1,fp); - fwrite(&cut_lj,sizeof(double),1,fp); - fwrite(&cut_coul_inner,sizeof(double),1,fp); - fwrite(&cut_coul,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); + fwrite(&cut_lj_inner, sizeof(double), 1, fp); + fwrite(&cut_lj, sizeof(double), 1, fp); + fwrite(&cut_coul_inner, sizeof(double), 1, fp); + fwrite(&cut_coul, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -410,19 +408,19 @@ void PairLJGromacsCoulGromacs::write_restart_settings(FILE *fp) void PairLJGromacsCoulGromacs::read_restart_settings(FILE *fp) { if (comm->me == 0) { - utils::sfread(FLERR,&cut_lj_inner,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_lj,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul_inner,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &cut_lj_inner, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_lj, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul_inner, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&cut_lj_inner,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_lj,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul_inner,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); + MPI_Bcast(&cut_lj_inner, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_lj, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul_inner, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); } /* ---------------------------------------------------------------------- @@ -431,8 +429,7 @@ void PairLJGromacsCoulGromacs::read_restart_settings(FILE *fp) void PairLJGromacsCoulGromacs::write_data(FILE *fp) { - for (int i = 1; i <= atom->ntypes; i++) - fprintf(fp,"%d %g %g\n",i,epsilon[i][i],sigma[i][i]); + for (int i = 1; i <= atom->ntypes; i++) fprintf(fp, "%d %g %g\n", i, epsilon[i][i], sigma[i][i]); } /* ---------------------------------------------------------------------- @@ -443,62 +440,63 @@ void PairLJGromacsCoulGromacs::write_data_all(FILE *fp) { for (int i = 1; i <= atom->ntypes; i++) for (int j = i; j <= atom->ntypes; j++) - fprintf(fp,"%d %d %g %g\n",i,j,epsilon[i][j],sigma[i][j]); + fprintf(fp, "%d %d %g %g\n", i, j, epsilon[i][j], sigma[i][j]); } /* ---------------------------------------------------------------------- */ -double PairLJGromacsCoulGromacs::single(int i, int j, int itype, int jtype, - double rsq, - double factor_coul, double factor_lj, - double &fforce) +double PairLJGromacsCoulGromacs::single(int i, int j, int itype, int jtype, double rsq, + double factor_coul, double factor_lj, double &fforce) { - double r2inv,r6inv,forcecoul,forcelj,phicoul,philj; - double r,tlj,tc,fswitch,phiswitch,fswitchcoul,phiswitchcoul; + double r2inv, r6inv, forcecoul, forcelj, phicoul, philj; + double r, tlj, tc, fswitch, phiswitch, fswitchcoul, phiswitchcoul; - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { - forcecoul = force->qqrd2e * atom->q[i]*atom->q[j]*sqrt(r2inv); + forcecoul = force->qqrd2e * atom->q[i] * atom->q[j] * sqrt(r2inv); if (rsq > cut_coul_innersq) { r = sqrt(rsq); tc = r - cut_coul_inner; - fswitchcoul = force->qqrd2e * - atom->q[i]*atom->q[j] * r*tc*tc * (coulsw1 + coulsw2*tc); + fswitchcoul = + force->qqrd2e * atom->q[i] * atom->q[j] * r * tc * tc * (coulsw1 + coulsw2 * tc); forcecoul += fswitchcoul; } - } else forcecoul = 0.0; + } else + forcecoul = 0.0; if (rsq < cut_ljsq) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (rsq > cut_lj_innersq) { r = sqrt(rsq); tlj = r - cut_lj_inner; - fswitch = r*tlj*tlj*(ljsw1[itype][jtype] + ljsw2[itype][jtype]*tlj); + fswitch = r * tlj * tlj * (ljsw1[itype][jtype] + ljsw2[itype][jtype] * tlj); forcelj += fswitch; } - } else forcelj = 0.0; + } else + forcelj = 0.0; - fforce = (factor_coul*forcecoul + factor_lj*forcelj) * r2inv; + fforce = (factor_coul * forcecoul + factor_lj * forcelj) * r2inv; double eng = 0.0; if (rsq < cut_coulsq) { - phicoul = force->qqrd2e * atom->q[i]*atom->q[j] * (sqrt(r2inv)-coulsw5); + phicoul = force->qqrd2e * atom->q[i] * atom->q[j] * (sqrt(r2inv) - coulsw5); if (rsq > cut_coul_innersq) { - phiswitchcoul = force->qqrd2e * atom->q[i]*atom->q[j] * tc*tc*tc * (coulsw3 + coulsw4*tc); + phiswitchcoul = + force->qqrd2e * atom->q[i] * atom->q[j] * tc * tc * tc * (coulsw3 + coulsw4 * tc); phicoul += phiswitchcoul; } - eng += factor_coul*phicoul; + eng += factor_coul * phicoul; } if (rsq < cut_ljsq) { - philj = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]); + philj = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); philj += ljsw5[itype][jtype]; if (rsq > cut_lj_innersq) { - phiswitch = tlj*tlj*tlj * (ljsw3[itype][jtype] + ljsw4[itype][jtype]*tlj); + phiswitch = tlj * tlj * tlj * (ljsw3[itype][jtype] + ljsw4[itype][jtype] * tlj); philj += phiswitch; } - eng += factor_lj*philj; + eng += factor_lj * philj; } return eng; diff --git a/src/EXTRA-PAIR/pair_mie_cut.cpp b/src/EXTRA-PAIR/pair_mie_cut.cpp index 4fd5dedb69..729cac8ff8 100644 --- a/src/EXTRA-PAIR/pair_mie_cut.cpp +++ b/src/EXTRA-PAIR/pair_mie_cut.cpp @@ -18,20 +18,19 @@ #include "pair_mie_cut.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "respa.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -497,21 +496,14 @@ void PairMIECut::init_style() { // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); // set rRESPA cutoffs diff --git a/src/EXTRA-PAIR/pair_nm_cut_coul_cut.cpp b/src/EXTRA-PAIR/pair_nm_cut_coul_cut.cpp index a0e31d3070..d9cfbf1525 100644 --- a/src/EXTRA-PAIR/pair_nm_cut_coul_cut.cpp +++ b/src/EXTRA-PAIR/pair_nm_cut_coul_cut.cpp @@ -18,17 +18,17 @@ #include "pair_nm_cut_coul_cut.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -267,7 +267,7 @@ void PairNMCutCoulCut::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style nm/cut/coul/cut requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/EXTRA-PAIR/pair_nm_cut_coul_long.cpp b/src/EXTRA-PAIR/pair_nm_cut_coul_long.cpp index ff8dd3d220..66f4e53ab2 100644 --- a/src/EXTRA-PAIR/pair_nm_cut_coul_long.cpp +++ b/src/EXTRA-PAIR/pair_nm_cut_coul_long.cpp @@ -18,18 +18,18 @@ #include "pair_nm_cut_coul_long.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -304,7 +304,7 @@ void PairNMCutCoulLong::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style nm/cut/coul/long requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; // insure use of KSpace long-range solver, set g_ewald diff --git a/src/FEP/pair_coul_cut_soft.cpp b/src/FEP/pair_coul_cut_soft.cpp index 877ca64cae..493ddbf3e8 100644 --- a/src/FEP/pair_coul_cut_soft.cpp +++ b/src/FEP/pair_coul_cut_soft.cpp @@ -18,16 +18,16 @@ #include "pair_coul_cut_soft.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; @@ -217,7 +217,7 @@ void PairCoulCutSoft::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style coul/cut/soft requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/FEP/pair_coul_long_soft.cpp b/src/FEP/pair_coul_long_soft.cpp index 74f1909415..03a0fbcbb6 100644 --- a/src/FEP/pair_coul_long_soft.cpp +++ b/src/FEP/pair_coul_long_soft.cpp @@ -19,17 +19,17 @@ #include "pair_coul_long_soft.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" -#include "neigh_list.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; @@ -231,7 +231,7 @@ void PairCoulLongSoft::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style lj/cut/coul/long requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; diff --git a/src/FEP/pair_lj_charmm_coul_long_soft.cpp b/src/FEP/pair_lj_charmm_coul_long_soft.cpp index 2460dbf313..86681cf51f 100644 --- a/src/FEP/pair_lj_charmm_coul_long_soft.cpp +++ b/src/FEP/pair_lj_charmm_coul_long_soft.cpp @@ -19,20 +19,19 @@ #include "pair_lj_charmm_coul_long_soft.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "respa.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" +#include +#include using namespace LAMMPS_NS; @@ -686,26 +685,18 @@ void PairLJCharmmCoulLongSoft::coeff(int narg, char **arg) void PairLJCharmmCoulLongSoft::init_style() { if (!atom->q_flag) - error->all(FLERR, - "Pair style lj/charmm/coul/long/soft requires atom attribute q"); + error->all(FLERR,"Pair style lj/charmm/coul/long/soft requires atom attribute q"); - // request regular or rRESPA neighbor lists + // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); // require cut_lj_inner < cut_lj diff --git a/src/FEP/pair_lj_class2_coul_cut_soft.cpp b/src/FEP/pair_lj_class2_coul_cut_soft.cpp index 6b6501f936..2854062641 100644 --- a/src/FEP/pair_lj_class2_coul_cut_soft.cpp +++ b/src/FEP/pair_lj_class2_coul_cut_soft.cpp @@ -14,17 +14,17 @@ #include "pair_lj_class2_coul_cut_soft.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -269,7 +269,7 @@ void PairLJClass2CoulCutSoft::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style lj/class2/coul/cut/soft requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/FEP/pair_lj_class2_coul_long_soft.cpp b/src/FEP/pair_lj_class2_coul_long_soft.cpp index c32a3ef884..db01dedea6 100644 --- a/src/FEP/pair_lj_class2_coul_long_soft.cpp +++ b/src/FEP/pair_lj_class2_coul_long_soft.cpp @@ -14,18 +14,18 @@ #include "pair_lj_class2_coul_long_soft.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -277,10 +277,9 @@ void PairLJClass2CoulLongSoft::coeff(int narg, char **arg) void PairLJClass2CoulLongSoft::init_style() { if (!atom->q_flag) - error->all(FLERR, - "Pair style lj/class2/coul/long/soft requires atom attribute q"); + error->all(FLERR, "Pair style lj/class2/coul/long/soft requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; diff --git a/src/FEP/pair_lj_cut_coul_cut_soft.cpp b/src/FEP/pair_lj_cut_coul_cut_soft.cpp index 49d6d84957..b6b9063d0f 100644 --- a/src/FEP/pair_lj_cut_coul_cut_soft.cpp +++ b/src/FEP/pair_lj_cut_coul_cut_soft.cpp @@ -18,17 +18,17 @@ #include "pair_lj_cut_coul_cut_soft.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -270,7 +270,7 @@ void PairLJCutCoulCutSoft::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style lj/cut/coul/cut/soft requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/FEP/pair_lj_cut_coul_long_soft.cpp b/src/FEP/pair_lj_cut_coul_long_soft.cpp index 0e43e72a17..7fdc431c61 100644 --- a/src/FEP/pair_lj_cut_coul_long_soft.cpp +++ b/src/FEP/pair_lj_cut_coul_long_soft.cpp @@ -19,21 +19,20 @@ #include "pair_lj_cut_coul_long_soft.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "respa.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -631,23 +630,16 @@ void PairLJCutCoulLongSoft::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style lj/cut/coul/long/soft requires atom attribute q"); - // request regular or rRESPA neighbor lists + // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); cut_coulsq = cut_coul * cut_coul; diff --git a/src/FEP/pair_lj_cut_soft.cpp b/src/FEP/pair_lj_cut_soft.cpp index e4c2d19e95..cf0a5df644 100644 --- a/src/FEP/pair_lj_cut_soft.cpp +++ b/src/FEP/pair_lj_cut_soft.cpp @@ -19,20 +19,19 @@ #include "pair_lj_cut_soft.h" -#include -#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "update.h" #include "respa.h" #include "math_const.h" #include "memory.h" #include "error.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -509,23 +508,16 @@ void PairLJCutSoft::coeff(int narg, char **arg) void PairLJCutSoft::init_style() { - // request regular or rRESPA neighbor lists + // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); // set rRESPA cutoffs diff --git a/src/GPU/pair_beck_gpu.cpp b/src/GPU/pair_beck_gpu.cpp index a9695a0b73..1c95becba7 100644 --- a/src/GPU/pair_beck_gpu.cpp +++ b/src/GPU/pair_beck_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "gpu_extra.h" #include "math_special.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -37,23 +35,19 @@ using namespace MathSpecial; // External functions from cuda library for atom decomposition -int beck_gpu_init(const int ntypes, double **cutsq, double **host_aa, - double **alpha, double **beta, double **AA, double **BB, - double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen); +int beck_gpu_init(const int ntypes, double **cutsq, double **host_aa, double **alpha, double **beta, + double **AA, double **BB, double *special_lj, const int nlocal, const int nall, + const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, + FILE *screen); void beck_gpu_clear(); -int ** beck_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void beck_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **beck_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void beck_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double beck_gpu_bytes(); @@ -81,7 +75,7 @@ PairBeckGPU::~PairBeckGPU() void PairBeckGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -89,7 +83,7 @@ void PairBeckGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -98,28 +92,24 @@ void PairBeckGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = beck_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + beck_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - beck_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + beck_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -150,21 +139,15 @@ void PairBeckGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = beck_gpu_init(atom->ntypes+1, cutsq, aa, alpha, beta, - AA, BB, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = beck_gpu_init(atom->ntypes + 1, cutsq, aa, alpha, beta, AA, BB, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, + gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -177,15 +160,15 @@ double PairBeckGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBeckGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r5,force_beck,factor_lj; - double r,rinv; - double aaij,alphaij,betaij; - double term1,term1inv,term2,term3,term4,term5,term6; +void PairBeckGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r5, force_beck, factor_lj; + double r, rinv; + double aaij, alphaij, betaij; + double term1, term1inv, term2, term3, term4, term5, term6; int *jlist; double **x = atom->x; @@ -212,39 +195,39 @@ void PairBeckGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { r = sqrt(rsq); - r5 = rsq*rsq*r; + r5 = rsq * rsq * r; aaij = aa[itype][jtype]; alphaij = alpha[itype][jtype]; betaij = beta[itype][jtype]; - term1 = aaij*aaij + rsq; - term2 = powint(term1,-5); - term3 = 21.672 + 30.0*aaij*aaij + 6.0*rsq; - term4 = alphaij + r5*betaij; - term5 = alphaij + 6.0*r5*betaij; - rinv = 1.0/r; - force_beck = AA[itype][jtype]*exp(-1.0*r*term4)*term5; - force_beck -= BB[itype][jtype]*r*term2*term3; + term1 = aaij * aaij + rsq; + term2 = powint(term1, -5); + term3 = 21.672 + 30.0 * aaij * aaij + 6.0 * rsq; + term4 = alphaij + r5 * betaij; + term5 = alphaij + 6.0 * r5 * betaij; + rinv = 1.0 / r; + force_beck = AA[itype][jtype] * exp(-1.0 * r * term4) * term5; + force_beck -= BB[itype][jtype] * r * term2 * term3; - fpair = factor_lj*force_beck*rinv; + fpair = factor_lj * force_beck * rinv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - term6 = powint(term1,-3); - term1inv = 1.0/term1; - evdwl = AA[itype][jtype]*exp(-1.0*r*term4); - evdwl -= BB[itype][jtype]*term6*(1.0+(2.709+3.0*aaij*aaij)*term1inv); + term6 = powint(term1, -3); + term1inv = 1.0 / term1; + evdwl = AA[itype][jtype] * exp(-1.0 * r * term4); + evdwl -= BB[itype][jtype] * term6 * (1.0 + (2.709 + 3.0 * aaij * aaij) * term1inv); evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_born_coul_long_cs_gpu.cpp b/src/GPU/pair_born_coul_long_cs_gpu.cpp index c358aa0945..5b414a5b07 100644 --- a/src/GPU/pair_born_coul_long_cs_gpu.cpp +++ b/src/GPU/pair_born_coul_long_cs_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "kspace.h" #include "math_const.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -35,14 +33,14 @@ using namespace LAMMPS_NS; using namespace MathConst; -#define EWALD_F 1.12837917 -#define EWALD_P 9.95473818e-1 -#define B0 -0.1335096380159268 -#define B1 -2.57839507e-1 -#define B2 -1.37203639e-1 -#define B3 -8.88822059e-3 -#define B4 -5.80844129e-3 -#define B5 1.14652755e-1 +#define EWALD_F 1.12837917 +#define EWALD_P 9.95473818e-1 +#define B0 -0.1335096380159268 +#define B1 -2.57839507e-1 +#define B2 -1.37203639e-1 +#define B3 -8.88822059e-3 +#define B4 -5.80844129e-3 +#define B5 1.14652755e-1 #define EPSILON 1.0e-20 #define EPS_EWALD 1.0e-6 @@ -50,37 +48,31 @@ using namespace MathConst; // External functions from cuda library for atom decomposition -int bornclcs_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_born1, double **host_born2, - double **host_born3, double **host_a, - double **host_c, double **host_d, - double **sigma, double **offset, double *special_lj, - const int inum, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen, double **host_cut_ljsq, - double host_cut_coulsq, double *host_special_coul, - const double qqrd2e, const double g_ewald); +int bornclcs_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, double **host_born1, + double **host_born2, double **host_born3, double **host_a, double **host_c, + double **host_d, double **sigma, double **offset, double *special_lj, + const int inum, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double host_cut_coulsq, double *host_special_coul, const double qqrd2e, + const double g_ewald); void bornclcs_gpu_clear(); -int** bornclcs_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void bornclcs_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **bornclcs_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, double *host_q, + double *boxlo, double *prd); +void bornclcs_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double bornclcs_gpu_bytes(); /* ---------------------------------------------------------------------- */ PairBornCoulLongCSGPU::PairBornCoulLongCSGPU(LAMMPS *lmp) : - PairBornCoulLongCS(lmp), gpu_mode(GPU_FORCE) + PairBornCoulLongCS(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -102,7 +94,7 @@ PairBornCoulLongCSGPU::~PairBornCoulLongCSGPU() void PairBornCoulLongCSGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -110,7 +102,7 @@ void PairBornCoulLongCSGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -119,30 +111,25 @@ void PairBornCoulLongCSGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = bornclcs_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = bornclcs_gpu_compute_n( + neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, atom->nspecial, + atom->special, eflag, vflag, eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - bornclcs_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, - atom->nlocal, domain->boxlo, domain->prd); + bornclcs_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, + success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -179,29 +165,20 @@ void PairBornCoulLongCSGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = bornclcs_gpu_init(atom->ntypes+1, cutsq, rhoinv, - born1, born2, born3, a, c, d, sigma, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, - force->qqrd2e, g_ewald); + int success = bornclcs_gpu_init( + atom->ntypes + 1, cutsq, rhoinv, born1, born2, born3, a, c, d, sigma, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, + gpu_mode, screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -214,15 +191,14 @@ double PairBornCoulLongCSGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBornCoulLongCSGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) +void PairBornCoulLongCSGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itable,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double fraction,table; - double r,rsq,rexp,r2inv,r6inv,forcecoul,forceborn,factor_coul,factor_lj; - double grij,expm2,prefactor,t,erfc,u; + int i, j, ii, jj, jnum, itable, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double fraction, table; + double r, rsq, rexp, r2inv, r6inv, forcecoul, forceborn, factor_coul, factor_lj; + double grij, expm2, prefactor, t, erfc, u; int *jlist; evdwl = ecoul = 0.0; @@ -256,39 +232,42 @@ void PairBornCoulLongCSGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { if (rsq < cut_coulsq) { - rsq += EPSILON; // Add Epsilon for case: r = 0; Interaction must be removed by special bond; - r2inv = 1.0/rsq; + rsq += + EPSILON; // Add Epsilon for case: r = 0; Interaction must be removed by special bond; + r2inv = 1.0 / rsq; if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); - prefactor = qqrd2e * qtmp*q[j]; + prefactor = qqrd2e * qtmp * q[j]; if (factor_coul < 1.0) { // When bonded parts are being calculated a minimal distance (EPS_EWALD) // has to be added to the prefactor and erfc in order to make the // used approximation functions for the Ewald correction valid - grij = g_ewald * (r+EPS_EWALD); - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); + grij = g_ewald * (r + EPS_EWALD); + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); u = 1.0 - t; - erfc = t * (1.+u*(B0+u*(B1+u*(B2+u*(B3+u*(B4+u*B5)))))) * expm2; - prefactor /= (r+EPS_EWALD); - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2 - (1.0-factor_coul)); + erfc = + t * (1. + u * (B0 + u * (B1 + u * (B2 + u * (B3 + u * (B4 + u * B5)))))) * expm2; + prefactor /= (r + EPS_EWALD); + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2 - (1.0 - factor_coul)); // Additionally r2inv needs to be accordingly modified since the later // scaling of the overall force shall be consistent - r2inv = 1.0/(rsq + EPS_EWALD_SQR); + r2inv = 1.0 / (rsq + EPS_EWALD_SQR); } else { grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); u = 1.0 - t; - erfc = t * (1.+u*(B0+u*(B1+u*(B2+u*(B3+u*(B4+u*B5)))))) * expm2; + erfc = + t * (1. + u * (B0 + u * (B1 + u * (B2 + u * (B3 + u * (B4 + u * B5)))))) * expm2; prefactor /= r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); } } else { union_int_float_t rsq_lookup; @@ -296,47 +275,51 @@ void PairBornCoulLongCSGPU::cpu_compute(int start, int inum, int eflag, itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = qtmp*q[j] * table; + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = qtmp * q[j] * table; if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = qtmp*q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = qtmp * q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; } } forcecoul *= r2inv; - } else forcecoul = 0; + } else + forcecoul = 0; - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; r = sqrt(rsq); if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - rexp = exp((sigma[itype][jtype]-r)*rhoinv[itype][jtype]); - forceborn = born1[itype][jtype]*r*rexp - born2[itype][jtype]*r6inv - + born3[itype][jtype]*r2inv*r6inv; - } else forceborn = 0.0; + r6inv = r2inv * r2inv * r2inv; + rexp = exp((sigma[itype][jtype] - r) * rhoinv[itype][jtype]); + forceborn = born1[itype][jtype] * r * rexp - born2[itype][jtype] * r6inv + + born3[itype][jtype] * r2inv * r6inv; + } else + forceborn = 0.0; - fpair = forcecoul + factor_lj*forceborn * r2inv; + fpair = forcecoul + factor_lj * forceborn * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { - ecoul = prefactor*erfc; - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + ecoul = prefactor * erfc; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv - + d[itype][jtype]*r6inv*r2inv - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv + + d[itype][jtype] * r6inv * r2inv - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_born_coul_long_gpu.cpp b/src/GPU/pair_born_coul_long_gpu.cpp index bb4359696f..1cafc55213 100644 --- a/src/GPU/pair_born_coul_long_gpu.cpp +++ b/src/GPU/pair_born_coul_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,56 +25,48 @@ #include "kspace.h" #include "math_const.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; using namespace MathConst; // External functions from cuda library for atom decomposition -int borncl_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_born1, double **host_born2, - double **host_born3, double **host_a, - double **host_c, double **host_d, - double **sigma, double **offset, double *special_lj, - const int inum, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen, double **host_cut_ljsq, - double host_cut_coulsq, double *host_special_coul, - const double qqrd2e, const double g_ewald); +int borncl_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, double **host_born1, + double **host_born2, double **host_born3, double **host_a, double **host_c, + double **host_d, double **sigma, double **offset, double *special_lj, + const int inum, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double host_cut_coulsq, double *host_special_coul, const double qqrd2e, + const double g_ewald); void borncl_gpu_clear(); -int** borncl_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void borncl_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **borncl_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, double *host_q, + double *boxlo, double *prd); +void borncl_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double borncl_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairBornCoulLongGPU::PairBornCoulLongGPU(LAMMPS *lmp) : - PairBornCoulLong(lmp), gpu_mode(GPU_FORCE) +PairBornCoulLongGPU::PairBornCoulLongGPU(LAMMPS *lmp) : PairBornCoulLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -97,7 +88,7 @@ PairBornCoulLongGPU::~PairBornCoulLongGPU() void PairBornCoulLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -105,7 +96,7 @@ void PairBornCoulLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -114,30 +105,25 @@ void PairBornCoulLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = borncl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = borncl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - borncl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + borncl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR, "Pair style born/coul/long/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style born/coul/long/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -159,10 +144,9 @@ void PairBornCoulLongGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -174,33 +158,24 @@ void PairBornCoulLongGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = borncl_gpu_init(atom->ntypes+1, cutsq, rhoinv, - born1, born2, born3, a, c, d, sigma, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, - force->qqrd2e, g_ewald); + int success = borncl_gpu_init( + atom->ntypes + 1, cutsq, rhoinv, born1, born2, born3, a, c, d, sigma, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, + gpu_mode, screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -213,14 +188,13 @@ double PairBornCoulLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBornCoulLongGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairBornCoulLongGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double r,rexp,r2inv,r6inv,forcecoul,forceborn,factor_coul,factor_lj; - double grij,expm2,prefactor,t,erfc; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double r, rexp, r2inv, r6inv, forcecoul, forceborn, factor_coul, factor_lj; + double grij, expm2, prefactor, t, erfc; int *jlist; double rsq; @@ -255,49 +229,53 @@ void PairBornCoulLongGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; r = sqrt(rsq); if (rsq < cut_coulsq) { grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; - } else forcecoul = 0.0; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - rexp = exp((sigma[itype][jtype]-r)*rhoinv[itype][jtype]); - forceborn = born1[itype][jtype]*r*rexp - born2[itype][jtype]*r6inv - + born3[itype][jtype]*r2inv*r6inv; - } else forceborn = 0.0; + r6inv = r2inv * r2inv * r2inv; + rexp = exp((sigma[itype][jtype] - r) * rhoinv[itype][jtype]); + forceborn = born1[itype][jtype] * r * rexp - born2[itype][jtype] * r6inv + + born3[itype][jtype] * r2inv * r6inv; + } else + forceborn = 0.0; - fpair = (forcecoul + factor_lj*forceborn) * r2inv; + fpair = (forcecoul + factor_lj * forceborn) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { - ecoul = prefactor*erfc; - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + ecoul = prefactor * erfc; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv - + d[itype][jtype]*r6inv*r2inv - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv + + d[itype][jtype] * r6inv * r2inv - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_born_coul_wolf_cs_gpu.cpp b/src/GPU/pair_born_coul_wolf_cs_gpu.cpp index f7d8ed5faa..4493ec18cc 100644 --- a/src/GPU/pair_born_coul_wolf_cs_gpu.cpp +++ b/src/GPU/pair_born_coul_wolf_cs_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,7 +24,6 @@ #include "gpu_extra.h" #include "math_const.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -38,39 +36,31 @@ using namespace MathConst; // External functions from cuda library for atom decomposition -int borncwcs_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_born1, double **host_born2, - double **host_born3, double **host_a, double **host_c, - double **host_d, double **sigma, double **offset, - double *special_lj, const int inum, const int nall, - const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, - const double alf, const double e_shift, - const double f_shift); +int borncwcs_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, double **host_born1, + double **host_born2, double **host_born3, double **host_a, double **host_c, + double **host_d, double **sigma, double **offset, double *special_lj, + const int inum, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double host_cut_coulsq, double *host_special_coul, const double qqrd2e, + const double alf, const double e_shift, const double f_shift); void borncwcs_gpu_clear(); -int ** borncwcs_gpu_compute_n(const int ago, const int inum_full, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, - const bool eflag, const bool vflag, - const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, - double *host_q, double *boxlo, double *prd); -void borncwcs_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **borncwcs_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, double *host_q, + double *boxlo, double *prd); +void borncwcs_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double borncwcs_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairBornCoulWolfCSGPU::PairBornCoulWolfCSGPU(LAMMPS *lmp) : PairBornCoulWolfCS(lmp), - gpu_mode(GPU_FORCE) +PairBornCoulWolfCSGPU::PairBornCoulWolfCSGPU(LAMMPS *lmp) : + PairBornCoulWolfCS(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -92,7 +82,7 @@ PairBornCoulWolfCSGPU::~PairBornCoulWolfCSGPU() void PairBornCoulWolfCSGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -100,7 +90,7 @@ void PairBornCoulWolfCSGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -109,30 +99,25 @@ void PairBornCoulWolfCSGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = borncwcs_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success, - atom->q, domain->boxlo, domain->prd); + firstneigh = borncwcs_gpu_compute_n( + neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, atom->nspecial, + atom->special, eflag, vflag, eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - borncwcs_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, - atom->nlocal, domain->boxlo, domain->prd); + borncwcs_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, + success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -167,28 +151,21 @@ void PairBornCoulWolfCSGPU::init_style() cut_coulsq = cut_coul * cut_coul; - double e_shift = erfc(alf*cut_coul)/cut_coul; - double f_shift = -(e_shift+ 2.0*alf/MY_PIS * exp(-alf*alf*cut_coul*cut_coul)) / - cut_coul; + double e_shift = erfc(alf * cut_coul) / cut_coul; + double f_shift = + -(e_shift + 2.0 * alf / MY_PIS * exp(-alf * alf * cut_coul * cut_coul)) / cut_coul; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = borncwcs_gpu_init(atom->ntypes+1, cutsq, rhoinv, - born1, born2, born3, a, c, d, sigma, offset, - force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, force->qqrd2e, - alf, e_shift, f_shift); - GPU_EXTRA::check_flag(success,error,world); + int success = + borncwcs_gpu_init(atom->ntypes + 1, cutsq, rhoinv, born1, born2, born3, a, c, d, sigma, + offset, force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, + force->special_coul, force->qqrd2e, alf, e_shift, f_shift); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -201,15 +178,15 @@ double PairBornCoulWolfCSGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBornCoulWolfCSGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,qtmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,forcecoul,forceborn,factor_coul,factor_lj; - double erfcc,erfcd,v_sh,dvdrr,e_self,qisq; +void PairBornCoulWolfCSGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, qtmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, forcecoul, forceborn, factor_coul, factor_lj; + double erfcc, erfcd, v_sh, dvdrr, e_self, qisq; double prefactor; - double r,rexp; + double r, rexp; int *jlist; evdwl = ecoul = 0.0; @@ -223,9 +200,9 @@ void PairBornCoulWolfCSGPU::cpu_compute(int start, int inum, int eflag, double *special_lj = force->special_lj; double qqrd2e = force->qqrd2e; - double e_shift = erfc(alf*cut_coul)/cut_coul; - double f_shift = -(e_shift+ 2.0*alf/MY_PIS * exp(-alf*alf*cut_coul*cut_coul)) / - cut_coul; + double e_shift = erfc(alf * cut_coul) / cut_coul; + double f_shift = + -(e_shift + 2.0 * alf / MY_PIS * exp(-alf * alf * cut_coul * cut_coul)) / cut_coul; // loop over neighbors of my atoms @@ -239,9 +216,9 @@ void PairBornCoulWolfCSGPU::cpu_compute(int start, int inum, int eflag, jlist = firstneigh[i]; jnum = numneigh[i]; - qisq = qtmp*qtmp; - e_self = -(e_shift/2.0 + alf/MY_PIS) * qisq*qqrd2e; - if (evflag) ev_tally(i,i,nlocal,0,0.0,e_self,0.0,0.0,0.0,0.0); + qisq = qtmp * qtmp; + e_self = -(e_shift / 2.0 + alf / MY_PIS) * qisq * qqrd2e; + if (evflag) ev_tally(i, i, nlocal, 0, 0.0, e_self, 0.0, 0.0, 0.0, 0.0); for (jj = 0; jj < jnum; jj++) { j = jlist[jj]; @@ -252,51 +229,56 @@ void PairBornCoulWolfCSGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - rsq += EPSILON; // Add EPSILON for case: r = 0; Interaction must be removed by special bond - r2inv = 1.0/rsq; + rsq += + EPSILON; // Add EPSILON for case: r = 0; Interaction must be removed by special bond + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { r = sqrt(rsq); - prefactor = qqrd2e*qtmp*q[j]/r; - erfcc = erfc(alf*r); - erfcd = exp(-alf*alf*r*r); - v_sh = (erfcc - e_shift*r) * prefactor; - dvdrr = (erfcc/rsq + 2.0*alf/MY_PIS * erfcd/r) + f_shift; - forcecoul = dvdrr*rsq*prefactor; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; - } else forcecoul = 0.0; + prefactor = qqrd2e * qtmp * q[j] / r; + erfcc = erfc(alf * r); + erfcd = exp(-alf * alf * r * r); + v_sh = (erfcc - e_shift * r) * prefactor; + dvdrr = (erfcc / rsq + 2.0 * alf / MY_PIS * erfcd / r) + f_shift; + forcecoul = dvdrr * rsq * prefactor; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; + r6inv = r2inv * r2inv * r2inv; r = sqrt(rsq); - rexp = exp((sigma[itype][jtype]-r)*rhoinv[itype][jtype]); - forceborn = born1[itype][jtype]*r*rexp - born2[itype][jtype]*r6inv + - born3[itype][jtype]*r2inv*r6inv; - } else forceborn = 0.0; + rexp = exp((sigma[itype][jtype] - r) * rhoinv[itype][jtype]); + forceborn = born1[itype][jtype] * r * rexp - born2[itype][jtype] * r6inv + + born3[itype][jtype] * r2inv * r6inv; + } else + forceborn = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forceborn) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forceborn) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { ecoul = v_sh; - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv + - d[itype][jtype]*r6inv*r2inv - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv + + d[itype][jtype] * r6inv * r2inv - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_born_coul_wolf_gpu.cpp b/src/GPU/pair_born_coul_wolf_gpu.cpp index 17a5165e04..16dbd93812 100644 --- a/src/GPU/pair_born_coul_wolf_gpu.cpp +++ b/src/GPU/pair_born_coul_wolf_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,7 +24,6 @@ #include "gpu_extra.h" #include "math_const.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -36,39 +34,30 @@ using namespace MathConst; // External functions from cuda library for atom decomposition -int borncw_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_born1, double **host_born2, - double **host_born3, double **host_a, double **host_c, - double **host_d, double **sigma, double **offset, - double *special_lj, const int inum, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, - const double alf, const double e_shift, - const double f_shift); +int borncw_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, double **host_born1, + double **host_born2, double **host_born3, double **host_a, double **host_c, + double **host_d, double **sigma, double **offset, double *special_lj, + const int inum, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double host_cut_coulsq, double *host_special_coul, const double qqrd2e, + const double alf, const double e_shift, const double f_shift); void borncw_gpu_clear(); -int ** borncw_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, - const bool vflag, const bool eatom, - const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void borncw_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **borncw_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, double *host_q, + double *boxlo, double *prd); +void borncw_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double borncw_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairBornCoulWolfGPU::PairBornCoulWolfGPU(LAMMPS *lmp) : PairBornCoulWolf(lmp), - gpu_mode(GPU_FORCE) +PairBornCoulWolfGPU::PairBornCoulWolfGPU(LAMMPS *lmp) : PairBornCoulWolf(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -90,7 +79,7 @@ PairBornCoulWolfGPU::~PairBornCoulWolfGPU() void PairBornCoulWolfGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -98,7 +87,7 @@ void PairBornCoulWolfGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -107,30 +96,25 @@ void PairBornCoulWolfGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = borncw_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success, - atom->q, domain->boxlo, domain->prd); + firstneigh = borncw_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - borncw_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + borncw_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR, "Pair style born/coul/wolf/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style born/coul/wolf/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -152,10 +135,9 @@ void PairBornCoulWolfGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -165,28 +147,21 @@ void PairBornCoulWolfGPU::init_style() cut_coulsq = cut_coul * cut_coul; - double e_shift = erfc(alf*cut_coul)/cut_coul; - double f_shift = -(e_shift+ 2.0*alf/MY_PIS * exp(-alf*alf*cut_coul*cut_coul)) / - cut_coul; + double e_shift = erfc(alf * cut_coul) / cut_coul; + double f_shift = + -(e_shift + 2.0 * alf / MY_PIS * exp(-alf * alf * cut_coul * cut_coul)) / cut_coul; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = borncw_gpu_init(atom->ntypes+1, cutsq, rhoinv, - born1, born2, born3, a, c, d, sigma, offset, - force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, force->qqrd2e, - alf, e_shift, f_shift); - GPU_EXTRA::check_flag(success,error,world); + int success = + borncw_gpu_init(atom->ntypes + 1, cutsq, rhoinv, born1, born2, born3, a, c, d, sigma, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, + cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, force->special_coul, + force->qqrd2e, alf, e_shift, f_shift); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -199,15 +174,15 @@ double PairBornCoulWolfGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBornCoulWolfGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,qtmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,forcecoul,forceborn,factor_coul,factor_lj; - double erfcc,erfcd,v_sh,dvdrr,e_self,qisq; +void PairBornCoulWolfGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, qtmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, forcecoul, forceborn, factor_coul, factor_lj; + double erfcc, erfcd, v_sh, dvdrr, e_self, qisq; double prefactor; - double r,rexp; + double r, rexp; int *jlist; evdwl = ecoul = 0.0; @@ -221,9 +196,9 @@ void PairBornCoulWolfGPU::cpu_compute(int start, int inum, int eflag, double *special_lj = force->special_lj; double qqrd2e = force->qqrd2e; - double e_shift = erfc(alf*cut_coul)/cut_coul; - double f_shift = -(e_shift+ 2.0*alf/MY_PIS * exp(-alf*alf*cut_coul*cut_coul)) / - cut_coul; + double e_shift = erfc(alf * cut_coul) / cut_coul; + double f_shift = + -(e_shift + 2.0 * alf / MY_PIS * exp(-alf * alf * cut_coul * cut_coul)) / cut_coul; // loop over neighbors of my atoms @@ -237,9 +212,9 @@ void PairBornCoulWolfGPU::cpu_compute(int start, int inum, int eflag, jlist = firstneigh[i]; jnum = numneigh[i]; - qisq = qtmp*qtmp; - e_self = -(e_shift/2.0 + alf/MY_PIS) * qisq*qqrd2e; - if (evflag) ev_tally(i,i,nlocal,0,0.0,e_self,0.0,0.0,0.0,0.0); + qisq = qtmp * qtmp; + e_self = -(e_shift / 2.0 + alf / MY_PIS) * qisq * qqrd2e; + if (evflag) ev_tally(i, i, nlocal, 0, 0.0, e_self, 0.0, 0.0, 0.0, 0.0); for (jj = 0; jj < jnum; jj++) { j = jlist[jj]; @@ -250,50 +225,54 @@ void PairBornCoulWolfGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { r = sqrt(rsq); - prefactor = qqrd2e*qtmp*q[j]/r; - erfcc = erfc(alf*r); - erfcd = exp(-alf*alf*r*r); - v_sh = (erfcc - e_shift*r) * prefactor; - dvdrr = (erfcc/rsq + 2.0*alf/MY_PIS * erfcd/r) + f_shift; - forcecoul = dvdrr*rsq*prefactor; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; - } else forcecoul = 0.0; + prefactor = qqrd2e * qtmp * q[j] / r; + erfcc = erfc(alf * r); + erfcd = exp(-alf * alf * r * r); + v_sh = (erfcc - e_shift * r) * prefactor; + dvdrr = (erfcc / rsq + 2.0 * alf / MY_PIS * erfcd / r) + f_shift; + forcecoul = dvdrr * rsq * prefactor; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; + r6inv = r2inv * r2inv * r2inv; r = sqrt(rsq); - rexp = exp((sigma[itype][jtype]-r)*rhoinv[itype][jtype]); - forceborn = born1[itype][jtype]*r*rexp - born2[itype][jtype]*r6inv + - born3[itype][jtype]*r2inv*r6inv; - } else forceborn = 0.0; + rexp = exp((sigma[itype][jtype] - r) * rhoinv[itype][jtype]); + forceborn = born1[itype][jtype] * r * rexp - born2[itype][jtype] * r6inv + + born3[itype][jtype] * r2inv * r6inv; + } else + forceborn = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forceborn) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forceborn) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { ecoul = v_sh; - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv + - d[itype][jtype]*r6inv*r2inv - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv + + d[itype][jtype] * r6inv * r2inv - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_born_gpu.cpp b/src/GPU/pair_born_gpu.cpp index 436dfef6fb..3ff08858bb 100644 --- a/src/GPU/pair_born_gpu.cpp +++ b/src/GPU/pair_born_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,29 +32,23 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int born_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_born1, double **host_born2, double **host_born3, - double **host_a, double **host_c, double **host_d, - double **host_sigma, double **offset, double *special_lj, - const int inum, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen); -void born_gpu_reinit(const int ntypes, double **host_rhoinv, - double **host_born1, double **host_born2, - double **host_born3, double **host_a, double **host_c, +int born_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, double **host_born1, + double **host_born2, double **host_born3, double **host_a, double **host_c, + double **host_d, double **host_sigma, double **offset, double *special_lj, + const int inum, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen); +void born_gpu_reinit(const int ntypes, double **host_rhoinv, double **host_born1, + double **host_born2, double **host_born3, double **host_a, double **host_c, double **host_d, double **offset); void born_gpu_clear(); -int ** born_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success); -void born_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **born_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void born_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double born_gpu_bytes(); @@ -83,7 +75,7 @@ PairBornGPU::~PairBornGPU() void PairBornGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -91,7 +83,7 @@ void PairBornGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -100,28 +92,24 @@ void PairBornGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = born_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + born_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - born_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + born_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -152,22 +139,15 @@ void PairBornGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = born_gpu_init(atom->ntypes+1, cutsq, rhoinv, - born1, born2, born3, a, c, d, sigma, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = born_gpu_init(atom->ntypes + 1, cutsq, rhoinv, born1, born2, born3, a, c, d, sigma, + offset, force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, + mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -176,8 +156,7 @@ void PairBornGPU::reinit() { Pair::reinit(); - born_gpu_reinit(atom->ntypes+1, rhoinv, born1, born2, born3, - a, c, d, offset); + born_gpu_reinit(atom->ntypes + 1, rhoinv, born1, born2, born3, a, c, d, offset); } /* ---------------------------------------------------------------------- */ @@ -190,13 +169,13 @@ double PairBornGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBornGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r6inv,forceborn,factor_lj; - double r,rexp; +void PairBornGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r6inv, forceborn, factor_lj; + double r, rexp; int *jlist; double **x = atom->x; @@ -223,29 +202,29 @@ void PairBornGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; r = sqrt(rsq); - rexp = exp((sigma[itype][jtype]-r)*rhoinv[itype][jtype]); - forceborn = born1[itype][jtype]*r*rexp - born2[itype][jtype]*r6inv + - born3[itype][jtype]*r2inv*r6inv; - fpair = factor_lj*forceborn*r2inv; + rexp = exp((sigma[itype][jtype] - r) * rhoinv[itype][jtype]); + forceborn = born1[itype][jtype] * r * rexp - born2[itype][jtype] * r6inv + + born3[itype][jtype] * r2inv * r6inv; + fpair = factor_lj * forceborn * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv + - d[itype][jtype]*r6inv*r2inv - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv + + d[itype][jtype] * r6inv * r2inv - offset[itype][jtype]; evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_buck_coul_cut_gpu.cpp b/src/GPU/pair_buck_coul_cut_gpu.cpp index 3c3ae40370..c972fbfc78 100644 --- a/src/GPU/pair_buck_coul_cut_gpu.cpp +++ b/src/GPU/pair_buck_coul_cut_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,35 +32,29 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int buckc_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_buck1, double **host_buck2, double **host_a, - double **host_c, double **offset, double *special_lj, - const int inum, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen, double **host_cut_ljsq, - double **host_cut_coulsq, double *host_special_coul, +int buckc_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, double **host_buck1, + double **host_buck2, double **host_a, double **host_c, double **offset, + double *special_lj, const int inum, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + double **host_cut_ljsq, double **host_cut_coulsq, double *host_special_coul, const double qqrd2e); void buckc_gpu_clear(); -int ** buckc_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void buckc_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **buckc_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void buckc_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double buckc_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairBuckCoulCutGPU::PairBuckCoulCutGPU(LAMMPS *lmp) : PairBuckCoulCut(lmp), - gpu_mode(GPU_FORCE) +PairBuckCoulCutGPU::PairBuckCoulCutGPU(LAMMPS *lmp) : PairBuckCoulCut(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -84,7 +76,7 @@ PairBuckCoulCutGPU::~PairBuckCoulCutGPU() void PairBuckCoulCutGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -92,7 +84,7 @@ void PairBuckCoulCutGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -101,30 +93,25 @@ void PairBuckCoulCutGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = buckc_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success, - atom->q, domain->boxlo, domain->prd); + firstneigh = buckc_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - buckc_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + buckc_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR, "Pair style buck/coul/cut/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style buck/coul/cut/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -146,10 +132,9 @@ void PairBuckCoulCutGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -157,22 +142,16 @@ void PairBuckCoulCutGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = buckc_gpu_init(atom->ntypes+1, cutsq, rhoinv, buck1, buck2, - a, c, offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, force->qqrd2e); - GPU_EXTRA::check_flag(success,error,world); + int success = + buckc_gpu_init(atom->ntypes + 1, cutsq, rhoinv, buck1, buck2, a, c, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, + gpu_mode, screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -185,13 +164,13 @@ double PairBuckCoulCutGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBuckCoulCutGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,qtmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,forcecoul,forcebuck,factor_coul,factor_lj; - double r,rexp; +void PairBuckCoulCutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, qtmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, forcecoul, forcebuck, factor_coul, factor_lj; + double r, rexp; int *jlist; evdwl = ecoul = 0.0; @@ -225,41 +204,44 @@ void PairBuckCoulCutGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; r = sqrt(rsq); if (rsq < cut_coulsq[itype][jtype]) - forcecoul = qqrd2e * qtmp*q[j]/r; - else forcecoul = 0.0; + forcecoul = qqrd2e * qtmp * q[j] / r; + else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - rexp = exp(-r*rhoinv[itype][jtype]); - forcebuck = buck1[itype][jtype]*r*rexp - buck2[itype][jtype]*r6inv; - } else forcebuck = 0.0; + r6inv = r2inv * r2inv * r2inv; + rexp = exp(-r * rhoinv[itype][jtype]); + forcebuck = buck1[itype][jtype] * r * rexp - buck2[itype][jtype] * r6inv; + } else + forcebuck = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forcebuck) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forcebuck) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq[itype][jtype]) - ecoul = factor_coul * qqrd2e * qtmp*q[j]/r; - else ecoul = 0.0; + ecoul = factor_coul * qqrd2e * qtmp * q[j] / r; + else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv - - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_buck_coul_long_gpu.cpp b/src/GPU/pair_buck_coul_long_gpu.cpp index 96ac39adae..6de1e8480b 100644 --- a/src/GPU/pair_buck_coul_long_gpu.cpp +++ b/src/GPU/pair_buck_coul_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,53 +24,46 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int buckcl_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_buck1, double **host_buck2, double **host_a, - double **host_c, double **offset, double *special_lj, - const int inum, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen, double **host_cut_ljsq, - double host_cut_coulsq, double *host_special_coul, +int buckcl_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, double **host_buck1, + double **host_buck2, double **host_a, double **host_c, double **offset, + double *special_lj, const int inum, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + double **host_cut_ljsq, double host_cut_coulsq, double *host_special_coul, const double qqrd2e, const double g_ewald); void buckcl_gpu_clear(); -int** buckcl_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void buckcl_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **buckcl_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, double *host_q, + double *boxlo, double *prd); +void buckcl_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double buckcl_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairBuckCoulLongGPU::PairBuckCoulLongGPU(LAMMPS *lmp) : - PairBuckCoulLong(lmp), gpu_mode(GPU_FORCE) +PairBuckCoulLongGPU::PairBuckCoulLongGPU(LAMMPS *lmp) : PairBuckCoulLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -93,7 +85,7 @@ PairBuckCoulLongGPU::~PairBuckCoulLongGPU() void PairBuckCoulLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -101,7 +93,7 @@ void PairBuckCoulLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -110,30 +102,25 @@ void PairBuckCoulLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = buckcl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = buckcl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - buckcl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + buckcl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR, "Pair style buck/coul/long/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style buck/coul/long/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -155,10 +141,9 @@ void PairBuckCoulLongGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -170,31 +155,23 @@ void PairBuckCoulLongGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = buckcl_gpu_init(atom->ntypes+1, cutsq, rhoinv, buck1, buck2, - a, c, offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, force->qqrd2e, - g_ewald); - GPU_EXTRA::check_flag(success,error,world); + int success = buckcl_gpu_init(atom->ntypes + 1, cutsq, rhoinv, buck1, buck2, a, c, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, + force->special_coul, force->qqrd2e, g_ewald); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -207,14 +184,13 @@ double PairBuckCoulLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBuckCoulLongGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) +void PairBuckCoulLongGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double r,rexp,r2inv,r6inv,forcecoul,forcebuck,factor_coul,factor_lj; - double grij,expm2,prefactor,t,erfc; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double r, rexp, r2inv, r6inv, forcecoul, forcebuck, factor_coul, factor_lj; + double grij, expm2, prefactor, t, erfc; int *jlist; double rsq; @@ -249,48 +225,51 @@ void PairBuckCoulLongGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; r = sqrt(rsq); if (rsq < cut_coulsq) { grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; - } else forcecoul = 0.0; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - rexp = exp(-r*rhoinv[itype][jtype]); - forcebuck = buck1[itype][jtype]*r*rexp - buck2[itype][jtype]*r6inv; - } else forcebuck = 0.0; + r6inv = r2inv * r2inv * r2inv; + rexp = exp(-r * rhoinv[itype][jtype]); + forcebuck = buck1[itype][jtype] * r * rexp - buck2[itype][jtype] * r6inv; + } else + forcebuck = 0.0; - fpair = (forcecoul + factor_lj*forcebuck) * r2inv; + fpair = (forcecoul + factor_lj * forcebuck) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { - ecoul = prefactor*erfc; - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + ecoul = prefactor * erfc; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv - - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_buck_gpu.cpp b/src/GPU/pair_buck_gpu.cpp index 7af0455a84..da07af8eff 100644 --- a/src/GPU/pair_buck_gpu.cpp +++ b/src/GPU/pair_buck_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,27 +32,21 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int buck_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_buck1, double **host_buck2, - double **host_a, double **host_c, - double **offset, double *special_lj, const int inum, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen); -void buck_gpu_reinit(const int ntypes, double **cutsq, double **host_rhoinv, - double **host_buck1, double **host_buck2, - double **host_a, double **host_c, double **offset); +int buck_gpu_init(const int ntypes, double **cutsq, double **host_rhoinv, double **host_buck1, + double **host_buck2, double **host_a, double **host_c, double **offset, + double *special_lj, const int inum, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); +void buck_gpu_reinit(const int ntypes, double **cutsq, double **host_rhoinv, double **host_buck1, + double **host_buck2, double **host_a, double **host_c, double **offset); void buck_gpu_clear(); -int ** buck_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success); -void buck_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **buck_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void buck_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double buck_gpu_bytes(); @@ -81,7 +73,7 @@ PairBuckGPU::~PairBuckGPU() void PairBuckGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -89,7 +81,7 @@ void PairBuckGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -98,28 +90,24 @@ void PairBuckGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = buck_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + buck_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - buck_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + buck_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -150,21 +137,15 @@ void PairBuckGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = buck_gpu_init(atom->ntypes+1, cutsq, rhoinv, buck1, buck2, - a, c, offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = buck_gpu_init(atom->ntypes + 1, cutsq, rhoinv, buck1, buck2, a, c, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -173,8 +154,7 @@ void PairBuckGPU::reinit() { Pair::reinit(); - buck_gpu_reinit(atom->ntypes+1, cutsq, rhoinv, buck1, buck2, - a, c, offset); + buck_gpu_reinit(atom->ntypes + 1, cutsq, rhoinv, buck1, buck2, a, c, offset); } /* ---------------------------------------------------------------------- */ @@ -187,12 +167,13 @@ double PairBuckGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairBuckGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r6inv,forcebuck,factor_lj; - double r,rexp; +void PairBuckGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r6inv, forcebuck, factor_lj; + double r, rexp; int *jlist; double **x = atom->x; @@ -219,28 +200,27 @@ void PairBuckGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; r = sqrt(rsq); - rexp = exp(-r*rhoinv[itype][jtype]); - forcebuck = buck1[itype][jtype]*r*rexp - buck2[itype][jtype]*r6inv; - fpair = factor_lj*forcebuck*r2inv; + rexp = exp(-r * rhoinv[itype][jtype]); + forcebuck = buck1[itype][jtype] * r * rexp - buck2[itype][jtype] * r6inv; + fpair = factor_lj * forcebuck * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv - - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv - offset[itype][jtype]; evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_colloid_gpu.cpp b/src/GPU/pair_colloid_gpu.cpp index e3e266f487..a21094dd80 100644 --- a/src/GPU/pair_colloid_gpu.cpp +++ b/src/GPU/pair_colloid_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,7 +24,6 @@ #include "gpu_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -35,26 +33,21 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int colloid_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, double **host_a12, - double **host_a1, double **host_a2, double **host_d1, - double **host_d2, double **host_sigma3, - double **host_sigma6, int **host_form, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, +int colloid_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + double **host_a12, double **host_a1, double **host_a2, double **host_d1, + double **host_d2, double **host_sigma3, double **host_sigma6, int **host_form, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void colloid_gpu_clear(); -int ** colloid_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, - const bool vflag, const bool eatom, - const bool vatom, int &host_start, int **ilist, - int **jnum, const double cpu_time, bool &success); -void colloid_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **colloid_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success); +void colloid_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double colloid_gpu_bytes(); @@ -82,7 +75,7 @@ PairColloidGPU::~PairColloidGPU() void PairColloidGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -90,7 +83,7 @@ void PairColloidGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -99,28 +92,24 @@ void PairColloidGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = colloid_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + colloid_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, eflag_atom, + vflag_atom, host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - colloid_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + colloid_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -152,32 +140,29 @@ void PairColloidGPU::init_style() double cell_size = sqrt(maxcut) + neighbor->skin; int **_form = nullptr; - int n=atom->ntypes; - memory->create(_form,n+1,n+1,"colloid/gpu:_form"); + int n = atom->ntypes; + memory->create(_form, n + 1, n + 1, "colloid/gpu:_form"); for (int i = 1; i <= n; i++) { for (int j = 1; j <= n; j++) { - if (form[i][j] == SMALL_SMALL) _form[i][j] = 0; - else if (form[i][j] == SMALL_LARGE) _form[i][j] = 1; - else if (form[i][j] == LARGE_LARGE) _form[i][j] = 2; + if (form[i][j] == SMALL_SMALL) + _form[i][j] = 0; + else if (form[i][j] == SMALL_LARGE) + _form[i][j] = 1; + else if (form[i][j] == LARGE_LARGE) + _form[i][j] = 2; } } - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = colloid_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, a12, a1, a2, - d1, d2, sigma3, sigma6, _form, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); + int success = + colloid_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, a12, + a1, a2, d1, d2, sigma3, sigma6, _form, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen); memory->destroy(_form); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -190,15 +175,14 @@ double PairColloidGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairColloidGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairColloidGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double r,rsq,r2inv,r6inv,forcelj,factor_lj; - double c1,c2,fR,dUR,dUA; - double K[9],h[4],g[4]; + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double r, rsq, r2inv, r6inv, forcelj, factor_lj; + double c1, c2, fR, dUR, dUA; + double K[9], h[4], g[4]; int *jlist; double **x = atom->x; @@ -225,90 +209,91 @@ void PairColloidGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq >= cutsq[itype][jtype]) continue; switch (form[itype][jtype]) { - case SMALL_SMALL: - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - fpair = factor_lj*forcelj*r2inv; - if (eflag) - evdwl = r6inv*(r6inv*lj3[itype][jtype]-lj4[itype][jtype]) - - offset[itype][jtype]; - break; + case SMALL_SMALL: + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + fpair = factor_lj * forcelj * r2inv; + if (eflag) + evdwl = r6inv * (r6inv * lj3[itype][jtype] - lj4[itype][jtype]) - offset[itype][jtype]; + break; - case SMALL_LARGE: - c2 = a2[itype][jtype]; - K[1] = c2*c2; - K[2] = rsq; - K[0] = K[1] - rsq; - K[4] = rsq*rsq; - K[3] = K[1] - K[2]; - K[3] *= K[3]*K[3]; - K[6] = K[3]*K[3]; - fR = sigma3[itype][jtype]*a12[itype][jtype]*c2*K[1]/K[3]; - fpair = 4.0/15.0*fR*factor_lj * - (2.0*(K[1]+K[2]) * (K[1]*(5.0*K[1]+22.0*K[2])+5.0*K[4]) * - sigma6[itype][jtype]/K[6]-5.0) / K[0]; - if (eflag) - evdwl = 2.0/9.0*fR * - (1.0-(K[1]*(K[1]*(K[1]/3.0+3.0*K[2])+4.2*K[4])+K[2]*K[4]) * - sigma6[itype][jtype]/K[6]) - offset[itype][jtype]; - if (rsq <= K[1]) - error->one(FLERR,"Overlapping small/large in pair colloid"); - break; + case SMALL_LARGE: + c2 = a2[itype][jtype]; + K[1] = c2 * c2; + K[2] = rsq; + K[0] = K[1] - rsq; + K[4] = rsq * rsq; + K[3] = K[1] - K[2]; + K[3] *= K[3] * K[3]; + K[6] = K[3] * K[3]; + fR = sigma3[itype][jtype] * a12[itype][jtype] * c2 * K[1] / K[3]; + fpair = 4.0 / 15.0 * fR * factor_lj * + (2.0 * (K[1] + K[2]) * (K[1] * (5.0 * K[1] + 22.0 * K[2]) + 5.0 * K[4]) * + sigma6[itype][jtype] / K[6] - + 5.0) / + K[0]; + if (eflag) + evdwl = 2.0 / 9.0 * fR * + (1.0 - + (K[1] * (K[1] * (K[1] / 3.0 + 3.0 * K[2]) + 4.2 * K[4]) + K[2] * K[4]) * + sigma6[itype][jtype] / K[6]) - + offset[itype][jtype]; + if (rsq <= K[1]) error->one(FLERR, "Overlapping small/large in pair colloid"); + break; - case LARGE_LARGE: - r = sqrt(rsq); - c1 = a1[itype][jtype]; - c2 = a2[itype][jtype]; - K[0] = c1*c2; - K[1] = c1+c2; - K[2] = c1-c2; - K[3] = K[1]+r; - K[4] = K[1]-r; - K[5] = K[2]+r; - K[6] = K[2]-r; - K[7] = 1.0/(K[3]*K[4]); - K[8] = 1.0/(K[5]*K[6]); - g[0] = pow(K[3],-7.0); - g[1] = pow(K[4],-7.0); - g[2] = pow(K[5],-7.0); - g[3] = pow(K[6],-7.0); - h[0] = ((K[3]+5.0*K[1])*K[3]+30.0*K[0])*g[0]; - h[1] = ((K[4]+5.0*K[1])*K[4]+30.0*K[0])*g[1]; - h[2] = ((K[5]+5.0*K[2])*K[5]-30.0*K[0])*g[2]; - h[3] = ((K[6]+5.0*K[2])*K[6]-30.0*K[0])*g[3]; - g[0] *= 42.0*K[0]/K[3]+6.0*K[1]+K[3]; - g[1] *= 42.0*K[0]/K[4]+6.0*K[1]+K[4]; - g[2] *= -42.0*K[0]/K[5]+6.0*K[2]+K[5]; - g[3] *= -42.0*K[0]/K[6]+6.0*K[2]+K[6]; + case LARGE_LARGE: + r = sqrt(rsq); + c1 = a1[itype][jtype]; + c2 = a2[itype][jtype]; + K[0] = c1 * c2; + K[1] = c1 + c2; + K[2] = c1 - c2; + K[3] = K[1] + r; + K[4] = K[1] - r; + K[5] = K[2] + r; + K[6] = K[2] - r; + K[7] = 1.0 / (K[3] * K[4]); + K[8] = 1.0 / (K[5] * K[6]); + g[0] = pow(K[3], -7.0); + g[1] = pow(K[4], -7.0); + g[2] = pow(K[5], -7.0); + g[3] = pow(K[6], -7.0); + h[0] = ((K[3] + 5.0 * K[1]) * K[3] + 30.0 * K[0]) * g[0]; + h[1] = ((K[4] + 5.0 * K[1]) * K[4] + 30.0 * K[0]) * g[1]; + h[2] = ((K[5] + 5.0 * K[2]) * K[5] - 30.0 * K[0]) * g[2]; + h[3] = ((K[6] + 5.0 * K[2]) * K[6] - 30.0 * K[0]) * g[3]; + g[0] *= 42.0 * K[0] / K[3] + 6.0 * K[1] + K[3]; + g[1] *= 42.0 * K[0] / K[4] + 6.0 * K[1] + K[4]; + g[2] *= -42.0 * K[0] / K[5] + 6.0 * K[2] + K[5]; + g[3] *= -42.0 * K[0] / K[6] + 6.0 * K[2] + K[6]; - fR = a12[itype][jtype]*sigma6[itype][jtype]/r/37800.0; - evdwl = fR * (h[0]-h[1]-h[2]+h[3]); - dUR = evdwl/r + 5.0*fR*(g[0]+g[1]-g[2]-g[3]); - dUA = -a12[itype][jtype]/3.0*r*((2.0*K[0]*K[7]+1.0)*K[7] + - (2.0*K[0]*K[8]-1.0)*K[8]); - fpair = factor_lj * (dUR+dUA)/r; - if (eflag) - evdwl += a12[itype][jtype]/6.0 * - (2.0*K[0]*(K[7]+K[8])-log(K[8]/K[7])) - offset[itype][jtype]; - if (r <= K[1]) - error->one(FLERR,"Overlapping large/large in pair colloid"); - break; + fR = a12[itype][jtype] * sigma6[itype][jtype] / r / 37800.0; + evdwl = fR * (h[0] - h[1] - h[2] + h[3]); + dUR = evdwl / r + 5.0 * fR * (g[0] + g[1] - g[2] - g[3]); + dUA = -a12[itype][jtype] / 3.0 * r * + ((2.0 * K[0] * K[7] + 1.0) * K[7] + (2.0 * K[0] * K[8] - 1.0) * K[8]); + fpair = factor_lj * (dUR + dUA) / r; + if (eflag) + evdwl += a12[itype][jtype] / 6.0 * (2.0 * K[0] * (K[7] + K[8]) - log(K[8] / K[7])) - + offset[itype][jtype]; + if (r <= K[1]) error->one(FLERR, "Overlapping large/large in pair colloid"); + break; } if (eflag) evdwl *= factor_lj; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_coul_cut_gpu.cpp b/src/GPU/pair_coul_cut_gpu.cpp index a0a6add94f..188b0c85a9 100644 --- a/src/GPU/pair_coul_cut_gpu.cpp +++ b/src/GPU/pair_coul_cut_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,27 +32,21 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int coul_gpu_init(const int ntypes, double **host_scale, double **cutsq, - double *special_coul, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - const double qqrd2e); +int coul_gpu_init(const int ntypes, double **host_scale, double **cutsq, double *special_coul, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, const double qqrd2e); void coul_gpu_reinit(const int ntypes, double **host_scale); void coul_gpu_clear(); -int ** coul_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void coul_gpu_compute(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, const bool eatom, - const bool vatom, int &host_start, const double cpu_time, - bool &success, double *host_q, const int nlocal, +int **coul_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void coul_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, double *boxlo, double *prd); double coul_gpu_bytes(); @@ -81,7 +73,7 @@ PairCoulCutGPU::~PairCoulCutGPU() void PairCoulCutGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -89,7 +81,7 @@ void PairCoulCutGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -98,30 +90,25 @@ void PairCoulCutGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = coul_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = coul_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - coul_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, - atom->nlocal, domain->boxlo, domain->prd); + coul_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, + atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style coul/cut/gpu requires atom attribute q"); - + if (!atom->q_flag) error->all(FLERR, "Pair style coul/cut/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -144,10 +129,9 @@ void PairCoulCutGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -155,21 +139,15 @@ void PairCoulCutGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = coul_gpu_init(atom->ntypes+1, scale, cutsq, - force->special_coul, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, force->qqrd2e); - GPU_EXTRA::check_flag(success,error,world); + int success = coul_gpu_init(atom->ntypes + 1, scale, cutsq, force->special_coul, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, force->qqrd2e); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -178,7 +156,7 @@ void PairCoulCutGPU::reinit() { Pair::reinit(); - coul_gpu_reinit(atom->ntypes+1, scale); + coul_gpu_reinit(atom->ntypes + 1, scale); } /* ---------------------------------------------------------------------- */ @@ -191,13 +169,12 @@ double PairCoulCutGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairCoulCutGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairCoulCutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,ecoul,fpair; - double rsq,r2inv,forcecoul,factor_coul; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, ecoul, fpair; + double rsq, r2inv, forcecoul, factor_coul; int *jlist; ecoul = 0.0; @@ -229,23 +206,21 @@ void PairCoulCutGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - forcecoul = qqrd2e * qtmp*q[j]*sqrt(r2inv); - fpair = factor_coul*forcecoul * r2inv; + r2inv = 1.0 / rsq; + forcecoul = qqrd2e * qtmp * q[j] * sqrt(r2inv); + fpair = factor_coul * forcecoul * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; - if (eflag) { - ecoul = factor_coul * qqrd2e * qtmp*q[j]*sqrt(r2inv); - } + if (eflag) { ecoul = factor_coul * qqrd2e * qtmp * q[j] * sqrt(r2inv); } - if (evflag) ev_tally_full(i,0.0,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, 0.0, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_coul_debye_gpu.cpp b/src/GPU/pair_coul_debye_gpu.cpp index 2684a2fd22..4b070f2b6e 100644 --- a/src/GPU/pair_coul_debye_gpu.cpp +++ b/src/GPU/pair_coul_debye_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,34 +32,28 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int cdebye_gpu_init(const int ntypes, double **host_scale, double **cutsq, - double *special_coul, const int nlocal, const int nall, - const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - const double qqrd2e, const double kappa); +int cdebye_gpu_init(const int ntypes, double **host_scale, double **cutsq, double *special_coul, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, const double qqrd2e, + const double kappa); void cdebye_gpu_reinit(const int ntypes, double **host_scale); void cdebye_gpu_clear(); -int ** cdebye_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, - const bool vflag, const bool eatom, - const bool vatom, int &host_start, int **ilist, - int **jnum, const double cpu_time, bool &success, - double *host_q, double *boxlo, double *prd); -void cdebye_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, - int *numj, int **firstneigh, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, const double cpu_time, bool &success, - double *host_q, const int nlocal, double *boxlo, - double *prd); +int **cdebye_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, double *host_q, + double *boxlo, double *prd); +void cdebye_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double cdebye_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairCoulDebyeGPU::PairCoulDebyeGPU(LAMMPS *lmp) : - PairCoulDebye(lmp), gpu_mode(GPU_FORCE) +PairCoulDebyeGPU::PairCoulDebyeGPU(LAMMPS *lmp) : PairCoulDebye(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; cpu_time = 0.0; @@ -82,7 +74,7 @@ PairCoulDebyeGPU::~PairCoulDebyeGPU() void PairCoulDebyeGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -90,7 +82,7 @@ void PairCoulDebyeGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -99,30 +91,25 @@ void PairCoulDebyeGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = cdebye_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = cdebye_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - cdebye_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, - atom->nlocal, domain->boxlo, domain->prd); + cdebye_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, + atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style coul/debye/gpu requires atom attribute q"); - + if (!atom->q_flag) error->all(FLERR, "Pair style coul/debye/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -145,10 +130,9 @@ void PairCoulDebyeGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -156,22 +140,15 @@ void PairCoulDebyeGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = cdebye_gpu_init(atom->ntypes+1, scale, cutsq, - force->special_coul, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, - force->qqrd2e, kappa); - GPU_EXTRA::check_flag(success,error,world); + int success = cdebye_gpu_init(atom->ntypes + 1, scale, cutsq, force->special_coul, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, force->qqrd2e, kappa); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -180,7 +157,7 @@ void PairCoulDebyeGPU::reinit() { Pair::reinit(); - cdebye_gpu_reinit(atom->ntypes+1, scale); + cdebye_gpu_reinit(atom->ntypes + 1, scale); } /* ---------------------------------------------------------------------- */ @@ -193,14 +170,13 @@ double PairCoulDebyeGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairCoulDebyeGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairCoulDebyeGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,ecoul,fpair; - double rsq,r2inv,forcecoul,factor_coul; - double r,rinv,screening; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, ecoul, fpair; + double rsq, r2inv, forcecoul, factor_coul; + double r, rinv, screening; int *jlist; ecoul = 0.0; @@ -232,28 +208,26 @@ void PairCoulDebyeGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; r = sqrt(rsq); - rinv = 1.0/r; - screening = exp(-kappa*r); - forcecoul = qqrd2e * scale[itype][jtype] * - qtmp*q[j] * screening * (kappa + rinv); - fpair = factor_coul*forcecoul * r2inv; + rinv = 1.0 / r; + screening = exp(-kappa * r); + forcecoul = qqrd2e * scale[itype][jtype] * qtmp * q[j] * screening * (kappa + rinv); + fpair = factor_coul * forcecoul * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - ecoul = factor_coul * qqrd2e * scale[itype][jtype] * - qtmp*q[j] * rinv * screening; + ecoul = factor_coul * qqrd2e * scale[itype][jtype] * qtmp * q[j] * rinv * screening; } - if (evflag) ev_tally_full(i,0.0,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, 0.0, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_coul_dsf_gpu.cpp b/src/GPU/pair_coul_dsf_gpu.cpp index b9e64674aa..d6453c6160 100644 --- a/src/GPU/pair_coul_dsf_gpu.cpp +++ b/src/GPU/pair_coul_dsf_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,54 +23,45 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include #define MY_PIS 1.77245385090551602729 -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int cdsf_gpu_init(const int ntypes, const int nlocal, const int nall, - const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - const double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, - const double e_shift, const double f_shift, - const double alpha); +int cdsf_gpu_init(const int ntypes, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + const double host_cut_coulsq, double *host_special_coul, const double qqrd2e, + const double e_shift, const double f_shift, const double alpha); void cdsf_gpu_clear(); -int ** cdsf_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void cdsf_gpu_compute(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, const bool eatom, - const bool vatom, int &host_start, const double cpu_time, - bool &success, double *host_q, const int nlocal, +int **cdsf_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void cdsf_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, double *boxlo, double *prd); double cdsf_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairCoulDSFGPU::PairCoulDSFGPU(LAMMPS *lmp) : PairCoulDSF(lmp), - gpu_mode(GPU_FORCE) +PairCoulDSFGPU::PairCoulDSFGPU(LAMMPS *lmp) : PairCoulDSF(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -93,7 +83,7 @@ PairCoulDSFGPU::~PairCoulDSFGPU() void PairCoulDSFGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -101,7 +91,7 @@ void PairCoulDSFGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -110,30 +100,25 @@ void PairCoulDSFGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = cdsf_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = cdsf_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - cdsf_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + cdsf_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style coul/dsf/gpu requires atom attribute q"); - + if (!atom->q_flag) error->all(FLERR, "Pair style coul/dsf/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -156,10 +139,9 @@ void PairCoulDSFGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -168,27 +150,20 @@ void PairCoulDSFGPU::init_style() double cell_size = sqrt(maxcut) + neighbor->skin; cut_coulsq = cut_coul * cut_coul; - double erfcc = erfc(alpha*cut_coul); - double erfcd = exp(-alpha*alpha*cut_coul*cut_coul); - f_shift = -(erfcc/cut_coulsq + 2.0/MY_PIS*alpha*erfcd/cut_coul); - e_shift = erfcc/cut_coul - f_shift*cut_coul; + double erfcc = erfc(alpha * cut_coul); + double erfcd = exp(-alpha * alpha * cut_coul * cut_coul); + f_shift = -(erfcc / cut_coulsq + 2.0 / MY_PIS * alpha * erfcd / cut_coul); + e_shift = erfcc / cut_coul - f_shift * cut_coul; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = cdsf_gpu_init(atom->ntypes+1, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_coulsq, - force->special_coul, force->qqrd2e, e_shift, - f_shift, alpha); - GPU_EXTRA::check_flag(success,error,world); + int success = cdsf_gpu_init(atom->ntypes + 1, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen, cut_coulsq, + force->special_coul, force->qqrd2e, e_shift, f_shift, alpha); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -201,14 +176,13 @@ double PairCoulDSFGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairCoulDSFGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairCoulDSFGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,ecoul,fpair; - double r,rsq,r2inv,forcecoul,factor_coul; - double prefactor,erfcc,erfcd,t; + int i, j, ii, jj, jnum; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, ecoul, fpair; + double r, rsq, r2inv, forcecoul, factor_coul; + double prefactor, erfcc, erfcd, t; int *jlist; ecoul = 0.0; @@ -232,8 +206,8 @@ void PairCoulDSFGPU::cpu_compute(int start, int inum, int eflag, jnum = numneigh[i]; if (evflag) { - double e_self = -(e_shift/2.0 + alpha/MY_PIS) * qtmp*qtmp*qqrd2e; - ev_tally(i,i,nlocal,0,0.0,e_self,0.0,0.0,0.0,0.0); + double e_self = -(e_shift / 2.0 + alpha / MY_PIS) * qtmp * qtmp * qqrd2e; + ev_tally(i, i, nlocal, 0, 0.0, e_self, 0.0, 0.0, 0.0, 0.0); } for (jj = 0; jj < jnum; jj++) { @@ -244,32 +218,32 @@ void PairCoulDSFGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cut_coulsq) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; r = sqrt(rsq); - prefactor = qqrd2e*qtmp*q[j]/r; - erfcd = exp(-alpha*alpha*r*r); - t = 1.0 / (1.0 + EWALD_P*alpha*r); - erfcc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * erfcd; - forcecoul = prefactor * (erfcc/r + 2.0*alpha/MY_PIS * erfcd + - r*f_shift) * r; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + prefactor = qqrd2e * qtmp * q[j] / r; + erfcd = exp(-alpha * alpha * r * r); + t = 1.0 / (1.0 + EWALD_P * alpha * r); + erfcc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * erfcd; + forcecoul = prefactor * (erfcc / r + 2.0 * alpha / MY_PIS * erfcd + r * f_shift) * r; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; fpair = forcecoul * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { - ecoul = prefactor * (erfcc - r*e_shift - rsq*f_shift); - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + ecoul = prefactor * (erfcc - r * e_shift - rsq * f_shift); + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; } - if (evflag) ev_tally_full(i,0.0,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, 0.0, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_coul_long_cs_gpu.cpp b/src/GPU/pair_coul_long_cs_gpu.cpp index 1a57cada93..f4a12d051a 100644 --- a/src/GPU/pair_coul_long_cs_gpu.cpp +++ b/src/GPU/pair_coul_long_cs_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,7 +24,6 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -33,14 +31,14 @@ using namespace LAMMPS_NS; -#define EWALD_F 1.12837917 -#define EWALD_P 9.95473818e-1 -#define B0 -0.1335096380159268 -#define B1 -2.57839507e-1 -#define B2 -1.37203639e-1 -#define B3 -8.88822059e-3 -#define B4 -5.80844129e-3 -#define B5 1.14652755e-1 +#define EWALD_F 1.12837917 +#define EWALD_P 9.95473818e-1 +#define B0 -0.1335096380159268 +#define B1 -2.57839507e-1 +#define B2 -1.37203639e-1 +#define B3 -8.88822059e-3 +#define B4 -5.80844129e-3 +#define B5 1.14652755e-1 #define EPSILON 1.0e-20 #define EPS_EWALD 1.0e-6 @@ -48,33 +46,28 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int clcs_gpu_init(const int ntypes, double **scale, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double host_cut_coulsq, double *host_special_coul, +int clcs_gpu_init(const int ntypes, double **scale, const int nlocal, const int nall, + const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, + FILE *screen, double host_cut_coulsq, double *host_special_coul, const double qqrd2e, const double g_ewald); void clcs_gpu_reinit(const int ntypes, double **scale); void clcs_gpu_clear(); -int ** clcs_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, double *host_q, - double *boxlo, double *prd); -void clcs_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **clcs_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void clcs_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double clcs_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairCoulLongCSGPU::PairCoulLongCSGPU(LAMMPS *lmp) : - PairCoulLongCS(lmp), gpu_mode(GPU_FORCE) +PairCoulLongCSGPU::PairCoulLongCSGPU(LAMMPS *lmp) : PairCoulLongCS(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; cpu_time = 0.0; @@ -95,7 +88,7 @@ PairCoulLongCSGPU::~PairCoulLongCSGPU() void PairCoulLongCSGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -103,7 +96,7 @@ void PairCoulLongCSGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -112,30 +105,25 @@ void PairCoulLongCSGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = clcs_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = clcs_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - clcs_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, - atom->nlocal, domain->boxlo, domain->prd); + clcs_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, + atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style coul/long/cs/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style coul/long/cs/gpu requires atom attribute q"); // Call init_one calculation make sure scale is correct for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { - if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - init_one(i,j); - } + if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { init_one(i, j); } } } double cell_size = cut_coul + neighbor->skin; @@ -167,30 +152,23 @@ void PairCoulLongCSGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = clcs_gpu_init(atom->ntypes+1, scale, - atom->nlocal, atom->nlocal+atom->nghost, mnf, - maxspecial, cell_size, gpu_mode, screen, cut_coulsq, - force->special_coul, force->qqrd2e, g_ewald); + int success = clcs_gpu_init(atom->ntypes + 1, scale, atom->nlocal, atom->nlocal + atom->nghost, + mnf, maxspecial, cell_size, gpu_mode, screen, cut_coulsq, + force->special_coul, force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -199,7 +177,7 @@ void PairCoulLongCSGPU::reinit() { Pair::reinit(); - clcs_gpu_reinit(atom->ntypes+1, scale); + clcs_gpu_reinit(atom->ntypes + 1, scale); } /* ---------------------------------------------------------------------- */ @@ -212,15 +190,14 @@ double PairCoulLongCSGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairCoulLongCSGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) +void PairCoulLongCSGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itable,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,ecoul,fpair; - double fraction,table; - double r,r2inv,forcecoul,factor_coul; - double grij,expm2,prefactor,t,erfc,u; + int i, j, ii, jj, jnum, itable, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, ecoul, fpair; + double fraction, table; + double r, r2inv, forcecoul, factor_coul; + double grij, expm2, prefactor, t, erfc, u; int *jlist; double rsq; @@ -253,37 +230,38 @@ void PairCoulLongCSGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cut_coulsq) { - rsq += EPSILON; // Add Epsilon for case: r = 0; Interaction must be removed by special bond; - r2inv = 1.0/rsq; + rsq += + EPSILON; // Add Epsilon for case: r = 0; Interaction must be removed by special bond; + r2inv = 1.0 / rsq; if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); - prefactor = qqrd2e * scale[itype][jtype] * qtmp*q[j]; + prefactor = qqrd2e * scale[itype][jtype] * qtmp * q[j]; if (factor_coul < 1.0) { // When bonded parts are being calculated a minimal distance (EPS_EWALD) // has to be added to the prefactor and erfc in order to make the // used approximation functions for the Ewald correction valid - grij = g_ewald * (r+EPS_EWALD); - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); + grij = g_ewald * (r + EPS_EWALD); + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); u = 1.0 - t; - erfc = t * (1.+u*(B0+u*(B1+u*(B2+u*(B3+u*(B4+u*B5)))))) * expm2; - prefactor /= (r+EPS_EWALD); - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2 - (1.0-factor_coul)); + erfc = t * (1. + u * (B0 + u * (B1 + u * (B2 + u * (B3 + u * (B4 + u * B5)))))) * expm2; + prefactor /= (r + EPS_EWALD); + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2 - (1.0 - factor_coul)); // Additionally r2inv needs to be accordingly modified since the later // scaling of the overall force shall be consistent - r2inv = 1.0/(rsq + EPS_EWALD_SQR); + r2inv = 1.0 / (rsq + EPS_EWALD_SQR); } else { grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); u = 1.0 - t; - erfc = t * (1.+u*(B0+u*(B1+u*(B2+u*(B3+u*(B4+u*B5)))))) * expm2; + erfc = t * (1. + u * (B0 + u * (B1 + u * (B2 + u * (B3 + u * (B4 + u * B5)))))) * expm2; prefactor /= r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); } } else { union_int_float_t rsq_lookup; @@ -291,34 +269,35 @@ void PairCoulLongCSGPU::cpu_compute(int start, int inum, int eflag, itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = scale[itype][jtype] * qtmp*q[j] * table; + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = scale[itype][jtype] * qtmp * q[j] * table; if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = scale[itype][jtype] * qtmp*q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = scale[itype][jtype] * qtmp * q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; } } fpair = forcecoul * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) - ecoul = prefactor*erfc; + ecoul = prefactor * erfc; else { - table = etable[itable] + fraction*detable[itable]; - ecoul = scale[itype][jtype] * qtmp*q[j] * table; + table = etable[itable] + fraction * detable[itable]; + ecoul = scale[itype][jtype] * qtmp * q[j] * table; } - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; } - if (evflag) ev_tally_full(i,0.0,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, 0.0, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_coul_long_gpu.cpp b/src/GPU/pair_coul_long_gpu.cpp index 28351ca0c1..fefc2c768d 100644 --- a/src/GPU/pair_coul_long_gpu.cpp +++ b/src/GPU/pair_coul_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,51 +24,44 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int cl_gpu_init(const int ntypes, double **scale, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, int &gpu_mode, +int cl_gpu_init(const int ntypes, double **scale, const int nlocal, const int nall, + const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, double host_cut_coulsq, double *host_special_coul, const double qqrd2e, const double g_ewald); void cl_gpu_reinit(const int ntypes, double **scale); void cl_gpu_clear(); -int ** cl_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, double *host_q, - double *boxlo, double *prd); -void cl_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **cl_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void cl_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success, double *host_q, const int nlocal, double *boxlo, double *prd); double cl_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairCoulLongGPU::PairCoulLongGPU(LAMMPS *lmp) : - PairCoulLong(lmp), gpu_mode(GPU_FORCE) +PairCoulLongGPU::PairCoulLongGPU(LAMMPS *lmp) : PairCoulLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; cpu_time = 0.0; @@ -90,7 +82,7 @@ PairCoulLongGPU::~PairCoulLongGPU() void PairCoulLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -98,7 +90,7 @@ void PairCoulLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -107,30 +99,25 @@ void PairCoulLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = cl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = cl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - cl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + cl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style coul/long/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style coul/long/gpu requires atom attribute q"); // Call init_one calculation make sure scale is correct for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { - if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - init_one(i,j); - } + if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { init_one(i, j); } } } double cell_size = cut_coul + neighbor->skin; @@ -162,30 +146,23 @@ void PairCoulLongGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = cl_gpu_init(atom->ntypes+1, scale, - atom->nlocal, atom->nlocal+atom->nghost, mnf, + int success = cl_gpu_init(atom->ntypes + 1, scale, atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen, cut_coulsq, force->special_coul, force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -194,7 +171,7 @@ void PairCoulLongGPU::reinit() { Pair::reinit(); - cl_gpu_reinit(atom->ntypes+1, scale); + cl_gpu_reinit(atom->ntypes + 1, scale); } /* ---------------------------------------------------------------------- */ @@ -207,15 +184,14 @@ double PairCoulLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairCoulLongGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairCoulLongGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itable; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,ecoul,fpair; - double fraction,table; - double r,r2inv,forcecoul,factor_coul; - double grij,expm2,prefactor,t,erfc; + int i, j, ii, jj, jnum, itable; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, ecoul, fpair; + double fraction, table; + double r, r2inv, forcecoul, factor_coul; + double grij, expm2, prefactor, t, erfc; int *jlist; double rsq; @@ -246,54 +222,55 @@ void PairCoulLongGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; } else { union_int_float_t rsq_lookup; rsq_lookup.f = rsq; itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = qtmp*q[j] * table; + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = qtmp * q[j] * table; if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = qtmp*q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = qtmp * q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; } } fpair = forcecoul * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) - ecoul = prefactor*erfc; + ecoul = prefactor * erfc; else { - table = etable[itable] + fraction*detable[itable]; - ecoul = qtmp*q[j] * table; + table = etable[itable] + fraction * detable[itable]; + ecoul = qtmp * q[j] * table; } - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; } - if (evflag) ev_tally_full(i,0.0,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, 0.0, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_dpd_gpu.cpp b/src/GPU/pair_dpd_gpu.cpp index bd1227123b..ffc05cc0d0 100644 --- a/src/GPU/pair_dpd_gpu.cpp +++ b/src/GPU/pair_dpd_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include "update.h" @@ -35,29 +33,24 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int dpd_gpu_init(const int ntypes, double **cutsq, double **host_a0, - double **host_gamma, double **host_sigma, double **host_cut, - double *special_lj, const int inum, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen); +int dpd_gpu_init(const int ntypes, double **cutsq, double **host_a0, double **host_gamma, + double **host_sigma, double **host_cut, double *special_lj, const int inum, + const int nall, const int max_nbors, const int maxspecial, const double cell_size, + int &gpu_mode, FILE *screen); void dpd_gpu_clear(); -int ** dpd_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double **host_v, const double dtinvsqrt, - const int seed, const int timestep, - double *boxlo, double *prd); -void dpd_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, tagint *tag, - double **host_v, const double dtinvsqrt, - const int seed, const int timestep, - const int nlocal, double *boxlo, double *prd); +int **dpd_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double **host_v, + const double dtinvsqrt, const int seed, const int timestep, double *boxlo, + double *prd); +void dpd_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, tagint *tag, double **host_v, + const double dtinvsqrt, const int seed, const int timestep, const int nlocal, + double *boxlo, double *prd); double dpd_gpu_bytes(); #define EPSILON 1.0e-10 @@ -66,7 +59,8 @@ double dpd_gpu_bytes(); //#define _USE_UNIFORM_SARU_TEA8 //#define _USE_GAUSSIAN_SARU_LCG -#if !defined(_USE_UNIFORM_SARU_LCG) && !defined(_USE_UNIFORM_SARU_TEA8) && !defined(_USE_GAUSSIAN_SARU_LCG) +#if !defined(_USE_UNIFORM_SARU_LCG) && !defined(_USE_UNIFORM_SARU_TEA8) && \ + !defined(_USE_GAUSSIAN_SARU_LCG) #define _USE_UNIFORM_SARU_LCG #endif @@ -75,9 +69,9 @@ double dpd_gpu_bytes(); // 2. C. L. Phillips, J. A. Anderson, S. C. Glotzer, Comput. Phys. Comm. 230 (2011), 7191-7201. // PRNG period = 3666320093*2^32 ~ 2^64 ~ 10^19 -#define LCGA 0x4beb5d59 // Full period 32 bit LCG +#define LCGA 0x4beb5d59 // Full period 32 bit LCG #define LCGC 0x2600e1f7 -#define oWeylPeriod 0xda879add // Prime period 3666320093 +#define oWeylPeriod 0xda879add // Prime period 3666320093 #define oWeylOffset 0x8009d14b #define TWO_N32 0.232830643653869628906250e-9f /* 2^-32 */ @@ -89,28 +83,29 @@ double dpd_gpu_bytes(); // Curly brackets to make variables local to the scope. #ifdef _USE_UNIFORM_SARU_LCG #define numtyp double -#define SQRT3 (numtyp)1.7320508075688772935274463 -#define saru(seed1, seed2, seed, timestep, randnum) { \ - unsigned int seed3 = seed + timestep; \ - seed3^=(seed1<<7)^(seed2>>6); \ - seed2+=(seed1>>4)^(seed3>>15); \ - seed1^=(seed2<<9)+(seed3<<8); \ - seed3^=0xA5366B4D*((seed2>>11) ^ (seed1<<1)); \ - seed2+=0x72BE1579*((seed1<<4) ^ (seed3>>16)); \ - seed1^=0x3F38A6ED*((seed3>>5) ^ (((signed int)seed2)>>22)); \ - seed2+=seed1*seed3; \ - seed1+=seed3 ^ (seed2>>2); \ - seed2^=((signed int)seed2)>>17; \ - unsigned int state = 0x79dedea3*(seed1^(((signed int)seed1)>>14)); \ - unsigned int wstate = (state + seed2) ^ (((signed int)state)>>8); \ - state = state + (wstate*(wstate^0xdddf97f5)); \ - wstate = 0xABCB96F7 + (wstate>>1); \ - state = LCGA*state + LCGC; \ - wstate = wstate + oWeylOffset+((((signed int)wstate)>>31) & oWeylPeriod); \ - unsigned int v = (state ^ (state>>26)) + wstate; \ - unsigned int s = (signed int)((v^(v>>20))*0x6957f5a7); \ - randnum = SQRT3*(s*TWO_N32*(numtyp)2.0-(numtyp)1.0); \ -} +#define SQRT3 (numtyp) 1.7320508075688772935274463 +#define saru(seed1, seed2, seed, timestep, randnum) \ + { \ + unsigned int seed3 = seed + timestep; \ + seed3 ^= (seed1 << 7) ^ (seed2 >> 6); \ + seed2 += (seed1 >> 4) ^ (seed3 >> 15); \ + seed1 ^= (seed2 << 9) + (seed3 << 8); \ + seed3 ^= 0xA5366B4D * ((seed2 >> 11) ^ (seed1 << 1)); \ + seed2 += 0x72BE1579 * ((seed1 << 4) ^ (seed3 >> 16)); \ + seed1 ^= 0x3F38A6ED * ((seed3 >> 5) ^ (((signed int) seed2) >> 22)); \ + seed2 += seed1 * seed3; \ + seed1 += seed3 ^ (seed2 >> 2); \ + seed2 ^= ((signed int) seed2) >> 17; \ + unsigned int state = 0x79dedea3 * (seed1 ^ (((signed int) seed1) >> 14)); \ + unsigned int wstate = (state + seed2) ^ (((signed int) state) >> 8); \ + state = state + (wstate * (wstate ^ 0xdddf97f5)); \ + wstate = 0xABCB96F7 + (wstate >> 1); \ + state = LCGA * state + LCGC; \ + wstate = wstate + oWeylOffset + ((((signed int) wstate) >> 31) & oWeylPeriod); \ + unsigned int v = (state ^ (state >> 26)) + wstate; \ + unsigned int s = (signed int) ((v ^ (v >> 20)) * 0x6957f5a7); \ + randnum = SQRT3 * (s * TWO_N32 * (numtyp) 2.0 - (numtyp) 1.0); \ + } #endif // specifically implemented for steps = 1; high = 1.0; low = -1.0 @@ -119,38 +114,39 @@ double dpd_gpu_bytes(); // Afshar et al. mutlplies u in [-0.5;0.5] with sqrt(12) #ifdef _USE_UNIFORM_SARU_TEA8 #define numtyp double -#define SQRT3 (numtyp)1.7320508075688772935274463 +#define SQRT3 (numtyp) 1.7320508075688772935274463 #define k0 0xA341316C #define k1 0xC8013EA4 #define k2 0xAD90777D #define k3 0x7E95761E #define delta 0x9e3779b9 #define rounds 8 -#define saru(seed1, seed2, seed, timestep, randnum) { \ - unsigned int seed3 = seed + timestep; \ - seed3^=(seed1<<7)^(seed2>>6); \ - seed2+=(seed1>>4)^(seed3>>15); \ - seed1^=(seed2<<9)+(seed3<<8); \ - seed3^=0xA5366B4D*((seed2>>11) ^ (seed1<<1)); \ - seed2+=0x72BE1579*((seed1<<4) ^ (seed3>>16)); \ - seed1^=0x3F38A6ED*((seed3>>5) ^ (((signed int)seed2)>>22)); \ - seed2+=seed1*seed3; \ - seed1+=seed3 ^ (seed2>>2); \ - seed2^=((signed int)seed2)>>17; \ - unsigned int state = 0x79dedea3*(seed1^(((signed int)seed1)>>14)); \ - unsigned int wstate = (state + seed2) ^ (((signed int)state)>>8); \ - state = state + (wstate*(wstate^0xdddf97f5)); \ - wstate = 0xABCB96F7 + (wstate>>1); \ - unsigned int sum = 0; \ - for (int i=0; i < rounds; i++) { \ - sum += delta; \ - state += ((wstate<<4) + k0)^(wstate + sum)^((wstate>>5) + k1); \ - wstate += ((state<<4) + k2)^(state + sum)^((state>>5) + k3); \ - } \ - unsigned int v = (state ^ (state>>26)) + wstate; \ - unsigned int s = (signed int)((v^(v>>20))*0x6957f5a7); \ - randnum = SQRT3*(s*TWO_N32*(numtyp)2.0-(numtyp)1.0); \ -} +#define saru(seed1, seed2, seed, timestep, randnum) \ + { \ + unsigned int seed3 = seed + timestep; \ + seed3 ^= (seed1 << 7) ^ (seed2 >> 6); \ + seed2 += (seed1 >> 4) ^ (seed3 >> 15); \ + seed1 ^= (seed2 << 9) + (seed3 << 8); \ + seed3 ^= 0xA5366B4D * ((seed2 >> 11) ^ (seed1 << 1)); \ + seed2 += 0x72BE1579 * ((seed1 << 4) ^ (seed3 >> 16)); \ + seed1 ^= 0x3F38A6ED * ((seed3 >> 5) ^ (((signed int) seed2) >> 22)); \ + seed2 += seed1 * seed3; \ + seed1 += seed3 ^ (seed2 >> 2); \ + seed2 ^= ((signed int) seed2) >> 17; \ + unsigned int state = 0x79dedea3 * (seed1 ^ (((signed int) seed1) >> 14)); \ + unsigned int wstate = (state + seed2) ^ (((signed int) state) >> 8); \ + state = state + (wstate * (wstate ^ 0xdddf97f5)); \ + wstate = 0xABCB96F7 + (wstate >> 1); \ + unsigned int sum = 0; \ + for (int i = 0; i < rounds; i++) { \ + sum += delta; \ + state += ((wstate << 4) + k0) ^ (wstate + sum) ^ ((wstate >> 5) + k1); \ + wstate += ((state << 4) + k2) ^ (state + sum) ^ ((state >> 5) + k3); \ + } \ + unsigned int v = (state ^ (state >> 26)) + wstate; \ + unsigned int s = (signed int) ((v ^ (v >> 20)) * 0x6957f5a7); \ + randnum = SQRT3 * (s * TWO_N32 * (numtyp) 2.0 - (numtyp) 1.0); \ + } #endif // specifically implemented for steps = 1; high = 1.0; low = -1.0 @@ -159,42 +155,43 @@ double dpd_gpu_bytes(); // This is used to compared with CPU DPD using RandMars::gaussian() #ifdef _USE_GAUSSIAN_SARU_LCG #define numtyp double -#define saru(seed1, seed2, seed, timestep, randnum) { \ - unsigned int seed3 = seed + timestep; \ - seed3^=(seed1<<7)^(seed2>>6); \ - seed2+=(seed1>>4)^(seed3>>15); \ - seed1^=(seed2<<9)+(seed3<<8); \ - seed3^=0xA5366B4D*((seed2>>11) ^ (seed1<<1)); \ - seed2+=0x72BE1579*((seed1<<4) ^ (seed3>>16)); \ - seed1^=0x3F38A6ED*((seed3>>5) ^ (((signed int)seed2)>>22)); \ - seed2+=seed1*seed3; \ - seed1+=seed3 ^ (seed2>>2); \ - seed2^=((signed int)seed2)>>17; \ - unsigned int state=0x12345678; \ - unsigned int wstate=12345678; \ - state = 0x79dedea3*(seed1^(((signed int)seed1)>>14)); \ - wstate = (state + seed2) ^ (((signed int)state)>>8); \ - state = state + (wstate*(wstate^0xdddf97f5)); \ - wstate = 0xABCB96F7 + (wstate>>1); \ - unsigned int v, s; \ - numtyp r1, r2, rsq; \ - while (1) { \ - state = LCGA*state + LCGC; \ - wstate = wstate + oWeylOffset+((((signed int)wstate)>>31) & oWeylPeriod); \ - v = (state ^ (state>>26)) + wstate; \ - s = (signed int)((v^(v>>20))*0x6957f5a7); \ - r1 = s*TWO_N32*(numtyp)2.0-(numtyp)1.0; \ - state = LCGA*state + LCGC; \ - wstate = wstate + oWeylOffset+((((signed int)wstate)>>31) & oWeylPeriod); \ - v = (state ^ (state>>26)) + wstate; \ - s = (signed int)((v^(v>>20))*0x6957f5a7); \ - r2 = s*TWO_N32*(numtyp)2.0-(numtyp)1.0; \ - rsq = r1 * r1 + r2 * r2; \ - if (rsq < (numtyp)1.0) break; \ - } \ - numtyp fac = sqrt((numtyp)-2.0*log(rsq)/rsq); \ - randnum = r2*fac; \ -} +#define saru(seed1, seed2, seed, timestep, randnum) \ + { \ + unsigned int seed3 = seed + timestep; \ + seed3 ^= (seed1 << 7) ^ (seed2 >> 6); \ + seed2 += (seed1 >> 4) ^ (seed3 >> 15); \ + seed1 ^= (seed2 << 9) + (seed3 << 8); \ + seed3 ^= 0xA5366B4D * ((seed2 >> 11) ^ (seed1 << 1)); \ + seed2 += 0x72BE1579 * ((seed1 << 4) ^ (seed3 >> 16)); \ + seed1 ^= 0x3F38A6ED * ((seed3 >> 5) ^ (((signed int) seed2) >> 22)); \ + seed2 += seed1 * seed3; \ + seed1 += seed3 ^ (seed2 >> 2); \ + seed2 ^= ((signed int) seed2) >> 17; \ + unsigned int state = 0x12345678; \ + unsigned int wstate = 12345678; \ + state = 0x79dedea3 * (seed1 ^ (((signed int) seed1) >> 14)); \ + wstate = (state + seed2) ^ (((signed int) state) >> 8); \ + state = state + (wstate * (wstate ^ 0xdddf97f5)); \ + wstate = 0xABCB96F7 + (wstate >> 1); \ + unsigned int v, s; \ + numtyp r1, r2, rsq; \ + while (1) { \ + state = LCGA * state + LCGC; \ + wstate = wstate + oWeylOffset + ((((signed int) wstate) >> 31) & oWeylPeriod); \ + v = (state ^ (state >> 26)) + wstate; \ + s = (signed int) ((v ^ (v >> 20)) * 0x6957f5a7); \ + r1 = s * TWO_N32 * (numtyp) 2.0 - (numtyp) 1.0; \ + state = LCGA * state + LCGC; \ + wstate = wstate + oWeylOffset + ((((signed int) wstate) >> 31) & oWeylPeriod); \ + v = (state ^ (state >> 26)) + wstate; \ + s = (signed int) ((v ^ (v >> 20)) * 0x6957f5a7); \ + r2 = s * TWO_N32 * (numtyp) 2.0 - (numtyp) 1.0; \ + rsq = r1 * r1 + r2 * r2; \ + if (rsq < (numtyp) 1.0) break; \ + } \ + numtyp fac = sqrt((numtyp) -2.0 * log(rsq) / rsq); \ + randnum = r2 * fac; \ + } #endif /* ---------------------------------------------------------------------- */ @@ -221,17 +218,17 @@ PairDPDGPU::~PairDPDGPU() void PairDPDGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; - double dtinvsqrt = 1.0/sqrt(update->dt); + double dtinvsqrt = 1.0 / sqrt(update->dt); bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -240,33 +237,26 @@ void PairDPDGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = dpd_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->v, dtinvsqrt, seed, - update->ntimestep, - domain->boxlo, domain->prd); + firstneigh = dpd_gpu_compute_n( + neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, atom->nspecial, + atom->special, eflag, vflag, eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->v, dtinvsqrt, seed, update->ntimestep, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - dpd_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, - atom->tag, atom->v, dtinvsqrt, seed, - update->ntimestep, - atom->nlocal, domain->boxlo, domain->prd); + dpd_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->tag, + atom->v, dtinvsqrt, seed, update->ntimestep, atom->nlocal, domain->boxlo, + domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - mcut = init_one(i,j); + mcut = init_one(i, j); mcut *= mcut; - if (mcut > maxcut) - maxcut = mcut; + if (mcut > maxcut) maxcut = mcut; cutsq[i][j] = cutsq[j][i] = mcut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -297,21 +286,15 @@ void PairDPDGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = dpd_gpu_init(atom->ntypes+1, cutsq, a0, gamma, sigma, - cut, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + dpd_gpu_init(atom->ntypes + 1, cutsq, a0, gamma, sigma, cut, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -324,14 +307,15 @@ double PairDPDGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairDPDGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double vxtmp,vytmp,vztmp,delvx,delvy,delvz; - double rsq,r,rinv,dot,wd,randnum,factor_dpd; +void PairDPDGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double vxtmp, vytmp, vztmp, delvx, delvy, delvz; + double rsq, r, rinv, dot, wd, randnum, factor_dpd; int *jlist; - tagint itag,jtag; + tagint itag, jtag; double **x = atom->x; double **v = atom->v; @@ -339,8 +323,8 @@ void PairDPDGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *type = atom->type; tagint *tag = atom->tag; double *special_lj = force->special_lj; - double dtinvsqrt = 1.0/sqrt(update->dt); - int timestep = (int)update->ntimestep; + double dtinvsqrt = 1.0 / sqrt(update->dt); + int timestep = (int) update->ntimestep; // loop over neighbors of my atoms @@ -365,23 +349,24 @@ void PairDPDGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; jtag = tag[j]; if (rsq < cutsq[itype][jtype]) { r = sqrt(rsq); - if (r < EPSILON) continue; // r can be 0.0 in DPD systems - rinv = 1.0/r; + if (r < EPSILON) continue; // r can be 0.0 in DPD systems + rinv = 1.0 / r; delvx = vxtmp - v[j][0]; delvy = vytmp - v[j][1]; delvz = vztmp - v[j][2]; - dot = delx*delvx + dely*delvy + delz*delvz; - wd = 1.0 - r/cut[itype][jtype]; + dot = delx * delvx + dely * delvy + delz * delvz; + wd = 1.0 - r / cut[itype][jtype]; - unsigned int tag1=itag, tag2=jtag; + unsigned int tag1 = itag, tag2 = jtag; if (tag1 > tag2) { - tag1 = jtag; tag2 = itag; + tag1 = jtag; + tag2 = itag; } randnum = 0.0; @@ -391,24 +376,24 @@ void PairDPDGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, // drag force = -gamma * wd^2 * (delx dot delv) / r // random force = sigma * wd * rnd * dtinvsqrt; - fpair = a0[itype][jtype]*wd; - fpair -= gamma[itype][jtype]*wd*wd*dot*rinv; - fpair += sigma[itype][jtype]*wd*randnum*dtinvsqrt; - fpair *= factor_dpd*rinv; + fpair = a0[itype][jtype] * wd; + fpair -= gamma[itype][jtype] * wd * wd * dot * rinv; + fpair += sigma[itype][jtype] * wd * randnum * dtinvsqrt; + fpair *= factor_dpd * rinv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { // unshifted eng of conservative term: // evdwl = -a0[itype][jtype]*r * (1.0-0.5*r/cut[itype][jtype]); // eng shifted to 0.0 at cutoff - evdwl = 0.5*a0[itype][jtype]*cut[itype][jtype] * wd*wd; + evdwl = 0.5 * a0[itype][jtype] * cut[itype][jtype] * wd * wd; evdwl *= factor_dpd; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_dpd_tstat_gpu.cpp b/src/GPU/pair_dpd_tstat_gpu.cpp index c1d07c42a5..c949c9a9aa 100644 --- a/src/GPU/pair_dpd_tstat_gpu.cpp +++ b/src/GPU/pair_dpd_tstat_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include "update.h" @@ -35,33 +33,26 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int dpd_tstat_gpu_init(const int ntypes, double **cutsq, double **host_a0, - double **host_gamma, double **host_sigma, double **host_cut, - double *special_lj, const int inum, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen); +int dpd_tstat_gpu_init(const int ntypes, double **cutsq, double **host_a0, double **host_gamma, + double **host_sigma, double **host_cut, double *special_lj, const int inum, + const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen); void dpd_tstat_gpu_clear(); -int ** dpd_tstat_gpu_compute_n(const int ago, const int inum_full, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, - double **host_v, const double dtinvsqrt, - const int seed, const int timestep, - double *boxlo, double *prd); -void dpd_tstat_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, tagint *tag, - double **host_v, const double dtinvsqrt, - const int seed, const int timestep, - const int nlocal, double *boxlo, double *prd); -void dpd_tstat_gpu_update_coeff(int ntypes, double **host_a0, - double **host_gamma, double **host_sigma, - double **host_cut); +int **dpd_tstat_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, double **host_v, + const double dtinvsqrt, const int seed, const int timestep, + double *boxlo, double *prd); +void dpd_tstat_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, + const bool eflag, const bool vflag, const bool eatom, const bool vatom, + int &host_start, const double cpu_time, bool &success, tagint *tag, + double **host_v, const double dtinvsqrt, const int seed, + const int timestep, const int nlocal, double *boxlo, double *prd); +void dpd_tstat_gpu_update_coeff(int ntypes, double **host_a0, double **host_gamma, + double **host_sigma, double **host_cut); double dpd_tstat_gpu_bytes(); #define EPSILON 1.0e-10 @@ -70,7 +61,8 @@ double dpd_tstat_gpu_bytes(); //#define _USE_UNIFORM_SARU_TEA8 //#define _USE_GAUSSIAN_SARU_LCG -#if !defined(_USE_UNIFORM_SARU_LCG) && !defined(_USE_UNIFORM_SARU_TEA8) && !defined(_USE_GAUSSIAN_SARU_LCG) +#if !defined(_USE_UNIFORM_SARU_LCG) && !defined(_USE_UNIFORM_SARU_TEA8) && \ + !defined(_USE_GAUSSIAN_SARU_LCG) #define _USE_UNIFORM_SARU_LCG #endif @@ -79,9 +71,9 @@ double dpd_tstat_gpu_bytes(); // 2. C. L. Phillips, J. A. Anderson, S. C. Glotzer, Comput. Phys. Comm. 230 (2011), 7191-7201. // PRNG period = 3666320093*2^32 ~ 2^64 ~ 10^19 -#define LCGA 0x4beb5d59 // Full period 32 bit LCG +#define LCGA 0x4beb5d59 // Full period 32 bit LCG #define LCGC 0x2600e1f7 -#define oWeylPeriod 0xda879add // Prime period 3666320093 +#define oWeylPeriod 0xda879add // Prime period 3666320093 #define oWeylOffset 0x8009d14b #define TWO_N32 0.232830643653869628906250e-9f /* 2^-32 */ @@ -93,28 +85,29 @@ double dpd_tstat_gpu_bytes(); // Curly brackets to make variables local to the scope. #ifdef _USE_UNIFORM_SARU_LCG #define numtyp double -#define SQRT3 (numtyp)1.7320508075688772935274463 -#define saru(seed1, seed2, seed, timestep, randnum) { \ - unsigned int seed3 = seed + timestep; \ - seed3^=(seed1<<7)^(seed2>>6); \ - seed2+=(seed1>>4)^(seed3>>15); \ - seed1^=(seed2<<9)+(seed3<<8); \ - seed3^=0xA5366B4D*((seed2>>11) ^ (seed1<<1)); \ - seed2+=0x72BE1579*((seed1<<4) ^ (seed3>>16)); \ - seed1^=0x3F38A6ED*((seed3>>5) ^ (((signed int)seed2)>>22)); \ - seed2+=seed1*seed3; \ - seed1+=seed3 ^ (seed2>>2); \ - seed2^=((signed int)seed2)>>17; \ - unsigned int state = 0x79dedea3*(seed1^(((signed int)seed1)>>14)); \ - unsigned int wstate = (state + seed2) ^ (((signed int)state)>>8); \ - state = state + (wstate*(wstate^0xdddf97f5)); \ - wstate = 0xABCB96F7 + (wstate>>1); \ - state = LCGA*state + LCGC; \ - wstate = wstate + oWeylOffset+((((signed int)wstate)>>31) & oWeylPeriod); \ - unsigned int v = (state ^ (state>>26)) + wstate; \ - unsigned int s = (signed int)((v^(v>>20))*0x6957f5a7); \ - randnum = SQRT3*(s*TWO_N32*(numtyp)2.0-(numtyp)1.0); \ -} +#define SQRT3 (numtyp) 1.7320508075688772935274463 +#define saru(seed1, seed2, seed, timestep, randnum) \ + { \ + unsigned int seed3 = seed + timestep; \ + seed3 ^= (seed1 << 7) ^ (seed2 >> 6); \ + seed2 += (seed1 >> 4) ^ (seed3 >> 15); \ + seed1 ^= (seed2 << 9) + (seed3 << 8); \ + seed3 ^= 0xA5366B4D * ((seed2 >> 11) ^ (seed1 << 1)); \ + seed2 += 0x72BE1579 * ((seed1 << 4) ^ (seed3 >> 16)); \ + seed1 ^= 0x3F38A6ED * ((seed3 >> 5) ^ (((signed int) seed2) >> 22)); \ + seed2 += seed1 * seed3; \ + seed1 += seed3 ^ (seed2 >> 2); \ + seed2 ^= ((signed int) seed2) >> 17; \ + unsigned int state = 0x79dedea3 * (seed1 ^ (((signed int) seed1) >> 14)); \ + unsigned int wstate = (state + seed2) ^ (((signed int) state) >> 8); \ + state = state + (wstate * (wstate ^ 0xdddf97f5)); \ + wstate = 0xABCB96F7 + (wstate >> 1); \ + state = LCGA * state + LCGC; \ + wstate = wstate + oWeylOffset + ((((signed int) wstate) >> 31) & oWeylPeriod); \ + unsigned int v = (state ^ (state >> 26)) + wstate; \ + unsigned int s = (signed int) ((v ^ (v >> 20)) * 0x6957f5a7); \ + randnum = SQRT3 * (s * TWO_N32 * (numtyp) 2.0 - (numtyp) 1.0); \ + } #endif // specifically implemented for steps = 1; high = 1.0; low = -1.0 @@ -123,38 +116,39 @@ double dpd_tstat_gpu_bytes(); // Afshar et al. mutlplies u in [-0.5;0.5] with sqrt(12) #ifdef _USE_UNIFORM_SARU_TEA8 #define numtyp double -#define SQRT3 (numtyp)1.7320508075688772935274463 +#define SQRT3 (numtyp) 1.7320508075688772935274463 #define k0 0xA341316C #define k1 0xC8013EA4 #define k2 0xAD90777D #define k3 0x7E95761E #define delta 0x9e3779b9 #define rounds 8 -#define saru(seed1, seed2, seed, timestep, randnum) { \ - unsigned int seed3 = seed + timestep; \ - seed3^=(seed1<<7)^(seed2>>6); \ - seed2+=(seed1>>4)^(seed3>>15); \ - seed1^=(seed2<<9)+(seed3<<8); \ - seed3^=0xA5366B4D*((seed2>>11) ^ (seed1<<1)); \ - seed2+=0x72BE1579*((seed1<<4) ^ (seed3>>16)); \ - seed1^=0x3F38A6ED*((seed3>>5) ^ (((signed int)seed2)>>22)); \ - seed2+=seed1*seed3; \ - seed1+=seed3 ^ (seed2>>2); \ - seed2^=((signed int)seed2)>>17; \ - unsigned int state = 0x79dedea3*(seed1^(((signed int)seed1)>>14)); \ - unsigned int wstate = (state + seed2) ^ (((signed int)state)>>8); \ - state = state + (wstate*(wstate^0xdddf97f5)); \ - wstate = 0xABCB96F7 + (wstate>>1); \ - unsigned int sum = 0; \ - for (int i=0; i < rounds; i++) { \ - sum += delta; \ - state += ((wstate<<4) + k0)^(wstate + sum)^((wstate>>5) + k1); \ - wstate += ((state<<4) + k2)^(state + sum)^((state>>5) + k3); \ - } \ - unsigned int v = (state ^ (state>>26)) + wstate; \ - unsigned int s = (signed int)((v^(v>>20))*0x6957f5a7); \ - randnum = SQRT3*(s*TWO_N32*(numtyp)2.0-(numtyp)1.0); \ -} +#define saru(seed1, seed2, seed, timestep, randnum) \ + { \ + unsigned int seed3 = seed + timestep; \ + seed3 ^= (seed1 << 7) ^ (seed2 >> 6); \ + seed2 += (seed1 >> 4) ^ (seed3 >> 15); \ + seed1 ^= (seed2 << 9) + (seed3 << 8); \ + seed3 ^= 0xA5366B4D * ((seed2 >> 11) ^ (seed1 << 1)); \ + seed2 += 0x72BE1579 * ((seed1 << 4) ^ (seed3 >> 16)); \ + seed1 ^= 0x3F38A6ED * ((seed3 >> 5) ^ (((signed int) seed2) >> 22)); \ + seed2 += seed1 * seed3; \ + seed1 += seed3 ^ (seed2 >> 2); \ + seed2 ^= ((signed int) seed2) >> 17; \ + unsigned int state = 0x79dedea3 * (seed1 ^ (((signed int) seed1) >> 14)); \ + unsigned int wstate = (state + seed2) ^ (((signed int) state) >> 8); \ + state = state + (wstate * (wstate ^ 0xdddf97f5)); \ + wstate = 0xABCB96F7 + (wstate >> 1); \ + unsigned int sum = 0; \ + for (int i = 0; i < rounds; i++) { \ + sum += delta; \ + state += ((wstate << 4) + k0) ^ (wstate + sum) ^ ((wstate >> 5) + k1); \ + wstate += ((state << 4) + k2) ^ (state + sum) ^ ((state >> 5) + k3); \ + } \ + unsigned int v = (state ^ (state >> 26)) + wstate; \ + unsigned int s = (signed int) ((v ^ (v >> 20)) * 0x6957f5a7); \ + randnum = SQRT3 * (s * TWO_N32 * (numtyp) 2.0 - (numtyp) 1.0); \ + } #endif // specifically implemented for steps = 1; high = 1.0; low = -1.0 @@ -163,48 +157,48 @@ double dpd_tstat_gpu_bytes(); // This is used to compared with CPU DPD using RandMars::gaussian() #ifdef _USE_GAUSSIAN_SARU_LCG #define numtyp double -#define saru(seed1, seed2, seed, timestep, randnum) { \ - unsigned int seed3 = seed + timestep; \ - seed3^=(seed1<<7)^(seed2>>6); \ - seed2+=(seed1>>4)^(seed3>>15); \ - seed1^=(seed2<<9)+(seed3<<8); \ - seed3^=0xA5366B4D*((seed2>>11) ^ (seed1<<1)); \ - seed2+=0x72BE1579*((seed1<<4) ^ (seed3>>16)); \ - seed1^=0x3F38A6ED*((seed3>>5) ^ (((signed int)seed2)>>22)); \ - seed2+=seed1*seed3; \ - seed1+=seed3 ^ (seed2>>2); \ - seed2^=((signed int)seed2)>>17; \ - unsigned int state=0x12345678; \ - unsigned int wstate=12345678; \ - state = 0x79dedea3*(seed1^(((signed int)seed1)>>14)); \ - wstate = (state + seed2) ^ (((signed int)state)>>8); \ - state = state + (wstate*(wstate^0xdddf97f5)); \ - wstate = 0xABCB96F7 + (wstate>>1); \ - unsigned int v, s; \ - numtyp r1, r2, rsq; \ - while (1) { \ - state = LCGA*state + LCGC; \ - wstate = wstate + oWeylOffset+((((signed int)wstate)>>31) & oWeylPeriod); \ - v = (state ^ (state>>26)) + wstate; \ - s = (signed int)((v^(v>>20))*0x6957f5a7); \ - r1 = s*TWO_N32*(numtyp)2.0-(numtyp)1.0; \ - state = LCGA*state + LCGC; \ - wstate = wstate + oWeylOffset+((((signed int)wstate)>>31) & oWeylPeriod); \ - v = (state ^ (state>>26)) + wstate; \ - s = (signed int)((v^(v>>20))*0x6957f5a7); \ - r2 = s*TWO_N32*(numtyp)2.0-(numtyp)1.0; \ - rsq = r1 * r1 + r2 * r2; \ - if (rsq < (numtyp)1.0) break; \ - } \ - numtyp fac = sqrt((numtyp)-2.0*log(rsq)/rsq); \ - randnum = r2*fac; \ -} +#define saru(seed1, seed2, seed, timestep, randnum) \ + { \ + unsigned int seed3 = seed + timestep; \ + seed3 ^= (seed1 << 7) ^ (seed2 >> 6); \ + seed2 += (seed1 >> 4) ^ (seed3 >> 15); \ + seed1 ^= (seed2 << 9) + (seed3 << 8); \ + seed3 ^= 0xA5366B4D * ((seed2 >> 11) ^ (seed1 << 1)); \ + seed2 += 0x72BE1579 * ((seed1 << 4) ^ (seed3 >> 16)); \ + seed1 ^= 0x3F38A6ED * ((seed3 >> 5) ^ (((signed int) seed2) >> 22)); \ + seed2 += seed1 * seed3; \ + seed1 += seed3 ^ (seed2 >> 2); \ + seed2 ^= ((signed int) seed2) >> 17; \ + unsigned int state = 0x12345678; \ + unsigned int wstate = 12345678; \ + state = 0x79dedea3 * (seed1 ^ (((signed int) seed1) >> 14)); \ + wstate = (state + seed2) ^ (((signed int) state) >> 8); \ + state = state + (wstate * (wstate ^ 0xdddf97f5)); \ + wstate = 0xABCB96F7 + (wstate >> 1); \ + unsigned int v, s; \ + numtyp r1, r2, rsq; \ + while (1) { \ + state = LCGA * state + LCGC; \ + wstate = wstate + oWeylOffset + ((((signed int) wstate) >> 31) & oWeylPeriod); \ + v = (state ^ (state >> 26)) + wstate; \ + s = (signed int) ((v ^ (v >> 20)) * 0x6957f5a7); \ + r1 = s * TWO_N32 * (numtyp) 2.0 - (numtyp) 1.0; \ + state = LCGA * state + LCGC; \ + wstate = wstate + oWeylOffset + ((((signed int) wstate) >> 31) & oWeylPeriod); \ + v = (state ^ (state >> 26)) + wstate; \ + s = (signed int) ((v ^ (v >> 20)) * 0x6957f5a7); \ + r2 = s * TWO_N32 * (numtyp) 2.0 - (numtyp) 1.0; \ + rsq = r1 * r1 + r2 * r2; \ + if (rsq < (numtyp) 1.0) break; \ + } \ + numtyp fac = sqrt((numtyp) -2.0 * log(rsq) / rsq); \ + randnum = r2 * fac; \ + } #endif /* ---------------------------------------------------------------------- */ -PairDPDTstatGPU::PairDPDTstatGPU(LAMMPS *lmp) : PairDPDTstat(lmp), - gpu_mode(GPU_FORCE) +PairDPDTstatGPU::PairDPDTstatGPU(LAMMPS *lmp) : PairDPDTstat(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -226,31 +220,31 @@ PairDPDTstatGPU::~PairDPDTstatGPU() void PairDPDTstatGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); // adjust sigma if target T is changing if (t_start != t_stop) { double delta = update->ntimestep - update->beginstep; if (delta != 0.0) delta /= update->endstep - update->beginstep; - temperature = t_start + delta * (t_stop-t_start); + temperature = t_start + delta * (t_stop - t_start); double boltz = force->boltz; for (int i = 1; i <= atom->ntypes; i++) for (int j = i; j <= atom->ntypes; j++) - sigma[i][j] = sigma[j][i] = sqrt(2.0*boltz*temperature*gamma[i][j]); + sigma[i][j] = sigma[j][i] = sqrt(2.0 * boltz * temperature * gamma[i][j]); - dpd_tstat_gpu_update_coeff(atom->ntypes+1, a0, gamma, sigma, cut); + dpd_tstat_gpu_update_coeff(atom->ntypes + 1, a0, gamma, sigma, cut); } int nall = atom->nlocal + atom->nghost; int inum, host_start; - double dtinvsqrt = 1.0/sqrt(update->dt); + double dtinvsqrt = 1.0 / sqrt(update->dt); bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -259,33 +253,26 @@ void PairDPDTstatGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = dpd_tstat_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->v, dtinvsqrt, seed, - update->ntimestep, - domain->boxlo, domain->prd); + firstneigh = dpd_tstat_gpu_compute_n( + neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, atom->nspecial, + atom->special, eflag, vflag, eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->v, dtinvsqrt, seed, update->ntimestep, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - dpd_tstat_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, - atom->tag, atom->v, dtinvsqrt, seed, - update->ntimestep, - atom->nlocal, domain->boxlo, domain->prd); + dpd_tstat_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, + success, atom->tag, atom->v, dtinvsqrt, seed, update->ntimestep, + atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - mcut = init_one(i,j); + mcut = init_one(i, j); mcut *= mcut; - if (mcut > maxcut) - maxcut = mcut; + if (mcut > maxcut) maxcut = mcut; cutsq[i][j] = cutsq[j][i] = mcut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -316,21 +302,15 @@ void PairDPDTstatGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = dpd_tstat_gpu_init(atom->ntypes+1, cutsq, a0, gamma, sigma, - cut, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = dpd_tstat_gpu_init(atom->ntypes + 1, cutsq, a0, gamma, sigma, cut, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, + mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -343,15 +323,15 @@ double PairDPDTstatGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairDPDTstatGPU::cpu_compute(int start, int inum, int /* eflag */, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,fpair; - double vxtmp,vytmp,vztmp,delvx,delvy,delvz; - double rsq,r,rinv,dot,wd,randnum,factor_dpd; +void PairDPDTstatGPU::cpu_compute(int start, int inum, int /* eflag */, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, fpair; + double vxtmp, vytmp, vztmp, delvx, delvy, delvz; + double rsq, r, rinv, dot, wd, randnum, factor_dpd; int *jlist; - tagint itag,jtag; + tagint itag, jtag; double **x = atom->x; double **v = atom->v; @@ -359,8 +339,8 @@ void PairDPDTstatGPU::cpu_compute(int start, int inum, int /* eflag */, int *type = atom->type; tagint *tag = atom->tag; double *special_lj = force->special_lj; - double dtinvsqrt = 1.0/sqrt(update->dt); - int timestep = (int)update->ntimestep; + double dtinvsqrt = 1.0 / sqrt(update->dt); + int timestep = (int) update->ntimestep; // loop over neighbors of my atoms @@ -385,23 +365,24 @@ void PairDPDTstatGPU::cpu_compute(int start, int inum, int /* eflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; jtag = tag[j]; if (rsq < cutsq[itype][jtype]) { r = sqrt(rsq); - if (r < EPSILON) continue; // r can be 0.0 in DPD systems - rinv = 1.0/r; + if (r < EPSILON) continue; // r can be 0.0 in DPD systems + rinv = 1.0 / r; delvx = vxtmp - v[j][0]; delvy = vytmp - v[j][1]; delvz = vztmp - v[j][2]; - dot = delx*delvx + dely*delvy + delz*delvz; - wd = 1.0 - r/cut[itype][jtype]; + dot = delx * delvx + dely * delvy + delz * delvz; + wd = 1.0 - r / cut[itype][jtype]; - unsigned int tag1=itag, tag2=jtag; + unsigned int tag1 = itag, tag2 = jtag; if (tag1 > tag2) { - tag1 = jtag; tag2 = itag; + tag1 = jtag; + tag2 = itag; } randnum = 0.0; @@ -411,15 +392,15 @@ void PairDPDTstatGPU::cpu_compute(int start, int inum, int /* eflag */, // drag force = -gamma * wd^2 * (delx dot delv) / r // random force = sigma * wd * rnd * dtinvsqrt; - fpair = -gamma[itype][jtype]*wd*wd*dot*rinv; - fpair += sigma[itype][jtype]*wd*randnum*dtinvsqrt; - fpair *= factor_dpd*rinv; + fpair = -gamma[itype][jtype] * wd * wd * dot * rinv; + fpair += sigma[itype][jtype] * wd * randnum * dtinvsqrt; + fpair *= factor_dpd * rinv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; - if (evflag) ev_tally_full(i,0.0,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, 0.0, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_eam_alloy_gpu.cpp b/src/GPU/pair_eam_alloy_gpu.cpp index 82710eb15d..d3a22bf1cc 100644 --- a/src/GPU/pair_eam_alloy_gpu.cpp +++ b/src/GPU/pair_eam_alloy_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "gpu_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "suffix.h" @@ -39,32 +37,26 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int eam_alloy_gpu_init(const int ntypes, double host_cutforcesq, - int **host_type2rhor, int **host_type2z2r, - int *host_type2frho, double ***host_rhor_spline, - double ***host_z2r_spline, double ***host_frho_spline, - double** host_cutsq, double rdr, double rdrho, double rhomax, - int nrhor, int nrho, int nz2r, int nfrho, int nr, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen, int &fp_size); +int eam_alloy_gpu_init(const int ntypes, double host_cutforcesq, int **host_type2rhor, + int **host_type2z2r, int *host_type2frho, double ***host_rhor_spline, + double ***host_z2r_spline, double ***host_frho_spline, double **host_cutsq, + double rdr, double rdrho, double rhomax, int nrhor, int nrho, int nz2r, + int nfrho, int nr, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + int &fp_size); void eam_alloy_gpu_clear(); -int** eam_alloy_gpu_compute_n(const int ago, const int inum_full, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, - int &inum, void **fp_ptr); -void eam_alloy_gpu_compute(const int ago, const int inum_full, const int nlocal, - const int nall,double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, void **fp_ptr); -void eam_alloy_gpu_compute_force(int *ilist, const bool eflag, const bool vflag, - const bool eatom, const bool vatom); +int **eam_alloy_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, int &inum, + void **fp_ptr); +void eam_alloy_gpu_compute(const int ago, const int inum_full, const int nlocal, const int nall, + double **host_x, int *host_type, int *ilist, int *numj, int **firstneigh, + const bool eflag, const bool vflag, const bool eatom, const bool vatom, + int &host_start, const double cpu_time, bool &success, void **fp_ptr); +void eam_alloy_gpu_compute_force(int *ilist, const bool eflag, const bool vflag, const bool eatom, + const bool vatom); double eam_alloy_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -98,7 +90,7 @@ double PairEAMAlloyGPU::memory_usage() void PairEAMAlloyGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); // compute density on each atom on GPU @@ -109,7 +101,7 @@ void PairEAMAlloyGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -118,27 +110,24 @@ void PairEAMAlloyGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = eam_alloy_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, inum_dev, &fp_pinned); - } else { // gpu_mode == GPU_FORCE + firstneigh = eam_alloy_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, + subhi, atom->tag, atom->nspecial, atom->special, eflag, + vflag, eflag_atom, vflag_atom, host_start, &ilist, + &numneigh, cpu_time, success, inum_dev, &fp_pinned); + } else { // gpu_mode == GPU_FORCE inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - eam_alloy_gpu_compute(neighbor->ago, inum, nlocal, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, &fp_pinned); + eam_alloy_gpu_compute(neighbor->ago, inum, nlocal, nall, atom->x, atom->type, ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, + success, &fp_pinned); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); // communicate derivative of embedding function @@ -169,10 +158,9 @@ void PairEAMAlloyGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -180,23 +168,17 @@ void PairEAMAlloyGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int fp_size; int mnf = 5e-2 * neighbor->oneatom; - int success = eam_alloy_gpu_init(atom->ntypes+1, cutforcesq, type2rhor, type2z2r, - type2frho, rhor_spline, z2r_spline, frho_spline, - cutsq, rdr, rdrho, rhomax, nrhor, nrho, nz2r, nfrho, nr, - atom->nlocal, atom->nlocal+atom->nghost, mnf, - maxspecial, cell_size, gpu_mode, screen, fp_size); - GPU_EXTRA::check_flag(success,error,world); + int success = eam_alloy_gpu_init( + atom->ntypes + 1, cutforcesq, type2rhor, type2z2r, type2frho, rhor_spline, z2r_spline, + frho_spline, cutsq, rdr, rdrho, rhomax, nrhor, nrho, nz2r, nfrho, nr, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen, fp_size); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); if (fp_size == sizeof(double)) fp_single = false; else @@ -207,64 +189,63 @@ void PairEAMAlloyGPU::init_style() /* ---------------------------------------------------------------------- */ -double PairEAMAlloyGPU::single(int i, int j, int itype, int jtype, - double rsq, double /* factor_coul */, - double /* factor_lj */, double &fforce) +double PairEAMAlloyGPU::single(int i, int j, int itype, int jtype, double rsq, + double /* factor_coul */, double /* factor_lj */, double &fforce) { int m; - double r,p,rhoip,rhojp,z2,z2p,recip,phi,phip,psip; + double r, p, rhoip, rhojp, z2, z2p, recip, phi, phip, psip; double *coeff; r = sqrt(rsq); - p = r*rdr + 1.0; - m = static_cast (p); - m = MIN(m,nr-1); + p = r * rdr + 1.0; + m = static_cast(p); + m = MIN(m, nr - 1); p -= m; - p = MIN(p,1.0); + p = MIN(p, 1.0); coeff = rhor_spline[type2rhor[itype][jtype]][m]; - rhoip = (coeff[0]*p + coeff[1])*p + coeff[2]; + rhoip = (coeff[0] * p + coeff[1]) * p + coeff[2]; coeff = rhor_spline[type2rhor[jtype][itype]][m]; - rhojp = (coeff[0]*p + coeff[1])*p + coeff[2]; + rhojp = (coeff[0] * p + coeff[1]) * p + coeff[2]; coeff = z2r_spline[type2z2r[itype][jtype]][m]; - z2p = (coeff[0]*p + coeff[1])*p + coeff[2]; - z2 = ((coeff[3]*p + coeff[4])*p + coeff[5])*p + coeff[6]; + z2p = (coeff[0] * p + coeff[1]) * p + coeff[2]; + z2 = ((coeff[3] * p + coeff[4]) * p + coeff[5]) * p + coeff[6]; - double fp_i,fp_j; + double fp_i, fp_j; if (fp_single == false) { - fp_i = ((double*)fp_pinned)[i]; - fp_j = ((double*)fp_pinned)[j]; + fp_i = ((double *) fp_pinned)[i]; + fp_j = ((double *) fp_pinned)[j]; } else { - fp_i = ((float*)fp_pinned)[i]; - fp_j = ((float*)fp_pinned)[j]; + fp_i = ((float *) fp_pinned)[i]; + fp_j = ((float *) fp_pinned)[j]; } - recip = 1.0/r; - phi = z2*recip; - phip = z2p*recip - phi*recip; - psip = fp_i*rhojp + fp_j*rhoip + phip; - fforce = -psip*recip; + recip = 1.0 / r; + phi = z2 * recip; + phip = z2p * recip - phi * recip; + psip = fp_i * rhojp + fp_j * rhoip + phip; + fforce = -psip * recip; return phi; } /* ---------------------------------------------------------------------- */ -int PairEAMAlloyGPU::pack_forward_comm(int n, int *list, double *buf, - int /* pbc_flag */, int * /* pbc */) +int PairEAMAlloyGPU::pack_forward_comm(int n, int *list, double *buf, int /* pbc_flag */, + int * /* pbc */) { - int i,j,m; + int i, j, m; m = 0; if (fp_single) { - float *fp_ptr = (float *)fp_pinned; + float *fp_ptr = (float *) fp_pinned; for (i = 0; i < n; i++) { j = list[i]; buf[m++] = static_cast(fp_ptr[j]); } } else { - double *fp_ptr = (double *)fp_pinned; + double *fp_ptr = (double *) fp_pinned; for (i = 0; i < n; i++) { j = list[i]; buf[m++] = fp_ptr[j]; @@ -278,15 +259,15 @@ int PairEAMAlloyGPU::pack_forward_comm(int n, int *list, double *buf, void PairEAMAlloyGPU::unpack_forward_comm(int n, int first, double *buf) { - int i,m,last; + int i, m, last; m = 0; last = first + n; if (fp_single) { - float *fp_ptr = (float *)fp_pinned; + float *fp_ptr = (float *) fp_pinned; for (i = first; i < last; i++) fp_ptr[i] = buf[m++]; } else { - double *fp_ptr = (double *)fp_pinned; + double *fp_ptr = (double *) fp_pinned; for (i = first; i < last; i++) fp_ptr[i] = buf[m++]; } } @@ -298,23 +279,22 @@ void PairEAMAlloyGPU::unpack_forward_comm(int n, int first, double *buf) void PairEAMAlloyGPU::coeff(int narg, char **arg) { - int i,j; + int i, j; if (!allocated) allocate(); - if (narg != 3 + atom->ntypes) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg != 3 + atom->ntypes) error->all(FLERR, "Incorrect args for pair coefficients"); // insure I,J args are * * - if (strcmp(arg[0],"*") != 0 || strcmp(arg[1],"*") != 0) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (strcmp(arg[0], "*") != 0 || strcmp(arg[1], "*") != 0) + error->all(FLERR, "Incorrect args for pair coefficients"); // read EAM setfl file if (setfl) { - for (i = 0; i < setfl->nelements; i++) delete [] setfl->elements[i]; - delete [] setfl->elements; + for (i = 0; i < setfl->nelements; i++) delete[] setfl->elements[i]; + delete[] setfl->elements; memory->destroy(setfl->mass); memory->destroy(setfl->frho); memory->destroy(setfl->rhor); @@ -328,22 +308,23 @@ void PairEAMAlloyGPU::coeff(int narg, char **arg) // map[i] = which element the Ith atom type is, -1 if "NULL" for (i = 3; i < narg; i++) { - if (strcmp(arg[i],"NULL") == 0) { - map[i-2] = -1; + if (strcmp(arg[i], "NULL") == 0) { + map[i - 2] = -1; continue; } for (j = 0; j < setfl->nelements; j++) - if (strcmp(arg[i],setfl->elements[j]) == 0) break; - if (j < setfl->nelements) map[i-2] = j; - else error->all(FLERR,"No matching element in EAM potential file"); + if (strcmp(arg[i], setfl->elements[j]) == 0) break; + if (j < setfl->nelements) + map[i - 2] = j; + else + error->all(FLERR, "No matching element in EAM potential file"); } // clear setflag since coeff() called once with I,J = * * int n = atom->ntypes; for (i = 1; i <= n; i++) - for (j = i; j <= n; j++) - setflag[i][j] = 0; + for (j = i; j <= n; j++) setflag[i][j] = 0; // set setflag i,j for type pairs where both are mapped to elements // set mass of atom type if i = j @@ -353,14 +334,14 @@ void PairEAMAlloyGPU::coeff(int narg, char **arg) for (j = i; j <= n; j++) { if (map[i] >= 0 && map[j] >= 0) { setflag[i][j] = 1; - if (i == j) atom->set_mass(FLERR,i,setfl->mass[map[i]]); + if (i == j) atom->set_mass(FLERR, i, setfl->mass[map[i]]); count++; } scale[i][j] = 1.0; } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -378,8 +359,7 @@ void PairEAMAlloyGPU::read_file(char *filename) // transparently convert units for supported conversions int unit_convert = reader.get_unit_convert(); - double conversion_factor = utils::get_conversion_factor(utils::ENERGY, - unit_convert); + double conversion_factor = utils::get_conversion_factor(utils::ENERGY, unit_convert); try { reader.skip_line(); reader.skip_line(); @@ -389,10 +369,10 @@ void PairEAMAlloyGPU::read_file(char *filename) ValueTokenizer values = reader.next_values(1); file->nelements = values.next_int(); - if ((int)values.count() != file->nelements + 1) - error->one(FLERR,"Incorrect element names in EAM potential file"); + if ((int) values.count() != file->nelements + 1) + error->one(FLERR, "Incorrect element names in EAM potential file"); - file->elements = new char*[file->nelements]; + file->elements = new char *[file->nelements]; for (int i = 0; i < file->nelements; i++) file->elements[i] = utils::strdup(values.next_string()); @@ -401,12 +381,12 @@ void PairEAMAlloyGPU::read_file(char *filename) values = reader.next_values(5); file->nrho = values.next_int(); file->drho = values.next_double(); - file->nr = values.next_int(); - file->dr = values.next_double(); - file->cut = values.next_double(); + file->nr = values.next_int(); + file->dr = values.next_double(); + file->cut = values.next_double(); if ((file->nrho <= 0) || (file->nr <= 0) || (file->dr <= 0.0)) - error->one(FLERR,"Invalid EAM potential file"); + error->one(FLERR, "Invalid EAM potential file"); memory->create(file->mass, file->nelements, "pair:mass"); memory->create(file->frho, file->nelements, file->nrho + 1, "pair:frho"); @@ -415,14 +395,13 @@ void PairEAMAlloyGPU::read_file(char *filename) for (int i = 0; i < file->nelements; i++) { values = reader.next_values(2); - values.next_int(); // ignore + values.next_int(); // ignore file->mass[i] = values.next_double(); reader.next_dvector(&file->frho[i][1], file->nrho); reader.next_dvector(&file->rhor[i][1], file->nr); if (unit_convert) { - for (int j = 1; j < file->nrho; ++j) - file->frho[i][j] *= conversion_factor; + for (int j = 1; j < file->nrho; ++j) file->frho[i][j] *= conversion_factor; } } @@ -430,8 +409,7 @@ void PairEAMAlloyGPU::read_file(char *filename) for (int j = 0; j <= i; j++) { reader.next_dvector(&file->z2r[i][j][1], file->nr); if (unit_convert) { - for (int k = 1; k < file->nr; ++k) - file->z2r[i][j][k] *= conversion_factor; + for (int k = 1; k < file->nr; ++k) file->z2r[i][j][k] *= conversion_factor; } } } @@ -451,7 +429,7 @@ void PairEAMAlloyGPU::read_file(char *filename) // allocate memory on other procs if (comm->me != 0) { - file->elements = new char*[file->nelements]; + file->elements = new char *[file->nelements]; for (int i = 0; i < file->nelements; i++) file->elements[i] = nullptr; memory->create(file->mass, file->nelements, "pair:mass"); memory->create(file->frho, file->nelements, file->nrho + 1, "pair:frho"); @@ -477,9 +455,7 @@ void PairEAMAlloyGPU::read_file(char *filename) // broadcast file->z2r for (int i = 0; i < file->nelements; i++) { - for (int j = 0; j <= i; j++) { - MPI_Bcast(&file->z2r[i][j][1], file->nr, MPI_DOUBLE, 0, world); - } + for (int j = 0; j <= i; j++) { MPI_Bcast(&file->z2r[i][j][1], file->nr, MPI_DOUBLE, 0, world); } } } @@ -489,7 +465,7 @@ void PairEAMAlloyGPU::read_file(char *filename) void PairEAMAlloyGPU::file2array() { - int i,j,m,n; + int i, j, m, n; int ntypes = atom->ntypes; // set function params directly from setfl file @@ -498,7 +474,7 @@ void PairEAMAlloyGPU::file2array() nr = setfl->nr; drho = setfl->drho; dr = setfl->dr; - rhomax = (nrho-1) * drho; + rhomax = (nrho - 1) * drho; // ------------------------------------------------------------------ // setup frho arrays @@ -509,7 +485,7 @@ void PairEAMAlloyGPU::file2array() nfrho = setfl->nelements + 1; memory->destroy(frho); - memory->create(frho,nfrho,nrho+1,"pair:frho"); + memory->create(frho, nfrho, nrho + 1, "pair:frho"); // copy each element's frho to global frho @@ -519,15 +495,17 @@ void PairEAMAlloyGPU::file2array() // add extra frho of zeroes for non-EAM types to point to (pair hybrid) // this is necessary b/c fp is still computed for non-EAM atoms - for (m = 1; m <= nrho; m++) frho[nfrho-1][m] = 0.0; + for (m = 1; m <= nrho; m++) frho[nfrho - 1][m] = 0.0; // type2frho[i] = which frho array (0 to nfrho-1) each atom type maps to // if atom type doesn't point to element (non-EAM atom in pair hybrid) // then map it to last frho array of zeroes for (i = 1; i <= ntypes; i++) - if (map[i] >= 0) type2frho[i] = map[i]; - else type2frho[i] = nfrho-1; + if (map[i] >= 0) + type2frho[i] = map[i]; + else + type2frho[i] = nfrho - 1; // ------------------------------------------------------------------ // setup rhor arrays @@ -538,7 +516,7 @@ void PairEAMAlloyGPU::file2array() nrhor = setfl->nelements; memory->destroy(rhor); - memory->create(rhor,nrhor,nr+1,"pair:rhor"); + memory->create(rhor, nrhor, nr + 1, "pair:rhor"); // copy each element's rhor to global rhor @@ -550,8 +528,7 @@ void PairEAMAlloyGPU::file2array() // OK if map = -1 (non-EAM atom in pair hybrid) b/c type2rhor not used for (i = 1; i <= ntypes; i++) - for (j = 1; j <= ntypes; j++) - type2rhor[i][j] = map[i]; + for (j = 1; j <= ntypes; j++) type2rhor[i][j] = map[i]; // ------------------------------------------------------------------ // setup z2r arrays @@ -560,9 +537,9 @@ void PairEAMAlloyGPU::file2array() // allocate z2r arrays // nz2r = N*(N+1)/2 where N = # of setfl elements - nz2r = setfl->nelements * (setfl->nelements+1) / 2; + nz2r = setfl->nelements * (setfl->nelements + 1) / 2; memory->destroy(z2r); - memory->create(z2r,nz2r,nr+1,"pair:z2r"); + memory->create(z2r, nz2r, nr + 1, "pair:z2r"); // copy each element pair z2r to global z2r, only for I >= J @@ -581,7 +558,7 @@ void PairEAMAlloyGPU::file2array() // type2z2r is not used by non-opt // but set type2z2r to 0 since accessed by opt - int irow,icol; + int irow, icol; for (i = 1; i <= ntypes; i++) { for (j = 1; j <= ntypes; j++) { irow = map[i]; diff --git a/src/GPU/pair_eam_fs_gpu.cpp b/src/GPU/pair_eam_fs_gpu.cpp index 2a406d68e8..09d2b03be4 100644 --- a/src/GPU/pair_eam_fs_gpu.cpp +++ b/src/GPU/pair_eam_fs_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "gpu_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "suffix.h" @@ -39,31 +37,26 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int eam_fs_gpu_init(const int ntypes, double host_cutforcesq, - int **host_type2rhor, int **host_type2z2r, - int *host_type2frho, double ***host_rhor_spline, - double ***host_z2r_spline, double ***host_frho_spline, - double** host_cutsq, double rdr, double rdrho, double rhomax, - int nrhor, int nrho, int nz2r, int nfrho, int nr, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, int &gpu_mode, - FILE *screen, int &fp_size); +int eam_fs_gpu_init(const int ntypes, double host_cutforcesq, int **host_type2rhor, + int **host_type2z2r, int *host_type2frho, double ***host_rhor_spline, + double ***host_z2r_spline, double ***host_frho_spline, double **host_cutsq, + double rdr, double rdrho, double rhomax, int nrhor, int nrho, int nz2r, + int nfrho, int nr, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + int &fp_size); void eam_fs_gpu_clear(); -int** eam_fs_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, int &inum, void **fp_ptr); -void eam_fs_gpu_compute(const int ago, const int inum_full, const int nlocal, - const int nall,double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, void **fp_ptr); -void eam_fs_gpu_compute_force(int *ilist, const bool eflag, const bool vflag, - const bool eatom, const bool vatom); +int **eam_fs_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, int &inum, + void **fp_ptr); +void eam_fs_gpu_compute(const int ago, const int inum_full, const int nlocal, const int nall, + double **host_x, int *host_type, int *ilist, int *numj, int **firstneigh, + const bool eflag, const bool vflag, const bool eatom, const bool vatom, + int &host_start, const double cpu_time, bool &success, void **fp_ptr); +void eam_fs_gpu_compute_force(int *ilist, const bool eflag, const bool vflag, const bool eatom, + const bool vatom); double eam_fs_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -97,7 +90,7 @@ double PairEAMFSGPU::memory_usage() void PairEAMFSGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); // compute density on each atom on GPU @@ -108,7 +101,7 @@ void PairEAMFSGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -117,27 +110,24 @@ void PairEAMFSGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = eam_fs_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, inum_dev, &fp_pinned); - } else { // gpu_mode == GPU_FORCE + firstneigh = eam_fs_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, inum_dev, &fp_pinned); + } else { // gpu_mode == GPU_FORCE inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - eam_fs_gpu_compute(neighbor->ago, inum, nlocal, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, &fp_pinned); + eam_fs_gpu_compute(neighbor->ago, inum, nlocal, nall, atom->x, atom->type, ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, + success, &fp_pinned); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); // communicate derivative of embedding function @@ -168,10 +158,9 @@ void PairEAMFSGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -179,23 +168,17 @@ void PairEAMFSGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int fp_size; int mnf = 5e-2 * neighbor->oneatom; - int success = eam_fs_gpu_init(atom->ntypes+1, cutforcesq, type2rhor, type2z2r, - type2frho, rhor_spline, z2r_spline, frho_spline, - cutsq, rdr, rdrho, rhomax, nrhor, nrho, nz2r, nfrho, nr, - atom->nlocal, atom->nlocal+atom->nghost, mnf, - maxspecial, cell_size, gpu_mode, screen, fp_size); - GPU_EXTRA::check_flag(success,error,world); + int success = eam_fs_gpu_init( + atom->ntypes + 1, cutforcesq, type2rhor, type2z2r, type2frho, rhor_spline, z2r_spline, + frho_spline, cutsq, rdr, rdrho, rhomax, nrhor, nrho, nz2r, nfrho, nr, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen, fp_size); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); if (fp_size == sizeof(double)) fp_single = false; else @@ -206,64 +189,63 @@ void PairEAMFSGPU::init_style() /* ---------------------------------------------------------------------- */ -double PairEAMFSGPU::single(int i, int j, int itype, int jtype, - double rsq, double /* factor_coul */, - double /* factor_lj */, double &fforce) +double PairEAMFSGPU::single(int i, int j, int itype, int jtype, double rsq, + double /* factor_coul */, double /* factor_lj */, double &fforce) { int m; - double r,p,rhoip,rhojp,z2,z2p,recip,phi,phip,psip; + double r, p, rhoip, rhojp, z2, z2p, recip, phi, phip, psip; double *coeff; r = sqrt(rsq); - p = r*rdr + 1.0; - m = static_cast (p); - m = MIN(m,nr-1); + p = r * rdr + 1.0; + m = static_cast(p); + m = MIN(m, nr - 1); p -= m; - p = MIN(p,1.0); + p = MIN(p, 1.0); coeff = rhor_spline[type2rhor[itype][jtype]][m]; - rhoip = (coeff[0]*p + coeff[1])*p + coeff[2]; + rhoip = (coeff[0] * p + coeff[1]) * p + coeff[2]; coeff = rhor_spline[type2rhor[jtype][itype]][m]; - rhojp = (coeff[0]*p + coeff[1])*p + coeff[2]; + rhojp = (coeff[0] * p + coeff[1]) * p + coeff[2]; coeff = z2r_spline[type2z2r[itype][jtype]][m]; - z2p = (coeff[0]*p + coeff[1])*p + coeff[2]; - z2 = ((coeff[3]*p + coeff[4])*p + coeff[5])*p + coeff[6]; + z2p = (coeff[0] * p + coeff[1]) * p + coeff[2]; + z2 = ((coeff[3] * p + coeff[4]) * p + coeff[5]) * p + coeff[6]; - double fp_i,fp_j; + double fp_i, fp_j; if (fp_single == false) { - fp_i = ((double*)fp_pinned)[i]; - fp_j = ((double*)fp_pinned)[j]; + fp_i = ((double *) fp_pinned)[i]; + fp_j = ((double *) fp_pinned)[j]; } else { - fp_i = ((float*)fp_pinned)[i]; - fp_j = ((float*)fp_pinned)[j]; + fp_i = ((float *) fp_pinned)[i]; + fp_j = ((float *) fp_pinned)[j]; } - recip = 1.0/r; - phi = z2*recip; - phip = z2p*recip - phi*recip; - psip = fp_i*rhojp + fp_j*rhoip + phip; - fforce = -psip*recip; + recip = 1.0 / r; + phi = z2 * recip; + phip = z2p * recip - phi * recip; + psip = fp_i * rhojp + fp_j * rhoip + phip; + fforce = -psip * recip; return phi; } /* ---------------------------------------------------------------------- */ -int PairEAMFSGPU::pack_forward_comm(int n, int *list, double *buf, - int /* pbc_flag */, int * /* pbc */) +int PairEAMFSGPU::pack_forward_comm(int n, int *list, double *buf, int /* pbc_flag */, + int * /* pbc */) { - int i,j,m; + int i, j, m; m = 0; if (fp_single) { - float *fp_ptr = (float *)fp_pinned; + float *fp_ptr = (float *) fp_pinned; for (i = 0; i < n; i++) { j = list[i]; buf[m++] = static_cast(fp_ptr[j]); } } else { - double *fp_ptr = (double *)fp_pinned; + double *fp_ptr = (double *) fp_pinned; for (i = 0; i < n; i++) { j = list[i]; buf[m++] = fp_ptr[j]; @@ -277,15 +259,15 @@ int PairEAMFSGPU::pack_forward_comm(int n, int *list, double *buf, void PairEAMFSGPU::unpack_forward_comm(int n, int first, double *buf) { - int i,m,last; + int i, m, last; m = 0; last = first + n; if (fp_single) { - float *fp_ptr = (float *)fp_pinned; + float *fp_ptr = (float *) fp_pinned; for (i = first; i < last; i++) fp_ptr[i] = buf[m++]; } else { - double *fp_ptr = (double *)fp_pinned; + double *fp_ptr = (double *) fp_pinned; for (i = first; i < last; i++) fp_ptr[i] = buf[m++]; } } @@ -297,23 +279,22 @@ void PairEAMFSGPU::unpack_forward_comm(int n, int first, double *buf) void PairEAMFSGPU::coeff(int narg, char **arg) { - int i,j; + int i, j; if (!allocated) allocate(); - if (narg != 3 + atom->ntypes) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg != 3 + atom->ntypes) error->all(FLERR, "Incorrect args for pair coefficients"); // insure I,J args are * * - if (strcmp(arg[0],"*") != 0 || strcmp(arg[1],"*") != 0) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (strcmp(arg[0], "*") != 0 || strcmp(arg[1], "*") != 0) + error->all(FLERR, "Incorrect args for pair coefficients"); // read EAM Finnis-Sinclair file if (fs) { - for (i = 0; i < fs->nelements; i++) delete [] fs->elements[i]; - delete [] fs->elements; + for (i = 0; i < fs->nelements; i++) delete[] fs->elements[i]; + delete[] fs->elements; memory->destroy(fs->mass); memory->destroy(fs->frho); memory->destroy(fs->rhor); @@ -327,22 +308,23 @@ void PairEAMFSGPU::coeff(int narg, char **arg) // map[i] = which element the Ith atom type is, -1 if "NULL" for (i = 3; i < narg; i++) { - if (strcmp(arg[i],"NULL") == 0) { - map[i-2] = -1; + if (strcmp(arg[i], "NULL") == 0) { + map[i - 2] = -1; continue; } for (j = 0; j < fs->nelements; j++) - if (strcmp(arg[i],fs->elements[j]) == 0) break; - if (j < fs->nelements) map[i-2] = j; - else error->all(FLERR,"No matching element in EAM potential file"); + if (strcmp(arg[i], fs->elements[j]) == 0) break; + if (j < fs->nelements) + map[i - 2] = j; + else + error->all(FLERR, "No matching element in EAM potential file"); } // clear setflag since coeff() called once with I,J = * * int n = atom->ntypes; for (i = 1; i <= n; i++) - for (j = i; j <= n; j++) - setflag[i][j] = 0; + for (j = i; j <= n; j++) setflag[i][j] = 0; // set setflag i,j for type pairs where both are mapped to elements // set mass of atom type if i = j @@ -352,14 +334,14 @@ void PairEAMFSGPU::coeff(int narg, char **arg) for (j = i; j <= n; j++) { if (map[i] >= 0 && map[j] >= 0) { setflag[i][j] = 1; - if (i == j) atom->set_mass(FLERR,i,fs->mass[map[i]]); + if (i == j) atom->set_mass(FLERR, i, fs->mass[map[i]]); count++; } scale[i][j] = 1.0; } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -372,14 +354,12 @@ void PairEAMFSGPU::read_file(char *filename) // read potential file if (comm->me == 0) { - PotentialFileReader reader(PairEAM::lmp, filename, "eam/fs", - unit_convert_flag); + PotentialFileReader reader(PairEAM::lmp, filename, "eam/fs", unit_convert_flag); // transparently convert units for supported conversions int unit_convert = reader.get_unit_convert(); - double conversion_factor = utils::get_conversion_factor(utils::ENERGY, - unit_convert); + double conversion_factor = utils::get_conversion_factor(utils::ENERGY, unit_convert); try { reader.skip_line(); reader.skip_line(); @@ -389,10 +369,10 @@ void PairEAMFSGPU::read_file(char *filename) ValueTokenizer values = reader.next_values(1); file->nelements = values.next_int(); - if ((int)values.count() != file->nelements + 1) - error->one(FLERR,"Incorrect element names in EAM potential file"); + if ((int) values.count() != file->nelements + 1) + error->one(FLERR, "Incorrect element names in EAM potential file"); - file->elements = new char*[file->nelements]; + file->elements = new char *[file->nelements]; for (int i = 0; i < file->nelements; i++) { const std::string word = values.next_string(); file->elements[i] = utils::strdup(word); @@ -403,13 +383,13 @@ void PairEAMFSGPU::read_file(char *filename) values = reader.next_values(5); file->nrho = values.next_int(); file->drho = values.next_double(); - file->nr = values.next_int(); - file->dr = values.next_double(); - file->cut = values.next_double(); + file->nr = values.next_int(); + file->dr = values.next_double(); + file->cut = values.next_double(); rhomax = 0.0; if ((file->nrho <= 0) || (file->nr <= 0) || (file->dr <= 0.0)) - error->one(FLERR,"Invalid EAM potential file"); + error->one(FLERR, "Invalid EAM potential file"); memory->create(file->mass, file->nelements, "pair:mass"); memory->create(file->frho, file->nelements, file->nrho + 1, "pair:frho"); @@ -418,13 +398,12 @@ void PairEAMFSGPU::read_file(char *filename) for (int i = 0; i < file->nelements; i++) { values = reader.next_values(2); - values.next_int(); // ignore + values.next_int(); // ignore file->mass[i] = values.next_double(); reader.next_dvector(&file->frho[i][1], file->nrho); if (unit_convert) { - for (int j = 1; j <= file->nrho; ++j) - file->frho[i][j] *= conversion_factor; + for (int j = 1; j <= file->nrho; ++j) file->frho[i][j] *= conversion_factor; } for (int j = 0; j < file->nelements; j++) { @@ -436,8 +415,7 @@ void PairEAMFSGPU::read_file(char *filename) for (int j = 0; j <= i; j++) { reader.next_dvector(&file->z2r[i][j][1], file->nr); if (unit_convert) { - for (int k = 1; k <= file->nr; ++k) - file->z2r[i][j][k] *= conversion_factor; + for (int k = 1; k <= file->nr; ++k) file->z2r[i][j][k] *= conversion_factor; } } } @@ -458,7 +436,7 @@ void PairEAMFSGPU::read_file(char *filename) // allocate memory on other procs if (comm->me != 0) { - file->elements = new char*[file->nelements]; + file->elements = new char *[file->nelements]; for (int i = 0; i < file->nelements; i++) file->elements[i] = nullptr; memory->create(file->mass, file->nelements, "pair:mass"); memory->create(file->frho, file->nelements, file->nrho + 1, "pair:frho"); @@ -487,9 +465,7 @@ void PairEAMFSGPU::read_file(char *filename) // broadcast file->z2r for (int i = 0; i < file->nelements; i++) { - for (int j = 0; j <= i; j++) { - MPI_Bcast(&file->z2r[i][j][1], file->nr, MPI_DOUBLE, 0, world); - } + for (int j = 0; j <= i; j++) { MPI_Bcast(&file->z2r[i][j][1], file->nr, MPI_DOUBLE, 0, world); } } } @@ -499,7 +475,7 @@ void PairEAMFSGPU::read_file(char *filename) void PairEAMFSGPU::file2array() { - int i,j,m,n; + int i, j, m, n; int ntypes = atom->ntypes; // set function params directly from fs file @@ -508,7 +484,7 @@ void PairEAMFSGPU::file2array() nr = fs->nr; drho = fs->drho; dr = fs->dr; - rhomax = (nrho-1) * drho; + rhomax = (nrho - 1) * drho; // ------------------------------------------------------------------ // setup frho arrays @@ -519,7 +495,7 @@ void PairEAMFSGPU::file2array() nfrho = fs->nelements + 1; memory->destroy(frho); - memory->create(frho,nfrho,nrho+1,"pair:frho"); + memory->create(frho, nfrho, nrho + 1, "pair:frho"); // copy each element's frho to global frho @@ -529,15 +505,17 @@ void PairEAMFSGPU::file2array() // add extra frho of zeroes for non-EAM types to point to (pair hybrid) // this is necessary b/c fp is still computed for non-EAM atoms - for (m = 1; m <= nrho; m++) frho[nfrho-1][m] = 0.0; + for (m = 1; m <= nrho; m++) frho[nfrho - 1][m] = 0.0; // type2frho[i] = which frho array (0 to nfrho-1) each atom type maps to // if atom type doesn't point to element (non-EAM atom in pair hybrid) // then map it to last frho array of zeroes for (i = 1; i <= ntypes; i++) - if (map[i] >= 0) type2frho[i] = map[i]; - else type2frho[i] = nfrho-1; + if (map[i] >= 0) + type2frho[i] = map[i]; + else + type2frho[i] = nfrho - 1; // ------------------------------------------------------------------ // setup rhor arrays @@ -548,7 +526,7 @@ void PairEAMFSGPU::file2array() nrhor = fs->nelements * fs->nelements; memory->destroy(rhor); - memory->create(rhor,nrhor,nr+1,"pair:rhor"); + memory->create(rhor, nrhor, nr + 1, "pair:rhor"); // copy each element pair rhor to global rhor @@ -564,8 +542,7 @@ void PairEAMFSGPU::file2array() // OK if map = -1 (non-EAM atom in pair hybrid) b/c type2rhor not used for (i = 1; i <= ntypes; i++) - for (j = 1; j <= ntypes; j++) - type2rhor[i][j] = map[i] * fs->nelements + map[j]; + for (j = 1; j <= ntypes; j++) type2rhor[i][j] = map[i] * fs->nelements + map[j]; // ------------------------------------------------------------------ // setup z2r arrays @@ -574,9 +551,9 @@ void PairEAMFSGPU::file2array() // allocate z2r arrays // nz2r = N*(N+1)/2 where N = # of fs elements - nz2r = fs->nelements * (fs->nelements+1) / 2; + nz2r = fs->nelements * (fs->nelements + 1) / 2; memory->destroy(z2r); - memory->create(z2r,nz2r,nr+1,"pair:z2r"); + memory->create(z2r, nz2r, nr + 1, "pair:z2r"); // copy each element pair z2r to global z2r, only for I >= J @@ -595,7 +572,7 @@ void PairEAMFSGPU::file2array() // type2z2r is not used by non-opt // but set type2z2r to 0 since accessed by opt - int irow,icol; + int irow, icol; for (i = 1; i <= ntypes; i++) { for (j = 1; j <= ntypes; j++) { irow = map[i]; diff --git a/src/GPU/pair_eam_gpu.cpp b/src/GPU/pair_eam_gpu.cpp index 76f7a9684c..1fbba6dd6b 100644 --- a/src/GPU/pair_eam_gpu.cpp +++ b/src/GPU/pair_eam_gpu.cpp @@ -24,7 +24,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -36,31 +35,25 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int eam_gpu_init(const int ntypes, double host_cutforcesq, - int **host_type2rhor, int **host_type2z2r, - int *host_type2frho, double ***host_rhor_spline, - double ***host_z2r_spline, double ***host_frho_spline, - double** host_cutsq, double rdr, double rdrho, double rhomax, - int nrhor, int nrho, int nz2r, int nfrho, int nr, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, int &gpu_mode, - FILE *screen, int &fp_size); +int eam_gpu_init(const int ntypes, double host_cutforcesq, int **host_type2rhor, + int **host_type2z2r, int *host_type2frho, double ***host_rhor_spline, + double ***host_z2r_spline, double ***host_frho_spline, double **host_cutsq, + double rdr, double rdrho, double rhomax, int nrhor, int nrho, int nz2r, int nfrho, + int nr, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + int &fp_size); void eam_gpu_clear(); -int** eam_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, int &inum, void **fp_ptr); -void eam_gpu_compute(const int ago, const int inum_full, const int nlocal, - const int nall,double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, void **fp_ptr); -void eam_gpu_compute_force(int *ilist, const bool eflag, const bool vflag, - const bool eatom, const bool vatom); +int **eam_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, int &inum, void **fp_ptr); +void eam_gpu_compute(const int ago, const int inum_full, const int nlocal, const int nall, + double **host_x, int *host_type, int *ilist, int *numj, int **firstneigh, + const bool eflag, const bool vflag, const bool eatom, const bool vatom, + int &host_start, const double cpu_time, bool &success, void **fp_ptr); +void eam_gpu_compute_force(int *ilist, const bool eflag, const bool vflag, const bool eatom, + const bool vatom); double eam_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -95,7 +88,7 @@ double PairEAMGPU::memory_usage() void PairEAMGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); // compute density on each atom on GPU @@ -106,7 +99,7 @@ void PairEAMGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -115,27 +108,24 @@ void PairEAMGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = eam_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, inum_dev, &fp_pinned); - } else { // gpu_mode == GPU_FORCE + firstneigh = + eam_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success, inum_dev, &fp_pinned); + } else { // gpu_mode == GPU_FORCE inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - eam_gpu_compute(neighbor->ago, inum, nlocal, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, &fp_pinned); + eam_gpu_compute(neighbor->ago, inum, nlocal, nall, atom->x, atom->type, ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, + &fp_pinned); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); // communicate derivative of embedding function @@ -165,10 +155,9 @@ void PairEAMGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -176,23 +165,17 @@ void PairEAMGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int fp_size; int mnf = 5e-2 * neighbor->oneatom; - int success = eam_gpu_init(atom->ntypes+1, cutforcesq, type2rhor, type2z2r, - type2frho, rhor_spline, z2r_spline, frho_spline, - cutsq, rdr, rdrho, rhomax, nrhor, nrho, nz2r, nfrho, nr, - atom->nlocal, atom->nlocal+atom->nghost, mnf, + int success = eam_gpu_init(atom->ntypes + 1, cutforcesq, type2rhor, type2z2r, type2frho, + rhor_spline, z2r_spline, frho_spline, cutsq, rdr, rdrho, rhomax, nrhor, + nrho, nz2r, nfrho, nr, atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen, fp_size); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); if (fp_size == sizeof(double)) fp_single = false; else @@ -203,64 +186,63 @@ void PairEAMGPU::init_style() /* ---------------------------------------------------------------------- */ -double PairEAMGPU::single(int i, int j, int itype, int jtype, - double rsq, double /* factor_coul */, +double PairEAMGPU::single(int i, int j, int itype, int jtype, double rsq, double /* factor_coul */, double /* factor_lj */, double &fforce) { int m; - double r,p,rhoip,rhojp,z2,z2p,recip,phi,phip,psip; + double r, p, rhoip, rhojp, z2, z2p, recip, phi, phip, psip; double *coeff; r = sqrt(rsq); - p = r*rdr + 1.0; - m = static_cast (p); - m = MIN(m,nr-1); + p = r * rdr + 1.0; + m = static_cast(p); + m = MIN(m, nr - 1); p -= m; - p = MIN(p,1.0); + p = MIN(p, 1.0); coeff = rhor_spline[type2rhor[itype][jtype]][m]; - rhoip = (coeff[0]*p + coeff[1])*p + coeff[2]; + rhoip = (coeff[0] * p + coeff[1]) * p + coeff[2]; coeff = rhor_spline[type2rhor[jtype][itype]][m]; - rhojp = (coeff[0]*p + coeff[1])*p + coeff[2]; + rhojp = (coeff[0] * p + coeff[1]) * p + coeff[2]; coeff = z2r_spline[type2z2r[itype][jtype]][m]; - z2p = (coeff[0]*p + coeff[1])*p + coeff[2]; - z2 = ((coeff[3]*p + coeff[4])*p + coeff[5])*p + coeff[6]; + z2p = (coeff[0] * p + coeff[1]) * p + coeff[2]; + z2 = ((coeff[3] * p + coeff[4]) * p + coeff[5]) * p + coeff[6]; - double fp_i,fp_j; + double fp_i, fp_j; if (fp_single == false) { - fp_i = ((double*)fp_pinned)[i]; - fp_j = ((double*)fp_pinned)[j]; + fp_i = ((double *) fp_pinned)[i]; + fp_j = ((double *) fp_pinned)[j]; } else { - fp_i = ((float*)fp_pinned)[i]; - fp_j = ((float*)fp_pinned)[j]; + fp_i = ((float *) fp_pinned)[i]; + fp_j = ((float *) fp_pinned)[j]; } - recip = 1.0/r; - phi = z2*recip; - phip = z2p*recip - phi*recip; - psip = fp_i*rhojp + fp_j*rhoip + phip; - fforce = -psip*recip; + recip = 1.0 / r; + phi = z2 * recip; + phip = z2p * recip - phi * recip; + psip = fp_i * rhojp + fp_j * rhoip + phip; + fforce = -psip * recip; return phi; } /* ---------------------------------------------------------------------- */ -int PairEAMGPU::pack_forward_comm(int n, int *list, double *buf, - int /* pbc_flag */, int * /* pbc */) +int PairEAMGPU::pack_forward_comm(int n, int *list, double *buf, int /* pbc_flag */, + int * /* pbc */) { - int i,j,m; + int i, j, m; m = 0; if (fp_single) { - float *fp_ptr = (float *)fp_pinned; + float *fp_ptr = (float *) fp_pinned; for (i = 0; i < n; i++) { j = list[i]; buf[m++] = static_cast(fp_ptr[j]); } } else { - double *fp_ptr = (double *)fp_pinned; + double *fp_ptr = (double *) fp_pinned; for (i = 0; i < n; i++) { j = list[i]; buf[m++] = fp_ptr[j]; @@ -274,15 +256,15 @@ int PairEAMGPU::pack_forward_comm(int n, int *list, double *buf, void PairEAMGPU::unpack_forward_comm(int n, int first, double *buf) { - int i,m,last; + int i, m, last; m = 0; last = first + n; if (fp_single) { - float *fp_ptr = (float *)fp_pinned; + float *fp_ptr = (float *) fp_pinned; for (i = first; i < last; i++) fp_ptr[i] = buf[m++]; } else { - double *fp_ptr = (double *)fp_pinned; + double *fp_ptr = (double *) fp_pinned; for (i = first; i < last; i++) fp_ptr[i] = buf[m++]; } } diff --git a/src/GPU/pair_gauss_gpu.cpp b/src/GPU/pair_gauss_gpu.cpp index e06050b2fd..3843616445 100644 --- a/src/GPU/pair_gauss_gpu.cpp +++ b/src/GPU/pair_gauss_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,25 +32,20 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int gauss_gpu_init(const int ntypes, double **cutsq, double **host_a, - double **b, double **offset, double *special_lj, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen); -void gauss_gpu_reinit(const int ntypes, double **cutsq, double **host_a, - double **b, double **offset); +int gauss_gpu_init(const int ntypes, double **cutsq, double **host_a, double **b, double **offset, + double *special_lj, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); +void gauss_gpu_reinit(const int ntypes, double **cutsq, double **host_a, double **b, + double **offset); void gauss_gpu_clear(); -int ** gauss_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void gauss_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **gauss_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void gauss_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double gauss_gpu_bytes(); @@ -79,7 +72,7 @@ PairGaussGPU::~PairGaussGPU() void PairGaussGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -87,7 +80,7 @@ void PairGaussGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -96,28 +89,24 @@ void PairGaussGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = gauss_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + gauss_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - gauss_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + gauss_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -148,21 +136,15 @@ void PairGaussGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = gauss_gpu_init(atom->ntypes+1, cutsq, a, b, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + gauss_gpu_init(atom->ntypes + 1, cutsq, a, b, offset, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -171,7 +153,7 @@ void PairGaussGPU::reinit() { Pair::reinit(); - gauss_gpu_reinit(atom->ntypes+1, cutsq, a, b, offset); + gauss_gpu_reinit(atom->ntypes + 1, cutsq, a, b, offset); } /* ---------------------------------------------------------------------- */ @@ -184,11 +166,12 @@ double PairGaussGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairGaussGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,forcelj,factor_lj; +void PairGaussGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, forcelj, factor_lj; int *jlist; double **x = atom->x; @@ -215,26 +198,24 @@ void PairGaussGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - forcelj = - 2.0*a[itype][jtype]*b[itype][jtype] * rsq * - exp(-b[itype][jtype]*rsq); - fpair = factor_lj*forcelj*r2inv; + r2inv = 1.0 / rsq; + forcelj = -2.0 * a[itype][jtype] * b[itype][jtype] * rsq * exp(-b[itype][jtype] * rsq); + fpair = factor_lj * forcelj * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = -(a[itype][jtype]*exp(-b[itype][jtype]*rsq) - - offset[itype][jtype]); + evdwl = -(a[itype][jtype] * exp(-b[itype][jtype] * rsq) - offset[itype][jtype]); evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_gayberne_gpu.cpp b/src/GPU/pair_gayberne_gpu.cpp index 1a2c67337f..967817bc36 100644 --- a/src/GPU/pair_gayberne_gpu.cpp +++ b/src/GPU/pair_gayberne_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -27,7 +26,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -37,35 +35,29 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int gb_gpu_init(const int ntypes, const double gamma, const double upsilon, - const double mu, double **shape, double **well, double **cutsq, - double **sigma, double **epsilon, double *host_lshape, - int **form, double **host_lj1, double **host_lj2, - double **host_lj3, double **host_lj4, double **offset, - double *special_lj, const int nlocal, const int nall, - const int max_nbors, const int maxspecial, +int gb_gpu_init(const int ntypes, const double gamma, const double upsilon, const double mu, + double **shape, double **well, double **cutsq, double **sigma, double **epsilon, + double *host_lshape, int **form, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void gb_gpu_clear(); -int ** gb_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double **host_quat); -int * gb_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double **host_quat); +int **gb_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double **host_quat); +int *gb_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success, double **host_quat); double gb_gpu_bytes(); -enum{SPHERE_SPHERE,SPHERE_ELLIPSE,ELLIPSE_SPHERE,ELLIPSE_ELLIPSE}; +enum { SPHERE_SPHERE, SPHERE_ELLIPSE, ELLIPSE_SPHERE, ELLIPSE_ELLIPSE }; /* ---------------------------------------------------------------------- */ -PairGayBerneGPU::PairGayBerneGPU(LAMMPS *lmp) : PairGayBerne(lmp), - gpu_mode(GPU_FORCE) +PairGayBerneGPU::PairGayBerneGPU(LAMMPS *lmp) : PairGayBerne(lmp), gpu_mode(GPU_FORCE) { quat_nmax = 0; reinitflag = 0; @@ -89,7 +81,7 @@ PairGayBerneGPU::~PairGayBerneGPU() void PairGayBerneGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -103,7 +95,7 @@ void PairGayBerneGPU::compute(int eflag, int vflag) } AtomVecEllipsoid::Bonus *bonus = avec->bonus; int *ellipsoid = atom->ellipsoid; - for (int i=0; i -1) { quat[i][0] = bonus[qi].quat[0]; @@ -114,7 +106,7 @@ void PairGayBerneGPU::compute(int eflag, int vflag) } if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -123,26 +115,22 @@ void PairGayBerneGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = gb_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, quat); + firstneigh = + gb_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success, quat); } else { inum = list->inum; numneigh = list->numneigh; firstneigh = list->firstneigh; - ilist = gb_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - list->ilist, numneigh, firstneigh, eflag, vflag, - eflag_atom, vflag_atom, host_start, - cpu_time, success, quat); + ilist = gb_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, list->ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, + success, quat); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); if (host_start < inum) { cpu_time = platform::walltime(); @@ -158,25 +146,22 @@ void PairGayBerneGPU::compute(int eflag, int vflag) void PairGayBerneGPU::init_style() { avec = (AtomVecEllipsoid *) atom->style_match("ellipsoid"); - if (!avec) - error->all(FLERR,"Pair gayberne/gpu requires atom style ellipsoid"); - if (!atom->ellipsoid_flag) - error->all(FLERR,"Pair gayberne/gpu requires atom style ellipsoid"); + if (!avec) error->all(FLERR, "Pair gayberne/gpu requires atom style ellipsoid"); + if (!atom->ellipsoid_flag) error->all(FLERR, "Pair gayberne/gpu requires atom style ellipsoid"); // per-type shape precalculations // require that atom shapes are identical within each type // if shape = 0 for point particle, set shape = 1 as required by Gay-Berne for (int i = 1; i <= atom->ntypes; i++) { - if (!atom->shape_consistency(i,shape1[i][0],shape1[i][1],shape1[i][2])) - error->all(FLERR,"Pair gayberne/gpu requires atoms with same type have same shape"); - if (shape1[i][0] == 0.0) - shape1[i][0] = shape1[i][1] = shape1[i][2] = 1.0; - shape2[i][0] = shape1[i][0]*shape1[i][0]; - shape2[i][1] = shape1[i][1]*shape1[i][1]; - shape2[i][2] = shape1[i][2]*shape1[i][2]; - lshape[i] = (shape1[i][0]*shape1[i][1]+shape1[i][2]*shape1[i][2]) * - sqrt(shape1[i][0]*shape1[i][1]); + if (!atom->shape_consistency(i, shape1[i][0], shape1[i][1], shape1[i][2])) + error->all(FLERR, "Pair gayberne/gpu requires atoms with same type have same shape"); + if (shape1[i][0] == 0.0) shape1[i][0] = shape1[i][1] = shape1[i][2] = 1.0; + shape2[i][0] = shape1[i][0] * shape1[i][0]; + shape2[i][1] = shape1[i][1] * shape1[i][1]; + shape2[i][2] = shape1[i][2] * shape1[i][2]; + lshape[i] = (shape1[i][0] * shape1[i][1] + shape1[i][2] * shape1[i][2]) * + sqrt(shape1[i][0] * shape1[i][1]); } // Repeat cutsq calculation because done after call to init_style @@ -185,10 +170,9 @@ void PairGayBerneGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -197,22 +181,16 @@ void PairGayBerneGPU::init_style() double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = gb_gpu_init(atom->ntypes+1, gamma, upsilon, mu, - shape2, well, cutsq, sigma, epsilon, lshape, form, - lj1, lj2, lj3, lj4, offset, force->special_lj, - atom->nlocal, atom->nlocal+atom->nghost, mnf, - maxspecial, cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + gb_gpu_init(atom->ntypes + 1, gamma, upsilon, mu, shape2, well, cutsq, sigma, epsilon, lshape, + form, lj1, lj2, lj3, lj4, offset, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); quat_nmax = static_cast(1.1 * (atom->nlocal + atom->nghost)); memory->grow(quat, quat_nmax, 4, "pair:quat"); } @@ -222,21 +200,20 @@ void PairGayBerneGPU::init_style() double PairGayBerneGPU::memory_usage() { double bytes = Pair::memory_usage(); - return bytes + memory->usage(quat,quat_nmax)+gb_gpu_bytes(); + return bytes + memory->usage(quat, quat_nmax) + gb_gpu_bytes(); } /* ---------------------------------------------------------------------- */ -void PairGayBerneGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairGayBerneGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double evdwl,one_eng,rsq,r2inv,r6inv,forcelj,factor_lj; - double fforce[3],ttor[3],rtor[3],r12[3]; - double a1[3][3],b1[3][3],g1[3][3],a2[3][3],b2[3][3],g2[3][3],temp[3][3]; + int i, j, ii, jj, jnum, itype, jtype; + double evdwl, one_eng, rsq, r2inv, r6inv, forcelj, factor_lj; + double fforce[3], ttor[3], rtor[3], r12[3]; + double a1[3][3], b1[3][3], g1[3][3], a2[3][3], b2[3][3], g2[3][3], temp[3][3]; int *jlist; - double *iquat,*jquat; + double *iquat, *jquat; AtomVecEllipsoid::Bonus *bonus = avec->bonus; int *ellipsoid = atom->ellipsoid; @@ -254,11 +231,11 @@ void PairGayBerneGPU::cpu_compute(int start, int inum, int eflag, if (form[itype][itype] == ELLIPSE_ELLIPSE) { iquat = bonus[ellipsoid[i]].quat; - MathExtra::quat_to_mat_trans(iquat,a1); - MathExtra::diag_times3(well[itype],a1,temp); - MathExtra::transpose_times3(a1,temp,b1); - MathExtra::diag_times3(shape2[itype],a1,temp); - MathExtra::transpose_times3(a1,temp,g1); + MathExtra::quat_to_mat_trans(iquat, a1); + MathExtra::diag_times3(well[itype], a1, temp); + MathExtra::transpose_times3(a1, temp, b1); + MathExtra::diag_times3(shape2[itype], a1, temp); + MathExtra::transpose_times3(a1, temp, g1); } jlist = firstneigh[i]; @@ -271,10 +248,10 @@ void PairGayBerneGPU::cpu_compute(int start, int inum, int eflag, // r12 = center to center vector - r12[0] = x[j][0]-x[i][0]; - r12[1] = x[j][1]-x[i][1]; - r12[2] = x[j][2]-x[i][2]; - rsq = MathExtra::dot3(r12,r12); + r12[0] = x[j][0] - x[i][0]; + r12[1] = x[j][1] - x[i][1]; + r12[2] = x[j][2] - x[i][2]; + rsq = MathExtra::dot3(r12, r12); jtype = type[j]; // compute if less than cutoff @@ -282,47 +259,46 @@ void PairGayBerneGPU::cpu_compute(int start, int inum, int eflag, if (rsq < cutsq[itype][jtype]) { switch (form[itype][jtype]) { - case SPHERE_SPHERE: - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - forcelj *= -r2inv; - if (eflag) one_eng = - r6inv*(r6inv*lj3[itype][jtype]-lj4[itype][jtype]) - - offset[itype][jtype]; - fforce[0] = r12[0]*forcelj; - fforce[1] = r12[1]*forcelj; - fforce[2] = r12[2]*forcelj; - ttor[0] = ttor[1] = ttor[2] = 0.0; - rtor[0] = rtor[1] = rtor[2] = 0.0; - break; + case SPHERE_SPHERE: + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + forcelj *= -r2inv; + if (eflag) + one_eng = + r6inv * (r6inv * lj3[itype][jtype] - lj4[itype][jtype]) - offset[itype][jtype]; + fforce[0] = r12[0] * forcelj; + fforce[1] = r12[1] * forcelj; + fforce[2] = r12[2] * forcelj; + ttor[0] = ttor[1] = ttor[2] = 0.0; + rtor[0] = rtor[1] = rtor[2] = 0.0; + break; - case SPHERE_ELLIPSE: - jquat = bonus[ellipsoid[j]].quat; - MathExtra::quat_to_mat_trans(jquat,a2); - MathExtra::diag_times3(well[jtype],a2,temp); - MathExtra::transpose_times3(a2,temp,b2); - MathExtra::diag_times3(shape2[jtype],a2,temp); - MathExtra::transpose_times3(a2,temp,g2); - one_eng = gayberne_lj(j,i,a2,b2,g2,r12,rsq,fforce,rtor); - ttor[0] = ttor[1] = ttor[2] = 0.0; - break; + case SPHERE_ELLIPSE: + jquat = bonus[ellipsoid[j]].quat; + MathExtra::quat_to_mat_trans(jquat, a2); + MathExtra::diag_times3(well[jtype], a2, temp); + MathExtra::transpose_times3(a2, temp, b2); + MathExtra::diag_times3(shape2[jtype], a2, temp); + MathExtra::transpose_times3(a2, temp, g2); + one_eng = gayberne_lj(j, i, a2, b2, g2, r12, rsq, fforce, rtor); + ttor[0] = ttor[1] = ttor[2] = 0.0; + break; - case ELLIPSE_SPHERE: - one_eng = gayberne_lj(i,j,a1,b1,g1,r12,rsq,fforce,ttor); - rtor[0] = rtor[1] = rtor[2] = 0.0; - break; + case ELLIPSE_SPHERE: + one_eng = gayberne_lj(i, j, a1, b1, g1, r12, rsq, fforce, ttor); + rtor[0] = rtor[1] = rtor[2] = 0.0; + break; - default: - jquat = bonus[ellipsoid[j]].quat; - MathExtra::quat_to_mat_trans(jquat,a2); - MathExtra::diag_times3(well[jtype],a2,temp); - MathExtra::transpose_times3(a2,temp,b2); - MathExtra::diag_times3(shape2[jtype],a2,temp); - MathExtra::transpose_times3(a2,temp,g2); - one_eng = gayberne_analytic(i,j,a1,a2,b1,b2,g1,g2,r12,rsq, - fforce,ttor,rtor); - break; + default: + jquat = bonus[ellipsoid[j]].quat; + MathExtra::quat_to_mat_trans(jquat, a2); + MathExtra::diag_times3(well[jtype], a2, temp); + MathExtra::transpose_times3(a2, temp, b2); + MathExtra::diag_times3(shape2[jtype], a2, temp); + MathExtra::transpose_times3(a2, temp, g2); + one_eng = gayberne_analytic(i, j, a1, a2, b1, b2, g1, g2, r12, rsq, fforce, ttor, rtor); + break; } fforce[0] *= factor_lj; @@ -339,10 +315,11 @@ void PairGayBerneGPU::cpu_compute(int start, int inum, int eflag, tor[i][1] += ttor[1]; tor[i][2] += ttor[2]; - if (eflag) evdwl = factor_lj*one_eng; + if (eflag) evdwl = factor_lj * one_eng; - if (evflag) ev_tally_xyz_full(i,evdwl,0.0,fforce[0],fforce[1],fforce[2], - -r12[0],-r12[1],-r12[2]); + if (evflag) + ev_tally_xyz_full(i, evdwl, 0.0, fforce[0], fforce[1], fforce[2], -r12[0], -r12[1], + -r12[2]); } } } diff --git a/src/GPU/pair_lj96_cut_gpu.cpp b/src/GPU/pair_lj96_cut_gpu.cpp index ab3cb15b2a..c0dc11f403 100644 --- a/src/GPU/pair_lj96_cut_gpu.cpp +++ b/src/GPU/pair_lj96_cut_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,23 +32,19 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int lj96_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, +int lj96_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void lj96_gpu_clear(); -int ** lj96_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void lj96_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **lj96_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void lj96_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double lj96_gpu_bytes(); @@ -78,7 +72,7 @@ PairLJ96CutGPU::~PairLJ96CutGPU() void PairLJ96CutGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -86,7 +80,7 @@ void PairLJ96CutGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -95,28 +89,24 @@ void PairLJ96CutGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = lj96_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success); + firstneigh = + lj96_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - lj96_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + lj96_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -149,21 +137,15 @@ void PairLJ96CutGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = lj96_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = lj96_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -176,13 +158,12 @@ double PairLJ96CutGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJ96CutGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairLJ96CutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r3inv,r6inv,forcelj,factor_lj; + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r3inv, r6inv, forcelj, factor_lj; int *jlist; double **x = atom->x; @@ -209,27 +190,26 @@ void PairLJ96CutGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; r3inv = sqrt(r6inv); - forcelj = r6inv * (lj1[itype][jtype]*r3inv - lj2[itype][jtype]); - fpair = factor_lj*forcelj*r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r3inv - lj2[itype][jtype]); + fpair = factor_lj * forcelj * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = r6inv*(lj3[itype][jtype]*r3inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r3inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_charmm_coul_charmm_gpu.cpp b/src/GPU/pair_lj_charmm_coul_charmm_gpu.cpp index 6b51933128..7f15ad1c48 100644 --- a/src/GPU/pair_lj_charmm_coul_charmm_gpu.cpp +++ b/src/GPU/pair_lj_charmm_coul_charmm_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -33,38 +31,30 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int crm_gpu_init(const int ntypes, double cut_bothsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double host_cut_ljsq, double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, - const double cut_lj_innersq, const double cut_coul_innersq, - const double denom_lj, const double denom_coul, - double **epsilon, double **sigma, - const bool mix_arithmetic); +int crm_gpu_init(const int ntypes, double cut_bothsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double *special_lj, const int nlocal, + const int nall, const int max_nbors, const int maxspecial, const double cell_size, + int &gpu_mode, FILE *screen, double host_cut_ljsq, double host_cut_coulsq, + double *host_special_coul, const double qqrd2e, const double cut_lj_innersq, + const double cut_coul_innersq, const double denom_lj, const double denom_coul, + double **epsilon, double **sigma, const bool mix_arithmetic); void crm_gpu_clear(); -int ** crm_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, - const bool vatom, int &host_start, int **ilist, - int **jnum, const double cpu_time, bool &success, - double *host_q, double *boxlo, double *prd); -void crm_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **crm_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void crm_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success, double *host_q, const int nlocal, double *boxlo, double *prd); double crm_gpu_bytes(); /* ---------------------------------------------------------------------- */ PairLJCharmmCoulCharmmGPU::PairLJCharmmCoulCharmmGPU(LAMMPS *lmp) : - PairLJCharmmCoulCharmm(lmp), gpu_mode(GPU_FORCE) + PairLJCharmmCoulCharmm(lmp), gpu_mode(GPU_FORCE) { reinitflag = 0; cpu_time = 0.0; @@ -84,8 +74,10 @@ PairLJCharmmCoulCharmmGPU::~PairLJCharmmCoulCharmmGPU() void PairLJCharmmCoulCharmmGPU::compute(int eflag, int vflag) { - if (eflag || vflag) ev_setup(eflag,vflag); - else evflag = vflag_fdotr = 0; + if (eflag || vflag) + ev_setup(eflag, vflag); + else + evflag = vflag_fdotr = 0; int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -94,27 +86,22 @@ void PairLJCharmmCoulCharmmGPU::compute(int eflag, int vflag) int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { inum = atom->nlocal; - firstneigh = crm_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, domain->sublo, domain->subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = crm_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, domain->sublo, + domain->subhi, atom->tag, atom->nspecial, atom->special, eflag, + vflag, eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - crm_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + crm_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { - if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) - init_one(i,j); + if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) init_one(i, j); } } @@ -143,46 +129,37 @@ void PairLJCharmmCoulCharmmGPU::init_style() cut_coul_innersq = cut_coul_inner * cut_coul_inner; cut_ljsq = cut_lj * cut_lj; cut_coulsq = cut_coul * cut_coul; - cut_bothsq = MAX(cut_ljsq,cut_coulsq); + cut_bothsq = MAX(cut_ljsq, cut_coulsq); - denom_lj = (cut_ljsq-cut_lj_innersq) * (cut_ljsq-cut_lj_innersq) * - (cut_ljsq-cut_lj_innersq); + denom_lj = + (cut_ljsq - cut_lj_innersq) * (cut_ljsq - cut_lj_innersq) * (cut_ljsq - cut_lj_innersq); denom_lj = 1.0 / denom_lj; - denom_coul = (cut_coulsq-cut_coul_innersq) * (cut_coulsq-cut_coul_innersq) * - (cut_coulsq-cut_coul_innersq); + denom_coul = (cut_coulsq - cut_coul_innersq) * (cut_coulsq - cut_coul_innersq) * + (cut_coulsq - cut_coul_innersq); denom_coul = 1.0 / denom_coul; double cell_size = sqrt(cut_bothsq) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; bool arithmetic = true; for (int i = 1; i < atom->ntypes + 1; i++) for (int j = i + 1; j < atom->ntypes + 1; j++) { - if (epsilon[i][j] != sqrt(epsilon[i][i] * epsilon[j][j])) - arithmetic = false; - if (sigma[i][j] != 0.5 * (sigma[i][i] + sigma[j][j])) - arithmetic = false; + if (epsilon[i][j] != sqrt(epsilon[i][i] * epsilon[j][j])) arithmetic = false; + if (sigma[i][j] != 0.5 * (sigma[i][i] + sigma[j][j])) arithmetic = false; } int mnf = 5e-2 * neighbor->oneatom; - int success = crm_gpu_init(atom->ntypes+1, cut_bothsq, lj1, lj2, lj3, lj4, - force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, force->qqrd2e, - cut_lj_innersq,cut_coul_innersq,denom_lj, - denom_coul,epsilon,sigma,arithmetic); - GPU_EXTRA::check_flag(success,error,world); + int success = + crm_gpu_init(atom->ntypes + 1, cut_bothsq, lj1, lj2, lj3, lj4, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, cut_lj_innersq, + cut_coul_innersq, denom_lj, denom_coul, epsilon, sigma, arithmetic); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -195,14 +172,13 @@ double PairLJCharmmCoulCharmmGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCharmmCoulCharmmGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) +void PairLJCharmmCoulCharmmGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, + int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - double philj,switch1,switch2; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + double philj, switch1, switch2; int *jlist; evdwl = ecoul = 0.0; @@ -236,64 +212,66 @@ void PairLJCharmmCoulCharmmGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cut_bothsq) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { - forcecoul = qqrd2e * qtmp*q[j]*sqrt(r2inv); + forcecoul = qqrd2e * qtmp * q[j] * sqrt(r2inv); if (rsq > cut_coul_innersq) { - switch1 = (cut_coulsq-rsq) * (cut_coulsq-rsq) * - (cut_coulsq + 2.0*rsq - 3.0*cut_coul_innersq) * denom_coul; + switch1 = (cut_coulsq - rsq) * (cut_coulsq - rsq) * + (cut_coulsq + 2.0 * rsq - 3.0 * cut_coul_innersq) * denom_coul; forcecoul *= switch1; } - } else forcecoul = 0.0; + } else + forcecoul = 0.0; if (rsq < cut_ljsq) { - r6inv = r2inv*r2inv*r2inv; + r6inv = r2inv * r2inv * r2inv; jtype = type[j]; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (rsq > cut_lj_innersq) { - switch1 = (cut_ljsq-rsq) * (cut_ljsq-rsq) * - (cut_ljsq + 2.0*rsq - 3.0*cut_lj_innersq) * denom_lj; - switch2 = 12.0*rsq * (cut_ljsq-rsq) * - (rsq-cut_lj_innersq) * denom_lj; - philj = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]); - forcelj = forcelj*switch1 + philj*switch2; + switch1 = (cut_ljsq - rsq) * (cut_ljsq - rsq) * + (cut_ljsq + 2.0 * rsq - 3.0 * cut_lj_innersq) * denom_lj; + switch2 = 12.0 * rsq * (cut_ljsq - rsq) * (rsq - cut_lj_innersq) * denom_lj; + philj = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); + forcelj = forcelj * switch1 + philj * switch2; } - } else forcelj = 0.0; + } else + forcelj = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forcelj) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { - ecoul = qqrd2e * qtmp*q[j]*sqrt(r2inv); + ecoul = qqrd2e * qtmp * q[j] * sqrt(r2inv); if (rsq > cut_coul_innersq) { - switch1 = (cut_coulsq-rsq) * (cut_coulsq-rsq) * - (cut_coulsq + 2.0*rsq - 3.0*cut_coul_innersq) * - denom_coul; + switch1 = (cut_coulsq - rsq) * (cut_coulsq - rsq) * + (cut_coulsq + 2.0 * rsq - 3.0 * cut_coul_innersq) * denom_coul; ecoul *= switch1; } ecoul *= factor_coul; - } else ecoul = 0.0; + } else + ecoul = 0.0; if (rsq < cut_ljsq) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]); + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); if (rsq > cut_lj_innersq) { - switch1 = (cut_ljsq-rsq) * (cut_ljsq-rsq) * - (cut_ljsq + 2.0*rsq - 3.0*cut_lj_innersq) * denom_lj; + switch1 = (cut_ljsq - rsq) * (cut_ljsq - rsq) * + (cut_ljsq + 2.0 * rsq - 3.0 * cut_lj_innersq) * denom_lj; evdwl *= switch1; } evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_charmm_coul_long_gpu.cpp b/src/GPU/pair_lj_charmm_coul_long_gpu.cpp index 861ef0c36d..9f0cac9f98 100644 --- a/src/GPU/pair_lj_charmm_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_charmm_coul_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,55 +24,48 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int crml_gpu_init(const int ntypes, double cut_bothsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double host_cut_ljsq, double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, - const double g_ewald, const double cut_lj_innersq, - const double denom_lj, double **epsilon, double **sigma, - const bool mix_arithmetic); +int crml_gpu_init(const int ntypes, double cut_bothsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double host_cut_ljsq, + double host_cut_coulsq, double *host_special_coul, const double qqrd2e, + const double g_ewald, const double cut_lj_innersq, const double denom_lj, + double **epsilon, double **sigma, const bool mix_arithmetic); void crml_gpu_clear(); -int ** crml_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, double *host_q, - double *boxlo, double *prd); -void crml_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **crml_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void crml_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double crml_gpu_bytes(); /* ---------------------------------------------------------------------- */ PairLJCharmmCoulLongGPU::PairLJCharmmCoulLongGPU(LAMMPS *lmp) : - PairLJCharmmCoulLong(lmp), gpu_mode(GPU_FORCE) + PairLJCharmmCoulLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -95,7 +87,7 @@ PairLJCharmmCoulLongGPU::~PairLJCharmmCoulLongGPU() void PairLJCharmmCoulLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -103,7 +95,7 @@ void PairLJCharmmCoulLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -112,30 +104,25 @@ void PairLJCharmmCoulLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = crml_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = crml_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - crml_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + crml_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style lj/charmm/coul/long/gpu requires atom attribute q"); + error->all(FLERR, "Pair style lj/charmm/coul/long/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { - if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) - init_one(i,j); + if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) init_one(i, j); } } cut_lj_innersq = cut_lj_inner * cut_lj_inner; cut_ljsq = cut_lj * cut_lj; cut_coulsq = cut_coul * cut_coul; - cut_bothsq = MAX(cut_ljsq,cut_coulsq); + cut_bothsq = MAX(cut_ljsq, cut_coulsq); - denom_lj = (cut_ljsq-cut_lj_innersq) * (cut_ljsq-cut_lj_innersq) * - (cut_ljsq-cut_lj_innersq); + denom_lj = + (cut_ljsq - cut_lj_innersq) * (cut_ljsq - cut_lj_innersq) * (cut_ljsq - cut_lj_innersq); double cell_size = sqrt(cut_bothsq) + neighbor->skin; // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; bool arithmetic = true; for (int i = 1; i < atom->ntypes + 1; i++) for (int j = i + 1; j < atom->ntypes + 1; j++) { - if (epsilon[i][j] != sqrt(epsilon[i][i] * epsilon[j][j])) - arithmetic = false; - if (sigma[i][j] != 0.5 * (sigma[i][i] + sigma[j][j])) - arithmetic = false; + if (epsilon[i][j] != sqrt(epsilon[i][i] * epsilon[j][j])) arithmetic = false; + if (sigma[i][j] != 0.5 * (sigma[i][i] + sigma[j][j])) arithmetic = false; } int mnf = 5e-2 * neighbor->oneatom; - int success = crml_gpu_init(atom->ntypes+1, cut_bothsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, force->qqrd2e, - g_ewald, cut_lj_innersq,denom_lj,epsilon,sigma, - arithmetic); - GPU_EXTRA::check_flag(success,error,world); + int success = + crml_gpu_init(atom->ntypes + 1, cut_bothsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, g_ewald, + cut_lj_innersq, denom_lj, epsilon, sigma, arithmetic); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -222,16 +198,15 @@ double PairLJCharmmCoulLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCharmmCoulLongGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) +void PairLJCharmmCoulLongGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, + int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype,itable; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double fraction,table; - double r,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - double grij,expm2,prefactor,t,erfc; - double philj,switch1,switch2; + int i, j, ii, jj, jnum, itype, jtype, itable; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double fraction, table; + double r, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + double grij, expm2, prefactor, t, erfc; + double philj, switch1, switch2; int *jlist; double rsq; @@ -266,80 +241,83 @@ void PairLJCharmmCoulLongGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cut_bothsq) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; } else { union_int_float_t rsq_lookup; rsq_lookup.f = rsq; itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = qtmp*q[j] * table; + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = qtmp * q[j] * table; if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = qtmp*q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = qtmp * q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; } } - } else forcecoul = 0.0; + } else + forcecoul = 0.0; if (rsq < cut_ljsq) { - r6inv = r2inv*r2inv*r2inv; + r6inv = r2inv * r2inv * r2inv; jtype = type[j]; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (rsq > cut_lj_innersq) { - switch1 = (cut_ljsq-rsq) * (cut_ljsq-rsq) * - (cut_ljsq + 2.0*rsq - 3.0*cut_lj_innersq) / denom_lj; - switch2 = 12.0*rsq * (cut_ljsq-rsq) * - (rsq-cut_lj_innersq) / denom_lj; - philj = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]); - forcelj = forcelj*switch1 + philj*switch2; + switch1 = (cut_ljsq - rsq) * (cut_ljsq - rsq) * + (cut_ljsq + 2.0 * rsq - 3.0 * cut_lj_innersq) / denom_lj; + switch2 = 12.0 * rsq * (cut_ljsq - rsq) * (rsq - cut_lj_innersq) / denom_lj; + philj = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); + forcelj = forcelj * switch1 + philj * switch2; } - } else forcelj = 0.0; + } else + forcelj = 0.0; - fpair = (forcecoul + factor_lj*forcelj) * r2inv; + fpair = (forcecoul + factor_lj * forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) - ecoul = prefactor*erfc; + ecoul = prefactor * erfc; else { - table = etable[itable] + fraction*detable[itable]; - ecoul = qtmp*q[j] * table; + table = etable[itable] + fraction * detable[itable]; + ecoul = qtmp * q[j] * table; } - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]); + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); if (rsq > cut_lj_innersq) { - switch1 = (cut_ljsq-rsq) * (cut_ljsq-rsq) * - (cut_ljsq + 2.0*rsq - 3.0*cut_lj_innersq) / denom_lj; + switch1 = (cut_ljsq - rsq) * (cut_ljsq - rsq) * + (cut_ljsq + 2.0 * rsq - 3.0 * cut_lj_innersq) / denom_lj; evdwl *= switch1; } evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_class2_coul_long_gpu.cpp b/src/GPU/pair_lj_class2_coul_long_gpu.cpp index d1258dde57..5efad208c0 100644 --- a/src/GPU/pair_lj_class2_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_class2_coul_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,53 +24,47 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int c2cl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, +int c2cl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double host_cut_coulsq, double *host_special_coul, const double qqrd2e, const double g_ewald); void c2cl_gpu_clear(); -int ** c2cl_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, double *host_q, - double *boxlo, double *prd); -void c2cl_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **c2cl_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void c2cl_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double c2cl_gpu_bytes(); /* ---------------------------------------------------------------------- */ PairLJClass2CoulLongGPU::PairLJClass2CoulLongGPU(LAMMPS *lmp) : - PairLJClass2CoulLong(lmp), gpu_mode(GPU_FORCE) + PairLJClass2CoulLong(lmp), gpu_mode(GPU_FORCE) { cpu_time = 0.0; reinitflag = 0; @@ -92,7 +85,7 @@ PairLJClass2CoulLongGPU::~PairLJClass2CoulLongGPU() void PairLJClass2CoulLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -100,7 +93,7 @@ void PairLJClass2CoulLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -109,30 +102,25 @@ void PairLJClass2CoulLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = c2cl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = c2cl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - c2cl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + c2cl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style lj/class2/coul/long/gpu requires atom attribute q"); + error->all(FLERR, "Pair style lj/class2/coul/long/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -154,10 +142,9 @@ void PairLJClass2CoulLongGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -169,30 +156,23 @@ void PairLJClass2CoulLongGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = c2cl_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, - force->special_coul, force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + int success = + c2cl_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, g_ewald); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -205,15 +185,14 @@ double PairLJClass2CoulLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJClass2CoulLongGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) +void PairLJClass2CoulLongGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, + int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r,rinv,r2inv,r3inv,r6inv,forcecoul,forcelj; - double grij,expm2,prefactor,t,erfc; - double factor_coul,factor_lj; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r, rinv, r2inv, r3inv, r6inv, forcecoul, forcelj; + double grij, expm2, prefactor, t, erfc; + double factor_coul, factor_lj; int *jlist; evdwl = ecoul = 0.0; @@ -247,49 +226,52 @@ void PairLJClass2CoulLongGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { r = sqrt(rsq); grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; - } else forcecoul = 0.0; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { rinv = sqrt(r2inv); - r3inv = r2inv*rinv; - r6inv = r3inv*r3inv; - forcelj = r6inv * (lj1[itype][jtype]*r3inv - lj2[itype][jtype]); - } else forcelj = 0.0; + r3inv = r2inv * rinv; + r6inv = r3inv * r3inv; + forcelj = r6inv * (lj1[itype][jtype] * r3inv - lj2[itype][jtype]); + } else + forcelj = 0.0; - fpair = (forcecoul + factor_lj*forcelj) * r2inv; + fpair = (forcecoul + factor_lj * forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { - ecoul = prefactor*erfc; - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + ecoul = prefactor * erfc; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r3inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r3inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_class2_gpu.cpp b/src/GPU/pair_lj_class2_gpu.cpp index 82edfa0809..73ad42f5a5 100644 --- a/src/GPU/pair_lj_class2_gpu.cpp +++ b/src/GPU/pair_lj_class2_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,23 +32,19 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int lj96_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, +int lj96_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void lj96_gpu_clear(); -int **lj96_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, +int **lj96_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, const double cpu_time, bool &success); -void lj96_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +void lj96_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double lj96_gpu_bytes(); @@ -78,7 +72,7 @@ PairLJClass2GPU::~PairLJClass2GPU() void PairLJClass2GPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -86,7 +80,7 @@ void PairLJClass2GPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -95,28 +89,24 @@ void PairLJClass2GPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = lj96_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success); + firstneigh = + lj96_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - lj96_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + lj96_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -147,21 +136,15 @@ void PairLJClass2GPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = lj96_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = lj96_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -174,13 +157,12 @@ double PairLJClass2GPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJClass2GPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairLJClass2GPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r3inv,r6inv,forcelj,factor_lj; + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r3inv, r6inv, forcelj, factor_lj; int *jlist; double **x = atom->x; @@ -207,27 +189,26 @@ void PairLJClass2GPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; r3inv = sqrt(r6inv); - forcelj = r6inv * (lj1[itype][jtype]*r3inv - lj2[itype][jtype]); - fpair = factor_lj*forcelj*r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r3inv - lj2[itype][jtype]); + fpair = factor_lj * forcelj * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = r6inv*(lj3[itype][jtype]*r3inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r3inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cubic_gpu.cpp b/src/GPU/pair_lj_cubic_gpu.cpp index 7ec121a6c6..1f8c5a251d 100644 --- a/src/GPU/pair_lj_cubic_gpu.cpp +++ b/src/GPU/pair_lj_cubic_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -37,32 +35,27 @@ using namespace PairLJCubicConstants; // External functions from cuda library for atom decomposition -int ljcb_gpu_init(const int ntypes, double **cutsq, double **cut_inner_sq, - double **cut_inner, double **sigma, double **epsilon, - double **host_lj1, double **host_lj2, double **host_lj3, - double **host_lj4, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen); +int ljcb_gpu_init(const int ntypes, double **cutsq, double **cut_inner_sq, double **cut_inner, + double **sigma, double **epsilon, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double *special_lj, const int nlocal, + const int nall, const int max_nbors, const int maxspecial, const double cell_size, + int &gpu_mode, FILE *screen); void ljcb_gpu_clear(); -int ** ljcb_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success); -void ljcb_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **ljcb_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void ljcb_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double ljcb_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairLJCubicGPU::PairLJCubicGPU(LAMMPS *lmp) : PairLJCubic(lmp), - gpu_mode(GPU_FORCE) +PairLJCubicGPU::PairLJCubicGPU(LAMMPS *lmp) : PairLJCubic(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; cpu_time = 0.0; @@ -84,7 +77,7 @@ PairLJCubicGPU::~PairLJCubicGPU() void PairLJCubicGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -92,7 +85,7 @@ void PairLJCubicGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -101,28 +94,24 @@ void PairLJCubicGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljcb_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + ljcb_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljcb_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + ljcb_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - mcut = init_one(i,j); + mcut = init_one(i, j); mcut *= mcut; - if (mcut > maxcut) - maxcut = mcut; + if (mcut > maxcut) maxcut = mcut; cutsq[i][j] = cutsq[j][i] = mcut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -153,22 +141,16 @@ void PairLJCubicGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljcb_gpu_init(atom->ntypes+1, cutsq, cut_inner_sq, - cut_inner, sigma, epsilon, lj1, lj2, - lj3, lj4, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + ljcb_gpu_init(atom->ntypes + 1, cutsq, cut_inner_sq, cut_inner, sigma, epsilon, lj1, lj2, lj3, + lj4, force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -181,13 +163,13 @@ double PairLJCubicGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCubicGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r6inv,forcelj,factor_lj; - double r,t,rmin; +void PairLJCubicGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r6inv, forcelj, factor_lj; + double r, t, rmin; int *jlist; double **x = atom->x; @@ -214,36 +196,35 @@ void PairLJCubicGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq <= cut_inner_sq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); } else { r = sqrt(rsq); - rmin = sigma[itype][jtype]*RT6TWO; - t = (r - cut_inner[itype][jtype])/rmin; - forcelj = epsilon[itype][jtype]*(-DPHIDS + A3*t*t/2.0)*r/rmin; + rmin = sigma[itype][jtype] * RT6TWO; + t = (r - cut_inner[itype][jtype]) / rmin; + forcelj = epsilon[itype][jtype] * (-DPHIDS + A3 * t * t / 2.0) * r / rmin; } - fpair = factor_lj*forcelj*r2inv; + fpair = factor_lj * forcelj * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq <= cut_inner_sq[itype][jtype]) - evdwl = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]); + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); else - evdwl = epsilon[itype][jtype]* - (PHIS + DPHIDS*t - A3*t*t*t/6.0); + evdwl = epsilon[itype][jtype] * (PHIS + DPHIDS * t - A3 * t * t * t / 6.0); evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_coul_cut_gpu.cpp b/src/GPU/pair_lj_cut_coul_cut_gpu.cpp index 62740c98b5..600afe2d5c 100644 --- a/src/GPU/pair_lj_cut_coul_cut_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_cut_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,29 +32,22 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljc_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double **host_cut_coulsq, - double *host_special_coul, const double qqrd2e); +int ljc_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double **host_cut_coulsq, double *host_special_coul, const double qqrd2e); void ljc_gpu_clear(); -int ** ljc_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void ljc_gpu_compute(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, const bool eatom, - const bool vatom, int &host_start, const double cpu_time, - bool &success, double *host_q, const int nlocal, - double *boxlo, double *prd); +int **ljc_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void ljc_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success, double *host_q, const int nlocal, double *boxlo, double *prd); double ljc_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -83,7 +74,7 @@ PairLJCutCoulCutGPU::~PairLJCutCoulCutGPU() void PairLJCutCoulCutGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -91,7 +82,7 @@ void PairLJCutCoulCutGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -100,30 +91,25 @@ void PairLJCutCoulCutGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljc_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = ljc_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljc_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + ljc_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style lj/cut/coul/cut/gpu requires atom attribute q"); - + if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/coul/cut/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -146,10 +130,9 @@ void PairLJCutCoulCutGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -157,22 +140,16 @@ void PairLJCutCoulCutGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljc_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, - force->special_coul, force->qqrd2e); - GPU_EXTRA::check_flag(success,error,world); + int success = + ljc_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -185,13 +162,12 @@ double PairLJCutCoulCutGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCutCoulCutGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairLJCutCoulCutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; int *jlist; evdwl = ecoul = 0.0; @@ -225,39 +201,42 @@ void PairLJCutCoulCutGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq[itype][jtype]) - forcecoul = qqrd2e * qtmp*q[j]*sqrt(r2inv); - else forcecoul = 0.0; + forcecoul = qqrd2e * qtmp * q[j] * sqrt(r2inv); + else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - } else forcelj = 0.0; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + } else + forcelj = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forcelj) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq[itype][jtype]) - ecoul = factor_coul * qqrd2e * qtmp*q[j]*sqrt(r2inv); - else ecoul = 0.0; + ecoul = factor_coul * qqrd2e * qtmp * q[j] * sqrt(r2inv); + else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_coul_debye_gpu.cpp b/src/GPU/pair_lj_cut_coul_debye_gpu.cpp index 24db5ac68c..819245ca0b 100644 --- a/src/GPU/pair_lj_cut_coul_debye_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_debye_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,36 +32,30 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljcd_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double **host_cut_coulsq, - double *host_special_coul, const double qqrd2e, +int ljcd_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double **host_cut_coulsq, double *host_special_coul, const double qqrd2e, const double kappa); void ljcd_gpu_clear(); -int ** ljcd_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void ljcd_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, const bool eatom, - const bool vatom, int &host_start, const double cpu_time, - bool &success, double *host_q, const int nlocal, +int **ljcd_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void ljcd_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, double *boxlo, double *prd); double ljcd_gpu_bytes(); /* ---------------------------------------------------------------------- */ PairLJCutCoulDebyeGPU::PairLJCutCoulDebyeGPU(LAMMPS *lmp) : - PairLJCutCoulDebye(lmp), gpu_mode(GPU_FORCE) + PairLJCutCoulDebye(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -78,14 +70,14 @@ PairLJCutCoulDebyeGPU::PairLJCutCoulDebyeGPU(LAMMPS *lmp) : PairLJCutCoulDebyeGPU::~PairLJCutCoulDebyeGPU() { -ljcd_gpu_clear(); + ljcd_gpu_clear(); } /* ---------------------------------------------------------------------- */ void PairLJCutCoulDebyeGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -93,7 +85,7 @@ void PairLJCutCoulDebyeGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -102,30 +94,25 @@ void PairLJCutCoulDebyeGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljcd_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = ljcd_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljcd_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + ljcd_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style lj/cut/coul/debye/gpu requires atom attribute q"); - + error->all(FLERR, "Pair style lj/cut/coul/debye/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -148,10 +134,9 @@ void PairLJCutCoulDebyeGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -159,23 +144,16 @@ void PairLJCutCoulDebyeGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljcd_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, - force->qqrd2e, kappa); - GPU_EXTRA::check_flag(success,error,world); + int success = + ljcd_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, kappa); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -188,14 +166,13 @@ double PairLJCutCoulDebyeGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCutCoulDebyeGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairLJCutCoulDebyeGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - double r,rinv,screening; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + double r, rinv, screening; int *jlist; evdwl = ecoul = 0.0; @@ -229,42 +206,45 @@ void PairLJCutCoulDebyeGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq[itype][jtype]) { r = sqrt(rsq); - rinv = 1.0/r; - screening = exp(-kappa*r); - forcecoul = qqrd2e * qtmp*q[j] * screening * (kappa + rinv); - } else forcecoul = 0.0; + rinv = 1.0 / r; + screening = exp(-kappa * r); + forcecoul = qqrd2e * qtmp * q[j] * screening * (kappa + rinv); + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - } else forcelj = 0.0; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + } else + forcelj = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forcelj) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq[itype][jtype]) - ecoul = factor_coul * qqrd2e * qtmp*q[j] * rinv * screening; - else ecoul = 0.0; + ecoul = factor_coul * qqrd2e * qtmp * q[j] * rinv * screening; + else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_coul_dsf_gpu.cpp b/src/GPU/pair_lj_cut_coul_dsf_gpu.cpp index b6bc14de7d..144777e4b6 100644 --- a/src/GPU/pair_lj_cut_coul_dsf_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_dsf_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,50 +23,41 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include #define MY_PIS 1.77245385090551602729 -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljd_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, const double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, - const double e_shift, const double f_shift, - const double alpha); +int ljd_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + const double host_cut_coulsq, double *host_special_coul, const double qqrd2e, + const double e_shift, const double f_shift, const double alpha); void ljd_gpu_clear(); -int ** ljd_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void ljd_gpu_compute(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, const bool eatom, - const bool vatom, int &host_start, const double cpu_time, - bool &success, double *host_q, const int nlocal, - double *boxlo, double *prd); +int **ljd_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void ljd_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success, double *host_q, const int nlocal, double *boxlo, double *prd); double ljd_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -94,7 +84,7 @@ PairLJCutCoulDSFGPU::~PairLJCutCoulDSFGPU() void PairLJCutCoulDSFGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -102,7 +92,7 @@ void PairLJCutCoulDSFGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -111,30 +101,25 @@ void PairLJCutCoulDSFGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljd_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = ljd_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljd_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + ljd_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style lj/cut/coul/dsf/gpu requires atom attribute q"); - + if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/coul/dsf/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -157,10 +140,9 @@ void PairLJCutCoulDSFGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -169,28 +151,21 @@ void PairLJCutCoulDSFGPU::init_style() double cell_size = sqrt(maxcut) + neighbor->skin; cut_coulsq = cut_coul * cut_coul; - double erfcc = erfc(alpha*cut_coul); - double erfcd = exp(-alpha*alpha*cut_coul*cut_coul); - f_shift = -(erfcc/cut_coulsq + 2.0/MY_PIS*alpha*erfcd/cut_coul); - e_shift = erfcc/cut_coul - f_shift*cut_coul; + double erfcc = erfc(alpha * cut_coul); + double erfcd = exp(-alpha * alpha * cut_coul * cut_coul); + f_shift = -(erfcc / cut_coulsq + 2.0 / MY_PIS * alpha * erfcd / cut_coul); + e_shift = erfcc / cut_coul - f_shift * cut_coul; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljd_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, - force->special_coul, force->qqrd2e, e_shift, - f_shift, alpha); - GPU_EXTRA::check_flag(success,error,world); + int success = ljd_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, + gpu_mode, screen, cut_ljsq, cut_coulsq, force->special_coul, + force->qqrd2e, e_shift, f_shift, alpha); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -203,14 +178,13 @@ double PairLJCutCoulDSFGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCutCoulDSFGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairLJCutCoulDSFGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double r,rsq,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - double prefactor,erfcc,erfcd,t; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double r, rsq, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + double prefactor, erfcc, erfcd, t; int *jlist; evdwl = ecoul = 0.0; @@ -237,8 +211,8 @@ void PairLJCutCoulDSFGPU::cpu_compute(int start, int inum, int eflag, jnum = numneigh[i]; if (evflag) { - double e_self = -(e_shift/2.0 + alpha/MY_PIS) * qtmp*qtmp*qqrd2e; - ev_tally(i,i,nlocal,0,0.0,e_self,0.0,0.0,0.0,0.0); + double e_self = -(e_shift / 2.0 + alpha / MY_PIS) * qtmp * qtmp * qqrd2e; + ev_tally(i, i, nlocal, 0, 0.0, e_self, 0.0, 0.0, 0.0, 0.0); } for (jj = 0; jj < jnum; jj++) { @@ -250,47 +224,48 @@ void PairLJCutCoulDSFGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - } else forcelj = 0.0; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + } else + forcelj = 0.0; if (rsq < cut_coulsq) { r = sqrt(rsq); - prefactor = qqrd2e*qtmp*q[j]/r; - erfcd = exp(-alpha*alpha*r*r); - t = 1.0 / (1.0 + EWALD_P*alpha*r); - erfcc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * erfcd; - forcecoul = prefactor * (erfcc/r + 2.0*alpha/MY_PIS * erfcd + - r*f_shift) * r; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + prefactor = qqrd2e * qtmp * q[j] / r; + erfcd = exp(-alpha * alpha * r * r); + t = 1.0 / (1.0 + EWALD_P * alpha * r); + erfcc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * erfcd; + forcecoul = prefactor * (erfcc / r + 2.0 * alpha / MY_PIS * erfcd + r * f_shift) * r; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; } - fpair = (forcecoul + factor_lj*forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + fpair = (forcecoul + factor_lj * forcelj) * r2inv; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; if (rsq < cut_coulsq) { - ecoul = prefactor * (erfcc - r*e_shift - rsq*f_shift); - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + ecoul = prefactor * (erfcc - r * e_shift - rsq * f_shift); + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_coul_long_gpu.cpp b/src/GPU/pair_lj_cut_coul_long_gpu.cpp index c70944229d..79b6dff9f5 100644 --- a/src/GPU/pair_lj_cut_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,56 +24,49 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljcl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, +int ljcl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double host_cut_coulsq, double *host_special_coul, const double qqrd2e, const double g_ewald); -void ljcl_gpu_reinit(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double **host_lj_cutsq); +void ljcl_gpu_reinit(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double **host_lj_cutsq); void ljcl_gpu_clear(); -int ** ljcl_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, double *host_q, - double *boxlo, double *prd); -void ljcl_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **ljcl_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void ljcl_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double ljcl_gpu_bytes(); /* ---------------------------------------------------------------------- */ PairLJCutCoulLongGPU::PairLJCutCoulLongGPU(LAMMPS *lmp) : - PairLJCutCoulLong(lmp), gpu_mode(GPU_FORCE) + PairLJCutCoulLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; cpu_time = 0.0; @@ -95,7 +87,7 @@ PairLJCutCoulLongGPU::~PairLJCutCoulLongGPU() void PairLJCutCoulLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -103,7 +95,7 @@ void PairLJCutCoulLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -112,30 +104,25 @@ void PairLJCutCoulLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljcl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = ljcl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljcl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + ljcl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style lj/cut/coul/long/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/coul/long/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -159,10 +145,9 @@ void PairLJCutCoulLongGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -174,30 +159,23 @@ void PairLJCutCoulLongGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljcl_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, - force->special_coul, force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + int success = + ljcl_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, g_ewald); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -206,7 +184,7 @@ void PairLJCutCoulLongGPU::reinit() { Pair::reinit(); - ljcl_gpu_reinit(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, offset, cut_ljsq); + ljcl_gpu_reinit(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, cut_ljsq); } /* ---------------------------------------------------------------------- */ @@ -219,15 +197,14 @@ double PairLJCutCoulLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCutCoulLongGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairLJCutCoulLongGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype,itable; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double fraction,table; - double r,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - double grij,expm2,prefactor,t,erfc; + int i, j, ii, jj, jnum, itype, jtype, itable; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double fraction, table; + double r, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + double grij, expm2, prefactor, t, erfc; int *jlist; double rsq; @@ -262,68 +239,71 @@ void PairLJCutCoulLongGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; } else { union_int_float_t rsq_lookup; rsq_lookup.f = rsq; itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = qtmp*q[j] * table; + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = qtmp * q[j] * table; if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = qtmp*q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = qtmp * q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; } } - } else forcecoul = 0.0; + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - } else forcelj = 0.0; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + } else + forcelj = 0.0; - fpair = (forcecoul + factor_lj*forcelj) * r2inv; + fpair = (forcecoul + factor_lj * forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) - ecoul = prefactor*erfc; + ecoul = prefactor * erfc; else { - table = etable[itable] + fraction*detable[itable]; - ecoul = qtmp*q[j] * table; + table = etable[itable] + fraction * detable[itable]; + ecoul = qtmp * q[j] * table; } - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_coul_msm_gpu.cpp b/src/GPU/pair_lj_cut_coul_msm_gpu.cpp index 8038db1424..0225127f29 100644 --- a/src/GPU/pair_lj_cut_coul_msm_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_msm_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,7 +24,6 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -35,36 +33,29 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljcm_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **host_gcons, double **host_dgcons, - double **offset, double *special_lj, const int inum, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double host_cut_coulsq, - double *host_special_coul, const int order, - const double qqrd2e); +int ljcm_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **host_gcons, double **host_dgcons, + double **offset, double *special_lj, const int inum, const int nall, + const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, + FILE *screen, double **host_cut_ljsq, double host_cut_coulsq, + double *host_special_coul, const int order, const double qqrd2e); void ljcm_gpu_clear(); -int ** ljcm_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void ljcm_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **ljcm_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void ljcm_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double ljcm_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairLJCutCoulMSMGPU::PairLJCutCoulMSMGPU(LAMMPS *lmp) : - PairLJCutCoulMSM(lmp), gpu_mode(GPU_FORCE) +PairLJCutCoulMSMGPU::PairLJCutCoulMSMGPU(LAMMPS *lmp) : PairLJCutCoulMSM(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -86,7 +77,7 @@ PairLJCutCoulMSMGPU::~PairLJCutCoulMSMGPU() void PairLJCutCoulMSMGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -94,7 +85,7 @@ void PairLJCutCoulMSMGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -103,30 +94,25 @@ void PairLJCutCoulMSMGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljcm_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success, - atom->q, domain->boxlo, domain->prd); + firstneigh = ljcm_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljcm_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + ljcm_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style lj/cut/coul/cut/gpu requires atom attribute q"); - + if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/coul/cut/gpu requires atom attribute q"); if (force->kspace->scalar_pressure_flag) - error->all(FLERR,"Must use 'kspace_modify pressure/scalar no' with GPU MSM Pair styles"); + error->all(FLERR, "Must use 'kspace_modify pressure/scalar no' with GPU MSM Pair styles"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -154,10 +138,9 @@ void PairLJCutCoulMSMGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -169,27 +152,19 @@ void PairLJCutCoulMSMGPU::init_style() // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljcm_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - force->kspace->get_gcons(), - force->kspace->get_dgcons(), - offset, force->special_lj, - atom->nlocal, atom->nlocal+atom->nghost, - mnf, maxspecial, cell_size, gpu_mode, screen, - cut_ljsq, cut_coulsq, force->special_coul, - force->kspace->order, force->qqrd2e); - GPU_EXTRA::check_flag(success,error,world); + int success = + ljcm_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, force->kspace->get_gcons(), + force->kspace->get_dgcons(), offset, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen, + cut_ljsq, cut_coulsq, force->special_coul, force->kspace->order, force->qqrd2e); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -202,14 +177,14 @@ double PairLJCutCoulMSMGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCutCoulMSMGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype,itable; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double fraction,table; - double r,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - double egamma,fgamma,prefactor; +void PairLJCutCoulMSMGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype, itable; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double fraction, table; + double r, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + double egamma, fgamma, prefactor; int *jlist; double rsq; @@ -242,66 +217,69 @@ void PairLJCutCoulMSMGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); - prefactor = qqrd2e * qtmp*q[j]/r; - egamma = 1.0 - (r/cut_coul)*force->kspace->gamma(r/cut_coul); - fgamma = 1.0 + (rsq/cut_coulsq)*force->kspace->dgamma(r/cut_coul); + prefactor = qqrd2e * qtmp * q[j] / r; + egamma = 1.0 - (r / cut_coul) * force->kspace->gamma(r / cut_coul); + fgamma = 1.0 + (rsq / cut_coulsq) * force->kspace->dgamma(r / cut_coul); forcecoul = prefactor * fgamma; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; } else { union_int_float_t rsq_lookup; rsq_lookup.f = rsq; itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = qtmp*q[j] * table; + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = qtmp * q[j] * table; if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = qtmp*q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = qtmp * q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; } } - } else forcecoul = 0.0; + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - } else forcelj = 0.0; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + } else + forcelj = 0.0; fpair = (forcecoul + forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) - ecoul = prefactor*egamma; + ecoul = prefactor * egamma; else { - table = etable[itable] + fraction*detable[itable]; - ecoul = qtmp*q[j] * table; + table = etable[itable] + fraction * detable[itable]; + ecoul = qtmp * q[j] * table; } - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_dipole_cut_gpu.cpp b/src/GPU/pair_lj_cut_dipole_cut_gpu.cpp index d2f9cbb720..2c47b76418 100644 --- a/src/GPU/pair_lj_cut_dipole_cut_gpu.cpp +++ b/src/GPU/pair_lj_cut_dipole_cut_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include "update.h" @@ -36,36 +34,29 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int dpl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double **host_cut_coulsq, - double *host_special_coul, const double qqrd2e); +int dpl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double **host_cut_coulsq, double *host_special_coul, const double qqrd2e); void dpl_gpu_clear(); -int ** dpl_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, - double *host_q, double **host_mu, - double *boxlo, double *prd); -void dpl_gpu_compute(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, const bool eatom, - const bool vatom, int &host_start, const double cpu_time, - bool &success, double *host_q, double **host_mu, - const int nlocal, double *boxlo, double *prd); +int **dpl_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double **host_mu, + double *boxlo, double *prd); +void dpl_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success, double *host_q, double **host_mu, const int nlocal, + double *boxlo, double *prd); double dpl_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairLJCutDipoleCutGPU::PairLJCutDipoleCutGPU(LAMMPS *lmp) : PairLJCutDipoleCut(lmp), - gpu_mode(GPU_FORCE) +PairLJCutDipoleCutGPU::PairLJCutDipoleCutGPU(LAMMPS *lmp) : + PairLJCutDipoleCut(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -87,7 +78,7 @@ PairLJCutDipoleCutGPU::~PairLJCutDipoleCutGPU() void PairLJCutDipoleCutGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -95,7 +86,7 @@ void PairLJCutDipoleCutGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -104,30 +95,25 @@ void PairLJCutDipoleCutGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = dpl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, atom->mu, domain->boxlo, - domain->prd); + firstneigh = dpl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, atom->mu, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - dpl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + dpl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->mu, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag || !atom->mu_flag || !atom->torque_flag) - error->all(FLERR,"Pair dipole/cut/gpu requires atom attributes q, mu, torque"); + error->all(FLERR, "Pair dipole/cut/gpu requires atom attributes q, mu, torque"); - - if (strcmp(update->unit_style,"electron") == 0) - error->all(FLERR,"Cannot (yet) use 'electron' units with dipoles"); + if (strcmp(update->unit_style, "electron") == 0) + error->all(FLERR, "Cannot (yet) use 'electron' units with dipoles"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -153,10 +138,9 @@ void PairLJCutDipoleCutGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -164,22 +148,16 @@ void PairLJCutDipoleCutGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = dpl_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, - force->special_coul, force->qqrd2e); - GPU_EXTRA::check_flag(success,error,world); + int success = + dpl_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -192,21 +170,20 @@ double PairLJCutDipoleCutGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCutDipoleCutGPU::cpu_compute(int start, int inum, int eflag, int vflag, - int *ilist, int *numneigh, - int **firstneigh) +void PairLJCutDipoleCutGPU::cpu_compute(int start, int inum, int eflag, int vflag, int *ilist, + int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fx,fy,fz; - double rsq,rinv,r2inv,r6inv,r3inv,r5inv,r7inv; - double forcecoulx,forcecouly,forcecoulz,crossx,crossy,crossz; - double tixcoul,tiycoul,tizcoul,tjxcoul,tjycoul,tjzcoul; - double fq,pdotp,pidotr,pjdotr,pre1,pre2,pre3,pre4; - double forcelj,factor_coul,factor_lj; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fx, fy, fz; + double rsq, rinv, r2inv, r6inv, r3inv, r5inv, r7inv; + double forcecoulx, forcecouly, forcecoulz, crossx, crossy, crossz; + double tixcoul, tiycoul, tizcoul, tjxcoul, tjycoul, tjzcoul; + double fq, pdotp, pidotr, pjdotr, pre1, pre2, pre3, pre4; + double forcelj, factor_coul, factor_lj; int *jlist; evdwl = ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -218,7 +195,6 @@ void PairLJCutDipoleCutGPU::cpu_compute(int start, int inum, int eflag, int vfla double *special_lj = force->special_lj; double qqrd2e = force->qqrd2e; - // loop over neighbors of my atoms for (ii = start; ii < inum; ii++) { @@ -240,11 +216,11 @@ void PairLJCutDipoleCutGPU::cpu_compute(int start, int inum, int eflag, int vfla delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; rinv = sqrt(r2inv); // atom can have both a charge and dipole @@ -257,119 +233,119 @@ void PairLJCutDipoleCutGPU::cpu_compute(int start, int inum, int eflag, int vfla if (rsq < cut_coulsq[itype][jtype]) { if (qtmp != 0.0 && q[j] != 0.0) { - r3inv = r2inv*rinv; - pre1 = qtmp*q[j]*r3inv; + r3inv = r2inv * rinv; + pre1 = qtmp * q[j] * r3inv; - forcecoulx += pre1*delx; - forcecouly += pre1*dely; - forcecoulz += pre1*delz; + forcecoulx += pre1 * delx; + forcecouly += pre1 * dely; + forcecoulz += pre1 * delz; } if (mu[i][3] > 0.0 && mu[j][3] > 0.0) { - r3inv = r2inv*rinv; - r5inv = r3inv*r2inv; - r7inv = r5inv*r2inv; + r3inv = r2inv * rinv; + r5inv = r3inv * r2inv; + r7inv = r5inv * r2inv; - pdotp = mu[i][0]*mu[j][0] + mu[i][1]*mu[j][1] + mu[i][2]*mu[j][2]; - pidotr = mu[i][0]*delx + mu[i][1]*dely + mu[i][2]*delz; - pjdotr = mu[j][0]*delx + mu[j][1]*dely + mu[j][2]*delz; + pdotp = mu[i][0] * mu[j][0] + mu[i][1] * mu[j][1] + mu[i][2] * mu[j][2]; + pidotr = mu[i][0] * delx + mu[i][1] * dely + mu[i][2] * delz; + pjdotr = mu[j][0] * delx + mu[j][1] * dely + mu[j][2] * delz; - pre1 = 3.0*r5inv*pdotp - 15.0*r7inv*pidotr*pjdotr; - pre2 = 3.0*r5inv*pjdotr; - pre3 = 3.0*r5inv*pidotr; - pre4 = -1.0*r3inv; + pre1 = 3.0 * r5inv * pdotp - 15.0 * r7inv * pidotr * pjdotr; + pre2 = 3.0 * r5inv * pjdotr; + pre3 = 3.0 * r5inv * pidotr; + pre4 = -1.0 * r3inv; - forcecoulx += pre1*delx + pre2*mu[i][0] + pre3*mu[j][0]; - forcecouly += pre1*dely + pre2*mu[i][1] + pre3*mu[j][1]; - forcecoulz += pre1*delz + pre2*mu[i][2] + pre3*mu[j][2]; + forcecoulx += pre1 * delx + pre2 * mu[i][0] + pre3 * mu[j][0]; + forcecouly += pre1 * dely + pre2 * mu[i][1] + pre3 * mu[j][1]; + forcecoulz += pre1 * delz + pre2 * mu[i][2] + pre3 * mu[j][2]; - crossx = pre4 * (mu[i][1]*mu[j][2] - mu[i][2]*mu[j][1]); - crossy = pre4 * (mu[i][2]*mu[j][0] - mu[i][0]*mu[j][2]); - crossz = pre4 * (mu[i][0]*mu[j][1] - mu[i][1]*mu[j][0]); + crossx = pre4 * (mu[i][1] * mu[j][2] - mu[i][2] * mu[j][1]); + crossy = pre4 * (mu[i][2] * mu[j][0] - mu[i][0] * mu[j][2]); + crossz = pre4 * (mu[i][0] * mu[j][1] - mu[i][1] * mu[j][0]); - tixcoul += crossx + pre2 * (mu[i][1]*delz - mu[i][2]*dely); - tiycoul += crossy + pre2 * (mu[i][2]*delx - mu[i][0]*delz); - tizcoul += crossz + pre2 * (mu[i][0]*dely - mu[i][1]*delx); - tjxcoul += -crossx + pre3 * (mu[j][1]*delz - mu[j][2]*dely); - tjycoul += -crossy + pre3 * (mu[j][2]*delx - mu[j][0]*delz); - tjzcoul += -crossz + pre3 * (mu[j][0]*dely - mu[j][1]*delx); + tixcoul += crossx + pre2 * (mu[i][1] * delz - mu[i][2] * dely); + tiycoul += crossy + pre2 * (mu[i][2] * delx - mu[i][0] * delz); + tizcoul += crossz + pre2 * (mu[i][0] * dely - mu[i][1] * delx); + tjxcoul += -crossx + pre3 * (mu[j][1] * delz - mu[j][2] * dely); + tjycoul += -crossy + pre3 * (mu[j][2] * delx - mu[j][0] * delz); + tjzcoul += -crossz + pre3 * (mu[j][0] * dely - mu[j][1] * delx); } if (mu[i][3] > 0.0 && q[j] != 0.0) { - r3inv = r2inv*rinv; - r5inv = r3inv*r2inv; - pidotr = mu[i][0]*delx + mu[i][1]*dely + mu[i][2]*delz; - pre1 = 3.0*q[j]*r5inv * pidotr; - pre2 = q[j]*r3inv; + r3inv = r2inv * rinv; + r5inv = r3inv * r2inv; + pidotr = mu[i][0] * delx + mu[i][1] * dely + mu[i][2] * delz; + pre1 = 3.0 * q[j] * r5inv * pidotr; + pre2 = q[j] * r3inv; - forcecoulx += pre2*mu[i][0] - pre1*delx; - forcecouly += pre2*mu[i][1] - pre1*dely; - forcecoulz += pre2*mu[i][2] - pre1*delz; - tixcoul += pre2 * (mu[i][1]*delz - mu[i][2]*dely); - tiycoul += pre2 * (mu[i][2]*delx - mu[i][0]*delz); - tizcoul += pre2 * (mu[i][0]*dely - mu[i][1]*delx); + forcecoulx += pre2 * mu[i][0] - pre1 * delx; + forcecouly += pre2 * mu[i][1] - pre1 * dely; + forcecoulz += pre2 * mu[i][2] - pre1 * delz; + tixcoul += pre2 * (mu[i][1] * delz - mu[i][2] * dely); + tiycoul += pre2 * (mu[i][2] * delx - mu[i][0] * delz); + tizcoul += pre2 * (mu[i][0] * dely - mu[i][1] * delx); } if (mu[j][3] > 0.0 && qtmp != 0.0) { - r3inv = r2inv*rinv; - r5inv = r3inv*r2inv; - pjdotr = mu[j][0]*delx + mu[j][1]*dely + mu[j][2]*delz; - pre1 = 3.0*qtmp*r5inv * pjdotr; - pre2 = qtmp*r3inv; + r3inv = r2inv * rinv; + r5inv = r3inv * r2inv; + pjdotr = mu[j][0] * delx + mu[j][1] * dely + mu[j][2] * delz; + pre1 = 3.0 * qtmp * r5inv * pjdotr; + pre2 = qtmp * r3inv; - forcecoulx += pre1*delx - pre2*mu[j][0]; - forcecouly += pre1*dely - pre2*mu[j][1]; - forcecoulz += pre1*delz - pre2*mu[j][2]; - tjxcoul += -pre2 * (mu[j][1]*delz - mu[j][2]*dely); - tjycoul += -pre2 * (mu[j][2]*delx - mu[j][0]*delz); - tjzcoul += -pre2 * (mu[j][0]*dely - mu[j][1]*delx); + forcecoulx += pre1 * delx - pre2 * mu[j][0]; + forcecouly += pre1 * dely - pre2 * mu[j][1]; + forcecoulz += pre1 * delz - pre2 * mu[j][2]; + tjxcoul += -pre2 * (mu[j][1] * delz - mu[j][2] * dely); + tjycoul += -pre2 * (mu[j][2] * delx - mu[j][0] * delz); + tjzcoul += -pre2 * (mu[j][0] * dely - mu[j][1] * delx); } } // LJ interaction if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); forcelj *= factor_lj * r2inv; - } else forcelj = 0.0; + } else + forcelj = 0.0; // total force - fq = factor_coul*qqrd2e; - fx = fq*forcecoulx + delx*forcelj; - fy = fq*forcecouly + dely*forcelj; - fz = fq*forcecoulz + delz*forcelj; + fq = factor_coul * qqrd2e; + fx = fq * forcecoulx + delx * forcelj; + fy = fq * forcecouly + dely * forcelj; + fz = fq * forcecoulz + delz * forcelj; // force & torque accumulation f[i][0] += fx; f[i][1] += fy; f[i][2] += fz; - torque[i][0] += fq*tixcoul; - torque[i][1] += fq*tiycoul; - torque[i][2] += fq*tizcoul; + torque[i][0] += fq * tixcoul; + torque[i][1] += fq * tiycoul; + torque[i][2] += fq * tizcoul; if (eflag) { if (rsq < cut_coulsq[itype][jtype]) { - ecoul = qtmp*q[j]*rinv; + ecoul = qtmp * q[j] * rinv; if (mu[i][3] > 0.0 && mu[j][3] > 0.0) - ecoul += r3inv*pdotp - 3.0*r5inv*pidotr*pjdotr; - if (mu[i][3] > 0.0 && q[j] != 0.0) - ecoul += -q[j]*r3inv*pidotr; - if (mu[j][3] > 0.0 && qtmp != 0.0) - ecoul += qtmp*r3inv*pjdotr; - ecoul *= factor_coul*qqrd2e; - } else ecoul = 0.0; + ecoul += r3inv * pdotp - 3.0 * r5inv * pidotr * pjdotr; + if (mu[i][3] > 0.0 && q[j] != 0.0) ecoul += -q[j] * r3inv * pidotr; + if (mu[j][3] > 0.0 && qtmp != 0.0) ecoul += qtmp * r3inv * pjdotr; + ecoul *= factor_coul * qqrd2e; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_xyz_full(i,evdwl,ecoul,fx,fy,fz,delx,dely,delz); + if (evflag) ev_tally_xyz_full(i, evdwl, ecoul, fx, fy, fz, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_dipole_long_gpu.cpp b/src/GPU/pair_lj_cut_dipole_long_gpu.cpp index c9830a8627..6db936447f 100644 --- a/src/GPU/pair_lj_cut_dipole_long_gpu.cpp +++ b/src/GPU/pair_lj_cut_dipole_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "kspace.h" #include "math_const.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include "update.h" @@ -34,50 +32,43 @@ #include #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; using namespace MathConst; // External functions from cuda library for atom decomposition -int dplj_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, const double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, +int dplj_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + const double host_cut_coulsq, double *host_special_coul, const double qqrd2e, const double g_ewald); void dplj_gpu_clear(); -int ** dplj_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, - double *host_q, double **host_mu, - double *boxlo, double *prd); -void dplj_gpu_compute(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, const bool eatom, - const bool vatom, int &host_start, const double cpu_time, - bool &success, double *host_q, double **host_mu, +int **dplj_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double **host_mu, + double *boxlo, double *prd); +void dplj_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, double **host_mu, const int nlocal, double *boxlo, double *prd); double dplj_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairLJCutDipoleLongGPU::PairLJCutDipoleLongGPU(LAMMPS *lmp) : PairLJCutDipoleLong(lmp), - gpu_mode(GPU_FORCE) +PairLJCutDipoleLongGPU::PairLJCutDipoleLongGPU(LAMMPS *lmp) : + PairLJCutDipoleLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -99,7 +90,7 @@ PairLJCutDipoleLongGPU::~PairLJCutDipoleLongGPU() void PairLJCutDipoleLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -107,7 +98,7 @@ void PairLJCutDipoleLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -116,30 +107,25 @@ void PairLJCutDipoleLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = dplj_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, atom->mu, domain->boxlo, - domain->prd); + firstneigh = dplj_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, atom->mu, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - dplj_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, - atom->mu, atom->nlocal, domain->boxlo, domain->prd); + dplj_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, + atom->mu, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag || !atom->mu_flag || !atom->torque_flag) - error->all(FLERR,"Pair dipole/cut/gpu requires atom attributes q, mu, torque"); + error->all(FLERR, "Pair dipole/cut/gpu requires atom attributes q, mu, torque"); - - if (strcmp(update->unit_style,"electron") == 0) - error->all(FLERR,"Cannot (yet) use 'electron' units with dipoles"); + if (strcmp(update->unit_style, "electron") == 0) + error->all(FLERR, "Cannot (yet) use 'electron' units with dipoles"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -165,10 +150,9 @@ void PairLJCutDipoleLongGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -180,30 +164,23 @@ void PairLJCutDipoleLongGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,nullptr); + if (ncoultablebits) init_tables(cut_coul, nullptr); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = dplj_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, - force->special_coul, force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + int success = + dplj_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, g_ewald); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -216,27 +193,26 @@ double PairLJCutDipoleLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCutDipoleLongGPU::cpu_compute(int start, int inum, int eflag, int vflag, - int *ilist, int *numneigh, - int **firstneigh) +void PairLJCutDipoleLongGPU::cpu_compute(int start, int inum, int eflag, int vflag, int *ilist, + int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz; - double rsq,r,rinv,r2inv,r6inv; - double forcecoulx,forcecouly,forcecoulz,fforce; - double tixcoul,tiycoul,tizcoul; - double fx,fy,fz,fdx,fdy,fdz,fax,fay,faz; - double pdotp,pidotr,pjdotr,pre1,pre2,pre3; - double grij,expm2,t,erfc; - double g0,g1,g2,b0,b1,b2,b3,d0,d1,d2,d3; - double zdix,zdiy,zdiz,zdjx,zdjy,zdjz,zaix,zaiy,zaiz,zajx,zajy,zajz; - double g0b1_g1b2_g2b3,g0d1_g1d2_g2d3; - double forcelj,factor_coul,factor_lj,facm1; - double evdwl,ecoul; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz; + double rsq, r, rinv, r2inv, r6inv; + double forcecoulx, forcecouly, forcecoulz, fforce; + double tixcoul, tiycoul, tizcoul; + double fx, fy, fz, fdx, fdy, fdz, fax, fay, faz; + double pdotp, pidotr, pjdotr, pre1, pre2, pre3; + double grij, expm2, t, erfc; + double g0, g1, g2, b0, b1, b2, b3, d0, d1, d2, d3; + double zdix, zdiy, zdiz, zdjx, zdjy, zdjz, zaix, zaiy, zaiz, zajx, zajy, zajz; + double g0b1_g1b2_g2b3, g0d1_g1d2_g2d3; + double forcelj, factor_coul, factor_lj, facm1; + double evdwl, ecoul; int *jlist; evdwl = ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -249,8 +225,8 @@ void PairLJCutDipoleLongGPU::cpu_compute(int start, int inum, int eflag, int vfl double qqrd2e = force->qqrd2e; pre1 = 2.0 * g_ewald / MY_PIS; - pre2 = 4.0 * pow(g_ewald,3.0) / MY_PIS; - pre3 = 8.0 * pow(g_ewald,5.0) / MY_PIS; + pre2 = 4.0 * pow(g_ewald, 3.0) / MY_PIS; + pre3 = 8.0 * pow(g_ewald, 5.0) / MY_PIS; // loop over neighbors of my atoms @@ -273,51 +249,48 @@ void PairLJCutDipoleLongGPU::cpu_compute(int start, int inum, int eflag, int vfl delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; rinv = sqrt(r2inv); if (rsq < cut_coulsq) { r = sqrt(rsq); grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; - pdotp = mu[i][0]*mu[j][0] + mu[i][1]*mu[j][1] + mu[i][2]*mu[j][2]; - pidotr = mu[i][0]*delx + mu[i][1]*dely + mu[i][2]*delz; - pjdotr = mu[j][0]*delx + mu[j][1]*dely + mu[j][2]*delz; + pdotp = mu[i][0] * mu[j][0] + mu[i][1] * mu[j][1] + mu[i][2] * mu[j][2]; + pidotr = mu[i][0] * delx + mu[i][1] * dely + mu[i][2] * delz; + pjdotr = mu[j][0] * delx + mu[j][1] * dely + mu[j][2] * delz; - g0 = qtmp*q[j]; - g1 = qtmp*pjdotr - q[j]*pidotr + pdotp; - g2 = -pidotr*pjdotr; + g0 = qtmp * q[j]; + g1 = qtmp * pjdotr - q[j] * pidotr + pdotp; + g2 = -pidotr * pjdotr; if (factor_coul > 0.0) { b0 = erfc * rinv; - b1 = (b0 + pre1*expm2) * r2inv; - b2 = (3.0*b1 + pre2*expm2) * r2inv; - b3 = (5.0*b2 + pre3*expm2) * r2inv; + b1 = (b0 + pre1 * expm2) * r2inv; + b2 = (3.0 * b1 + pre2 * expm2) * r2inv; + b3 = (5.0 * b2 + pre3 * expm2) * r2inv; - g0b1_g1b2_g2b3 = g0*b1 + g1*b2 + g2*b3; - fdx = delx * g0b1_g1b2_g2b3 - - b1 * (qtmp*mu[j][0] - q[j]*mu[i][0]) + - b2 * (pjdotr*mu[i][0] + pidotr*mu[j][0]); - fdy = dely * g0b1_g1b2_g2b3 - - b1 * (qtmp*mu[j][1] - q[j]*mu[i][1]) + - b2 * (pjdotr*mu[i][1] + pidotr*mu[j][1]); - fdz = delz * g0b1_g1b2_g2b3 - - b1 * (qtmp*mu[j][2] - q[j]*mu[i][2]) + - b2 * (pjdotr*mu[i][2] + pidotr*mu[j][2]); + g0b1_g1b2_g2b3 = g0 * b1 + g1 * b2 + g2 * b3; + fdx = delx * g0b1_g1b2_g2b3 - b1 * (qtmp * mu[j][0] - q[j] * mu[i][0]) + + b2 * (pjdotr * mu[i][0] + pidotr * mu[j][0]); + fdy = dely * g0b1_g1b2_g2b3 - b1 * (qtmp * mu[j][1] - q[j] * mu[i][1]) + + b2 * (pjdotr * mu[i][1] + pidotr * mu[j][1]); + fdz = delz * g0b1_g1b2_g2b3 - b1 * (qtmp * mu[j][2] - q[j] * mu[i][2]) + + b2 * (pjdotr * mu[i][2] + pidotr * mu[j][2]); - zdix = delx * (q[j]*b1 + b2*pjdotr) - b1*mu[j][0]; - zdiy = dely * (q[j]*b1 + b2*pjdotr) - b1*mu[j][1]; - zdiz = delz * (q[j]*b1 + b2*pjdotr) - b1*mu[j][2]; - zdjx = delx * (-qtmp*b1 + b2*pidotr) - b1*mu[i][0]; - zdjy = dely * (-qtmp*b1 + b2*pidotr) - b1*mu[i][1]; - zdjz = delz * (-qtmp*b1 + b2*pidotr) - b1*mu[i][2]; + zdix = delx * (q[j] * b1 + b2 * pjdotr) - b1 * mu[j][0]; + zdiy = dely * (q[j] * b1 + b2 * pjdotr) - b1 * mu[j][1]; + zdiz = delz * (q[j] * b1 + b2 * pjdotr) - b1 * mu[j][2]; + zdjx = delx * (-qtmp * b1 + b2 * pidotr) - b1 * mu[i][0]; + zdjy = dely * (-qtmp * b1 + b2 * pidotr) - b1 * mu[i][1]; + zdjz = delz * (-qtmp * b1 + b2 * pidotr) - b1 * mu[i][2]; if (factor_coul < 1.0) { fdx *= factor_coul; @@ -338,27 +311,24 @@ void PairLJCutDipoleLongGPU::cpu_compute(int start, int inum, int eflag, int vfl if (factor_coul < 1.0) { d0 = (erfc - 1.0) * rinv; - d1 = (d0 + pre1*expm2) * r2inv; - d2 = (3.0*d1 + pre2*expm2) * r2inv; - d3 = (5.0*d2 + pre3*expm2) * r2inv; + d1 = (d0 + pre1 * expm2) * r2inv; + d2 = (3.0 * d1 + pre2 * expm2) * r2inv; + d3 = (5.0 * d2 + pre3 * expm2) * r2inv; - g0d1_g1d2_g2d3 = g0*d1 + g1*d2 + g2*d3; - fax = delx * g0d1_g1d2_g2d3 - - d1 * (qtmp*mu[j][0] - q[j]*mu[i][0]) + - d2 * (pjdotr*mu[i][0] + pidotr*mu[j][0]); - fay = dely * g0d1_g1d2_g2d3 - - d1 * (qtmp*mu[j][1] - q[j]*mu[i][1]) + - d2 * (pjdotr*mu[i][1] + pidotr*mu[j][1]); - faz = delz * g0d1_g1d2_g2d3 - - d1 * (qtmp*mu[j][2] - q[j]*mu[i][2]) + - d2 * (pjdotr*mu[i][2] + pidotr*mu[j][2]); + g0d1_g1d2_g2d3 = g0 * d1 + g1 * d2 + g2 * d3; + fax = delx * g0d1_g1d2_g2d3 - d1 * (qtmp * mu[j][0] - q[j] * mu[i][0]) + + d2 * (pjdotr * mu[i][0] + pidotr * mu[j][0]); + fay = dely * g0d1_g1d2_g2d3 - d1 * (qtmp * mu[j][1] - q[j] * mu[i][1]) + + d2 * (pjdotr * mu[i][1] + pidotr * mu[j][1]); + faz = delz * g0d1_g1d2_g2d3 - d1 * (qtmp * mu[j][2] - q[j] * mu[i][2]) + + d2 * (pjdotr * mu[i][2] + pidotr * mu[j][2]); - zaix = delx * (q[j]*d1 + d2*pjdotr) - d1*mu[j][0]; - zaiy = dely * (q[j]*d1 + d2*pjdotr) - d1*mu[j][1]; - zaiz = delz * (q[j]*d1 + d2*pjdotr) - d1*mu[j][2]; - zajx = delx * (-qtmp*d1 + d2*pidotr) - d1*mu[i][0]; - zajy = dely * (-qtmp*d1 + d2*pidotr) - d1*mu[i][1]; - zajz = delz * (-qtmp*d1 + d2*pidotr) - d1*mu[i][2]; + zaix = delx * (q[j] * d1 + d2 * pjdotr) - d1 * mu[j][0]; + zaiy = dely * (q[j] * d1 + d2 * pjdotr) - d1 * mu[j][1]; + zaiz = delz * (q[j] * d1 + d2 * pjdotr) - d1 * mu[j][2]; + zajx = delx * (-qtmp * d1 + d2 * pidotr) - d1 * mu[i][0]; + zajy = dely * (-qtmp * d1 + d2 * pidotr) - d1 * mu[i][1]; + zajz = delz * (-qtmp * d1 + d2 * pidotr) - d1 * mu[i][2]; if (factor_coul > 0.0) { facm1 = 1.0 - factor_coul; @@ -382,9 +352,9 @@ void PairLJCutDipoleLongGPU::cpu_compute(int start, int inum, int eflag, int vfl forcecouly = fdy + fay; forcecoulz = fdz + faz; - tixcoul = mu[i][1]*(zdiz + zaiz) - mu[i][2]*(zdiy + zaiy); - tiycoul = mu[i][2]*(zdix + zaix) - mu[i][0]*(zdiz + zaiz); - tizcoul = mu[i][0]*(zdiy + zaiy) - mu[i][1]*(zdix + zaix); + tixcoul = mu[i][1] * (zdiz + zaiz) - mu[i][2] * (zdiy + zaiy); + tiycoul = mu[i][2] * (zdix + zaix) - mu[i][0] * (zdiz + zaiz); + tizcoul = mu[i][0] * (zdiy + zaiy) - mu[i][1] * (zdix + zaix); } else { forcecoulx = forcecouly = forcecoulz = 0.0; tixcoul = tiycoul = tizcoul = 0.0; @@ -393,43 +363,45 @@ void PairLJCutDipoleLongGPU::cpu_compute(int start, int inum, int eflag, int vfl // LJ interaction if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - fforce = factor_lj * forcelj*r2inv; - } else fforce = 0.0; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + fforce = factor_lj * forcelj * r2inv; + } else + fforce = 0.0; // total force - fx = qqrd2e*forcecoulx + delx*fforce; - fy = qqrd2e*forcecouly + dely*fforce; - fz = qqrd2e*forcecoulz + delz*fforce; + fx = qqrd2e * forcecoulx + delx * fforce; + fy = qqrd2e * forcecouly + dely * fforce; + fz = qqrd2e * forcecoulz + delz * fforce; // force & torque accumulation f[i][0] += fx; f[i][1] += fy; f[i][2] += fz; - torque[i][0] += qqrd2e*tixcoul; - torque[i][1] += qqrd2e*tiycoul; - torque[i][2] += qqrd2e*tizcoul; + torque[i][0] += qqrd2e * tixcoul; + torque[i][1] += qqrd2e * tiycoul; + torque[i][2] += qqrd2e * tizcoul; if (eflag) { if (rsq < cut_coulsq && factor_coul > 0.0) { - ecoul = qqrd2e*(b0*g0 + b1*g1 + b2*g2); + ecoul = qqrd2e * (b0 * g0 + b1 * g1 + b2 * g2); if (factor_coul < 1.0) { ecoul *= factor_coul; - ecoul += (1-factor_coul) * qqrd2e * (d0*g0 + d1*g1 + d2*g2); + ecoul += (1 - factor_coul) * qqrd2e * (d0 * g0 + d1 * g1 + d2 * g2); } - } else ecoul = 0.0; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_xyz_full(i,evdwl,ecoul,fx,fy,fz,delx,dely,delz); + if (evflag) ev_tally_xyz_full(i, evdwl, ecoul, fx, fy, fz, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_gpu.cpp b/src/GPU/pair_lj_cut_gpu.cpp index ec04cb969d..c629a5f3bb 100644 --- a/src/GPU/pair_lj_cut_gpu.cpp +++ b/src/GPU/pair_lj_cut_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,29 +32,24 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, +int ljl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); -void ljl_gpu_reinit(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset); +void ljl_gpu_reinit(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset); void ljl_gpu_clear(); -int ** ljl_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void ljl_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success); +int **ljl_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void ljl_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success); double ljl_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -82,7 +75,7 @@ PairLJCutGPU::~PairLJCutGPU() void PairLJCutGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -90,7 +83,7 @@ void PairLJCutGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -99,28 +92,24 @@ void PairLJCutGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljl_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + ljl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + ljl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -153,21 +140,15 @@ void PairLJCutGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljl_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = ljl_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, + gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -176,7 +157,7 @@ void PairLJCutGPU::reinit() { Pair::reinit(); - ljl_gpu_reinit(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, offset); + ljl_gpu_reinit(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset); } /* ---------------------------------------------------------------------- */ @@ -189,11 +170,12 @@ double PairLJCutGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJCutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r6inv,forcelj,factor_lj; +void PairLJCutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r6inv, forcelj, factor_lj; int *jlist; double **x = atom->x; @@ -220,26 +202,25 @@ void PairLJCutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - fpair = factor_lj*forcelj*r2inv; + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + fpair = factor_lj * forcelj * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_cut_tip4p_long_gpu.cpp b/src/GPU/pair_lj_cut_tip4p_long_gpu.cpp index cfb2f06768..5c2c391136 100644 --- a/src/GPU/pair_lj_cut_tip4p_long_gpu.cpp +++ b/src/GPU/pair_lj_cut_tip4p_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -34,55 +33,47 @@ #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljtip4p_long_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double *special_lj, const int nlocal, - const int tH, const int tO, const double alpha, const double qdist, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, const double host_cut_coulsq, - const double host_cut_coulsqplus, double *host_special_coul, - const double qqrd2e, const double g_ewald, - int map_size, int max_same); +int ljtip4p_long_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int tH, const int tO, const double alpha, + const double qdist, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + double **host_cut_ljsq, const double host_cut_coulsq, + const double host_cut_coulsqplus, double *host_special_coul, + const double qqrd2e, const double g_ewald, int map_size, int max_same); void ljtip4p_long_gpu_clear(); -int ** ljtip4p_long_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, - tagint *tag, int *map_array, int map_size, - int *sametag, int max_same, - int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success, double *host_q, - double *boxlo, double *prd); -void ljtip4p_long_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, - bool &success, double *host_q, const int nlocal, - double *boxlo, double *prd); +int **ljtip4p_long_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int *map_array, int map_size, int *sametag, int max_same, + int **nspecial, tagint **special, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, + int &host_start, int **ilist, int **jnum, const double cpu_time, + bool &success, double *host_q, double *boxlo, double *prd); +void ljtip4p_long_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, + const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, const double cpu_time, + bool &success, double *host_q, const int nlocal, double *boxlo, + double *prd); double ljtip4p_long_gpu_bytes(); -void ljtip4p_long_copy_molecule_data(int, tagint *, int *, - int, int *, int, int); +void ljtip4p_long_copy_molecule_data(int, tagint *, int *, int, int *, int, int); /* ---------------------------------------------------------------------- */ -PairLJCutTIP4PLongGPU::PairLJCutTIP4PLongGPU(LAMMPS *lmp) -: PairLJCutTIP4PLong(lmp), gpu_mode(GPU_FORCE) +PairLJCutTIP4PLongGPU::PairLJCutTIP4PLongGPU(LAMMPS *lmp) : + PairLJCutTIP4PLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -104,14 +95,14 @@ PairLJCutTIP4PLongGPU::~PairLJCutTIP4PLongGPU() void PairLJCutTIP4PLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -120,40 +111,26 @@ void PairLJCutTIP4PLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljtip4p_long_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, - atom->tag, atom->get_map_array(), atom->get_map_size(), - atom->sametag, atom->get_max_same(), - atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, &ilist, &numneigh, - cpu_time, success, atom->q, domain->boxlo, - domain->prd); + firstneigh = ljtip4p_long_gpu_compute_n( + neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->get_map_array(), atom->get_map_size(), atom->sametag, atom->get_max_same(), + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, host_start, &ilist, + &numneigh, cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljtip4p_long_copy_molecule_data(nall, atom->tag, - atom->get_map_array(), atom->get_map_size(), - atom->sametag, atom->get_max_same(), neighbor->ago); - ljtip4p_long_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, - atom->nlocal, domain->boxlo, domain->prd); + ljtip4p_long_copy_molecule_data(nall, atom->tag, atom->get_map_array(), atom->get_map_size(), + atom->sametag, atom->get_max_same(), neighbor->ago); + ljtip4p_long_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, + success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); - -// if (host_startone(FLERR, "Insufficient memory on accelerator"); } /* ---------------------------------------------------------------------- @@ -165,17 +142,16 @@ void PairLJCutTIP4PLongGPU::init_style() cut_respa = nullptr; if (atom->tag_enable == 0) - error->all(FLERR,"Pair style lj/cut/tip4p/long/gpu requires atom IDs"); + error->all(FLERR, "Pair style lj/cut/tip4p/long/gpu requires atom IDs"); if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/tip4p/long/gpu requires atom attribute q"); - if (force->bond == nullptr) - error->all(FLERR,"Must use a bond style with TIP4P potential"); - if (force->angle == nullptr) - error->all(FLERR,"Must use an angle style with TIP4P potential"); + if (force->bond == nullptr) error->all(FLERR, "Must use a bond style with TIP4P potential"); + if (force->angle == nullptr) error->all(FLERR, "Must use an angle style with TIP4P potential"); if (atom->map_style == Atom::MAP_HASH) - error->all(FLERR,"GPU-accelerated lj/cut/tip4p/long currently" - " requires 'array' style atom map (atom_modify map array)"); + error->all(FLERR, + "GPU-accelerated lj/cut/tip4p/long currently" + " requires 'array' style atom map (atom_modify map array)"); //PairLJCutCoulLong::init_style(); // Repeat cutsq calculation because done after call to init_style @@ -184,10 +160,9 @@ void PairLJCutTIP4PLongGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -196,51 +171,41 @@ void PairLJCutTIP4PLongGPU::init_style() double cell_size = sqrt(maxcut) + neighbor->skin; // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; // set alpha parameter double theta = force->angle->equilibrium_angle(typeA); double blen = force->bond->equilibrium_distance(typeB); - alpha = qdist / (cos(0.5*theta) * blen); + alpha = qdist / (cos(0.5 * theta) * blen); cut_coulsq = cut_coul * cut_coul; - double cut_coulsqplus = (cut_coul+qdist+blen) * (cut_coul+qdist+blen); - if (maxcut < cut_coulsqplus) { - cell_size = (cut_coul+qdist+blen) + neighbor->skin; - } + double cut_coulsqplus = (cut_coul + qdist + blen) * (cut_coul + qdist + blen); + if (maxcut < cut_coulsqplus) { cell_size = (cut_coul + qdist + blen) + neighbor->skin; } if (comm->cutghostuser < cell_size) { if (comm->me == 0) - error->warning(FLERR,"Increasing communication cutoff from {:.8} " - "to {:.8} for TIP4P GPU style",comm->cutghostuser,cell_size); + error->warning(FLERR, + "Increasing communication cutoff from {:.8} to {:.8} for TIP4P GPU style", + comm->cutghostuser, cell_size); comm->cutghostuser = cell_size; } int mnf = 5e-2 * neighbor->oneatom; - int success = ljtip4p_long_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, force->special_lj, atom->nlocal, - typeH, typeO, alpha, qdist, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, cut_coulsqplus, - force->special_coul, force->qqrd2e, - g_ewald, atom->get_map_size(), - atom->get_max_same()); - GPU_EXTRA::check_flag(success,error,world); + int success = ljtip4p_long_gpu_init( + atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, force->special_lj, atom->nlocal, typeH, + typeO, alpha, qdist, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, cut_coulsqplus, force->special_coul, force->qqrd2e, g_ewald, + atom->get_map_size(), atom->get_max_same()); + GPU_EXTRA::check_flag(success, error, world); if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->cut = 1; - neighbor->requests[irequest]->cutoff = cut_coul+qdist+blen + neighbor->skin; + auto req = neighbor->add_request(this, NeighConst::REQ_FULL); + req->set_cutoff(cut_coul + qdist + blen + neighbor->skin); } } @@ -253,4 +218,3 @@ double PairLJCutTIP4PLongGPU::memory_usage() } /* ---------------------------------------------------------------------- */ - diff --git a/src/GPU/pair_lj_expand_coul_long_gpu.cpp b/src/GPU/pair_lj_expand_coul_long_gpu.cpp index 5dc53a57fa..e14ffef0ea 100644 --- a/src/GPU/pair_lj_expand_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_expand_coul_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,56 +24,50 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljecl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double **shift, double *special_lj, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen, double **host_cut_ljsq, - double host_cut_coulsq, double *host_special_coul, +int ljecl_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double **shift, + double *special_lj, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + double **host_cut_ljsq, double host_cut_coulsq, double *host_special_coul, const double qqrd2e, const double g_ewald); -void ljecl_gpu_reinit(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double **shift, double **host_lj_cutsq); +void ljecl_gpu_reinit(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double **shift, + double **host_lj_cutsq); void ljecl_gpu_clear(); -int ** ljecl_gpu_compute_n(const int ago, const int inum, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, double *host_q, - double *boxlo, double *prd); -void ljecl_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **ljecl_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void ljecl_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double ljecl_gpu_bytes(); /* ---------------------------------------------------------------------- */ PairLJExpandCoulLongGPU::PairLJExpandCoulLongGPU(LAMMPS *lmp) : - PairLJExpandCoulLong(lmp), gpu_mode(GPU_FORCE) + PairLJExpandCoulLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; cpu_time = 0.0; @@ -95,7 +88,7 @@ PairLJExpandCoulLongGPU::~PairLJExpandCoulLongGPU() void PairLJExpandCoulLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -103,7 +96,7 @@ void PairLJExpandCoulLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -112,30 +105,25 @@ void PairLJExpandCoulLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljecl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = ljecl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljecl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, - atom->nlocal, domain->boxlo, domain->prd); + ljecl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, + atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag) - error->all(FLERR,"Pair style lj/cut/coul/long/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/coul/long/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -159,10 +146,9 @@ void PairLJExpandCoulLongGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -174,30 +160,23 @@ void PairLJExpandCoulLongGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style requires a KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,cut_respa); + if (ncoultablebits) init_tables(cut_coul, cut_respa); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljecl_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, shift, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, - force->special_coul, force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + int success = ljecl_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, shift, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, + force->special_coul, force->qqrd2e, g_ewald); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -206,7 +185,7 @@ void PairLJExpandCoulLongGPU::reinit() { Pair::reinit(); - ljecl_gpu_reinit(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, offset, shift, cut_ljsq); + ljecl_gpu_reinit(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, shift, cut_ljsq); } /* ---------------------------------------------------------------------- */ @@ -219,16 +198,15 @@ double PairLJExpandCoulLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJExpandCoulLongGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) +void PairLJExpandCoulLongGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, + int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype,itable; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double fraction,table; - double r,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - double grij,expm2,prefactor,t,erfc; - double rsq,rshift,rshiftsq,rshift2inv; + int i, j, ii, jj, jnum, itype, jtype, itable; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double fraction, table; + double r, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + double grij, expm2, prefactor, t, erfc; + double rsq, rshift, rshiftsq, rshift2inv; int *jlist; @@ -263,73 +241,76 @@ void PairLJExpandCoulLongGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) { r = sqrt(rsq); grij = g_ewald * r; - expm2 = exp(-grij*grij); - t = 1.0 / (1.0 + EWALD_P*grij); - erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + expm2 = exp(-grij * grij); + t = 1.0 / (1.0 + EWALD_P * grij); + erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; } else { union_int_float_t rsq_lookup; rsq_lookup.f = rsq; itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; - table = ftable[itable] + fraction*dftable[itable]; - forcecoul = qtmp*q[j] * table; + table = ftable[itable] + fraction * dftable[itable]; + forcecoul = qtmp * q[j] * table; if (factor_coul < 1.0) { - table = ctable[itable] + fraction*dctable[itable]; - prefactor = qtmp*q[j] * table; - forcecoul -= (1.0-factor_coul)*prefactor; + table = ctable[itable] + fraction * dctable[itable]; + prefactor = qtmp * q[j] * table; + forcecoul -= (1.0 - factor_coul) * prefactor; } } - } else forcecoul = 0.0; + } else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { r = sqrt(rsq); rshift = r - shift[itype][jtype]; - rshiftsq = rshift*rshift; - rshift2inv = 1.0/rshiftsq; - r6inv = rshift2inv*rshift2inv*rshift2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - forcelj = factor_lj*forcelj/rshift/r; - } else forcelj = 0.0; + rshiftsq = rshift * rshift; + rshift2inv = 1.0 / rshiftsq; + r6inv = rshift2inv * rshift2inv * rshift2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + forcelj = factor_lj * forcelj / rshift / r; + } else + forcelj = 0.0; - fpair = forcecoul*r2inv + forcelj; + fpair = forcecoul * r2inv + forcelj; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) - ecoul = prefactor*erfc; + ecoul = prefactor * erfc; else { - table = etable[itable] + fraction*detable[itable]; - ecoul = qtmp*q[j] * table; + table = etable[itable] + fraction * detable[itable]; + ecoul = qtmp * q[j] * table; } - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_expand_gpu.cpp b/src/GPU/pair_lj_expand_gpu.cpp index e2dae0870c..fd6888e81f 100644 --- a/src/GPU/pair_lj_expand_gpu.cpp +++ b/src/GPU/pair_lj_expand_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,28 +32,22 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int lje_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double **shift, double *special_lj, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, int &gpu_mode, - FILE *screen); -void lje_gpu_reinit(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double **offset, double **shift); +int lje_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double **shift, + double *special_lj, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); +void lje_gpu_reinit(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double **shift); void lje_gpu_clear(); -int ** lje_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void lje_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success); +int **lje_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void lje_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success); double lje_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -81,7 +73,7 @@ PairLJExpandGPU::~PairLJExpandGPU() void PairLJExpandGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -89,7 +81,7 @@ void PairLJExpandGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -98,28 +90,24 @@ void PairLJExpandGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = lje_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success); + firstneigh = + lje_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - lje_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + lje_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -150,21 +137,15 @@ void PairLJExpandGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = lje_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - offset, shift, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = lje_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, shift, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -173,7 +154,7 @@ void PairLJExpandGPU::reinit() { Pair::reinit(); - lje_gpu_reinit(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, offset, shift); + lje_gpu_reinit(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, offset, shift); } /* ---------------------------------------------------------------------- */ @@ -186,14 +167,13 @@ double PairLJExpandGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJExpandGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairLJExpandGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r6inv,forcelj,factor_lj; - double r,rshift,rshiftsq; + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r6inv, forcelj, factor_lj; + double r, rshift, rshiftsq; int *jlist; double **x = atom->x; @@ -220,29 +200,28 @@ void PairLJExpandGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { r = sqrt(rsq); rshift = r - shift[itype][jtype]; - rshiftsq = rshift*rshift; - r2inv = 1.0/rshiftsq; - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - fpair = factor_lj*forcelj/rshift/r; + rshiftsq = rshift * rshift; + r2inv = 1.0 / rshiftsq; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + fpair = factor_lj * forcelj / rshift / r; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_gromacs_gpu.cpp b/src/GPU/pair_lj_gromacs_gpu.cpp index cdccb51725..7d47936f8c 100644 --- a/src/GPU/pair_lj_gromacs_gpu.cpp +++ b/src/GPU/pair_lj_gromacs_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,34 +32,27 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ljgrm_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double *special_lj, const int inum, const int nall, - const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_ljsw1, double **host_ljsw2, - double **host_ljsw3, double **host_ljsw4, - double **host_ljsw5, double **cut_inner, - double **cut_innersq); +int ljgrm_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double *special_lj, const int inum, + const int nall, const int max_nbors, const int maxspecial, + const double cell_size, int &gpu_mode, FILE *screen, double **host_ljsw1, + double **host_ljsw2, double **host_ljsw3, double **host_ljsw4, + double **host_ljsw5, double **cut_inner, double **cut_innersq); void ljgrm_gpu_clear(); -int ** ljgrm_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success); -void ljgrm_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **ljgrm_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void ljgrm_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double ljgrm_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairLJGromacsGPU::PairLJGromacsGPU(LAMMPS *lmp) : - PairLJGromacs(lmp), gpu_mode(GPU_FORCE) +PairLJGromacsGPU::PairLJGromacsGPU(LAMMPS *lmp) : PairLJGromacs(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -83,7 +74,7 @@ PairLJGromacsGPU::~PairLJGromacsGPU() void PairLJGromacsGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -91,7 +82,7 @@ void PairLJGromacsGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -100,28 +91,24 @@ void PairLJGromacsGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ljgrm_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, &ilist, - &numneigh, cpu_time, success); + firstneigh = + ljgrm_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ljgrm_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + ljgrm_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - mcut = init_one(i,j); + mcut = init_one(i, j); mcut *= mcut; - if (mcut > maxcut) - maxcut = mcut; + if (mcut > maxcut) maxcut = mcut; cutsq[i][j] = cutsq[j][i] = mcut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -152,23 +138,17 @@ void PairLJGromacsGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ljgrm_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, ljsw1, ljsw2, - ljsw3, ljsw4, ljsw5, cut_inner, cut_inner_sq); - GPU_EXTRA::check_flag(success,error,world); + int success = + ljgrm_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen, + ljsw1, ljsw2, ljsw3, ljsw4, ljsw5, cut_inner, cut_inner_sq); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -181,14 +161,13 @@ double PairLJGromacsGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJGromacsGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairLJGromacsGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r6inv,forcelj,factor_lj; - double r,t,fswitch,eswitch; + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r6inv, forcelj, factor_lj; + double r, t, fswitch, eswitch; int *jlist; double **x = atom->x; @@ -215,36 +194,36 @@ void PairLJGromacsGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - if (rsq > cut_inner_sq[itype][jtype]) { + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + if (rsq > cut_inner_sq[itype][jtype]) { r = sqrt(rsq); t = r - cut_inner[itype][jtype]; - fswitch = r*t*t*(ljsw1[itype][jtype] + ljsw2[itype][jtype]*t); - forcelj += fswitch; + fswitch = r * t * t * (ljsw1[itype][jtype] + ljsw2[itype][jtype] * t); + forcelj += fswitch; } - fpair = factor_lj*forcelj * r2inv; + fpair = factor_lj * forcelj * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; - if (eflag) { - evdwl = r6inv * (lj3[itype][jtype]*r6inv - lj4[itype][jtype]); - evdwl += ljsw5[itype][jtype]; + if (eflag) { + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]); + evdwl += ljsw5[itype][jtype]; if (rsq > cut_inner_sq[itype][jtype]) { - eswitch = t*t*t*(ljsw3[itype][jtype] + ljsw4[itype][jtype]*t); + eswitch = t * t * t * (ljsw3[itype][jtype] + ljsw4[itype][jtype] * t); evdwl += eswitch; } - evdwl *= factor_lj; - } + evdwl *= factor_lj; + } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_sdk_coul_long_gpu.cpp b/src/GPU/pair_lj_sdk_coul_long_gpu.cpp index 998cba05a0..8638f3d21d 100644 --- a/src/GPU/pair_lj_sdk_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_sdk_coul_long_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,58 +24,51 @@ #include "gpu_extra.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int sdkl_gpu_init(const int ntypes, double **cutsq, int **lj_type, - double **host_lj1, double **host_lj2, double **host_lj3, - double **host_lj4, double **offset, double *special_lj, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, int &gpu_mode, - FILE *screen, double **host_cut_ljsq, double host_cut_coulsq, - double *host_special_coul, const double qqrd2e, - const double g_ewald); +int sdkl_gpu_init(const int ntypes, double **cutsq, int **lj_type, double **host_lj1, + double **host_lj2, double **host_lj3, double **host_lj4, double **offset, + double *special_lj, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + double **host_cut_ljsq, double host_cut_coulsq, double *host_special_coul, + const double qqrd2e, const double g_ewald); void sdkl_gpu_clear(); -int ** sdkl_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double *boxlo, - double *prd); -void sdkl_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - const int nlocal, double *boxlo, double *prd); +int **sdkl_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double *boxlo, + double *prd); +void sdkl_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, const int nlocal, + double *boxlo, double *prd); double sdkl_gpu_bytes(); #include "lj_sdk_common.h" - using namespace LJSDKParms; /* ---------------------------------------------------------------------- */ PairLJSDKCoulLongGPU::PairLJSDKCoulLongGPU(LAMMPS *lmp) : - PairLJSDKCoulLong(lmp), gpu_mode(GPU_FORCE) + PairLJSDKCoulLong(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -98,7 +90,7 @@ PairLJSDKCoulLongGPU::~PairLJSDKCoulLongGPU() void PairLJSDKCoulLongGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -106,7 +98,7 @@ void PairLJSDKCoulLongGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -115,35 +107,33 @@ void PairLJSDKCoulLongGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = sdkl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, domain->boxlo, - domain->prd); + firstneigh = sdkl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, + eflag_atom, vflag_atom, host_start, &ilist, &numneigh, cpu_time, + success, atom->q, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - sdkl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + sdkl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_start(host_start, inum, ilist, numneigh, firstneigh); - else cpu_compute<1,0>(host_start, inum, ilist, numneigh, firstneigh); - } else cpu_compute<0,0>(host_start, inum, ilist, numneigh, firstneigh); + if (eflag) + cpu_compute<1, 1>(host_start, inum, ilist, numneigh, firstneigh); + else + cpu_compute<1, 0>(host_start, inum, ilist, numneigh, firstneigh); + } else + cpu_compute<0, 0>(host_start, inum, ilist, numneigh, firstneigh); cpu_time = platform::walltime() - cpu_time; } } @@ -154,8 +144,7 @@ void PairLJSDKCoulLongGPU::compute(int eflag, int vflag) void PairLJSDKCoulLongGPU::init_style() { - if (!atom->q_flag) - error->all(FLERR,"Pair style lj/sdk/coul/long/gpu requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style lj/sdk/coul/long/gpu requires atom attribute q"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -163,10 +152,9 @@ void PairLJSDKCoulLongGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -178,31 +166,23 @@ void PairLJSDKCoulLongGPU::init_style() // insure use of KSpace long-range solver, set g_ewald - if (force->kspace == nullptr) - error->all(FLERR,"Pair style is incompatible with KSpace style"); + if (force->kspace == nullptr) error->all(FLERR, "Pair style is incompatible with KSpace style"); g_ewald = force->kspace->g_ewald; // setup force tables - if (ncoultablebits) init_tables(cut_coul,nullptr); + if (ncoultablebits) init_tables(cut_coul, nullptr); - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = sdkl_gpu_init(atom->ntypes+1, cutsq, lj_type, lj1, lj2, lj3, - lj4, offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, - cut_coulsq, force->special_coul, - force->qqrd2e, g_ewald); - GPU_EXTRA::check_flag(success,error,world); + int success = + sdkl_gpu_init(atom->ntypes + 1, cutsq, lj_type, lj1, lj2, lj3, lj4, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, + screen, cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e, g_ewald); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -215,21 +195,21 @@ double PairLJSDKCoulLongGPU::memory_usage() /* ---------------------------------------------------------------------- */ template -void PairLJSDKCoulLongGPU::cpu_compute(int start, int inum, int *ilist, - int *numneigh, int **firstneigh) +void PairLJSDKCoulLongGPU::cpu_compute(int start, int inum, int *ilist, int *numneigh, + int **firstneigh) { - int i,j,ii,jj; - double qtmp,xtmp,ytmp,ztmp; - double r2inv,forcecoul,forcelj,factor_coul,factor_lj; + int i, j, ii, jj; + double qtmp, xtmp, ytmp, ztmp; + double r2inv, forcecoul, forcelj, factor_coul, factor_lj; - const double * const * const x = atom->x; - double * const * const f = atom->f; - const double * const q = atom->q; - const int * const type = atom->type; - const double * const special_coul = force->special_coul; - const double * const special_lj = force->special_lj; + const double *const *const x = atom->x; + double *const *const f = atom->f; + const double *const q = atom->q; + const int *const type = atom->type; + const double *const special_coul = force->special_coul; + const double *const special_lj = force->special_lj; const double qqrd2e = force->qqrd2e; - double fxtmp,fytmp,fztmp; + double fxtmp, fytmp, fztmp; // loop over neighbors of my atoms @@ -239,10 +219,10 @@ void PairLJSDKCoulLongGPU::cpu_compute(int start, int inum, int *ilist, xtmp = x[i][0]; ytmp = x[i][1]; ztmp = x[i][2]; - fxtmp=fytmp=fztmp=0.0; + fxtmp = fytmp = fztmp = 0.0; const int itype = type[i]; - const int * const jlist = firstneigh[i]; + const int *const jlist = firstneigh[i]; const int jnum = numneigh[i]; for (jj = 0; jj < jnum; jj++) { @@ -254,7 +234,7 @@ void PairLJSDKCoulLongGPU::cpu_compute(int start, int inum, int *ilist, const double delx = xtmp - x[j][0]; const double dely = ytmp - x[j][1]; const double delz = ztmp - x[j][2]; - const double rsq = delx*delx + dely*dely + delz*delz; + const double rsq = delx * delx + dely * dely + delz * delz; const int jtype = type[j]; double evdwl = 0.0; @@ -262,41 +242,40 @@ void PairLJSDKCoulLongGPU::cpu_compute(int start, int inum, int *ilist, double fpair = 0.0; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; const int ljt = lj_type[itype][jtype]; if (rsq < cut_coulsq) { if (!ncoultablebits || rsq <= tabinnersq) { const double r = sqrt(rsq); const double grij = g_ewald * r; - const double expm2 = exp(-grij*grij); - const double t = 1.0 / (1.0 + EWALD_P*grij); - const double erfc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * expm2; - const double prefactor = qqrd2e * qtmp*q[j]/r; - forcecoul = prefactor * (erfc + EWALD_F*grij*expm2); - if (EFLAG) ecoul = prefactor*erfc; + const double expm2 = exp(-grij * grij); + const double t = 1.0 / (1.0 + EWALD_P * grij); + const double erfc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * expm2; + const double prefactor = qqrd2e * qtmp * q[j] / r; + forcecoul = prefactor * (erfc + EWALD_F * grij * expm2); + if (EFLAG) ecoul = prefactor * erfc; if (factor_coul < 1.0) { - forcecoul -= (1.0-factor_coul)*prefactor; - if (EFLAG) ecoul -= (1.0-factor_coul)*prefactor; + forcecoul -= (1.0 - factor_coul) * prefactor; + if (EFLAG) ecoul -= (1.0 - factor_coul) * prefactor; } } else { union_int_float_t rsq_lookup; rsq_lookup.f = rsq; int itable = rsq_lookup.i & ncoulmask; itable >>= ncoulshiftbits; - const double fraction = (rsq_lookup.f - rtable[itable]) * - drtable[itable]; - const double table = ftable[itable] + fraction*dftable[itable]; - forcecoul = qtmp*q[j] * table; + const double fraction = (rsq_lookup.f - rtable[itable]) * drtable[itable]; + const double table = ftable[itable] + fraction * dftable[itable]; + forcecoul = qtmp * q[j] * table; if (EFLAG) { - const double table2 = etable[itable] + fraction*detable[itable]; - ecoul = qtmp*q[j] * table2; + const double table2 = etable[itable] + fraction * detable[itable]; + ecoul = qtmp * q[j] * table2; } if (factor_coul < 1.0) { - const double table2 = ctable[itable] + fraction*dctable[itable]; - const double prefactor = qtmp*q[j] * table2; - forcecoul -= (1.0-factor_coul)*prefactor; - if (EFLAG) ecoul -= (1.0-factor_coul)*prefactor; + const double table2 = ctable[itable] + fraction * dctable[itable]; + const double prefactor = qtmp * q[j] * table2; + forcecoul -= (1.0 - factor_coul) * prefactor; + if (EFLAG) ecoul -= (1.0 - factor_coul) * prefactor; } } } else { @@ -304,50 +283,46 @@ void PairLJSDKCoulLongGPU::cpu_compute(int start, int inum, int *ilist, ecoul = 0.0; } - if (rsq < cut_ljsq[itype][jtype]) { if (ljt == LJ12_4) { - const double r4inv=r2inv*r2inv; - forcelj = r4inv*(lj1[itype][jtype]*r4inv*r4inv - - lj2[itype][jtype]); + const double r4inv = r2inv * r2inv; + forcelj = r4inv * (lj1[itype][jtype] * r4inv * r4inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r4inv*(lj3[itype][jtype]*r4inv*r4inv - - lj4[itype][jtype]) - offset[itype][jtype]; + evdwl = r4inv * (lj3[itype][jtype] * r4inv * r4inv - lj4[itype][jtype]) - + offset[itype][jtype]; } else if (ljt == LJ9_6) { - const double r3inv = r2inv*sqrt(r2inv); - const double r6inv = r3inv*r3inv; - forcelj = r6inv*(lj1[itype][jtype]*r3inv - - lj2[itype][jtype]); + const double r3inv = r2inv * sqrt(r2inv); + const double r6inv = r3inv * r3inv; + forcelj = r6inv * (lj1[itype][jtype] * r3inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r6inv*(lj3[itype][jtype]*r3inv - - lj4[itype][jtype]) - offset[itype][jtype]; + evdwl = + r6inv * (lj3[itype][jtype] * r3inv - lj4[itype][jtype]) - offset[itype][jtype]; } else if (ljt == LJ12_6) { - const double r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv*(lj1[itype][jtype]*r6inv - - lj2[itype][jtype]); + const double r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r6inv*(lj3[itype][jtype]*r6inv - - lj4[itype][jtype]) - offset[itype][jtype]; + evdwl = + r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; } if (EFLAG) evdwl *= factor_lj; } else { - forcelj=0.0; + forcelj = 0.0; evdwl = 0.0; } - fpair = (forcecoul + factor_lj*forcelj) * r2inv; + fpair = (forcecoul + factor_lj * forcelj) * r2inv; - fxtmp += delx*fpair; - fytmp += dely*fpair; - fztmp += delz*fpair; + fxtmp += delx * fpair; + fytmp += dely * fpair; + fztmp += delz * fpair; - if (EVFLAG) ev_tally_full(i,evdwl,ecoul,fpair,delx,dely,delz); + if (EVFLAG) ev_tally_full(i, evdwl, ecoul, fpair, delx, dely, delz); } } f[i][0] += fxtmp; diff --git a/src/GPU/pair_lj_sdk_gpu.cpp b/src/GPU/pair_lj_sdk_gpu.cpp index 66cfe53009..21e079e06f 100644 --- a/src/GPU/pair_lj_sdk_gpu.cpp +++ b/src/GPU/pair_lj_sdk_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,25 +32,20 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int sdk_gpu_init(const int ntypes, double **cutsq, int **cg_types, - double **host_lj1, double **host_lj2, double **host_lj3, - double **host_lj4, double **offset, double *special_lj, - const int nlocal, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, int &gpu_mode, - FILE *screen); +int sdk_gpu_init(const int ntypes, double **cutsq, int **cg_types, double **host_lj1, + double **host_lj2, double **host_lj3, double **host_lj4, double **offset, + double *special_lj, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void sdk_gpu_clear(); -int ** sdk_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void sdk_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success); +int **sdk_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void sdk_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success); double sdk_gpu_bytes(); #include "lj_sdk_common.h" @@ -83,7 +76,7 @@ PairLJSDKGPU::~PairLJSDKGPU() void PairLJSDKGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -91,7 +84,7 @@ void PairLJSDKGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -100,33 +93,32 @@ void PairLJSDKGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = sdk_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success); + firstneigh = + sdk_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - sdk_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + sdk_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_start(host_start, inum, ilist, numneigh, firstneigh); - else cpu_compute<1,0>(host_start, inum, ilist, numneigh, firstneigh); - } else cpu_compute<0,0>(host_start, inum, ilist, numneigh, firstneigh); + if (eflag) + cpu_compute<1, 1>(host_start, inum, ilist, numneigh, firstneigh); + else + cpu_compute<1, 0>(host_start, inum, ilist, numneigh, firstneigh); + } else + cpu_compute<0, 0>(host_start, inum, ilist, numneigh, firstneigh); cpu_time = platform::walltime() - cpu_time; } } @@ -144,10 +136,9 @@ void PairLJSDKGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -155,21 +146,15 @@ void PairLJSDKGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = sdk_gpu_init(atom->ntypes+1,cutsq,lj_type,lj1,lj2,lj3,lj4, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = sdk_gpu_init(atom->ntypes + 1, cutsq, lj_type, lj1, lj2, lj3, lj4, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -182,19 +167,18 @@ double PairLJSDKGPU::memory_usage() /* ---------------------------------------------------------------------- */ template -void PairLJSDKGPU::cpu_compute(int start, int inum, int *ilist, - int *numneigh, int **firstneigh) +void PairLJSDKGPU::cpu_compute(int start, int inum, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,forcelj,factor_lj; + int i, j, ii, jj, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, forcelj, factor_lj; - const double * const * const x = atom->x; - double * const * const f = atom->f; - const int * const type = atom->type; - const double * const special_lj = force->special_lj; - double fxtmp,fytmp,fztmp; - evdwl=0.0; + const double *const *const x = atom->x; + double *const *const f = atom->f; + const int *const type = atom->type; + const double *const special_lj = force->special_lj; + double fxtmp, fytmp, fztmp; + evdwl = 0.0; // loop over neighbors of my atoms @@ -203,10 +187,10 @@ void PairLJSDKGPU::cpu_compute(int start, int inum, int *ilist, xtmp = x[i][0]; ytmp = x[i][1]; ztmp = x[i][2]; - fxtmp=fytmp=fztmp=0.0; + fxtmp = fytmp = fztmp = 0.0; const int itype = type[i]; - const int * const jlist = firstneigh[i]; + const int *const jlist = firstneigh[i]; const int jnum = numneigh[i]; for (jj = 0; jj < jnum; jj++) { @@ -217,47 +201,43 @@ void PairLJSDKGPU::cpu_compute(int start, int inum, int *ilist, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; const int ljt = lj_type[itype][jtype]; if (ljt == LJ12_4) { - const double r4inv=r2inv*r2inv; - forcelj = r4inv*(lj1[itype][jtype]*r4inv*r4inv - - lj2[itype][jtype]); + const double r4inv = r2inv * r2inv; + forcelj = r4inv * (lj1[itype][jtype] * r4inv * r4inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r4inv*(lj3[itype][jtype]*r4inv*r4inv - - lj4[itype][jtype]) - offset[itype][jtype]; + evdwl = r4inv * (lj3[itype][jtype] * r4inv * r4inv - lj4[itype][jtype]) - + offset[itype][jtype]; } else if (ljt == LJ9_6) { - const double r3inv = r2inv*sqrt(r2inv); - const double r6inv = r3inv*r3inv; - forcelj = r6inv*(lj1[itype][jtype]*r3inv - - lj2[itype][jtype]); + const double r3inv = r2inv * sqrt(r2inv); + const double r6inv = r3inv * r3inv; + forcelj = r6inv * (lj1[itype][jtype] * r3inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r6inv*(lj3[itype][jtype]*r3inv - - lj4[itype][jtype]) - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r3inv - lj4[itype][jtype]) - offset[itype][jtype]; } else if (ljt == LJ12_6) { - const double r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv*(lj1[itype][jtype]*r6inv - - lj2[itype][jtype]); + const double r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); if (EFLAG) - evdwl = r6inv*(lj3[itype][jtype]*r6inv - - lj4[itype][jtype]) - offset[itype][jtype]; - } else continue; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; + } else + continue; - fpair = factor_lj*forcelj*r2inv; + fpair = factor_lj * forcelj * r2inv; - fxtmp += delx*fpair; - fytmp += dely*fpair; - fztmp += delz*fpair; + fxtmp += delx * fpair; + fytmp += dely * fpair; + fztmp += delz * fpair; - if (EVFLAG) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (EVFLAG) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } f[i][0] += fxtmp; diff --git a/src/GPU/pair_lj_sf_dipole_sf_gpu.cpp b/src/GPU/pair_lj_sf_dipole_sf_gpu.cpp index f387dc8715..84b9f70624 100644 --- a/src/GPU/pair_lj_sf_dipole_sf_gpu.cpp +++ b/src/GPU/pair_lj_sf_dipole_sf_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" #include "update.h" @@ -36,35 +34,28 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int dplsf_gpu_init(const int ntypes, double **cutsq, double **host_lj1, - double **host_lj2, double **host_lj3, double **host_lj4, - double *special_lj, const int nlocal, +int dplsf_gpu_init(const int ntypes, double **cutsq, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double *special_lj, const int nlocal, const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - double **host_cut_ljsq, double **host_cut_coulsq, - double *host_special_coul, const double qqrd2e); + const double cell_size, int &gpu_mode, FILE *screen, double **host_cut_ljsq, + double **host_cut_coulsq, double *host_special_coul, const double qqrd2e); void dplsf_gpu_clear(); -int ** dplsf_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double *host_q, double **host_mu, - double *boxlo, double *prd); -void dplsf_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double *host_q, - double **host_mu, const int nlocal, double *boxlo, - double *prd); +int **dplsf_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double *host_q, double **host_mu, + double *boxlo, double *prd); +void dplsf_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success, double *host_q, double **host_mu, + const int nlocal, double *boxlo, double *prd); double dplsf_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairLJSFDipoleSFGPU::PairLJSFDipoleSFGPU(LAMMPS *lmp) : PairLJSFDipoleSF(lmp), - gpu_mode(GPU_FORCE) +PairLJSFDipoleSFGPU::PairLJSFDipoleSFGPU(LAMMPS *lmp) : PairLJSFDipoleSF(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -86,7 +77,7 @@ PairLJSFDipoleSFGPU::~PairLJSFDipoleSFGPU() void PairLJSFDipoleSFGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -94,7 +85,7 @@ void PairLJSFDipoleSFGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -103,30 +94,25 @@ void PairLJSFDipoleSFGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = dplsf_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, atom->q, atom->mu, domain->boxlo, - domain->prd); + firstneigh = dplsf_gpu_compute_n( + neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, atom->nspecial, + atom->special, eflag, vflag, eflag_atom, vflag_atom, host_start, &ilist, &numneigh, + cpu_time, success, atom->q, atom->mu, domain->boxlo, domain->prd); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - dplsf_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success, atom->q, + dplsf_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->q, atom->mu, atom->nlocal, domain->boxlo, domain->prd); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startq_flag || !atom->mu_flag || !atom->torque_flag) - error->all(FLERR,"Pair dipole/sf/gpu requires atom attributes q, mu, torque"); + error->all(FLERR, "Pair dipole/sf/gpu requires atom attributes q, mu, torque"); - - if (strcmp(update->unit_style,"electron") == 0) - error->all(FLERR,"Cannot (yet) use 'electron' units with dipoles"); + if (strcmp(update->unit_style, "electron") == 0) + error->all(FLERR, "Cannot (yet) use 'electron' units with dipoles"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -152,10 +137,9 @@ void PairLJSFDipoleSFGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -163,22 +147,16 @@ void PairLJSFDipoleSFGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = dplsf_gpu_init(atom->ntypes+1, cutsq, lj1, lj2, lj3, lj4, - force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, cut_ljsq, cut_coulsq, - force->special_coul, force->qqrd2e); - GPU_EXTRA::check_flag(success,error,world); + int success = + dplsf_gpu_init(atom->ntypes + 1, cutsq, lj1, lj2, lj3, lj4, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen, + cut_ljsq, cut_coulsq, force->special_coul, force->qqrd2e); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -191,25 +169,24 @@ double PairLJSFDipoleSFGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairLJSFDipoleSFGPU::cpu_compute(int start, int inum, int eflag, int vflag, - int *ilist, int *numneigh, - int **firstneigh) +void PairLJSFDipoleSFGPU::cpu_compute(int start, int inum, int eflag, int vflag, int *ilist, + int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fx,fy,fz; - double rsq,rinv,r2inv,r6inv,r3inv,r5inv; - double forcecoulx,forcecouly,forcecoulz,crossx,crossy,crossz; - double tixcoul,tiycoul,tizcoul,tjxcoul,tjycoul,tjzcoul; - double fq,pdotp,pidotr,pjdotr,pre1,pre2,pre3,pre4; - double forcelj,factor_coul,factor_lj; - double presf,afac,bfac,pqfac,qpfac,forceljcut,forceljsf; - double aforcecoulx,aforcecouly,aforcecoulz; - double bforcecoulx,bforcecouly,bforcecoulz; - double rcutlj2inv, rcutcoul2inv,rcutlj6inv; + int i, j, ii, jj, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fx, fy, fz; + double rsq, rinv, r2inv, r6inv, r3inv, r5inv; + double forcecoulx, forcecouly, forcecoulz, crossx, crossy, crossz; + double tixcoul, tiycoul, tizcoul, tjxcoul, tjycoul, tjzcoul; + double fq, pdotp, pidotr, pjdotr, pre1, pre2, pre3, pre4; + double forcelj, factor_coul, factor_lj; + double presf, afac, bfac, pqfac, qpfac, forceljcut, forceljsf; + double aforcecoulx, aforcecouly, aforcecoulz; + double bforcecoulx, bforcecouly, bforcecoulz; + double rcutlj2inv, rcutcoul2inv, rcutlj6inv; int *jlist; evdwl = ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -221,7 +198,6 @@ void PairLJSFDipoleSFGPU::cpu_compute(int start, int inum, int eflag, int vflag, double *special_lj = force->special_lj; double qqrd2e = force->qqrd2e; - // loop over neighbors of my atoms for (ii = start; ii < inum; ii++) { @@ -243,11 +219,11 @@ void PairLJSFDipoleSFGPU::cpu_compute(int start, int inum, int eflag, int vflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; rinv = sqrt(r2inv); // atom can have both a charge and dipole @@ -260,146 +236,145 @@ void PairLJSFDipoleSFGPU::cpu_compute(int start, int inum, int eflag, int vflag, if (rsq < cut_coulsq[itype][jtype]) { if (qtmp != 0.0 && q[j] != 0.0) { - pre1 = qtmp*q[j]*rinv*(r2inv-1.0/cut_coulsq[itype][jtype]); + pre1 = qtmp * q[j] * rinv * (r2inv - 1.0 / cut_coulsq[itype][jtype]); - forcecoulx += pre1*delx; - forcecouly += pre1*dely; - forcecoulz += pre1*delz; + forcecoulx += pre1 * delx; + forcecouly += pre1 * dely; + forcecoulz += pre1 * delz; } if (mu[i][3] > 0.0 && mu[j][3] > 0.0) { - r3inv = r2inv*rinv; - r5inv = r3inv*r2inv; - rcutcoul2inv=1.0/cut_coulsq[itype][jtype]; + r3inv = r2inv * rinv; + r5inv = r3inv * r2inv; + rcutcoul2inv = 1.0 / cut_coulsq[itype][jtype]; - pdotp = mu[i][0]*mu[j][0] + mu[i][1]*mu[j][1] + mu[i][2]*mu[j][2]; - pidotr = mu[i][0]*delx + mu[i][1]*dely + mu[i][2]*delz; - pjdotr = mu[j][0]*delx + mu[j][1]*dely + mu[j][2]*delz; + pdotp = mu[i][0] * mu[j][0] + mu[i][1] * mu[j][1] + mu[i][2] * mu[j][2]; + pidotr = mu[i][0] * delx + mu[i][1] * dely + mu[i][2] * delz; + pjdotr = mu[j][0] * delx + mu[j][1] * dely + mu[j][2] * delz; - afac = 1.0 - rsq*rsq * rcutcoul2inv*rcutcoul2inv; - pre1 = afac * ( pdotp - 3.0 * r2inv * pidotr * pjdotr ); - aforcecoulx = pre1*delx; - aforcecouly = pre1*dely; - aforcecoulz = pre1*delz; + afac = 1.0 - rsq * rsq * rcutcoul2inv * rcutcoul2inv; + pre1 = afac * (pdotp - 3.0 * r2inv * pidotr * pjdotr); + aforcecoulx = pre1 * delx; + aforcecouly = pre1 * dely; + aforcecoulz = pre1 * delz; - bfac = 1.0 - 4.0*rsq*sqrt(rsq)*rcutcoul2inv*sqrt(rcutcoul2inv) + - 3.0*rsq*rsq*rcutcoul2inv*rcutcoul2inv; + bfac = 1.0 - 4.0 * rsq * sqrt(rsq) * rcutcoul2inv * sqrt(rcutcoul2inv) + + 3.0 * rsq * rsq * rcutcoul2inv * rcutcoul2inv; presf = 2.0 * r2inv * pidotr * pjdotr; - bforcecoulx = bfac * (pjdotr*mu[i][0]+pidotr*mu[j][0]-presf*delx); - bforcecouly = bfac * (pjdotr*mu[i][1]+pidotr*mu[j][1]-presf*dely); - bforcecoulz = bfac * (pjdotr*mu[i][2]+pidotr*mu[j][2]-presf*delz); + bforcecoulx = bfac * (pjdotr * mu[i][0] + pidotr * mu[j][0] - presf * delx); + bforcecouly = bfac * (pjdotr * mu[i][1] + pidotr * mu[j][1] - presf * dely); + bforcecoulz = bfac * (pjdotr * mu[i][2] + pidotr * mu[j][2] - presf * delz); - forcecoulx += 3.0 * r5inv * ( aforcecoulx + bforcecoulx ); - forcecouly += 3.0 * r5inv * ( aforcecouly + bforcecouly ); - forcecoulz += 3.0 * r5inv * ( aforcecoulz + bforcecoulz ); + forcecoulx += 3.0 * r5inv * (aforcecoulx + bforcecoulx); + forcecouly += 3.0 * r5inv * (aforcecouly + bforcecouly); + forcecoulz += 3.0 * r5inv * (aforcecoulz + bforcecoulz); pre2 = 3.0 * bfac * r5inv * pjdotr; pre3 = 3.0 * bfac * r5inv * pidotr; pre4 = -bfac * r3inv; - crossx = pre4 * (mu[i][1]*mu[j][2] - mu[i][2]*mu[j][1]); - crossy = pre4 * (mu[i][2]*mu[j][0] - mu[i][0]*mu[j][2]); - crossz = pre4 * (mu[i][0]*mu[j][1] - mu[i][1]*mu[j][0]); + crossx = pre4 * (mu[i][1] * mu[j][2] - mu[i][2] * mu[j][1]); + crossy = pre4 * (mu[i][2] * mu[j][0] - mu[i][0] * mu[j][2]); + crossz = pre4 * (mu[i][0] * mu[j][1] - mu[i][1] * mu[j][0]); - tixcoul += crossx + pre2 * (mu[i][1]*delz - mu[i][2]*dely); - tiycoul += crossy + pre2 * (mu[i][2]*delx - mu[i][0]*delz); - tizcoul += crossz + pre2 * (mu[i][0]*dely - mu[i][1]*delx); - tjxcoul += -crossx + pre3 * (mu[j][1]*delz - mu[j][2]*dely); - tjycoul += -crossy + pre3 * (mu[j][2]*delx - mu[j][0]*delz); - tjzcoul += -crossz + pre3 * (mu[j][0]*dely - mu[j][1]*delx); + tixcoul += crossx + pre2 * (mu[i][1] * delz - mu[i][2] * dely); + tiycoul += crossy + pre2 * (mu[i][2] * delx - mu[i][0] * delz); + tizcoul += crossz + pre2 * (mu[i][0] * dely - mu[i][1] * delx); + tjxcoul += -crossx + pre3 * (mu[j][1] * delz - mu[j][2] * dely); + tjycoul += -crossy + pre3 * (mu[j][2] * delx - mu[j][0] * delz); + tjzcoul += -crossz + pre3 * (mu[j][0] * dely - mu[j][1] * delx); } if (mu[i][3] > 0.0 && q[j] != 0.0) { - r3inv = r2inv*rinv; - r5inv = r3inv*r2inv; - pidotr = mu[i][0]*delx + mu[i][1]*dely + mu[i][2]*delz; - rcutcoul2inv=1.0/cut_coulsq[itype][jtype]; - pre1 = 3.0 * q[j] * r5inv * pidotr * (1-rsq*rcutcoul2inv); - pqfac = 1.0 - 3.0*rsq*rcutcoul2inv + - 2.0*rsq*sqrt(rsq)*rcutcoul2inv*sqrt(rcutcoul2inv); + r3inv = r2inv * rinv; + r5inv = r3inv * r2inv; + pidotr = mu[i][0] * delx + mu[i][1] * dely + mu[i][2] * delz; + rcutcoul2inv = 1.0 / cut_coulsq[itype][jtype]; + pre1 = 3.0 * q[j] * r5inv * pidotr * (1 - rsq * rcutcoul2inv); + pqfac = 1.0 - 3.0 * rsq * rcutcoul2inv + + 2.0 * rsq * sqrt(rsq) * rcutcoul2inv * sqrt(rcutcoul2inv); pre2 = q[j] * r3inv * pqfac; - forcecoulx += pre2*mu[i][0] - pre1*delx; - forcecouly += pre2*mu[i][1] - pre1*dely; - forcecoulz += pre2*mu[i][2] - pre1*delz; - tixcoul += pre2 * (mu[i][1]*delz - mu[i][2]*dely); - tiycoul += pre2 * (mu[i][2]*delx - mu[i][0]*delz); - tizcoul += pre2 * (mu[i][0]*dely - mu[i][1]*delx); + forcecoulx += pre2 * mu[i][0] - pre1 * delx; + forcecouly += pre2 * mu[i][1] - pre1 * dely; + forcecoulz += pre2 * mu[i][2] - pre1 * delz; + tixcoul += pre2 * (mu[i][1] * delz - mu[i][2] * dely); + tiycoul += pre2 * (mu[i][2] * delx - mu[i][0] * delz); + tizcoul += pre2 * (mu[i][0] * dely - mu[i][1] * delx); } if (mu[j][3] > 0.0 && qtmp != 0.0) { - r3inv = r2inv*rinv; - r5inv = r3inv*r2inv; - pjdotr = mu[j][0]*delx + mu[j][1]*dely + mu[j][2]*delz; - rcutcoul2inv=1.0/cut_coulsq[itype][jtype]; - pre1 = 3.0 * qtmp * r5inv * pjdotr * (1-rsq*rcutcoul2inv); - qpfac = 1.0 - 3.0*rsq*rcutcoul2inv + - 2.0*rsq*sqrt(rsq)*rcutcoul2inv*sqrt(rcutcoul2inv); + r3inv = r2inv * rinv; + r5inv = r3inv * r2inv; + pjdotr = mu[j][0] * delx + mu[j][1] * dely + mu[j][2] * delz; + rcutcoul2inv = 1.0 / cut_coulsq[itype][jtype]; + pre1 = 3.0 * qtmp * r5inv * pjdotr * (1 - rsq * rcutcoul2inv); + qpfac = 1.0 - 3.0 * rsq * rcutcoul2inv + + 2.0 * rsq * sqrt(rsq) * rcutcoul2inv * sqrt(rcutcoul2inv); pre2 = qtmp * r3inv * qpfac; - forcecoulx += pre1*delx - pre2*mu[j][0]; - forcecouly += pre1*dely - pre2*mu[j][1]; - forcecoulz += pre1*delz - pre2*mu[j][2]; - tjxcoul += -pre2 * (mu[j][1]*delz - mu[j][2]*dely); - tjycoul += -pre2 * (mu[j][2]*delx - mu[j][0]*delz); - tjzcoul += -pre2 * (mu[j][0]*dely - mu[j][1]*delx); + forcecoulx += pre1 * delx - pre2 * mu[j][0]; + forcecouly += pre1 * dely - pre2 * mu[j][1]; + forcecoulz += pre1 * delz - pre2 * mu[j][2]; + tjxcoul += -pre2 * (mu[j][1] * delz - mu[j][2] * dely); + tjycoul += -pre2 * (mu[j][2] * delx - mu[j][0] * delz); + tjzcoul += -pre2 * (mu[j][0] * dely - mu[j][1] * delx); } } // LJ interaction if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forceljcut = r6inv*(lj1[itype][jtype]*r6inv-lj2[itype][jtype])*r2inv; + r6inv = r2inv * r2inv * r2inv; + forceljcut = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]) * r2inv; rcutlj2inv = 1.0 / cut_ljsq[itype][jtype]; rcutlj6inv = rcutlj2inv * rcutlj2inv * rcutlj2inv; - forceljsf = (lj1[itype][jtype]*rcutlj6inv - lj2[itype][jtype]) * - rcutlj6inv * rcutlj2inv; + forceljsf = + (lj1[itype][jtype] * rcutlj6inv - lj2[itype][jtype]) * rcutlj6inv * rcutlj2inv; forcelj = factor_lj * (forceljcut - forceljsf); - } else forcelj = 0.0; + } else + forcelj = 0.0; // total force - fq = factor_coul*qqrd2e; - fx = fq*forcecoulx + delx*forcelj; - fy = fq*forcecouly + dely*forcelj; - fz = fq*forcecoulz + delz*forcelj; + fq = factor_coul * qqrd2e; + fx = fq * forcecoulx + delx * forcelj; + fy = fq * forcecouly + dely * forcelj; + fz = fq * forcecoulz + delz * forcelj; // force & torque accumulation f[i][0] += fx; f[i][1] += fy; f[i][2] += fz; - torque[i][0] += fq*tixcoul; - torque[i][1] += fq*tiycoul; - torque[i][2] += fq*tizcoul; + torque[i][0] += fq * tixcoul; + torque[i][1] += fq * tiycoul; + torque[i][2] += fq * tizcoul; if (eflag) { if (rsq < cut_coulsq[itype][jtype]) { - ecoul = qtmp*q[j]*rinv* - pow((1.0-sqrt(rsq)/sqrt(cut_coulsq[itype][jtype])),2); + ecoul = qtmp * q[j] * rinv * pow((1.0 - sqrt(rsq) / sqrt(cut_coulsq[itype][jtype])), 2); if (mu[i][3] > 0.0 && mu[j][3] > 0.0) - ecoul += bfac * (r3inv*pdotp - 3.0*r5inv*pidotr*pjdotr); - if (mu[i][3] > 0.0 && q[j] != 0.0) - ecoul += -q[j]*r3inv * pqfac * pidotr; - if (mu[j][3] > 0.0 && qtmp != 0.0) - ecoul += qtmp*r3inv * qpfac * pjdotr; - ecoul *= factor_coul*qqrd2e; - } else ecoul = 0.0; + ecoul += bfac * (r3inv * pdotp - 3.0 * r5inv * pidotr * pjdotr); + if (mu[i][3] > 0.0 && q[j] != 0.0) ecoul += -q[j] * r3inv * pqfac * pidotr; + if (mu[j][3] > 0.0 && qtmp != 0.0) ecoul += qtmp * r3inv * qpfac * pjdotr; + ecoul *= factor_coul * qqrd2e; + } else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) + - rcutlj6inv*(6*lj3[itype][jtype]*rcutlj6inv-3*lj4[itype][jtype])* - rsq*rcutlj2inv + - rcutlj6inv*(-7*lj3[itype][jtype]*rcutlj6inv+4*lj4[itype][jtype]); + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) + + rcutlj6inv * (6 * lj3[itype][jtype] * rcutlj6inv - 3 * lj4[itype][jtype]) * rsq * + rcutlj2inv + + rcutlj6inv * (-7 * lj3[itype][jtype] * rcutlj6inv + 4 * lj4[itype][jtype]); evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally_xyz_full(i,evdwl,ecoul, - fx,fy,fz,delx,dely,delz); + if (evflag) ev_tally_xyz_full(i, evdwl, ecoul, fx, fy, fz, delx, dely, delz); } } } diff --git a/src/GPU/pair_lj_smooth_gpu.cpp b/src/GPU/pair_lj_smooth_gpu.cpp index 3b438b909e..a78c6c395e 100644 --- a/src/GPU/pair_lj_smooth_gpu.cpp +++ b/src/GPU/pair_lj_smooth_gpu.cpp @@ -23,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -155,11 +154,7 @@ void PairLJSmoothGPU::init_style() gpu_mode, screen, ljsw0, ljsw1, ljsw2, ljsw3, ljsw4, cut_inner, cut_inner_sq); GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/GPU/pair_mie_cut_gpu.cpp b/src/GPU/pair_mie_cut_gpu.cpp index df5438e095..4d257feba1 100644 --- a/src/GPU/pair_mie_cut_gpu.cpp +++ b/src/GPU/pair_mie_cut_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,25 +32,21 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int mie_gpu_init(const int ntypes, double **cutsq, double **host_mie1, - double **host_mie2, double **host_mie3, double **host_mie4, - double **host_gamA, double **host_gamR, double **offset, - double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen); +int mie_gpu_init(const int ntypes, double **cutsq, double **host_mie1, double **host_mie2, + double **host_mie3, double **host_mie4, double **host_gamA, double **host_gamR, + double **offset, double *special_lj, const int nlocal, const int nall, + const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, + FILE *screen); void mie_gpu_clear(); -int ** mie_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void mie_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success); +int **mie_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void mie_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success); double mie_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -79,7 +73,7 @@ PairMIECutGPU::~PairMIECutGPU() void PairMIECutGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -87,7 +81,7 @@ void PairMIECutGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -96,28 +90,24 @@ void PairMIECutGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = mie_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + mie_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - mie_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + mie_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -150,21 +138,15 @@ void PairMIECutGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = mie_gpu_init(atom->ntypes+1, cutsq, mie1, mie2, mie3, mie4, - gamA, gamR, offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = mie_gpu_init(atom->ntypes + 1, cutsq, mie1, mie2, mie3, mie4, gamA, gamR, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -177,11 +159,12 @@ double PairMIECutGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairMIECutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,rgamR,rgamA,forcemie,factor_mie; +void PairMIECutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, rgamR, rgamA, forcemie, factor_mie; int *jlist; double **x = atom->x; @@ -208,27 +191,26 @@ void PairMIECutGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; - rgamA = pow(r2inv,(gamA[itype][jtype]/2.0)); - rgamR = pow(r2inv,(gamR[itype][jtype]/2.0)); - forcemie = (mie1[itype][jtype]*rgamR - mie2[itype][jtype]*rgamA); - fpair = factor_mie*forcemie*r2inv; + r2inv = 1.0 / rsq; + rgamA = pow(r2inv, (gamA[itype][jtype] / 2.0)); + rgamR = pow(r2inv, (gamR[itype][jtype] / 2.0)); + forcemie = (mie1[itype][jtype] * rgamR - mie2[itype][jtype] * rgamA); + fpair = factor_mie * forcemie * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = (mie3[itype][jtype]*rgamR - mie4[itype][jtype]*rgamA) - - offset[itype][jtype]; + evdwl = (mie3[itype][jtype] * rgamR - mie4[itype][jtype] * rgamA) - offset[itype][jtype]; evdwl *= factor_mie; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_morse_gpu.cpp b/src/GPU/pair_morse_gpu.cpp index d7522d1a08..842bd29fa9 100644 --- a/src/GPU/pair_morse_gpu.cpp +++ b/src/GPU/pair_morse_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,24 +32,20 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int mor_gpu_init(const int ntypes, double **cutsq, double **host_morse1, - double **host_r0, double **host_alpha, double **host_d0, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, +int mor_gpu_init(const int ntypes, double **cutsq, double **host_morse1, double **host_r0, + double **host_alpha, double **host_d0, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void mor_gpu_clear(); -int ** mor_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void mor_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success); +int **mor_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void mor_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success); double mor_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -77,7 +71,7 @@ PairMorseGPU::~PairMorseGPU() void PairMorseGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -85,7 +79,7 @@ void PairMorseGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -94,28 +88,24 @@ void PairMorseGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = mor_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, &ilist, &numneigh, - cpu_time, success); + firstneigh = + mor_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - mor_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + mor_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -146,21 +135,15 @@ void PairMorseGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = mor_gpu_init(atom->ntypes+1, cutsq, morse1, r0, alpha, d0, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = mor_gpu_init(atom->ntypes + 1, cutsq, morse1, r0, alpha, d0, offset, + force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -173,12 +156,12 @@ double PairMorseGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairMorseGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) +void PairMorseGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r,dr,dexp,factor_lj; + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r, dr, dexp, factor_lj; int *jlist; double **x = atom->x; @@ -205,26 +188,25 @@ void PairMorseGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { r = sqrt(rsq); dr = r - r0[itype][jtype]; dexp = exp(-alpha[itype][jtype] * dr); - fpair = factor_lj * morse1[itype][jtype] * (dexp*dexp - dexp) / r; + fpair = factor_lj * morse1[itype][jtype] * (dexp * dexp - dexp) / r; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = d0[itype][jtype] * (dexp*dexp - 2.0*dexp) - - offset[itype][jtype]; + evdwl = d0[itype][jtype] * (dexp * dexp - 2.0 * dexp) - offset[itype][jtype]; evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_resquared_gpu.cpp b/src/GPU/pair_resquared_gpu.cpp index e43025f014..cfe871be2b 100644 --- a/src/GPU/pair_resquared_gpu.cpp +++ b/src/GPU/pair_resquared_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -27,7 +26,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -37,39 +35,32 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int re_gpu_init(const int ntypes, double **shape, double **well, - double **cutsq, double **sigma, double **epsilon, - int **form, double **host_lj1, double **host_lj2, - double **host_lj3, double **host_lj4, double **offset, - double *special_lj, const int nlocal, const int nall, - const int max_nbors, const int maxspecial, +int re_gpu_init(const int ntypes, double **shape, double **well, double **cutsq, double **sigma, + double **epsilon, int **form, double **host_lj1, double **host_lj2, + double **host_lj3, double **host_lj4, double **offset, double *special_lj, + const int nlocal, const int nall, const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void re_gpu_clear(); -int ** re_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success, double **host_quat); -int * re_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, double **host_quat); +int **re_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success, double **host_quat); +int *re_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success, double **host_quat); double re_gpu_bytes(); -enum{SPHERE_SPHERE,SPHERE_ELLIPSE,ELLIPSE_SPHERE,ELLIPSE_ELLIPSE}; +enum { SPHERE_SPHERE, SPHERE_ELLIPSE, ELLIPSE_SPHERE, ELLIPSE_ELLIPSE }; /* ---------------------------------------------------------------------- */ -PairRESquaredGPU::PairRESquaredGPU(LAMMPS *lmp) : PairRESquared(lmp), - gpu_mode(GPU_FORCE) +PairRESquaredGPU::PairRESquaredGPU(LAMMPS *lmp) : PairRESquared(lmp), gpu_mode(GPU_FORCE) { reinitflag = 0; avec = (AtomVecEllipsoid *) atom->style_match("ellipsoid"); - if (!avec) - error->all(FLERR,"Pair resquared/gpu requires atom style ellipsoid"); + if (!avec) error->all(FLERR, "Pair resquared/gpu requires atom style ellipsoid"); quat_nmax = 0; quat = nullptr; suffix_flag |= Suffix::GPU; @@ -91,7 +82,7 @@ PairRESquaredGPU::~PairRESquaredGPU() void PairRESquaredGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -105,7 +96,7 @@ void PairRESquaredGPU::compute(int eflag, int vflag) } AtomVecEllipsoid::Bonus *bonus = avec->bonus; int *ellipsoid = atom->ellipsoid; - for (int i=0; i -1) { quat[i][0] = bonus[qi].quat[0]; @@ -116,7 +107,7 @@ void PairRESquaredGPU::compute(int eflag, int vflag) } if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -125,26 +116,22 @@ void PairRESquaredGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = re_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success, quat); + firstneigh = + re_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success, quat); } else { inum = list->inum; numneigh = list->numneigh; firstneigh = list->firstneigh; - ilist = re_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - list->ilist, numneigh, firstneigh, eflag, vflag, - eflag_atom, vflag_atom, host_start, - cpu_time, success, quat); + ilist = re_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, list->ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, + success, quat); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); if (host_start < inum) { cpu_time = platform::walltime(); @@ -159,21 +146,20 @@ void PairRESquaredGPU::compute(int eflag, int vflag) void PairRESquaredGPU::init_style() { - if (!atom->ellipsoid_flag) - error->all(FLERR,"Pair resquared/gpu requires atom style ellipsoid"); + if (!atom->ellipsoid_flag) error->all(FLERR, "Pair resquared/gpu requires atom style ellipsoid"); // per-type shape precalculations // require that atom shapes are identical within each type // if shape = 0 for point particle, set shape = 1 as required by Gay-Berne for (int i = 1; i <= atom->ntypes; i++) { - if (!atom->shape_consistency(i,shape1[i][0],shape1[i][1],shape1[i][2])) - error->all(FLERR,"Pair resquared/gpu requires atoms with same type have same shape"); + if (!atom->shape_consistency(i, shape1[i][0], shape1[i][1], shape1[i][2])) + error->all(FLERR, "Pair resquared/gpu requires atoms with same type have same shape"); if (setwell[i]) { - shape2[i][0] = shape1[i][0]*shape1[i][0]; - shape2[i][1] = shape1[i][1]*shape1[i][1]; - shape2[i][2] = shape1[i][2]*shape1[i][2]; - lshape[i] = shape1[i][0]*shape1[i][1]*shape1[i][2]; + shape2[i][0] = shape1[i][0] * shape1[i][0]; + shape2[i][1] = shape1[i][1] * shape1[i][1]; + shape2[i][2] = shape1[i][2] * shape1[i][2]; + lshape[i] = shape1[i][0] * shape1[i][1] * shape1[i][2]; } } @@ -183,10 +169,9 @@ void PairRESquaredGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -195,22 +180,16 @@ void PairRESquaredGPU::init_style() double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = re_gpu_init(atom->ntypes+1, shape1, well, cutsq, sigma, - epsilon, form, lj1, lj2, lj3, lj4, offset, - force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + re_gpu_init(atom->ntypes + 1, shape1, well, cutsq, sigma, epsilon, form, lj1, lj2, lj3, lj4, + offset, force->special_lj, atom->nlocal, atom->nlocal + atom->nghost, mnf, + maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); quat_nmax = static_cast(1.1 * (atom->nlocal + atom->nghost)); memory->grow(quat, quat_nmax, 4, "pair:quat"); } @@ -220,20 +199,19 @@ void PairRESquaredGPU::init_style() double PairRESquaredGPU::memory_usage() { double bytes = Pair::memory_usage(); - return bytes + memory->usage(quat,quat_nmax)+re_gpu_bytes(); + return bytes + memory->usage(quat, quat_nmax) + re_gpu_bytes(); } /* ---------------------------------------------------------------------- */ -void PairRESquaredGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, +void PairRESquaredGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double evdwl,one_eng,rsq,r2inv,r6inv,forcelj,factor_lj; - double fforce[3],ttor[3],rtor[3],r12[3]; + int i, j, ii, jj, jnum, itype, jtype; + double evdwl, one_eng, rsq, r2inv, r6inv, forcelj, factor_lj; + double fforce[3], ttor[3], rtor[3], r12[3]; int *jlist; - RE2Vars wi,wj; + RE2Vars wi, wj; double **x = atom->x; double **f = atom->f; @@ -249,7 +227,7 @@ void PairRESquaredGPU::cpu_compute(int start, int inum, int eflag, // not a LJ sphere - if (lshape[itype] != 0.0) precompute_i(i,wi); + if (lshape[itype] != 0.0) precompute_i(i, wi); jlist = firstneigh[i]; jnum = numneigh[i]; @@ -261,10 +239,10 @@ void PairRESquaredGPU::cpu_compute(int start, int inum, int eflag, // r12 = center to center vector - r12[0] = x[j][0]-x[i][0]; - r12[1] = x[j][1]-x[i][1]; - r12[2] = x[j][2]-x[i][2]; - rsq = MathExtra::dot3(r12,r12); + r12[0] = x[j][0] - x[i][0]; + r12[1] = x[j][1] - x[i][1]; + r12[2] = x[j][2] - x[i][2]; + rsq = MathExtra::dot3(r12, r12); jtype = type[j]; // compute if less than cutoff @@ -272,39 +250,39 @@ void PairRESquaredGPU::cpu_compute(int start, int inum, int eflag, if (rsq < cutsq[itype][jtype]) { switch (form[itype][jtype]) { - case SPHERE_SPHERE: - r2inv = 1.0/rsq; - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - forcelj *= -r2inv; - if (eflag) one_eng = - r6inv*(r6inv*lj3[itype][jtype]-lj4[itype][jtype]) - - offset[itype][jtype]; - fforce[0] = r12[0]*forcelj; - fforce[1] = r12[1]*forcelj; - fforce[2] = r12[2]*forcelj; - break; + case SPHERE_SPHERE: + r2inv = 1.0 / rsq; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + forcelj *= -r2inv; + if (eflag) + one_eng = + r6inv * (r6inv * lj3[itype][jtype] - lj4[itype][jtype]) - offset[itype][jtype]; + fforce[0] = r12[0] * forcelj; + fforce[1] = r12[1] * forcelj; + fforce[2] = r12[2] * forcelj; + break; - case SPHERE_ELLIPSE: - precompute_i(j,wj); - one_eng = resquared_lj(j,i,wj,r12,rsq,fforce,rtor,false); - break; + case SPHERE_ELLIPSE: + precompute_i(j, wj); + one_eng = resquared_lj(j, i, wj, r12, rsq, fforce, rtor, false); + break; - case ELLIPSE_SPHERE: - one_eng = resquared_lj(i,j,wi,r12,rsq,fforce,ttor,true); - tor[i][0] += ttor[0]*factor_lj; - tor[i][1] += ttor[1]*factor_lj; - tor[i][2] += ttor[2]*factor_lj; - break; + case ELLIPSE_SPHERE: + one_eng = resquared_lj(i, j, wi, r12, rsq, fforce, ttor, true); + tor[i][0] += ttor[0] * factor_lj; + tor[i][1] += ttor[1] * factor_lj; + tor[i][2] += ttor[2] * factor_lj; + break; - default: - precompute_i(j,wj); - one_eng = resquared_analytic(i,j,wi,wj,r12,rsq,fforce,ttor,rtor); - tor[i][0] += ttor[0]*factor_lj; - tor[i][1] += ttor[1]*factor_lj; - tor[i][2] += ttor[2]*factor_lj; + default: + precompute_i(j, wj); + one_eng = resquared_analytic(i, j, wi, wj, r12, rsq, fforce, ttor, rtor); + tor[i][0] += ttor[0] * factor_lj; + tor[i][1] += ttor[1] * factor_lj; + tor[i][2] += ttor[2] * factor_lj; - break; + break; } fforce[0] *= factor_lj; @@ -314,10 +292,11 @@ void PairRESquaredGPU::cpu_compute(int start, int inum, int eflag, f[i][1] += fforce[1]; f[i][2] += fforce[2]; - if (eflag) evdwl = factor_lj*one_eng; + if (eflag) evdwl = factor_lj * one_eng; - if (evflag) ev_tally_xyz_full(i,evdwl,0.0,fforce[0],fforce[1], - fforce[2],-r12[0],-r12[1],-r12[2]); + if (evflag) + ev_tally_xyz_full(i, evdwl, 0.0, fforce[0], fforce[1], fforce[2], -r12[0], -r12[1], + -r12[2]); } } } diff --git a/src/GPU/pair_soft_gpu.cpp b/src/GPU/pair_soft_gpu.cpp index b2e491bd83..dc970858e5 100644 --- a/src/GPU/pair_soft_gpu.cpp +++ b/src/GPU/pair_soft_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,7 +24,6 @@ #include "gpu_extra.h" #include "math_const.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -35,28 +33,22 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int soft_gpu_init(const int ntypes, double **cutsq, double **prefactor, - double **cut, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen); -void soft_gpu_reinit(const int ntypes, double **cutsq, double **host_prefactor, - double **host_cut); +int soft_gpu_init(const int ntypes, double **cutsq, double **prefactor, double **cut, + double *special_lj, const int nlocal, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); +void soft_gpu_reinit(const int ntypes, double **cutsq, double **host_prefactor, double **host_cut); void soft_gpu_clear(); -int ** soft_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void soft_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success); +int **soft_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void soft_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success); double soft_gpu_bytes(); - using namespace MathConst; /* ---------------------------------------------------------------------- */ @@ -82,7 +74,7 @@ PairSoftGPU::~PairSoftGPU() void PairSoftGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -90,7 +82,7 @@ void PairSoftGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -99,28 +91,24 @@ void PairSoftGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = soft_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + soft_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - soft_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + soft_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - mcut = init_one(i,j); + mcut = init_one(i, j); mcut *= mcut; - if (mcut > maxcut) - maxcut = mcut; + if (mcut > maxcut) maxcut = mcut; cutsq[i][j] = cutsq[j][i] = mcut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -151,21 +138,15 @@ void PairSoftGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = soft_gpu_init(atom->ntypes+1, cutsq, prefactor, cut, - force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + soft_gpu_init(atom->ntypes + 1, cutsq, prefactor, cut, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -174,7 +155,7 @@ void PairSoftGPU::reinit() { Pair::reinit(); - soft_gpu_reinit(atom->ntypes+1, cutsq, prefactor, cut); + soft_gpu_reinit(atom->ntypes + 1, cutsq, prefactor, cut); } /* ---------------------------------------------------------------------- */ @@ -187,11 +168,12 @@ double PairSoftGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairSoftGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double r,rsq,arg,factor_lj; +void PairSoftGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double r, rsq, arg, factor_lj; int *jlist; double **x = atom->x; @@ -218,24 +200,24 @@ void PairSoftGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { r = sqrt(rsq); - arg = MY_PI*r/cut[itype][jtype]; - if (r > 0.0) fpair = factor_lj * prefactor[itype][jtype] * - sin(arg) * MY_PI/cut[itype][jtype]/r; - else fpair = 0.0; + arg = MY_PI * r / cut[itype][jtype]; + if (r > 0.0) + fpair = factor_lj * prefactor[itype][jtype] * sin(arg) * MY_PI / cut[itype][jtype] / r; + else + fpair = 0.0; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; - if (eflag) - evdwl = factor_lj * prefactor[itype][jtype] * (1.0+cos(arg)); + if (eflag) evdwl = factor_lj * prefactor[itype][jtype] * (1.0 + cos(arg)); - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_sw_gpu.cpp b/src/GPU/pair_sw_gpu.cpp index 69cafd2972..e79221fadd 100644 --- a/src/GPU/pair_sw_gpu.cpp +++ b/src/GPU/pair_sw_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "gpu_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,26 +32,21 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int sw_gpu_init(const int ntypes, const int inum, const int nall, - const int max_nbors, const double cell_size, int &gpu_mode, - FILE *screen, double **ncutsq, double **ncut, double **sigma, - double **powerp, double **powerq, double **sigma_gamma, - double **c1, double **c2, double **c3,double **c4, - double **c5, double **c6, double ***lambda_epsilon, - double ***costheta, const int *map, int ***e2param); +int sw_gpu_init(const int ntypes, const int inum, const int nall, const int max_nbors, + const double cell_size, int &gpu_mode, FILE *screen, double **ncutsq, double **ncut, + double **sigma, double **powerp, double **powerq, double **sigma_gamma, double **c1, + double **c2, double **c3, double **c4, double **c5, double **c6, + double ***lambda_epsilon, double ***costheta, const int *map, int ***e2param); void sw_gpu_clear(); -int ** sw_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void sw_gpu_compute(const int ago, const int nloc, const int nall, - const int ln, double **host_x, int *host_type, int *ilist, - int *numj, int **firstneigh, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, const double cpu_time, bool &success); +int **sw_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void sw_gpu_compute(const int ago, const int nloc, const int nall, const int ln, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, + const double cpu_time, bool &success); double sw_gpu_bytes(); #define MAXLINE 1024 @@ -79,15 +72,14 @@ PairSWGPU::PairSWGPU(LAMMPS *lmp) : PairSW(lmp), gpu_mode(GPU_FORCE) PairSWGPU::~PairSWGPU() { sw_gpu_clear(); - if (allocated) - memory->destroy(cutghost); + if (allocated) memory->destroy(cutghost); } /* ---------------------------------------------------------------------- */ void PairSWGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -95,7 +87,7 @@ void PairSWGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -104,28 +96,24 @@ void PairSWGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = sw_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + sw_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - sw_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum, - atom->x, atom->type, ilist, numneigh, firstneigh, eflag, - vflag, eflag_atom, vflag_atom, host_start, cpu_time, + sw_gpu_compute(neighbor->ago, inum, nall, inum + list->gnum, atom->x, atom->type, ilist, + numneigh, firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); } /* ---------------------------------------------------------------------- */ @@ -135,7 +123,7 @@ void PairSWGPU::allocate() PairSW::allocate(); int n = atom->ntypes; - memory->create(cutghost,n+1,n+1,"pair:cutghost"); + memory->create(cutghost, n + 1, n + 1, "pair:cutghost"); } /* ---------------------------------------------------------------------- @@ -146,8 +134,7 @@ void PairSWGPU::init_style() { double cell_size = cutmax + neighbor->skin; - if (atom->tag_enable == 0) - error->all(FLERR,"Pair style sw/gpu requires atom IDs"); + if (atom->tag_enable == 0) error->all(FLERR, "Pair style sw/gpu requires atom IDs"); double **c1, **c2, **c3, **c4, **c5, **c6; double **ncutsq, **ncut, **sigma, **powerp, **powerq, **sigma_gamma; @@ -209,10 +196,9 @@ void PairSWGPU::init_style() } int mnf = 5e-2 * neighbor->oneatom; - int success = sw_gpu_init(tp1, atom->nlocal, atom->nlocal+atom->nghost, mnf, - cell_size, gpu_mode, screen, ncutsq, ncut, sigma, - powerp, powerq, sigma_gamma, c1, c2, c3, c4, c5, - c6, lambda_epsilon, costheta, map, elem3param); + int success = sw_gpu_init(tp1, atom->nlocal, atom->nlocal + atom->nghost, mnf, cell_size, + gpu_mode, screen, ncutsq, ncut, sigma, powerp, powerq, sigma_gamma, c1, + c2, c3, c4, c5, c6, lambda_epsilon, costheta, map, elem3param); memory->destroy(ncutsq); memory->destroy(ncut); @@ -229,18 +215,13 @@ void PairSWGPU::init_style() memory->destroy(lambda_epsilon); memory->destroy(costheta); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; - } - if (comm->cutghostuser < (2.0*cutmax + neighbor->skin)) { - comm->cutghostuser=2.0*cutmax + neighbor->skin; - if (comm->me == 0) - error->warning(FLERR,"Increasing communication cutoff for GPU style"); + if (gpu_mode == GPU_FORCE) + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); + if (comm->cutghostuser < (2.0 * cutmax + neighbor->skin)) { + comm->cutghostuser = 2.0 * cutmax + neighbor->skin; + if (comm->me == 0) error->warning(FLERR, "Increasing communication cutoff for GPU style"); } } @@ -250,10 +231,9 @@ void PairSWGPU::init_style() double PairSWGPU::init_one(int i, int j) { - if (setflag[i][j] == 0) error->all(FLERR,"All pair coeffs are not set"); + if (setflag[i][j] == 0) error->all(FLERR, "All pair coeffs are not set"); cutghost[i][j] = cutmax; cutghost[j][i] = cutmax; return cutmax; } - diff --git a/src/GPU/pair_table_gpu.cpp b/src/GPU/pair_table_gpu.cpp index 7a7881993d..8331e28010 100644 --- a/src/GPU/pair_table_gpu.cpp +++ b/src/GPU/pair_table_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,7 +24,6 @@ #include "gpu_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -35,31 +33,25 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int table_gpu_init(const int ntypes, double **cutsq, - double ***host_table_coeffs, double **host_table_data, - double *special_lj, const int nlocal, const int nall, - const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen, - int tabstyle, int ntables, int tablength); +int table_gpu_init(const int ntypes, double **cutsq, double ***host_table_coeffs, + double **host_table_data, double *special_lj, const int nlocal, const int nall, + const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, + FILE *screen, int tabstyle, int ntables, int tablength); void table_gpu_clear(); -int ** table_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success); -void table_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **table_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void table_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double table_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairTableGPU::PairTableGPU(LAMMPS *lmp) : PairTable(lmp), - gpu_mode(GPU_FORCE) +PairTableGPU::PairTableGPU(LAMMPS *lmp) : PairTable(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -81,7 +73,7 @@ PairTableGPU::~PairTableGPU() void PairTableGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -89,7 +81,7 @@ void PairTableGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -98,28 +90,24 @@ void PairTableGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = table_gpu_compute_n(neighbor->ago, inum, nall, atom->x, - atom->type, sublo, subhi, - atom->tag, atom->nspecial, atom->special, - eflag, vflag, eflag_atom, vflag_atom, - host_start, &ilist, &numneigh, cpu_time, - success); + firstneigh = + table_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - table_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + table_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -155,7 +142,7 @@ void PairTableGPU::init_style() // pack tables and send them to device double ***table_coeffs = nullptr; double **table_data = nullptr; - memory->create(table_coeffs, ntypes+1, ntypes+1, 6, "table:coeffs"); + memory->create(table_coeffs, ntypes + 1, ntypes + 1, 6, "table:coeffs"); Table *tb; for (int i = 1; i <= atom->ntypes; i++) @@ -171,67 +158,60 @@ void PairTableGPU::init_style() } if (tabstyle != BITMAP) { - memory->create(table_data, ntables, 6*tablength, "table:data"); + memory->create(table_data, ntables, 6 * tablength, "table:data"); for (int n = 0; n < ntables; n++) { tb = &tables[n]; if (tabstyle == LOOKUP) { - for (int k = 0; ke[k]; - table_data[n][6*k+2] = tb->f[k]; + for (int k = 0; k < tablength - 1; k++) { + table_data[n][6 * k + 1] = tb->e[k]; + table_data[n][6 * k + 2] = tb->f[k]; } } else if (tabstyle == LINEAR) { - for (int k = 0; krsq[k]; - table_data[n][6*k+1] = tb->e[k]; - table_data[n][6*k+2] = tb->f[k]; - if (kde[k]; - table_data[n][6*k+4] = tb->df[k]; + for (int k = 0; k < tablength; k++) { + table_data[n][6 * k + 0] = tb->rsq[k]; + table_data[n][6 * k + 1] = tb->e[k]; + table_data[n][6 * k + 2] = tb->f[k]; + if (k < tablength - 1) { + table_data[n][6 * k + 3] = tb->de[k]; + table_data[n][6 * k + 4] = tb->df[k]; } - } + } } else if (tabstyle == SPLINE) { - for (int k = 0; krsq[k]; - table_data[n][6*k+1] = tb->e[k]; - table_data[n][6*k+2] = tb->f[k]; - table_data[n][6*k+3] = tb->e2[k]; - table_data[n][6*k+4] = tb->f2[k]; + for (int k = 0; k < tablength; k++) { + table_data[n][6 * k + 0] = tb->rsq[k]; + table_data[n][6 * k + 1] = tb->e[k]; + table_data[n][6 * k + 2] = tb->f[k]; + table_data[n][6 * k + 3] = tb->e2[k]; + table_data[n][6 * k + 4] = tb->f2[k]; } } } } else { int ntable = 1 << tablength; - memory->create(table_data, ntables, 6*ntable, "table:data"); + memory->create(table_data, ntables, 6 * ntable, "table:data"); for (int n = 0; n < ntables; n++) { tb = &tables[n]; - for (int k = 0; krsq[k]; - table_data[n][6*k+1] = tb->e[k]; - table_data[n][6*k+2] = tb->f[k]; - table_data[n][6*k+3] = tb->de[k]; - table_data[n][6*k+4] = tb->df[k]; - table_data[n][6*k+5] = tb->drsq[k]; + for (int k = 0; k < ntable; k++) { + table_data[n][6 * k + 0] = tb->rsq[k]; + table_data[n][6 * k + 1] = tb->e[k]; + table_data[n][6 * k + 2] = tb->f[k]; + table_data[n][6 * k + 3] = tb->de[k]; + table_data[n][6 * k + 4] = tb->df[k]; + table_data[n][6 * k + 5] = tb->drsq[k]; } } } - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = table_gpu_init(atom->ntypes+1, cutsq, table_coeffs, table_data, - force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen, tabstyle, ntables, - tablength); - GPU_EXTRA::check_flag(success,error,world); + int success = table_gpu_init(atom->ntypes + 1, cutsq, table_coeffs, table_data, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, + cell_size, gpu_mode, screen, tabstyle, ntables, tablength); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); memory->destroy(table_coeffs); memory->destroy(table_data); } @@ -246,11 +226,12 @@ double PairTableGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairTableGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype,itable; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,factor_lj,fraction,value,a,b; +void PairTableGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype, itable; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, factor_lj, fraction, value, a, b; int *jlist; Table *tb; @@ -281,62 +262,58 @@ void PairTableGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { tb = &tables[tabindex[itype][jtype]]; - if (rsq < tb->innersq) - error->one(FLERR,"Pair distance < table inner cutoff"); + if (rsq < tb->innersq) error->one(FLERR, "Pair distance < table inner cutoff"); if (tabstyle == LOOKUP) { - itable = static_cast ((rsq - tb->innersq) * tb->invdelta); - if (itable >= tlm1) - error->one(FLERR,"Pair distance > table outer cutoff"); + itable = static_cast((rsq - tb->innersq) * tb->invdelta); + if (itable >= tlm1) error->one(FLERR, "Pair distance > table outer cutoff"); fpair = factor_lj * tb->f[itable]; } else if (tabstyle == LINEAR) { - itable = static_cast ((rsq - tb->innersq) * tb->invdelta); - if (itable >= tlm1) - error->one(FLERR,"Pair distance > table outer cutoff"); + itable = static_cast((rsq - tb->innersq) * tb->invdelta); + if (itable >= tlm1) error->one(FLERR, "Pair distance > table outer cutoff"); fraction = (rsq - tb->rsq[itable]) * tb->invdelta; - value = tb->f[itable] + fraction*tb->df[itable]; + value = tb->f[itable] + fraction * tb->df[itable]; fpair = factor_lj * value; } else if (tabstyle == SPLINE) { - itable = static_cast ((rsq - tb->innersq) * tb->invdelta); - if (itable >= tlm1) - error->one(FLERR,"Pair distance > table outer cutoff"); + itable = static_cast((rsq - tb->innersq) * tb->invdelta); + if (itable >= tlm1) error->one(FLERR, "Pair distance > table outer cutoff"); b = (rsq - tb->rsq[itable]) * tb->invdelta; a = 1.0 - b; - value = a * tb->f[itable] + b * tb->f[itable+1] + - ((a*a*a-a)*tb->f2[itable] + (b*b*b-b)*tb->f2[itable+1]) * - tb->deltasq6; + value = a * tb->f[itable] + b * tb->f[itable + 1] + + ((a * a * a - a) * tb->f2[itable] + (b * b * b - b) * tb->f2[itable + 1]) * + tb->deltasq6; fpair = factor_lj * value; } else { rsq_lookup.f = rsq; itable = rsq_lookup.i & tb->nmask; itable >>= tb->nshiftbits; fraction = (rsq_lookup.f - tb->rsq[itable]) * tb->drsq[itable]; - value = tb->f[itable] + fraction*tb->df[itable]; + value = tb->f[itable] + fraction * tb->df[itable]; fpair = factor_lj * value; } - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { if (tabstyle == LOOKUP) evdwl = tb->e[itable]; else if (tabstyle == LINEAR || tabstyle == BITMAP) - evdwl = tb->e[itable] + fraction*tb->de[itable]; + evdwl = tb->e[itable] + fraction * tb->de[itable]; else - evdwl = a * tb->e[itable] + b * tb->e[itable+1] + - ((a*a*a-a)*tb->e2[itable] + (b*b*b-b)*tb->e2[itable+1]) * - tb->deltasq6; + evdwl = a * tb->e[itable] + b * tb->e[itable + 1] + + ((a * a * a - a) * tb->e2[itable] + (b * b * b - b) * tb->e2[itable + 1]) * + tb->deltasq6; evdwl *= factor_lj; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_tersoff_gpu.cpp b/src/GPU/pair_tersoff_gpu.cpp index 891b5051e6..ad4275cfac 100644 --- a/src/GPU/pair_tersoff_gpu.cpp +++ b/src/GPU/pair_tersoff_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,42 +24,34 @@ #include "force.h" #include "gpu_extra.h" #include "memory.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" +#include "neighbor.h" #include "suffix.h" using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int tersoff_gpu_init(const int ntypes, const int inum, const int nall, - const int max_nbors, const double cell_size, int &gpu_mode, - FILE *screen, int* host_map, const int nelements, - int*** host_elem3param, const int nparams, - const double* ts_lam1, const double* ts_lam2, - const double* ts_lam3, const double* ts_powermint, - const double* ts_biga, const double* ts_bigb, - const double* ts_bigr, const double* ts_bigd, - const double* ts_c1, const double* ts_c2, - const double* ts_c3, const double* ts_c4, - const double* ts_c, const double* ts_d, - const double* ts_h, const double* ts_gamma, - const double* ts_beta, const double* ts_powern, - const double* ts_cutsq); +int tersoff_gpu_init(const int ntypes, const int inum, const int nall, const int max_nbors, + const double cell_size, int &gpu_mode, FILE *screen, int *host_map, + const int nelements, int ***host_elem3param, const int nparams, + const double *ts_lam1, const double *ts_lam2, const double *ts_lam3, + const double *ts_powermint, const double *ts_biga, const double *ts_bigb, + const double *ts_bigr, const double *ts_bigd, const double *ts_c1, + const double *ts_c2, const double *ts_c3, const double *ts_c4, + const double *ts_c, const double *ts_d, const double *ts_h, + const double *ts_gamma, const double *ts_beta, const double *ts_powern, + const double *ts_cutsq); void tersoff_gpu_clear(); -int ** tersoff_gpu_compute_n(const int ago, const int inum_full, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success); -void tersoff_gpu_compute(const int ago, const int nlocal, const int nall, - const int nlist, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, const double cpu_time, bool &success); +int **tersoff_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success); +void tersoff_gpu_compute(const int ago, const int nlocal, const int nall, const int nlist, + double **host_x, int *host_type, int *ilist, int *numj, int **firstneigh, + const bool eflag, const bool vflag, const bool eatom, const bool vatom, + int &host_start, const double cpu_time, bool &success); double tersoff_gpu_bytes(); #define MAXLINE 1024 @@ -85,15 +76,14 @@ PairTersoffGPU::PairTersoffGPU(LAMMPS *lmp) : PairTersoff(lmp), gpu_mode(GPU_FOR PairTersoffGPU::~PairTersoffGPU() { tersoff_gpu_clear(); - if (allocated) - memory->destroy(cutghost); + if (allocated) memory->destroy(cutghost); } /* ---------------------------------------------------------------------- */ void PairTersoffGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -101,7 +91,7 @@ void PairTersoffGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -110,28 +100,24 @@ void PairTersoffGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = tersoff_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + tersoff_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, eflag_atom, + vflag_atom, host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - tersoff_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum, - atom->x, atom->type, ilist, numneigh, firstneigh, eflag, - vflag, eflag_atom, vflag_atom, host_start, cpu_time, - success); + tersoff_gpu_compute(neighbor->ago, inum, nall, inum + list->gnum, atom->x, atom->type, ilist, + numneigh, firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, + cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); } /* ---------------------------------------------------------------------- */ @@ -141,7 +127,7 @@ void PairTersoffGPU::allocate() PairTersoff::allocate(); int n = atom->ntypes; - memory->create(cutghost,n+1,n+1,"pair:cutghost"); + memory->create(cutghost, n + 1, n + 1, "pair:cutghost"); } /* ---------------------------------------------------------------------- @@ -152,8 +138,7 @@ void PairTersoffGPU::init_style() { double cell_size = cutmax + neighbor->skin; - if (atom->tag_enable == 0) - error->all(FLERR,"Pair style tersoff/gpu requires atom IDs"); + if (atom->tag_enable == 0) error->all(FLERR, "Pair style tersoff/gpu requires atom IDs"); double *lam1, *lam2, *lam3, *powermint; double *biga, *bigb, *bigr, *bigd; @@ -166,25 +151,25 @@ void PairTersoffGPU::init_style() c = d = h = gamma = nullptr; beta = powern = _cutsq = nullptr; - memory->create(lam1,nparams,"pair:lam1"); - memory->create(lam2,nparams,"pair:lam2"); - memory->create(lam3,nparams,"pair:lam3"); - memory->create(powermint,nparams,"pair:powermint"); - memory->create(biga,nparams,"pair:biga"); - memory->create(bigb,nparams,"pair:bigb"); - memory->create(bigr,nparams,"pair:bigr"); - memory->create(bigd,nparams,"pair:bigd"); - memory->create(c1,nparams,"pair:c1"); - memory->create(c2,nparams,"pair:c2"); - memory->create(c3,nparams,"pair:c3"); - memory->create(c4,nparams,"pair:c4"); - memory->create(c,nparams,"pair:c"); - memory->create(d,nparams,"pair:d"); - memory->create(h,nparams,"pair:h"); - memory->create(gamma,nparams,"pair:gamma"); - memory->create(beta,nparams,"pair:beta"); - memory->create(powern,nparams,"pair:powern"); - memory->create(_cutsq,nparams,"pair:_cutsq"); + memory->create(lam1, nparams, "pair:lam1"); + memory->create(lam2, nparams, "pair:lam2"); + memory->create(lam3, nparams, "pair:lam3"); + memory->create(powermint, nparams, "pair:powermint"); + memory->create(biga, nparams, "pair:biga"); + memory->create(bigb, nparams, "pair:bigb"); + memory->create(bigr, nparams, "pair:bigr"); + memory->create(bigd, nparams, "pair:bigd"); + memory->create(c1, nparams, "pair:c1"); + memory->create(c2, nparams, "pair:c2"); + memory->create(c3, nparams, "pair:c3"); + memory->create(c4, nparams, "pair:c4"); + memory->create(c, nparams, "pair:c"); + memory->create(d, nparams, "pair:d"); + memory->create(h, nparams, "pair:h"); + memory->create(gamma, nparams, "pair:gamma"); + memory->create(beta, nparams, "pair:beta"); + memory->create(powern, nparams, "pair:powern"); + memory->create(_cutsq, nparams, "pair:_cutsq"); for (int i = 0; i < nparams; i++) { lam1[i] = params[i].lam1; @@ -209,13 +194,10 @@ void PairTersoffGPU::init_style() } int mnf = 5e-2 * neighbor->oneatom; - int success = tersoff_gpu_init(atom->ntypes+1, atom->nlocal, - atom->nlocal+atom->nghost, mnf, - cell_size, gpu_mode, screen, map, nelements, - elem3param, nparams, lam1, lam2, lam3, - powermint, biga, bigb, bigr, bigd, - c1, c2, c3, c4, c, d, h, gamma, - beta, powern, _cutsq); + int success = tersoff_gpu_init(atom->ntypes + 1, atom->nlocal, atom->nlocal + atom->nghost, mnf, + cell_size, gpu_mode, screen, map, nelements, elem3param, nparams, + lam1, lam2, lam3, powermint, biga, bigb, bigr, bigd, c1, c2, c3, + c4, c, d, h, gamma, beta, powern, _cutsq); memory->destroy(lam1); memory->destroy(lam2); @@ -237,18 +219,13 @@ void PairTersoffGPU::init_style() memory->destroy(powern); memory->destroy(_cutsq); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; - } - if (comm->cutghostuser < (2.0*cutmax + neighbor->skin)) { - comm->cutghostuser = 2.0*cutmax + neighbor->skin; - if (comm->me == 0) - error->warning(FLERR,"Increasing communication cutoff for GPU style"); + if (gpu_mode == GPU_FORCE) + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); + if (comm->cutghostuser < (2.0 * cutmax + neighbor->skin)) { + comm->cutghostuser = 2.0 * cutmax + neighbor->skin; + if (comm->me == 0) error->warning(FLERR, "Increasing communication cutoff for GPU style"); } } @@ -258,10 +235,9 @@ void PairTersoffGPU::init_style() double PairTersoffGPU::init_one(int i, int j) { - if (setflag[i][j] == 0) error->all(FLERR,"All pair coeffs are not set"); + if (setflag[i][j] == 0) error->all(FLERR, "All pair coeffs are not set"); cutghost[i][j] = cutmax; cutghost[j][i] = cutmax; return cutmax; } - diff --git a/src/GPU/pair_tersoff_mod_gpu.cpp b/src/GPU/pair_tersoff_mod_gpu.cpp index 703ce54ad1..3c1220771a 100644 --- a/src/GPU/pair_tersoff_mod_gpu.cpp +++ b/src/GPU/pair_tersoff_mod_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "gpu_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,35 +32,33 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int tersoff_mod_gpu_init(const int ntypes, const int inum, const int nall, - const int max_nbors, const double cell_size, int &gpu_mode, FILE *screen, - int* host_map, const int nelements, int*** host_elem3param, const int nparams, - const double* ts_lam1, const double* ts_lam2, const double* ts_lam3, - const double* ts_powermint, const double* ts_biga, const double* ts_bigb, - const double* ts_bigr, const double* ts_bigd, const double* ts_c1, - const double* ts_c2, const double* ts_c3, const double* ts_c4, - const double* ts_c5, const double* ts_h, const double* ts_beta, - const double* ts_powern, const double* ts_powern_del, - const double* ts_ca1, const double* ts_cutsq); +int tersoff_mod_gpu_init(const int ntypes, const int inum, const int nall, const int max_nbors, + const double cell_size, int &gpu_mode, FILE *screen, int *host_map, + const int nelements, int ***host_elem3param, const int nparams, + const double *ts_lam1, const double *ts_lam2, const double *ts_lam3, + const double *ts_powermint, const double *ts_biga, const double *ts_bigb, + const double *ts_bigr, const double *ts_bigd, const double *ts_c1, + const double *ts_c2, const double *ts_c3, const double *ts_c4, + const double *ts_c5, const double *ts_h, const double *ts_beta, + const double *ts_powern, const double *ts_powern_del, const double *ts_ca1, + const double *ts_cutsq); void tersoff_mod_gpu_clear(); -int ** tersoff_mod_gpu_compute_n(const int ago, const int inum_full, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success); -void tersoff_mod_gpu_compute(const int ago, const int nlocal, const int nall, - const int nlist, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, const double cpu_time, bool &success); +int **tersoff_mod_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, + int &host_start, int **ilist, int **jnum, const double cpu_time, + bool &success); +void tersoff_mod_gpu_compute(const int ago, const int nlocal, const int nall, const int nlist, + double **host_x, int *host_type, int *ilist, int *numj, + int **firstneigh, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, const double cpu_time, + bool &success); double tersoff_mod_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairTersoffMODGPU::PairTersoffMODGPU(LAMMPS *lmp) : PairTersoffMOD(lmp), - gpu_mode(GPU_FORCE) +PairTersoffMODGPU::PairTersoffMODGPU(LAMMPS *lmp) : PairTersoffMOD(lmp), gpu_mode(GPU_FORCE) { cpu_time = 0.0; suffix_flag |= Suffix::GPU; @@ -79,15 +75,14 @@ PairTersoffMODGPU::PairTersoffMODGPU(LAMMPS *lmp) : PairTersoffMOD(lmp), PairTersoffMODGPU::~PairTersoffMODGPU() { tersoff_mod_gpu_clear(); - if (allocated) - memory->destroy(cutghost); + if (allocated) memory->destroy(cutghost); } /* ---------------------------------------------------------------------- */ void PairTersoffMODGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -95,7 +90,7 @@ void PairTersoffMODGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -104,28 +99,24 @@ void PairTersoffMODGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = tersoff_mod_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = tersoff_mod_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, + subhi, atom->tag, atom->nspecial, atom->special, eflag, + vflag, eflag_atom, vflag_atom, host_start, &ilist, + &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - tersoff_mod_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum, - atom->x, atom->type, ilist, numneigh, firstneigh, eflag, - vflag, eflag_atom, vflag_atom, host_start, cpu_time, - success); + tersoff_mod_gpu_compute(neighbor->ago, inum, nall, inum + list->gnum, atom->x, atom->type, + ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, vflag_atom, + host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); } /* ---------------------------------------------------------------------- */ @@ -135,7 +126,7 @@ void PairTersoffMODGPU::allocate() PairTersoffMOD::allocate(); int n = atom->ntypes; - memory->create(cutghost,n+1,n+1,"pair:cutghost"); + memory->create(cutghost, n + 1, n + 1, "pair:cutghost"); } /* ---------------------------------------------------------------------- @@ -146,8 +137,7 @@ void PairTersoffMODGPU::init_style() { double cell_size = cutmax + neighbor->skin; - if (atom->tag_enable == 0) - error->all(FLERR,"Pair style tersoff/mod/gpu requires atom IDs"); + if (atom->tag_enable == 0) error->all(FLERR, "Pair style tersoff/mod/gpu requires atom IDs"); double *lam1, *lam2, *lam3, *powermint; double *biga, *bigb, *bigr, *bigd; @@ -159,25 +149,25 @@ void PairTersoffMODGPU::init_style() c1 = c2 = c3 = c4 = c5 = h = nullptr; beta = powern = _cutsq = nullptr; - memory->create(lam1,nparams,"pair:lam1"); - memory->create(lam2,nparams,"pair:lam2"); - memory->create(lam3,nparams,"pair:lam3"); - memory->create(powermint,nparams,"pair:powermint"); - memory->create(biga,nparams,"pair:biga"); - memory->create(bigb,nparams,"pair:bigb"); - memory->create(bigr,nparams,"pair:bigr"); - memory->create(bigd,nparams,"pair:bigd"); - memory->create(c1,nparams,"pair:c1"); - memory->create(c2,nparams,"pair:c2"); - memory->create(c3,nparams,"pair:c3"); - memory->create(c4,nparams,"pair:c4"); - memory->create(c5,nparams,"pair:c5"); - memory->create(h,nparams,"pair:h"); - memory->create(beta,nparams,"pair:beta"); - memory->create(powern,nparams,"pair:powern"); - memory->create(powern_del,nparams,"pair:powern_del"); - memory->create(ca1,nparams,"pair:ca1"); - memory->create(_cutsq,nparams,"pair:_cutsq"); + memory->create(lam1, nparams, "pair:lam1"); + memory->create(lam2, nparams, "pair:lam2"); + memory->create(lam3, nparams, "pair:lam3"); + memory->create(powermint, nparams, "pair:powermint"); + memory->create(biga, nparams, "pair:biga"); + memory->create(bigb, nparams, "pair:bigb"); + memory->create(bigr, nparams, "pair:bigr"); + memory->create(bigd, nparams, "pair:bigd"); + memory->create(c1, nparams, "pair:c1"); + memory->create(c2, nparams, "pair:c2"); + memory->create(c3, nparams, "pair:c3"); + memory->create(c4, nparams, "pair:c4"); + memory->create(c5, nparams, "pair:c5"); + memory->create(h, nparams, "pair:h"); + memory->create(beta, nparams, "pair:beta"); + memory->create(powern, nparams, "pair:powern"); + memory->create(powern_del, nparams, "pair:powern_del"); + memory->create(ca1, nparams, "pair:ca1"); + memory->create(_cutsq, nparams, "pair:_cutsq"); for (int i = 0; i < nparams; i++) { lam1[i] = params[i].lam1; @@ -202,13 +192,10 @@ void PairTersoffMODGPU::init_style() } int mnf = 5e-2 * neighbor->oneatom; - int success = tersoff_mod_gpu_init(atom->ntypes+1, atom->nlocal, - atom->nlocal+atom->nghost, mnf, - cell_size, gpu_mode, screen, map, nelements, - elem3param, nparams, lam1, lam2, lam3, - powermint, biga, bigb, bigr, bigd, - c1, c2, c3, c4, c5, h, beta, powern, - powern_del, ca1, _cutsq); + int success = tersoff_mod_gpu_init(atom->ntypes + 1, atom->nlocal, atom->nlocal + atom->nghost, + mnf, cell_size, gpu_mode, screen, map, nelements, elem3param, + nparams, lam1, lam2, lam3, powermint, biga, bigb, bigr, bigd, + c1, c2, c3, c4, c5, h, beta, powern, powern_del, ca1, _cutsq); memory->destroy(lam1); memory->destroy(lam2); @@ -230,18 +217,13 @@ void PairTersoffMODGPU::init_style() memory->destroy(powern_del); memory->destroy(_cutsq); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; - } - if (comm->cutghostuser < (2.0*cutmax + neighbor->skin)) { - comm->cutghostuser = 2.0*cutmax + neighbor->skin; - if (comm->me == 0) - error->warning(FLERR,"Increasing communication cutoff for GPU style"); + if (gpu_mode == GPU_FORCE) + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); + if (comm->cutghostuser < (2.0 * cutmax + neighbor->skin)) { + comm->cutghostuser = 2.0 * cutmax + neighbor->skin; + if (comm->me == 0) error->warning(FLERR, "Increasing communication cutoff for GPU style"); } } @@ -251,10 +233,9 @@ void PairTersoffMODGPU::init_style() double PairTersoffMODGPU::init_one(int i, int j) { - if (setflag[i][j] == 0) error->all(FLERR,"All pair coeffs are not set"); + if (setflag[i][j] == 0) error->all(FLERR, "All pair coeffs are not set"); cutghost[i][j] = cutmax; cutghost[j][i] = cutmax; return cutmax; } - diff --git a/src/GPU/pair_tersoff_zbl_gpu.cpp b/src/GPU/pair_tersoff_zbl_gpu.cpp index a272815f94..c7b605ae0d 100644 --- a/src/GPU/pair_tersoff_zbl_gpu.cpp +++ b/src/GPU/pair_tersoff_zbl_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -34,42 +33,36 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int tersoff_zbl_gpu_init(const int ntypes, const int inum, const int nall, - const int max_nbors, const double cell_size, int &gpu_mode, - FILE *screen, int* host_map, const int nelements, - int*** host_elem3param, const int nparams, - const double* ts_lam1, const double* ts_lam2, - const double* ts_lam3, const double* ts_powermint, - const double* ts_biga, const double* ts_bigb, - const double* ts_bigr, const double* ts_bigd, - const double* ts_c1, const double* ts_c2, - const double* ts_c3, const double* ts_c4, - const double* ts_c, const double* ts_d, - const double* ts_h, const double* ts_gamma, - const double* ts_beta, const double* ts_powern, - const double* ts_Z_i, const double* ts_Z_j, - const double* ts_ZBLcut, const double* ts_ZBLexpscale, - const double global_e, const double global_a_0, - const double global_epsilon_0, const double* ts_cutsq); +int tersoff_zbl_gpu_init(const int ntypes, const int inum, const int nall, const int max_nbors, + const double cell_size, int &gpu_mode, FILE *screen, int *host_map, + const int nelements, int ***host_elem3param, const int nparams, + const double *ts_lam1, const double *ts_lam2, const double *ts_lam3, + const double *ts_powermint, const double *ts_biga, const double *ts_bigb, + const double *ts_bigr, const double *ts_bigd, const double *ts_c1, + const double *ts_c2, const double *ts_c3, const double *ts_c4, + const double *ts_c, const double *ts_d, const double *ts_h, + const double *ts_gamma, const double *ts_beta, const double *ts_powern, + const double *ts_Z_i, const double *ts_Z_j, const double *ts_ZBLcut, + const double *ts_ZBLexpscale, const double global_e, + const double global_a_0, const double global_epsilon_0, + const double *ts_cutsq); void tersoff_zbl_gpu_clear(); -int ** tersoff_zbl_gpu_compute_n(const int ago, const int inum_full, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, const double cpu_time, - bool &success); -void tersoff_zbl_gpu_compute(const int ago, const int nlocal, const int nall, - const int nlist, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, const bool eflag, - const bool vflag, const bool eatom, const bool vatom, - int &host_start, const double cpu_time, bool &success); +int **tersoff_zbl_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, + int &host_start, int **ilist, int **jnum, const double cpu_time, + bool &success); +void tersoff_zbl_gpu_compute(const int ago, const int nlocal, const int nall, const int nlist, + double **host_x, int *host_type, int *ilist, int *numj, + int **firstneigh, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, const double cpu_time, + bool &success); double tersoff_zbl_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairTersoffZBLGPU::PairTersoffZBLGPU(LAMMPS *lmp) : PairTersoffZBL(lmp), - gpu_mode(GPU_FORCE) +PairTersoffZBLGPU::PairTersoffZBLGPU(LAMMPS *lmp) : PairTersoffZBL(lmp), gpu_mode(GPU_FORCE) { cpu_time = 0.0; suffix_flag |= Suffix::GPU; @@ -86,15 +79,14 @@ PairTersoffZBLGPU::PairTersoffZBLGPU(LAMMPS *lmp) : PairTersoffZBL(lmp), PairTersoffZBLGPU::~PairTersoffZBLGPU() { tersoff_zbl_gpu_clear(); - if (allocated) - memory->destroy(cutghost); + if (allocated) memory->destroy(cutghost); } /* ---------------------------------------------------------------------- */ void PairTersoffZBLGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -102,7 +94,7 @@ void PairTersoffZBLGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -111,28 +103,24 @@ void PairTersoffZBLGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = tersoff_zbl_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = tersoff_zbl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, + subhi, atom->tag, atom->nspecial, atom->special, eflag, + vflag, eflag_atom, vflag_atom, host_start, &ilist, + &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - tersoff_zbl_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum, - atom->x, atom->type, ilist, numneigh, firstneigh, eflag, - vflag, eflag_atom, vflag_atom, host_start, cpu_time, - success); + tersoff_zbl_gpu_compute(neighbor->ago, inum, nall, inum + list->gnum, atom->x, atom->type, + ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, vflag_atom, + host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); } /* ---------------------------------------------------------------------- */ @@ -140,9 +128,9 @@ void PairTersoffZBLGPU::compute(int eflag, int vflag) void PairTersoffZBLGPU::allocate() { PairTersoffZBL::allocate(); - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(cutghost,n+1,n+1,"pair:cutghost"); + memory->create(cutghost, np1, np1, "pair:cutghost"); } /* ---------------------------------------------------------------------- @@ -153,8 +141,7 @@ void PairTersoffZBLGPU::init_style() { double cell_size = cutmax + neighbor->skin; - if (atom->tag_enable == 0) - error->all(FLERR,"Pair style tersoff/zbl/gpu requires atom IDs"); + if (atom->tag_enable == 0) error->all(FLERR, "Pair style tersoff/zbl/gpu requires atom IDs"); double *lam1, *lam2, *lam3, *powermint; double *biga, *bigb, *bigr, *bigd; @@ -167,29 +154,29 @@ void PairTersoffZBLGPU::init_style() c = d = h = gamma = nullptr; beta = powern = Z_i = Z_j = ZBLcut = ZBLexpscale = _cutsq = nullptr; - memory->create(lam1,nparams,"pair:lam1"); - memory->create(lam2,nparams,"pair:lam2"); - memory->create(lam3,nparams,"pair:lam3"); - memory->create(powermint,nparams,"pair:powermint"); - memory->create(biga,nparams,"pair:biga"); - memory->create(bigb,nparams,"pair:bigb"); - memory->create(bigr,nparams,"pair:bigr"); - memory->create(bigd,nparams,"pair:bigd"); - memory->create(c1,nparams,"pair:c1"); - memory->create(c2,nparams,"pair:c2"); - memory->create(c3,nparams,"pair:c3"); - memory->create(c4,nparams,"pair:c4"); - memory->create(c,nparams,"pair:c"); - memory->create(d,nparams,"pair:d"); - memory->create(h,nparams,"pair:h"); - memory->create(gamma,nparams,"pair:gamma"); - memory->create(beta,nparams,"pair:beta"); - memory->create(powern,nparams,"pair:powern"); - memory->create(Z_i,nparams,"pair:Z_i"); - memory->create(Z_j,nparams,"pair:Z_j"); - memory->create(ZBLcut,nparams,"pair:ZBLcut"); - memory->create(ZBLexpscale,nparams,"pair:ZBLexpscale"); - memory->create(_cutsq,nparams,"pair:_cutsq"); + memory->create(lam1, nparams, "pair:lam1"); + memory->create(lam2, nparams, "pair:lam2"); + memory->create(lam3, nparams, "pair:lam3"); + memory->create(powermint, nparams, "pair:powermint"); + memory->create(biga, nparams, "pair:biga"); + memory->create(bigb, nparams, "pair:bigb"); + memory->create(bigr, nparams, "pair:bigr"); + memory->create(bigd, nparams, "pair:bigd"); + memory->create(c1, nparams, "pair:c1"); + memory->create(c2, nparams, "pair:c2"); + memory->create(c3, nparams, "pair:c3"); + memory->create(c4, nparams, "pair:c4"); + memory->create(c, nparams, "pair:c"); + memory->create(d, nparams, "pair:d"); + memory->create(h, nparams, "pair:h"); + memory->create(gamma, nparams, "pair:gamma"); + memory->create(beta, nparams, "pair:beta"); + memory->create(powern, nparams, "pair:powern"); + memory->create(Z_i, nparams, "pair:Z_i"); + memory->create(Z_j, nparams, "pair:Z_j"); + memory->create(ZBLcut, nparams, "pair:ZBLcut"); + memory->create(ZBLexpscale, nparams, "pair:ZBLexpscale"); + memory->create(_cutsq, nparams, "pair:_cutsq"); for (int i = 0; i < nparams; i++) { lam1[i] = params[i].lam1; @@ -218,14 +205,11 @@ void PairTersoffZBLGPU::init_style() } int mnf = 5e-2 * neighbor->oneatom; - int success = tersoff_zbl_gpu_init(atom->ntypes+1, atom->nlocal, - atom->nlocal+atom->nghost, mnf, - cell_size, gpu_mode, screen, map, nelements, - elem3param, nparams, lam1, lam2, lam3, - powermint, biga, bigb, bigr, bigd, - c1, c2, c3, c4, c, d, h, gamma, - beta, powern, Z_i, Z_j, ZBLcut, ZBLexpscale, - global_e, global_a_0, global_epsilon_0, _cutsq); + int success = tersoff_zbl_gpu_init(atom->ntypes + 1, atom->nlocal, atom->nlocal + atom->nghost, + mnf, cell_size, gpu_mode, screen, map, nelements, elem3param, + nparams, lam1, lam2, lam3, powermint, biga, bigb, bigr, bigd, + c1, c2, c3, c4, c, d, h, gamma, beta, powern, Z_i, Z_j, ZBLcut, + ZBLexpscale, global_e, global_a_0, global_epsilon_0, _cutsq); memory->destroy(lam1); memory->destroy(lam2); @@ -251,18 +235,13 @@ void PairTersoffZBLGPU::init_style() memory->destroy(ZBLexpscale); memory->destroy(_cutsq); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; - } - if (comm->cutghostuser < (2.0*cutmax + neighbor->skin)) { - comm->cutghostuser = 2.0*cutmax + neighbor->skin; - if (comm->me == 0) - error->warning(FLERR,"Increasing communication cutoff for GPU style"); + if (gpu_mode == GPU_FORCE) + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); + if (comm->cutghostuser < (2.0 * cutmax + neighbor->skin)) { + comm->cutghostuser = 2.0 * cutmax + neighbor->skin; + if (comm->me == 0) error->warning(FLERR, "Increasing communication cutoff for GPU style"); } } @@ -272,10 +251,9 @@ void PairTersoffZBLGPU::init_style() double PairTersoffZBLGPU::init_one(int i, int j) { - if (setflag[i][j] == 0) error->all(FLERR,"All pair coeffs are not set"); + if (setflag[i][j] == 0) error->all(FLERR, "All pair coeffs are not set"); cutghost[i][j] = cutmax; cutghost[j][i] = cutmax; return cutmax; } - diff --git a/src/GPU/pair_ufm_gpu.cpp b/src/GPU/pair_ufm_gpu.cpp index 5d8a2068e1..96f034b91d 100644 --- a/src/GPU/pair_ufm_gpu.cpp +++ b/src/GPU/pair_ufm_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* -*- c++ -*- ---------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -36,27 +34,23 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ufml_gpu_init(const int ntypes, double **cutsq, double **host_uf1, - double **host_uf2, double **host_uf3, - double **offset, double *special_lj, const int nlocal, - const int nall, const int max_nbors, const int maxspecial, - const double cell_size, int &gpu_mode, FILE *screen); +int ufml_gpu_init(const int ntypes, double **cutsq, double **host_uf1, double **host_uf2, + double **host_uf3, double **offset, double *special_lj, const int nlocal, + const int nall, const int max_nbors, const int maxspecial, const double cell_size, + int &gpu_mode, FILE *screen); -void ufml_gpu_reinit(const int ntypes, double **cutsq, double **host_uf1, - double **host_uf2, double **host_uf3, double **offset); +void ufml_gpu_reinit(const int ntypes, double **cutsq, double **host_uf1, double **host_uf2, + double **host_uf3, double **offset); void ufml_gpu_clear(); -int ** ufml_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void ufml_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **ufml_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void ufml_gpu_compute(const int ago, const int inum, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double ufml_gpu_bytes(); @@ -83,7 +77,7 @@ PairUFMGPU::~PairUFMGPU() void PairUFMGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -91,7 +85,7 @@ void PairUFMGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -100,28 +94,24 @@ void PairUFMGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ufml_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + ufml_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ufml_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + ufml_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -154,21 +142,15 @@ void PairUFMGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ufml_gpu_init(atom->ntypes+1, cutsq, uf1, uf2, uf3, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + ufml_gpu_init(atom->ntypes + 1, cutsq, uf1, uf2, uf3, offset, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -177,7 +159,7 @@ void PairUFMGPU::reinit() { Pair::reinit(); - ufml_gpu_reinit(atom->ntypes+1, cutsq, uf1, uf2, uf3, offset); + ufml_gpu_reinit(atom->ntypes + 1, cutsq, uf1, uf2, uf3, offset); } /* ---------------------------------------------------------------------- */ @@ -190,11 +172,12 @@ double PairUFMGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairUFMGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,expuf,factor_lj; +void PairUFMGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, expuf, factor_lj; int *jlist; double **x = atom->x; @@ -202,7 +185,6 @@ void PairUFMGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *type = atom->type; double *special_lj = force->special_lj; - // loop over neighbors of my atoms for (ii = start; ii < inum; ii++) { @@ -222,22 +204,22 @@ void PairUFMGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - expuf = exp(- rsq * uf2[itype][jtype]); - fpair = factor_lj * uf1[itype][jtype] * expuf /(1.0 - expuf); + expuf = exp(-rsq * uf2[itype][jtype]); + fpair = factor_lj * uf1[itype][jtype] * expuf / (1.0 - expuf); - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { evdwl = -factor_lj * uf3[itype][jtype] * log(1.0 - expuf) - offset[itype][jtype]; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_vashishta_gpu.cpp b/src/GPU/pair_vashishta_gpu.cpp index cc3ed487e4..5b517b613c 100644 --- a/src/GPU/pair_vashishta_gpu.cpp +++ b/src/GPU/pair_vashishta_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "gpu_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,33 +32,25 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int vashishta_gpu_init(const int ntypes, const int inum, const int nall, - const int max_nbors, const double cell_size, - int &gpu_mode, FILE *screen, int* host_map, - const int nelements, int*** host_elem3param, - const int nparams, const double* cutsq, const double* r0, - const double* gamma, const double* eta, - const double* lam1inv, const double* lam4inv, - const double* zizj, const double* mbigd, - const double* dvrc, const double* big6w, - const double* heta, const double* bigh, - const double* bigw, const double* c0, - const double* costheta, const double* bigb, - const double* big2b, const double* bigc); +int vashishta_gpu_init(const int ntypes, const int inum, const int nall, const int max_nbors, + const double cell_size, int &gpu_mode, FILE *screen, int *host_map, + const int nelements, int ***host_elem3param, const int nparams, + const double *cutsq, const double *r0, const double *gamma, + const double *eta, const double *lam1inv, const double *lam4inv, + const double *zizj, const double *mbigd, const double *dvrc, + const double *big6w, const double *heta, const double *bigh, + const double *bigw, const double *c0, const double *costheta, + const double *bigb, const double *big2b, const double *bigc); void vashishta_gpu_clear(); -int ** vashishta_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void vashishta_gpu_compute(const int ago, const int nloc, const int nall, - const int ln, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success); +int **vashishta_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success); +void vashishta_gpu_compute(const int ago, const int nloc, const int nall, const int ln, + double **host_x, int *host_type, int *ilist, int *numj, int **firstneigh, + const bool eflag, const bool vflag, const bool eatom, const bool vatom, + int &host_start, const double cpu_time, bool &success); double vashishta_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -84,15 +74,14 @@ PairVashishtaGPU::PairVashishtaGPU(LAMMPS *lmp) : PairVashishta(lmp), gpu_mode(G PairVashishtaGPU::~PairVashishtaGPU() { vashishta_gpu_clear(); - if (allocated) - memory->destroy(cutghost); + if (allocated) memory->destroy(cutghost); } /* ---------------------------------------------------------------------- */ void PairVashishtaGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -100,7 +89,7 @@ void PairVashishtaGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -109,40 +98,34 @@ void PairVashishtaGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = vashishta_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + vashishta_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, eflag_atom, + vflag_atom, host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - vashishta_gpu_compute(neighbor->ago, inum, nall, inum+list->gnum, - atom->x, atom->type, ilist, numneigh, firstneigh, eflag, - vflag, eflag_atom, vflag_atom, host_start, cpu_time, - success); + vashishta_gpu_compute(neighbor->ago, inum, nall, inum + list->gnum, atom->x, atom->type, ilist, + numneigh, firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, + cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); } /* ---------------------------------------------------------------------- */ void PairVashishtaGPU::allocate() { - if (!allocated) { - PairVashishta::allocate(); - } + if (!allocated) { PairVashishta::allocate(); } int n = atom->ntypes; - memory->create(cutghost,n+1,n+1,"pair:cutghost"); + memory->create(cutghost, n + 1, n + 1, "pair:cutghost"); gpu_allocated = true; } @@ -154,8 +137,7 @@ void PairVashishtaGPU::init_style() { double cell_size = cutmax + neighbor->skin; - if (atom->tag_enable == 0) - error->all(FLERR,"Pair style vashishta/gpu requires atom IDs"); + if (atom->tag_enable == 0) error->all(FLERR, "Pair style vashishta/gpu requires atom IDs"); double *cutsq, *r0, *gamma, *eta; double *lam1inv, *lam4inv, *zizj, *mbigd; @@ -169,24 +151,24 @@ void PairVashishtaGPU::init_style() bigw = c0 = costheta = bigb = nullptr; big2b = bigc = nullptr; - memory->create(cutsq,nparams,"pair:cutsq"); - memory->create(r0,nparams,"pair:r0"); - memory->create(gamma,nparams,"pair:gamma"); - memory->create(eta,nparams,"pair:eta"); - memory->create(lam1inv,nparams,"pair:lam1inv"); - memory->create(lam4inv,nparams,"pair:lam4inv"); - memory->create(zizj,nparams,"pair:zizj"); - memory->create(mbigd,nparams,"pair:mbigd"); - memory->create(dvrc,nparams,"pair:dvrc"); - memory->create(big6w,nparams,"pair:big6w"); - memory->create(heta,nparams,"pair:heta"); - memory->create(bigh,nparams,"pair:bigh"); - memory->create(bigw,nparams,"pair:bigw"); - memory->create(c0,nparams,"pair:c0"); - memory->create(costheta,nparams,"pair:costheta"); - memory->create(bigb,nparams,"pair:bigb"); - memory->create(big2b,nparams,"pair:big2b"); - memory->create(bigc,nparams,"pair:bigc"); + memory->create(cutsq, nparams, "pair:cutsq"); + memory->create(r0, nparams, "pair:r0"); + memory->create(gamma, nparams, "pair:gamma"); + memory->create(eta, nparams, "pair:eta"); + memory->create(lam1inv, nparams, "pair:lam1inv"); + memory->create(lam4inv, nparams, "pair:lam4inv"); + memory->create(zizj, nparams, "pair:zizj"); + memory->create(mbigd, nparams, "pair:mbigd"); + memory->create(dvrc, nparams, "pair:dvrc"); + memory->create(big6w, nparams, "pair:big6w"); + memory->create(heta, nparams, "pair:heta"); + memory->create(bigh, nparams, "pair:bigh"); + memory->create(bigw, nparams, "pair:bigw"); + memory->create(c0, nparams, "pair:c0"); + memory->create(costheta, nparams, "pair:costheta"); + memory->create(bigb, nparams, "pair:bigb"); + memory->create(big2b, nparams, "pair:big2b"); + memory->create(bigc, nparams, "pair:bigc"); for (int i = 0; i < nparams; i++) { cutsq[i] = params[i].cutsq; @@ -209,11 +191,10 @@ void PairVashishtaGPU::init_style() bigc[i] = params[i].bigc; } int mnf = 5e-2 * neighbor->oneatom; - int success = vashishta_gpu_init(atom->ntypes+1, atom->nlocal, atom->nlocal+atom->nghost, mnf, - cell_size, gpu_mode, screen, map, nelements, - elem3param, nparams, cutsq, r0, gamma, eta, lam1inv, - lam4inv, zizj, mbigd, dvrc, big6w, heta, bigh, bigw, - c0, costheta, bigb, big2b, bigc); + int success = vashishta_gpu_init(atom->ntypes + 1, atom->nlocal, atom->nlocal + atom->nghost, mnf, + cell_size, gpu_mode, screen, map, nelements, elem3param, nparams, + cutsq, r0, gamma, eta, lam1inv, lam4inv, zizj, mbigd, dvrc, + big6w, heta, bigh, bigw, c0, costheta, bigb, big2b, bigc); memory->destroy(cutsq); memory->destroy(r0); memory->destroy(gamma); @@ -233,18 +214,13 @@ void PairVashishtaGPU::init_style() memory->destroy(big2b); memory->destroy(bigc); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; - } - if (comm->cutghostuser < (2.0*cutmax + neighbor->skin)) { - comm->cutghostuser=2.0*cutmax + neighbor->skin; - if (comm->me == 0) - error->warning(FLERR,"Increasing communication cutoff for GPU style"); + if (gpu_mode == GPU_FORCE) + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); + if (comm->cutghostuser < (2.0 * cutmax + neighbor->skin)) { + comm->cutghostuser = 2.0 * cutmax + neighbor->skin; + if (comm->me == 0) error->warning(FLERR, "Increasing communication cutoff for GPU style"); } } @@ -254,13 +230,10 @@ void PairVashishtaGPU::init_style() double PairVashishtaGPU::init_one(int i, int j) { - if (!gpu_allocated) { - allocate(); - } - if (setflag[i][j] == 0) error->all(FLERR,"All pair coeffs are not set"); + if (!gpu_allocated) { allocate(); } + if (setflag[i][j] == 0) error->all(FLERR, "All pair coeffs are not set"); cutghost[i][j] = cutmax; cutghost[j][i] = cutmax; return cutmax; } - diff --git a/src/GPU/pair_yukawa_colloid_gpu.cpp b/src/GPU/pair_yukawa_colloid_gpu.cpp index a31148b352..8a9938143d 100644 --- a/src/GPU/pair_yukawa_colloid_gpu.cpp +++ b/src/GPU/pair_yukawa_colloid_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,34 +32,26 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int ykcolloid_gpu_init(const int ntypes, double **cutsq, double **host_a, - double **host_offset, double *special_lj, const int inum, - const int nall, const int max_nbors, - const int maxspecial, const double cell_size, - int &gpu_mode, FILE *screen, const double kappa); +int ykcolloid_gpu_init(const int ntypes, double **cutsq, double **host_a, double **host_offset, + double *special_lj, const int inum, const int nall, const int max_nbors, + const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen, + const double kappa); void ykcolloid_gpu_clear(); -int ** ykcolloid_gpu_compute_n(const int ago, const int inum_full, - const int nall, double **host_x, int *host_type, - double *sublo, double *subhi, tagint *tag, - int **nspecial, tagint **special, - const bool eflag, const bool vflag, - const bool eatom, const bool vatom, - int &host_start, int **ilist, int **jnum, - const double cpu_time, bool &success, - double *host_rad); -void ykcolloid_gpu_compute(const int ago, const int inum_full, - const int nall, double **host_x, int *host_type, - int *ilist, int *numj, int **firstneigh, - const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success, - double *host_rad); +int **ykcolloid_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success, double *host_rad); +void ykcolloid_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, + const bool eflag, const bool vflag, const bool eatom, const bool vatom, + int &host_start, const double cpu_time, bool &success, double *host_rad); double ykcolloid_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairYukawaColloidGPU::PairYukawaColloidGPU(LAMMPS *lmp) : PairYukawaColloid(lmp), - gpu_mode(GPU_FORCE) +PairYukawaColloidGPU::PairYukawaColloidGPU(LAMMPS *lmp) : + PairYukawaColloid(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -83,7 +73,7 @@ PairYukawaColloidGPU::~PairYukawaColloidGPU() void PairYukawaColloidGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -91,7 +81,7 @@ void PairYukawaColloidGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -100,32 +90,25 @@ void PairYukawaColloidGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = ykcolloid_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, - sublo, - subhi, atom->tag, - atom->nspecial, atom->special, - eflag, vflag, eflag_atom, - vflag_atom, host_start, &ilist, - &numneigh, cpu_time, - success, atom->radius); + firstneigh = ykcolloid_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, + subhi, atom->tag, atom->nspecial, atom->special, eflag, + vflag, eflag_atom, vflag_atom, host_start, &ilist, + &numneigh, cpu_time, success, atom->radius); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - ykcolloid_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, - eflag_atom, vflag_atom, host_start, cpu_time, + ykcolloid_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, + firstneigh, eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success, atom->radius); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startsphere_flag) - error->all(FLERR,"Pair yukawa/colloid/gpu requires atom style sphere"); - + if (!atom->sphere_flag) error->all(FLERR, "Pair yukawa/colloid/gpu requires atom style sphere"); // Repeat cutsq calculation because done after call to init_style double maxcut = -1.0; @@ -148,10 +129,9 @@ void PairYukawaColloidGPU::init_style() for (int i = 1; i <= atom->ntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -159,21 +139,15 @@ void PairYukawaColloidGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = ykcolloid_gpu_init(atom->ntypes+1, cutsq, a, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, + int success = ykcolloid_gpu_init(atom->ntypes + 1, cutsq, a, offset, force->special_lj, + atom->nlocal, atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen, kappa); - GPU_EXTRA::check_flag(success,error,world); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -186,12 +160,12 @@ double PairYukawaColloidGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairYukawaColloidGPU::cpu_compute(int start, int inum, int eflag, - int /* vflag */, int *ilist, - int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair,radi,radj; - double r,rsq,rinv,screening,forceyukawa,factor; +void PairYukawaColloidGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair, radi, radj; + double r, rsq, rinv, screening, forceyukawa, factor; int *jlist; double **x = atom->x; @@ -220,28 +194,28 @@ void PairYukawaColloidGPU::cpu_compute(int start, int inum, int eflag, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; radj = radius[j]; if (rsq < cutsq[itype][jtype]) { r = sqrt(rsq); - rinv = 1.0/r; - screening = exp(-kappa*(r-(radi+radj))); + rinv = 1.0 / r; + screening = exp(-kappa * (r - (radi + radj))); forceyukawa = a[itype][jtype] * screening; - fpair = factor*forceyukawa * rinv; + fpair = factor * forceyukawa * rinv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { - evdwl = a[itype][jtype]/kappa * screening - offset[itype][jtype]; + evdwl = a[itype][jtype] / kappa * screening - offset[itype][jtype]; evdwl *= factor; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_yukawa_gpu.cpp b/src/GPU/pair_yukawa_gpu.cpp index 267052b0e2..3a56d40c76 100644 --- a/src/GPU/pair_yukawa_gpu.cpp +++ b/src/GPU/pair_yukawa_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,30 +32,25 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int yukawa_gpu_init(const int ntypes, double **cutsq, double kappa, - double **host_a, double **offset, double *special_lj, - const int inum, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, +int yukawa_gpu_init(const int ntypes, double **cutsq, double kappa, double **host_a, + double **offset, double *special_lj, const int inum, const int nall, + const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void yukawa_gpu_clear(); -int ** yukawa_gpu_compute_n(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, - const bool vflag, const bool eatom, - const bool vatom, int &host_start, int **ilist, - int **jnum, const double cpu_time, bool &success); -void yukawa_gpu_compute(const int ago, const int inum_full, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, +int **yukawa_gpu_compute_n(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, + int **nspecial, tagint **special, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, int **ilist, + int **jnum, const double cpu_time, bool &success); +void yukawa_gpu_compute(const int ago, const int inum_full, const int nall, double **host_x, + int *host_type, int *ilist, int *numj, int **firstneigh, const bool eflag, + const bool vflag, const bool eatom, const bool vatom, int &host_start, const double cpu_time, bool &success); double yukawa_gpu_bytes(); /* ---------------------------------------------------------------------- */ -PairYukawaGPU::PairYukawaGPU(LAMMPS *lmp) : PairYukawa(lmp), - gpu_mode(GPU_FORCE) +PairYukawaGPU::PairYukawaGPU(LAMMPS *lmp) : PairYukawa(lmp), gpu_mode(GPU_FORCE) { respa_enable = 0; reinitflag = 0; @@ -79,7 +72,7 @@ PairYukawaGPU::~PairYukawaGPU() void PairYukawaGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -87,7 +80,7 @@ void PairYukawaGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -96,28 +89,24 @@ void PairYukawaGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = yukawa_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + yukawa_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, + atom->tag, atom->nspecial, atom->special, eflag, vflag, eflag_atom, + vflag_atom, host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - yukawa_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + yukawa_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -148,21 +136,15 @@ void PairYukawaGPU::init_style() } double cell_size = sqrt(maxcut) + neighbor->skin; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = yukawa_gpu_init(atom->ntypes+1, cutsq, kappa, a, - offset, force->special_lj, atom->nlocal, - atom->nlocal+atom->nghost, mnf, maxspecial, - cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + yukawa_gpu_init(atom->ntypes + 1, cutsq, kappa, a, offset, force->special_lj, atom->nlocal, + atom->nlocal + atom->nghost, mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -175,11 +157,12 @@ double PairYukawaGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairYukawaGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r2inv,r,rinv,screening,forceyukawa,factor; +void PairYukawaGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r2inv, r, rinv, screening, forceyukawa, factor; int *jlist; double **x = atom->x; @@ -206,28 +189,28 @@ void PairYukawaGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; r = sqrt(rsq); - rinv = 1.0/r; - screening = exp(-kappa*r); + rinv = 1.0 / r; + screening = exp(-kappa * r); forceyukawa = a[itype][jtype] * screening * (kappa + rinv); - fpair = factor*forceyukawa * r2inv; + fpair = factor * forceyukawa * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { evdwl = a[itype][jtype] * screening * rinv - offset[itype][jtype]; evdwl *= factor; } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GPU/pair_zbl_gpu.cpp b/src/GPU/pair_zbl_gpu.cpp index 28a69c2ddd..68e4c05c53 100644 --- a/src/GPU/pair_zbl_gpu.cpp +++ b/src/GPU/pair_zbl_gpu.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -24,7 +23,6 @@ #include "force.h" #include "gpu_extra.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -34,27 +32,22 @@ using namespace LAMMPS_NS; // External functions from cuda library for atom decomposition -int zbl_gpu_init(const int ntypes, double **cutsq, double **host_sw1, - double **host_sw2, double **host_sw3, double **host_sw4, - double **host_sw5, double **host_d1a, double **host_d2a, - double **host_d3a, double **host_d4a, double **host_zze, - double cut_globalsq, double cut_innersq, double cut_inner, - const int inum, const int nall, const int max_nbors, - const int maxspecial, const double cell_size, +int zbl_gpu_init(const int ntypes, double **cutsq, double **host_sw1, double **host_sw2, + double **host_sw3, double **host_sw4, double **host_sw5, double **host_d1a, + double **host_d2a, double **host_d3a, double **host_d4a, double **host_zze, + double cut_globalsq, double cut_innersq, double cut_inner, const int inum, + const int nall, const int max_nbors, const int maxspecial, const double cell_size, int &gpu_mode, FILE *screen); void zbl_gpu_clear(); -int ** zbl_gpu_compute_n(const int ago, const int inum, const int nall, - double **host_x, int *host_type, double *sublo, - double *subhi, tagint *tag, int **nspecial, - tagint **special, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - int **ilist, int **jnum, - const double cpu_time, bool &success); -void zbl_gpu_compute(const int ago, const int inum, const int nall, - double **host_x, int *host_type, int *ilist, int *numj, - int **firstneigh, const bool eflag, const bool vflag, - const bool eatom, const bool vatom, int &host_start, - const double cpu_time, bool &success); +int **zbl_gpu_compute_n(const int ago, const int inum, const int nall, double **host_x, + int *host_type, double *sublo, double *subhi, tagint *tag, int **nspecial, + tagint **special, const bool eflag, const bool vflag, const bool eatom, + const bool vatom, int &host_start, int **ilist, int **jnum, + const double cpu_time, bool &success); +void zbl_gpu_compute(const int ago, const int inum, const int nall, double **host_x, int *host_type, + int *ilist, int *numj, int **firstneigh, const bool eflag, const bool vflag, + const bool eatom, const bool vatom, int &host_start, const double cpu_time, + bool &success); double zbl_gpu_bytes(); /* ---------------------------------------------------------------------- */ @@ -81,7 +74,7 @@ PairZBLGPU::~PairZBLGPU() void PairZBLGPU::compute(int eflag, int vflag) { - ev_init(eflag,vflag); + ev_init(eflag, vflag); int nall = atom->nlocal + atom->nghost; int inum, host_start; @@ -89,7 +82,7 @@ void PairZBLGPU::compute(int eflag, int vflag) bool success = true; int *ilist, *numneigh, **firstneigh; if (gpu_mode != GPU_FORCE) { - double sublo[3],subhi[3]; + double sublo[3], subhi[3]; if (domain->triclinic == 0) { sublo[0] = domain->sublo[0]; sublo[1] = domain->sublo[1]; @@ -98,28 +91,24 @@ void PairZBLGPU::compute(int eflag, int vflag) subhi[1] = domain->subhi[1]; subhi[2] = domain->subhi[2]; } else { - domain->bbox(domain->sublo_lamda,domain->subhi_lamda,sublo,subhi); + domain->bbox(domain->sublo_lamda, domain->subhi_lamda, sublo, subhi); } inum = atom->nlocal; - firstneigh = zbl_gpu_compute_n(neighbor->ago, inum, nall, - atom->x, atom->type, sublo, - subhi, atom->tag, atom->nspecial, - atom->special, eflag, vflag, eflag_atom, - vflag_atom, host_start, - &ilist, &numneigh, cpu_time, success); + firstneigh = + zbl_gpu_compute_n(neighbor->ago, inum, nall, atom->x, atom->type, sublo, subhi, atom->tag, + atom->nspecial, atom->special, eflag, vflag, eflag_atom, vflag_atom, + host_start, &ilist, &numneigh, cpu_time, success); } else { inum = list->inum; ilist = list->ilist; numneigh = list->numneigh; firstneigh = list->firstneigh; - zbl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, - ilist, numneigh, firstneigh, eflag, vflag, eflag_atom, - vflag_atom, host_start, cpu_time, success); + zbl_gpu_compute(neighbor->ago, inum, nall, atom->x, atom->type, ilist, numneigh, firstneigh, + eflag, vflag, eflag_atom, vflag_atom, host_start, cpu_time, success); } - if (!success) - error->one(FLERR,"Insufficient memory on accelerator"); + if (!success) error->one(FLERR, "Insufficient memory on accelerator"); - if (host_startntypes; i++) { for (int j = i; j <= atom->ntypes; j++) { if (setflag[i][j] != 0 || (setflag[i][i] != 0 && setflag[j][j] != 0)) { - cut = init_one(i,j); + cut = init_one(i, j); cut *= cut; - if (cut > maxcut) - maxcut = cut; + if (cut > maxcut) maxcut = cut; cutsq[i][j] = cutsq[j][i] = cut; } else cutsq[i][j] = cutsq[j][i] = 0.0; @@ -153,22 +141,16 @@ void PairZBLGPU::init_style() cut_innersq = cut_inner * cut_inner; cut_globalsq = cut_global * cut_global; - int maxspecial=0; - if (atom->molecular != Atom::ATOMIC) - maxspecial=atom->maxspecial; + int maxspecial = 0; + if (atom->molecular != Atom::ATOMIC) maxspecial = atom->maxspecial; int mnf = 5e-2 * neighbor->oneatom; - int success = zbl_gpu_init(atom->ntypes+1, cutsq, sw1, sw2, sw3, sw4, - sw5, d1a, d2a, d3a, d4a, zze, - cut_globalsq, cut_innersq, cut_inner, - atom->nlocal, atom->nlocal+atom->nghost, - mnf, maxspecial, cell_size, gpu_mode, screen); - GPU_EXTRA::check_flag(success,error,world); + int success = + zbl_gpu_init(atom->ntypes + 1, cutsq, sw1, sw2, sw3, sw4, sw5, d1a, d2a, d3a, d4a, zze, + cut_globalsq, cut_innersq, cut_inner, atom->nlocal, atom->nlocal + atom->nghost, + mnf, maxspecial, cell_size, gpu_mode, screen); + GPU_EXTRA::check_flag(success, error, world); - if (gpu_mode == GPU_FORCE) { - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - } + if (gpu_mode == GPU_FORCE) neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ @@ -181,11 +163,12 @@ double PairZBLGPU::memory_usage() /* ---------------------------------------------------------------------- */ -void PairZBLGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, - int *ilist, int *numneigh, int **firstneigh) { - int i,j,ii,jj,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r,t,fswitch,eswitch; +void PairZBLGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, int *ilist, + int *numneigh, int **firstneigh) +{ + int i, j, ii, jj, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r, t, fswitch, eswitch; int *jlist; double **x = atom->x; @@ -210,36 +193,34 @@ void PairZBLGPU::cpu_compute(int start, int inum, int eflag, int /* vflag */, delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cut_globalsq) { - r = sqrt(rsq); + r = sqrt(rsq); fpair = dzbldr(r, itype, jtype); - if (rsq > cut_innersq) { - t = r - cut_inner; - fswitch = t*t * - (sw1[itype][jtype] + sw2[itype][jtype]*t); - fpair += fswitch; - } + if (rsq > cut_innersq) { + t = r - cut_inner; + fswitch = t * t * (sw1[itype][jtype] + sw2[itype][jtype] * t); + fpair += fswitch; + } - fpair *= -1.0/r; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + fpair *= -1.0 / r; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (eflag) { evdwl = e_zbl(r, itype, jtype); - evdwl += sw5[itype][jtype]; - if (rsq > cut_innersq) { - eswitch = t*t*t * - (sw3[itype][jtype] + sw4[itype][jtype]*t); - evdwl += eswitch; - } + evdwl += sw5[itype][jtype]; + if (rsq > cut_innersq) { + eswitch = t * t * t * (sw3[itype][jtype] + sw4[itype][jtype] * t); + evdwl += eswitch; + } } - if (evflag) ev_tally_full(i,evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally_full(i, evdwl, 0.0, fpair, delx, dely, delz); } } } diff --git a/src/GRANULAR/compute_contact_atom.cpp b/src/GRANULAR/compute_contact_atom.cpp index a8494342a9..5a07d14eb8 100644 --- a/src/GRANULAR/compute_contact_atom.cpp +++ b/src/GRANULAR/compute_contact_atom.cpp @@ -13,17 +13,18 @@ ------------------------------------------------------------------------- */ #include "compute_contact_atom.h" -#include + #include "atom.h" -#include "update.h" -#include "modify.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "force.h" #include "comm.h" -#include "memory.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "update.h" + +#include using namespace LAMMPS_NS; @@ -61,19 +62,12 @@ void ComputeContactAtom::init() if (force->pair == nullptr) error->all(FLERR,"Compute contact/atom requires a pair style be defined"); - int count = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"contact/atom") == 0) count++; - if (count > 1 && comm->me == 0) + if (modify->get_compute_by_style("contact/atom").size() > 1 && comm->me == 0) error->warning(FLERR,"More than one compute contact/atom"); // need an occasional neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->size = 1; - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_SIZE | NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/GRANULAR/compute_fabric.cpp b/src/GRANULAR/compute_fabric.cpp index ac8d434b7a..77168df90e 100644 --- a/src/GRANULAR/compute_fabric.cpp +++ b/src/GRANULAR/compute_fabric.cpp @@ -89,8 +89,8 @@ ComputeFabric::ComputeFabric(LAMMPS *lmp, int narg, char **arg) : } } - std::vector iwords = Tokenizer(arg[iarg+1], ",").as_vector(); - std::vector jwords = Tokenizer(arg[iarg+2], ",").as_vector(); + std::vector iwords = Tokenizer(arg[iarg + 1], ",").as_vector(); + std::vector jwords = Tokenizer(arg[iarg + 2], ",").as_vector(); for (const auto &ifield : iwords) { utils::bounds(FLERR, ifield, 1, ntypes, inlo, inhi, error); @@ -152,12 +152,11 @@ void ComputeFabric::init() // set size to same value as request made by force->pair // this should enable it to always be a copy list (e.g. for granular pstyle) - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; - NeighRequest *pairrequest = neighbor->find_request((void *) force->pair); - if (pairrequest) neighbor->requests[irequest]->size = pairrequest->size; + auto pairrequest = neighbor->find_request(force->pair); + if (pairrequest && pairrequest->get_size()) + neighbor->add_request(this, NeighConst::REQ_SIZE | NeighConst::REQ_OCCASIONAL); + else + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/GRANULAR/pair_gran_hertz_history.cpp b/src/GRANULAR/pair_gran_hertz_history.cpp index 151644bb83..2320b7a8fb 100644 --- a/src/GRANULAR/pair_gran_hertz_history.cpp +++ b/src/GRANULAR/pair_gran_hertz_history.cpp @@ -17,18 +17,20 @@ ------------------------------------------------------------------------- */ #include "pair_gran_hertz_history.h" -#include -#include + #include "atom.h" -#include "update.h" -#include "force.h" +#include "comm.h" +#include "error.h" #include "fix.h" #include "fix_neigh_history.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "comm.h" +#include "force.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; diff --git a/src/GRANULAR/pair_gran_hooke_history.cpp b/src/GRANULAR/pair_gran_hooke_history.cpp index 4d2dc441a5..49eb1be89b 100644 --- a/src/GRANULAR/pair_gran_hooke_history.cpp +++ b/src/GRANULAR/pair_gran_hooke_history.cpp @@ -431,11 +431,10 @@ void PairGranHookeHistory::init_style() if (comm->ghost_velocity == 0) error->all(FLERR, "Pair granular requires ghost atoms store velocity"); - // need a granular neigh list + // need a granular neighbor list - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->size = 1; - if (history) neighbor->requests[irequest]->history = 1; + if (history) neighbor->add_request(this, NeighConst::REQ_SIZE|NeighConst::REQ_HISTORY); + else neighbor->add_request(this, NeighConst::REQ_SIZE); dt = update->dt; diff --git a/src/GRANULAR/pair_granular.cpp b/src/GRANULAR/pair_granular.cpp index 0559ca4c84..e1719853a4 100644 --- a/src/GRANULAR/pair_granular.cpp +++ b/src/GRANULAR/pair_granular.cpp @@ -1110,9 +1110,8 @@ void PairGranular::init_style() break; } - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->size = 1; - if (use_history) neighbor->requests[irequest]->history = 1; + if (use_history) neighbor->add_request(this, NeighConst::REQ_SIZE|NeighConst::REQ_HISTORY); + else neighbor->add_request(this, NeighConst::REQ_SIZE); dt = update->dt; diff --git a/src/INTEL/fix_intel.cpp b/src/INTEL/fix_intel.cpp index a201386724..933c90e9e8 100644 --- a/src/INTEL/fix_intel.cpp +++ b/src/INTEL/fix_intel.cpp @@ -546,17 +546,7 @@ void FixIntel::check_neighbor_intel() } if (neighbor->requests[i]->skip && _offload_balance != 0.0) error->all(FLERR,"Cannot yet use hybrid styles with Intel offload."); - - // avoid flagging a neighbor list as both INTEL and OPENMP - if (neighbor->requests[i]->intel) - neighbor->requests[i]->omp = 0; } - #else - // avoid flagging a neighbor list as both INTEL and OPENMP - const int nrequest = neighbor->nrequest; - for (int i = 0; i < nrequest; ++i) - if (neighbor->requests[i]->intel) - neighbor->requests[i]->omp = 0; #endif } diff --git a/src/INTEL/pair_airebo_intel.cpp b/src/INTEL/pair_airebo_intel.cpp index 525d81bd61..5b73ba99d2 100644 --- a/src/INTEL/pair_airebo_intel.cpp +++ b/src/INTEL/pair_airebo_intel.cpp @@ -26,7 +26,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -181,7 +180,6 @@ PairAIREBOIntel::~PairAIREBOIntel() void PairAIREBOIntel::init_style() { PairAIREBO::init_style(); - neighbor->find_request(this)->intel = 1; if (utils::strmatch(force->pair_style,"^hybrid")) error->all(FLERR, "Cannot yet use airebo/intel with hybrid."); diff --git a/src/INTEL/pair_buck_coul_cut_intel.cpp b/src/INTEL/pair_buck_coul_cut_intel.cpp index b1e904c800..934c5ec0b2 100644 --- a/src/INTEL/pair_buck_coul_cut_intel.cpp +++ b/src/INTEL/pair_buck_coul_cut_intel.cpp @@ -409,12 +409,8 @@ void PairBuckCoulCutIntel::eval(const int offload, const int vflag, void PairBuckCoulCutIntel::init_style() { PairBuckCoulCut::init_style(); - auto request = neighbor->find_request(this); - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_buck_coul_long_intel.cpp b/src/INTEL/pair_buck_coul_long_intel.cpp index 70c13b42c0..563e3abafc 100644 --- a/src/INTEL/pair_buck_coul_long_intel.cpp +++ b/src/INTEL/pair_buck_coul_long_intel.cpp @@ -485,13 +485,8 @@ void PairBuckCoulLongIntel::eval(const int offload, const int vflag, void PairBuckCoulLongIntel::init_style() { PairBuckCoulLong::init_style(); - auto request = neighbor->find_request(this); - - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_buck_intel.cpp b/src/INTEL/pair_buck_intel.cpp index 889c039cae..54a4cc0be3 100644 --- a/src/INTEL/pair_buck_intel.cpp +++ b/src/INTEL/pair_buck_intel.cpp @@ -376,12 +376,8 @@ void PairBuckIntel::init_style() PairBuck::init_style(); // augment neighbor list request - auto request = neighbor->find_request(this); - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_dpd_intel.cpp b/src/INTEL/pair_dpd_intel.cpp index fca749ee9a..fe76e81a4e 100644 --- a/src/INTEL/pair_dpd_intel.cpp +++ b/src/INTEL/pair_dpd_intel.cpp @@ -484,13 +484,8 @@ void PairDPDIntel::settings(int narg, char **arg) { void PairDPDIntel::init_style() { PairDPD::init_style(); - auto request = neighbor->find_request(this); - - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_eam_intel.cpp b/src/INTEL/pair_eam_intel.cpp index 67d50a7dd6..56188028cf 100644 --- a/src/INTEL/pair_eam_intel.cpp +++ b/src/INTEL/pair_eam_intel.cpp @@ -666,13 +666,8 @@ void PairEAMIntel::eval(const int offload, const int vflag, void PairEAMIntel::init_style() { PairEAM::init_style(); - auto request = neighbor->find_request(this); - - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_gayberne_intel.cpp b/src/INTEL/pair_gayberne_intel.cpp index d76a4befc4..32f5f2fe78 100644 --- a/src/INTEL/pair_gayberne_intel.cpp +++ b/src/INTEL/pair_gayberne_intel.cpp @@ -889,13 +889,8 @@ void PairGayBerneIntel::eval(const int offload, const int vflag, void PairGayBerneIntel::init_style() { PairGayBerne::init_style(); - auto request = neighbor->find_request(this); - - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_lj_charmm_coul_charmm_intel.cpp b/src/INTEL/pair_lj_charmm_coul_charmm_intel.cpp index 8964dae921..c5035d5f03 100644 --- a/src/INTEL/pair_lj_charmm_coul_charmm_intel.cpp +++ b/src/INTEL/pair_lj_charmm_coul_charmm_intel.cpp @@ -456,13 +456,8 @@ void PairLJCharmmCoulCharmmIntel::eval(const int offload, const int vflag, void PairLJCharmmCoulCharmmIntel::init_style() { PairLJCharmmCoulCharmm::init_style(); - auto request = neighbor->find_request(this); - - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_lj_charmm_coul_long_intel.cpp b/src/INTEL/pair_lj_charmm_coul_long_intel.cpp index 35cb7a207a..850429cd1b 100644 --- a/src/INTEL/pair_lj_charmm_coul_long_intel.cpp +++ b/src/INTEL/pair_lj_charmm_coul_long_intel.cpp @@ -521,13 +521,8 @@ void PairLJCharmmCoulLongIntel::eval(const int offload, const int vflag, void PairLJCharmmCoulLongIntel::init_style() { PairLJCharmmCoulLong::init_style(); - auto request = neighbor->find_request(this); - - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_lj_cut_coul_long_intel.cpp b/src/INTEL/pair_lj_cut_coul_long_intel.cpp index 3e48008774..a13cfbc148 100644 --- a/src/INTEL/pair_lj_cut_coul_long_intel.cpp +++ b/src/INTEL/pair_lj_cut_coul_long_intel.cpp @@ -486,13 +486,8 @@ void PairLJCutCoulLongIntel::eval(const int offload, const int vflag, void PairLJCutCoulLongIntel::init_style() { PairLJCutCoulLong::init_style(); - auto request = neighbor->find_request(this); - - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_lj_cut_intel.cpp b/src/INTEL/pair_lj_cut_intel.cpp index a5d4beb23f..50205cfc49 100644 --- a/src/INTEL/pair_lj_cut_intel.cpp +++ b/src/INTEL/pair_lj_cut_intel.cpp @@ -392,13 +392,8 @@ void PairLJCutIntel::eval(const int offload, const int vflag, void PairLJCutIntel::init_style() { PairLJCut::init_style(); - auto request = neighbor->find_request(this); - - if (force->newton_pair == 0) { - request->half = 0; - request->full = 1; - } - request->intel = 1; + if (force->newton_pair == 0) + neighbor->find_request(this)->enable_full(); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_lj_long_coul_long_intel.cpp b/src/INTEL/pair_lj_long_coul_long_intel.cpp index 614f7c3810..d326e5b839 100644 --- a/src/INTEL/pair_lj_long_coul_long_intel.cpp +++ b/src/INTEL/pair_lj_long_coul_long_intel.cpp @@ -46,7 +46,6 @@ PairLJLongCoulLongIntel::~PairLJLongCoulLongIntel() void PairLJLongCoulLongIntel::init_style() { PairLJLongCoulLong::init_style(); - neighbor->find_request(this)->intel = 1; auto fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTEL/pair_sw_intel.cpp b/src/INTEL/pair_sw_intel.cpp index f06ab8af99..f6cf90b1d1 100644 --- a/src/INTEL/pair_sw_intel.cpp +++ b/src/INTEL/pair_sw_intel.cpp @@ -25,7 +25,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "suffix.h" @@ -1109,7 +1108,6 @@ void PairSWIntel::allocate() void PairSWIntel::init_style() { PairSW::init_style(); - neighbor->find_request(this)->intel = 1; map[0] = map[1]; diff --git a/src/INTEL/pair_tersoff_intel.cpp b/src/INTEL/pair_tersoff_intel.cpp index 8707b313ab..42378c999c 100644 --- a/src/INTEL/pair_tersoff_intel.cpp +++ b/src/INTEL/pair_tersoff_intel.cpp @@ -23,7 +23,6 @@ #include "force.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" using namespace LAMMPS_NS; @@ -407,10 +406,7 @@ void PairTersoffIntel::init_style() // need a full neighbor list - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->intel = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); fix = static_cast(modify->get_fix_by_id("package_intel")); if (!fix) error->all(FLERR, "The 'package intel' command is required for /intel styles"); diff --git a/src/INTERLAYER/pair_coul_shield.cpp b/src/INTERLAYER/pair_coul_shield.cpp index da2a2cf2fd..68873a3350 100644 --- a/src/INTERLAYER/pair_coul_shield.cpp +++ b/src/INTERLAYER/pair_coul_shield.cpp @@ -236,7 +236,7 @@ void PairCoulShield::init_style() if (!atom->molecule_flag) error->all(FLERR, "Pair style coul/shield requires atom attribute molecule"); - neighbor->request(this, instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/INTERLAYER/pair_drip.cpp b/src/INTERLAYER/pair_drip.cpp index 85b50ba170..2bd6a16e8c 100644 --- a/src/INTERLAYER/pair_drip.cpp +++ b/src/INTERLAYER/pair_drip.cpp @@ -92,10 +92,7 @@ void PairDRIP::init_style() if (!atom->molecule_flag) error->all(FLERR, "Pair style drip requires atom attribute molecule"); // need a full neighbor list, including neighbors of ghosts - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); } /* ---------------------------------------------------------------------- diff --git a/src/INTERLAYER/pair_ilp_graphene_hbn.cpp b/src/INTERLAYER/pair_ilp_graphene_hbn.cpp index 85a2d8bfb5..fc1289ff28 100644 --- a/src/INTERLAYER/pair_ilp_graphene_hbn.cpp +++ b/src/INTERLAYER/pair_ilp_graphene_hbn.cpp @@ -31,7 +31,6 @@ #include "memory.h" #include "my_page.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -342,10 +341,7 @@ void PairILPGrapheneHBN::init_style() // need a full neighbor list, including neighbors of ghosts - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); // local ILP neighbor list // create pages if first time or if neighbor pgsize/oneatom has changed diff --git a/src/INTERLAYER/pair_kolmogorov_crespi_full.cpp b/src/INTERLAYER/pair_kolmogorov_crespi_full.cpp index a107ed29a0..3076242ee3 100644 --- a/src/INTERLAYER/pair_kolmogorov_crespi_full.cpp +++ b/src/INTERLAYER/pair_kolmogorov_crespi_full.cpp @@ -31,7 +31,6 @@ #include "memory.h" #include "my_page.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -313,10 +312,7 @@ void PairKolmogorovCrespiFull::init_style() // need a full neighbor list, including neighbors of ghosts - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); // local KC neighbor list // create pages if first time or if neighbor pgsize/oneatom has changed diff --git a/src/INTERLAYER/pair_kolmogorov_crespi_z.cpp b/src/INTERLAYER/pair_kolmogorov_crespi_z.cpp index bd2ce680d5..144e09cb50 100644 --- a/src/INTERLAYER/pair_kolmogorov_crespi_z.cpp +++ b/src/INTERLAYER/pair_kolmogorov_crespi_z.cpp @@ -248,7 +248,7 @@ void PairKolmogorovCrespiZ::init_style() if (force->newton_pair == 0) error->all(FLERR, "Pair style kolmogorov/crespi/z requires newton pair on"); - neighbor->request(this, instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/INTERLAYER/pair_lebedeva_z.cpp b/src/INTERLAYER/pair_lebedeva_z.cpp index f837934843..95e23d3348 100644 --- a/src/INTERLAYER/pair_lebedeva_z.cpp +++ b/src/INTERLAYER/pair_lebedeva_z.cpp @@ -245,7 +245,7 @@ void PairLebedevaZ::init_style() if (force->newton_pair == 0) error->all(FLERR,"Pair style lebedeva/z requires newton pair on"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/KIM/pair_kim.cpp b/src/KIM/pair_kim.cpp index 1f0a76d4da..fc33faab43 100644 --- a/src/KIM/pair_kim.cpp +++ b/src/KIM/pair_kim.cpp @@ -600,25 +600,16 @@ void PairKIM::init_style() // request full neighbor for (int i = 0; i < kim_number_of_neighbor_lists; ++i) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->id = i; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - - if (modelWillNotRequestNeighborsOfNoncontributingParticles[i]) - neighbor->requests[irequest]->ghost = 0; - else - neighbor->requests[irequest]->ghost = 1; - - // always want all owned/ghost pairs - neighbor->requests[irequest]->newton = 2; + int neighflags = NeighConst::REQ_FULL | NeighConst::REQ_NEWTON_OFF; + if (!modelWillNotRequestNeighborsOfNoncontributingParticles[i]) + neighflags |= NeighConst::REQ_GHOST; + auto req = neighbor->add_request(this, neighflags); + req->set_id(i); // set cutoff - neighbor->requests[irequest]->cut = 1; if (kim_cutoff_values[i] <= neighbor->skin) error->all(FLERR,"Illegal neighbor request (force cutoff <= skin)"); - neighbor->requests[irequest]->cutoff - = kim_cutoff_values[i] + neighbor->skin; + req->set_cutoff(kim_cutoff_values[i] + neighbor->skin); } // increment instance_me in case of need to change the neighbor list // request settings diff --git a/src/KOKKOS/compute_ave_sphere_atom_kokkos.cpp b/src/KOKKOS/compute_ave_sphere_atom_kokkos.cpp index e73f6d39a6..0b890ae4e5 100644 --- a/src/KOKKOS/compute_ave_sphere_atom_kokkos.cpp +++ b/src/KOKKOS/compute_ave_sphere_atom_kokkos.cpp @@ -64,17 +64,12 @@ void ComputeAveSphereAtomKokkos::init() { ComputeAveSphereAtom::init(); - // need an occasional full neighbor list + // adjust neighbor list request for KOKKOS - // irequest = neigh request made by parent class - - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/compute_coord_atom_kokkos.cpp b/src/KOKKOS/compute_coord_atom_kokkos.cpp index 443e9a89eb..e877400028 100644 --- a/src/KOKKOS/compute_coord_atom_kokkos.cpp +++ b/src/KOKKOS/compute_coord_atom_kokkos.cpp @@ -74,17 +74,12 @@ void ComputeCoordAtomKokkos::init() { ComputeCoordAtom::init(); - // need an occasional full neighbor list + // adjust neighbor list request for KOKKOS - // irequest = neigh request made by parent class - - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/compute_orientorder_atom_kokkos.cpp b/src/KOKKOS/compute_orientorder_atom_kokkos.cpp index f7ec879e3c..285f212c1a 100644 --- a/src/KOKKOS/compute_orientorder_atom_kokkos.cpp +++ b/src/KOKKOS/compute_orientorder_atom_kokkos.cpp @@ -85,15 +85,10 @@ void ComputeOrientOrderAtomKokkos::init() // need an occasional full neighbor list - // irequest = neigh request made by parent class - - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/fix_acks2_reaxff_kokkos.cpp b/src/KOKKOS/fix_acks2_reaxff_kokkos.cpp index d72d4009b0..d8fbe32b9a 100644 --- a/src/KOKKOS/fix_acks2_reaxff_kokkos.cpp +++ b/src/KOKKOS/fix_acks2_reaxff_kokkos.cpp @@ -96,26 +96,14 @@ void FixACKS2ReaxFFKokkos::init() FixACKS2ReaxFF::init(); + // adjust neighbor list request for KOKKOS + neighflag = lmp->kokkos->neighflag_qeq; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else { //if (neighflag == HALF || neighflag == HALFTHREAD) - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); int ntypes = atom->ntypes; k_params = Kokkos::DualView diff --git a/src/KOKKOS/fix_qeq_reaxff_kokkos.cpp b/src/KOKKOS/fix_qeq_reaxff_kokkos.cpp index e685558584..4aa23b77be 100644 --- a/src/KOKKOS/fix_qeq_reaxff_kokkos.cpp +++ b/src/KOKKOS/fix_qeq_reaxff_kokkos.cpp @@ -98,26 +98,14 @@ void FixQEqReaxFFKokkos::init() FixQEqReaxFF::init(); + // adjust neighbor list request for KOKKOS + neighflag = lmp->kokkos->neighflag_qeq; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else { //if (neighflag == HALF || neighflag == HALFTHREAD) - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); int ntypes = atom->ntypes; k_params = Kokkos::DualView diff --git a/src/KOKKOS/fix_rx_kokkos.cpp b/src/KOKKOS/fix_rx_kokkos.cpp index ed76540f87..265661d410 100644 --- a/src/KOKKOS/fix_rx_kokkos.cpp +++ b/src/KOKKOS/fix_rx_kokkos.cpp @@ -113,11 +113,6 @@ void FixRxKokkos::post_constructor() template void FixRxKokkos::init() { - //printf("Inside FixRxKokkos::init\n"); - - // Call the parent's version. - //FixRX::init(); - pairDPDE = (PairDPDfdtEnergy *) force->pair_match("dpd/fdt/energy",1); if (pairDPDE == nullptr) pairDPDE = (PairDPDfdtEnergy *) force->pair_match("dpd/fdt/energy/kk",1); @@ -137,30 +132,14 @@ void FixRxKokkos::init() if (update_kinetics_data) create_kinetics_data(); - // From FixRX::init() // need a half neighbor list // built whenever re-neighboring occurs - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - - // Update the neighbor data for Kokkos. - int neighflag = lmp->kokkos->neighflag; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else { //if (neighflag == HALF || neighflag == HALFTHREAD) - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } + auto request = neighbor->add_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (lmp->kokkos->neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/fix_shardlow_kokkos.cpp b/src/KOKKOS/fix_shardlow_kokkos.cpp index 1ec94adfb6..035a2ffbb8 100644 --- a/src/KOKKOS/fix_shardlow_kokkos.cpp +++ b/src/KOKKOS/fix_shardlow_kokkos.cpp @@ -35,22 +35,23 @@ ------------------------------------------------------------------------- */ #include "fix_shardlow_kokkos.h" -#include #include "atom.h" -#include "atom_masks.h" #include "atom_kokkos.h" -#include "force.h" -#include "update.h" -#include "error.h" +#include "atom_masks.h" #include "comm.h" -#include "neighbor.h" +#include "domain.h" +#include "error.h" +#include "force.h" +#include "memory_kokkos.h" #include "neigh_list_kokkos.h" #include "neigh_request.h" -#include "memory_kokkos.h" -#include "domain.h" -#include "pair_dpd_fdt_energy_kokkos.h" +#include "neighbor.h" #include "npair_ssa_kokkos.h" +#include "pair_dpd_fdt_energy_kokkos.h" +#include "update.h" + +#include using namespace LAMMPS_NS; using namespace FixConst; @@ -59,7 +60,6 @@ using namespace random_external_state; #define EPSILON 1.0e-10 #define EPSILON_SQUARED ((EPSILON) * (EPSILON)) - /* ---------------------------------------------------------------------- */ template @@ -125,18 +125,12 @@ void FixShardlowKokkos::init() { FixShardlow::init(); - int irequest = neighbor->nrequest - 1; + // adjust neighbor list request for KOKKOS - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - -// neighbor->requests[irequest]->pair = 0; -// neighbor->requests[irequest]->fix = 1; -// neighbor->requests[irequest]->ghost= 1; -// neighbor->requests[irequest]->ssa = 1; + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); int ntypes = atom->ntypes; k_params = Kokkos::DualView diff --git a/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp b/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp index 6fe8922a96..78d3a9e78e 100644 --- a/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp @@ -17,20 +17,22 @@ ------------------------------------------------------------------------- */ #include "pair_buck_coul_cut_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "respa.h" +#include "kokkos.h" #include "math_const.h" #include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neigh_list.h" +#include "neigh_request.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -286,26 +288,14 @@ void PairBuckCoulCutKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with buck/coul/cut/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_buck_coul_long_kokkos.cpp b/src/KOKKOS/pair_buck_coul_long_kokkos.cpp index 01ad5c7ad8..ab0476a28b 100644 --- a/src/KOKKOS/pair_buck_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_buck_coul_long_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_buck_coul_long_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -433,26 +435,14 @@ void PairBuckCoulLongKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with buck/coul/long/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_buck_kokkos.cpp b/src/KOKKOS/pair_buck_kokkos.cpp index 2f7a486997..dc375dddf7 100644 --- a/src/KOKKOS/pair_buck_kokkos.cpp +++ b/src/KOKKOS/pair_buck_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_buck_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -207,30 +209,17 @@ void PairBuckKokkos::init_style() int respa = 0; if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; - if (respa) - error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); + if (respa) error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with buck/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_coul_cut_kokkos.cpp b/src/KOKKOS/pair_coul_cut_kokkos.cpp index 89390576e7..0532644579 100644 --- a/src/KOKKOS/pair_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_coul_cut_kokkos.cpp @@ -13,16 +13,18 @@ ------------------------------------------------------------------------- */ #include "pair_coul_cut_kokkos.h" -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neighbor.h" + +#include using namespace LAMMPS_NS; @@ -209,26 +211,14 @@ void PairCoulCutKokkos::init_style() { PairCoulCut::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with coul/cut/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_coul_debye_kokkos.cpp b/src/KOKKOS/pair_coul_debye_kokkos.cpp index 55d0754328..ff98885e3e 100644 --- a/src/KOKKOS/pair_coul_debye_kokkos.cpp +++ b/src/KOKKOS/pair_coul_debye_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_coul_debye_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -243,26 +245,14 @@ void PairCoulDebyeKokkos::init_style() { PairCoulDebye::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with coul/debye/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_coul_dsf_kokkos.cpp b/src/KOKKOS/pair_coul_dsf_kokkos.cpp index 8cfdb709f5..097fa36419 100644 --- a/src/KOKKOS/pair_coul_dsf_kokkos.cpp +++ b/src/KOKKOS/pair_coul_dsf_kokkos.cpp @@ -17,17 +17,19 @@ ------------------------------------------------------------------------- */ #include "pair_coul_dsf_kokkos.h" -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "math_const.h" +#include "memory_kokkos.h" #include "neigh_list_kokkos.h" #include "neigh_request.h" -#include "memory_kokkos.h" -#include "math_const.h" -#include "error.h" -#include "atom_masks.h" +#include "neighbor.h" + +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -198,26 +200,14 @@ void PairCoulDSFKokkos::init_style() { PairCoulDSF::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with coul/dsf/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_coul_long_kokkos.cpp b/src/KOKKOS/pair_coul_long_kokkos.cpp index f45366df22..3f5ad0a6d5 100644 --- a/src/KOKKOS/pair_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_coul_long_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_coul_long_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -397,26 +399,14 @@ void PairCoulLongKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with buck/coul/long/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_coul_wolf_kokkos.cpp b/src/KOKKOS/pair_coul_wolf_kokkos.cpp index e652c50a39..79186d8951 100644 --- a/src/KOKKOS/pair_coul_wolf_kokkos.cpp +++ b/src/KOKKOS/pair_coul_wolf_kokkos.cpp @@ -17,17 +17,19 @@ ------------------------------------------------------------------------- */ #include "pair_coul_wolf_kokkos.h" -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list_kokkos.h" -#include "neigh_request.h" +#include "kokkos.h" #include "math_const.h" #include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neigh_list_kokkos.h" +#include "neigh_request.h" +#include "neighbor.h" + +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -199,26 +201,14 @@ void PairCoulWolfKokkos::init_style() { PairCoulWolf::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with coul/wolf/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp b/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp index b905ec5e67..c95c02b767 100644 --- a/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp +++ b/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp @@ -17,18 +17,20 @@ ------------------------------------------------------------------------- */ #include "pair_dpd_fdt_energy_kokkos.h" -#include + #include "atom_kokkos.h" +#include "atom_masks.h" #include "comm.h" -#include "update.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" -#include "kokkos.h" +#include "neighbor.h" +#include "update.h" + +#include using namespace LAMMPS_NS; @@ -83,26 +85,14 @@ void PairDPDfdtEnergyKokkos::init_style() { PairDPDfdtEnergy::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with dpd/fdt/energy/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); #ifdef DPD_USE_RAN_MARS rand_pool.init(random,seed); @@ -121,26 +111,14 @@ void PairDPDfdtEnergyKokkos::init_style() { PairDPDfdtEnergy::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with dpd/fdt/energy/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); #ifdef DPD_USE_RAN_MARS rand_pool.init(random,seed); diff --git a/src/KOKKOS/pair_eam_alloy_kokkos.cpp b/src/KOKKOS/pair_eam_alloy_kokkos.cpp index e08daf2ff7..ca2692a21e 100644 --- a/src/KOKKOS/pair_eam_alloy_kokkos.cpp +++ b/src/KOKKOS/pair_eam_alloy_kokkos.cpp @@ -299,27 +299,14 @@ void PairEAMAlloyKokkos::init_style() PairEAM::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with pair eam/kk/alloy"); - } - + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_eam_fs_kokkos.cpp b/src/KOKKOS/pair_eam_fs_kokkos.cpp index 88380a834d..55aabdc920 100644 --- a/src/KOKKOS/pair_eam_fs_kokkos.cpp +++ b/src/KOKKOS/pair_eam_fs_kokkos.cpp @@ -299,27 +299,14 @@ void PairEAMFSKokkos::init_style() PairEAM::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with pair eam/kk/fs"); - } - + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_eam_kokkos.cpp b/src/KOKKOS/pair_eam_kokkos.cpp index daa9b38252..ac3b0d3f07 100644 --- a/src/KOKKOS/pair_eam_kokkos.cpp +++ b/src/KOKKOS/pair_eam_kokkos.cpp @@ -294,27 +294,14 @@ void PairEAMKokkos::init_style() PairEAM::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with pair eam/kk"); - } - + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_exp6_rx_kokkos.cpp b/src/KOKKOS/pair_exp6_rx_kokkos.cpp index d96e9f3f65..de9d2433ae 100644 --- a/src/KOKKOS/pair_exp6_rx_kokkos.cpp +++ b/src/KOKKOS/pair_exp6_rx_kokkos.cpp @@ -99,26 +99,14 @@ void PairExp6rxKokkos::init_style() { PairExp6rx::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with exp6/rx/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_gran_hooke_history_kokkos.cpp b/src/KOKKOS/pair_gran_hooke_history_kokkos.cpp index b47b5f5a47..1456bab0bc 100644 --- a/src/KOKKOS/pair_gran_hooke_history_kokkos.cpp +++ b/src/KOKKOS/pair_gran_hooke_history_kokkos.cpp @@ -81,23 +81,15 @@ void PairGranHookeHistoryKokkos::init_style() PairGranHookeHistory::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) error->all(FLERR,"Must use half neighbor list with gran/hooke/history/kk"); - } } /* ---------------------------------------------------------------------- */ @@ -175,7 +167,7 @@ void PairGranHookeHistoryKokkos::compute(int eflag_in, int vflag_in) EV_FLOAT ev; - if (lmp->kokkos->neighflag == HALF) { + if (neighflag == HALF) { if (force->newton_pair) { if (vflag_atom) { if (shearupdate) { diff --git a/src/KOKKOS/pair_hybrid_kokkos.cpp b/src/KOKKOS/pair_hybrid_kokkos.cpp index 00abc36768..dd43ad8841 100644 --- a/src/KOKKOS/pair_hybrid_kokkos.cpp +++ b/src/KOKKOS/pair_hybrid_kokkos.cpp @@ -71,8 +71,7 @@ void PairHybridKokkos::compute(int eflag, int vflag) // if so, reset vflag as if global component were VIRIAL_PAIR // necessary since one or more sub-styles cannot compute virial as F dot r - int neighflag = lmp->kokkos->neighflag; - if (neighflag == FULL) no_virial_fdotr_compute = 1; + if (lmp->kokkos->neighflag == FULL) no_virial_fdotr_compute = 1; if (no_virial_fdotr_compute && (vflag & VIRIAL_FDOTR)) vflag = VIRIAL_PAIR | (vflag & ~VIRIAL_FDOTR); diff --git a/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp index ab49237f4e..1b0b426aa7 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp @@ -17,18 +17,20 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmm_coul_charmm_implicit_kokkos.h" -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include using namespace LAMMPS_NS; @@ -432,26 +434,14 @@ void PairLJCharmmCoulCharmmImplicitKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/charmm/coul/charmm/implicit/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp index 982ec9d99e..501b80fe85 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmm_coul_charmm_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -433,26 +435,14 @@ void PairLJCharmmCoulCharmmKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/charmm/coul/charmm/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp index 0a650e30e1..2b846c0a85 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmm_coul_long_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -441,26 +443,14 @@ void PairLJCharmmCoulLongKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/charmm/coul/long/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp b/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp index eb9baa0e92..0f8e426521 100644 --- a/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp @@ -13,8 +13,7 @@ ------------------------------------------------------------------------- */ #include "pair_lj_class2_coul_cut_kokkos.h" -#include -#include + #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" @@ -28,6 +27,9 @@ #include "error.h" #include "atom_masks.h" +#include +#include + using namespace LAMMPS_NS; #define KOKKOS_CUDA_MAX_THREADS 256 @@ -283,26 +285,14 @@ void PairLJClass2CoulCutKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/class2/coul/cut/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp index 3606b979c6..64ab396824 100644 --- a/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp @@ -13,19 +13,21 @@ ------------------------------------------------------------------------- */ #include "pair_lj_class2_coul_long_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -441,26 +443,14 @@ void PairLJClass2CoulLongKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/class2/coul/long/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_class2_kokkos.cpp b/src/KOKKOS/pair_lj_class2_kokkos.cpp index c1a16a0078..b5866066d3 100644 --- a/src/KOKKOS/pair_lj_class2_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_lj_class2_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -222,26 +224,14 @@ void PairLJClass2Kokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/class2/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp index 9a2a5ce673..c8379107f4 100644 --- a/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp @@ -13,19 +13,21 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_coul_cut_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -274,26 +276,14 @@ void PairLJCutCoulCutKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/cut/coul/cut/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp index 9673796205..ed1b2c05d5 100644 --- a/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_coul_debye_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -303,26 +305,14 @@ void PairLJCutCoulDebyeKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/cut/coul/debye/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp index 8f25ee45dc..d04e66057a 100644 --- a/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp @@ -17,20 +17,22 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_coul_dsf_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "respa.h" +#include "kokkos.h" #include "math_const.h" #include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neigh_list.h" +#include "neigh_request.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -298,26 +300,14 @@ void PairLJCutCoulDSFKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/cut/coul/cut/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp index 2d4833843c..d3bb7e8819 100644 --- a/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp @@ -13,20 +13,22 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_coul_long_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "respa.h" +#include "kokkos.h" #include "math_const.h" #include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neigh_list.h" +#include "neigh_request.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -434,26 +436,14 @@ void PairLJCutCoulLongKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/cut/coul/long/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_cut_kokkos.cpp b/src/KOKKOS/pair_lj_cut_kokkos.cpp index 5a5edcab76..487c43cef6 100644 --- a/src/KOKKOS/pair_lj_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_kokkos.cpp @@ -13,18 +13,20 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_kokkos.h" -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include using namespace LAMMPS_NS; @@ -214,26 +216,14 @@ void PairLJCutKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/cut/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_expand_kokkos.cpp b/src/KOKKOS/pair_lj_expand_kokkos.cpp index 14342357ec..25a562d5a6 100644 --- a/src/KOKKOS/pair_lj_expand_kokkos.cpp +++ b/src/KOKKOS/pair_lj_expand_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_lj_expand_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -226,26 +228,14 @@ void PairLJExpandKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/expand/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp b/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp index 069b4068e8..4114c8f5a6 100644 --- a/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp +++ b/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp @@ -17,8 +17,7 @@ ------------------------------------------------------------------------- */ #include "pair_lj_gromacs_coul_gromacs_kokkos.h" -#include -#include + #include "kokkos.h" #include "atom_kokkos.h" #include "force.h" @@ -31,6 +30,9 @@ #include "error.h" #include "atom_masks.h" +#include +#include + using namespace LAMMPS_NS; #define KOKKOS_CUDA_MAX_THREADS 256 @@ -418,26 +420,14 @@ void PairLJGromacsCoulGromacsKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/gromacs/coul/gromacs/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_gromacs_kokkos.cpp b/src/KOKKOS/pair_lj_gromacs_kokkos.cpp index 4647b14ade..ee038c9c17 100644 --- a/src/KOKKOS/pair_lj_gromacs_kokkos.cpp +++ b/src/KOKKOS/pair_lj_gromacs_kokkos.cpp @@ -17,19 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_lj_gromacs_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; @@ -261,26 +263,14 @@ void PairLJGromacsKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/gromacs/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_lj_sdk_kokkos.cpp b/src/KOKKOS/pair_lj_sdk_kokkos.cpp index 79452765c5..aed03f157d 100644 --- a/src/KOKKOS/pair_lj_sdk_kokkos.cpp +++ b/src/KOKKOS/pair_lj_sdk_kokkos.cpp @@ -13,23 +13,24 @@ ------------------------------------------------------------------------- */ #include "pair_lj_sdk_kokkos.h" -#include -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" -#include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "update.h" -#include "respa.h" -#include "memory_kokkos.h" -#include "error.h" #include "atom_masks.h" +#include "comm.h" +#include "error.h" +#include "force.h" +#include "kokkos.h" +#include "memory_kokkos.h" +#include "neigh_request.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" #include "lj_sdk_common.h" +#include +#include + using namespace LAMMPS_NS; using namespace LJSDKParms; @@ -254,26 +255,14 @@ void PairLJSDKKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/sdk/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_morse_kokkos.cpp b/src/KOKKOS/pair_morse_kokkos.cpp index d6663608fb..7619883047 100644 --- a/src/KOKKOS/pair_morse_kokkos.cpp +++ b/src/KOKKOS/pair_morse_kokkos.cpp @@ -17,20 +17,22 @@ ------------------------------------------------------------------------- */ #include "pair_morse_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "respa.h" +#include "kokkos.h" #include "math_const.h" #include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neigh_list.h" +#include "neigh_request.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -229,26 +231,14 @@ void PairMorseKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with morse/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp b/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp index c2942288ff..96b6e75307 100644 --- a/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp +++ b/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp @@ -31,7 +31,6 @@ #include "force.h" #include "kokkos.h" #include "math_const.h" -#include "math_const.h" #include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" @@ -99,26 +98,14 @@ void PairMultiLucyRXKokkos::init_style() { PairMultiLucyRX::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with multi/lucy/rx/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_reaxff_kokkos.cpp b/src/KOKKOS/pair_reaxff_kokkos.cpp index ab890ac8b7..fd73bd7c4c 100644 --- a/src/KOKKOS/pair_reaxff_kokkos.cpp +++ b/src/KOKKOS/pair_reaxff_kokkos.cpp @@ -166,24 +166,15 @@ void PairReaxFFKokkos::init_style() } } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - neighbor->requests[irequest]->ghost = 1; - } else { + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) error->all(FLERR,"Must use half neighbor list with pair style reaxff/kk"); - } allocate(); setup(); diff --git a/src/KOKKOS/pair_snap_kokkos_impl.h b/src/KOKKOS/pair_snap_kokkos_impl.h index 49c022105d..1d83064136 100644 --- a/src/KOKKOS/pair_snap_kokkos_impl.h +++ b/src/KOKKOS/pair_snap_kokkos_impl.h @@ -17,20 +17,22 @@ Evan Weinberg (NVIDIA) ------------------------------------------------------------------------- */ +#include "pair_snap_kokkos.h" + +#include "atom_kokkos.h" +#include "atom_masks.h" +#include "comm.h" +#include "error.h" +#include "force.h" +#include "kokkos.h" +#include "memory_kokkos.h" +#include "neighbor_kokkos.h" +#include "neigh_request.h" +#include "sna.h" + #include #include #include -#include "pair_snap_kokkos.h" -#include "atom_kokkos.h" -#include "error.h" -#include "force.h" -#include "atom_masks.h" -#include "memory_kokkos.h" -#include "neigh_request.h" -#include "neighbor_kokkos.h" -#include "kokkos.h" -#include "sna.h" -#include "comm.h" #define MAXLINE 1024 #define MAXWORD 3 @@ -100,23 +102,14 @@ void PairSNAPKokkos::init_style() if (force->newton_pair == 0) error->all(FLERR,"Pair style SNAP requires newton pair on"); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS - neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->request(this,instance_me); - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == HALF || neighflag == HALFTHREAD) { // still need atomics, even though using a full neigh list - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else { + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (lmp->kokkos->neighflag == FULL) error->all(FLERR,"Must use half neighbor list style with pair snap/kk"); - } } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_sw_kokkos.cpp b/src/KOKKOS/pair_sw_kokkos.cpp index dec7d12ebb..f2d2058504 100644 --- a/src/KOKKOS/pair_sw_kokkos.cpp +++ b/src/KOKKOS/pair_sw_kokkos.cpp @@ -17,20 +17,22 @@ ------------------------------------------------------------------------- */ #include "pair_sw_kokkos.h" -#include -#include "kokkos.h" -#include "pair_kokkos.h" + #include "atom_kokkos.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "force.h" -#include "comm.h" -#include "memory_kokkos.h" -#include "neighbor.h" -#include "neigh_list_kokkos.h" -#include "error.h" #include "atom_masks.h" +#include "comm.h" +#include "error.h" +#include "force.h" +#include "kokkos.h" #include "math_const.h" +#include "memory_kokkos.h" +#include "neigh_list_kokkos.h" +#include "neigh_request.h" +#include "neighbor.h" +#include "neighbor.h" +#include "pair_kokkos.h" + +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -604,29 +606,16 @@ void PairSWKokkos::init_style() { PairSW::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); // always request a full neighbor list - - if (neighflag == FULL || neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - if (neighflag == FULL) - neighbor->requests[irequest]->ghost = 1; - else - neighbor->requests[irequest]->ghost = 0; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with pair sw/kk"); - } + request->enable_full(); + if (neighflag == FULL) request->enable_ghost(); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_table_kokkos.cpp b/src/KOKKOS/pair_table_kokkos.cpp index 158af4ed70..59b2c0516f 100644 --- a/src/KOKKOS/pair_table_kokkos.cpp +++ b/src/KOKKOS/pair_table_kokkos.cpp @@ -17,16 +17,18 @@ ------------------------------------------------------------------------- */ #include "pair_table_kokkos.h" -#include -#include "kokkos.h" + #include "atom.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neighbor.h" + +#include using namespace LAMMPS_NS; @@ -510,25 +512,12 @@ void PairTableKokkos::compute_table(Table *tb) template void PairTableKokkos::init_style() { - neighbor->request(this,instance_me); neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/cut/kk"); - } + auto request = neighbor->add_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } namespace LAMMPS_NS { diff --git a/src/KOKKOS/pair_table_rx_kokkos.cpp b/src/KOKKOS/pair_table_rx_kokkos.cpp index b7b9560bc1..0d3f88d10d 100644 --- a/src/KOKKOS/pair_table_rx_kokkos.cpp +++ b/src/KOKKOS/pair_table_rx_kokkos.cpp @@ -18,24 +18,24 @@ #include "pair_table_rx_kokkos.h" -#include -#include -#include "kokkos.h" #include "atom.h" -#include "force.h" +#include "atom_masks.h" #include "comm.h" -#include "neighbor.h" +#include "error.h" +#include "fix.h" +#include "force.h" +#include "kokkos.h" +#include "kokkos.h" +#include "kokkos_few.h" +#include "memory_kokkos.h" +#include "modify.h" #include "neigh_list.h" #include "neigh_request.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" -#include "fix.h" -#include "kokkos_few.h" -#include "kokkos.h" -#include "modify.h" +#include "neighbor.h" #include +#include +#include using namespace LAMMPS_NS; @@ -1265,25 +1265,12 @@ void PairTableRXKokkos::compute_table(Table *tb) template void PairTableRXKokkos::init_style() { - neighbor->request(this,instance_me); neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/cut/kk"); - } + auto request = neighbor->add_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } namespace LAMMPS_NS { diff --git a/src/KOKKOS/pair_tersoff_kokkos.cpp b/src/KOKKOS/pair_tersoff_kokkos.cpp index c40efef8fa..1bab686926 100644 --- a/src/KOKKOS/pair_tersoff_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_kokkos.cpp @@ -27,20 +27,22 @@ ------------------------------------------------------------------------- */ #include "pair_tersoff_kokkos.h" -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "neigh_list_kokkos.h" +#include "kokkos.h" #include "math_const.h" #include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neigh_list_kokkos.h" +#include "neigh_request.h" +#include "neighbor.h" #include "suffix.h" +#include + using namespace LAMMPS_NS; using namespace MathConst; @@ -96,31 +98,16 @@ void PairTersoffKokkos::init_style() { PairTersoff::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + request->enable_full(); if (neighflag == FULL) error->all(FLERR,"Cannot (yet) use full neighbor list style with tersoff/kk"); - - if (neighflag == FULL || neighflag == HALF || neighflag == HALFTHREAD) { - //if (neighflag == FULL || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - if (neighflag == FULL) - neighbor->requests[irequest]->ghost = 1; - else - neighbor->requests[irequest]->ghost = 0; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with tersoff/kk"); - } } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_tersoff_mod_kokkos.cpp b/src/KOKKOS/pair_tersoff_mod_kokkos.cpp index 388e216a41..2f354a93a9 100644 --- a/src/KOKKOS/pair_tersoff_mod_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_mod_kokkos.cpp @@ -17,20 +17,22 @@ ------------------------------------------------------------------------- */ #include "pair_tersoff_mod_kokkos.h" -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "neigh_list_kokkos.h" +#include "kokkos.h" #include "math_const.h" #include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neigh_list_kokkos.h" +#include "neigh_request.h" +#include "neighbor.h" #include "suffix.h" +#include + using namespace LAMMPS_NS; using namespace MathConst; @@ -86,30 +88,15 @@ void PairTersoffMODKokkos::init_style() { PairTersoffMOD::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); if (neighflag == FULL) error->all(FLERR,"Cannot (yet) use full neighbor list style with tersoff/mod/kk"); - - if (neighflag == FULL || neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - if (neighflag == FULL) - neighbor->requests[irequest]->ghost = 1; - else - neighbor->requests[irequest]->ghost = 0; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with tersoff/mod/kk"); - } } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp b/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp index 9dc82be8c0..56c73cc3ce 100644 --- a/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp @@ -17,21 +17,23 @@ ------------------------------------------------------------------------- */ #include "pair_tersoff_zbl_kokkos.h" -#include -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "neigh_list_kokkos.h" -#include "update.h" +#include "kokkos.h" #include "math_const.h" #include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "neigh_list_kokkos.h" +#include "neigh_request.h" +#include "neighbor.h" #include "suffix.h" +#include "update.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -99,30 +101,16 @@ void PairTersoffZBLKokkos::init_style() { PairTersoffZBL::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + request->enable_full(); if (neighflag == FULL) error->all(FLERR,"Cannot (yet) use full neighbor list style with tersoff/zbl/kk"); - - if (neighflag == FULL || neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - if (neighflag == FULL) - neighbor->requests[irequest]->ghost = 1; - else - neighbor->requests[irequest]->ghost = 0; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with tersoff/zbl/kk"); - } } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_vashishta_kokkos.cpp b/src/KOKKOS/pair_vashishta_kokkos.cpp index 58ec9ca82f..432cfbcf20 100644 --- a/src/KOKKOS/pair_vashishta_kokkos.cpp +++ b/src/KOKKOS/pair_vashishta_kokkos.cpp @@ -580,29 +580,15 @@ void PairVashishtaKokkos::init_style() { PairVashishta::init_style(); - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - // always request a full neighbor list - - if (neighflag == FULL || neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - if (neighflag == FULL) - neighbor->requests[irequest]->ghost = 1; - else - neighbor->requests[irequest]->ghost = 0; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with pair vashishta/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + request->enable_full(); + if (neighflag == FULL) request->enable_ghost(); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pair_yukawa_kokkos.cpp b/src/KOKKOS/pair_yukawa_kokkos.cpp index 9654185b73..7672385dfb 100644 --- a/src/KOKKOS/pair_yukawa_kokkos.cpp +++ b/src/KOKKOS/pair_yukawa_kokkos.cpp @@ -17,18 +17,20 @@ ------------------------------------------------------------------------- */ #include "pair_yukawa_kokkos.h" -#include -#include "kokkos.h" + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" +#include "update.h" + +#include using namespace LAMMPS_NS; @@ -102,26 +104,14 @@ void PairYukawaKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with yukawa/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- diff --git a/src/KOKKOS/pair_zbl_kokkos.cpp b/src/KOKKOS/pair_zbl_kokkos.cpp index 87a0f5d353..316c583717 100644 --- a/src/KOKKOS/pair_zbl_kokkos.cpp +++ b/src/KOKKOS/pair_zbl_kokkos.cpp @@ -17,22 +17,24 @@ ------------------------------------------------------------------------- */ #include "pair_zbl_kokkos.h" -#include -#include + #include "atom_kokkos.h" +#include "atom_masks.h" +#include "error.h" #include "force.h" -#include "neighbor.h" +#include "kokkos.h" +#include "memory_kokkos.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" +#include "neighbor.h" #include "respa.h" -#include "memory_kokkos.h" -#include "error.h" -#include "atom_masks.h" -#include "kokkos.h" +#include "update.h" #include "pair_zbl_const.h" +#include +#include + // From J.F. Zeigler, J. P. Biersack and U. Littmark, // "The Stopping and Range of Ions in Matter" volume 1, Pergamon, 1985. @@ -88,26 +90,14 @@ void PairZBLKokkos::init_style() error->all(FLERR,"Cannot use Kokkos pair style with rRESPA inner/middle"); } - // irequest = neigh request made by parent class + // adjust neighbor list request for KOKKOS neighflag = lmp->kokkos->neighflag; - int irequest = neighbor->nrequest - 1; - - neighbor->requests[irequest]-> - kokkos_host = std::is_same::value && - !std::is_same::value; - neighbor->requests[irequest]-> - kokkos_device = std::is_same::value; - - if (neighflag == FULL) { - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->half = 0; - } else if (neighflag == HALF || neighflag == HALFTHREAD) { - neighbor->requests[irequest]->full = 0; - neighbor->requests[irequest]->half = 1; - } else { - error->all(FLERR,"Cannot use chosen neighbor list style with lj/cut/kk"); - } + auto request = neighbor->find_request(this); + request->set_kokkos_host(std::is_same::value && + !std::is_same::value); + request->set_kokkos_device(std::is_same::value); + if (neighflag == FULL) request->enable_full(); } /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pppm_kokkos.cpp b/src/KOKKOS/pppm_kokkos.cpp index a5073129e8..432e866b2c 100644 --- a/src/KOKKOS/pppm_kokkos.cpp +++ b/src/KOKKOS/pppm_kokkos.cpp @@ -1898,7 +1898,6 @@ void PPPMKokkos::poisson_ik_triclinic() numz_fft = nzhi_fft-nzlo_fft + 1; numy_fft = nyhi_fft-nylo_fft + 1; numx_fft = nxhi_fft-nxlo_fft + 1; - const int inum_fft = numz_fft*numy_fft*numx_fft; numz_inout = (nzhi_in-nzlo_out)-(nzlo_in-nzlo_out) + 1; numy_inout = (nyhi_in-nylo_out)-(nylo_in-nylo_out) + 1; diff --git a/src/KSPACE/pair_born_coul_long.cpp b/src/KSPACE/pair_born_coul_long.cpp index c602189c23..8298fe792c 100644 --- a/src/KSPACE/pair_born_coul_long.cpp +++ b/src/KSPACE/pair_born_coul_long.cpp @@ -17,18 +17,19 @@ ------------------------------------------------------------------------- */ #include "pair_born_coul_long.h" -#include -#include + #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -380,7 +381,7 @@ void PairBornCoulLong::init_style() error->all(FLERR,"Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; - neighbor->request(this,instance_me); + neighbor->add_request(this); // setup force tables diff --git a/src/KSPACE/pair_buck_coul_long.cpp b/src/KSPACE/pair_buck_coul_long.cpp index 7cdab7d84d..50e5c9052c 100644 --- a/src/KSPACE/pair_buck_coul_long.cpp +++ b/src/KSPACE/pair_buck_coul_long.cpp @@ -14,18 +14,18 @@ #include "pair_buck_coul_long.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -369,7 +369,7 @@ void PairBuckCoulLong::init_style() error->all(FLERR,"Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; - neighbor->request(this,instance_me); + neighbor->add_request(this); // setup force tables diff --git a/src/KSPACE/pair_buck_long_coul_long.cpp b/src/KSPACE/pair_buck_long_coul_long.cpp index eb70a1807a..1af0857668 100644 --- a/src/KSPACE/pair_buck_long_coul_long.cpp +++ b/src/KSPACE/pair_buck_long_coul_long.cpp @@ -26,7 +26,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "respa.h" #include "update.h" @@ -262,21 +261,14 @@ void PairBuckLongCoulLong::init_style() // request regular or rRESPA neighbor lists if neighrequest_flag != 0 if (force->kspace->neighrequest_flag) { - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); } cut_coulsq = cut_coul * cut_coul; diff --git a/src/KSPACE/pair_coul_long.cpp b/src/KSPACE/pair_coul_long.cpp index b4b467e6bc..6b991beec7 100644 --- a/src/KSPACE/pair_coul_long.cpp +++ b/src/KSPACE/pair_coul_long.cpp @@ -233,7 +233,7 @@ void PairCoulLong::init_style() { if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/coul/long requires atom attribute q"); - neighbor->request(this, instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; diff --git a/src/KSPACE/pair_coul_streitz.cpp b/src/KSPACE/pair_coul_streitz.cpp index 27a8f87107..f388f4cc88 100644 --- a/src/KSPACE/pair_coul_streitz.cpp +++ b/src/KSPACE/pair_coul_streitz.cpp @@ -26,7 +26,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -143,9 +142,7 @@ void PairCoulStreitz::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style coul/streitz requires atom attribute q"); - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); cut_coulsq = cut_coul * cut_coul; diff --git a/src/KSPACE/pair_lj_charmm_coul_long.cpp b/src/KSPACE/pair_lj_charmm_coul_long.cpp index db1de908a3..67e0a328e5 100644 --- a/src/KSPACE/pair_lj_charmm_coul_long.cpp +++ b/src/KSPACE/pair_lj_charmm_coul_long.cpp @@ -17,20 +17,20 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmm_coul_long.h" -#include -#include + #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "respa.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" +#include +#include using namespace LAMMPS_NS; @@ -687,21 +687,14 @@ void PairLJCharmmCoulLong::init_style() // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); // require cut_lj_inner < cut_lj diff --git a/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp b/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp index 42fdb47338..1fb72a3108 100644 --- a/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp +++ b/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp @@ -21,20 +21,20 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmmfsw_coul_long.h" -#include -#include + #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "respa.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "respa.h" +#include "update.h" +#include +#include using namespace LAMMPS_NS; @@ -738,20 +738,14 @@ void PairLJCharmmfswCoulLong::init_style() // request regular or rRESPA neighbor lists - int irequest; + int list_style = NeighConst::REQ_DEFAULT; - int respa = 0; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); // require cut_lj_inner < cut_lj diff --git a/src/KSPACE/pair_lj_cut_coul_long.cpp b/src/KSPACE/pair_lj_cut_coul_long.cpp index b438e9e31e..6a3597a0ae 100644 --- a/src/KSPACE/pair_lj_cut_coul_long.cpp +++ b/src/KSPACE/pair_lj_cut_coul_long.cpp @@ -26,7 +26,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "respa.h" #include "update.h" @@ -656,21 +655,14 @@ void PairLJCutCoulLong::init_style() // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); cut_coulsq = cut_coul * cut_coul; diff --git a/src/KSPACE/pair_lj_long_coul_long.cpp b/src/KSPACE/pair_lj_long_coul_long.cpp index afd880a27b..a7d4464094 100644 --- a/src/KSPACE/pair_lj_long_coul_long.cpp +++ b/src/KSPACE/pair_lj_long_coul_long.cpp @@ -28,7 +28,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "respa.h" #include "update.h" @@ -231,7 +230,7 @@ void PairLJLongCoulLong::init_style() if (!atom->q_flag && (ewald_order&(1<<1))) error->all(FLERR, - "Invoking coulombic in pair style lj/long/coul/long requires atom attribute q"); + "Invoking coulombic in pair style lj/long/coul/long requires atom attribute q"); // ensure use of KSpace long-range solver, set two g_ewalds @@ -255,21 +254,14 @@ void PairLJLongCoulLong::init_style() // request regular or rRESPA neighbor lists if neighrequest_flag != 0 if (force->kspace->neighrequest_flag) { - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; - if (update->whichflag == 1 && utils::strmatch(update->integrate_style,"^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this,instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); } cut_coulsq = cut_coul * cut_coul; diff --git a/src/MACHDYN/pair_smd_hertz.cpp b/src/MACHDYN/pair_smd_hertz.cpp index a5355e46e0..d115e71cdf 100644 --- a/src/MACHDYN/pair_smd_hertz.cpp +++ b/src/MACHDYN/pair_smd_hertz.cpp @@ -29,19 +29,17 @@ #include "pair_smd_hertz.h" -#include - -#include #include "atom.h" -#include "domain.h" -#include "force.h" #include "comm.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "memory.h" +#include "domain.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; @@ -329,8 +327,7 @@ void PairHertz::init_style() { if (!atom->contact_radius_flag) error->all(FLERR, "Pair style smd/hertz requires atom style with contact_radius"); - int irequest = neighbor->request(this); - neighbor->requests[irequest]->size = 1; + neighbor->add_request(this, NeighConst::REQ_SIZE); // set maxrad_dynamic and maxrad_frozen for each type // include future Fix pour particles as dynamic diff --git a/src/MACHDYN/pair_smd_tlsph.cpp b/src/MACHDYN/pair_smd_tlsph.cpp index 748c6b2c0d..5fcc8742de 100644 --- a/src/MACHDYN/pair_smd_tlsph.cpp +++ b/src/MACHDYN/pair_smd_tlsph.cpp @@ -25,27 +25,27 @@ #include "pair_smd_tlsph.h" +#include "fix_smd_tlsph_reference_configuration.h" + +#include "atom.h" +#include "comm.h" +#include "domain.h" +#include "error.h" +#include "fix.h" +#include "force.h" +#include "group.h" +#include "memory.h" +#include "modify.h" +#include "neighbor.h" +#include "smd_kernels.h" +#include "smd_material_models.h" +#include "smd_math.h" +#include "update.h" + #include #include - -#include #include -#include "fix_smd_tlsph_reference_configuration.h" -#include "atom.h" -#include "domain.h" -#include "group.h" -#include "force.h" -#include "update.h" -#include "modify.h" -#include "fix.h" -#include "comm.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "memory.h" -#include "error.h" -#include "smd_material_models.h" -#include "smd_kernels.h" -#include "smd_math.h" +#include using namespace SMD_Kernels; using namespace Eigen; @@ -1725,8 +1725,7 @@ void PairTlsph::init_style() { } // request a granular neighbor list - int irequest = neighbor->request(this); - neighbor->requests[irequest]->size = 1; + neighbor->add_request(this, NeighConst::REQ_SIZE); // set maxrad_dynamic and maxrad_frozen for each type // include future Fix pour particles as dynamic diff --git a/src/MACHDYN/pair_smd_triangulated_surface.cpp b/src/MACHDYN/pair_smd_triangulated_surface.cpp index 0d6abb6dfb..cecdf43ff0 100644 --- a/src/MACHDYN/pair_smd_triangulated_surface.cpp +++ b/src/MACHDYN/pair_smd_triangulated_surface.cpp @@ -29,20 +29,18 @@ #include "pair_smd_triangulated_surface.h" -#include +#include "atom.h" +#include "comm.h" +#include "domain.h" +#include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include #include #include -#include "atom.h" -#include "domain.h" -#include "force.h" -#include "comm.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "memory.h" -#include "error.h" - using namespace std; using namespace LAMMPS_NS; @@ -411,14 +409,7 @@ void PairTriSurf::init_style() { if (!atom->contact_radius_flag) error->all(FLERR, "Pair style smd/smd/tri_surface requires atom style with contact_radius"); - // old: half list - int irequest = neighbor->request(this); - neighbor->requests[irequest]->size = 1; - - // need a full neighbor list -// int irequest = neighbor->request(this); -// neighbor->requests[irequest]->half = 0; -// neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_SIZE); // set maxrad_dynamic and maxrad_frozen for each type // include future Fix pour particles as dynamic diff --git a/src/MACHDYN/pair_smd_ulsph.cpp b/src/MACHDYN/pair_smd_ulsph.cpp index 71091a0419..d4e7053446 100644 --- a/src/MACHDYN/pair_smd_ulsph.cpp +++ b/src/MACHDYN/pair_smd_ulsph.cpp @@ -31,7 +31,6 @@ #include "error.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "smd_kernels.h" #include "smd_material_models.h" @@ -1434,10 +1433,8 @@ double PairULSPH::init_one(int i, int j) { void PairULSPH::init_style() { int i; -//printf(" in init style\n"); -// request a granular neighbor list - int irequest = neighbor->request(this); - neighbor->requests[irequest]->size = 1; + // request a granular neighbor list + neighbor->add_request(this, NeighConst::REQ_SIZE); // set maxrad_dynamic and maxrad_frozen for each type // include future Fix pour particles as dynamic diff --git a/src/MANYBODY/pair_adp.cpp b/src/MANYBODY/pair_adp.cpp index 0931f9c222..819a57efa2 100644 --- a/src/MANYBODY/pair_adp.cpp +++ b/src/MANYBODY/pair_adp.cpp @@ -512,7 +512,7 @@ void PairADP::init_style() file2array(); array2spline(); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_airebo.cpp b/src/MANYBODY/pair_airebo.cpp index 29d2121f1f..90e43b7a6d 100644 --- a/src/MANYBODY/pair_airebo.cpp +++ b/src/MANYBODY/pair_airebo.cpp @@ -31,7 +31,6 @@ #include "memory.h" #include "my_page.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "text_file_reader.h" @@ -237,10 +236,7 @@ void PairAIREBO::init_style() // need a full neighbor list, including neighbors of ghosts - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this,NeighConst::REQ_FULL|NeighConst::REQ_GHOST); // local REBO neighbor list // create pages if first time or if neighbor pgsize/oneatom has changed diff --git a/src/MANYBODY/pair_atm.cpp b/src/MANYBODY/pair_atm.cpp index f7eda909e6..4b61e575a3 100644 --- a/src/MANYBODY/pair_atm.cpp +++ b/src/MANYBODY/pair_atm.cpp @@ -18,7 +18,6 @@ #include "pair_atm.h" -#include #include "atom.h" #include "citeme.h" #include "comm.h" @@ -26,9 +25,9 @@ #include "force.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" +#include using namespace LAMMPS_NS; @@ -257,9 +256,7 @@ void PairATM::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_bop.cpp b/src/MANYBODY/pair_bop.cpp index ebb576dcc9..b3aa470592 100644 --- a/src/MANYBODY/pair_bop.cpp +++ b/src/MANYBODY/pair_bop.cpp @@ -46,7 +46,6 @@ #include "math_special.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "tabular_function.h" @@ -417,10 +416,7 @@ void PairBOP::init_style() // need a full neighbor list and neighbors of ghosts - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); } /* ---------------------------------------------------------------------- */ diff --git a/src/MANYBODY/pair_comb.cpp b/src/MANYBODY/pair_comb.cpp index 82a47b9f6a..90e2d72512 100644 --- a/src/MANYBODY/pair_comb.cpp +++ b/src/MANYBODY/pair_comb.cpp @@ -32,7 +32,6 @@ #include "memory.h" #include "my_page.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -108,12 +107,12 @@ PairComb::~PairComb() memory->destroy(sht_num); memory->sfree(sht_first); - delete [] ipage; + delete[] ipage; if (allocated) { memory->destroy(setflag); memory->destroy(cutsq); - delete [] esm; + delete[] esm; } } @@ -483,9 +482,7 @@ void PairComb::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); // local Comb neighbor list // create pages if first time or if neighbor pgsize/oneatom has changed @@ -496,7 +493,7 @@ void PairComb::init_style() if (oneatom != neighbor->oneatom) create = 1; if (create) { - delete [] ipage; + delete[] ipage; pgsize = neighbor->pgsize; oneatom = neighbor->oneatom; diff --git a/src/MANYBODY/pair_comb3.cpp b/src/MANYBODY/pair_comb3.cpp index 8f01749358..7c126bf8ab 100644 --- a/src/MANYBODY/pair_comb3.cpp +++ b/src/MANYBODY/pair_comb3.cpp @@ -31,7 +31,6 @@ #include "memory.h" #include "my_page.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "text_file_reader.h" @@ -126,13 +125,13 @@ PairComb3::~PairComb3() memory->destroy(sht_num); memory->sfree(sht_first); - delete [] ipage; + delete[] ipage; if (allocated) { memory->destroy(setflag); memory->destroy(cutsq); memory->destroy(cutghost); - delete [] esm; + delete[] esm; } } @@ -216,11 +215,8 @@ void PairComb3::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style COMB3 requires atom attribute q"); - // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; +// need a full neighbor list + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); // local Comb neighbor list // create pages if first time or if neighbor pgsize/oneatom has changed @@ -231,7 +227,7 @@ void PairComb3::init_style() if (oneatom != neighbor->oneatom) create = 1; if (create) { - delete [] ipage; + delete[] ipage; pgsize = neighbor->pgsize; oneatom = neighbor->oneatom; @@ -2503,10 +2499,10 @@ void PairComb3::tables() } } - delete [] vrc; - delete [] rrc; - delete [] cc2; - delete [] cc3; + delete[] vrc; + delete[] rrc; + delete[] cc2; + delete[] cc3; memory->destroy(rvdw); } diff --git a/src/MANYBODY/pair_eam.cpp b/src/MANYBODY/pair_eam.cpp index fd8335fca9..77b6d551be 100644 --- a/src/MANYBODY/pair_eam.cpp +++ b/src/MANYBODY/pair_eam.cpp @@ -425,7 +425,7 @@ void PairEAM::init_style() file2array(); array2spline(); - neighbor->request(this,instance_me); + neighbor->add_request(this); embedstep = -1; } diff --git a/src/MANYBODY/pair_edip.cpp b/src/MANYBODY/pair_edip.cpp index 24a7391c92..23361e56cb 100644 --- a/src/MANYBODY/pair_edip.cpp +++ b/src/MANYBODY/pair_edip.cpp @@ -29,7 +29,6 @@ #include "force.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -747,9 +746,7 @@ void PairEDIP::init_style() // need a full neighbor list - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_edip_multi.cpp b/src/MANYBODY/pair_edip_multi.cpp index cdfe120fc4..4710dcce0a 100644 --- a/src/MANYBODY/pair_edip_multi.cpp +++ b/src/MANYBODY/pair_edip_multi.cpp @@ -28,7 +28,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -561,9 +560,7 @@ void PairEDIPMulti::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_eim.cpp b/src/MANYBODY/pair_eim.cpp index badcb28e25..5a97e23b40 100644 --- a/src/MANYBODY/pair_eim.cpp +++ b/src/MANYBODY/pair_eim.cpp @@ -382,7 +382,7 @@ void PairEIM::init_style() file2array(); array2spline(); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_extep.cpp b/src/MANYBODY/pair_extep.cpp index 68db444f31..7c75cfcfc0 100644 --- a/src/MANYBODY/pair_extep.cpp +++ b/src/MANYBODY/pair_extep.cpp @@ -27,7 +27,6 @@ #include "memory.h" #include "my_page.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -76,7 +75,7 @@ PairExTeP::~PairExTeP() memory->destroy(SR_numneigh); memory->sfree(SR_firstneigh); - delete [] ipage; + delete[] ipage; memory->destroy(Nt); memory->destroy(Nd); @@ -473,12 +472,7 @@ void PairExTeP::init_style() // need a full neighbor list - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - - // including neighbors of ghosts - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); // create pages if first time or if neighbor pgsize/oneatom has changed @@ -488,7 +482,7 @@ void PairExTeP::init_style() if (oneatom != neighbor->oneatom) create = 1; if (create) { - delete [] ipage; + delete[] ipage; pgsize = neighbor->pgsize; oneatom = neighbor->oneatom; @@ -652,7 +646,7 @@ void PairExTeP::read_file(char *file) } // deallocate words array - delete [] words; + delete[] words; /* F_IJ (3) */ // read the spline coefficients @@ -742,7 +736,7 @@ void PairExTeP::read_file(char *file) } } - delete [] words; + delete[] words; /* END F_IJ (3) */ } diff --git a/src/MANYBODY/pair_gw.cpp b/src/MANYBODY/pair_gw.cpp index 6e76c9ea39..3e948880ca 100644 --- a/src/MANYBODY/pair_gw.cpp +++ b/src/MANYBODY/pair_gw.cpp @@ -27,7 +27,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -285,9 +284,7 @@ void PairGW::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_lcbop.cpp b/src/MANYBODY/pair_lcbop.cpp index 547fc75154..a5e15479e3 100644 --- a/src/MANYBODY/pair_lcbop.cpp +++ b/src/MANYBODY/pair_lcbop.cpp @@ -24,7 +24,6 @@ #include "comm.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "my_page.h" #include "memory.h" #include "error.h" @@ -153,10 +152,7 @@ void PairLCBOP::init_style() // need a full neighbor list, including neighbors of ghosts - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); // local SR neighbor list // create pages if first time or if neighbor pgsize/oneatom has changed diff --git a/src/MANYBODY/pair_local_density.cpp b/src/MANYBODY/pair_local_density.cpp index a811927ea4..d8bfd9d03a 100644 --- a/src/MANYBODY/pair_local_density.cpp +++ b/src/MANYBODY/pair_local_density.cpp @@ -421,12 +421,12 @@ void PairLocalDensity::coeff(int narg, char **arg) void PairLocalDensity::init_style() { // spline rho and frho arrays - // request half neighbor list array2spline(); // half neighbor request - neighbor->request(this); + + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_meam_spline.cpp b/src/MANYBODY/pair_meam_spline.cpp index b09e5b6881..706c4a6013 100644 --- a/src/MANYBODY/pair_meam_spline.cpp +++ b/src/MANYBODY/pair_meam_spline.cpp @@ -579,15 +579,8 @@ void PairMEAMSpline::init_style() error->all(FLERR,"Pair style meam/spline requires newton pair on"); // Need both full and half neighbor list. - int irequest_full = neighbor->request(this,instance_me); - neighbor->requests[irequest_full]->id = 1; - neighbor->requests[irequest_full]->half = 0; - neighbor->requests[irequest_full]->full = 1; - int irequest_half = neighbor->request(this,instance_me); - neighbor->requests[irequest_half]->id = 2; - // neighbor->requests[irequest_half]->half = 1; - // neighbor->requests[irequest_half]->halffull = 1; - // neighbor->requests[irequest_half]->halffulllist = irequest_full; + neighbor->add_request(this, NeighConst::REQ_FULL)->set_id(1); + neighbor->add_request(this)->set_id(2); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_meam_sw_spline.cpp b/src/MANYBODY/pair_meam_sw_spline.cpp index 68f22a28c3..e0225818a2 100644 --- a/src/MANYBODY/pair_meam_sw_spline.cpp +++ b/src/MANYBODY/pair_meam_sw_spline.cpp @@ -381,8 +381,7 @@ void PairMEAMSWSpline::coeff(int narg, char **arg) // for now, only allow single element if (nelements > 1) - error->all(FLERR, - "Pair meam/sw/spline only supports single element potentials"); + error->all(FLERR, "Pair meam/sw/spline only supports single element potentials"); // read potential file @@ -463,12 +462,8 @@ void PairMEAMSWSpline::init_style() error->all(FLERR,"Pair style meam/sw/spline requires newton pair on"); // Need both full and half neighbor list. - int irequest_full = neighbor->request(this,instance_me); - neighbor->requests[irequest_full]->id = 1; - neighbor->requests[irequest_full]->half = 0; - neighbor->requests[irequest_full]->full = 1; - int irequest_half = neighbor->request(this,instance_me); - neighbor->requests[irequest_half]->id = 2; + neighbor->add_request(this, NeighConst::REQ_FULL)->set_id(1); + neighbor->add_request(this)->set_id(2); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_nb3b_harmonic.cpp b/src/MANYBODY/pair_nb3b_harmonic.cpp index 2b86658468..d74c504aea 100644 --- a/src/MANYBODY/pair_nb3b_harmonic.cpp +++ b/src/MANYBODY/pair_nb3b_harmonic.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -23,9 +22,9 @@ #include "comm.h" #include "error.h" #include "force.h" +#include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -33,10 +32,10 @@ #include using namespace LAMMPS_NS; +using MathConst::MY_PI; #define DELTA 4 #define SMALL 0.001 -#define PI 3.141592653589793238462643383279 /* ---------------------------------------------------------------------- */ @@ -71,15 +70,15 @@ PairNb3bHarmonic::~PairNb3bHarmonic() void PairNb3bHarmonic::compute(int eflag, int vflag) { - int i,j,k,ii,jj,kk,inum,jnum,jnumm1; - int itype,jtype,ktype,ijparam,ikparam,ijkparam; - double xtmp,ytmp,ztmp,evdwl; - double rsq1,rsq2; - double delr1[3],delr2[3],fj[3],fk[3]; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, k, ii, jj, kk, inum, jnum, jnumm1; + int itype, jtype, ktype, ijparam, ikparam, ijkparam; + double xtmp, ytmp, ztmp, evdwl; + double rsq1, rsq2; + double delr1[3], delr2[3], fj[3], fk[3]; + int *ilist, *jlist, *numneigh, **firstneigh; evdwl = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -111,10 +110,10 @@ void PairNb3bHarmonic::compute(int eflag, int vflag) delr1[0] = x[j][0] - xtmp; delr1[1] = x[j][1] - ytmp; delr1[2] = x[j][2] - ztmp; - rsq1 = delr1[0]*delr1[0] + delr1[1]*delr1[1] + delr1[2]*delr1[2]; + rsq1 = delr1[0] * delr1[0] + delr1[1] * delr1[1] + delr1[2] * delr1[2]; if (rsq1 > params[ijparam].cutsq) continue; - for (kk = jj+1; kk < jnum; kk++) { + for (kk = jj + 1; kk < jnum; kk++) { k = jlist[kk]; k &= NEIGHMASK; ktype = map[type[k]]; @@ -124,11 +123,11 @@ void PairNb3bHarmonic::compute(int eflag, int vflag) delr2[0] = x[k][0] - xtmp; delr2[1] = x[k][1] - ytmp; delr2[2] = x[k][2] - ztmp; - rsq2 = delr2[0]*delr2[0] + delr2[1]*delr2[1] + delr2[2]*delr2[2]; + rsq2 = delr2[0] * delr2[0] + delr2[1] * delr2[1] + delr2[2] * delr2[2]; if (rsq2 > params[ikparam].cutsq) continue; - threebody(¶ms[ijparam],¶ms[ikparam],¶ms[ijkparam], - rsq1,rsq2,delr1,delr2,fj,fk,eflag,evdwl); + threebody(¶ms[ijparam], ¶ms[ikparam], ¶ms[ijkparam], rsq1, rsq2, delr1, delr2, + fj, fk, eflag, evdwl); f[i][0] -= fj[0] + fk[0]; f[i][1] -= fj[1] + fk[1]; @@ -140,7 +139,7 @@ void PairNb3bHarmonic::compute(int eflag, int vflag) f[k][1] += fk[1]; f[k][2] += fk[2]; - if (evflag) ev_tally3(i,j,k,evdwl,0.0,fj,fk,delr1,delr2); + if (evflag) ev_tally3(i, j, k, evdwl, 0.0, fj, fk, delr1, delr2); } } } @@ -153,21 +152,21 @@ void PairNb3bHarmonic::compute(int eflag, int vflag) void PairNb3bHarmonic::allocate() { allocated = 1; - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(setflag, np1, np1, "pair:setflag"); + memory->create(cutsq, np1, np1, "pair:cutsq"); - map = new int[n+1]; + map = new int[np1]; } /* ---------------------------------------------------------------------- global settings ------------------------------------------------------------------------- */ -void PairNb3bHarmonic::settings(int narg, char **/*arg*/) +void PairNb3bHarmonic::settings(int narg, char ** /*arg*/) { - if (narg != 0) error->all(FLERR,"Illegal pair_style command"); + if (narg != 0) error->all(FLERR, "Illegal pair_style command"); } /* ---------------------------------------------------------------------- @@ -178,7 +177,7 @@ void PairNb3bHarmonic::coeff(int narg, char **arg) { if (!allocated) allocate(); - map_element2type(narg-3,arg+3); + map_element2type(narg - 3, arg + 3); // read potential file and initialize potential parameters @@ -186,23 +185,19 @@ void PairNb3bHarmonic::coeff(int narg, char **arg) setup_params(); } - /* ---------------------------------------------------------------------- init specific to this pair style ------------------------------------------------------------------------- */ void PairNb3bHarmonic::init_style() { - if (atom->tag_enable == 0) - error->all(FLERR,"Pair style nb3b/harmonic requires atom IDs"); + if (atom->tag_enable == 0) error->all(FLERR, "Pair style nb3b/harmonic requires atom IDs"); if (force->newton_pair == 0) - error->all(FLERR,"Pair style nb3b/harmonic requires newton pair on"); + error->all(FLERR, "Pair style nb3b/harmonic requires newton pair on"); // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- @@ -211,7 +206,7 @@ void PairNb3bHarmonic::init_style() double PairNb3bHarmonic::init_one(int i, int j) { - if (setflag[i][j] == 0) error->all(FLERR,"All pair coeffs are not set"); + if (setflag[i][j] == 0) error->all(FLERR, "All pair coeffs are not set"); return cutmax; } @@ -228,13 +223,12 @@ void PairNb3bHarmonic::read_file(char *file) if (comm->me == 0) { PotentialFileReader reader(lmp, file, "nb3b/harmonic", unit_convert_flag); - char * line; + char *line; // transparently convert units for supported conversions int unit_convert = reader.get_unit_convert(); - double conversion_factor = utils::get_conversion_factor(utils::ENERGY, - unit_convert); + double conversion_factor = utils::get_conversion_factor(utils::ENERGY, unit_convert); while ((line = reader.next_line(NPARAMS_PER_LINE))) { try { ValueTokenizer values(line); @@ -262,21 +256,20 @@ void PairNb3bHarmonic::read_file(char *file) if (nparams == maxparam) { maxparam += DELTA; - params = (Param *) memory->srealloc(params,maxparam*sizeof(Param), - "pair:params"); + params = (Param *) memory->srealloc(params, maxparam * sizeof(Param), "pair:params"); // make certain all addional allocated storage is initialized // to avoid false positives when checking with valgrind - memset(params + nparams, 0, DELTA*sizeof(Param)); + memset(params + nparams, 0, DELTA * sizeof(Param)); } params[nparams].ielement = ielement; params[nparams].jelement = jelement; params[nparams].kelement = kelement; - params[nparams].k_theta = values.next_double(); - params[nparams].theta0 = values.next_double(); - params[nparams].cutoff = values.next_double(); + params[nparams].k_theta = values.next_double(); + params[nparams].theta0 = values.next_double(); + params[nparams].cutoff = values.next_double(); if (unit_convert) params[nparams].k_theta *= conversion_factor; } catch (TokenizerException &e) { @@ -285,7 +278,7 @@ void PairNb3bHarmonic::read_file(char *file) if (params[nparams].k_theta < 0.0 || params[nparams].theta0 < 0.0 || params[nparams].cutoff < 0.0) - error->one(FLERR,"Illegal nb3b/harmonic parameter"); + error->one(FLERR, "Illegal nb3b/harmonic parameter"); nparams++; } @@ -295,17 +288,17 @@ void PairNb3bHarmonic::read_file(char *file) MPI_Bcast(&maxparam, 1, MPI_INT, 0, world); if (comm->me != 0) { - params = (Param *) memory->srealloc(params,maxparam*sizeof(Param), "pair:params"); + params = (Param *) memory->srealloc(params, maxparam * sizeof(Param), "pair:params"); } - MPI_Bcast(params, maxparam*sizeof(Param), MPI_BYTE, 0, world); + MPI_Bcast(params, maxparam * sizeof(Param), MPI_BYTE, 0, world); } /* ---------------------------------------------------------------------- */ void PairNb3bHarmonic::setup_params() { - int i,j,k,m,n; + int i, j, k, m, n; double rtmp; // set elem3param for all triplet combinations @@ -313,20 +306,19 @@ void PairNb3bHarmonic::setup_params() // do not allow for ACB in place of ABC memory->destroy(elem3param); - memory->create(elem3param,nelements,nelements,nelements,"pair:elem3param"); + memory->create(elem3param, nelements, nelements, nelements, "pair:elem3param"); for (i = 0; i < nelements; i++) for (j = 0; j < nelements; j++) for (k = 0; k < nelements; k++) { n = -1; for (m = 0; m < nparams; m++) { - if (i == params[m].ielement && j == params[m].jelement && - k == params[m].kelement) { - if (n >= 0) error->all(FLERR,"Potential file has duplicate entry"); + if (i == params[m].ielement && j == params[m].jelement && k == params[m].kelement) { + if (n >= 0) error->all(FLERR, "Potential file has duplicate entry"); n = m; } } - if (n < 0) error->all(FLERR,"Potential file is missing an entry"); + if (n < 0) error->all(FLERR, "Potential file is missing an entry"); elem3param[i][j][k] = n; } @@ -341,8 +333,7 @@ void PairNb3bHarmonic::setup_params() params[m].cut = params[m].cutoff; params[m].cutsq = params[m].cut * params[m].cut; - params[m].theta0 = params[m].theta0 / 180.0 * PI; - + params[m].theta0 = params[m].theta0 / 180.0 * MY_PI; } // set cutmax to max of all params @@ -356,48 +347,44 @@ void PairNb3bHarmonic::setup_params() /* ---------------------------------------------------------------------- */ - -void PairNb3bHarmonic::threebody(Param * /*paramij*/, Param * /*paramik*/, - Param *paramijk, - double rsq1, double rsq2, - double *delr1, double *delr2, - double *fj, double *fk, int eflag, double &eng) +void PairNb3bHarmonic::threebody(Param * /*paramij*/, Param * /*paramik*/, Param *paramijk, + double rsq1, double rsq2, double *delr1, double *delr2, double *fj, + double *fk, int eflag, double &eng) { - double dtheta,tk; - double r1,r2,c,s,a,a11,a12,a22; + double dtheta, tk; + double r1, r2, c, s, a, a11, a12, a22; // angle (cos and sin) r1 = sqrt(rsq1); r2 = sqrt(rsq2); - c = delr1[0]*delr2[0] + delr1[1]*delr2[1] + delr1[2]*delr2[2]; - c /= r1*r2; + c = delr1[0] * delr2[0] + delr1[1] * delr2[1] + delr1[2] * delr2[2]; + c /= r1 * r2; if (c > 1.0) c = 1.0; if (c < -1.0) c = -1.0; - s = sqrt(1.0 - c*c); + s = sqrt(1.0 - c * c); if (s < SMALL) s = SMALL; - s = 1.0/s; + s = 1.0 / s; // force & energy dtheta = acos(c) - paramijk->theta0; tk = paramijk->k_theta * dtheta; - if (eflag) eng = tk*dtheta; + if (eflag) eng = tk * dtheta; a = -2.0 * tk * s; - a11 = a*c / rsq1; - a12 = -a / (r1*r2); - a22 = a*c / rsq2; + a11 = a * c / rsq1; + a12 = -a / (r1 * r2); + a22 = a * c / rsq2; - fj[0] = a11*delr1[0] + a12*delr2[0]; - fj[1] = a11*delr1[1] + a12*delr2[1]; - fj[2] = a11*delr1[2] + a12*delr2[2]; - fk[0] = a22*delr2[0] + a12*delr1[0]; - fk[1] = a22*delr2[1] + a12*delr1[1]; - fk[2] = a22*delr2[2] + a12*delr1[2]; + fj[0] = a11 * delr1[0] + a12 * delr2[0]; + fj[1] = a11 * delr1[1] + a12 * delr2[1]; + fj[2] = a11 * delr1[2] + a12 * delr2[2]; + fk[0] = a22 * delr2[0] + a12 * delr1[0]; + fk[1] = a22 * delr2[1] + a12 * delr1[1]; + fk[2] = a22 * delr2[2] + a12 * delr1[2]; } - diff --git a/src/MANYBODY/pair_polymorphic.cpp b/src/MANYBODY/pair_polymorphic.cpp index 3d2bf9497e..21aba6d6df 100644 --- a/src/MANYBODY/pair_polymorphic.cpp +++ b/src/MANYBODY/pair_polymorphic.cpp @@ -29,7 +29,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "tabular_function.h" @@ -525,9 +524,7 @@ void PairPolymorphic::init_style() // need a full neighbor list - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_sw.cpp b/src/MANYBODY/pair_sw.cpp index 239b125f93..71cb1cf5bc 100644 --- a/src/MANYBODY/pair_sw.cpp +++ b/src/MANYBODY/pair_sw.cpp @@ -24,7 +24,6 @@ #include "force.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -264,9 +263,7 @@ void PairSW::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_tersoff.cpp b/src/MANYBODY/pair_tersoff.cpp index 6ad0a37ba3..c5578dfc18 100644 --- a/src/MANYBODY/pair_tersoff.cpp +++ b/src/MANYBODY/pair_tersoff.cpp @@ -28,7 +28,6 @@ #include "math_special.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "suffix.h" @@ -397,9 +396,7 @@ void PairTersoff::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this,NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_tersoff_table.cpp b/src/MANYBODY/pair_tersoff_table.cpp index 12733e1c60..dee1fd3237 100644 --- a/src/MANYBODY/pair_tersoff_table.cpp +++ b/src/MANYBODY/pair_tersoff_table.cpp @@ -30,7 +30,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -744,9 +743,7 @@ void PairTersoffTable::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MANYBODY/pair_vashishta.cpp b/src/MANYBODY/pair_vashishta.cpp index 40a42cd44b..6ce6c6f59a 100644 --- a/src/MANYBODY/pair_vashishta.cpp +++ b/src/MANYBODY/pair_vashishta.cpp @@ -26,7 +26,6 @@ #include "memory.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "potential_file_reader.h" #include @@ -270,9 +269,7 @@ void PairVashishta::init_style() // need a full neighbor list - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MC/fix_bond_create.cpp b/src/MC/fix_bond_create.cpp index eecf8763b7..c05a37cb38 100644 --- a/src/MC/fix_bond_create.cpp +++ b/src/MC/fix_bond_create.cpp @@ -14,21 +14,21 @@ #include "fix_bond_create.h" -#include -#include "update.h" -#include "respa.h" #include "atom.h" -#include "force.h" -#include "modify.h" -#include "pair.h" #include "comm.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "random_mars.h" -#include "memory.h" #include "error.h" +#include "force.h" #include "math_const.h" +#include "memory.h" +#include "modify.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "pair.h" +#include "random_mars.h" +#include "respa.h" +#include "update.h" + +#include using namespace LAMMPS_NS; using namespace FixConst; @@ -283,11 +283,7 @@ void FixBondCreate::init() } // need a half neighbor list, built every Nevery steps - - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); lastcheck = -1; } diff --git a/src/MC/fix_bond_swap.cpp b/src/MC/fix_bond_swap.cpp index c0978f51cb..c4abf31f16 100644 --- a/src/MC/fix_bond_swap.cpp +++ b/src/MC/fix_bond_swap.cpp @@ -26,7 +26,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "random_mars.h" @@ -160,10 +159,7 @@ void FixBondSwap::init() // need a half neighbor list, built every Nevery steps - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); // zero out stats diff --git a/src/MEAM/pair_meam.cpp b/src/MEAM/pair_meam.cpp index 0d7c3a0736..ffa94ca9fd 100644 --- a/src/MEAM/pair_meam.cpp +++ b/src/MEAM/pair_meam.cpp @@ -312,14 +312,10 @@ void PairMEAM::init_style() if (force->newton_pair == 0) error->all(FLERR,"Pair style MEAM requires newton pair on"); - // need full and half neighbor list + // need a full and a half neighbor list - int irequest_full = neighbor->request(this,instance_me); - neighbor->requests[irequest_full]->id = 1; - neighbor->requests[irequest_full]->half = 0; - neighbor->requests[irequest_full]->full = 1; - int irequest_half = neighbor->request(this,instance_me); - neighbor->requests[irequest_half]->id = 2; + neighbor->add_request(this, NeighConst::REQ_FULL)->set_id(1); + neighbor->add_request(this)->set_id(2); } /* ---------------------------------------------------------------------- diff --git a/src/MESONT/pair_mesocnt.cpp b/src/MESONT/pair_mesocnt.cpp index e7625f625c..9137b19e7c 100644 --- a/src/MESONT/pair_mesocnt.cpp +++ b/src/MESONT/pair_mesocnt.cpp @@ -26,7 +26,6 @@ #include "math_extra.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "update.h" @@ -503,9 +502,7 @@ void PairMesoCNT::init_style() // need a full neighbor list - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MESONT/pair_mesont_tpm.cpp b/src/MESONT/pair_mesont_tpm.cpp index b52adafe89..0c1ef1939a 100644 --- a/src/MESONT/pair_mesont_tpm.cpp +++ b/src/MESONT/pair_mesont_tpm.cpp @@ -16,7 +16,6 @@ #include "pair_mesont_tpm.h" #include "export_mesont.h" - #include "atom.h" #include "comm.h" #include "force.h" @@ -24,12 +23,11 @@ #include "error.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include #include -#include +#include #include #include @@ -765,10 +763,7 @@ void PairMESONTTPM::write_data_all(FILE *fp) { void PairMESONTTPM::init_style() { //make sure that a full list is created (including ghost nodes) - int r = neighbor->request(this,instance_me); - neighbor->requests[r]->half = false; - neighbor->requests[r]->full = true; - neighbor->requests[r]->ghost = true; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST); } void* PairMESONTTPM::extract(const char *str, int &) { diff --git a/src/MGPT/pair_mgpt.cpp b/src/MGPT/pair_mgpt.cpp index 4744693b0f..98c02732a1 100644 --- a/src/MGPT/pair_mgpt.cpp +++ b/src/MGPT/pair_mgpt.cpp @@ -769,7 +769,7 @@ void PairMGPT::compute_x(const int *nnei,const int * const *nlist, if (domain->triclinic) { if (comm->me == 0) printf("Can not handle triclinic box yet\n"); - error->all(__FILE__,__LINE__,"Can not handle triclinic cell with mgpt yet."); + error->all(FLERR,"Can not handle triclinic cell with mgpt yet."); } /* @@ -876,7 +876,7 @@ void PairMGPT::compute_x(const int *nnei,const int * const *nlist, if (first[i+1] > nneitot) { printf("nneitot = %d, short list full. i=%d\n", nneitot,i); - error->one(__FILE__,__LINE__,"Shit! Short list full\n"); + error->one(FLERR,"Shit! Short list full\n"); } } @@ -1272,7 +1272,7 @@ void PairMGPT::compute_x(const int *nnei,const int * const *nlist, " k=%d first[k]=%d first[k+1]=%d mk=%d\n", j,first[j],first[j+1],mj, k,first[k],first[k+1],mk); - error->one(__FILE__,__LINE__,"Shit, brkoen quad loop"); + error->one(FLERR,"Shit, brkoen quad loop"); } if (nlist_short[mj] == nlist_short[mk]) { @@ -1804,7 +1804,7 @@ void PairMGPT::allocate() ------------------------------------------------------------------------- */ void PairMGPT::settings(int narg, char **/*arg*/) { - if (narg != 0) error->all(__FILE__,__LINE__,"Illegal pair_style command"); + if (narg != 0) error->all(FLERR,"Illegal pair_style command"); } /* ---------------------------------------------------------------------- @@ -1816,18 +1816,18 @@ void PairMGPT::coeff(int narg, char **arg) int single_precision = 0; if (narg < 5) - error->all(__FILE__,__LINE__, + error->all(FLERR, "Not enough arguments for mgpt (MGPT) pair coefficients."); if (!allocated) allocate(); // Make sure I,J args are * * if (strcmp(arg[0],"*") != 0 || strcmp(arg[1],"*") != 0) - error->all(__FILE__,__LINE__,"Incorrect args for pair coefficients"); + error->all(FLERR,"Incorrect args for pair coefficients"); double vol; if (sscanf(arg[4], "%lg", &vol) != 1 || vol <= 0.0) - error->all(__FILE__,__LINE__,"Invalid volume in mgpt (MGPT) pair coefficients."); + error->all(FLERR,"Invalid volume in mgpt (MGPT) pair coefficients."); volpres_flag = 1; single_precision = 0; @@ -1846,8 +1846,8 @@ void PairMGPT::coeff(int narg, char **arg) char line[1024]; sprintf(line,"(In %s:%d) Invalid value for volumetric pressure argument.\n" "It should be \"volpress yes\" or \"volpress no\".\n" - "The value is \"%s\".\n",__FILE__,__LINE__,arg[iarg+1]); - error->all(__FILE__,__LINE__,line); + "The value is \"%s\".\n",FLERR,arg[iarg+1]); + error->all(FLERR,line); } volpres_tag = 1; iarg += 2; @@ -1868,8 +1868,8 @@ void PairMGPT::coeff(int narg, char **arg) "It should be e.g. \"nbody=1234\" (for single, pair, triple, and quad forces/energiers)\n" "For e.g. only pair and triple forces/energies, use \"nbody=23\".\n" "The default is \"nbody=1234\".\n" - "The current value is \"%s\".\n",__FILE__,__LINE__,arg[iarg+1]); - error->all(__FILE__,__LINE__,line); + "The current value is \"%s\".\n",FLERR,arg[iarg+1]); + error->all(FLERR,line); } nbody_tag = 1; iarg += 2; @@ -1882,8 +1882,8 @@ void PairMGPT::coeff(int narg, char **arg) char line[1024]; sprintf(line,"(In %s:%d) Invalid value for precision argument.\n" "It should be \"precision single\" or \"precision double\".\n" - "The value is \"%s\".\n",__FILE__,__LINE__,arg[iarg+1]); - error->all(__FILE__,__LINE__,line); + "The value is \"%s\".\n",FLERR,arg[iarg+1]); + error->all(FLERR,line); } precision_tag = 1; iarg += 2; @@ -1894,8 +1894,8 @@ void PairMGPT::coeff(int narg, char **arg) " volpress {yes|no} , default = yes\n" " precision {single|double} , default = double\n" " nbody {[1234,]*} , default = whichever terms potential require\n" - "The invalid argument is \"%s\".\n",__FILE__,__LINE__,arg[iarg]); - error->all(__FILE__,__LINE__,line); + "The invalid argument is \"%s\".\n",FLERR,arg[iarg]); + error->all(FLERR,line); } } @@ -1995,18 +1995,11 @@ void PairMGPT::coeff(int narg, char **arg) void PairMGPT::init_style() { if (force->newton_pair == 0) - error->all(__FILE__,__LINE__,"Pair style mgpt requires newton pair on."); + error->all(FLERR,"Pair style mgpt requires newton pair on."); - // Need full neighbor list. - int irequest_full = neighbor->request(this); - neighbor->requests[irequest_full]->id = 1; - neighbor->requests[irequest_full]->half = 0; - neighbor->requests[irequest_full]->full = 1; - neighbor->requests[irequest_full]->ghost = 1; - - // Also need half neighbor list. - int irequest_half = neighbor->request(this); - neighbor->requests[irequest_half]->id = 2; + // Need a half list and a full neighbor list with neighbors of ghosts + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_GHOST)->set_id(1); + neighbor->add_request(this)->set_id(2); } /* ---------------------------------------------------------------------- diff --git a/src/MISC/pair_agni.cpp b/src/MISC/pair_agni.cpp index f614dd9c36..46cc630f2d 100644 --- a/src/MISC/pair_agni.cpp +++ b/src/MISC/pair_agni.cpp @@ -27,7 +27,6 @@ #include "math_special.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" @@ -249,10 +248,7 @@ void PairAGNI::coeff(int narg, char **arg) void PairAGNI::init_style() { // need a full neighbor list - - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MISC/pair_srp.cpp b/src/MISC/pair_srp.cpp index 77a8eb4c2d..84f7c330a8 100644 --- a/src/MISC/pair_srp.cpp +++ b/src/MISC/pair_srp.cpp @@ -471,16 +471,13 @@ void PairSRP::init_style() // bond particles do not belong to group all // but thermo normalization is by nall // therefore should turn off normalization - int me; - MPI_Comm_rank(world,&me); char *arg1[2]; arg1[0] = (char *) "norm"; arg1[1] = (char *) "no"; output->thermo->modify_params(2, arg1); - if (me == 0) - error->message(FLERR,"Thermo normalization turned off by pair srp"); + if (comm->me == 0) error->message(FLERR,"Thermo normalization turned off by pair srp"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/MISC/pair_tracker.cpp b/src/MISC/pair_tracker.cpp index 43e65d6af7..502b04c49d 100644 --- a/src/MISC/pair_tracker.cpp +++ b/src/MISC/pair_tracker.cpp @@ -24,7 +24,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -271,15 +270,11 @@ void PairTracker::init_style() if (!atom->radius_flag && finitecutflag) error->all(FLERR, "Pair tracker requires atom attribute radius for finite cutoffs"); - // need a history neigh list - - int irequest = neighbor->request(this, instance_me); - if (finitecutflag) { - neighbor->requests[irequest]->size = 1; - neighbor->requests[irequest]->history = 1; - // history flag won't affect results, but match granular pairstyles - // so neighborlist can be copied to reduce overhead - } + int neigh_flags = NeighConst::REQ_DEFAULT; + // history flag won't affect results, but match granular pairstyles + // so neighborlist can be copied to reduce overhead + if (finitecutflag) neigh_flags |= NeighConst::REQ_SIZE | NeighConst::REQ_HISTORY; + neighbor->add_request(this, neigh_flags); // if history is stored and first init, create Fix to store history // it replaces FixDummy, created in the constructor @@ -288,10 +283,12 @@ void PairTracker::init_style() if (fix_history == nullptr) { modify->replace_fix("NEIGH_HISTORY_TRACK_DUMMY", fmt::format("NEIGH_HISTORY_TRACK all NEIGH_HISTORY {}", size_history), 1); - int ifix = modify->find_fix("NEIGH_HISTORY_TRACK"); - fix_history = (FixNeighHistory *) modify->fix[ifix]; + fix_history = (FixNeighHistory *) modify->get_fix_by_id("NEIGH_HISTORY_TRACK"); fix_history->pair = this; fix_history->use_bit_flag = 0; + } else { + fix_history = (FixNeighHistory *) modify->get_fix_by_id("NEIGH_HISTORY_TRACK"); + if (!fix_history) error->all(FLERR, "Could not find pair fix neigh history ID"); } if (finitecutflag) { @@ -342,10 +339,6 @@ void PairTracker::init_style() MPI_Allreduce(&onerad_frozen[1], &maxrad_frozen[1], atom->ntypes, MPI_DOUBLE, MPI_MAX, world); } - int ifix = modify->find_fix("NEIGH_HISTORY_TRACK"); - if (ifix < 0) error->all(FLERR, "Could not find pair fix neigh history ID"); - fix_history = (FixNeighHistory *) modify->fix[ifix]; - auto trackfixes = modify->get_fix_by_style("pair/tracker"); if (trackfixes.size() != 1) error->all(FLERR, "Must use exactly one fix pair/tracker command with pair style tracker"); diff --git a/src/ML-HDNNP/pair_hdnnp.cpp b/src/ML-HDNNP/pair_hdnnp.cpp index 8411a0c3cf..7522b301bf 100644 --- a/src/ML-HDNNP/pair_hdnnp.cpp +++ b/src/ML-HDNNP/pair_hdnnp.cpp @@ -26,7 +26,6 @@ #include "error.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -226,9 +225,7 @@ void PairHDNNP::coeff(int narg, char **arg) void PairHDNNP::init_style() { - int irequest = neighbor->request((void *) this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); // Return immediately if HDNNP setup is already completed. if (interface->isInitialized()) return; diff --git a/src/ML-IAP/compute_mliap.cpp b/src/ML-IAP/compute_mliap.cpp index 58bcd87943..915fb2724c 100644 --- a/src/ML-IAP/compute_mliap.cpp +++ b/src/ML-IAP/compute_mliap.cpp @@ -16,7 +16,7 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ -#include +#include "compute_mliap.h" #include "mliap_data.h" #include "mliap_model_linear.h" @@ -26,17 +26,17 @@ #include "mliap_model_python.h" #endif -#include "compute_mliap.h" #include "atom.h" -#include "update.h" +#include "comm.h" +#include "error.h" +#include "force.h" +#include "memory.h" #include "modify.h" #include "neighbor.h" -#include "neigh_request.h" -#include "force.h" #include "pair.h" -#include "comm.h" -#include "memory.h" -#include "error.h" +#include "update.h" + +#include using namespace LAMMPS_NS; @@ -151,17 +151,9 @@ void ComputeMLIAP::init() // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); - int count = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"mliap") == 0) count++; - if (count > 1 && comm->me == 0) + if (modify->get_compute_by_style("mliap").size() > 1 && comm->me == 0) error->warning(FLERR,"More than one compute mliap"); // initialize model and descriptor diff --git a/src/ML-IAP/mliap_descriptor_snap.cpp b/src/ML-IAP/mliap_descriptor_snap.cpp index dd9bf5d812..7badf7b641 100644 --- a/src/ML-IAP/mliap_descriptor_snap.cpp +++ b/src/ML-IAP/mliap_descriptor_snap.cpp @@ -416,7 +416,7 @@ void MLIAPDescriptorSNAP::read_paramfile(char *paramfilename) if ((keywd == "elems") || (keywd == "radelems") || (keywd == "welems") || (keywd == "rinnerelems") || (keywd == "drinnerelems")) { - if ((nelementsflag == 0) || (words.count() != nelements + 1)) + if ((nelementsflag == 0) || ((int)words.count() != nelements + 1)) error->all(FLERR, "Incorrect SNAP parameter file"); if (comm->me == 0) utils::logmesg(lmp, "SNAP keyword {} \n", utils::trim(line)); diff --git a/src/ML-IAP/pair_mliap.cpp b/src/ML-IAP/pair_mliap.cpp index 64c5a547be..179649caff 100644 --- a/src/ML-IAP/pair_mliap.cpp +++ b/src/ML-IAP/pair_mliap.cpp @@ -32,7 +32,6 @@ #include "error.h" #include "force.h" #include "memory.h" -#include "neigh_request.h" #include "neighbor.h" #include @@ -314,9 +313,7 @@ void PairMLIAP::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } diff --git a/src/ML-PACE/pair_pace.cpp b/src/ML-PACE/pair_pace.cpp index e4141ae4b8..fca66fd328 100644 --- a/src/ML-PACE/pair_pace.cpp +++ b/src/ML-PACE/pair_pace.cpp @@ -35,7 +35,6 @@ Copyright 2021 Yury Lysogorskiy^1, Cas van der Oord^2, Anton Bochkarev^1, #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -353,9 +352,7 @@ void PairPACE::init_style() if (force->newton_pair == 0) error->all(FLERR, "Pair style pACE requires newton pair on"); // request a full neighbor list - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/ML-QUIP/pair_quip.cpp b/src/ML-QUIP/pair_quip.cpp index f1a2eb8a4a..f2879af6c4 100644 --- a/src/ML-QUIP/pair_quip.cpp +++ b/src/ML-QUIP/pair_quip.cpp @@ -25,7 +25,6 @@ #include "force.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "potential_file_reader.h" #include "update.h" @@ -308,10 +307,8 @@ void PairQUIP::init_style() if (force->newton_pair != 1) error->all(FLERR, "Pair style quip requires newton pair on"); - // Initialise neighbor list - int irequest_full = neighbor->request(this); - neighbor->requests[irequest_full]->half = 0; - neighbor->requests[irequest_full]->full = 1; + // request full neighbor list + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/ML-RANN/pair_rann.cpp b/src/ML-RANN/pair_rann.cpp index 97a3478332..3f3e95282c 100644 --- a/src/ML-RANN/pair_rann.cpp +++ b/src/ML-RANN/pair_rann.cpp @@ -38,7 +38,6 @@ DISTRIBUTION A. Approved for public release; distribution unlimited. OPSEC#4918 #include "memory.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "tokenizer.h" #include "update.h" @@ -1253,10 +1252,7 @@ void PairRANN::init_list(int /*which*/, NeighList *ptr) void PairRANN::init_style() { - int irequest_full = neighbor->request(this,instance_me); - neighbor->requests[irequest_full]->id = 1; - neighbor->requests[irequest_full]->half = 0; - neighbor->requests[irequest_full]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } @@ -1274,34 +1270,34 @@ void PairRANN::errorf(const char *file, int line, const char * message) { } int PairRANN::factorial(int n) { - return round(MathSpecial::factorial(n)); + return round(MathSpecial::factorial(n)); } RANN::Fingerprint *PairRANN::create_fingerprint(const char *style) { if (strcmp(style,"radial")==0) { - return new RANN::Fingerprint_radial(this); + return new RANN::Fingerprint_radial(this); } else if (strcmp(style,"radialscreened")==0) { - return new RANN::Fingerprint_radialscreened(this); + return new RANN::Fingerprint_radialscreened(this); } else if (strcmp(style,"radialscreenedspin")==0) { - return new RANN::Fingerprint_radialscreenedspin(this); + return new RANN::Fingerprint_radialscreenedspin(this); } else if (strcmp(style,"radialspin")==0) { - return new RANN::Fingerprint_radialspin(this); + return new RANN::Fingerprint_radialspin(this); } else if (strcmp(style,"bond")==0) { - return new RANN::Fingerprint_bond(this); + return new RANN::Fingerprint_bond(this); } else if (strcmp(style,"bondscreened")==0) { - return new RANN::Fingerprint_bondscreened(this); + return new RANN::Fingerprint_bondscreened(this); } else if (strcmp(style,"bondscreenedspin")==0) { - return new RANN::Fingerprint_bondscreenedspin(this); + return new RANN::Fingerprint_bondscreenedspin(this); } else if (strcmp(style,"bondspin")==0) { - return new RANN::Fingerprint_bondspin(this); + return new RANN::Fingerprint_bondspin(this); } error->one(FLERR,"Unknown fingerprint style {}",style); return nullptr; @@ -1311,10 +1307,10 @@ RANN::Fingerprint *PairRANN::create_fingerprint(const char *style) RANN::Activation *PairRANN::create_activation(const char *style) { if (strcmp(style,"linear")==0) { - return new RANN::Activation_linear(this); + return new RANN::Activation_linear(this); } else if (strcmp(style,"sigI")==0) { - return new RANN::Activation_sigI(this); + return new RANN::Activation_sigI(this); } error->one(FLERR,"Unknown activation style {}",style); return nullptr; diff --git a/src/ML-SNAP/compute_sna_atom.cpp b/src/ML-SNAP/compute_sna_atom.cpp index 0dc2de4656..cec705770d 100644 --- a/src/ML-SNAP/compute_sna_atom.cpp +++ b/src/ML-SNAP/compute_sna_atom.cpp @@ -13,7 +13,6 @@ ------------------------------------------------------------------------- */ #include "compute_sna_atom.h" -#include #include "sna.h" #include "atom.h" @@ -21,13 +20,14 @@ #include "modify.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "pair.h" #include "comm.h" #include "memory.h" #include "error.h" +#include + using namespace LAMMPS_NS; ComputeSNAAtom::ComputeSNAAtom(LAMMPS *lmp, int narg, char **arg) : @@ -193,17 +193,9 @@ void ComputeSNAAtom::init() // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); - int count = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"sna/atom") == 0) count++; - if (count > 1 && comm->me == 0) + if (modify->get_compute_by_style("sna/atom").size() > 1 && comm->me == 0) error->warning(FLERR,"More than one compute sna/atom"); snaptr->init(); } diff --git a/src/ML-SNAP/compute_snad_atom.cpp b/src/ML-SNAP/compute_snad_atom.cpp index 25f4b430aa..4874a53c9c 100644 --- a/src/ML-SNAP/compute_snad_atom.cpp +++ b/src/ML-SNAP/compute_snad_atom.cpp @@ -13,7 +13,6 @@ ------------------------------------------------------------------------- */ #include "compute_snad_atom.h" -#include #include "sna.h" #include "atom.h" @@ -21,13 +20,14 @@ #include "modify.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "pair.h" #include "comm.h" #include "memory.h" #include "error.h" +#include + using namespace LAMMPS_NS; ComputeSNADAtom::ComputeSNADAtom(LAMMPS *lmp, int narg, char **arg) : @@ -194,17 +194,9 @@ void ComputeSNADAtom::init() // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); - int count = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"snad/atom") == 0) count++; - if (count > 1 && comm->me == 0) + if (modify->get_compute_by_style("snad/atom").size() > 1 && comm->me == 0) error->warning(FLERR,"More than one compute snad/atom"); snaptr->init(); } diff --git a/src/ML-SNAP/compute_snap.cpp b/src/ML-SNAP/compute_snap.cpp index af8c52c2ee..04dac2acba 100644 --- a/src/ML-SNAP/compute_snap.cpp +++ b/src/ML-SNAP/compute_snap.cpp @@ -13,7 +13,6 @@ ------------------------------------------------------------------------- */ #include "compute_snap.h" -#include #include "sna.h" #include "atom.h" @@ -21,13 +20,14 @@ #include "modify.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "pair.h" #include "comm.h" #include "memory.h" #include "error.h" +#include + using namespace LAMMPS_NS; enum{SCALAR,VECTOR,ARRAY}; @@ -35,7 +35,7 @@ enum{SCALAR,VECTOR,ARRAY}; ComputeSnap::ComputeSnap(LAMMPS *lmp, int narg, char **arg) : Compute(lmp, narg, arg), cutsq(nullptr), list(nullptr), snap(nullptr), snapall(nullptr), snap_peratom(nullptr), radelem(nullptr), wjelem(nullptr), - snaptr(nullptr), rinnerelem(nullptr), drinnerelem(nullptr) + rinnerelem(nullptr), drinnerelem(nullptr), snaptr(nullptr) { array_flag = 1; @@ -215,17 +215,9 @@ void ComputeSnap::init() // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); - int count = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"snap") == 0) count++; - if (count > 1 && comm->me == 0) + if (modify->get_compute_by_style("snap").size() > 1 && comm->me == 0) error->warning(FLERR,"More than one compute snap"); snaptr->init(); diff --git a/src/ML-SNAP/compute_snav_atom.cpp b/src/ML-SNAP/compute_snav_atom.cpp index 9834dc2a0c..d3999381f2 100644 --- a/src/ML-SNAP/compute_snav_atom.cpp +++ b/src/ML-SNAP/compute_snav_atom.cpp @@ -13,7 +13,6 @@ ------------------------------------------------------------------------- */ #include "compute_snav_atom.h" -#include #include "sna.h" #include "atom.h" @@ -21,12 +20,13 @@ #include "modify.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "comm.h" #include "memory.h" #include "error.h" +#include + using namespace LAMMPS_NS; ComputeSNAVAtom::ComputeSNAVAtom(LAMMPS *lmp, int narg, char **arg) : @@ -189,17 +189,9 @@ void ComputeSNAVAtom::init() // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); - int count = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"snav/atom") == 0) count++; - if (count > 1 && comm->me == 0) + if (modify->get_compute_by_style("snav/atom").size() > 1 && comm->me == 0) error->warning(FLERR,"More than one compute snav/atom"); snaptr->init(); } diff --git a/src/ML-SNAP/pair_snap.cpp b/src/ML-SNAP/pair_snap.cpp index e9c6958ceb..ed30bd714e 100644 --- a/src/ML-SNAP/pair_snap.cpp +++ b/src/ML-SNAP/pair_snap.cpp @@ -20,7 +20,6 @@ #include "force.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "sna.h" #include "tokenizer.h" @@ -446,9 +445,7 @@ void PairSNAP::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); snaptr->init(); diff --git a/src/MOFFF/pair_buck6d_coul_gauss_dsf.cpp b/src/MOFFF/pair_buck6d_coul_gauss_dsf.cpp index b480a04b04..6f7d50ebdd 100644 --- a/src/MOFFF/pair_buck6d_coul_gauss_dsf.cpp +++ b/src/MOFFF/pair_buck6d_coul_gauss_dsf.cpp @@ -20,19 +20,21 @@ ------------------------------------------------------------------------- */ #include "pair_buck6d_coul_gauss_dsf.h" -#include -#include + #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" -#include "math_const.h" #include "error.h" +#include "force.h" +#include "math_const.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" #include "math_special.h" +#include +#include + using namespace LAMMPS_NS; using namespace MathConst; @@ -314,7 +316,7 @@ void PairBuck6dCoulGaussDSF::init_style() if (!atom->q_flag) error->all(FLERR,"Pair style buck6d/coul/dsf requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; } diff --git a/src/MOFFF/pair_buck6d_coul_gauss_long.cpp b/src/MOFFF/pair_buck6d_coul_gauss_long.cpp index 79849fad2a..946aeb4635 100644 --- a/src/MOFFF/pair_buck6d_coul_gauss_long.cpp +++ b/src/MOFFF/pair_buck6d_coul_gauss_long.cpp @@ -20,19 +20,20 @@ #include "pair_buck6d_coul_gauss_long.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" -#include "neigh_list.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" #include "math_special.h" +#include +#include + using namespace LAMMPS_NS; #define EWALD_F 1.12837917 @@ -336,7 +337,7 @@ void PairBuck6dCoulGaussLong::init_style() error->all(FLERR,"Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; diff --git a/src/MOLECULE/pair_hbond_dreiding_lj.cpp b/src/MOLECULE/pair_hbond_dreiding_lj.cpp index f2c24c6d26..bdca9446a0 100644 --- a/src/MOLECULE/pair_hbond_dreiding_lj.cpp +++ b/src/MOLECULE/pair_hbond_dreiding_lj.cpp @@ -17,21 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_hbond_dreiding_lj.h" -#include -#include + #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "neigh_list.h" #include "domain.h" +#include "error.h" +#include "force.h" #include "math_const.h" #include "math_special.h" #include "memory.h" -#include "error.h" +#include "molecule.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -441,9 +441,7 @@ void PairHbondDreidingLJ::init_style() // full neighbor list request - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- diff --git a/src/MOLECULE/pair_hbond_dreiding_morse.cpp b/src/MOLECULE/pair_hbond_dreiding_morse.cpp index cf83c6baa3..1530283f4d 100644 --- a/src/MOLECULE/pair_hbond_dreiding_morse.cpp +++ b/src/MOLECULE/pair_hbond_dreiding_morse.cpp @@ -17,21 +17,21 @@ ------------------------------------------------------------------------- */ #include "pair_hbond_dreiding_morse.h" -#include -#include + #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "neigh_list.h" #include "domain.h" +#include "error.h" +#include "force.h" #include "math_const.h" #include "math_special.h" #include "memory.h" -#include "error.h" +#include "molecule.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -365,9 +365,7 @@ void PairHbondDreidingMorse::init_style() // full neighbor list request - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp b/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp index 5df54a0911..c1dd0ec48c 100644 --- a/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp +++ b/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp @@ -18,16 +18,16 @@ #include "pair_lj_charmm_coul_charmm.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; @@ -281,15 +281,14 @@ void PairLJCharmmCoulCharmm::coeff(int narg, char **arg) void PairLJCharmmCoulCharmm::init_style() { if (!atom->q_flag) - error->all(FLERR, - "Pair style lj/charmm/coul/charmm requires atom attribute q"); + error->all(FLERR, "Pair style lj/charmm/coul/charmm requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); // require cut_lj_inner < cut_lj, cut_coul_inner < cut_coul if (cut_lj_inner >= cut_lj || cut_coul_inner >= cut_coul) - error->all(FLERR,"Pair inner cutoff >= Pair outer cutoff"); + error->all(FLERR, "Pair inner cutoff >= Pair outer cutoff"); cut_lj_innersq = cut_lj_inner * cut_lj_inner; cut_ljsq = cut_lj * cut_lj; diff --git a/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp b/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp index 1d9be47db2..1259dba07b 100644 --- a/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp +++ b/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp @@ -22,17 +22,17 @@ #include "pair_lj_charmmfsw_coul_charmmfsh.h" +#include "atom.h" +#include "comm.h" +#include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include "update.h" + #include #include -#include "atom.h" -#include "update.h" -#include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" -#include "error.h" - using namespace LAMMPS_NS; @@ -305,10 +305,9 @@ void PairLJCharmmfswCoulCharmmfsh::coeff(int narg, char **arg) void PairLJCharmmfswCoulCharmmfsh::init_style() { if (!atom->q_flag) - error->all(FLERR,"Pair style lj/charmmfsw/coul/charmmfsh " - "requires atom attribute q"); + error->all(FLERR,"Pair style lj/charmmfsw/coul/charmmfsh requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); // require cut_lj_inner < cut_lj diff --git a/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp b/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp index dda09f62ce..b024afd575 100644 --- a/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp +++ b/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp @@ -490,17 +490,15 @@ void PairLJCutTIP4PCut::init_style() if (atom->tag_enable == 0) error->all(FLERR,"Pair style lj/cut/tip4p/cut requires atom IDs"); if (!force->newton_pair) - error->all(FLERR, - "Pair style lj/cut/tip4p/cut requires newton pair on"); + error->all(FLERR,"Pair style lj/cut/tip4p/cut requires newton pair on"); if (!atom->q_flag) - error->all(FLERR, - "Pair style lj/cut/tip4p/cut requires atom attribute q"); + error->all(FLERR,"Pair style lj/cut/tip4p/cut requires atom attribute q"); if (force->bond == nullptr) error->all(FLERR,"Must use a bond style with TIP4P potential"); if (force->angle == nullptr) error->all(FLERR,"Must use an angle style with TIP4P potential"); - neighbor->request(this,instance_me); + neighbor->add_request(this); // set alpha parameter diff --git a/src/MOLECULE/pair_tip4p_cut.cpp b/src/MOLECULE/pair_tip4p_cut.cpp index e0eeaa6e58..1d46df3e13 100644 --- a/src/MOLECULE/pair_tip4p_cut.cpp +++ b/src/MOLECULE/pair_tip4p_cut.cpp @@ -18,18 +18,18 @@ #include "pair_tip4p_cut.h" -#include -#include "atom.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "domain.h" #include "angle.h" +#include "atom.h" #include "bond.h" #include "comm.h" -#include "memory.h" +#include "domain.h" #include "error.h" +#include "force.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" +#include using namespace LAMMPS_NS; @@ -419,17 +419,15 @@ void PairTIP4PCut::init_style() if (atom->tag_enable == 0) error->all(FLERR,"Pair style tip4p/cut requires atom IDs"); if (!force->newton_pair) - error->all(FLERR, - "Pair style tip4p/cut requires newton pair on"); + error->all(FLERR,"Pair style tip4p/cut requires newton pair on"); if (!atom->q_flag) - error->all(FLERR, - "Pair style tip4p/cut requires atom attribute q"); + error->all(FLERR,"Pair style tip4p/cut requires atom attribute q"); if (force->bond == nullptr) error->all(FLERR,"Must use a bond style with TIP4P potential"); if (force->angle == nullptr) error->all(FLERR,"Must use an angle style with TIP4P potential"); - neighbor->request(this,instance_me); + neighbor->add_request(this); // set alpha parameter diff --git a/src/OPENMP/fix_omp.cpp b/src/OPENMP/fix_omp.cpp index ec5b1d5be0..6be7f7c1fc 100644 --- a/src/OPENMP/fix_omp.cpp +++ b/src/OPENMP/fix_omp.cpp @@ -277,7 +277,7 @@ void FixOMP::init() #undef CheckStyleForOMP #undef CheckHybridForOMP - set_neighbor_omp(); + neighbor->set_omp_neighbor(_neighbor ? 1 : 0); // diagnostic output if (comm->me == 0) { @@ -293,27 +293,6 @@ void FixOMP::init() /* ---------------------------------------------------------------------- */ -void FixOMP::set_neighbor_omp() -{ - // select or deselect multi-threaded neighbor - // list build depending on setting in package omp. - // NOTE: since we are at the top of the list of - // fixes, we cannot adjust neighbor lists from - // other fixes. those have to be re-implemented - // as /omp fix styles. :-( - - const int neigh_omp = _neighbor ? 1 : 0; - const int nrequest = neighbor->nrequest; - - // flag *all* neighbor list requests as OPENMP threaded, - // but skip lists already flagged as INTEL threaded - for (int i = 0; i < nrequest; ++i) - if (! neighbor->requests[i]->intel) - neighbor->requests[i]->omp = neigh_omp; -} - -/* ---------------------------------------------------------------------- */ - void FixOMP::setup(int) { // we are post the force compute in setup. turn on timers diff --git a/src/OPENMP/fix_omp.h b/src/OPENMP/fix_omp.h index af57abc85c..b6e0e516f4 100644 --- a/src/OPENMP/fix_omp.h +++ b/src/OPENMP/fix_omp.h @@ -71,8 +71,6 @@ class FixOMP : public Fix { bool _reduced; // whether forces have been reduced for this step bool _pair_compute_flag; // whether pair_compute is called bool _kspace_compute_flag; // whether kspace_compute is called - - void set_neighbor_omp(); }; } // namespace LAMMPS_NS diff --git a/src/OPENMP/fix_peri_neigh_omp.cpp b/src/OPENMP/fix_peri_neigh_omp.cpp deleted file mode 100644 index e24a8ec838..0000000000 --- a/src/OPENMP/fix_peri_neigh_omp.cpp +++ /dev/null @@ -1,51 +0,0 @@ -// clang-format off -/* ---------------------------------------------------------------------- - LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator - https://www.lammps.org/, Sandia National Laboratories - Steve Plimpton, sjplimp@sandia.gov - - Copyright (2003) Sandia Corporation. Under the terms of Contract - DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains - certain rights in this software. This software is distributed under - the GNU General Public License. - - See the README file in the top-level LAMMPS directory. -------------------------------------------------------------------------- */ - -/* ---------------------------------------------------------------------- - Contributing author: Mike Parks (SNL) -------------------------------------------------------------------------- */ - -#include "fix_peri_neigh_omp.h" -#include "fix_omp.h" -#include "modify.h" -#include "neighbor.h" -#include "neigh_request.h" - -using namespace LAMMPS_NS; -using namespace FixConst; - -/* ---------------------------------------------------------------------- */ - -void FixPeriNeighOMP::init() -{ - if (!first) return; - - // determine status of neighbor flag of the omp package command - int ifix = modify->find_fix("package_omp"); - int use_omp = 0; - if (ifix >=0) { - FixOMP * fix = static_cast(lmp->modify->fix[ifix]); - if (fix->get_neighbor()) use_omp = 1; - } - - // need a full neighbor list once - - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->omp = use_omp; - neighbor->requests[irequest]->occasional = 1; -} diff --git a/src/OPENMP/fix_peri_neigh_omp.h b/src/OPENMP/fix_peri_neigh_omp.h deleted file mode 100644 index 1c52132b1c..0000000000 --- a/src/OPENMP/fix_peri_neigh_omp.h +++ /dev/null @@ -1,37 +0,0 @@ -/* -*- c++ -*- ---------------------------------------------------------- - LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator - https://www.lammps.org/, Sandia National Laboratories - Steve Plimpton, sjplimp@sandia.gov - - Copyright (2003) Sandia Corporation. Under the terms of Contract - DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains - certain rights in this software. This software is distributed under - the GNU General Public License. - - See the README file in the top-level LAMMPS directory. -------------------------------------------------------------------------- */ - -#ifdef FIX_CLASS -// clang-format off -FixStyle(PERI_NEIGH_OMP,FixPeriNeighOMP); -// clang-format on -#else - -#ifndef LMP_FIX_PERI_NEIGH_OMP_H -#define LMP_FIX_PERI_NEIGH_OMP_H - -#include "fix_peri_neigh.h" - -namespace LAMMPS_NS { - -class FixPeriNeighOMP : public FixPeriNeigh { - - public: - FixPeriNeighOMP(class LAMMPS *lmp, int narg, char **argv) : FixPeriNeigh(lmp, narg, argv){}; - void init() override; -}; - -} // namespace LAMMPS_NS - -#endif -#endif diff --git a/src/OPENMP/pair_reaxff_omp.cpp b/src/OPENMP/pair_reaxff_omp.cpp index a329809c4e..6d613abf60 100644 --- a/src/OPENMP/pair_reaxff_omp.cpp +++ b/src/OPENMP/pair_reaxff_omp.cpp @@ -45,7 +45,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -127,9 +126,7 @@ void PairReaxFFOMP::init_style() // need a half neighbor list w/ Newton off and ghost neighbors // built whenever re-neighboring occurs - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->newton = 2; - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this, NeighConst::REQ_GHOST | NeighConst::REQ_NEWTON_OFF); cutmax = MAX3(api->control->nonb_cut, api->control->hbond_cut, api->control->bond_cut); if ((cutmax < 2.0*api->control->bond_cut) && (comm->me == 0)) diff --git a/src/ORIENT/fix_orient_bcc.cpp b/src/ORIENT/fix_orient_bcc.cpp index a64487040c..9449f5bcd8 100644 --- a/src/ORIENT/fix_orient_bcc.cpp +++ b/src/ORIENT/fix_orient_bcc.cpp @@ -28,7 +28,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "respa.h" #include "update.h" @@ -206,14 +205,9 @@ void FixOrientBCC::init() if (respa_level >= 0) ilevel_respa = MIN(respa_level,ilevel_respa); } - // need a full neighbor list - // perpetual list, built whenever re-neighboring occurs + // need a full perpetual neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this,NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/ORIENT/fix_orient_eco.cpp b/src/ORIENT/fix_orient_eco.cpp index 61d26e597d..6f633316cf 100644 --- a/src/ORIENT/fix_orient_eco.cpp +++ b/src/ORIENT/fix_orient_eco.cpp @@ -26,7 +26,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "respa.h" @@ -161,10 +160,9 @@ void FixOrientECO::init() { // compute normalization factor int neigh = get_norm(); - if (me == 0) { - utils::logmesg(lmp," fix orient/eco: cutoff={} norm_fac={} " - "neighbors={}\n", r_cut, norm_fac, neigh); - } + if (me == 0) + utils::logmesg(lmp," fix orient/eco: cutoff={} norm_fac={} neighbors={}\n", + r_cut, norm_fac, neigh); inv_norm_fac = 1.0 / norm_fac; @@ -182,14 +180,9 @@ void FixOrientECO::init() { if (respa_level >= 0) ilevel_respa = MIN(respa_level, ilevel_respa); } - // need a full neighbor list - // perpetual list, built whenever re-neighboring occurs + // need a full perpetual neighbor list - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/ORIENT/fix_orient_fcc.cpp b/src/ORIENT/fix_orient_fcc.cpp index 07a9008f0f..d631ca9bd8 100644 --- a/src/ORIENT/fix_orient_fcc.cpp +++ b/src/ORIENT/fix_orient_fcc.cpp @@ -25,7 +25,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "respa.h" #include "update.h" @@ -204,14 +203,9 @@ void FixOrientFCC::init() if (respa_level >= 0) ilevel_respa = MIN(respa_level,ilevel_respa); } - // need a full neighbor list - // perpetual list, built whenever re-neighboring occurs + // need a full perpetual neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this,NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/PERI/fix_peri_neigh.cpp b/src/PERI/fix_peri_neigh.cpp index 2ecf283d07..1d1c0d1c5e 100644 --- a/src/PERI/fix_peri_neigh.cpp +++ b/src/PERI/fix_peri_neigh.cpp @@ -122,12 +122,7 @@ void FixPeriNeigh::init() // need a full neighbor list once - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this,NeighConst::REQ_FULL|NeighConst::REQ_OCCASIONAL); // compute PD scale factor, stored in Atom class, used by DumpCFG diff --git a/src/PERI/pair_peri.cpp b/src/PERI/pair_peri.cpp index a13b6adad1..4ed281489b 100644 --- a/src/PERI/pair_peri.cpp +++ b/src/PERI/pair_peri.cpp @@ -132,7 +132,7 @@ void PairPeri::init_style() if (!fix_peri_neigh) fix_peri_neigh = (FixPeriNeigh *) modify->add_fix("PERI_NEIGH all PERI_NEIGH"); - neighbor->request(this, instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- */ diff --git a/src/PHONON/third_order.cpp b/src/PHONON/third_order.cpp index 0f70a591d8..3bcff07ea7 100644 --- a/src/PHONON/third_order.cpp +++ b/src/PHONON/third_order.cpp @@ -124,16 +124,10 @@ void ThirdOrder::command(int narg, char **arg) // request a full neighbor list for use by this command - int irequest = neighbor->request(this); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->command = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; - neighbor->requests[irequest]->command_style = "third_order"; + neighbor->add_request(this, "third_order", NeighConst::REQ_FULL); lmp->init(); - list = neighbor->lists[irequest]; + list = neighbor->find_list(this); // orthogonal vs triclinic simulation box diff --git a/src/PTM/compute_ptm_atom.cpp b/src/PTM/compute_ptm_atom.cpp index 3e7ea775ac..e024d45012 100644 --- a/src/PTM/compute_ptm_atom.cpp +++ b/src/PTM/compute_ptm_atom.cpp @@ -159,12 +159,7 @@ void ComputePTMAtom::init() { // need an occasional full neighbor list - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/Purge.list b/src/Purge.list index 8284961e1e..00a2269ec8 100644 --- a/src/Purge.list +++ b/src/Purge.list @@ -51,6 +51,9 @@ lmpinstalledpkgs.h lmpgitversion.h mliap_model_python_couple.cpp mliap_model_python_couple.h +# removed on 8 March 2022 +fix_peri_neigh_omp.cpp +fix_peri_neigh_omp.h # renamed on 7 March 2022 compute_pressure_cylinder.cpp compute_pressure_cylinder.h diff --git a/src/QEQ/fix_qeq_dynamic.cpp b/src/QEQ/fix_qeq_dynamic.cpp index 06c9d6ace8..257394ebb9 100644 --- a/src/QEQ/fix_qeq_dynamic.cpp +++ b/src/QEQ/fix_qeq_dynamic.cpp @@ -24,7 +24,6 @@ #include "force.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -66,11 +65,7 @@ void FixQEqDynamic::init() { FixQEq::init(); - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 1; - neighbor->requests[irequest]->full = 0; + neighbor->add_request(this); if (tolerance < 1e-4) if (comm->me == 0) diff --git a/src/QEQ/fix_qeq_fire.cpp b/src/QEQ/fix_qeq_fire.cpp index 56c8e16b10..219106b702 100644 --- a/src/QEQ/fix_qeq_fire.cpp +++ b/src/QEQ/fix_qeq_fire.cpp @@ -24,7 +24,6 @@ #include "force.h" #include "kspace.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair_comb.h" #include "pair_comb3.h" @@ -76,11 +75,7 @@ void FixQEqFire::init() { FixQEq::init(); - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 1; - neighbor->requests[irequest]->full = 0; + neighbor->add_request(this); if (tolerance < 1e-4) if (comm->me == 0) diff --git a/src/QEQ/fix_qeq_point.cpp b/src/QEQ/fix_qeq_point.cpp index 3cb3e3ee35..9af903b0db 100644 --- a/src/QEQ/fix_qeq_point.cpp +++ b/src/QEQ/fix_qeq_point.cpp @@ -25,7 +25,6 @@ #include "kspace.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -51,11 +50,7 @@ void FixQEqPoint::init() { FixQEq::init(); - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); int ntypes = atom->ntypes; memory->create(shld,ntypes+1,ntypes+1,"qeq:shielding"); diff --git a/src/QEQ/fix_qeq_shielded.cpp b/src/QEQ/fix_qeq_shielded.cpp index 3a1f114cfb..afd2bd6ba3 100644 --- a/src/QEQ/fix_qeq_shielded.cpp +++ b/src/QEQ/fix_qeq_shielded.cpp @@ -25,7 +25,6 @@ #include "kspace.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -53,11 +52,7 @@ void FixQEqShielded::init() { FixQEq::init(); - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); int ntypes = atom->ntypes; memory->create(shld,ntypes+1,ntypes+1,"qeq:shielding"); diff --git a/src/QEQ/fix_qeq_slater.cpp b/src/QEQ/fix_qeq_slater.cpp index 9f22d97683..2ac9db880e 100644 --- a/src/QEQ/fix_qeq_slater.cpp +++ b/src/QEQ/fix_qeq_slater.cpp @@ -25,7 +25,6 @@ #include "kspace.h" #include "math_const.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -67,11 +66,7 @@ void FixQEqSlater::init() { FixQEq::init(); - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); int ntypes = atom->ntypes; for (int i = 1; i <= ntypes; i++) { diff --git a/src/REACTION/fix_bond_react.cpp b/src/REACTION/fix_bond_react.cpp index a74a0fa934..dd56e96e81 100644 --- a/src/REACTION/fix_bond_react.cpp +++ b/src/REACTION/fix_bond_react.cpp @@ -802,10 +802,7 @@ void FixBondReact::init() } // need a half neighbor list, built every Nevery steps - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); lastcheck = -1; } diff --git a/src/REAXFF/fix_qeq_reaxff.cpp b/src/REAXFF/fix_qeq_reaxff.cpp index db5d5100ba..c2469ee9eb 100644 --- a/src/REAXFF/fix_qeq_reaxff.cpp +++ b/src/REAXFF/fix_qeq_reaxff.cpp @@ -32,7 +32,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "region.h" @@ -419,10 +418,7 @@ void FixQEqReaxFF::init() // we need a half neighbor list w/ Newton off // built whenever re-neighboring occurs - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->newton = 2; + neighbor->add_request(this, NeighConst::REQ_NEWTON_OFF); init_shielding(); init_taper(); diff --git a/src/REAXFF/pair_reaxff.cpp b/src/REAXFF/pair_reaxff.cpp index 991b6f0a30..94646fd8a7 100644 --- a/src/REAXFF/pair_reaxff.cpp +++ b/src/REAXFF/pair_reaxff.cpp @@ -33,7 +33,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" #include "fix_acks2_reaxff.h" @@ -366,9 +365,7 @@ void PairReaxFF::init_style() // need a half neighbor list w/ Newton off and ghost neighbors // built whenever re-neighboring occurs - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->newton = 2; - neighbor->requests[irequest]->ghost = 1; + neighbor->add_request(this, NeighConst::REQ_GHOST | NeighConst::REQ_NEWTON_OFF); cutmax = MAX3(api->control->nonb_cut, api->control->hbond_cut, api->control->bond_cut); if ((cutmax < 2.0*api->control->bond_cut) && (comm->me == 0)) diff --git a/src/REPLICA/fix_hyper_global.cpp b/src/REPLICA/fix_hyper_global.cpp index bd96897a9e..232a72a9ad 100644 --- a/src/REPLICA/fix_hyper_global.cpp +++ b/src/REPLICA/fix_hyper_global.cpp @@ -14,8 +14,6 @@ #include "fix_hyper_global.h" -#include -#include #include "atom.h" #include "update.h" #include "group.h" @@ -23,12 +21,14 @@ #include "domain.h" #include "comm.h" #include "neighbor.h" -#include "neigh_request.h" #include "neigh_list.h" #include "math_extra.h" #include "memory.h" #include "error.h" +#include +#include + using namespace LAMMPS_NS; using namespace FixConst; @@ -138,10 +138,7 @@ void FixHyperGlobal::init() // need an occasional half neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->fix = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ diff --git a/src/REPLICA/fix_hyper_local.cpp b/src/REPLICA/fix_hyper_local.cpp index 6b6a672fa0..9364a2f753 100644 --- a/src/REPLICA/fix_hyper_local.cpp +++ b/src/REPLICA/fix_hyper_local.cpp @@ -14,9 +14,6 @@ #include "fix_hyper_local.h" -#include -#include - #include "atom.h" #include "update.h" #include "group.h" @@ -32,6 +29,9 @@ #include "memory.h" #include "error.h" +#include +#include + using namespace LAMMPS_NS; using namespace FixConst; @@ -310,15 +310,9 @@ void FixHyperLocal::init() // NOTE: what if pair style list cutoff > Dcut // or what if neigh skin is huge? - int irequest_full = neighbor->request(this,instance_me); - neighbor->requests[irequest_full]->id = 1; - neighbor->requests[irequest_full]->pair = 0; - neighbor->requests[irequest_full]->fix = 1; - neighbor->requests[irequest_full]->half = 0; - neighbor->requests[irequest_full]->full = 1; - neighbor->requests[irequest_full]->cut = 1; - neighbor->requests[irequest_full]->cutoff = dcut; - neighbor->requests[irequest_full]->occasional = 1; + auto req = neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); + req->set_id(1); + req->set_cutoff(dcut); // also need occasional half neighbor list derived from pair style // used for building local bond list @@ -326,11 +320,8 @@ void FixHyperLocal::init() // this list will also be built (or derived/copied) // every time build_bond() is called - int irequest_half = neighbor->request(this,instance_me); - neighbor->requests[irequest_half]->id = 2; - neighbor->requests[irequest_half]->pair = 0; - neighbor->requests[irequest_half]->fix = 1; - neighbor->requests[irequest_half]->occasional = 1; + req = neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); + req->set_id(2); // extra timing output diff --git a/src/SMTBQ/pair_smtbq.cpp b/src/SMTBQ/pair_smtbq.cpp index b01c214ac6..be8af7f9bd 100644 --- a/src/SMTBQ/pair_smtbq.cpp +++ b/src/SMTBQ/pair_smtbq.cpp @@ -50,7 +50,6 @@ #include "math_special.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -286,9 +285,7 @@ void PairSMTBQ::init_style() // need a full neighbor list - int irequest = neighbor->request(this); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); pgsize = neighbor->pgsize; oneatom = neighbor->oneatom; diff --git a/src/SPH/pair_sph_rhosum.cpp b/src/SPH/pair_sph_rhosum.cpp index 09ec206b58..30fac93036 100644 --- a/src/SPH/pair_sph_rhosum.cpp +++ b/src/SPH/pair_sph_rhosum.cpp @@ -20,7 +20,6 @@ #include "error.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "update.h" @@ -55,9 +54,7 @@ PairSPHRhoSum::~PairSPHRhoSum() { void PairSPHRhoSum::init_style() { // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); } /* ---------------------------------------------------------------------- */ diff --git a/src/SPIN/pair_spin.cpp b/src/SPIN/pair_spin.cpp index 4247918499..c2fb771def 100644 --- a/src/SPIN/pair_spin.cpp +++ b/src/SPIN/pair_spin.cpp @@ -90,9 +90,7 @@ void PairSpin::init_style() // need a full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; + neighbor->add_request(this, NeighConst::REQ_FULL); // get the lattice_flag from nve/spin diff --git a/src/YAFF/pair_lj_switch3_coulgauss_long.cpp b/src/YAFF/pair_lj_switch3_coulgauss_long.cpp index 7d12ecbe04..5a3102a96f 100644 --- a/src/YAFF/pair_lj_switch3_coulgauss_long.cpp +++ b/src/YAFF/pair_lj_switch3_coulgauss_long.cpp @@ -341,7 +341,7 @@ void PairLJSwitch3CoulGaussLong::init_style() error->all(FLERR,"Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; - neighbor->request(this,instance_me); + neighbor->add_request(this); // setup force tables diff --git a/src/YAFF/pair_mm3_switch3_coulgauss_long.cpp b/src/YAFF/pair_mm3_switch3_coulgauss_long.cpp index 84c33e6b9a..85908d4d81 100644 --- a/src/YAFF/pair_mm3_switch3_coulgauss_long.cpp +++ b/src/YAFF/pair_mm3_switch3_coulgauss_long.cpp @@ -343,7 +343,7 @@ void PairMM3Switch3CoulGaussLong::init_style() error->all(FLERR,"Pair style requires a KSpace style"); g_ewald = force->kspace->g_ewald; - neighbor->request(this,instance_me); + neighbor->add_request(this); // setup force tables diff --git a/src/atom.cpp b/src/atom.cpp index 2f27dd7457..00b9701689 100644 --- a/src/atom.cpp +++ b/src/atom.cpp @@ -38,10 +38,6 @@ #include #include -#ifdef LMP_INTEL -#include "neigh_request.h" -#endif - #ifdef LMP_GPU #include "fix_gpu.h" #include @@ -2177,12 +2173,7 @@ void Atom::setup_sort_bins() bininvz = nbinz / (bboxhi[2]-bboxlo[2]); #ifdef LMP_INTEL - int intel_neigh = 0; - if (neighbor->nrequest) { - if (neighbor->requests[0]->intel) intel_neigh = 1; - } else if (neighbor->old_nrequest) - if (neighbor->old_requests[0]->intel) intel_neigh = 1; - if (intel_neigh && userbinsize == 0.0) { + if (neighbor->has_intel_request() && userbinsize == 0.0) { if (neighbor->binsizeflag) bininv = 1.0/neighbor->binsize_user; double nx_low = neighbor->bboxlo[0]; diff --git a/src/compute.h b/src/compute.h index ef57754b18..3d6323b3d1 100644 --- a/src/compute.h +++ b/src/compute.h @@ -19,6 +19,8 @@ namespace LAMMPS_NS { class Compute : protected Pointers { + friend class Neighbor; + public: // clang-format off enum { diff --git a/src/compute_aggregate_atom.cpp b/src/compute_aggregate_atom.cpp index 563cf4fd2c..6811ae2d87 100644 --- a/src/compute_aggregate_atom.cpp +++ b/src/compute_aggregate_atom.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -27,29 +26,27 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" -#include #include +#include using namespace LAMMPS_NS; /* ---------------------------------------------------------------------- */ ComputeAggregateAtom::ComputeAggregateAtom(LAMMPS *lmp, int narg, char **arg) : - Compute(lmp, narg, arg), - aggregateID(nullptr) + Compute(lmp, narg, arg), aggregateID(nullptr) { - if (narg != 4) error->all(FLERR,"Illegal compute aggregate/atom command"); + if (narg != 4) error->all(FLERR, "Illegal compute aggregate/atom command"); - double cutoff = utils::numeric(FLERR,arg[3],false,lmp); - cutsq = cutoff*cutoff; + double cutoff = utils::numeric(FLERR, arg[3], false, lmp); + cutsq = cutoff * cutoff; if (atom->avec->bonds_allow == 0) - error->all(FLERR,"Compute aggregate/atom used when bonds are not allowed"); + error->all(FLERR, "Compute aggregate/atom used when bonds are not allowed"); peratom_flag = 1; size_peratom_cols = 0; @@ -71,31 +68,24 @@ ComputeAggregateAtom::~ComputeAggregateAtom() void ComputeAggregateAtom::init() { if (atom->tag_enable == 0) - error->all(FLERR,"Cannot use compute aggregate/atom unless atoms have IDs"); + error->all(FLERR, "Cannot use compute aggregate/atom unless atoms have IDs"); if (force->bond == nullptr) - error->all(FLERR,"Compute aggregate/atom requires a bond style to be defined"); + error->all(FLERR, "Compute aggregate/atom requires a bond style to be defined"); if (force->pair == nullptr) - error->all(FLERR,"Compute cluster/atom requires a pair style to be defined"); + error->all(FLERR, "Compute cluster/atom requires a pair style to be defined"); if (sqrt(cutsq) > force->pair->cutforce) - error->all(FLERR, - "Compute cluster/atom cutoff is longer than pairwise cutoff"); + error->all(FLERR, "Compute cluster/atom cutoff is longer than pairwise cutoff"); // need an occasional full neighbor list // full required so that pair of atoms on 2 procs both set their clusterID - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); int count = 0; for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"aggregate/atom") == 0) count++; - if (count > 1 && comm->me == 0) - error->warning(FLERR,"More than one compute aggregate/atom"); + if (strcmp(modify->compute[i]->style, "aggregate/atom") == 0) count++; + if (count > 1 && comm->me == 0) error->warning(FLERR, "More than one compute aggregate/atom"); } /* ---------------------------------------------------------------------- */ @@ -109,7 +99,7 @@ void ComputeAggregateAtom::init_list(int /*id*/, NeighList *ptr) void ComputeAggregateAtom::compute_peratom() { - int i,j,k; + int i, j, k; invoked_peratom = update->ntimestep; @@ -118,15 +108,17 @@ void ComputeAggregateAtom::compute_peratom() if (atom->nmax > nmax) { memory->destroy(aggregateID); nmax = atom->nmax; - memory->create(aggregateID,nmax,"aggregate/atom:aggregateID"); + memory->create(aggregateID, nmax, "aggregate/atom:aggregateID"); vector_atom = aggregateID; } // invoke full neighbor list (will copy or build if necessary) // on the first step of a run, set preflag to one in neighbor->build_one(...) - if (update->firststep == update->ntimestep) neighbor->build_one(list,1); - else neighbor->build_one(list); + if (update->firststep == update->ntimestep) + neighbor->build_one(list, 1); + else + neighbor->build_one(list); // if group is dynamic, insure ghost atom masks are current @@ -150,8 +142,10 @@ void ComputeAggregateAtom::compute_peratom() double **x = atom->x; for (i = 0; i < nlocal + atom->nghost; i++) - if (mask[i] & groupbit) aggregateID[i] = tag[i]; - else aggregateID[i] = 0; + if (mask[i] & groupbit) + aggregateID[i] = tag[i]; + else + aggregateID[i] = 0; // loop until no more changes on any proc: // acquire aggregateIDs of ghost atoms @@ -164,15 +158,14 @@ void ComputeAggregateAtom::compute_peratom() commflag = 1; - int change,done,anychange; + int change, done, anychange; while (true) { comm->forward_comm(this); // reverse communication when bonds are not stored on every processor - if (force->newton_bond) - comm->reverse_comm(this); + if (force->newton_bond) comm->reverse_comm(this); change = 0; while (true) { @@ -187,7 +180,7 @@ void ComputeAggregateAtom::compute_peratom() if (!(mask[k] & groupbit)) continue; if (aggregateID[i] == aggregateID[k]) continue; - aggregateID[i] = aggregateID[k] = MIN(aggregateID[i],aggregateID[k]); + aggregateID[i] = aggregateID[k] = MIN(aggregateID[i], aggregateID[k]); done = 0; } } @@ -211,10 +204,9 @@ void ComputeAggregateAtom::compute_peratom() const double delx = xtmp - x[j][0]; const double dely = ytmp - x[j][1]; const double delz = ztmp - x[j][2]; - const double rsq = delx*delx + dely*dely + delz*delz; + const double rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { - aggregateID[i] = aggregateID[j] - = MIN(aggregateID[i],aggregateID[j]); + aggregateID[i] = aggregateID[j] = MIN(aggregateID[i], aggregateID[j]); done = 0; } } @@ -225,17 +217,17 @@ void ComputeAggregateAtom::compute_peratom() // stop if all procs are done - MPI_Allreduce(&change,&anychange,1,MPI_INT,MPI_MAX,world); + MPI_Allreduce(&change, &anychange, 1, MPI_INT, MPI_MAX, world); if (!anychange) break; } } /* ---------------------------------------------------------------------- */ -int ComputeAggregateAtom::pack_forward_comm(int n, int *list, double *buf, - int /*pbc_flag*/, int * /*pbc*/) +int ComputeAggregateAtom::pack_forward_comm(int n, int *list, double *buf, int /*pbc_flag*/, + int * /*pbc*/) { - int i,j,m; + int i, j, m; m = 0; if (commflag) { @@ -258,7 +250,7 @@ int ComputeAggregateAtom::pack_forward_comm(int n, int *list, double *buf, void ComputeAggregateAtom::unpack_forward_comm(int n, int first, double *buf) { - int i,m,last; + int i, m, last; m = 0; last = first + n; @@ -268,7 +260,7 @@ void ComputeAggregateAtom::unpack_forward_comm(int n, int first, double *buf) // only overwrite ghost IDs with values lower than current ones - aggregateID[i] = MIN(x,aggregateID[i]); + aggregateID[i] = MIN(x, aggregateID[i]); } else { int *mask = atom->mask; @@ -280,13 +272,11 @@ void ComputeAggregateAtom::unpack_forward_comm(int n, int first, double *buf) int ComputeAggregateAtom::pack_reverse_comm(int n, int first, double *buf) { - int i,m,last; + int i, m, last; m = 0; last = first + n; - for (i = first; i < last; i++) { - buf[m++] = aggregateID[i]; - } + for (i = first; i < last; i++) { buf[m++] = aggregateID[i]; } return m; } @@ -294,7 +284,7 @@ int ComputeAggregateAtom::pack_reverse_comm(int n, int first, double *buf) void ComputeAggregateAtom::unpack_reverse_comm(int n, int *list, double *buf) { - int i,j,m; + int i, j, m; m = 0; for (i = 0; i < n; i++) { @@ -303,7 +293,7 @@ void ComputeAggregateAtom::unpack_reverse_comm(int n, int *list, double *buf) // only overwrite local IDs with values lower than current ones - aggregateID[j] = MIN(x,aggregateID[j]); + aggregateID[j] = MIN(x, aggregateID[j]); } } @@ -313,6 +303,6 @@ void ComputeAggregateAtom::unpack_reverse_comm(int n, int *list, double *buf) double ComputeAggregateAtom::memory_usage() { - double bytes = (double)nmax * sizeof(double); + double bytes = (double) nmax * sizeof(double); return bytes; } diff --git a/src/compute_centro_atom.cpp b/src/compute_centro_atom.cpp index 90f535613b..535720c575 100644 --- a/src/compute_centro_atom.cpp +++ b/src/compute_centro_atom.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -26,7 +25,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -38,15 +36,16 @@ using namespace LAMMPS_NS; /* ---------------------------------------------------------------------- */ ComputeCentroAtom::ComputeCentroAtom(LAMMPS *lmp, int narg, char **arg) : - Compute(lmp, narg, arg), - distsq(nullptr), nearest(nullptr), centro(nullptr) + Compute(lmp, narg, arg), distsq(nullptr), nearest(nullptr), centro(nullptr) { - if (narg < 4 || narg > 6) - error->all(FLERR,"Illegal compute centro/atom command"); + if (narg < 4 || narg > 6) error->all(FLERR, "Illegal compute centro/atom command"); - if (strcmp(arg[3],"fcc") == 0) nnn = 12; - else if (strcmp(arg[3],"bcc") == 0) nnn = 8; - else nnn = utils::inumeric(FLERR,arg[3],false,lmp); + if (strcmp(arg[3], "fcc") == 0) + nnn = 12; + else if (strcmp(arg[3], "bcc") == 0) + nnn = 8; + else + nnn = utils::inumeric(FLERR, arg[3], false, lmp); // default values @@ -56,19 +55,22 @@ ComputeCentroAtom::ComputeCentroAtom(LAMMPS *lmp, int narg, char **arg) : int iarg = 4; while (iarg < narg) { - if (strcmp(arg[iarg],"axes") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute centro/atom command3"); - axes_flag = utils::logical(FLERR,arg[iarg+1],false,lmp); + if (strcmp(arg[iarg], "axes") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute centro/atom command3"); + axes_flag = utils::logical(FLERR, arg[iarg + 1], false, lmp); iarg += 2; - } else error->all(FLERR,"Illegal compute centro/atom command1"); + } else + error->all(FLERR, "Illegal compute centro/atom command1"); } if (nnn <= 0 || nnn % 2) - error->all(FLERR,"Illegal neighbor value for compute centro/atom command"); + error->all(FLERR, "Illegal neighbor value for compute centro/atom command"); peratom_flag = 1; - if (!axes_flag) size_peratom_cols = 0; - else size_peratom_cols = 10; + if (!axes_flag) + size_peratom_cols = 0; + else + size_peratom_cols = 10; nmax = 0; maxneigh = 0; @@ -89,22 +91,16 @@ ComputeCentroAtom::~ComputeCentroAtom() void ComputeCentroAtom::init() { if (force->pair == nullptr) - error->all(FLERR,"Compute centro/atom requires a pair style be defined"); + error->all(FLERR, "Compute centro/atom requires a pair style be defined"); int count = 0; for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"centro/atom") == 0) count++; - if (count > 1 && comm->me == 0) - error->warning(FLERR,"More than one compute centro/atom"); + if (strcmp(modify->compute[i]->style, "centro/atom") == 0) count++; + if (count > 1 && comm->me == 0) error->warning(FLERR, "More than one compute centro/atom"); // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ @@ -118,9 +114,9 @@ void ComputeCentroAtom::init_list(int /*id*/, NeighList *ptr) void ComputeCentroAtom::compute_peratom() { - int i,j,k,ii,jj,kk,n,inum,jnum; - double xtmp,ytmp,ztmp,delx,dely,delz,rsq,value; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, k, ii, jj, kk, n, inum, jnum; + double xtmp, ytmp, ztmp, delx, dely, delz, rsq, value; + int *ilist, *jlist, *numneigh, **firstneigh; invoked_peratom = update->ntimestep; @@ -131,15 +127,14 @@ void ComputeCentroAtom::compute_peratom() if (!axes_flag) { memory->destroy(centro); nmax = atom->nmax; - memory->create(centro,nmax,"centro/atom:centro"); + memory->create(centro, nmax, "centro/atom:centro"); vector_atom = centro; } else { memory->destroy(centro); memory->destroy(array_atom); nmax = atom->nmax; - memory->create(centro,nmax,"centro/atom:centro"); - memory->create(array_atom,nmax,size_peratom_cols, - "centro/atom:array_atom"); + memory->create(centro, nmax, "centro/atom:centro"); + memory->create(array_atom, nmax, size_peratom_cols, "centro/atom:array_atom"); } } @@ -154,8 +149,8 @@ void ComputeCentroAtom::compute_peratom() // npairs = number of unique pairs - int nhalf = nnn/2; - int npairs = nnn * (nnn-1) / 2; + int nhalf = nnn / 2; + int npairs = nnn * (nnn - 1) / 2; double *pairs = new double[npairs]; // compute centro-symmetry parameter for each atom in group @@ -180,8 +175,8 @@ void ComputeCentroAtom::compute_peratom() memory->destroy(distsq); memory->destroy(nearest); maxneigh = jnum; - memory->create(distsq,maxneigh,"centro/atom:distsq"); - memory->create(nearest,maxneigh,"centro/atom:nearest"); + memory->create(distsq, maxneigh, "centro/atom:distsq"); + memory->create(nearest, maxneigh, "centro/atom:nearest"); } // loop over list of all neighbors within force cutoff @@ -196,7 +191,7 @@ void ComputeCentroAtom::compute_peratom() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { distsq[n] = rsq; nearest[n++] = j; @@ -216,7 +211,7 @@ void ComputeCentroAtom::compute_peratom() // store nnn nearest neighs in 1st nnn locations of distsq and nearest - select2(nnn,n,distsq,nearest); + select2(nnn, n, distsq, nearest); // R = Ri + Rj for each of npairs i,j pairs among nnn neighbors // pairs = squared length of each R @@ -224,13 +219,12 @@ void ComputeCentroAtom::compute_peratom() n = 0; for (j = 0; j < nnn; j++) { jj = nearest[j]; - for (k = j+1; k < nnn; k++) { + for (k = j + 1; k < nnn; k++) { kk = nearest[k]; - delx = x[jj][0] + x[kk][0] - 2.0*xtmp; - dely = x[jj][1] + x[kk][1] - 2.0*ytmp; - delz = x[jj][2] + x[kk][2] - 2.0*ztmp; - pairs[n++] = delx*delx + dely*dely + delz*delz; - + delx = x[jj][0] + x[kk][0] - 2.0 * xtmp; + dely = x[jj][1] + x[kk][1] - 2.0 * ytmp; + delz = x[jj][2] + x[kk][2] - 2.0 * ztmp; + pairs[n++] = delx * delx + dely * dely + delz * delz; } } @@ -242,11 +236,11 @@ void ComputeCentroAtom::compute_peratom() // R1, R2 are corresponding vectors Ri - Rj // R3 is normal to R1, R2 - double rsq1,rsq2; + double rsq1, rsq2; - double* r1 = &array_atom[i][1]; - double* r2 = &array_atom[i][4]; - double* r3 = &array_atom[i][7]; + double *r1 = &array_atom[i][1]; + double *r2 = &array_atom[i][4]; + double *r3 = &array_atom[i][7]; if (n < nnn) { centro[i] = 0.0; @@ -258,18 +252,18 @@ void ComputeCentroAtom::compute_peratom() // store nnn nearest neighs in 1st nnn locations of distsq and nearest - select2(nnn,n,distsq,nearest); + select2(nnn, n, distsq, nearest); n = 0; rsq1 = rsq2 = cutsq; for (j = 0; j < nnn; j++) { jj = nearest[j]; - for (k = j+1; k < nnn; k++) { + for (k = j + 1; k < nnn; k++) { kk = nearest[k]; - delx = x[jj][0] + x[kk][0] - 2.0*xtmp; - dely = x[jj][1] + x[kk][1] - 2.0*ytmp; - delz = x[jj][2] + x[kk][2] - 2.0*ztmp; - rsq = delx*delx + dely*dely + delz*delz; + delx = x[jj][0] + x[kk][0] - 2.0 * xtmp; + dely = x[jj][1] + x[kk][1] - 2.0 * ytmp; + delz = x[jj][2] + x[kk][2] - 2.0 * ztmp; + rsq = delx * delx + dely * dely + delz * delz; pairs[n++] = rsq; if (rsq < rsq2) { @@ -277,16 +271,16 @@ void ComputeCentroAtom::compute_peratom() rsq2 = rsq1; MathExtra::copy3(r1, r2); rsq1 = rsq; - MathExtra::sub3(x[jj],x[kk],r1); + MathExtra::sub3(x[jj], x[kk], r1); } else { rsq2 = rsq; - MathExtra::sub3(x[jj],x[kk],r2); + MathExtra::sub3(x[jj], x[kk], r2); } } } } - MathExtra::cross3(r1,r2,r3); + MathExtra::cross3(r1, r2, r3); MathExtra::norm3(r1); MathExtra::norm3(r2); MathExtra::norm3(r3); @@ -294,7 +288,7 @@ void ComputeCentroAtom::compute_peratom() // store nhalf smallest pair distances in 1st nhalf locations of pairs - select(nhalf,npairs,pairs); + select(nhalf, npairs, pairs); // centrosymmetry = sum of nhalf smallest squared values @@ -312,64 +306,62 @@ void ComputeCentroAtom::compute_peratom() } } - delete [] pairs; + delete[] pairs; if (axes_flag) for (ii = 0; ii < inum; ii++) { i = ilist[ii]; - if (mask[i] & groupbit) - array_atom[i][0] = centro[i]; + if (mask[i] & groupbit) array_atom[i][0] = centro[i]; } } - /* ---------------------------------------------------------------------- 2 select routines from Numerical Recipes (slightly modified) find k smallest values in array of length n 2nd routine sorts auxiliary array at same time ------------------------------------------------------------------------- */ -#define SWAP(a,b) tmp = a; a = b; b = tmp; -#define ISWAP(a,b) itmp = a; a = b; b = itmp; +#define SWAP(a, b) \ + tmp = a; \ + a = b; \ + b = tmp; +#define ISWAP(a, b) \ + itmp = a; \ + a = b; \ + b = itmp; void ComputeCentroAtom::select(int k, int n, double *arr) { - int i,ir,j,l,mid; - double a,tmp; + int i, ir, j, l, mid; + double a, tmp; arr--; l = 1; ir = n; for (;;) { - if (ir <= l+1) { - if (ir == l+1 && arr[ir] < arr[l]) { - SWAP(arr[l],arr[ir]) - } + if (ir <= l + 1) { + if (ir == l + 1 && arr[ir] < arr[l]) { SWAP(arr[l], arr[ir]) } return; } else { - mid=(l+ir) >> 1; - SWAP(arr[mid],arr[l+1]) - if (arr[l] > arr[ir]) { - SWAP(arr[l],arr[ir]) - } - if (arr[l+1] > arr[ir]) { - SWAP(arr[l+1],arr[ir]) - } - if (arr[l] > arr[l+1]) { - SWAP(arr[l],arr[l+1]) - } - i = l+1; + mid = (l + ir) >> 1; + SWAP(arr[mid], arr[l + 1]) + if (arr[l] > arr[ir]) { SWAP(arr[l], arr[ir]) } + if (arr[l + 1] > arr[ir]) { SWAP(arr[l + 1], arr[ir]) } + if (arr[l] > arr[l + 1]) { SWAP(arr[l], arr[l + 1]) } + i = l + 1; j = ir; - a = arr[l+1]; + a = arr[l + 1]; for (;;) { - do i++; while (arr[i] < a); - do j--; while (arr[j] > a); + do i++; + while (arr[i] < a); + do j--; + while (arr[j] > a); if (j < i) break; - SWAP(arr[i],arr[j]) + SWAP(arr[i], arr[j]) } - arr[l+1] = arr[j]; + arr[l + 1] = arr[j]; arr[j] = a; - if (j >= k) ir = j-1; + if (j >= k) ir = j - 1; if (j <= k) l = i; } } @@ -379,52 +371,54 @@ void ComputeCentroAtom::select(int k, int n, double *arr) void ComputeCentroAtom::select2(int k, int n, double *arr, int *iarr) { - int i,ir,j,l,mid,ia,itmp; - double a,tmp; + int i, ir, j, l, mid, ia, itmp; + double a, tmp; arr--; iarr--; l = 1; ir = n; for (;;) { - if (ir <= l+1) { - if (ir == l+1 && arr[ir] < arr[l]) { - SWAP(arr[l],arr[ir]) - ISWAP(iarr[l],iarr[ir]) + if (ir <= l + 1) { + if (ir == l + 1 && arr[ir] < arr[l]) { + SWAP(arr[l], arr[ir]) + ISWAP(iarr[l], iarr[ir]) } return; } else { - mid=(l+ir) >> 1; - SWAP(arr[mid],arr[l+1]) - ISWAP(iarr[mid],iarr[l+1]) + mid = (l + ir) >> 1; + SWAP(arr[mid], arr[l + 1]) + ISWAP(iarr[mid], iarr[l + 1]) if (arr[l] > arr[ir]) { - SWAP(arr[l],arr[ir]) - ISWAP(iarr[l],iarr[ir]) + SWAP(arr[l], arr[ir]) + ISWAP(iarr[l], iarr[ir]) } - if (arr[l+1] > arr[ir]) { - SWAP(arr[l+1],arr[ir]) - ISWAP(iarr[l+1],iarr[ir]) + if (arr[l + 1] > arr[ir]) { + SWAP(arr[l + 1], arr[ir]) + ISWAP(iarr[l + 1], iarr[ir]) } - if (arr[l] > arr[l+1]) { - SWAP(arr[l],arr[l+1]) - ISWAP(iarr[l],iarr[l+1]) + if (arr[l] > arr[l + 1]) { + SWAP(arr[l], arr[l + 1]) + ISWAP(iarr[l], iarr[l + 1]) } - i = l+1; + i = l + 1; j = ir; - a = arr[l+1]; - ia = iarr[l+1]; + a = arr[l + 1]; + ia = iarr[l + 1]; for (;;) { - do i++; while (arr[i] < a); - do j--; while (arr[j] > a); + do i++; + while (arr[i] < a); + do j--; + while (arr[j] > a); if (j < i) break; - SWAP(arr[i],arr[j]) - ISWAP(iarr[i],iarr[j]) + SWAP(arr[i], arr[j]) + ISWAP(iarr[i], iarr[j]) } - arr[l+1] = arr[j]; + arr[l + 1] = arr[j]; arr[j] = a; - iarr[l+1] = iarr[j]; + iarr[l + 1] = iarr[j]; iarr[j] = ia; - if (j >= k) ir = j-1; + if (j >= k) ir = j - 1; if (j <= k) l = i; } } @@ -436,7 +430,7 @@ void ComputeCentroAtom::select2(int k, int n, double *arr, int *iarr) double ComputeCentroAtom::memory_usage() { - double bytes = (double)nmax * sizeof(double); - if (axes_flag) bytes += (double)size_peratom_cols*nmax * sizeof(double); + double bytes = (double) nmax * sizeof(double); + if (axes_flag) bytes += (double) size_peratom_cols * nmax * sizeof(double); return bytes; } diff --git a/src/compute_cluster_atom.cpp b/src/compute_cluster_atom.cpp index c429ba5cac..07a0c700ee 100644 --- a/src/compute_cluster_atom.cpp +++ b/src/compute_cluster_atom.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -22,7 +21,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -32,18 +30,17 @@ using namespace LAMMPS_NS; -enum{CLUSTER,MASK,COORDS}; +enum { CLUSTER, MASK, COORDS }; /* ---------------------------------------------------------------------- */ ComputeClusterAtom::ComputeClusterAtom(LAMMPS *lmp, int narg, char **arg) : - Compute(lmp, narg, arg), - clusterID(nullptr) + Compute(lmp, narg, arg), clusterID(nullptr) { - if (narg != 4) error->all(FLERR,"Illegal compute cluster/atom command"); + if (narg != 4) error->all(FLERR, "Illegal compute cluster/atom command"); - double cutoff = utils::numeric(FLERR,arg[3],false,lmp); - cutsq = cutoff*cutoff; + double cutoff = utils::numeric(FLERR, arg[3], false, lmp); + cutsq = cutoff * cutoff; peratom_flag = 1; size_peratom_cols = 0; @@ -64,28 +61,21 @@ ComputeClusterAtom::~ComputeClusterAtom() void ComputeClusterAtom::init() { if (atom->tag_enable == 0) - error->all(FLERR,"Cannot use compute cluster/atom unless atoms have IDs"); + error->all(FLERR, "Cannot use compute cluster/atom unless atoms have IDs"); if (force->pair == nullptr) - error->all(FLERR,"Compute cluster/atom requires a pair style to be defined"); + error->all(FLERR, "Compute cluster/atom requires a pair style to be defined"); if (sqrt(cutsq) > force->pair->cutforce) - error->all(FLERR, - "Compute cluster/atom cutoff is longer than pairwise cutoff"); + error->all(FLERR, "Compute cluster/atom cutoff is longer than pairwise cutoff"); // need an occasional full neighbor list // full required so that pair of atoms on 2 procs both set their clusterID - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); int count = 0; for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"cluster/atom") == 0) count++; - if (count > 1 && comm->me == 0) - error->warning(FLERR,"More than one compute cluster/atom"); + if (strcmp(modify->compute[i]->style, "cluster/atom") == 0) count++; + if (count > 1 && comm->me == 0) error->warning(FLERR, "More than one compute cluster/atom"); } /* ---------------------------------------------------------------------- */ @@ -99,9 +89,9 @@ void ComputeClusterAtom::init_list(int /*id*/, NeighList *ptr) void ComputeClusterAtom::compute_peratom() { - int i,j,ii,jj,inum,jnum; - double xtmp,ytmp,ztmp,delx,dely,delz,rsq; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum; + double xtmp, ytmp, ztmp, delx, dely, delz, rsq; + int *ilist, *jlist, *numneigh, **firstneigh; invoked_peratom = update->ntimestep; @@ -110,15 +100,17 @@ void ComputeClusterAtom::compute_peratom() if (atom->nmax > nmax) { memory->destroy(clusterID); nmax = atom->nmax; - memory->create(clusterID,nmax,"cluster/atom:clusterID"); + memory->create(clusterID, nmax, "cluster/atom:clusterID"); vector_atom = clusterID; } // invoke full neighbor list (will copy or build if necessary) // on the first step of a run, set preflag to one in neighbor->build_one(...) - if (update->firststep == update->ntimestep) neighbor->build_one(list,1); - else neighbor->build_one(list); + if (update->firststep == update->ntimestep) + neighbor->build_one(list, 1); + else + neighbor->build_one(list); inum = list->inum; ilist = list->ilist; @@ -148,8 +140,10 @@ void ComputeClusterAtom::compute_peratom() for (ii = 0; ii < inum; ii++) { i = ilist[ii]; - if (mask[i] & groupbit) clusterID[i] = tag[i]; - else clusterID[i] = 0; + if (mask[i] & groupbit) + clusterID[i] = tag[i]; + else + clusterID[i] = 0; } // loop until no more changes on any proc: @@ -162,7 +156,7 @@ void ComputeClusterAtom::compute_peratom() commflag = CLUSTER; double **x = atom->x; - int change,done,anychange; + int change, done, anychange; while (true) { comm->forward_comm(this); @@ -189,9 +183,9 @@ void ComputeClusterAtom::compute_peratom() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { - clusterID[i] = clusterID[j] = MIN(clusterID[i],clusterID[j]); + clusterID[i] = clusterID[j] = MIN(clusterID[i], clusterID[j]); done = 0; } } @@ -202,17 +196,17 @@ void ComputeClusterAtom::compute_peratom() // stop if all procs are done - MPI_Allreduce(&change,&anychange,1,MPI_INT,MPI_MAX,world); + MPI_Allreduce(&change, &anychange, 1, MPI_INT, MPI_MAX, world); if (!anychange) break; } } /* ---------------------------------------------------------------------- */ -int ComputeClusterAtom::pack_forward_comm(int n, int *list, double *buf, - int /*pbc_flag*/, int * /*pbc*/) +int ComputeClusterAtom::pack_forward_comm(int n, int *list, double *buf, int /*pbc_flag*/, + int * /*pbc*/) { - int i,j,m; + int i, j, m; m = 0; if (commflag == CLUSTER) { @@ -243,7 +237,7 @@ int ComputeClusterAtom::pack_forward_comm(int n, int *list, double *buf, void ComputeClusterAtom::unpack_forward_comm(int n, int first, double *buf) { - int i,m,last; + int i, m, last; m = 0; last = first + n; @@ -268,6 +262,6 @@ void ComputeClusterAtom::unpack_forward_comm(int n, int first, double *buf) double ComputeClusterAtom::memory_usage() { - double bytes = (double)nmax * sizeof(double); + double bytes = (double) nmax * sizeof(double); return bytes; } diff --git a/src/compute_cna_atom.cpp b/src/compute_cna_atom.cpp index e002e54983..4b9c28362c 100644 --- a/src/compute_cna_atom.cpp +++ b/src/compute_cna_atom.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -25,36 +24,34 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" -#include #include +#include using namespace LAMMPS_NS; -#define MAXNEAR 16 -#define MAXCOMMON 8 +static constexpr int MAXNEAR = 16; +static constexpr int MAXCOMMON = 8; -enum{UNKNOWN,FCC,HCP,BCC,ICOS,OTHER}; -enum{NCOMMON,NBOND,MAXBOND,MINBOND}; +enum { UNKNOWN, FCC, HCP, BCC, ICOS, OTHER }; +enum { NCOMMON, NBOND, MAXBOND, MINBOND }; /* ---------------------------------------------------------------------- */ ComputeCNAAtom::ComputeCNAAtom(LAMMPS *lmp, int narg, char **arg) : - Compute(lmp, narg, arg), - list(nullptr), nearest(nullptr), nnearest(nullptr), pattern(nullptr) + Compute(lmp, narg, arg), list(nullptr), nearest(nullptr), nnearest(nullptr), pattern(nullptr) { - if (narg != 4) error->all(FLERR,"Illegal compute cna/atom command"); + if (narg != 4) error->all(FLERR, "Illegal compute cna/atom command"); peratom_flag = 1; size_peratom_cols = 0; - double cutoff = utils::numeric(FLERR,arg[3],false,lmp); - if (cutoff < 0.0) error->all(FLERR,"Illegal compute cna/atom command"); - cutsq = cutoff*cutoff; + double cutoff = utils::numeric(FLERR, arg[3], false, lmp); + if (cutoff < 0.0) error->all(FLERR, "Illegal compute cna/atom command"); + cutsq = cutoff * cutoff; nmax = 0; } @@ -73,31 +70,25 @@ ComputeCNAAtom::~ComputeCNAAtom() void ComputeCNAAtom::init() { if (force->pair == nullptr) - error->all(FLERR,"Compute cna/atom requires a pair style be defined"); + error->all(FLERR, "Compute cna/atom requires a pair style be defined"); if (sqrt(cutsq) > force->pair->cutforce) - error->all(FLERR,"Compute cna/atom cutoff is longer than pairwise cutoff"); + error->all(FLERR, "Compute cna/atom cutoff is longer than pairwise cutoff"); // cannot use neighbor->cutneighmax b/c neighbor has not yet been init - if (2.0*sqrt(cutsq) > force->pair->cutforce + neighbor->skin && - comm->me == 0) - error->warning(FLERR,"Compute cna/atom cutoff may be too large to find " + if (2.0 * sqrt(cutsq) > force->pair->cutforce + neighbor->skin && comm->me == 0) + error->warning(FLERR, + "Compute cna/atom cutoff may be too large to find " "ghost atom neighbors"); int count = 0; for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"cna/atom") == 0) count++; - if (count > 1 && comm->me == 0) - error->warning(FLERR,"More than one compute cna/atom defined"); + if (strcmp(modify->compute[i]->style, "cna/atom") == 0) count++; + if (count > 1 && comm->me == 0) error->warning(FLERR, "More than one compute cna/atom defined"); // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ @@ -111,13 +102,13 @@ void ComputeCNAAtom::init_list(int /*id*/, NeighList *ptr) void ComputeCNAAtom::compute_peratom() { - int i,j,k,ii,jj,kk,m,n,inum,jnum,inear,jnear; - int firstflag,ncommon,nbonds,maxbonds,minbonds; - int nfcc,nhcp,nbcc4,nbcc6,nico,cj,ck,cl,cm; - int *ilist,*jlist,*numneigh,**firstneigh; - int cna[MAXNEAR][4],onenearest[MAXNEAR]; - int common[MAXCOMMON],bonds[MAXCOMMON]; - double xtmp,ytmp,ztmp,delx,dely,delz,rsq; + int i, j, k, ii, jj, kk, m, n, inum, jnum, inear, jnear; + int firstflag, ncommon, nbonds, maxbonds, minbonds; + int nfcc, nhcp, nbcc4, nbcc6, nico, cj, ck, cl, cm; + int *ilist, *jlist, *numneigh, **firstneigh; + int cna[MAXNEAR][4], onenearest[MAXNEAR]; + int common[MAXCOMMON], bonds[MAXCOMMON]; + double xtmp, ytmp, ztmp, delx, dely, delz, rsq; invoked_peratom = update->ntimestep; @@ -129,9 +120,9 @@ void ComputeCNAAtom::compute_peratom() memory->destroy(pattern); nmax = atom->nmax; - memory->create(nearest,nmax,MAXNEAR,"cna:nearest"); - memory->create(nnearest,nmax,"cna:nnearest"); - memory->create(pattern,nmax,"cna:cna_pattern"); + memory->create(nearest, nmax, MAXNEAR, "cna:nearest"); + memory->create(nnearest, nmax, "cna:nnearest"); + memory->create(pattern, nmax, "cna:cna_pattern"); vector_atom = pattern; } @@ -170,9 +161,10 @@ void ComputeCNAAtom::compute_peratom() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { - if (n < MAXNEAR) nearest[i][n++] = j; + if (n < MAXNEAR) + nearest[i][n++] = j; else { nerror++; break; @@ -185,9 +177,9 @@ void ComputeCNAAtom::compute_peratom() // warning message int nerrorall; - MPI_Allreduce(&nerror,&nerrorall,1,MPI_INT,MPI_SUM,world); + MPI_Allreduce(&nerror, &nerrorall, 1, MPI_INT, MPI_SUM, world); if (nerrorall && comm->me == 0) - error->warning(FLERR,"Too many neighbors in CNA for {} atoms",nerrorall); + error->warning(FLERR, "Too many neighbors in CNA for {} atoms", nerrorall); // compute CNA for each atom in group // only performed if # of nearest neighbors = 12 or 14 (fcc,hcp) @@ -226,7 +218,8 @@ void ComputeCNAAtom::compute_peratom() for (inear = 0; inear < nnearest[i]; inear++) for (jnear = 0; jnear < nnearest[j]; jnear++) if (nearest[i][inear] == nearest[j][jnear]) { - if (ncommon < MAXCOMMON) common[ncommon++] = nearest[i][inear]; + if (ncommon < MAXCOMMON) + common[ncommon++] = nearest[i][inear]; else if (firstflag) { nerror++; firstflag = 0; @@ -249,10 +242,12 @@ void ComputeCNAAtom::compute_peratom() delx = xtmp - x[k][0]; dely = ytmp - x[k][1]; delz = ztmp - x[k][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { - if (n < MAXNEAR) onenearest[n++] = k; - else break; + if (n < MAXNEAR) + onenearest[n++] = k; + else + break; } } @@ -261,7 +256,8 @@ void ComputeCNAAtom::compute_peratom() for (inear = 0; inear < nnearest[i]; inear++) for (jnear = 0; (jnear < n) && (n < MAXNEAR); jnear++) if (nearest[i][inear] == onenearest[jnear]) { - if (ncommon < MAXCOMMON) common[ncommon++] = nearest[i][inear]; + if (ncommon < MAXCOMMON) + common[ncommon++] = nearest[i][inear]; else if (firstflag) { nerror++; firstflag = 0; @@ -278,17 +274,17 @@ void ComputeCNAAtom::compute_peratom() for (n = 0; n < ncommon; n++) bonds[n] = 0; nbonds = 0; - for (jj = 0; jj < ncommon-1; jj++) { + for (jj = 0; jj < ncommon - 1; jj++) { j = common[jj]; xtmp = x[j][0]; ytmp = x[j][1]; ztmp = x[j][2]; - for (kk = jj+1; kk < ncommon; kk++) { + for (kk = jj + 1; kk < ncommon; kk++) { k = common[kk]; delx = xtmp - x[k][0]; dely = ytmp - x[k][1]; delz = ztmp - x[k][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { nbonds++; bonds[jj]++; @@ -302,8 +298,8 @@ void ComputeCNAAtom::compute_peratom() maxbonds = 0; minbonds = MAXCOMMON; for (n = 0; n < ncommon; n++) { - maxbonds = MAX(bonds[n],maxbonds); - minbonds = MIN(bonds[n],minbonds); + maxbonds = MAX(bonds[n], maxbonds); + minbonds = MIN(bonds[n], minbonds); } cna[m][MAXBOND] = maxbonds; cna[m][MINBOND] = minbonds; @@ -320,13 +316,19 @@ void ComputeCNAAtom::compute_peratom() ck = cna[inear][NBOND]; cl = cna[inear][MAXBOND]; cm = cna[inear][MINBOND]; - if (cj == 4 && ck == 2 && cl == 1 && cm == 1) nfcc++; - else if (cj == 4 && ck == 2 && cl == 2 && cm == 0) nhcp++; - else if (cj == 5 && ck == 5 && cl == 2 && cm == 2) nico++; + if (cj == 4 && ck == 2 && cl == 1 && cm == 1) + nfcc++; + else if (cj == 4 && ck == 2 && cl == 2 && cm == 0) + nhcp++; + else if (cj == 5 && ck == 5 && cl == 2 && cm == 2) + nico++; } - if (nfcc == 12) pattern[i] = FCC; - else if (nfcc == 6 && nhcp == 6) pattern[i] = HCP; - else if (nico == 12) pattern[i] = ICOS; + if (nfcc == 12) + pattern[i] = FCC; + else if (nfcc == 6 && nhcp == 6) + pattern[i] = HCP; + else if (nico == 12) + pattern[i] = ICOS; } else if (nnearest[i] == 14) { for (inear = 0; inear < 14; inear++) { @@ -334,8 +336,10 @@ void ComputeCNAAtom::compute_peratom() ck = cna[inear][NBOND]; cl = cna[inear][MAXBOND]; cm = cna[inear][MINBOND]; - if (cj == 4 && ck == 4 && cl == 2 && cm == 2) nbcc4++; - else if (cj == 6 && ck == 6 && cl == 2 && cm == 2) nbcc6++; + if (cj == 4 && ck == 4 && cl == 2 && cm == 2) + nbcc4++; + else if (cj == 6 && ck == 6 && cl == 2 && cm == 2) + nbcc6++; } if (nbcc4 == 6 && nbcc6 == 8) pattern[i] = BCC; } @@ -343,9 +347,9 @@ void ComputeCNAAtom::compute_peratom() // warning message - MPI_Allreduce(&nerror,&nerrorall,1,MPI_INT,MPI_SUM,world); + MPI_Allreduce(&nerror, &nerrorall, 1, MPI_INT, MPI_SUM, world); if (nerrorall && comm->me == 0) - error->warning(FLERR,"Too many common neighbors in CNA: {}x", nerrorall); + error->warning(FLERR, "Too many common neighbors in CNA: {}x", nerrorall); } /* ---------------------------------------------------------------------- @@ -354,8 +358,8 @@ void ComputeCNAAtom::compute_peratom() double ComputeCNAAtom::memory_usage() { - double bytes = (double)nmax * sizeof(int); - bytes += (double)nmax * MAXNEAR * sizeof(int); - bytes += (double)nmax * sizeof(double); + double bytes = (double) nmax * sizeof(int); + bytes += (double) nmax * MAXNEAR * sizeof(int); + bytes += (double) nmax * sizeof(double); return bytes; } diff --git a/src/compute_coord_atom.cpp b/src/compute_coord_atom.cpp index 45784205d3..4487e82985 100644 --- a/src/compute_coord_atom.cpp +++ b/src/compute_coord_atom.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -23,7 +22,6 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" @@ -33,36 +31,33 @@ using namespace LAMMPS_NS; - /* ---------------------------------------------------------------------- */ ComputeCoordAtom::ComputeCoordAtom(LAMMPS *lmp, int narg, char **arg) : - Compute(lmp, narg, arg), - typelo(nullptr), typehi(nullptr), cvec(nullptr), carray(nullptr), - group2(nullptr), id_orientorder(nullptr), normv(nullptr) + Compute(lmp, narg, arg), typelo(nullptr), typehi(nullptr), cvec(nullptr), carray(nullptr), + group2(nullptr), id_orientorder(nullptr), normv(nullptr) { - if (narg < 5) error->all(FLERR,"Illegal compute coord/atom command"); + if (narg < 5) error->all(FLERR, "Illegal compute coord/atom command"); jgroup = group->find("all"); jgroupbit = group->bitmask[jgroup]; cstyle = NONE; - if (strcmp(arg[3],"cutoff") == 0) { + if (strcmp(arg[3], "cutoff") == 0) { cstyle = CUTOFF; - double cutoff = utils::numeric(FLERR,arg[4],false,lmp); - cutsq = cutoff*cutoff; + double cutoff = utils::numeric(FLERR, arg[4], false, lmp); + cutsq = cutoff * cutoff; int iarg = 5; - if ((narg > 6) && (strcmp(arg[5],"group") == 0)) { + if ((narg > 6) && (strcmp(arg[5], "group") == 0)) { group2 = utils::strdup(arg[6]); iarg += 2; jgroup = group->find(group2); - if (jgroup == -1) - error->all(FLERR,"Compute coord/atom group2 ID does not exist"); + if (jgroup == -1) error->all(FLERR, "Compute coord/atom group2 ID does not exist"); jgroupbit = group->bitmask[jgroup]; } - ncol = narg-iarg + 1; + ncol = narg - iarg + 1; int ntypes = atom->ntypes; typelo = new int[ncol]; typehi = new int[ncol]; @@ -74,29 +69,27 @@ ComputeCoordAtom::ComputeCoordAtom(LAMMPS *lmp, int narg, char **arg) : } else { ncol = 0; while (iarg < narg) { - utils::bounds(FLERR,arg[iarg],1,ntypes,typelo[ncol],typehi[ncol],error); - if (typelo[ncol] > typehi[ncol]) - error->all(FLERR,"Illegal compute coord/atom command"); + utils::bounds(FLERR, arg[iarg], 1, ntypes, typelo[ncol], typehi[ncol], error); + if (typelo[ncol] > typehi[ncol]) error->all(FLERR, "Illegal compute coord/atom command"); ncol++; iarg++; } } - } else if (strcmp(arg[3],"orientorder") == 0) { + } else if (strcmp(arg[3], "orientorder") == 0) { cstyle = ORIENT; - if (narg != 6) error->all(FLERR,"Illegal compute coord/atom command"); + if (narg != 6) error->all(FLERR, "Illegal compute coord/atom command"); id_orientorder = utils::strdup(arg[4]); int iorientorder = modify->find_compute(id_orientorder); - if (iorientorder < 0) - error->all(FLERR,"Could not find compute coord/atom compute ID"); - if (!utils::strmatch(modify->compute[iorientorder]->style,"^orientorder/atom")) - error->all(FLERR,"Compute coord/atom compute ID is not orientorder/atom"); + if (iorientorder < 0) error->all(FLERR, "Could not find compute coord/atom compute ID"); + if (!utils::strmatch(modify->compute[iorientorder]->style, "^orientorder/atom")) + error->all(FLERR, "Compute coord/atom compute ID is not orientorder/atom"); - threshold = utils::numeric(FLERR,arg[5],false,lmp); + threshold = utils::numeric(FLERR, arg[5], false, lmp); if (threshold <= -1.0 || threshold >= 1.0) - error->all(FLERR,"Compute coord/atom threshold not between -1 and 1"); + error->all(FLERR, "Compute coord/atom threshold not between -1 and 1"); ncol = 1; typelo = new int[ncol]; @@ -104,11 +97,14 @@ ComputeCoordAtom::ComputeCoordAtom(LAMMPS *lmp, int narg, char **arg) : typelo[0] = 1; typehi[0] = atom->ntypes; - } else error->all(FLERR,"Invalid cstyle in compute coord/atom"); + } else + error->all(FLERR, "Invalid cstyle in compute coord/atom"); peratom_flag = 1; - if (ncol == 1) size_peratom_cols = 0; - else size_peratom_cols = ncol; + if (ncol == 1) + size_peratom_cols = 0; + else + size_peratom_cols = ncol; nmax = 0; } @@ -119,12 +115,12 @@ ComputeCoordAtom::~ComputeCoordAtom() { if (copymode) return; - delete [] group2; - delete [] typelo; - delete [] typehi; + delete[] group2; + delete[] typelo; + delete[] typehi; memory->destroy(cvec); memory->destroy(carray); - delete [] id_orientorder; + delete[] id_orientorder; } /* ---------------------------------------------------------------------- */ @@ -133,30 +129,24 @@ void ComputeCoordAtom::init() { if (cstyle == ORIENT) { int iorientorder = modify->find_compute(id_orientorder); - c_orientorder = (ComputeOrientOrderAtom*)(modify->compute[iorientorder]); + c_orientorder = (ComputeOrientOrderAtom *) (modify->compute[iorientorder]); cutsq = c_orientorder->cutsq; l = c_orientorder->qlcomp; // communicate real and imaginary 2*l+1 components of the normalized vector - comm_forward = 2*(2*l+1); + comm_forward = 2 * (2 * l + 1); if (!(c_orientorder->qlcompflag)) - error->all(FLERR,"Compute coord/atom requires components " - "option in compute orientorder/atom"); + error->all(FLERR, + "Compute coord/atom requires components option in compute orientorder/atom"); } if (force->pair == nullptr) - error->all(FLERR,"Compute coord/atom requires a pair style be defined"); + error->all(FLERR, "Compute coord/atom requires a pair style be defined"); if (sqrt(cutsq) > force->pair->cutforce) - error->all(FLERR, - "Compute coord/atom cutoff is longer than pairwise cutoff"); + error->all(FLERR, "Compute coord/atom cutoff is longer than pairwise cutoff"); // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ @@ -170,9 +160,9 @@ void ComputeCoordAtom::init_list(int /*id*/, NeighList *ptr) void ComputeCoordAtom::compute_peratom() { - int i,j,m,ii,jj,inum,jnum,jtype,n; - double xtmp,ytmp,ztmp,delx,dely,delz,rsq; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, m, ii, jj, inum, jnum, jtype, n; + double xtmp, ytmp, ztmp, delx, dely, delz, rsq; + int *ilist, *jlist, *numneigh, **firstneigh; double *count; invoked_peratom = update->ntimestep; @@ -183,12 +173,12 @@ void ComputeCoordAtom::compute_peratom() if (ncol == 1) { memory->destroy(cvec); nmax = atom->nmax; - memory->create(cvec,nmax,"coord/atom:cvec"); + memory->create(cvec, nmax, "coord/atom:cvec"); vector_atom = cvec; } else { memory->destroy(carray); nmax = atom->nmax; - memory->create(carray,nmax,ncol,"coord/atom:carray"); + memory->create(carray, nmax, ncol, "coord/atom:carray"); array_atom = carray; } } @@ -242,14 +232,14 @@ void ComputeCoordAtom::compute_peratom() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; - if (rsq < cutsq && jtype >= typelo[0] && jtype <= typehi[0]) - n++; + rsq = delx * delx + dely * dely + delz * delz; + if (rsq < cutsq && jtype >= typelo[0] && jtype <= typehi[0]) n++; } } cvec[i] = n; - } else cvec[i] = 0.0; + } else + cvec[i] = 0.0; } } else { @@ -265,7 +255,6 @@ void ComputeCoordAtom::compute_peratom() jlist = firstneigh[i]; jnum = numneigh[i]; - for (jj = 0; jj < jnum; jj++) { j = jlist[jj]; j &= NEIGHMASK; @@ -274,11 +263,10 @@ void ComputeCoordAtom::compute_peratom() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { for (m = 0; m < ncol; m++) - if (jtype >= typelo[m] && jtype <= typehi[m]) - count[m] += 1.0; + if (jtype >= typelo[m] && jtype <= typehi[m]) count[m] += 1.0; } } } @@ -303,31 +291,30 @@ void ComputeCoordAtom::compute_peratom() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { double dot_product = 0.0; - for (m=0; m < 2*(2*l+1); m++) { - dot_product += normv[i][nqlist+m]*normv[j][nqlist+m]; + for (m = 0; m < 2 * (2 * l + 1); m++) { + dot_product += normv[i][nqlist + m] * normv[j][nqlist + m]; } if (dot_product > threshold) n++; } } cvec[i] = n; - } else cvec[i] = 0.0; + } else + cvec[i] = 0.0; } } } /* ---------------------------------------------------------------------- */ -int ComputeCoordAtom::pack_forward_comm(int n, int *list, double *buf, - int /*pbc_flag*/, int * /*pbc*/) +int ComputeCoordAtom::pack_forward_comm(int n, int *list, double *buf, int /*pbc_flag*/, + int * /*pbc*/) { - int i,m=0,j; + int i, m = 0, j; for (i = 0; i < n; ++i) { - for (j = nqlist; j < nqlist + 2*(2*l+1); ++j) { - buf[m++] = normv[list[i]][j]; - } + for (j = nqlist; j < nqlist + 2 * (2 * l + 1); ++j) { buf[m++] = normv[list[i]][j]; } } return m; @@ -337,12 +324,10 @@ int ComputeCoordAtom::pack_forward_comm(int n, int *list, double *buf, void ComputeCoordAtom::unpack_forward_comm(int n, int first, double *buf) { - int i,last,m=0,j; + int i, last, m = 0, j; last = first + n; for (i = first; i < last; ++i) { - for (j = nqlist; j < nqlist + 2*(2*l+1); ++j) { - normv[i][j] = buf[m++]; - } + for (j = nqlist; j < nqlist + 2 * (2 * l + 1); ++j) { normv[i][j] = buf[m++]; } } } @@ -352,6 +337,6 @@ void ComputeCoordAtom::unpack_forward_comm(int n, int first, double *buf) double ComputeCoordAtom::memory_usage() { - double bytes = (double)ncol*nmax * sizeof(double); + double bytes = (double) ncol * nmax * sizeof(double); return bytes; } diff --git a/src/compute_group_group.cpp b/src/compute_group_group.cpp index db26a75880..2fcd3b9c22 100644 --- a/src/compute_group_group.cpp +++ b/src/compute_group_group.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -28,28 +27,26 @@ #include "kspace.h" #include "math_const.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" -#include #include +#include using namespace LAMMPS_NS; using namespace MathConst; #define SMALL 0.00001 -enum{OFF,INTER,INTRA}; +enum { OFF, INTER, INTRA }; /* ---------------------------------------------------------------------- */ ComputeGroupGroup::ComputeGroupGroup(LAMMPS *lmp, int narg, char **arg) : - Compute(lmp, narg, arg), - group2(nullptr) + Compute(lmp, narg, arg), group2(nullptr) { - if (narg < 4) error->all(FLERR,"Illegal compute group/group command"); + if (narg < 4) error->all(FLERR, "Illegal compute group/group command"); scalar_flag = vector_flag = 1; size_vector = 3; @@ -58,8 +55,7 @@ ComputeGroupGroup::ComputeGroupGroup(LAMMPS *lmp, int narg, char **arg) : group2 = utils::strdup(arg[3]); jgroup = group->find(group2); - if (jgroup == -1) - error->all(FLERR,"Compute group/group group ID does not exist"); + if (jgroup == -1) error->all(FLERR, "Compute group/group group ID does not exist"); jgroupbit = group->bitmask[jgroup]; pairflag = 1; @@ -69,28 +65,33 @@ ComputeGroupGroup::ComputeGroupGroup(LAMMPS *lmp, int narg, char **arg) : int iarg = 4; while (iarg < narg) { - if (strcmp(arg[iarg],"pair") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute group/group command"); - pairflag = utils::logical(FLERR,arg[iarg+1],false,lmp); + if (strcmp(arg[iarg], "pair") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute group/group command"); + pairflag = utils::logical(FLERR, arg[iarg + 1], false, lmp); iarg += 2; - } else if (strcmp(arg[iarg],"kspace") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute group/group command"); - kspaceflag = utils::logical(FLERR,arg[iarg+1],false,lmp); + } else if (strcmp(arg[iarg], "kspace") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute group/group command"); + kspaceflag = utils::logical(FLERR, arg[iarg + 1], false, lmp); iarg += 2; - } else if (strcmp(arg[iarg],"boundary") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute group/group command"); - boundaryflag = utils::logical(FLERR,arg[iarg+1],false,lmp); + } else if (strcmp(arg[iarg], "boundary") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute group/group command"); + boundaryflag = utils::logical(FLERR, arg[iarg + 1], false, lmp); iarg += 2; - } else if (strcmp(arg[iarg],"molecule") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute group/group command"); - if (strcmp(arg[iarg+1],"off") == 0) molflag = OFF; - else if (strcmp(arg[iarg+1],"inter") == 0) molflag = INTER; - else if (strcmp(arg[iarg+1],"intra") == 0) molflag = INTRA; - else error->all(FLERR,"Illegal compute group/group command"); + } else if (strcmp(arg[iarg], "molecule") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute group/group command"); + if (strcmp(arg[iarg + 1], "off") == 0) + molflag = OFF; + else if (strcmp(arg[iarg + 1], "inter") == 0) + molflag = INTER; + else if (strcmp(arg[iarg + 1], "intra") == 0) + molflag = INTRA; + else + error->all(FLERR, "Illegal compute group/group command"); if (molflag != OFF && atom->molecule_flag == 0) - error->all(FLERR,"Compute group/group molecule requires molecule IDs"); + error->all(FLERR, "Compute group/group molecule requires molecule IDs"); iarg += 2; - } else error->all(FLERR,"Illegal compute group/group command"); + } else + error->all(FLERR, "Illegal compute group/group command"); } vector = new double[size_vector]; @@ -100,8 +101,8 @@ ComputeGroupGroup::ComputeGroupGroup(LAMMPS *lmp, int narg, char **arg) : ComputeGroupGroup::~ComputeGroupGroup() { - delete [] group2; - delete [] vector; + delete[] group2; + delete[] vector; } /* ---------------------------------------------------------------------- */ @@ -112,50 +113,47 @@ void ComputeGroupGroup::init() // if hybrid, let hybrid determine if sub-style sets single_enable = 0 if (pairflag && force->pair == nullptr) - error->all(FLERR,"No pair style defined for compute group/group"); - if (force->pair_match("^hybrid",0) == nullptr - && force->pair->single_enable == 0) - error->all(FLERR,"Pair style does not support compute group/group"); + error->all(FLERR, "No pair style defined for compute group/group"); + if (force->pair_match("^hybrid", 0) == nullptr && force->pair->single_enable == 0) + error->all(FLERR, "Pair style does not support compute group/group"); // error if Kspace style does not compute group/group interactions if (kspaceflag && force->kspace == nullptr) - error->all(FLERR,"No Kspace style defined for compute group/group"); + error->all(FLERR, "No Kspace style defined for compute group/group"); if (kspaceflag && force->kspace->group_group_enable == 0) - error->all(FLERR,"Kspace style does not support compute group/group"); + error->all(FLERR, "Kspace style does not support compute group/group"); if (pairflag) { pair = force->pair; cutsq = force->pair->cutsq; - } else pair = nullptr; + } else + pair = nullptr; - if (kspaceflag) kspace = force->kspace; - else kspace = nullptr; + if (kspaceflag) + kspace = force->kspace; + else + kspace = nullptr; // compute Kspace correction terms if (kspaceflag) { kspace_correction(); if ((fabs(e_correction) > SMALL) && (comm->me == 0)) - error->warning(FLERR,"Both groups in compute group/group have a net charge; " + error->warning(FLERR, + "Both groups in compute group/group have a net charge; " "the Kspace boundary correction to energy will be non-zero"); } // recheck that group 2 has not been deleted jgroup = group->find(group2); - if (jgroup == -1) - error->all(FLERR,"Compute group/group group ID does not exist"); + if (jgroup == -1) error->all(FLERR, "Compute group/group group ID does not exist"); jgroupbit = group->bitmask[jgroup]; // need an occasional half neighbor list - if (pairflag) { - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; - } + if (pairflag) neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); } /* ---------------------------------------------------------------------- */ @@ -197,10 +195,10 @@ void ComputeGroupGroup::compute_vector() void ComputeGroupGroup::pair_contribution() { - int i,j,ii,jj,inum,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz; - double rsq,eng,fpair,factor_coul,factor_lj; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz; + double rsq, eng, fpair, factor_coul, factor_lj; + int *ilist, *jlist, *numneigh, **firstneigh; double **x = atom->x; tagint *molecule = atom->molecule; @@ -269,11 +267,11 @@ void ComputeGroupGroup::pair_contribution() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - eng = pair->single(i,j,itype,jtype,rsq,factor_coul,factor_lj,fpair); + eng = pair->single(i, j, itype, jtype, rsq, factor_coul, factor_lj, fpair); // energy only computed once so tally full amount // force tally is jgroup acting on igroup @@ -281,25 +279,25 @@ void ComputeGroupGroup::pair_contribution() if (newton_pair || j < nlocal) { one[0] += eng; if (ij_flag) { - one[1] += delx*fpair; - one[2] += dely*fpair; - one[3] += delz*fpair; + one[1] += delx * fpair; + one[2] += dely * fpair; + one[3] += delz * fpair; } if (ji_flag) { - one[1] -= delx*fpair; - one[2] -= dely*fpair; - one[3] -= delz*fpair; + one[1] -= delx * fpair; + one[2] -= dely * fpair; + one[3] -= delz * fpair; } - // energy computed twice so tally half amount - // only tally force if I own igroup atom + // energy computed twice so tally half amount + // only tally force if I own igroup atom } else { - one[0] += 0.5*eng; + one[0] += 0.5 * eng; if (ij_flag) { - one[1] += delx*fpair; - one[2] += dely*fpair; - one[3] += delz*fpair; + one[1] += delx * fpair; + one[2] += dely * fpair; + one[3] += delz * fpair; } } } @@ -307,9 +305,11 @@ void ComputeGroupGroup::pair_contribution() } double all[4]; - MPI_Allreduce(one,all,4,MPI_DOUBLE,MPI_SUM,world); + MPI_Allreduce(one, all, 4, MPI_DOUBLE, MPI_SUM, world); scalar += all[0]; - vector[0] += all[1]; vector[1] += all[2]; vector[2] += all[3]; + vector[0] += all[1]; + vector[1] += all[2]; + vector[2] += all[3]; } /* ---------------------------------------------------------------------- */ @@ -318,8 +318,8 @@ void ComputeGroupGroup::kspace_contribution() { double *vector_kspace = force->kspace->f2group; - force->kspace->compute_group_group(groupbit,jgroupbit,0); - scalar += 2.0*force->kspace->e2group; + force->kspace->compute_group_group(groupbit, jgroupbit, 0); + scalar += 2.0 * force->kspace->e2group; vector[0] += vector_kspace[0]; vector[1] += vector_kspace[1]; vector[2] += vector_kspace[2]; @@ -328,7 +328,7 @@ void ComputeGroupGroup::kspace_contribution() // real-space style of compute group-group // add extra Kspace term to energy - force->kspace->compute_group_group(groupbit,jgroupbit,1); + force->kspace->compute_group_group(groupbit, jgroupbit, 1); scalar -= force->kspace->e2group; // self energy correction term @@ -345,8 +345,8 @@ void ComputeGroupGroup::kspace_contribution() // adjustment of z dimension for 2d slab Ewald // 3d Ewald just uses zprd since slab_volfactor = 1.0 - double volume = xprd*yprd*zprd*force->kspace->slab_volfactor; - scalar -= e_correction/volume; + double volume = xprd * yprd * zprd * force->kspace->slab_volfactor; + scalar -= e_correction / volume; } } @@ -357,7 +357,7 @@ void ComputeGroupGroup::kspace_correction() // total charge of groups A & B, needed for correction term - double qsqsum_group,qsum_A,qsum_B; + double qsqsum_group, qsum_A, qsum_B; qsqsum_group = qsum_A = qsum_B = 0.0; double *q = atom->q; @@ -366,20 +366,19 @@ void ComputeGroupGroup::kspace_correction() int groupbit_B = jgroupbit; for (int i = 0; i < atom->nlocal; i++) { - if ((mask[i] & groupbit_A) && (mask[i] & groupbit_B)) - qsqsum_group += q[i]*q[i]; + if ((mask[i] & groupbit_A) && (mask[i] & groupbit_B)) qsqsum_group += q[i] * q[i]; if (mask[i] & groupbit_A) qsum_A += q[i]; if (mask[i] & groupbit_B) qsum_B += q[i]; } double tmp; - MPI_Allreduce(&qsqsum_group,&tmp,1,MPI_DOUBLE,MPI_SUM,world); + MPI_Allreduce(&qsqsum_group, &tmp, 1, MPI_DOUBLE, MPI_SUM, world); qsqsum_group = tmp; - MPI_Allreduce(&qsum_A,&tmp,1,MPI_DOUBLE,MPI_SUM,world); + MPI_Allreduce(&qsum_A, &tmp, 1, MPI_DOUBLE, MPI_SUM, world); qsum_A = tmp; - MPI_Allreduce(&qsum_B,&tmp,1,MPI_DOUBLE,MPI_SUM,world); + MPI_Allreduce(&qsum_B, &tmp, 1, MPI_DOUBLE, MPI_SUM, world); qsum_B = tmp; double g_ewald = force->kspace->g_ewald; @@ -389,29 +388,28 @@ void ComputeGroupGroup::kspace_correction() // self-energy correction - e_self = qscale * g_ewald*qsqsum_group/MY_PIS; - e_correction = 2.0*qsum_A*qsum_B; + e_self = qscale * g_ewald * qsqsum_group / MY_PIS; + e_correction = 2.0 * qsum_A * qsum_B; // subtract extra AA terms qsum_A = qsum_B = 0.0; for (int i = 0; i < atom->nlocal; i++) { - if (!((mask[i] & groupbit_A) && (mask[i] & groupbit_B))) - continue; + if (!((mask[i] & groupbit_A) && (mask[i] & groupbit_B))) continue; if (mask[i] & groupbit_A) qsum_A += q[i]; if (mask[i] & groupbit_B) qsum_B += q[i]; } - MPI_Allreduce(&qsum_A,&tmp,1,MPI_DOUBLE,MPI_SUM,world); + MPI_Allreduce(&qsum_A, &tmp, 1, MPI_DOUBLE, MPI_SUM, world); qsum_A = tmp; - MPI_Allreduce(&qsum_B,&tmp,1,MPI_DOUBLE,MPI_SUM,world); + MPI_Allreduce(&qsum_B, &tmp, 1, MPI_DOUBLE, MPI_SUM, world); qsum_B = tmp; // k=0 energy correction term (still need to divide by volume above) - e_correction -= qsum_A*qsum_B; - e_correction *= qscale * MY_PI2 / (g_ewald*g_ewald); + e_correction -= qsum_A * qsum_B; + e_correction *= qscale * MY_PI2 / (g_ewald * g_ewald); } diff --git a/src/compute_orientorder_atom.cpp b/src/compute_orientorder_atom.cpp index fd020e1865..163f68e5ac 100644 --- a/src/compute_orientorder_atom.cpp +++ b/src/compute_orientorder_atom.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -28,23 +27,21 @@ #include "memory.h" #include "modify.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "pair.h" #include "update.h" -#include #include +#include using namespace LAMMPS_NS; using namespace MathConst; using namespace MathSpecial; - #ifdef DBL_EPSILON - #define MY_EPSILON (10.0*DBL_EPSILON) +#define MY_EPSILON (10.0 * DBL_EPSILON) #else - #define MY_EPSILON (10.0*2.220446049250313e-16) +#define MY_EPSILON (10.0 * 2.220446049250313e-16) #endif #define QEPSILON 1.0e-6 @@ -52,11 +49,10 @@ using namespace MathSpecial; /* ---------------------------------------------------------------------- */ ComputeOrientOrderAtom::ComputeOrientOrderAtom(LAMMPS *lmp, int narg, char **arg) : - Compute(lmp, narg, arg), - qlist(nullptr), distsq(nullptr), nearest(nullptr), rlist(nullptr), - qnarray(nullptr), qnm_r(nullptr), qnm_i(nullptr), cglist(nullptr) + Compute(lmp, narg, arg), qlist(nullptr), distsq(nullptr), nearest(nullptr), rlist(nullptr), + qnarray(nullptr), qnm_r(nullptr), qnm_i(nullptr), cglist(nullptr) { - if (narg < 3 ) error->all(FLERR,"Illegal compute orientorder/atom command"); + if (narg < 3) error->all(FLERR, "Illegal compute orientorder/atom command"); // set default values for optional args @@ -70,7 +66,7 @@ ComputeOrientOrderAtom::ComputeOrientOrderAtom(LAMMPS *lmp, int narg, char **arg // specify which orders to request nqlist = 5; - memory->create(qlist,nqlist,"orientorder/atom:qlist"); + memory->create(qlist, nqlist, "orientorder/atom:qlist"); qlist[0] = 4; qlist[1] = 6; qlist[2] = 8; @@ -82,69 +78,69 @@ ComputeOrientOrderAtom::ComputeOrientOrderAtom(LAMMPS *lmp, int narg, char **arg int iarg = 3; while (iarg < narg) { - if (strcmp(arg[iarg],"nnn") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute orientorder/atom command"); - if (strcmp(arg[iarg+1],"NULL") == 0) { + if (strcmp(arg[iarg], "nnn") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute orientorder/atom command"); + if (strcmp(arg[iarg + 1], "NULL") == 0) { nnn = 0; } else { - nnn = utils::numeric(FLERR,arg[iarg+1],false,lmp); - if (nnn <= 0) error->all(FLERR,"Illegal compute orientorder/atom command"); + nnn = utils::numeric(FLERR, arg[iarg + 1], false, lmp); + if (nnn <= 0) error->all(FLERR, "Illegal compute orientorder/atom command"); } iarg += 2; - } else if (strcmp(arg[iarg],"degrees") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute orientorder/atom command"); - nqlist = utils::numeric(FLERR,arg[iarg+1],false,lmp); - if (nqlist <= 0) error->all(FLERR,"Illegal compute orientorder/atom command"); + } else if (strcmp(arg[iarg], "degrees") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute orientorder/atom command"); + nqlist = utils::numeric(FLERR, arg[iarg + 1], false, lmp); + if (nqlist <= 0) error->all(FLERR, "Illegal compute orientorder/atom command"); memory->destroy(qlist); - memory->create(qlist,nqlist,"orientorder/atom:qlist"); + memory->create(qlist, nqlist, "orientorder/atom:qlist"); iarg += 2; - if (iarg+nqlist > narg) error->all(FLERR,"Illegal compute orientorder/atom command"); + if (iarg + nqlist > narg) error->all(FLERR, "Illegal compute orientorder/atom command"); qmax = 0; for (int il = 0; il < nqlist; il++) { - qlist[il] = utils::numeric(FLERR,arg[iarg+il],false,lmp); - if (qlist[il] < 0) error->all(FLERR,"Illegal compute orientorder/atom command"); + qlist[il] = utils::numeric(FLERR, arg[iarg + il], false, lmp); + if (qlist[il] < 0) error->all(FLERR, "Illegal compute orientorder/atom command"); if (qlist[il] > qmax) qmax = qlist[il]; } iarg += nqlist; - } else if (strcmp(arg[iarg],"wl") == 0) { - if (iarg+2 > narg) - error->all(FLERR,"Illegal compute orientorder/atom command"); - wlflag = utils::logical(FLERR,arg[iarg+1],false,lmp); + } else if (strcmp(arg[iarg], "wl") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute orientorder/atom command"); + wlflag = utils::logical(FLERR, arg[iarg + 1], false, lmp); iarg += 2; - } else if (strcmp(arg[iarg],"wl/hat") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute orientorder/atom command"); - wlhatflag = utils::logical(FLERR,arg[iarg+1],false,lmp); + } else if (strcmp(arg[iarg], "wl/hat") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute orientorder/atom command"); + wlhatflag = utils::logical(FLERR, arg[iarg + 1], false, lmp); iarg += 2; - } else if (strcmp(arg[iarg],"components") == 0) { + } else if (strcmp(arg[iarg], "components") == 0) { qlcompflag = 1; - if (iarg+2 > narg) error->all(FLERR,"Illegal compute orientorder/atom command"); - qlcomp = utils::numeric(FLERR,arg[iarg+1],false,lmp); + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute orientorder/atom command"); + qlcomp = utils::numeric(FLERR, arg[iarg + 1], false, lmp); iqlcomp = -1; for (int il = 0; il < nqlist; il++) if (qlcomp == qlist[il]) { iqlcomp = il; break; } - if (iqlcomp == -1) error->all(FLERR,"Illegal compute orientorder/atom command"); + if (iqlcomp == -1) error->all(FLERR, "Illegal compute orientorder/atom command"); iarg += 2; - } else if (strcmp(arg[iarg],"cutoff") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute orientorder/atom command"); - double cutoff = utils::numeric(FLERR,arg[iarg+1],false,lmp); - if (cutoff <= 0.0) error->all(FLERR,"Illegal compute orientorder/atom command"); - cutsq = cutoff*cutoff; + } else if (strcmp(arg[iarg], "cutoff") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute orientorder/atom command"); + double cutoff = utils::numeric(FLERR, arg[iarg + 1], false, lmp); + if (cutoff <= 0.0) error->all(FLERR, "Illegal compute orientorder/atom command"); + cutsq = cutoff * cutoff; iarg += 2; - } else if (strcmp(arg[iarg],"chunksize") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal compute orientorder/atom command"); - chunksize = utils::numeric(FLERR,arg[iarg+1],false,lmp); - if (chunksize <= 0) error->all(FLERR,"Illegal compute orientorder/atom command"); + } else if (strcmp(arg[iarg], "chunksize") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute orientorder/atom command"); + chunksize = utils::numeric(FLERR, arg[iarg + 1], false, lmp); + if (chunksize <= 0) error->all(FLERR, "Illegal compute orientorder/atom command"); iarg += 2; - } else error->all(FLERR,"Illegal compute orientorder/atom command"); + } else + error->all(FLERR, "Illegal compute orientorder/atom command"); } ncol = nqlist; if (wlflag) ncol += nqlist; if (wlhatflag) ncol += nqlist; - if (qlcompflag) ncol += 2*(2*qlcomp+1); + if (qlcompflag) ncol += 2 * (2 * qlcomp + 1); peratom_flag = 1; size_peratom_cols = ncol; @@ -174,32 +170,23 @@ ComputeOrientOrderAtom::~ComputeOrientOrderAtom() void ComputeOrientOrderAtom::init() { if (force->pair == nullptr) - error->all(FLERR,"Compute orientorder/atom requires a " - "pair style be defined"); - if (cutsq == 0.0) cutsq = force->pair->cutforce * force->pair->cutforce; + error->all(FLERR, "Compute orientorder/atom requires a pair style be defined"); + if (cutsq == 0.0) + cutsq = force->pair->cutforce * force->pair->cutforce; else if (sqrt(cutsq) > force->pair->cutforce) - error->all(FLERR,"Compute orientorder/atom cutoff is " - "longer than pairwise cutoff"); + error->all(FLERR, "Compute orientorder/atom cutoff is longer than pairwise cutoff"); memory->destroy(qnm_r); memory->destroy(qnm_i); - memory->create(qnm_r,nqlist,2*qmax+1,"orientorder/atom:qnm_r"); - memory->create(qnm_i,nqlist,2*qmax+1,"orientorder/atom:qnm_i"); + memory->create(qnm_r, nqlist, 2 * qmax + 1, "orientorder/atom:qnm_r"); + memory->create(qnm_i, nqlist, 2 * qmax + 1, "orientorder/atom:qnm_i"); // need an occasional full neighbor list - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; + neighbor->add_request(this, NeighConst::REQ_FULL | NeighConst::REQ_OCCASIONAL); - int count = 0; - for (int i = 0; i < modify->ncompute; i++) - if (strcmp(modify->compute[i]->style,"orientorder/atom") == 0) count++; - if (count > 1 && comm->me == 0) - error->warning(FLERR,"More than one compute orientorder/atom"); + if ((modify->get_compute_by_style("orientorder/atom").size() > 1) && (comm->me == 0)) + error->warning(FLERR, "More than one instance of compute orientorder/atom"); if (wlflag || wlhatflag) init_clebsch_gordan(); } @@ -215,9 +202,9 @@ void ComputeOrientOrderAtom::init_list(int /*id*/, NeighList *ptr) void ComputeOrientOrderAtom::compute_peratom() { - int i,j,ii,jj,inum,jnum; - double xtmp,ytmp,ztmp,delx,dely,delz,rsq; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum; + double xtmp, ytmp, ztmp, delx, dely, delz, rsq; + int *ilist, *jlist, *numneigh, **firstneigh; invoked_peratom = update->ntimestep; @@ -226,7 +213,7 @@ void ComputeOrientOrderAtom::compute_peratom() if (atom->nmax > nmax) { memory->destroy(qnarray); nmax = atom->nmax; - memory->create(qnarray,nmax,ncol,"orientorder/atom:qnarray"); + memory->create(qnarray, nmax, ncol, "orientorder/atom:qnarray"); array_atom = qnarray; } @@ -244,11 +231,11 @@ void ComputeOrientOrderAtom::compute_peratom() double **x = atom->x; int *mask = atom->mask; - memset(&qnarray[0][0],0,sizeof(double)*nmax*ncol); + memset(&qnarray[0][0], 0, sizeof(double) * nmax * ncol); for (ii = 0; ii < inum; ii++) { i = ilist[ii]; - double* qn = qnarray[i]; + double *qn = qnarray[i]; if (mask[i] & groupbit) { xtmp = x[i][0]; ytmp = x[i][1]; @@ -263,9 +250,9 @@ void ComputeOrientOrderAtom::compute_peratom() memory->destroy(rlist); memory->destroy(nearest); maxneigh = jnum; - memory->create(distsq,maxneigh,"orientorder/atom:distsq"); - memory->create(rlist,maxneigh,3,"orientorder/atom:rlist"); - memory->create(nearest,maxneigh,"orientorder/atom:nearest"); + memory->create(distsq, maxneigh, "orientorder/atom:distsq"); + memory->create(rlist, maxneigh, 3, "orientorder/atom:rlist"); + memory->create(nearest, maxneigh, "orientorder/atom:nearest"); } // loop over list of all neighbors within force cutoff @@ -281,7 +268,7 @@ void ComputeOrientOrderAtom::compute_peratom() delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cutsq) { distsq[ncount] = rsq; rlist[ncount][0] = delx; @@ -294,15 +281,14 @@ void ComputeOrientOrderAtom::compute_peratom() // if not nnn neighbors, order parameter = 0; if ((ncount == 0) || (ncount < nnn)) { - for (jj = 0; jj < ncol; jj++) - qn[jj] = 0.0; + for (jj = 0; jj < ncol; jj++) qn[jj] = 0.0; continue; } // if nnn > 0, use only nearest nnn neighbors if (nnn > 0) { - select3(nnn,ncount,distsq,nearest,rlist); + select3(nnn, ncount, distsq, nearest, rlist); ncount = nnn; } @@ -317,9 +303,9 @@ void ComputeOrientOrderAtom::compute_peratom() double ComputeOrientOrderAtom::memory_usage() { - double bytes = (double)ncol*nmax * sizeof(double); - bytes += (double)(qmax*(2*qmax+1)+maxneigh*4) * sizeof(double); - bytes += (double)(nqlist+maxneigh) * sizeof(int); + double bytes = (double) ncol * nmax * sizeof(double); + bytes += (double) (qmax * (2 * qmax + 1) + maxneigh * 4) * sizeof(double); + bytes += (double) (nqlist + maxneigh) * sizeof(int); return bytes; } @@ -331,26 +317,39 @@ double ComputeOrientOrderAtom::memory_usage() // Use no-op do while to create single statement -#define SWAP(a,b) do { \ - tmp = a; a = b; b = tmp; \ +#define SWAP(a, b) \ + do { \ + tmp = a; \ + a = b; \ + b = tmp; \ } while (0) -#define ISWAP(a,b) do { \ - itmp = a; a = b; b = itmp; \ +#define ISWAP(a, b) \ + do { \ + itmp = a; \ + a = b; \ + b = itmp; \ } while (0) -#define SWAP3(a,b) do { \ - tmp = a[0]; a[0] = b[0]; b[0] = tmp; \ - tmp = a[1]; a[1] = b[1]; b[1] = tmp; \ - tmp = a[2]; a[2] = b[2]; b[2] = tmp; \ +#define SWAP3(a, b) \ + do { \ + tmp = a[0]; \ + a[0] = b[0]; \ + b[0] = tmp; \ + tmp = a[1]; \ + a[1] = b[1]; \ + b[1] = tmp; \ + tmp = a[2]; \ + a[2] = b[2]; \ + b[2] = tmp; \ } while (0) /* ---------------------------------------------------------------------- */ void ComputeOrientOrderAtom::select3(int k, int n, double *arr, int *iarr, double **arr3) { - int i,ir,j,l,mid,ia,itmp; - double a,tmp,a3[3]; + int i, ir, j, l, mid, ia, itmp; + double a, tmp, a3[3]; arr--; iarr--; @@ -358,59 +357,61 @@ void ComputeOrientOrderAtom::select3(int k, int n, double *arr, int *iarr, doubl l = 1; ir = n; for (;;) { - if (ir <= l+1) { - if (ir == l+1 && arr[ir] < arr[l]) { - SWAP(arr[l],arr[ir]); - ISWAP(iarr[l],iarr[ir]); - SWAP3(arr3[l],arr3[ir]); + if (ir <= l + 1) { + if (ir == l + 1 && arr[ir] < arr[l]) { + SWAP(arr[l], arr[ir]); + ISWAP(iarr[l], iarr[ir]); + SWAP3(arr3[l], arr3[ir]); } return; } else { - mid=(l+ir) >> 1; - SWAP(arr[mid],arr[l+1]); - ISWAP(iarr[mid],iarr[l+1]); - SWAP3(arr3[mid],arr3[l+1]); + mid = (l + ir) >> 1; + SWAP(arr[mid], arr[l + 1]); + ISWAP(iarr[mid], iarr[l + 1]); + SWAP3(arr3[mid], arr3[l + 1]); if (arr[l] > arr[ir]) { - SWAP(arr[l],arr[ir]); - ISWAP(iarr[l],iarr[ir]); - SWAP3(arr3[l],arr3[ir]); + SWAP(arr[l], arr[ir]); + ISWAP(iarr[l], iarr[ir]); + SWAP3(arr3[l], arr3[ir]); } - if (arr[l+1] > arr[ir]) { - SWAP(arr[l+1],arr[ir]); - ISWAP(iarr[l+1],iarr[ir]); - SWAP3(arr3[l+1],arr3[ir]); + if (arr[l + 1] > arr[ir]) { + SWAP(arr[l + 1], arr[ir]); + ISWAP(iarr[l + 1], iarr[ir]); + SWAP3(arr3[l + 1], arr3[ir]); } - if (arr[l] > arr[l+1]) { - SWAP(arr[l],arr[l+1]); - ISWAP(iarr[l],iarr[l+1]); - SWAP3(arr3[l],arr3[l+1]); + if (arr[l] > arr[l + 1]) { + SWAP(arr[l], arr[l + 1]); + ISWAP(iarr[l], iarr[l + 1]); + SWAP3(arr3[l], arr3[l + 1]); } - i = l+1; + i = l + 1; j = ir; - a = arr[l+1]; - ia = iarr[l+1]; - a3[0] = arr3[l+1][0]; - a3[1] = arr3[l+1][1]; - a3[2] = arr3[l+1][2]; + a = arr[l + 1]; + ia = iarr[l + 1]; + a3[0] = arr3[l + 1][0]; + a3[1] = arr3[l + 1][1]; + a3[2] = arr3[l + 1][2]; for (;;) { - do i++; while (arr[i] < a); - do j--; while (arr[j] > a); + do i++; + while (arr[i] < a); + do j--; + while (arr[j] > a); if (j < i) break; - SWAP(arr[i],arr[j]); - ISWAP(iarr[i],iarr[j]); - SWAP3(arr3[i],arr3[j]); + SWAP(arr[i], arr[j]); + ISWAP(iarr[i], iarr[j]); + SWAP3(arr3[i], arr3[j]); } - arr[l+1] = arr[j]; + arr[l + 1] = arr[j]; arr[j] = a; - iarr[l+1] = iarr[j]; + iarr[l + 1] = iarr[j]; iarr[j] = ia; - arr3[l+1][0] = arr3[j][0]; - arr3[l+1][1] = arr3[j][1]; - arr3[l+1][2] = arr3[j][2]; + arr3[l + 1][0] = arr3[j][0]; + arr3[l + 1][1] = arr3[j][1]; + arr3[l + 1][2] = arr3[j][2]; arr3[j][0] = a3[0]; arr3[j][1] = a3[1]; arr3[j][2] = a3[2]; - if (j >= k) ir = j-1; + if (j >= k) ir = j - 1; if (j <= k) l = i; } } @@ -420,34 +421,32 @@ void ComputeOrientOrderAtom::select3(int k, int n, double *arr, int *iarr, doubl calculate the bond orientational order parameters ------------------------------------------------------------------------- */ -void ComputeOrientOrderAtom::calc_boop(double **rlist, - int ncount, double qn[], - int qlist[], int nqlist) { +void ComputeOrientOrderAtom::calc_boop(double **rlist, int ncount, double qn[], int qlist[], + int nqlist) +{ for (int il = 0; il < nqlist; il++) { int l = qlist[il]; - for (int m = 0; m < 2*l+1; m++) { + for (int m = 0; m < 2 * l + 1; m++) { qnm_r[il][m] = 0.0; qnm_i[il][m] = 0.0; } } for (int ineigh = 0; ineigh < ncount; ineigh++) { - const double * const r = rlist[ineigh]; - double rmag = dist(r); - if (rmag <= MY_EPSILON) { - return; - } + const double *const r = rlist[ineigh]; + double rmag = sqrt(r[0] * r[0] + r[1] * r[1] + r[2] * r[2]); + if (rmag <= MY_EPSILON) { return; } double costheta = r[2] / rmag; double expphi_r = r[0]; double expphi_i = r[1]; - double rxymag = sqrt(expphi_r*expphi_r+expphi_i*expphi_i); + double rxymag = sqrt(expphi_r * expphi_r + expphi_i * expphi_i); if (rxymag <= MY_EPSILON) { expphi_r = 1.0; expphi_i = 0.0; } else { - double rxymaginv = 1.0/rxymag; + double rxymaginv = 1.0 / rxymag; expphi_r *= rxymaginv; expphi_i *= rxymaginv; } @@ -467,21 +466,20 @@ void ComputeOrientOrderAtom::calc_boop(double **rlist, double prefactor = polar_prefactor(l, m, costheta); double ylm_r = prefactor * expphim_r; double ylm_i = prefactor * expphim_i; - qnm_r[il][m+l] += ylm_r; - qnm_i[il][m+l] += ylm_i; + qnm_r[il][m + l] += ylm_r; + qnm_i[il][m + l] += ylm_i; if (m & 1) { - qnm_r[il][-m+l] -= ylm_r; - qnm_i[il][-m+l] += ylm_i; + qnm_r[il][-m + l] -= ylm_r; + qnm_i[il][-m + l] += ylm_i; } else { - qnm_r[il][-m+l] += ylm_r; - qnm_i[il][-m+l] -= ylm_i; + qnm_r[il][-m + l] += ylm_r; + qnm_i[il][-m + l] -= ylm_i; } - double tmp_r = expphim_r*expphi_r - expphim_i*expphi_i; - double tmp_i = expphim_r*expphi_i + expphim_i*expphi_r; + double tmp_r = expphim_r * expphi_r - expphim_i * expphi_i; + double tmp_i = expphim_r * expphi_i + expphim_i * expphi_r; expphim_r = tmp_r; expphim_i = tmp_i; } - } } @@ -490,7 +488,7 @@ void ComputeOrientOrderAtom::calc_boop(double **rlist, double facn = 1.0 / ncount; for (int il = 0; il < nqlist; il++) { int l = qlist[il]; - for (int m = 0; m < 2*l+1; m++) { + for (int m = 0; m < 2 * l + 1; m++) { qnm_r[il][m] *= facn; qnm_i[il][m] *= facn; } @@ -502,10 +500,10 @@ void ComputeOrientOrderAtom::calc_boop(double **rlist, int jj = 0; for (int il = 0; il < nqlist; il++) { int l = qlist[il]; - double qnormfac = sqrt(MY_4PI/(2*l+1)); + double qnormfac = sqrt(MY_4PI / (2 * l + 1)); double qm_sum = 0.0; - for (int m = 0; m < 2*l+1; m++) - qm_sum += qnm_r[il][m]*qnm_r[il][m] + qnm_i[il][m]*qnm_i[il][m]; + for (int m = 0; m < 2 * l + 1; m++) + qm_sum += qnm_r[il][m] * qnm_r[il][m] + qnm_i[il][m] * qnm_i[il][m]; qn[jj++] = qnormfac * sqrt(qm_sum); } @@ -516,16 +514,16 @@ void ComputeOrientOrderAtom::calc_boop(double **rlist, for (int il = 0; il < nqlist; il++) { int l = qlist[il]; double wlsum = 0.0; - for (int m1 = 0; m1 < 2*l+1; m1++) { - for (int m2 = MAX(0,l-m1); m2 < MIN(2*l+1,3*l-m1+1); m2++) { + for (int m1 = 0; m1 < 2 * l + 1; m1++) { + for (int m2 = MAX(0, l - m1); m2 < MIN(2 * l + 1, 3 * l - m1 + 1); m2++) { int m = m1 + m2 - l; - double qm1qm2_r = qnm_r[il][m1]*qnm_r[il][m2] - qnm_i[il][m1]*qnm_i[il][m2]; - double qm1qm2_i = qnm_r[il][m1]*qnm_i[il][m2] + qnm_i[il][m1]*qnm_r[il][m2]; - wlsum += (qm1qm2_r*qnm_r[il][m] + qm1qm2_i*qnm_i[il][m])*cglist[idxcg_count]; + double qm1qm2_r = qnm_r[il][m1] * qnm_r[il][m2] - qnm_i[il][m1] * qnm_i[il][m2]; + double qm1qm2_i = qnm_r[il][m1] * qnm_i[il][m2] + qnm_i[il][m1] * qnm_r[il][m2]; + wlsum += (qm1qm2_r * qnm_r[il][m] + qm1qm2_i * qnm_i[il][m]) * cglist[idxcg_count]; idxcg_count++; } } - qn[jj++] = wlsum/sqrt(2*l+1); + qn[jj++] = wlsum / sqrt(2 * l + 1); } } @@ -536,21 +534,21 @@ void ComputeOrientOrderAtom::calc_boop(double **rlist, for (int il = 0; il < nqlist; il++) { int l = qlist[il]; double wlsum = 0.0; - for (int m1 = 0; m1 < 2*l+1; m1++) { - for (int m2 = MAX(0,l-m1); m2 < MIN(2*l+1,3*l-m1+1); m2++) { + for (int m1 = 0; m1 < 2 * l + 1; m1++) { + for (int m2 = MAX(0, l - m1); m2 < MIN(2 * l + 1, 3 * l - m1 + 1); m2++) { int m = m1 + m2 - l; - double qm1qm2_r = qnm_r[il][m1]*qnm_r[il][m2] - qnm_i[il][m1]*qnm_i[il][m2]; - double qm1qm2_i = qnm_r[il][m1]*qnm_i[il][m2] + qnm_i[il][m1]*qnm_r[il][m2]; - wlsum += (qm1qm2_r*qnm_r[il][m] + qm1qm2_i*qnm_i[il][m])*cglist[idxcg_count]; + double qm1qm2_r = qnm_r[il][m1] * qnm_r[il][m2] - qnm_i[il][m1] * qnm_i[il][m2]; + double qm1qm2_i = qnm_r[il][m1] * qnm_i[il][m2] + qnm_i[il][m1] * qnm_r[il][m2]; + wlsum += (qm1qm2_r * qnm_r[il][m] + qm1qm2_i * qnm_i[il][m]) * cglist[idxcg_count]; idxcg_count++; } } if (qn[il] < QEPSILON) qn[jj++] = 0.0; else { - double qnormfac = sqrt(MY_4PI/(2*l+1)); - double qnfac = qnormfac/qn[il]; - qn[jj++] = wlsum/sqrt(2*l+1)*(qnfac*qnfac*qnfac); + double qnormfac = sqrt(MY_4PI / (2 * l + 1)); + double qnfac = qnormfac / qn[il]; + qn[jj++] = wlsum / sqrt(2 * l + 1) * (qnfac * qnfac * qnfac); } } } @@ -561,29 +559,19 @@ void ComputeOrientOrderAtom::calc_boop(double **rlist, int il = iqlcomp; int l = qlcomp; if (qn[il] < QEPSILON) - for (int m = 0; m < 2*l+1; m++) { + for (int m = 0; m < 2 * l + 1; m++) { qn[jj++] = 0.0; qn[jj++] = 0.0; } else { - double qnormfac = sqrt(MY_4PI/(2*l+1)); - double qnfac = qnormfac/qn[il]; - for (int m = 0; m < 2*l+1; m++) { + double qnormfac = sqrt(MY_4PI / (2 * l + 1)); + double qnfac = qnormfac / qn[il]; + for (int m = 0; m < 2 * l + 1; m++) { qn[jj++] = qnm_r[il][m] * qnfac; qn[jj++] = qnm_i[il][m] * qnfac; } } } - -} - -/* ---------------------------------------------------------------------- - calculate scalar distance -------------------------------------------------------------------------- */ - -double ComputeOrientOrderAtom::dist(const double r[]) -{ - return sqrt(r[0]*r[0] + r[1]*r[1] + r[2]*r[2]); } /* ---------------------------------------------------------------------- @@ -596,11 +584,10 @@ double ComputeOrientOrderAtom::polar_prefactor(int l, int m, double costheta) const int mabs = abs(m); double prefactor = 1.0; - for (int i=l-mabs+1; i < l+mabs+1; ++i) - prefactor *= static_cast(i); + for (int i = l - mabs + 1; i < l + mabs + 1; ++i) prefactor *= static_cast(i); - prefactor = sqrt(static_cast(2*l+1)/(MY_4PI*prefactor)) - * associated_legendre(l,mabs,costheta); + prefactor = sqrt(static_cast(2 * l + 1) / (MY_4PI * prefactor)) * + associated_legendre(l, mabs, costheta); if ((m < 0) && (m % 2)) prefactor = -prefactor; @@ -619,16 +606,15 @@ double ComputeOrientOrderAtom::associated_legendre(int l, int m, double x) double p(1.0), pm1(0.0), pm2(0.0); if (m != 0) { - const double msqx = -sqrt(1.0-x*x); - for (int i=1; i < m+1; ++i) - p *= static_cast(2*i-1) * msqx; + const double msqx = -sqrt(1.0 - x * x); + for (int i = 1; i < m + 1; ++i) p *= static_cast(2 * i - 1) * msqx; } - for (int i=m+1; i < l+1; ++i) { + for (int i = m + 1; i < l + 1; ++i) { pm2 = pm1; pm1 = p; - p = (static_cast(2*i-1)*x*pm1 - - static_cast(i+m-1)*pm2) / static_cast(i-m); + p = (static_cast(2 * i - 1) * x * pm1 - static_cast(i + m - 1) * pm2) / + static_cast(i - m); } return p; @@ -642,16 +628,15 @@ double ComputeOrientOrderAtom::associated_legendre(int l, int m, double x) void ComputeOrientOrderAtom::init_clebsch_gordan() { - double sum,dcg,sfaccg, sfac1, sfac2; + double sum, dcg, sfaccg, sfac1, sfac2; int m, aa2, bb2, cc2; int ifac, idxcg_count; idxcg_count = 0; for (int il = 0; il < nqlist; il++) { int l = qlist[il]; - for (int m1 = 0; m1 < 2*l+1; m1++) - for (int m2 = MAX(0,l-m1); m2 < MIN(2*l+1,3*l-m1+1); m2++) - idxcg_count++; + for (int m1 = 0; m1 < 2 * l + 1; m1++) + for (int m2 = MAX(0, l - m1); m2 < MIN(2 * l + 1, 3 * l - m1 + 1); m2++) idxcg_count++; } idxcg_max = idxcg_count; memory->destroy(cglist); @@ -660,41 +645,44 @@ void ComputeOrientOrderAtom::init_clebsch_gordan() idxcg_count = 0; for (int il = 0; il < nqlist; il++) { int l = qlist[il]; - for (int m1 = 0; m1 < 2*l+1; m1++) { - aa2 = m1 - l; - for (int m2 = MAX(0,l-m1); m2 < MIN(2*l+1,3*l-m1+1); m2++) { - bb2 = m2 - l; - m = aa2 + bb2 + l; + for (int m1 = 0; m1 < 2 * l + 1; m1++) { + aa2 = m1 - l; + for (int m2 = MAX(0, l - m1); m2 < MIN(2 * l + 1, 3 * l - m1 + 1); m2++) { + bb2 = m2 - l; + m = aa2 + bb2 + l; - sum = 0.0; - for (int z = MAX(0, MAX(-aa2, bb2)); - z <= MIN(l, MIN(l - aa2, l + bb2)); z++) { - ifac = z % 2 ? -1 : 1; - sum += ifac / - (factorial(z) * - factorial(l - z) * - factorial(l - aa2 - z) * - factorial(l + bb2 - z) * - factorial(aa2 + z) * - factorial(-bb2 + z)); - } + // clang-format off - cc2 = m - l; - sfaccg = sqrt(factorial(l + aa2) * - factorial(l - aa2) * - factorial(l + bb2) * - factorial(l - bb2) * - factorial(l + cc2) * - factorial(l - cc2) * - (2*l + 1)); - - sfac1 = factorial(3*l + 1); - sfac2 = factorial(l); - dcg = sqrt(sfac2*sfac2*sfac2 / sfac1); - - cglist[idxcg_count] = sum * dcg * sfaccg; - idxcg_count++; + sum = 0.0; + for (int z = MAX(0, MAX(-aa2, bb2)); + z <= MIN(l, MIN(l - aa2, l + bb2)); z++) { + ifac = z % 2 ? -1 : 1; + sum += ifac / + (factorial(z) * + factorial(l - z) * + factorial(l - aa2 - z) * + factorial(l + bb2 - z) * + factorial(aa2 + z) * + factorial(-bb2 + z)); } + + cc2 = m - l; + sfaccg = sqrt(factorial(l + aa2) * + factorial(l - aa2) * + factorial(l + bb2) * + factorial(l - bb2) * + factorial(l + cc2) * + factorial(l - cc2) * + (2*l + 1)); + // clang-format on + + sfac1 = factorial(3 * l + 1); + sfac2 = factorial(l); + dcg = sqrt(sfac2 * sfac2 * sfac2 / sfac1); + + cglist[idxcg_count] = sum * dcg * sfaccg; + idxcg_count++; } + } } } diff --git a/src/compute_orientorder_atom.h b/src/compute_orientorder_atom.h index b88b01fbc9..c762c0e74b 100644 --- a/src/compute_orientorder_atom.h +++ b/src/compute_orientorder_atom.h @@ -50,7 +50,6 @@ class ComputeOrientOrderAtom : public Compute { void select3(int, int, double *, int *, double **); void calc_boop(double **rlist, int numNeighbors, double qn[], int nlist[], int nnlist); - double dist(const double r[]); double polar_prefactor(int, int, double); double associated_legendre(int, int, double); diff --git a/src/compute_pair_local.cpp b/src/compute_pair_local.cpp index 3dc37707c6..708b31c370 100644 --- a/src/compute_pair_local.cpp +++ b/src/compute_pair_local.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -31,16 +30,15 @@ using namespace LAMMPS_NS; #define DELTA 10000 -enum{DIST,ENG,FORCE,FX,FY,FZ,PN,DX,DY,DZ}; -enum{TYPE,RADIUS}; +enum { DIST, ENG, FORCE, FX, FY, FZ, PN, DX, DY, DZ }; +enum { TYPE, RADIUS }; /* ---------------------------------------------------------------------- */ ComputePairLocal::ComputePairLocal(LAMMPS *lmp, int narg, char **arg) : - Compute(lmp, narg, arg), - pstyle(nullptr), pindex(nullptr), vlocal(nullptr), alocal(nullptr) + Compute(lmp, narg, arg), pstyle(nullptr), pindex(nullptr), vlocal(nullptr), alocal(nullptr) { - if (narg < 4) error->all(FLERR,"Illegal compute pair/local command"); + if (narg < 4) error->all(FLERR, "Illegal compute pair/local command"); local_flag = 1; nvalues = narg - 3; @@ -50,23 +48,32 @@ ComputePairLocal::ComputePairLocal(LAMMPS *lmp, int narg, char **arg) : nvalues = 0; int iarg = 3; while (iarg < narg) { - if (strcmp(arg[iarg],"dist") == 0) pstyle[nvalues++] = DIST; - else if (strcmp(arg[iarg],"eng") == 0) pstyle[nvalues++] = ENG; - else if (strcmp(arg[iarg],"force") == 0) pstyle[nvalues++] = FORCE; - else if (strcmp(arg[iarg],"fx") == 0) pstyle[nvalues++] = FX; - else if (strcmp(arg[iarg],"fy") == 0) pstyle[nvalues++] = FY; - else if (strcmp(arg[iarg],"fz") == 0) pstyle[nvalues++] = FZ; - else if (strcmp(arg[iarg],"dx") == 0) pstyle[nvalues++] = DX; - else if (strcmp(arg[iarg],"dy") == 0) pstyle[nvalues++] = DY; - else if (strcmp(arg[iarg],"dz") == 0) pstyle[nvalues++] = DZ; + if (strcmp(arg[iarg], "dist") == 0) + pstyle[nvalues++] = DIST; + else if (strcmp(arg[iarg], "eng") == 0) + pstyle[nvalues++] = ENG; + else if (strcmp(arg[iarg], "force") == 0) + pstyle[nvalues++] = FORCE; + else if (strcmp(arg[iarg], "fx") == 0) + pstyle[nvalues++] = FX; + else if (strcmp(arg[iarg], "fy") == 0) + pstyle[nvalues++] = FY; + else if (strcmp(arg[iarg], "fz") == 0) + pstyle[nvalues++] = FZ; + else if (strcmp(arg[iarg], "dx") == 0) + pstyle[nvalues++] = DX; + else if (strcmp(arg[iarg], "dy") == 0) + pstyle[nvalues++] = DY; + else if (strcmp(arg[iarg], "dz") == 0) + pstyle[nvalues++] = DZ; else if (arg[iarg][0] == 'p') { int n = atoi(&arg[iarg][1]); - if (n <= 0) error->all(FLERR, - "Invalid keyword in compute pair/local command"); + if (n <= 0) error->all(FLERR, "Invalid keyword in compute pair/local command"); pstyle[nvalues] = PN; - pindex[nvalues++] = n-1; + pindex[nvalues++] = n - 1; - } else break; + } else + break; iarg++; } @@ -76,20 +83,23 @@ ComputePairLocal::ComputePairLocal(LAMMPS *lmp, int narg, char **arg) : cutstyle = TYPE; while (iarg < narg) { - if (strcmp(arg[iarg],"cutoff") == 0) { - if (iarg+2 > narg) - error->all(FLERR,"Illegal compute pair/local command"); - if (strcmp(arg[iarg+1],"type") == 0) cutstyle = TYPE; - else if (strcmp(arg[iarg+1],"radius") == 0) cutstyle = RADIUS; - else error->all(FLERR,"Illegal compute pair/local command"); + if (strcmp(arg[iarg], "cutoff") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal compute pair/local command"); + if (strcmp(arg[iarg + 1], "type") == 0) + cutstyle = TYPE; + else if (strcmp(arg[iarg + 1], "radius") == 0) + cutstyle = RADIUS; + else + error->all(FLERR, "Illegal compute pair/local command"); iarg += 2; - } else error->all(FLERR,"Illegal compute pair/local command"); + } else + error->all(FLERR, "Illegal compute pair/local command"); } // error check if (cutstyle == RADIUS && !atom->radius_flag) - error->all(FLERR,"Compute pair/local requires atom attribute radius"); + error->all(FLERR, "Compute pair/local requires atom attribute radius"); // set singleflag if need to call pair->single() @@ -97,8 +107,10 @@ ComputePairLocal::ComputePairLocal(LAMMPS *lmp, int narg, char **arg) : for (int i = 0; i < nvalues; i++) if (pstyle[i] != DIST && pstyle[i] != DX && pstyle[i] != DY && pstyle[i] != DZ) singleflag = 1; - if (nvalues == 1) size_local_cols = 0; - else size_local_cols = nvalues; + if (nvalues == 1) + size_local_cols = 0; + else + size_local_cols = nvalues; nmax = 0; vlocal = nullptr; @@ -111,8 +123,8 @@ ComputePairLocal::~ComputePairLocal() { memory->destroy(vlocal); memory->destroy(alocal); - delete [] pstyle; - delete [] pindex; + delete[] pstyle; + delete[] pindex; } /* ---------------------------------------------------------------------- */ @@ -120,25 +132,22 @@ ComputePairLocal::~ComputePairLocal() void ComputePairLocal::init() { if (singleflag && force->pair == nullptr) - error->all(FLERR,"No pair style is defined for compute pair/local"); + error->all(FLERR, "No pair style is defined for compute pair/local"); if (singleflag && force->pair->single_enable == 0) - error->all(FLERR,"Pair style does not support compute pair/local"); + error->all(FLERR, "Pair style does not support compute pair/local"); for (int i = 0; i < nvalues; i++) if (pstyle[i] == PN && pindex[i] >= force->pair->single_extra) - error->all(FLERR,"Pair style does not have extra field" - " requested by compute pair/local"); + error->all(FLERR, "Pair style does not have extra field requested by compute pair/local"); // need an occasional half neighbor list // set size to same value as request made by force->pair // this should enable it to always be a copy list (e.g. for granular pstyle) - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; - NeighRequest *pairrequest = neighbor->find_request((void *) force->pair); - if (pairrequest) neighbor->requests[irequest]->size = pairrequest->size; + int neighflags = NeighConst::REQ_OCCASIONAL; + auto pairrequest = neighbor->find_request(force->pair); + if (pairrequest && pairrequest->get_size()) neighflags |= NeighConst::REQ_SIZE; + neighbor->add_request(this, neighflags); } /* ---------------------------------------------------------------------- */ @@ -171,11 +180,11 @@ void ComputePairLocal::compute_local() int ComputePairLocal::compute_pairs(int flag) { - int i,j,m,n,ii,jj,inum,jnum,itype,jtype; - tagint itag,jtag; - double xtmp,ytmp,ztmp,delx,dely,delz; - double rsq,radsum,eng,fpair,factor_coul,factor_lj; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, m, n, ii, jj, inum, jnum, itype, jtype; + tagint itag, jtag; + double xtmp, ytmp, ztmp, delx, dely, delz; + double rsq, radsum, eng, fpair, factor_coul, factor_lj; + int *ilist, *jlist, *numneigh, **firstneigh; double *ptr; double **x = atom->x; @@ -234,9 +243,9 @@ int ComputePairLocal::compute_pairs(int flag) if (newton_pair == 0 && j >= nlocal) { if (itag > jtag) { - if ((itag+jtag) % 2 == 0) continue; + if ((itag + jtag) % 2 == 0) continue; } else if (itag < jtag) { - if ((itag+jtag) % 2 == 1) continue; + if ((itag + jtag) % 2 == 1) continue; } else { if (x[j][2] < ztmp) continue; if (x[j][2] == ztmp) { @@ -249,59 +258,62 @@ int ComputePairLocal::compute_pairs(int flag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (cutstyle == TYPE) { if (rsq >= cutsq[itype][jtype]) continue; } else { radsum = radius[i] + radius[j]; - if (rsq >= radsum*radsum) continue; + if (rsq >= radsum * radsum) continue; } if (flag) { if (singleflag) - eng = pair->single(i,j,itype,jtype,rsq,factor_coul,factor_lj,fpair); - else eng = fpair = 0.0; + eng = pair->single(i, j, itype, jtype, rsq, factor_coul, factor_lj, fpair); + else + eng = fpair = 0.0; - if (nvalues == 1) ptr = &vlocal[m]; - else ptr = alocal[m]; + if (nvalues == 1) + ptr = &vlocal[m]; + else + ptr = alocal[m]; // to make sure dx, dy and dz are always from the lower to the higher id double directionCorrection = itag > jtag ? -1.0 : 1.0; for (n = 0; n < nvalues; n++) { switch (pstyle[n]) { - case DIST: - ptr[n] = sqrt(rsq); - break; - case DX: - ptr[n] = delx*directionCorrection; - break; - case DY: - ptr[n] = dely*directionCorrection; - break; - case DZ: - ptr[n] = delz*directionCorrection; - break; - case ENG: - ptr[n] = eng; - break; - case FORCE: - ptr[n] = sqrt(rsq)*fpair; - break; - case FX: - ptr[n] = delx*fpair; - break; - case FY: - ptr[n] = dely*fpair; - break; - case FZ: - ptr[n] = delz*fpair; - break; - case PN: - ptr[n] = pair->svector[pindex[n]]; - break; + case DIST: + ptr[n] = sqrt(rsq); + break; + case DX: + ptr[n] = delx * directionCorrection; + break; + case DY: + ptr[n] = dely * directionCorrection; + break; + case DZ: + ptr[n] = delz * directionCorrection; + break; + case ENG: + ptr[n] = eng; + break; + case FORCE: + ptr[n] = sqrt(rsq) * fpair; + break; + case FX: + ptr[n] = delx * fpair; + break; + case FY: + ptr[n] = dely * fpair; + break; + case FZ: + ptr[n] = delz * fpair; + break; + case PN: + ptr[n] = pair->svector[pindex[n]]; + break; } } } @@ -323,11 +335,11 @@ void ComputePairLocal::reallocate(int n) if (nvalues == 1) { memory->destroy(vlocal); - memory->create(vlocal,nmax,"pair/local:vector_local"); + memory->create(vlocal, nmax, "pair/local:vector_local"); vector_local = vlocal; } else { memory->destroy(alocal); - memory->create(alocal,nmax,nvalues,"pair/local:array_local"); + memory->create(alocal, nmax, nvalues, "pair/local:array_local"); array_local = alocal; } } @@ -338,6 +350,6 @@ void ComputePairLocal::reallocate(int n) double ComputePairLocal::memory_usage() { - double bytes = (double)nmax*nvalues * sizeof(double); + double bytes = (double) nmax * nvalues * sizeof(double); return bytes; } diff --git a/src/compute_property_local.cpp b/src/compute_property_local.cpp index fce18fecd1..b00535d5ed 100644 --- a/src/compute_property_local.cpp +++ b/src/compute_property_local.cpp @@ -264,12 +264,10 @@ void ComputePropertyLocal::init() // this should enable it to always be a copy list (e.g. for granular pstyle) if (kindflag == NEIGH || kindflag == PAIR) { - int irequest = neighbor->request(this, instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; - NeighRequest *pairrequest = neighbor->find_request((void *) force->pair); - if (pairrequest) neighbor->requests[irequest]->size = pairrequest->size; + int neighflags = NeighConst::REQ_OCCASIONAL; + auto pairrequest = neighbor->find_request(force->pair); + if (pairrequest && pairrequest->get_size()) neighflags |= NeighConst::REQ_SIZE; + neighbor->add_request(this, neighflags); } // do initial memory allocation so that memory_usage() is correct diff --git a/src/compute_rdf.cpp b/src/compute_rdf.cpp index 59b456d40e..a5068b5acd 100644 --- a/src/compute_rdf.cpp +++ b/src/compute_rdf.cpp @@ -18,22 +18,22 @@ #include "compute_rdf.h" -#include -#include #include "atom.h" -#include "update.h" -#include "force.h" -#include "pair.h" +#include "comm.h" #include "domain.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "neigh_list.h" +#include "error.h" +#include "force.h" #include "group.h" #include "math_const.h" #include "memory.h" -#include "error.h" -#include "comm.h" +#include "neigh_list.h" +#include "neigh_request.h" +#include "neighbor.h" +#include "pair.h" +#include "update.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -204,14 +204,8 @@ void ComputeRDF::init() // (until next reneighbor), so it needs to contain atoms further // than cutoff_user apart, just like a normal neighbor list does - int irequest = neighbor->request(this,instance_me); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->compute = 1; - neighbor->requests[irequest]->occasional = 1; - if (cutflag) { - neighbor->requests[irequest]->cut = 1; - neighbor->requests[irequest]->cutoff = mycutneigh; - } + auto req = neighbor->add_request(this, NeighConst::REQ_OCCASIONAL); + if (cutflag) req->set_cutoff(mycutneigh); } /* ---------------------------------------------------------------------- */ diff --git a/src/compute_temp_deform.cpp b/src/compute_temp_deform.cpp index c7b8e14d9e..cd467c0069 100644 --- a/src/compute_temp_deform.cpp +++ b/src/compute_temp_deform.cpp @@ -63,8 +63,6 @@ ComputeTempDeform::~ComputeTempDeform() void ComputeTempDeform::init() { - int i; - // check fix deform remap settings auto fixes = modify->get_fix_by_style("^deform"); diff --git a/src/create_bonds.cpp b/src/create_bonds.cpp index ab3bba7041..7b3929db62 100644 --- a/src/create_bonds.cpp +++ b/src/create_bonds.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -35,7 +34,7 @@ using namespace LAMMPS_NS; -enum{MANY,SBOND,SANGLE,SDIHEDRAL,SIMPROPER}; +enum { MANY, SBOND, SANGLE, SDIHEDRAL, SIMPROPER }; /* ---------------------------------------------------------------------- */ @@ -46,118 +45,122 @@ CreateBonds::CreateBonds(LAMMPS *lmp) : Command(lmp) {} void CreateBonds::command(int narg, char **arg) { if (domain->box_exist == 0) - error->all(FLERR,"Create_bonds command before simulation box is defined"); - if (atom->tag_enable == 0) - error->all(FLERR,"Cannot use create_bonds unless atoms have IDs"); + error->all(FLERR, "Create_bonds command before simulation box is defined"); + if (atom->tag_enable == 0) error->all(FLERR, "Cannot use create_bonds unless atoms have IDs"); if (atom->molecular != Atom::MOLECULAR) - error->all(FLERR,"Cannot use create_bonds with non-molecular system"); + error->all(FLERR, "Cannot use create_bonds with non-molecular system"); - if (narg < 4) error->all(FLERR,"Illegal create_bonds command"); + if (narg < 4) error->all(FLERR, "Illegal create_bonds command"); // parse args int style; int iarg = 0; - if (strcmp(arg[0],"many") == 0) { + if (strcmp(arg[0], "many") == 0) { style = MANY; - if (narg != 6) error->all(FLERR,"Illegal create_bonds command"); + if (narg != 6) error->all(FLERR, "Illegal create_bonds command"); igroup = group->find(arg[1]); - if (igroup == -1) error->all(FLERR,"Cannot find create_bonds group ID"); + if (igroup == -1) error->all(FLERR, "Cannot find create_bonds group ID"); group1bit = group->bitmask[igroup]; igroup = group->find(arg[2]); - if (igroup == -1) error->all(FLERR,"Cannot find create_bonds group ID"); + if (igroup == -1) error->all(FLERR, "Cannot find create_bonds group ID"); group2bit = group->bitmask[igroup]; - btype = utils::inumeric(FLERR,arg[3],false,lmp); - rmin = utils::numeric(FLERR,arg[4],false,lmp); - rmax = utils::numeric(FLERR,arg[5],false,lmp); - if (rmin > rmax) error->all(FLERR,"Illegal create_bonds command"); + btype = utils::inumeric(FLERR, arg[3], false, lmp); + rmin = utils::numeric(FLERR, arg[4], false, lmp); + rmax = utils::numeric(FLERR, arg[5], false, lmp); + if (rmin > rmax) error->all(FLERR, "Illegal create_bonds command"); iarg = 6; - } else if (strcmp(arg[0],"single/bond") == 0) { + } else if (strcmp(arg[0], "single/bond") == 0) { style = SBOND; - if (narg < 4) error->all(FLERR,"Illegal create_bonds command"); - btype = utils::inumeric(FLERR,arg[1],false,lmp); - batom1 = utils::tnumeric(FLERR,arg[2],false,lmp); - batom2 = utils::tnumeric(FLERR,arg[3],false,lmp); - if (batom1 == batom2) - error->all(FLERR,"Illegal create_bonds command"); + if (narg < 4) error->all(FLERR, "Illegal create_bonds command"); + btype = utils::inumeric(FLERR, arg[1], false, lmp); + batom1 = utils::tnumeric(FLERR, arg[2], false, lmp); + batom2 = utils::tnumeric(FLERR, arg[3], false, lmp); + if (batom1 == batom2) error->all(FLERR, "Illegal create_bonds command"); iarg = 4; - } else if (strcmp(arg[0],"single/angle") == 0) { + } else if (strcmp(arg[0], "single/angle") == 0) { style = SANGLE; - if (narg < 5) error->all(FLERR,"Illegal create_bonds command"); - atype = utils::inumeric(FLERR,arg[1],false,lmp); - aatom1 = utils::tnumeric(FLERR,arg[2],false,lmp); - aatom2 = utils::tnumeric(FLERR,arg[3],false,lmp); - aatom3 = utils::tnumeric(FLERR,arg[4],false,lmp); + if (narg < 5) error->all(FLERR, "Illegal create_bonds command"); + atype = utils::inumeric(FLERR, arg[1], false, lmp); + aatom1 = utils::tnumeric(FLERR, arg[2], false, lmp); + aatom2 = utils::tnumeric(FLERR, arg[3], false, lmp); + aatom3 = utils::tnumeric(FLERR, arg[4], false, lmp); if ((aatom1 == aatom2) || (aatom1 == aatom3) || (aatom2 == aatom3)) - error->all(FLERR,"Illegal create_bonds command"); + error->all(FLERR, "Illegal create_bonds command"); iarg = 5; - } else if (strcmp(arg[0],"single/dihedral") == 0) { + } else if (strcmp(arg[0], "single/dihedral") == 0) { style = SDIHEDRAL; - if (narg < 6) error->all(FLERR,"Illegal create_bonds command"); - dtype = utils::inumeric(FLERR,arg[1],false,lmp); - datom1 = utils::tnumeric(FLERR,arg[2],false,lmp); - datom2 = utils::tnumeric(FLERR,arg[3],false,lmp); - datom3 = utils::tnumeric(FLERR,arg[4],false,lmp); - datom4 = utils::tnumeric(FLERR,arg[5],false,lmp); - if ((datom1 == datom2) || (datom1 == datom3) || (datom1 == datom4) || - (datom2 == datom3) || (datom2 == datom4) || (datom3 == datom4)) - error->all(FLERR,"Illegal create_bonds command"); + if (narg < 6) error->all(FLERR, "Illegal create_bonds command"); + dtype = utils::inumeric(FLERR, arg[1], false, lmp); + datom1 = utils::tnumeric(FLERR, arg[2], false, lmp); + datom2 = utils::tnumeric(FLERR, arg[3], false, lmp); + datom3 = utils::tnumeric(FLERR, arg[4], false, lmp); + datom4 = utils::tnumeric(FLERR, arg[5], false, lmp); + if ((datom1 == datom2) || (datom1 == datom3) || (datom1 == datom4) || (datom2 == datom3) || + (datom2 == datom4) || (datom3 == datom4)) + error->all(FLERR, "Illegal create_bonds command"); iarg = 6; - } else if (strcmp(arg[0],"single/improper") == 0) { + } else if (strcmp(arg[0], "single/improper") == 0) { style = SIMPROPER; - if (narg < 6) error->all(FLERR,"Illegal create_bonds command"); - dtype = utils::inumeric(FLERR,arg[1],false,lmp); - datom1 = utils::tnumeric(FLERR,arg[2],false,lmp); - datom2 = utils::tnumeric(FLERR,arg[3],false,lmp); - datom3 = utils::tnumeric(FLERR,arg[4],false,lmp); - datom4 = utils::tnumeric(FLERR,arg[5],false,lmp); - if ((datom1 == datom2) || (datom1 == datom3) || (datom1 == datom4) || - (datom2 == datom3) || (datom2 == datom4) || (datom3 == datom4)) - error->all(FLERR,"Illegal create_bonds command"); + if (narg < 6) error->all(FLERR, "Illegal create_bonds command"); + dtype = utils::inumeric(FLERR, arg[1], false, lmp); + datom1 = utils::tnumeric(FLERR, arg[2], false, lmp); + datom2 = utils::tnumeric(FLERR, arg[3], false, lmp); + datom3 = utils::tnumeric(FLERR, arg[4], false, lmp); + datom4 = utils::tnumeric(FLERR, arg[5], false, lmp); + if ((datom1 == datom2) || (datom1 == datom3) || (datom1 == datom4) || (datom2 == datom3) || + (datom2 == datom4) || (datom3 == datom4)) + error->all(FLERR, "Illegal create_bonds command"); iarg = 6; - } else error->all(FLERR,"Illegal create_bonds command"); + } else + error->all(FLERR, "Illegal create_bonds command"); // optional args int specialflag = 1; while (iarg < narg) { - if (strcmp(arg[iarg],"special") == 0) { - if (iarg+2 > narg) error->all(FLERR,"Illegal create_bonds command"); - specialflag = utils::logical(FLERR,arg[iarg+1],false,lmp); + if (strcmp(arg[iarg], "special") == 0) { + if (iarg + 2 > narg) error->all(FLERR, "Illegal create_bonds command"); + specialflag = utils::logical(FLERR, arg[iarg + 1], false, lmp); iarg += 2; - } else error->all(FLERR,"Illegal create_bonds command"); + } else + error->all(FLERR, "Illegal create_bonds command"); } // error checks if (style == MANY) { if (btype <= 0 || btype > atom->nbondtypes) - error->all(FLERR,"Invalid bond type in create_bonds command"); - if (specialflag == 0) - error->all(FLERR,"Cannot use special no with create_bonds many"); + error->all(FLERR, "Invalid bond type in create_bonds command"); + if (specialflag == 0) error->all(FLERR, "Cannot use special no with create_bonds many"); } else if (style == SBOND) { if (btype <= 0 || btype > atom->nbondtypes) - error->all(FLERR,"Invalid bond type in create_bonds command"); + error->all(FLERR, "Invalid bond type in create_bonds command"); } else if (style == SANGLE) { if (atype <= 0 || atype > atom->nangletypes) - error->all(FLERR,"Invalid angle type in create_bonds command"); + error->all(FLERR, "Invalid angle type in create_bonds command"); } else if (style == SDIHEDRAL) { if (dtype <= 0 || dtype > atom->ndihedraltypes) - error->all(FLERR,"Invalid dihedral type in create_bonds command"); + error->all(FLERR, "Invalid dihedral type in create_bonds command"); } else if (style == SIMPROPER) { if (dtype <= 0 || dtype > atom->nimpropertypes) - error->all(FLERR,"Invalid improper type in create_bonds command"); + error->all(FLERR, "Invalid improper type in create_bonds command"); } // invoke creation method - if (style == MANY) many(); - else if (style == SBOND) single_bond(); - else if (style == SANGLE) single_angle(); - else if (style == SDIHEDRAL) single_dihedral(); - else if (style == SIMPROPER) single_improper(); + if (style == MANY) + many(); + else if (style == SBOND) + single_bond(); + else if (style == SANGLE) + single_angle(); + else if (style == SDIHEDRAL) + single_dihedral(); + else if (style == SIMPROPER) + single_improper(); // trigger special list build @@ -171,8 +174,8 @@ void CreateBonds::command(int narg, char **arg) void CreateBonds::many() { - double rminsq = rmin*rmin; - double rmaxsq = rmax*rmax; + double rminsq = rmin * rmin; + double rmaxsq = rmax * rmax; // store state before bond creation @@ -180,13 +183,7 @@ void CreateBonds::many() // request a full neighbor list for use by this command - int irequest = neighbor->request(this); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->command = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; - neighbor->requests[irequest]->command_style = "create_bonds"; + neighbor->add_request(this, "create_bonds", NeighConst::REQ_FULL); // init entire system since comm->borders and neighbor->build is done // comm::init needs neighbor::init needs pair::init needs kspace::init, etc @@ -196,12 +193,11 @@ void CreateBonds::many() // error check on cutoff // if no pair style, neighbor list will be empty - if (force->pair == nullptr) - error->all(FLERR,"Create_bonds requires a pair style be defined"); + if (force->pair == nullptr) error->all(FLERR, "Create_bonds requires a pair style be defined"); if (rmax > neighbor->cutneighmax) - error->all(FLERR,"Create_bonds max distance > neighbor cutoff"); + error->all(FLERR, "Create_bonds max distance > neighbor cutoff"); if (rmax > neighbor->cutneighmin && comm->me == 0) - error->warning(FLERR,"Create_bonds max distance > minimum neighbor cutoff"); + error->warning(FLERR, "Create_bonds max distance > minimum neighbor cutoff"); // require special_bonds 1-2 weights = 0.0 and KSpace = nullptr // so that already bonded atom pairs do not appear in neighbor list @@ -210,11 +206,8 @@ void CreateBonds::many() // note that with KSpace, pair with weight = 0 could still be in neigh list if (force->special_lj[1] != 0.0 || force->special_coul[1] != 0.0) - error->all(FLERR,"Create_bonds command requires " - "special_bonds 1-2 weights be 0.0"); - if (force->kspace) - error->all(FLERR,"Create_bonds command requires " - "no kspace_style be defined"); + error->all(FLERR, "Create_bonds command requires special_bonds 1-2 weights be 0.0"); + if (force->kspace) error->all(FLERR, "Create_bonds command requires no kspace_style be defined"); // setup domain, communication and neighboring // acquire ghosts and build standard neighbor lists @@ -226,13 +219,13 @@ void CreateBonds::many() if (neighbor->style) neighbor->setup_bins(); comm->exchange(); comm->borders(); - if (domain->triclinic) domain->lamda2x(atom->nlocal+atom->nghost); + if (domain->triclinic) domain->lamda2x(atom->nlocal + atom->nghost); neighbor->build(1); // build neighbor list this command needs based on earlier request - NeighList *list = neighbor->lists[irequest]; - neighbor->build_one(list,1); + auto list = neighbor->find_list(this); + neighbor->build_one(list, 1); // loop over all neighs of each atom // compute distance between two atoms consistently on both procs @@ -248,9 +241,9 @@ void CreateBonds::many() double newton_bond = force->newton_bond; int nlocal = atom->nlocal; - int i,j,ii,jj,inum,jnum,flag; - double xtmp,ytmp,ztmp,delx,dely,delz,rsq; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, flag; + double xtmp, ytmp, ztmp, delx, dely, delz, rsq; + int *ilist, *jlist, *numneigh, **firstneigh; inum = list->inum; ilist = list->ilist; @@ -281,8 +274,9 @@ void CreateBonds::many() delx = x[j][0] - xtmp; dely = x[j][1] - ytmp; delz = x[j][2] - ztmp; - } else continue; - rsq = delx*delx + dely*dely + delz*delz; + } else + continue; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < rminsq || rsq > rmaxsq) continue; // only consider bond creation if igroup and jgroup match I,J atoms @@ -297,8 +291,8 @@ void CreateBonds::many() if (!newton_bond || tag[i] < tag[j]) { if (num_bond[i] == atom->bond_per_atom) - error->one(FLERR,"New bond exceeded bonds per atom limit " - " of {} in create_bonds",atom->bond_per_atom); + error->one(FLERR, "New bond exceeded bonds per atom limit of {} in create_bonds", + atom->bond_per_atom); bond_type[i][num_bond[i]] = btype; bond_atom[i][num_bond[i]] = tag[j]; num_bond[i]++; @@ -311,7 +305,7 @@ void CreateBonds::many() bigint nbonds = 0; for (i = 0; i < nlocal; i++) nbonds += num_bond[i]; - MPI_Allreduce(&nbonds,&atom->nbonds,1,MPI_LMP_BIGINT,MPI_SUM,world); + MPI_Allreduce(&nbonds, &atom->nbonds, 1, MPI_LMP_BIGINT, MPI_SUM, world); if (!force->newton_bond) atom->nbonds /= 2; // print new bond count @@ -319,8 +313,7 @@ void CreateBonds::many() bigint nadd_bonds = atom->nbonds - nbonds_previous; if (comm->me == 0) - utils::logmesg(lmp,"Added {} bonds, new total = {}\n", - nadd_bonds,atom->nbonds); + utils::logmesg(lmp, "Added {} bonds, new total = {}\n", nadd_bonds, atom->nbonds); } /* ---------------------------------------------------------------------- */ @@ -340,9 +333,8 @@ void CreateBonds::single_bond() if ((idx2 >= 0) && (idx2 < nlocal)) count++; int allcount; - MPI_Allreduce(&count,&allcount,1,MPI_INT,MPI_SUM,world); - if (allcount != 2) - error->all(FLERR,"Create_bonds single/bond atoms do not exist"); + MPI_Allreduce(&count, &allcount, 1, MPI_INT, MPI_SUM, world); + if (allcount != 2) error->all(FLERR, "Create_bonds single/bond atoms do not exist"); // create bond once or 2x if newton_bond set @@ -352,7 +344,7 @@ void CreateBonds::single_bond() if ((m = idx1) >= 0) { if (num_bond[m] == atom->bond_per_atom) - error->one(FLERR,"New bond exceeded bonds per atom in create_bonds"); + error->one(FLERR, "New bond exceeded bonds per atom in create_bonds"); bond_type[m][num_bond[m]] = btype; bond_atom[m][num_bond[m]] = batom2; num_bond[m]++; @@ -363,7 +355,7 @@ void CreateBonds::single_bond() if ((m = idx2) >= 0) { if (num_bond[m] == atom->bond_per_atom) - error->one(FLERR,"New bond exceeded bonds per atom in create_bonds"); + error->one(FLERR, "New bond exceeded bonds per atom in create_bonds"); bond_type[m][num_bond[m]] = btype; bond_atom[m][num_bond[m]] = batom1; num_bond[m]++; @@ -389,9 +381,8 @@ void CreateBonds::single_angle() if ((idx3 >= 0) && (idx3 < nlocal)) count++; int allcount; - MPI_Allreduce(&count,&allcount,1,MPI_INT,MPI_SUM,world); - if (allcount != 3) - error->all(FLERR,"Create_bonds single/angle atoms do not exist"); + MPI_Allreduce(&count, &allcount, 1, MPI_INT, MPI_SUM, world); + if (allcount != 3) error->all(FLERR, "Create_bonds single/angle atoms do not exist"); // create angle once or 3x if newton_bond set @@ -403,7 +394,7 @@ void CreateBonds::single_angle() if ((m = idx2) >= 0) { if (num_angle[m] == atom->angle_per_atom) - error->one(FLERR,"New angle exceeded angles per atom in create_bonds"); + error->one(FLERR, "New angle exceeded angles per atom in create_bonds"); angle_type[m][num_angle[m]] = atype; angle_atom1[m][num_angle[m]] = aatom1; angle_atom2[m][num_angle[m]] = aatom2; @@ -416,7 +407,7 @@ void CreateBonds::single_angle() if ((m = idx1) >= 0) { if (num_angle[m] == atom->angle_per_atom) - error->one(FLERR,"New angle exceeded angles per atom in create_bonds"); + error->one(FLERR, "New angle exceeded angles per atom in create_bonds"); angle_type[m][num_angle[m]] = atype; angle_atom1[m][num_angle[m]] = aatom1; angle_atom2[m][num_angle[m]] = aatom2; @@ -426,7 +417,7 @@ void CreateBonds::single_angle() if ((m = idx3) >= 0) { if (num_angle[m] == atom->angle_per_atom) - error->one(FLERR,"New angle exceeded angles per atom in create_bonds"); + error->one(FLERR, "New angle exceeded angles per atom in create_bonds"); angle_type[m][num_angle[m]] = atype; angle_atom1[m][num_angle[m]] = aatom1; angle_atom2[m][num_angle[m]] = aatom2; @@ -456,9 +447,8 @@ void CreateBonds::single_dihedral() if ((idx4 >= 0) && (idx4 < nlocal)) count++; int allcount; - MPI_Allreduce(&count,&allcount,1,MPI_INT,MPI_SUM,world); - if (allcount != 4) - error->all(FLERR,"Create_bonds single/dihedral atoms do not exist"); + MPI_Allreduce(&count, &allcount, 1, MPI_INT, MPI_SUM, world); + if (allcount != 4) error->all(FLERR, "Create_bonds single/dihedral atoms do not exist"); // create bond once or 4x if newton_bond set @@ -471,8 +461,7 @@ void CreateBonds::single_dihedral() if ((m = idx2) >= 0) { if (num_dihedral[m] == atom->dihedral_per_atom) - error->one(FLERR, - "New dihedral exceeded dihedrals per atom in create_bonds"); + error->one(FLERR, "New dihedral exceeded dihedrals per atom in create_bonds"); dihedral_type[m][num_dihedral[m]] = dtype; dihedral_atom1[m][num_dihedral[m]] = datom1; dihedral_atom2[m][num_dihedral[m]] = datom2; @@ -486,8 +475,7 @@ void CreateBonds::single_dihedral() if ((m = idx1) >= 0) { if (num_dihedral[m] == atom->dihedral_per_atom) - error->one(FLERR, - "New dihedral exceeded dihedrals per atom in create_bonds"); + error->one(FLERR, "New dihedral exceeded dihedrals per atom in create_bonds"); dihedral_type[m][num_dihedral[m]] = dtype; dihedral_atom1[m][num_dihedral[m]] = datom1; dihedral_atom2[m][num_dihedral[m]] = datom2; @@ -498,8 +486,7 @@ void CreateBonds::single_dihedral() if ((m = idx3) >= 0) { if (num_dihedral[m] == atom->dihedral_per_atom) - error->one(FLERR, - "New dihedral exceeded dihedrals per atom in create_bonds"); + error->one(FLERR, "New dihedral exceeded dihedrals per atom in create_bonds"); dihedral_type[m][num_dihedral[m]] = dtype; dihedral_atom1[m][num_dihedral[m]] = datom1; dihedral_atom2[m][num_dihedral[m]] = datom2; @@ -510,8 +497,7 @@ void CreateBonds::single_dihedral() if ((m = idx4) >= 0) { if (num_dihedral[m] == atom->dihedral_per_atom) - error->one(FLERR, - "New dihedral exceeded dihedrals per atom in create_bonds"); + error->one(FLERR, "New dihedral exceeded dihedrals per atom in create_bonds"); dihedral_type[m][num_dihedral[m]] = dtype; dihedral_atom1[m][num_dihedral[m]] = datom1; dihedral_atom2[m][num_dihedral[m]] = datom2; @@ -542,9 +528,8 @@ void CreateBonds::single_improper() if ((idx4 >= 0) && (idx4 < nlocal)) count++; int allcount; - MPI_Allreduce(&count,&allcount,1,MPI_INT,MPI_SUM,world); - if (allcount != 4) - error->all(FLERR,"Create_bonds single/improper atoms do not exist"); + MPI_Allreduce(&count, &allcount, 1, MPI_INT, MPI_SUM, world); + if (allcount != 4) error->all(FLERR, "Create_bonds single/improper atoms do not exist"); // create bond once or 4x if newton_bond set @@ -557,8 +542,7 @@ void CreateBonds::single_improper() if ((m = idx2) >= 0) { if (num_improper[m] == atom->improper_per_atom) - error->one(FLERR, - "New improper exceeded impropers per atom in create_bonds"); + error->one(FLERR, "New improper exceeded impropers per atom in create_bonds"); improper_type[m][num_improper[m]] = dtype; improper_atom1[m][num_improper[m]] = datom1; improper_atom2[m][num_improper[m]] = datom2; @@ -572,8 +556,7 @@ void CreateBonds::single_improper() if ((m = idx1) >= 0) { if (num_improper[m] == atom->improper_per_atom) - error->one(FLERR, - "New improper exceeded impropers per atom in create_bonds"); + error->one(FLERR, "New improper exceeded impropers per atom in create_bonds"); improper_type[m][num_improper[m]] = dtype; improper_atom1[m][num_improper[m]] = datom1; improper_atom2[m][num_improper[m]] = datom2; @@ -584,8 +567,7 @@ void CreateBonds::single_improper() if ((m = idx3) >= 0) { if (num_improper[m] == atom->improper_per_atom) - error->one(FLERR, - "New improper exceeded impropers per atom in create_bonds"); + error->one(FLERR, "New improper exceeded impropers per atom in create_bonds"); improper_type[m][num_improper[m]] = dtype; improper_atom1[m][num_improper[m]] = datom1; improper_atom2[m][num_improper[m]] = datom2; @@ -596,8 +578,7 @@ void CreateBonds::single_improper() if ((m = idx4) >= 0) { if (num_improper[m] == atom->improper_per_atom) - error->one(FLERR, - "New improper exceeded impropers per atom in create_bonds"); + error->one(FLERR, "New improper exceeded impropers per atom in create_bonds"); improper_type[m][num_improper[m]] = dtype; improper_atom1[m][num_improper[m]] = datom1; improper_atom2[m][num_improper[m]] = datom2; diff --git a/src/delete_atoms.cpp b/src/delete_atoms.cpp index 5e06fc22f3..11d3523cd0 100644 --- a/src/delete_atoms.cpp +++ b/src/delete_atoms.cpp @@ -29,7 +29,6 @@ #include "modify.h" #include "molecule.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "random_mars.h" #include "region.h" @@ -284,13 +283,7 @@ void DeleteAtoms::delete_overlap(int narg, char **arg) // request a full neighbor list for use by this command - int irequest = neighbor->request(this); - neighbor->requests[irequest]->pair = 0; - neighbor->requests[irequest]->command = 1; - neighbor->requests[irequest]->half = 0; - neighbor->requests[irequest]->full = 1; - neighbor->requests[irequest]->occasional = 1; - neighbor->requests[irequest]->command_style = "delete_atoms"; + neighbor->add_request(this, "delete_atoms", NeighConst::REQ_FULL); // init entire system since comm->borders and neighbor->build is done // comm::init needs neighbor::init needs pair::init needs kspace::init, etc @@ -320,9 +313,9 @@ void DeleteAtoms::delete_overlap(int narg, char **arg) if (domain->triclinic) domain->lamda2x(atom->nlocal+atom->nghost); neighbor->build(1); - // build neighbor list this command needs based on earlier request + // build neighbor list this command needs based on the earlier request - NeighList *list = neighbor->lists[irequest]; + auto list = neighbor->find_list(this); neighbor->build_one(list); // allocate and initialize deletion list diff --git a/src/dump_local.cpp b/src/dump_local.cpp index 8ed1f62fe2..67586c625a 100644 --- a/src/dump_local.cpp +++ b/src/dump_local.cpp @@ -435,7 +435,6 @@ void DumpLocal::parse_fields(int narg, char **arg) vtype[iarg] = Dump::INT; } else { - int n; ArgInfo argi(arg[iarg],ArgInfo::COMPUTE|ArgInfo::FIX); computefixflag = 1; vtype[iarg] = Dump::DOUBLE; diff --git a/src/finish.cpp b/src/finish.cpp index 35be03dca7..cc0cad7f92 100644 --- a/src/finish.cpp +++ b/src/finish.cpp @@ -63,7 +63,7 @@ Finish::Finish(LAMMPS *lmp) : Pointers(lmp) {} void Finish::end(int flag) { - int i,m,nneigh,nneighfull; + int i,nneigh,nneighfull; int histo[10]; int minflag,prdflag,tadflag,hyperflag; int timeflag,fftflag,histoflag,neighflag; @@ -436,6 +436,7 @@ void Finish::end(int flag) time3d,fraction,flop3,flop1); } + nneigh = nneighfull = 0; if (histoflag) { std::string mesg = "\n"; tmp = atom->nlocal; @@ -456,27 +457,8 @@ void Finish::end(int flag) mesg += "\n"; } - // find a non-skip neighbor list containing half pairwise interactions - // count neighbors in that list for stats purposes - // allow it to be Kokkos neigh list as well - - for (m = 0; m < neighbor->old_nrequest; m++) - if (neighbor->old_requests[m]->half && - neighbor->old_requests[m]->skip == 0 && - neighbor->lists[m] && neighbor->lists[m]->numneigh) break; - - nneigh = 0; - if (m < neighbor->old_nrequest) { - if (!neighbor->lists[m]->kokkos) { - int inum = neighbor->lists[m]->inum; - int *ilist = neighbor->lists[m]->ilist; - int *numneigh = neighbor->lists[m]->numneigh; - for (i = 0; i < inum; i++) - nneigh += numneigh[ilist[i]]; - } else if (lmp->kokkos) nneigh = lmp->kokkos->neigh_count(m); - } - - tmp = nneigh; + tmp = nneigh = neighbor->get_nneigh_half(); + if (tmp < 0.0) tmp = 0.0; stats(1,&tmp,&ave,&max,&min,10,histo); if (me == 0) { mesg += fmt::format("Neighs: {:11.6} ave {:11.6g} max {:11.6g} min\n",ave,max,min); @@ -485,33 +467,14 @@ void Finish::end(int flag) mesg += "\n"; } - // find a non-skip neighbor list containing full pairwise interactions - // count neighbors in that list for stats purposes - // allow it to be Kokkos neigh list as well - - for (m = 0; m < neighbor->old_nrequest; m++) - if (neighbor->old_requests[m]->full && - neighbor->old_requests[m]->skip == 0) break; - - nneighfull = 0; - if (m < neighbor->old_nrequest) { - if (!neighbor->lists[m]->kokkos && neighbor->lists[m]->numneigh) { - int inum = neighbor->lists[m]->inum; - int *ilist = neighbor->lists[m]->ilist; - int *numneigh = neighbor->lists[m]->numneigh; - for (i = 0; i < inum; i++) - nneighfull += numneigh[ilist[i]]; - } else if (lmp->kokkos) - nneighfull = lmp->kokkos->neigh_count(m); - - tmp = nneighfull; + tmp = nneighfull = neighbor->get_nneigh_full(); + if (tmp >= 0.0) { stats(1,&tmp,&ave,&max,&min,10,histo); if (me == 0) { mesg += fmt::format("FullNghs: {:11.6} ave {:11.6g} max {:11.6g} min\n",ave,max,min); mesg += "Histogram:"; for (i = 0; i < 10; i++) mesg += fmt::format(" {}",histo[i]); mesg += "\n"; - } } if (me == 0) utils::logmesg(lmp,mesg); @@ -571,9 +534,7 @@ void Finish::end(int flag) /* ---------------------------------------------------------------------- */ -void Finish::stats(int n, double *data, - double *pave, double *pmax, double *pmin, - int nhisto, int *histo) +void Finish::stats(int n, double *data, double *pave, double *pmax, double *pmin, int nhisto, int *histo) { int i,m; int *histotmp; diff --git a/src/fix.h b/src/fix.h index a83b032172..34ef32207d 100644 --- a/src/fix.h +++ b/src/fix.h @@ -19,6 +19,8 @@ namespace LAMMPS_NS { class Fix : protected Pointers { + friend class Neighbor; + public: static int instance_total; // # of Fix classes ever instantiated diff --git a/src/imbalance_neigh.cpp b/src/imbalance_neigh.cpp index 0a1c2a87cc..8b5dace4d2 100644 --- a/src/imbalance_neigh.cpp +++ b/src/imbalance_neigh.cpp @@ -46,8 +46,6 @@ int ImbalanceNeigh::options(int narg, char **arg) void ImbalanceNeigh::compute(double *weight) { - int req; - if (factor == 0.0) return; // cannot use neighbor list weight with KOKKOS using GPUs @@ -61,19 +59,12 @@ void ImbalanceNeigh::compute(double *weight) } } - // find suitable neighbor list - // can only use certain conventional neighbor lists - // NOTE: why not full list, if half does not exist? + bigint neighsum = neighbor->get_nneigh_half(); + if (neighsum < 0) neighsum = neighbor->get_nneigh_full(); - for (req = 0; req < neighbor->old_nrequest; ++req) { - if (neighbor->old_requests[req]->half && neighbor->old_requests[req]->skip == 0 && - neighbor->lists[req] && neighbor->lists[req]->numneigh) - break; - } - - if (req >= neighbor->old_nrequest || neighbor->ago < 0) { + if ((neighsum < 0) || (neighbor->ago < 0)) { if (comm->me == 0 && !did_warn) - error->warning(FLERR, "Balance weight neigh skipped b/c no list found"); + error->warning(FLERR, "Balance weight neigh skipped b/c no suitable list found"); did_warn = 1; return; } @@ -81,18 +72,11 @@ void ImbalanceNeigh::compute(double *weight) // neighsum = total neigh count for atoms on this proc // localwt = weight assigned to each owned atom - NeighList *list = neighbor->lists[req]; - const int inum = list->inum; - const int *const ilist = list->ilist; - const int *const numneigh = list->numneigh; - int nlocal = atom->nlocal; - - bigint neighsum = 0; - for (int i = 0; i < inum; ++i) neighsum += numneigh[ilist[i]]; double localwt = 0.0; + const int nlocal = atom->nlocal; if (nlocal) localwt = 1.0 * neighsum / nlocal; - if (nlocal && localwt <= 0.0) error->one(FLERR, "Balance weight <= 0.0"); + if (nlocal && localwt < 0.0) error->one(FLERR, "Balance weight < 0.0"); // apply factor if specified != 1.0 // wtlo,wthi = lo/hi values excluding 0.0 due to no atoms on this proc diff --git a/src/neigh_request.cpp b/src/neigh_request.cpp index 96ec568469..9d4adfbd96 100644 --- a/src/neigh_request.cpp +++ b/src/neigh_request.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -13,14 +12,17 @@ ------------------------------------------------------------------------- */ #include "neigh_request.h" + #include "atom.h" #include "memory.h" +#include "neighbor.h" using namespace LAMMPS_NS; +using namespace NeighConst; /* ---------------------------------------------------------------------- */ -NeighRequest::NeighRequest(LAMMPS *lmp) : Pointers(lmp) +NeighRequest::NeighRequest(LAMMPS *_lmp) : Pointers(_lmp) { // default ID = 0 @@ -96,9 +98,25 @@ NeighRequest::NeighRequest(LAMMPS *lmp) : Pointers(lmp) /* ---------------------------------------------------------------------- */ +NeighRequest::NeighRequest(LAMMPS *_lmp, int idx, void *ptr, int num) : NeighRequest(_lmp) +{ + index = idx; + requestor = ptr; + requestor_instance = num; +} + +/* ---------------------------------------------------------------------- */ + +NeighRequest::NeighRequest(NeighRequest *old) : NeighRequest(old->lmp) +{ + copy_request(old, 1); +} + +/* ---------------------------------------------------------------------- */ + NeighRequest::~NeighRequest() { - delete [] iskip; + delete[] iskip; memory->destroy(ijskip); } @@ -165,15 +183,13 @@ int NeighRequest::identical(NeighRequest *other) int NeighRequest::same_skip(NeighRequest *other) { - int i,j; - - int ntypes = atom->ntypes; + const int ntypes = atom->ntypes; int same = 1; - for (i = 1; i <= ntypes; i++) + for (int i = 1; i <= ntypes; i++) if (iskip[i] != other->iskip[i]) same = 0; - for (i = 1; i <= ntypes; i++) - for (j = 1; j <= ntypes; j++) + for (int i = 1; i <= ntypes; i++) + for (int j = 1; j <= ntypes; j++) if (ijskip[i][j] != other->ijskip[i][j]) same = 0; return same; @@ -206,7 +222,7 @@ void NeighRequest::copy_request(NeighRequest *other, int skipflag) size = other->size; history = other->history; granonesided = other->granonesided; - respainner = other->respainner; + respainner = other->respainner; respamiddle = other->respamiddle; respaouter = other->respaouter; bond = other->bond; @@ -223,22 +239,81 @@ void NeighRequest::copy_request(NeighRequest *other, int skipflag) if (!skipflag) return; - int i,j; - int ntypes = atom->ntypes; + int i, j; + int ntp1 = atom->ntypes + 1; skip = other->skip; if (other->iskip) { - iskip = new int[ntypes+1]; - for (i = 1; i <= ntypes; i++) - iskip[i] = other->iskip[i]; + iskip = new int[ntp1]; + for (i = 1; i < ntp1; i++) iskip[i] = other->iskip[i]; } if (other->ijskip) { - memory->create(ijskip,ntypes+1,ntypes+1,"neigh_request:ijskip"); - for (i = 1; i <= ntypes; i++) - for (j = 1; j <= ntypes; j++) - ijskip[i][j] = other->ijskip[i][j]; + memory->create(ijskip, ntp1, ntp1, "neigh_request:ijskip"); + for (i = 1; i < ntp1; i++) + for (j = 1; j < ntp1; j++) ijskip[i][j] = other->ijskip[i][j]; } } +/* ---------------------------------------------------------------------- */ + +void NeighRequest::apply_flags(int flags) +{ + if (flags & REQ_FULL) { + half = 0; + full = 1; + } + // clang-format off + if (flags & REQ_GHOST) { ghost = 1; } + if (flags & REQ_SIZE) { size = 1; } + if (flags & REQ_HISTORY) { history = 1; } + if (flags & REQ_NEWTON_ON) { newton = 1; } + if (flags & REQ_NEWTON_OFF) { newton = 2; } + if (flags & REQ_OCCASIONAL) { occasional = 1; } + if (flags & REQ_RESPA_INOUT) { respainner = respaouter = 1; } + if (flags & REQ_RESPA_ALL) { respainner = respamiddle = respaouter = 1; } + if (flags & REQ_SSA) { ssa = 1; } + // clang-format on +} + +/* ---------------------------------------------------------------------- */ + +void NeighRequest::set_cutoff(double _cutoff) +{ + cut = 1; + cutoff = _cutoff; +} + +void NeighRequest::set_id(int _id) +{ + id = _id; +} + +void NeighRequest::set_kokkos_device(int flag) +{ + kokkos_device = flag; +} + +void NeighRequest::set_kokkos_host(int flag) +{ + kokkos_host = flag; +} + +void NeighRequest::set_skip(int *_iskip, int **_ijskip) +{ + skip = 1; + iskip = _iskip; + ijskip = _ijskip; +} + +void NeighRequest::enable_full() +{ + half = 0; + full = 1; +} + +void NeighRequest::enable_ghost() +{ + ghost = 1; +} diff --git a/src/neigh_request.h b/src/neigh_request.h index ff86cfa7fe..c8c2277acc 100644 --- a/src/neigh_request.h +++ b/src/neigh_request.h @@ -19,7 +19,15 @@ namespace LAMMPS_NS { class NeighRequest : protected Pointers { - public: + friend class Neighbor; + friend class NBin; + friend class NeighList; + friend class NPair; + friend class NStencil; + friend class NeighborKokkos; + friend class NPairSkipIntel; + friend class FixIntel; + protected: int index; // index of which neigh request this is void *requestor; // class that made request int requestor_instance; // instance of that class (only Fix, Compute, Pair) @@ -110,13 +118,28 @@ class NeighRequest : protected Pointers { int index_pair; // index of NPair class assigned to this request // methods - + public: NeighRequest(class LAMMPS *); + NeighRequest(class LAMMPS *, int, void *, int); + NeighRequest(NeighRequest *); ~NeighRequest() override; + void archive(); int identical(NeighRequest *); int same_skip(NeighRequest *); void copy_request(NeighRequest *, int); + + void apply_flags(int); + void set_cutoff(double); + void set_id(int); + void set_kokkos_device(int); + void set_kokkos_host(int); + void set_skip(int *, int **); + void enable_full(); + void enable_ghost(); + + int get_size() const { return size; } + void *get_requestor() const { return requestor; } }; } // namespace LAMMPS_NS diff --git a/src/neighbor.cpp b/src/neighbor.cpp index 489d76eaed..98c773915b 100644 --- a/src/neighbor.cpp +++ b/src/neighbor.cpp @@ -19,6 +19,7 @@ #include "neighbor.h" +#include "accelerator_kokkos.h" #include "atom.h" #include "atom_vec.h" #include "citeme.h" @@ -45,6 +46,7 @@ #include "style_npair.h" // IWYU pragma: keep #include "style_nstencil.h" // IWYU pragma: keep #include "style_ntopo.h" // IWYU pragma: keep +#include "suffix.h" #include "tokenizer.h" #include "update.h" @@ -228,21 +230,21 @@ Neighbor::~Neighbor() memory->destroy(cutneighsq); memory->destroy(cutneighghostsq); - delete [] cuttype; - delete [] cuttypesq; - delete [] fixchecklist; + delete[] cuttype; + delete[] cuttypesq; + delete[] fixchecklist; for (int i = 0; i < nlist; i++) delete lists[i]; for (int i = 0; i < nbin; i++) delete neigh_bin[i]; for (int i = 0; i < nstencil; i++) delete neigh_stencil[i]; for (int i = 0; i < nlist; i++) delete neigh_pair[i]; - delete [] lists; - delete [] neigh_bin; - delete [] neigh_stencil; - delete [] neigh_pair; + delete[] lists; + delete[] neigh_bin; + delete[] neigh_stencil; + delete[] neigh_pair; - delete [] slist; - delete [] plist; + delete[] slist; + delete[] plist; for (int i = 0; i < nrequest; i++) if (requests[i]) delete requests[i]; @@ -251,15 +253,15 @@ Neighbor::~Neighbor() if (old_requests[i]) delete old_requests[i]; memory->sfree(old_requests); - delete [] binclass; - delete [] binnames; - delete [] binmasks; - delete [] stencilclass; - delete [] stencilnames; - delete [] stencilmasks; - delete [] pairclass; - delete [] pairnames; - delete [] pairmasks; + delete[] binclass; + delete[] binnames; + delete[] binmasks; + delete[] stencilclass; + delete[] stencilnames; + delete[] stencilmasks; + delete[] pairclass; + delete[] pairnames; + delete[] pairmasks; delete neigh_bond; delete neigh_angle; @@ -274,11 +276,11 @@ Neighbor::~Neighbor() memory->destroy(ex1_group); memory->destroy(ex2_group); - delete [] ex1_bit; - delete [] ex2_bit; + delete[] ex1_bit; + delete[] ex2_bit; memory->destroy(ex_mol_group); - delete [] ex_mol_bit; + delete[] ex_mol_bit; memory->destroy(ex_mol_intra); memory->destroy(type2collection); @@ -484,7 +486,7 @@ void Neighbor::init() restart_check = 0; if (output->restart_flag) restart_check = 1; - delete [] fixchecklist; + delete[] fixchecklist; fixchecklist = nullptr; fixchecklist = new int[modify->nfix]; @@ -607,8 +609,8 @@ void Neighbor::init() if (lmp->kokkos) init_ex_bit_kokkos(); else { - delete [] ex1_bit; - delete [] ex2_bit; + delete[] ex1_bit; + delete[] ex2_bit; ex1_bit = new int[nex_group]; ex2_bit = new int[nex_group]; } @@ -623,7 +625,7 @@ void Neighbor::init() if (lmp->kokkos) init_ex_mol_bit_kokkos(); else { - delete [] ex_mol_bit; + delete[] ex_mol_bit; ex_mol_bit = new int[nex_mol]; } @@ -801,10 +803,10 @@ int Neighbor::init_pair() for (i = 0; i < nbin; i++) delete neigh_bin[i]; for (i = 0; i < nstencil; i++) delete neigh_stencil[i]; for (i = 0; i < nlist; i++) delete neigh_pair[i]; - delete [] lists; - delete [] neigh_bin; - delete [] neigh_stencil; - delete [] neigh_pair; + delete[] lists; + delete[] neigh_bin; + delete[] neigh_stencil; + delete[] neigh_pair; // error check on requests // do not allow occasional, ghost, bin list @@ -1026,8 +1028,8 @@ int Neighbor::init_pair() // slist = indices of perpetual NStencil classes // perpetual = used by any perpetual NPair class - delete [] slist; - delete [] plist; + delete[] slist; + delete[] plist; nstencil_perpetual = npair_perpetual = 0; slist = new int[nstencil]; plist = new int[nlist]; @@ -1090,8 +1092,8 @@ int Neighbor::init_pair() } /* ---------------------------------------------------------------------- - scan NeighRequests to set additional flags - only for custom cutoff lists + scan NeighRequests to set additional flags: + custom cutoff lists and accelerator lists ------------------------------------------------------------------------- */ void Neighbor::morph_unique() @@ -1105,6 +1107,14 @@ void Neighbor::morph_unique() // this forces Pair,Stencil,Bin styles to be instantiated separately if (irq->cut) irq->unique = 1; + + // avoid flagging a neighbor list as both INTEL and OPENMP + + if (irq->intel) irq->omp = 0; + + // avoid flagging a neighbor list as both KOKKOS and INTEL or OPENMP + + if (irq->kokkos_host || irq->kokkos_device) irq->omp = irq->intel = 0; } } @@ -1715,13 +1725,10 @@ void Neighbor::requests_new2old() old_nrequest = nrequest; old_requests = (NeighRequest **) - memory->smalloc(old_nrequest*sizeof(NeighRequest *), - "neighbor:old_requests"); + memory->smalloc(old_nrequest*sizeof(NeighRequest *),"neighbor:old_requests"); - for (int i = 0; i < old_nrequest; i++) { - old_requests[i] = new NeighRequest(lmp); - old_requests[i]->copy_request(requests[i],1); - } + for (int i = 0; i < old_nrequest; i++) + old_requests[i] = new NeighRequest(requests[i]); old_style = style; old_triclinic = triclinic; @@ -1731,10 +1738,11 @@ void Neighbor::requests_new2old() /* ---------------------------------------------------------------------- find and return request made by classptr - if not found or classpt = nullptr, return nullptr + if not found or classptr = nullptr, return nullptr + TODO: should have optional argument "id" to match ID if multiple requests ------------------------------------------------------------------------- */ -NeighRequest *Neighbor::find_request(void *classptr) +NeighRequest *Neighbor::find_request(void *classptr) const { if (classptr == nullptr) return nullptr; @@ -1744,6 +1752,34 @@ NeighRequest *Neighbor::find_request(void *classptr) return nullptr; } +/* ---------------------------------------------------------------------- + return vector with neighbor list requests from pair styles +------------------------------------------------------------------------- */ + +const std::vector Neighbor::get_pair_requests() const +{ + std::vector matches; + for (int i=0; i < nrequest; ++i) + if (requests[i]->pair) matches.push_back(requests[i]); + return matches; +} + +/* ---------------------------------------------------------------------- + find and return list requested by classptr + if not found or classptr = nullptr, return nullptr + TODO: should have optional argument "id" to match ID if multiple requests +------------------------------------------------------------------------- */ + +NeighList *Neighbor::find_list(void *classptr) const +{ + if (classptr == nullptr) return nullptr; + + for (int i = 0; i < nlist; i++) + if (lists[i]->requestor == classptr) return lists[i]; + + return nullptr; +} + /* ---------------------------------------------------------------------- assign NBin class to a NeighList use neigh request settings to build mask @@ -2024,18 +2060,81 @@ int Neighbor::request(void *requestor, int instance) if (nrequest == maxrequest) { maxrequest += RQDELTA; requests = (NeighRequest **) - memory->srealloc(requests,maxrequest*sizeof(NeighRequest *), - "neighbor:requests"); + memory->srealloc(requests,maxrequest*sizeof(NeighRequest *), "neighbor:requests"); } - requests[nrequest] = new NeighRequest(lmp); - requests[nrequest]->index = nrequest; - requests[nrequest]->requestor = requestor; - requests[nrequest]->requestor_instance = instance; + requests[nrequest] = new NeighRequest(lmp, nrequest, requestor, instance); nrequest++; return nrequest-1; } +/* ---------------------------------------------------------------------- + called by other classes to request a pairwise neighbor list +------------------------------------------------------------------------- */ + +NeighRequest *Neighbor::add_request(Pair *requestor, int flags) +{ + int irequest = request(requestor, requestor->instance_me); + auto req = requests[irequest]; + req->apply_flags(flags); + // apply intel flag. omp flag is set globally via set_omp_neighbor() + if (requestor->suffix_flag & Suffix::INTEL) { + req->intel = 1; + req->omp = 0; + } + return req; +} + +NeighRequest *Neighbor::add_request(Fix *requestor, int flags) +{ + int irequest = request(requestor, requestor->instance_me); + auto req = requests[irequest]; + req->pair = 0; + req->fix = 1; + req->apply_flags(flags); + return req; +} + +NeighRequest *Neighbor::add_request(Compute *requestor, int flags) +{ + int irequest = request(requestor, requestor->instance_me); + auto req = requests[irequest]; + req->pair = 0; + req->compute = 1; + req->apply_flags(flags); + return req; +} + +NeighRequest *Neighbor::add_request(Command *requestor, const char *style, int flags) +{ + int irequest = request(requestor, 0); + auto req = requests[irequest]; + req->pair = 0; + req->command = 1; + req->occasional = 1; + req->command_style = style; + req->apply_flags(flags); + return req; +} + +// set neighbor list request OpenMP flag + +void Neighbor::set_omp_neighbor(int flag) +{ + // flag *all* neighbor list requests as OPENMP threaded, + // but skip lists already flagged as INTEL threaded + for (int i = 0; i < nrequest; ++i) + if (!requests[i]->intel) requests[i]->omp = flag; +} + +/* report if there is a neighbor list with the intel flag set */ + +bool Neighbor::has_intel_request() const +{ + return (((nrequest > 0) && (requests[0]->intel > 0)) + || ((old_nrequest > 0) && (old_requests[0]->intel > 0))); +} + /* ---------------------------------------------------------------------- setup neighbor binning and neighbor stencils called before run and every reneighbor if box size/shape changes @@ -2275,13 +2374,11 @@ void Neighbor::build_one(class NeighList *mylist, int preflag) // check if list structure is initialized if (mylist == nullptr) - error->all(FLERR,"Trying to build an occasional neighbor list " - "before initialization completed"); + error->all(FLERR,"Trying to build an occasional neighbor list before initialization complete"); // build_one() should never be invoked on a perpetual list - if (!mylist->occasional) - error->all(FLERR,"Neighbor build one invoked on perpetual list"); + if (!mylist->occasional) error->all(FLERR,"Neighbor::build_one() invoked on perpetual list"); // no need to build if already built since last re-neighbor // preflag is set by fix bond/create and fix bond/swap @@ -2676,6 +2773,59 @@ void Neighbor::build_collection(int istart) } } + +/* ---------------------------------------------------------------------- + for neighbor list statistics in Finish class +------------------------------------------------------------------------- */ + +bigint Neighbor::get_nneigh_full() +{ + // find a non-skip neighbor list containing full pairwise interactions + // count neighbors in that list for stats purposes + // allow it to be Kokkos neigh list as well + + int m; + for (m = 0; m < old_nrequest; m++) + if (old_requests[m]->full && !old_requests[m]->skip) break; + + bigint nneighfull = -1; + if (m < old_nrequest) { + nneighfull = 0; + if (!lists[m]->kokkos && lists[m]->numneigh) { + int inum = neighbor->lists[m]->inum; + int *ilist = neighbor->lists[m]->ilist; + int *numneigh = neighbor->lists[m]->numneigh; + for (int i = 0; i < inum; i++) + nneighfull += numneigh[ilist[i]]; + } else if (lmp->kokkos) nneighfull = lmp->kokkos->neigh_count(m); + } + return nneighfull; +} + +bigint Neighbor::get_nneigh_half() +{ + // find a non-skip neighbor list containing half pairwise interactions + // count neighbors in that list for stats purposes + // allow it to be Kokkos neigh list as well + + int m; + for (m = 0; m < old_nrequest; m++) + if (old_requests[m]->half && !old_requests[m]->skip && lists[m] && lists[m]->numneigh) break; + + bigint nneighhalf = -1; + if (m < old_nrequest) { + nneighhalf = 0; + if (!lists[m]->kokkos) { + int inum = neighbor->lists[m]->inum; + int *ilist = neighbor->lists[m]->ilist; + int *numneigh = neighbor->lists[m]->numneigh; + for (int i = 0; i < inum; i++) + nneighhalf += numneigh[ilist[i]]; + } else if (lmp->kokkos) nneighhalf = lmp->kokkos->neigh_count(m); + } + return nneighhalf; +} + /* ---------------------------------------------------------------------- return # of bytes of allocated memory ------------------------------------------------------------------------- */ diff --git a/src/neighbor.h b/src/neighbor.h index 45468c0c9b..2feafe1bce 100644 --- a/src/neighbor.h +++ b/src/neighbor.h @@ -18,6 +18,10 @@ namespace LAMMPS_NS { +// forward declarations +class NeighRequest; +class NeighList; + class Neighbor : protected Pointers { public: enum { NSQ, BIN, MULTI_OLD, MULTI }; @@ -87,9 +91,9 @@ class Neighbor : protected Pointers { int nrequest; // # of requests, same as nlist int old_nrequest; // # of requests for previous run - class NeighList **lists; - class NeighRequest **requests; // from Pair,Fix,Compute,Command classes - class NeighRequest **old_requests; // copy of requests to compare to + NeighList **lists; + NeighRequest **requests; // from Pair,Fix,Compute,Command classes + NeighRequest **old_requests; // copy of requests to compare to // data from topology neighbor lists @@ -119,14 +123,29 @@ class Neighbor : protected Pointers { Neighbor(class LAMMPS *); ~Neighbor() override; virtual void init(); + + // old API for creating neighbor list requests int request(void *, int instance = 0); + + // new API for creating neighbor list requests + NeighRequest *add_request(class Pair *, int flags = 0); + NeighRequest *add_request(class Fix *, int flags = 0); + NeighRequest *add_request(class Compute *, int flags = 0); + NeighRequest *add_request(class Command *, const char *, int flags = 0); + + // set neighbor list request OpenMP flag + void set_omp_neighbor(int); + + // report if we have INTEL package neighbor lists + bool has_intel_request() const; + int decide(); // decide whether to build or not virtual int check_distance(); // check max distance moved since last build void setup_bins(); // setup bins based on box and cutoff virtual void build(int); // build all perpetual neighbor lists virtual void build_topology(); // pairwise topology neighbor lists - void build_one(class NeighList *list, int preflag = 0); // create a one-time pairwise neigh list + void build_one(class NeighList *list, int preflag = 0); void set(int, char **); // set neighbor style and skin distance void reset_timestep(bigint); // reset of timestep counter void modify_params(int, char **); // modify params that control builds @@ -134,10 +153,14 @@ class Neighbor : protected Pointers { void exclusion_group_group_delete(int, int); // rm a group-group exclusion int exclude_setting(); // return exclude value to accelerator pkg - class NeighRequest *find_request(void *); // find a neighbor request + NeighList *find_list(void *) const; // find a neighbor list based on requestor + NeighRequest *find_request(void *) const; // find a neighbor request based on requestor + const std::vector get_pair_requests() const; int any_full(); // Check if any old requests had full neighbor lists void build_collection(int); // build peratom collection array starting at the given index + bigint get_nneigh_full(); // return number of neighbors in a regular full neighbor list + bigint get_nneigh_half(); // return number of neighbors in a regular half neighbor list double memory_usage(); bigint last_setup_bins; // step of last neighbor::setup_bins() call @@ -246,6 +269,7 @@ class Neighbor : protected Pointers { }; namespace NeighConst { + enum { NB_INTEL = 1 << 0, NB_KOKKOS_DEVICE = 1 << 1, @@ -297,6 +321,20 @@ namespace NeighConst { NP_OFF2ON = 1 << 24, NP_MULTI_OLD = 1 << 25 }; + + enum { + REQ_DEFAULT = 0, + REQ_FULL = 1 << 0, + REQ_GHOST = 1 << 1, + REQ_SIZE = 1 << 2, + REQ_HISTORY = 1 << 3, + REQ_OCCASIONAL = 1 << 4, + REQ_RESPA_INOUT = 1 << 5, + REQ_RESPA_ALL = 1 << 6, + REQ_NEWTON_ON = 1 << 8, + REQ_NEWTON_OFF = 1 << 9, + REQ_SSA = 1 << 10, + }; } // namespace NeighConst } // namespace LAMMPS_NS diff --git a/src/pair.cpp b/src/pair.cpp index f88c4e0972..aee89db49e 100644 --- a/src/pair.cpp +++ b/src/pair.cpp @@ -326,7 +326,7 @@ void Pair::reinit() void Pair::init_style() { - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- diff --git a/src/pair.h b/src/pair.h index a61af0c1da..f4aa82a586 100644 --- a/src/pair.h +++ b/src/pair.h @@ -33,6 +33,7 @@ class Pair : protected Pointers { friend class PairHybridScaled; friend class ThrOMP; friend class Info; + friend class Neighbor; public: static int instance_total; // # of Pair classes ever instantiated diff --git a/src/pair_buck_coul_cut.cpp b/src/pair_buck_coul_cut.cpp index 95cec11eff..7926b01c91 100644 --- a/src/pair_buck_coul_cut.cpp +++ b/src/pair_buck_coul_cut.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -68,13 +67,13 @@ PairBuckCoulCut::~PairBuckCoulCut() void PairBuckCoulCut::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,r,rexp,forcecoul,forcebuck,factor_coul,factor_lj; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, r, rexp, forcecoul, forcebuck, factor_coul, factor_lj; + int *ilist, *jlist, *numneigh, **firstneigh; evdwl = ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -112,47 +111,49 @@ void PairBuckCoulCut::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; r = sqrt(rsq); if (rsq < cut_coulsq[itype][jtype]) - forcecoul = qqrd2e * qtmp*q[j]/r; - else forcecoul = 0.0; + forcecoul = qqrd2e * qtmp * q[j] / r; + else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - rexp = exp(-r*rhoinv[itype][jtype]); - forcebuck = buck1[itype][jtype]*r*rexp - buck2[itype][jtype]*r6inv; - } else forcebuck = 0.0; + r6inv = r2inv * r2inv * r2inv; + rexp = exp(-r * rhoinv[itype][jtype]); + forcebuck = buck1[itype][jtype] * r * rexp - buck2[itype][jtype] * r6inv; + } else + forcebuck = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forcebuck) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forcebuck) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (newton_pair || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } if (eflag) { if (rsq < cut_coulsq[itype][jtype]) - ecoul = factor_coul * qqrd2e * qtmp*q[j]/r; - else ecoul = 0.0; + ecoul = factor_coul * qqrd2e * qtmp * q[j] / r; + else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = a[itype][jtype]*rexp - c[itype][jtype]*r6inv - - offset[itype][jtype]; + evdwl = a[itype][jtype] * rexp - c[itype][jtype] * r6inv - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally(i,j,nlocal,newton_pair, - evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally(i, j, nlocal, newton_pair, evdwl, ecoul, fpair, delx, dely, delz); } } } @@ -167,27 +168,26 @@ void PairBuckCoulCut::compute(int eflag, int vflag) void PairBuckCoulCut::allocate() { allocated = 1; - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); + memory->create(setflag, np1, np1, "pair:setflag"); - for (int i = 1; i <= n; i++) - for (int j = i; j <= n; j++) - setflag[i][j] = 0; + for (int i = 1; i < np1; i++) + for (int j = i; j < np1; j++) setflag[i][j] = 0; - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, np1, np1, "pair:cutsq"); - memory->create(cut_lj,n+1,n+1,"pair:cut_lj"); - memory->create(cut_ljsq,n+1,n+1,"pair:cut_ljsq"); - memory->create(cut_coul,n+1,n+1,"pair:cut_coul"); - memory->create(cut_coulsq,n+1,n+1,"pair:cut_coulsq"); - memory->create(a,n+1,n+1,"pair:a"); - memory->create(rho,n+1,n+1,"pair:rho"); - memory->create(c,n+1,n+1,"pair:c"); - memory->create(rhoinv,n+1,n+1,"pair:rhoinv"); - memory->create(buck1,n+1,n+1,"pair:buck1"); - memory->create(buck2,n+1,n+1,"pair:buck2"); - memory->create(offset,n+1,n+1,"pair:offset"); + memory->create(cut_lj, np1, np1, "pair:cut_lj"); + memory->create(cut_ljsq, np1, np1, "pair:cut_ljsq"); + memory->create(cut_coul, np1, np1, "pair:cut_coul"); + memory->create(cut_coulsq, np1, np1, "pair:cut_coulsq"); + memory->create(a, np1, np1, "pair:a"); + memory->create(rho, np1, np1, "pair:rho"); + memory->create(c, np1, np1, "pair:c"); + memory->create(rhoinv, np1, np1, "pair:rhoinv"); + memory->create(buck1, np1, np1, "pair:buck1"); + memory->create(buck2, np1, np1, "pair:buck2"); + memory->create(offset, np1, np1, "pair:offset"); } /* ---------------------------------------------------------------------- @@ -196,16 +196,18 @@ void PairBuckCoulCut::allocate() void PairBuckCoulCut::settings(int narg, char **arg) { - if (narg < 1 || narg > 2) error->all(FLERR,"Illegal pair_style command"); + if (narg < 1 || narg > 2) error->all(FLERR, "Illegal pair_style command"); - cut_lj_global = utils::numeric(FLERR,arg[0],false,lmp); - if (narg == 1) cut_coul_global = cut_lj_global; - else cut_coul_global = utils::numeric(FLERR,arg[1],false,lmp); + cut_lj_global = utils::numeric(FLERR, arg[0], false, lmp); + if (narg == 1) + cut_coul_global = cut_lj_global; + else + cut_coul_global = utils::numeric(FLERR, arg[1], false, lmp); // reset cutoffs that have been explicitly set if (allocated) { - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) if (setflag[i][j]) { @@ -221,27 +223,26 @@ void PairBuckCoulCut::settings(int narg, char **arg) void PairBuckCoulCut::coeff(int narg, char **arg) { - if (narg < 5 || narg > 7) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg < 5 || narg > 7) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); - double a_one = utils::numeric(FLERR,arg[2],false,lmp); - double rho_one = utils::numeric(FLERR,arg[3],false,lmp); - if (rho_one <= 0) error->all(FLERR,"Incorrect args for pair coefficients"); - double c_one = utils::numeric(FLERR,arg[4],false,lmp); + double a_one = utils::numeric(FLERR, arg[2], false, lmp); + double rho_one = utils::numeric(FLERR, arg[3], false, lmp); + if (rho_one <= 0) error->all(FLERR, "Incorrect args for pair coefficients"); + double c_one = utils::numeric(FLERR, arg[4], false, lmp); double cut_lj_one = cut_lj_global; double cut_coul_one = cut_coul_global; - if (narg >= 6) cut_coul_one = cut_lj_one = utils::numeric(FLERR,arg[5],false,lmp); - if (narg == 7) cut_coul_one = utils::numeric(FLERR,arg[6],false,lmp); + if (narg >= 6) cut_coul_one = cut_lj_one = utils::numeric(FLERR, arg[5], false, lmp); + if (narg == 7) cut_coul_one = utils::numeric(FLERR, arg[6], false, lmp); int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { a[i][j] = a_one; rho[i][j] = rho_one; c[i][j] = c_one; @@ -252,7 +253,7 @@ void PairBuckCoulCut::coeff(int narg, char **arg) } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -261,10 +262,9 @@ void PairBuckCoulCut::coeff(int narg, char **arg) void PairBuckCoulCut::init_style() { - if (!atom->q_flag) - error->all(FLERR,"Pair style buck/coul/cut requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style buck/coul/cut requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- @@ -273,20 +273,21 @@ void PairBuckCoulCut::init_style() double PairBuckCoulCut::init_one(int i, int j) { - if (setflag[i][j] == 0) error->all(FLERR,"All pair coeffs are not set"); + if (setflag[i][j] == 0) error->all(FLERR, "All pair coeffs are not set"); - double cut = MAX(cut_lj[i][j],cut_coul[i][j]); + double cut = MAX(cut_lj[i][j], cut_coul[i][j]); cut_ljsq[i][j] = cut_lj[i][j] * cut_lj[i][j]; cut_coulsq[i][j] = cut_coul[i][j] * cut_coul[i][j]; - rhoinv[i][j] = 1.0/rho[i][j]; - buck1[i][j] = a[i][j]/rho[i][j]; - buck2[i][j] = 6.0*c[i][j]; + rhoinv[i][j] = 1.0 / rho[i][j]; + buck1[i][j] = a[i][j] / rho[i][j]; + buck2[i][j] = 6.0 * c[i][j]; if (offset_flag && (cut_lj[i][j] > 0.0)) { - double rexp = exp(-cut_lj[i][j]/rho[i][j]); - offset[i][j] = a[i][j]*rexp - c[i][j]/pow(cut_lj[i][j],6.0); - } else offset[i][j] = 0.0; + double rexp = exp(-cut_lj[i][j] / rho[i][j]); + offset[i][j] = a[i][j] * rexp - c[i][j] / pow(cut_lj[i][j], 6.0); + } else + offset[i][j] = 0.0; cut_ljsq[j][i] = cut_ljsq[i][j]; cut_coulsq[j][i] = cut_coulsq[i][j]; @@ -304,26 +305,26 @@ double PairBuckCoulCut::init_one(int i, int j) int *type = atom->type; int nlocal = atom->nlocal; - double count[2],all[2]; + double count[2], all[2]; count[0] = count[1] = 0.0; for (int k = 0; k < nlocal; k++) { if (type[k] == i) count[0] += 1.0; if (type[k] == j) count[1] += 1.0; } - MPI_Allreduce(count,all,2,MPI_DOUBLE,MPI_SUM,world); + MPI_Allreduce(count, all, 2, MPI_DOUBLE, MPI_SUM, world); double rho1 = rho[i][j]; - double rho2 = rho1*rho1; - double rho3 = rho2*rho1; + double rho2 = rho1 * rho1; + double rho3 = rho2 * rho1; double rc = cut_lj[i][j]; - double rc2 = rc*rc; - double rc3 = rc2*rc; - etail_ij = 2.0*MY_PI*all[0]*all[1]* - (a[i][j]*exp(-rc/rho1)*rho1*(rc2 + 2.0*rho1*rc + 2.0*rho2) - - c[i][j]/(3.0*rc3)); - ptail_ij = (-1/3.0)*2.0*MY_PI*all[0]*all[1]* - (-a[i][j]*exp(-rc/rho1)* - (rc3 + 3.0*rho1*rc2 + 6.0*rho2*rc + 6.0*rho3) + 2.0*c[i][j]/rc3); + double rc2 = rc * rc; + double rc3 = rc2 * rc; + etail_ij = 2.0 * MY_PI * all[0] * all[1] * + (a[i][j] * exp(-rc / rho1) * rho1 * (rc2 + 2.0 * rho1 * rc + 2.0 * rho2) - + c[i][j] / (3.0 * rc3)); + ptail_ij = (-1 / 3.0) * 2.0 * MY_PI * all[0] * all[1] * + (-a[i][j] * exp(-rc / rho1) * (rc3 + 3.0 * rho1 * rc2 + 6.0 * rho2 * rc + 6.0 * rho3) + + 2.0 * c[i][j] / rc3); } return cut; @@ -337,16 +338,16 @@ void PairBuckCoulCut::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - fwrite(&setflag[i][j],sizeof(int),1,fp); + fwrite(&setflag[i][j], sizeof(int), 1, fp); if (setflag[i][j]) { - fwrite(&a[i][j],sizeof(double),1,fp); - fwrite(&rho[i][j],sizeof(double),1,fp); - fwrite(&c[i][j],sizeof(double),1,fp); - fwrite(&cut_lj[i][j],sizeof(double),1,fp); - fwrite(&cut_coul[i][j],sizeof(double),1,fp); + fwrite(&a[i][j], sizeof(double), 1, fp); + fwrite(&rho[i][j], sizeof(double), 1, fp); + fwrite(&c[i][j], sizeof(double), 1, fp); + fwrite(&cut_lj[i][j], sizeof(double), 1, fp); + fwrite(&cut_coul[i][j], sizeof(double), 1, fp); } } } @@ -361,25 +362,25 @@ void PairBuckCoulCut::read_restart(FILE *fp) allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); if (setflag[i][j]) { if (me == 0) { - utils::sfread(FLERR,&a[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&rho[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&c[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_lj[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul[i][j],sizeof(double),1,fp,nullptr,error); + utils::sfread(FLERR, &a[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &rho[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &c[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_lj[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul[i][j], sizeof(double), 1, fp, nullptr, error); } - MPI_Bcast(&a[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&rho[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&c[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_lj[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul[i][j],1,MPI_DOUBLE,0,world); + MPI_Bcast(&a[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&rho[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&c[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_lj[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul[i][j], 1, MPI_DOUBLE, 0, world); } } } @@ -390,11 +391,11 @@ void PairBuckCoulCut::read_restart(FILE *fp) void PairBuckCoulCut::write_restart_settings(FILE *fp) { - fwrite(&cut_lj_global,sizeof(double),1,fp); - fwrite(&cut_coul_global,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); - fwrite(&tail_flag,sizeof(int),1,fp); + fwrite(&cut_lj_global, sizeof(double), 1, fp); + fwrite(&cut_coul_global, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); + fwrite(&tail_flag, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -404,17 +405,17 @@ void PairBuckCoulCut::write_restart_settings(FILE *fp) void PairBuckCoulCut::read_restart_settings(FILE *fp) { if (comm->me == 0) { - utils::sfread(FLERR,&cut_lj_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&tail_flag,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &cut_lj_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &tail_flag, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&cut_lj_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); - MPI_Bcast(&tail_flag,1,MPI_INT,0,world); + MPI_Bcast(&cut_lj_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&tail_flag, 1, MPI_INT, 0, world); } /* ---------------------------------------------------------------------- @@ -424,7 +425,7 @@ void PairBuckCoulCut::read_restart_settings(FILE *fp) void PairBuckCoulCut::write_data(FILE *fp) { for (int i = 1; i <= atom->ntypes; i++) - fprintf(fp,"%d %g %g %g\n",i,a[i][i],rho[i][i],c[i][i]); + fprintf(fp, "%d %g %g %g\n", i, a[i][i], rho[i][i], c[i][i]); } /* ---------------------------------------------------------------------- @@ -435,40 +436,39 @@ void PairBuckCoulCut::write_data_all(FILE *fp) { for (int i = 1; i <= atom->ntypes; i++) for (int j = i; j <= atom->ntypes; j++) - fprintf(fp,"%d %d %g %g %g %g %g\n",i,j, - a[i][j],rho[i][j],c[i][j],cut_lj[i][j],cut_coul[i][j]); + fprintf(fp, "%d %d %g %g %g %g %g\n", i, j, a[i][j], rho[i][j], c[i][j], cut_lj[i][j], + cut_coul[i][j]); } /* ---------------------------------------------------------------------- */ -double PairBuckCoulCut::single(int i, int j, int itype, int jtype, - double rsq, - double factor_coul, double factor_lj, - double &fforce) +double PairBuckCoulCut::single(int i, int j, int itype, int jtype, double rsq, double factor_coul, + double factor_lj, double &fforce) { - double r2inv,r6inv,r,rexp,forcecoul,forcebuck,phicoul,phibuck; + double r2inv, r6inv, r, rexp, forcecoul, forcebuck, phicoul, phibuck; - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq[itype][jtype]) - forcecoul = force->qqrd2e * atom->q[i]*atom->q[j]*sqrt(r2inv); - else forcecoul = 0.0; + forcecoul = force->qqrd2e * atom->q[i] * atom->q[j] * sqrt(r2inv); + else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; + r6inv = r2inv * r2inv * r2inv; r = sqrt(rsq); - rexp = exp(-r*rhoinv[itype][jtype]); - forcebuck = buck1[itype][jtype]*r*rexp - buck2[itype][jtype]*r6inv; - } else forcebuck = 0.0; - fforce = (factor_coul*forcecoul + factor_lj*forcebuck) * r2inv; + rexp = exp(-r * rhoinv[itype][jtype]); + forcebuck = buck1[itype][jtype] * r * rexp - buck2[itype][jtype] * r6inv; + } else + forcebuck = 0.0; + fforce = (factor_coul * forcecoul + factor_lj * forcebuck) * r2inv; double eng = 0.0; if (rsq < cut_coulsq[itype][jtype]) { - phicoul = force->qqrd2e * atom->q[i]*atom->q[j]*sqrt(r2inv); - eng += factor_coul*phicoul; + phicoul = force->qqrd2e * atom->q[i] * atom->q[j] * sqrt(r2inv); + eng += factor_coul * phicoul; } if (rsq < cut_ljsq[itype][jtype]) { - phibuck = a[itype][jtype]*rexp - c[itype][jtype]*r6inv - - offset[itype][jtype]; - eng += factor_lj*phibuck; + phibuck = a[itype][jtype] * rexp - c[itype][jtype] * r6inv - offset[itype][jtype]; + eng += factor_lj * phibuck; } return eng; } @@ -478,7 +478,7 @@ double PairBuckCoulCut::single(int i, int j, int itype, int jtype, void *PairBuckCoulCut::extract(const char *str, int &dim) { dim = 2; - if (strcmp(str,"a") == 0) return (void *) a; - if (strcmp(str,"c") == 0) return (void *) c; + if (strcmp(str, "a") == 0) return (void *) a; + if (strcmp(str, "c") == 0) return (void *) c; return nullptr; } diff --git a/src/pair_coul_cut.cpp b/src/pair_coul_cut.cpp index ea29358174..daca6374c5 100644 --- a/src/pair_coul_cut.cpp +++ b/src/pair_coul_cut.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -29,7 +28,8 @@ using namespace LAMMPS_NS; /* ---------------------------------------------------------------------- */ -PairCoulCut::PairCoulCut(LAMMPS *lmp) : Pair(lmp) { +PairCoulCut::PairCoulCut(LAMMPS *lmp) : Pair(lmp) +{ writedata = 1; } @@ -52,13 +52,13 @@ PairCoulCut::~PairCoulCut() void PairCoulCut::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,ecoul,fpair; - double rsq,r2inv,rinv,forcecoul,factor_coul; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, ecoul, fpair; + double rsq, r2inv, rinv, forcecoul, factor_coul; + int *ilist, *jlist, *numneigh, **firstneigh; ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -94,29 +94,27 @@ void PairCoulCut::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; rinv = sqrt(r2inv); - forcecoul = qqrd2e * scale[itype][jtype] * qtmp*q[j]*rinv; - fpair = factor_coul*forcecoul * r2inv; + forcecoul = qqrd2e * scale[itype][jtype] * qtmp * q[j] * rinv; + fpair = factor_coul * forcecoul * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (newton_pair || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } - if (eflag) - ecoul = factor_coul * qqrd2e * scale[itype][jtype] * qtmp*q[j]*rinv; + if (eflag) ecoul = factor_coul * qqrd2e * scale[itype][jtype] * qtmp * q[j] * rinv; - if (evflag) ev_tally(i,j,nlocal,newton_pair, - 0.0,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally(i, j, nlocal, newton_pair, 0.0, ecoul, fpair, delx, dely, delz); } } } @@ -131,19 +129,19 @@ void PairCoulCut::compute(int eflag, int vflag) void PairCoulCut::allocate() { allocated = 1; - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); - memory->create(scale,n+1,n+1,"pair:scale"); - for (int i = 1; i <= n; i++) { - for (int j = i; j <= n; j++) { + memory->create(setflag, np1, np1, "pair:setflag"); + memory->create(scale, np1, np1, "pair:scale"); + for (int i = 1; i < np1; i++) { + for (int j = i; j < np1; j++) { setflag[i][j] = 0; scale[i][j] = 1.0; } } - memory->create(cutsq,n+1,n+1,"pair:cutsq"); - memory->create(cut,n+1,n+1,"pair:cut"); + memory->create(cutsq, np1, np1, "pair:cutsq"); + memory->create(cut, np1, np1, "pair:cut"); } /* ---------------------------------------------------------------------- @@ -152,14 +150,14 @@ void PairCoulCut::allocate() void PairCoulCut::settings(int narg, char **arg) { - if (narg != 1) error->all(FLERR,"Illegal pair_style command"); + if (narg != 1) error->all(FLERR, "Illegal pair_style command"); - cut_global = utils::numeric(FLERR,arg[0],false,lmp); + cut_global = utils::numeric(FLERR, arg[0], false, lmp); // reset cutoffs that have been explicitly set if (allocated) { - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) if (setflag[i][j]) cut[i][j] = cut_global; @@ -172,20 +170,19 @@ void PairCoulCut::settings(int narg, char **arg) void PairCoulCut::coeff(int narg, char **arg) { - if (narg < 2 || narg > 3) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg < 2 || narg > 3) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); double cut_one = cut_global; - if (narg == 3) cut_one = utils::numeric(FLERR,arg[2],false,lmp); + if (narg == 3) cut_one = utils::numeric(FLERR, arg[2], false, lmp); int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { cut[i][j] = cut_one; scale[i][j] = 1.0; setflag[i][j] = 1; @@ -193,20 +190,18 @@ void PairCoulCut::coeff(int narg, char **arg) } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } - /* ---------------------------------------------------------------------- init specific to this pair style ------------------------------------------------------------------------- */ void PairCoulCut::init_style() { - if (!atom->q_flag) - error->all(FLERR,"Pair style coul/cut requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style coul/cut requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- @@ -216,7 +211,7 @@ void PairCoulCut::init_style() double PairCoulCut::init_one(int i, int j) { if (setflag[i][j] == 0) { - cut[i][j] = mix_distance(cut[i][i],cut[j][j]); + cut[i][j] = mix_distance(cut[i][i], cut[j][j]); scale[i][j] = 1.0; } @@ -233,14 +228,12 @@ void PairCoulCut::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) { for (j = i; j <= atom->ntypes; j++) { - fwrite(&scale[i][j],sizeof(double),1,fp); - fwrite(&setflag[i][j],sizeof(int),1,fp); - if (setflag[i][j]) { - fwrite(&cut[i][j],sizeof(double),1,fp); - } + fwrite(&scale[i][j], sizeof(double), 1, fp); + fwrite(&setflag[i][j], sizeof(int), 1, fp); + if (setflag[i][j]) { fwrite(&cut[i][j], sizeof(double), 1, fp); } } } } @@ -254,20 +247,19 @@ void PairCoulCut::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) { for (j = i; j <= atom->ntypes; j++) { if (me == 0) { - utils::sfread(FLERR,&scale[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &scale[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&scale[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + MPI_Bcast(&scale[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); if (setflag[i][j]) { - if (me == 0) - utils::sfread(FLERR,&cut[i][j],sizeof(double),1,fp,nullptr,error); - MPI_Bcast(&cut[i][j],1,MPI_DOUBLE,0,world); + if (me == 0) utils::sfread(FLERR, &cut[i][j], sizeof(double), 1, fp, nullptr, error); + MPI_Bcast(&cut[i][j], 1, MPI_DOUBLE, 0, world); } } } @@ -279,9 +271,9 @@ void PairCoulCut::read_restart(FILE *fp) void PairCoulCut::write_restart_settings(FILE *fp) { - fwrite(&cut_global,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); + fwrite(&cut_global, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -291,13 +283,13 @@ void PairCoulCut::write_restart_settings(FILE *fp) void PairCoulCut::read_restart_settings(FILE *fp) { if (comm->me == 0) { - utils::sfread(FLERR,&cut_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &cut_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&cut_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); + MPI_Bcast(&cut_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); } /* ---------------------------------------------------------------------- @@ -306,8 +298,7 @@ void PairCoulCut::read_restart_settings(FILE *fp) void PairCoulCut::write_data(FILE *fp) { - for (int i = 1; i <= atom->ntypes; i++) - fprintf(fp,"%d\n",i); + for (int i = 1; i <= atom->ntypes; i++) fprintf(fp, "%d\n", i); } /* ---------------------------------------------------------------------- @@ -317,25 +308,23 @@ void PairCoulCut::write_data(FILE *fp) void PairCoulCut::write_data_all(FILE *fp) { for (int i = 1; i <= atom->ntypes; i++) - for (int j = i; j <= atom->ntypes; j++) - fprintf(fp,"%d %d %g\n",i,j,cut[i][j]); + for (int j = i; j <= atom->ntypes; j++) fprintf(fp, "%d %d %g\n", i, j, cut[i][j]); } /* ---------------------------------------------------------------------- */ -double PairCoulCut::single(int i, int j, int /*itype*/, int /*jtype*/, - double rsq, double factor_coul, double /*factor_lj*/, - double &fforce) +double PairCoulCut::single(int i, int j, int /*itype*/, int /*jtype*/, double rsq, + double factor_coul, double /*factor_lj*/, double &fforce) { - double r2inv,rinv,forcecoul,phicoul; + double r2inv, rinv, forcecoul, phicoul; - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; rinv = sqrt(r2inv); - forcecoul = force->qqrd2e * atom->q[i]*atom->q[j]*rinv; - fforce = factor_coul*forcecoul * r2inv; + forcecoul = force->qqrd2e * atom->q[i] * atom->q[j] * rinv; + fforce = factor_coul * forcecoul * r2inv; - phicoul = force->qqrd2e * atom->q[i]*atom->q[j]*rinv; - return factor_coul*phicoul; + phicoul = force->qqrd2e * atom->q[i] * atom->q[j] * rinv; + return factor_coul * phicoul; } /* ---------------------------------------------------------------------- */ @@ -343,7 +332,7 @@ double PairCoulCut::single(int i, int j, int /*itype*/, int /*jtype*/, void *PairCoulCut::extract(const char *str, int &dim) { dim = 2; - if (strcmp(str,"cut_coul") == 0) return (void *) cut; - if (strcmp(str,"scale") == 0) return (void *) scale; + if (strcmp(str, "cut_coul") == 0) return (void *) cut; + if (strcmp(str, "scale") == 0) return (void *) scale; return nullptr; } diff --git a/src/pair_coul_dsf.cpp b/src/pair_coul_dsf.cpp index 98c9f7f5d6..9617cc1331 100644 --- a/src/pair_coul_dsf.cpp +++ b/src/pair_coul_dsf.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -19,27 +18,28 @@ #include "pair_coul_dsf.h" -#include -#include #include "atom.h" #include "comm.h" -#include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "memory.h" -#include "math_const.h" #include "error.h" +#include "force.h" +#include "math_const.h" +#include "memory.h" +#include "neigh_list.h" +#include "neighbor.h" + +#include +#include using namespace LAMMPS_NS; using namespace MathConst; -#define EWALD_F 1.12837917 -#define EWALD_P 0.3275911 -#define A1 0.254829592 -#define A2 -0.284496736 -#define A3 1.421413741 -#define A4 -1.453152027 -#define A5 1.061405429 +#define EWALD_F 1.12837917 +#define EWALD_P 0.3275911 +#define A1 0.254829592 +#define A2 -0.284496736 +#define A3 1.421413741 +#define A4 -1.453152027 +#define A5 1.061405429 /* ---------------------------------------------------------------------- */ @@ -61,14 +61,14 @@ PairCoulDSF::~PairCoulDSF() void PairCoulDSF::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,ecoul,fpair; - double r,rsq,forcecoul,factor_coul; - double prefactor,erfcc,erfcd,t; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, ecoul, fpair; + double r, rsq, forcecoul, factor_coul; + double prefactor, erfcc, erfcd, t; + int *ilist, *jlist, *numneigh, **firstneigh; ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -95,8 +95,8 @@ void PairCoulDSF::compute(int eflag, int vflag) jnum = numneigh[i]; if (eflag) { - double e_self = -(e_shift/2.0 + alpha/MY_PIS) * qtmp*qtmp*qqrd2e; - ev_tally(i,i,nlocal,0,0.0,e_self,0.0,0.0,0.0,0.0); + double e_self = -(e_shift / 2.0 + alpha / MY_PIS) * qtmp * qtmp * qqrd2e; + ev_tally(i, i, nlocal, 0, 0.0, e_self, 0.0, 0.0, 0.0, 0.0); } for (jj = 0; jj < jnum; jj++) { @@ -107,36 +107,35 @@ void PairCoulDSF::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cut_coulsq) { r = sqrt(rsq); - prefactor = qqrd2e*qtmp*q[j]/r; - erfcd = exp(-alpha*alpha*rsq); - t = 1.0 / (1.0 + EWALD_P*alpha*r); - erfcc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * erfcd; + prefactor = qqrd2e * qtmp * q[j] / r; + erfcd = exp(-alpha * alpha * rsq); + t = 1.0 / (1.0 + EWALD_P * alpha * r); + erfcc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * erfcd; - forcecoul = prefactor * (erfcc/r + 2.0*alpha/MY_PIS * erfcd + - r*f_shift) * r; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + forcecoul = prefactor * (erfcc / r + 2.0 * alpha / MY_PIS * erfcd + r * f_shift) * r; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; fpair = forcecoul / rsq; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (newton_pair || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } if (eflag) { - ecoul = prefactor * (erfcc - r*e_shift - rsq*f_shift); - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + ecoul = prefactor * (erfcc - r * e_shift - rsq * f_shift); + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; - if (evflag) ev_tally(i,j,nlocal,newton_pair, - 0.0,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally(i, j, nlocal, newton_pair, 0.0, ecoul, fpair, delx, dely, delz); } } } @@ -153,12 +152,11 @@ void PairCoulDSF::allocate() allocated = 1; int n = atom->ntypes; - memory->create(setflag,n+1,n+1,"pair:setflag"); + memory->create(setflag, n + 1, n + 1, "pair:setflag"); for (int i = 1; i <= n; i++) - for (int j = i; j <= n; j++) - setflag[i][j] = 0; + for (int j = i; j <= n; j++) setflag[i][j] = 0; - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, n + 1, n + 1, "pair:cutsq"); } /* ---------------------------------------------------------------------- @@ -167,10 +165,10 @@ void PairCoulDSF::allocate() void PairCoulDSF::settings(int narg, char **arg) { - if (narg != 2) error->all(FLERR,"Illegal pair_style command"); + if (narg != 2) error->all(FLERR, "Illegal pair_style command"); - alpha = utils::numeric(FLERR,arg[0],false,lmp); - cut_coul = utils::numeric(FLERR,arg[1],false,lmp); + alpha = utils::numeric(FLERR, arg[0], false, lmp); + cut_coul = utils::numeric(FLERR, arg[1], false, lmp); } /* ---------------------------------------------------------------------- @@ -179,22 +177,22 @@ void PairCoulDSF::settings(int narg, char **arg) void PairCoulDSF::coeff(int narg, char **arg) { - if (narg != 2) error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg != 2) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { setflag[i][j] = 1; count++; } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -203,16 +201,15 @@ void PairCoulDSF::coeff(int narg, char **arg) void PairCoulDSF::init_style() { - if (!atom->q_flag) - error->all(FLERR,"Pair style coul/dsf requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style coul/dsf requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_coulsq = cut_coul * cut_coul; - double erfcc = erfc(alpha*cut_coul); - double erfcd = exp(-alpha*alpha*cut_coul*cut_coul); - f_shift = -(erfcc/cut_coulsq + 2.0/MY_PIS*alpha*erfcd/cut_coul); - e_shift = erfcc/cut_coul - f_shift*cut_coul; + double erfcc = erfc(alpha * cut_coul); + double erfcd = exp(-alpha * alpha * cut_coul * cut_coul); + f_shift = -(erfcc / cut_coulsq + 2.0 / MY_PIS * alpha * erfcd / cut_coul); + e_shift = erfcc / cut_coul - f_shift * cut_coul; } /* ---------------------------------------------------------------------- @@ -232,11 +229,9 @@ void PairCoulDSF::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) - for (j = i; j <= atom->ntypes; j++) { - fwrite(&setflag[i][j],sizeof(int),1,fp); - } + for (j = i; j <= atom->ntypes; j++) { fwrite(&setflag[i][j], sizeof(int), 1, fp); } } /* ---------------------------------------------------------------------- @@ -248,12 +243,12 @@ void PairCoulDSF::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); } } @@ -263,10 +258,10 @@ void PairCoulDSF::read_restart(FILE *fp) void PairCoulDSF::write_restart_settings(FILE *fp) { - fwrite(&alpha,sizeof(double),1,fp); - fwrite(&cut_coul,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); + fwrite(&alpha, sizeof(double), 1, fp); + fwrite(&cut_coul, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -276,40 +271,38 @@ void PairCoulDSF::write_restart_settings(FILE *fp) void PairCoulDSF::read_restart_settings(FILE *fp) { if (comm->me == 0) { - utils::sfread(FLERR,&alpha,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &alpha, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&alpha,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); + MPI_Bcast(&alpha, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); } /* ---------------------------------------------------------------------- */ double PairCoulDSF::single(int i, int j, int /*itype*/, int /*jtype*/, double rsq, - double factor_coul, double /*factor_lj*/, - double &fforce) + double factor_coul, double /*factor_lj*/, double &fforce) { - double r,erfcc,erfcd,prefactor,t; - double forcecoul,phicoul; + double r, erfcc, erfcd, prefactor, t; + double forcecoul, phicoul; forcecoul = phicoul = 0.0; if (rsq < cut_coulsq) { r = sqrt(rsq); - prefactor = force->qqrd2e * atom->q[i]*atom->q[j]/r; - erfcd = exp(-alpha*alpha*rsq); - t = 1.0 / (1.0 + EWALD_P*alpha*r); - erfcc = t * (A1+t*(A2+t*(A3+t*(A4+t*A5)))) * erfcd; + prefactor = force->qqrd2e * atom->q[i] * atom->q[j] / r; + erfcd = exp(-alpha * alpha * rsq); + t = 1.0 / (1.0 + EWALD_P * alpha * r); + erfcc = t * (A1 + t * (A2 + t * (A3 + t * (A4 + t * A5)))) * erfcd; - forcecoul = prefactor * (erfcc/r + 2.0*alpha/MY_PIS*erfcd + - r*f_shift) * r; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + forcecoul = prefactor * (erfcc / r + 2.0 * alpha / MY_PIS * erfcd + r * f_shift) * r; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; - phicoul = prefactor * (erfcc - r*e_shift - rsq*f_shift); - if (factor_coul < 1.0) phicoul -= (1.0-factor_coul)*prefactor; + phicoul = prefactor * (erfcc - r * e_shift - rsq * f_shift); + if (factor_coul < 1.0) phicoul -= (1.0 - factor_coul) * prefactor; } fforce = forcecoul / rsq; @@ -321,7 +314,7 @@ double PairCoulDSF::single(int i, int j, int /*itype*/, int /*jtype*/, double rs void *PairCoulDSF::extract(const char *str, int &dim) { - if (strcmp(str,"cut_coul") == 0) { + if (strcmp(str, "cut_coul") == 0) { dim = 0; return (void *) &cut_coul; } diff --git a/src/pair_coul_wolf.cpp b/src/pair_coul_wolf.cpp index 3a260abf28..3d8ade8110 100644 --- a/src/pair_coul_wolf.cpp +++ b/src/pair_coul_wolf.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -18,16 +17,16 @@ #include "pair_coul_wolf.h" -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -36,7 +35,7 @@ using namespace MathConst; PairCoulWolf::PairCoulWolf(LAMMPS *lmp) : Pair(lmp) { - single_enable = 0; // NOTE: single() method below is not yet correct + single_enable = 0; // NOTE: single() method below is not yet correct } /* ---------------------------------------------------------------------- */ @@ -55,16 +54,16 @@ PairCoulWolf::~PairCoulWolf() void PairCoulWolf::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,ecoul,fpair; - double rsq,forcecoul,factor_coul; + int i, j, ii, jj, inum, jnum; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, ecoul, fpair; + double rsq, forcecoul, factor_coul; double prefactor; double r; - int *ilist,*jlist,*numneigh,**firstneigh; - double erfcc,erfcd,v_sh,dvdrr,e_self,e_shift,f_shift,qisq; + int *ilist, *jlist, *numneigh, **firstneigh; + double erfcc, erfcd, v_sh, dvdrr, e_self, e_shift, f_shift, qisq; ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -77,9 +76,8 @@ void PairCoulWolf::compute(int eflag, int vflag) // self and shifted coulombic energy e_self = v_sh = 0.0; - e_shift = erfc(alf*cut_coul)/cut_coul; - f_shift = -(e_shift+ 2.0*alf/MY_PIS * exp(-alf*alf*cut_coul*cut_coul)) / - cut_coul; + e_shift = erfc(alf * cut_coul) / cut_coul; + f_shift = -(e_shift + 2.0 * alf / MY_PIS * exp(-alf * alf * cut_coul * cut_coul)) / cut_coul; inum = list->inum; ilist = list->ilist; @@ -97,9 +95,9 @@ void PairCoulWolf::compute(int eflag, int vflag) jlist = firstneigh[i]; jnum = numneigh[i]; - qisq = qtmp*qtmp; - e_self = -(e_shift/2.0 + alf/MY_PIS) * qisq*qqrd2e; - if (evflag) ev_tally(i,i,nlocal,0,0.0,e_self,0.0,0.0,0.0,0.0); + qisq = qtmp * qtmp; + e_self = -(e_shift / 2.0 + alf / MY_PIS) * qisq * qqrd2e; + if (evflag) ev_tally(i, i, nlocal, 0, 0.0, e_self, 0.0, 0.0, 0.0, 0.0); for (jj = 0; jj < jnum; jj++) { j = jlist[jj]; @@ -109,35 +107,35 @@ void PairCoulWolf::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; if (rsq < cut_coulsq) { r = sqrt(rsq); - prefactor = qqrd2e*qtmp*q[j]/r; - erfcc = erfc(alf*r); - erfcd = exp(-alf*alf*r*r); - v_sh = (erfcc - e_shift*r) * prefactor; - dvdrr = (erfcc/rsq + 2.0*alf/MY_PIS * erfcd/r) + f_shift; - forcecoul = dvdrr*rsq*prefactor; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; + prefactor = qqrd2e * qtmp * q[j] / r; + erfcc = erfc(alf * r); + erfcd = exp(-alf * alf * r * r); + v_sh = (erfcc - e_shift * r) * prefactor; + dvdrr = (erfcc / rsq + 2.0 * alf / MY_PIS * erfcd / r) + f_shift; + forcecoul = dvdrr * rsq * prefactor; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; fpair = forcecoul / rsq; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (newton_pair || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } if (eflag) { ecoul = v_sh; - if (factor_coul < 1.0) ecoul -= (1.0-factor_coul)*prefactor; - } else ecoul = 0.0; + if (factor_coul < 1.0) ecoul -= (1.0 - factor_coul) * prefactor; + } else + ecoul = 0.0; - if (evflag) ev_tally(i,j,nlocal,newton_pair, - 0.0,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally(i, j, nlocal, newton_pair, 0.0, ecoul, fpair, delx, dely, delz); } } } @@ -154,12 +152,11 @@ void PairCoulWolf::allocate() allocated = 1; int n = atom->ntypes; - memory->create(setflag,n+1,n+1,"pair:setflag"); + memory->create(setflag, n + 1, n + 1, "pair:setflag"); for (int i = 1; i <= n; i++) - for (int j = i; j <= n; j++) - setflag[i][j] = 0; + for (int j = i; j <= n; j++) setflag[i][j] = 0; - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, n + 1, n + 1, "pair:cutsq"); } /* ---------------------------------------------------------------------- @@ -170,10 +167,10 @@ void PairCoulWolf::allocate() void PairCoulWolf::settings(int narg, char **arg) { - if (narg != 2) error->all(FLERR,"Illegal pair_style command"); + if (narg != 2) error->all(FLERR, "Illegal pair_style command"); - alf = utils::numeric(FLERR,arg[0],false,lmp); - cut_coul = utils::numeric(FLERR,arg[1],false,lmp); + alf = utils::numeric(FLERR, arg[0], false, lmp); + cut_coul = utils::numeric(FLERR, arg[1], false, lmp); } /* ---------------------------------------------------------------------- @@ -182,22 +179,22 @@ void PairCoulWolf::settings(int narg, char **arg) void PairCoulWolf::coeff(int narg, char **arg) { - if (narg != 2) error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg != 2) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { setflag[i][j] = 1; count++; } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -206,12 +203,11 @@ void PairCoulWolf::coeff(int narg, char **arg) void PairCoulWolf::init_style() { - if (!atom->q_flag) - error->all(FLERR,"Pair coul/wolf requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair coul/wolf requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); - cut_coulsq = cut_coul*cut_coul; + cut_coulsq = cut_coul * cut_coul; } /* ---------------------------------------------------------------------- @@ -231,10 +227,9 @@ void PairCoulWolf::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) - for (j = i; j <= atom->ntypes; j++) - fwrite(&setflag[i][j],sizeof(int),1,fp); + for (j = i; j <= atom->ntypes; j++) fwrite(&setflag[i][j], sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -246,12 +241,12 @@ void PairCoulWolf::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); } } @@ -261,10 +256,10 @@ void PairCoulWolf::read_restart(FILE *fp) void PairCoulWolf::write_restart_settings(FILE *fp) { - fwrite(&alf,sizeof(double),1,fp); - fwrite(&cut_coul,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); + fwrite(&alf, sizeof(double), 1, fp); + fwrite(&cut_coul, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -274,15 +269,15 @@ void PairCoulWolf::write_restart_settings(FILE *fp) void PairCoulWolf::read_restart_settings(FILE *fp) { if (comm->me == 0) { - utils::sfread(FLERR,&alf,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &alf, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&alf,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); + MPI_Bcast(&alf, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); } /* ---------------------------------------------------------------------- @@ -290,32 +285,31 @@ void PairCoulWolf::read_restart_settings(FILE *fp) ------------------------------------------------------------------------- */ double PairCoulWolf::single(int i, int j, int /*itype*/, int /*jtype*/, double rsq, - double factor_coul, double /*factor_lj*/, - double &fforce) + double factor_coul, double /*factor_lj*/, double &fforce) { - double r,prefactor; - double forcecoul,phicoul; - double e_shift,f_shift,dvdrr,erfcc,erfcd; + double r, prefactor; + double forcecoul, phicoul; + double e_shift, f_shift, dvdrr, erfcc, erfcd; - e_shift = erfc(alf*cut_coul) / cut_coul; - f_shift = -(e_shift+ 2.0*alf/MY_PIS * exp(-alf*alf*cut_coul*cut_coul)) / - cut_coul; + e_shift = erfc(alf * cut_coul) / cut_coul; + f_shift = -(e_shift + 2.0 * alf / MY_PIS * exp(-alf * alf * cut_coul * cut_coul)) / cut_coul; if (rsq < cut_coulsq) { r = sqrt(rsq); - prefactor = force->qqrd2e * atom->q[i]*atom->q[j]/r; - erfcc = erfc(alf*r); - erfcd = exp(-alf*alf*r*r); - dvdrr = (erfcc/rsq + 2.0*alf/MY_PIS * erfcd/r) + f_shift; - forcecoul = dvdrr*rsq*prefactor; - if (factor_coul < 1.0) forcecoul -= (1.0-factor_coul)*prefactor; - } else forcecoul = 0.0; + prefactor = force->qqrd2e * atom->q[i] * atom->q[j] / r; + erfcc = erfc(alf * r); + erfcd = exp(-alf * alf * r * r); + dvdrr = (erfcc / rsq + 2.0 * alf / MY_PIS * erfcd / r) + f_shift; + forcecoul = dvdrr * rsq * prefactor; + if (factor_coul < 1.0) forcecoul -= (1.0 - factor_coul) * prefactor; + } else + forcecoul = 0.0; fforce = forcecoul / rsq; double eng = 0.0; if (rsq < cut_coulsq) { - phicoul = prefactor * (erfcc-e_shift*r); - if (factor_coul < 1.0) phicoul -= (1.0-factor_coul)*prefactor; + phicoul = prefactor * (erfcc - e_shift * r); + if (factor_coul < 1.0) phicoul -= (1.0 - factor_coul) * prefactor; eng += phicoul; } return eng; diff --git a/src/pair_hybrid.cpp b/src/pair_hybrid.cpp index 6287fb97db..5deb35b634 100644 --- a/src/pair_hybrid.cpp +++ b/src/pair_hybrid.cpp @@ -610,13 +610,12 @@ void PairHybrid::init_style() // create skip lists inside each pair neigh request // any kind of list can have its skip flag set in this loop - for (i = 0; i < neighbor->nrequest; i++) { - if (!neighbor->requests[i]->pair) continue; + for (auto &request : neighbor->get_pair_requests()) { // istyle = associated sub-style for the request for (istyle = 0; istyle < nstyles; istyle++) - if (styles[istyle] == neighbor->requests[i]->requestor) break; + if (styles[istyle] == request->get_requestor()) break; // allocate iskip and ijskip // initialize so as to skip all pair types @@ -663,9 +662,7 @@ void PairHybrid::init_style() if (ijskip[itype][jtype] == 1) skip = 1; if (skip) { - neighbor->requests[i]->skip = 1; - neighbor->requests[i]->iskip = iskip; - neighbor->requests[i]->ijskip = ijskip; + request->set_skip(iskip, ijskip); } else { delete[] iskip; memory->destroy(ijskip); diff --git a/src/pair_lj_cut.cpp b/src/pair_lj_cut.cpp index a9d45b9007..c6751b3505 100644 --- a/src/pair_lj_cut.cpp +++ b/src/pair_lj_cut.cpp @@ -24,7 +24,6 @@ #include "math_const.h" #include "memory.h" #include "neigh_list.h" -#include "neigh_request.h" #include "neighbor.h" #include "respa.h" #include "update.h" @@ -476,21 +475,14 @@ void PairLJCut::init_style() { // request regular or rRESPA neighbor list - int irequest; - int respa = 0; + int list_style = NeighConst::REQ_DEFAULT; if (update->whichflag == 1 && utils::strmatch(update->integrate_style, "^respa")) { - if (((Respa *) update->integrate)->level_inner >= 0) respa = 1; - if (((Respa *) update->integrate)->level_middle >= 0) respa = 2; + auto respa = (Respa *) update->integrate; + if (respa->level_inner >= 0) list_style = NeighConst::REQ_RESPA_INOUT; + if (respa->level_middle >= 0) list_style = NeighConst::REQ_RESPA_ALL; } - - irequest = neighbor->request(this, instance_me); - - if (respa >= 1) { - neighbor->requests[irequest]->respaouter = 1; - neighbor->requests[irequest]->respainner = 1; - } - if (respa == 2) neighbor->requests[irequest]->respamiddle = 1; + neighbor->add_request(this, list_style); // set rRESPA cutoffs diff --git a/src/pair_lj_cut_coul_cut.cpp b/src/pair_lj_cut_coul_cut.cpp index 4782a96fec..264a31b2c6 100644 --- a/src/pair_lj_cut_coul_cut.cpp +++ b/src/pair_lj_cut_coul_cut.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -14,17 +13,17 @@ #include "pair_lj_cut_coul_cut.h" -#include -#include #include "atom.h" #include "comm.h" +#include "error.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" #include "math_const.h" #include "memory.h" -#include "error.h" +#include "neigh_list.h" +#include "neighbor.h" +#include +#include using namespace LAMMPS_NS; using namespace MathConst; @@ -64,13 +63,13 @@ PairLJCutCoulCut::~PairLJCutCoulCut() void PairLJCutCoulCut::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum,itype,jtype; - double qtmp,xtmp,ytmp,ztmp,delx,dely,delz,evdwl,ecoul,fpair; - double rsq,r2inv,r6inv,forcecoul,forcelj,factor_coul,factor_lj; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, itype, jtype; + double qtmp, xtmp, ytmp, ztmp, delx, dely, delz, evdwl, ecoul, fpair; + double rsq, r2inv, r6inv, forcecoul, forcelj, factor_coul, factor_lj; + int *ilist, *jlist, *numneigh, **firstneigh; evdwl = ecoul = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -108,45 +107,47 @@ void PairLJCutCoulCut::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cutsq[itype][jtype]) { - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq[itype][jtype]) - forcecoul = qqrd2e * qtmp*q[j]*sqrt(r2inv); - else forcecoul = 0.0; + forcecoul = qqrd2e * qtmp * q[j] * sqrt(r2inv); + else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - } else forcelj = 0.0; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + } else + forcelj = 0.0; - fpair = (factor_coul*forcecoul + factor_lj*forcelj) * r2inv; + fpair = (factor_coul * forcecoul + factor_lj * forcelj) * r2inv; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (newton_pair || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } if (eflag) { if (rsq < cut_coulsq[itype][jtype]) - ecoul = factor_coul * qqrd2e * qtmp*q[j]*sqrt(r2inv); - else ecoul = 0.0; + ecoul = factor_coul * qqrd2e * qtmp * q[j] * sqrt(r2inv); + else + ecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - evdwl = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; + evdwl = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; evdwl *= factor_lj; - } else evdwl = 0.0; + } else + evdwl = 0.0; } - if (evflag) ev_tally(i,j,nlocal,newton_pair, - evdwl,ecoul,fpair,delx,dely,delz); + if (evflag) ev_tally(i, j, nlocal, newton_pair, evdwl, ecoul, fpair, delx, dely, delz); } } } @@ -161,26 +162,25 @@ void PairLJCutCoulCut::compute(int eflag, int vflag) void PairLJCutCoulCut::allocate() { allocated = 1; - int n = atom->ntypes; + int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); - for (int i = 1; i <= n; i++) - for (int j = i; j <= n; j++) - setflag[i][j] = 0; + memory->create(setflag, np1, np1, "pair:setflag"); + for (int i = 1; i < np1; i++) + for (int j = i; j < np1; j++) setflag[i][j] = 0; - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, np1, np1, "pair:cutsq"); - memory->create(cut_lj,n+1,n+1,"pair:cut_lj"); - memory->create(cut_ljsq,n+1,n+1,"pair:cut_ljsq"); - memory->create(cut_coul,n+1,n+1,"pair:cut_coul"); - memory->create(cut_coulsq,n+1,n+1,"pair:cut_coulsq"); - memory->create(epsilon,n+1,n+1,"pair:epsilon"); - memory->create(sigma,n+1,n+1,"pair:sigma"); - memory->create(lj1,n+1,n+1,"pair:lj1"); - memory->create(lj2,n+1,n+1,"pair:lj2"); - memory->create(lj3,n+1,n+1,"pair:lj3"); - memory->create(lj4,n+1,n+1,"pair:lj4"); - memory->create(offset,n+1,n+1,"pair:offset"); + memory->create(cut_lj, np1, np1, "pair:cut_lj"); + memory->create(cut_ljsq, np1, np1, "pair:cut_ljsq"); + memory->create(cut_coul, np1, np1, "pair:cut_coul"); + memory->create(cut_coulsq, np1, np1, "pair:cut_coulsq"); + memory->create(epsilon, np1, np1, "pair:epsilon"); + memory->create(sigma, np1, np1, "pair:sigma"); + memory->create(lj1, np1, np1, "pair:lj1"); + memory->create(lj2, np1, np1, "pair:lj2"); + memory->create(lj3, np1, np1, "pair:lj3"); + memory->create(lj4, np1, np1, "pair:lj4"); + memory->create(offset, np1, np1, "pair:offset"); } /* ---------------------------------------------------------------------- @@ -189,16 +189,18 @@ void PairLJCutCoulCut::allocate() void PairLJCutCoulCut::settings(int narg, char **arg) { - if (narg < 1 || narg > 2) error->all(FLERR,"Illegal pair_style command"); + if (narg < 1 || narg > 2) error->all(FLERR, "Illegal pair_style command"); - cut_lj_global = utils::numeric(FLERR,arg[0],false,lmp); - if (narg == 1) cut_coul_global = cut_lj_global; - else cut_coul_global = utils::numeric(FLERR,arg[1],false,lmp); + cut_lj_global = utils::numeric(FLERR, arg[0], false, lmp); + if (narg == 1) + cut_coul_global = cut_lj_global; + else + cut_coul_global = utils::numeric(FLERR, arg[1], false, lmp); // reset cutoffs that have been explicitly set if (allocated) { - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) if (setflag[i][j]) { @@ -214,25 +216,24 @@ void PairLJCutCoulCut::settings(int narg, char **arg) void PairLJCutCoulCut::coeff(int narg, char **arg) { - if (narg < 4 || narg > 6) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg < 4 || narg > 6) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi,jlo,jhi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int ilo, ihi, jlo, jhi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); - double epsilon_one = utils::numeric(FLERR,arg[2],false,lmp); - double sigma_one = utils::numeric(FLERR,arg[3],false,lmp); + double epsilon_one = utils::numeric(FLERR, arg[2], false, lmp); + double sigma_one = utils::numeric(FLERR, arg[3], false, lmp); double cut_lj_one = cut_lj_global; double cut_coul_one = cut_coul_global; - if (narg >= 5) cut_coul_one = cut_lj_one = utils::numeric(FLERR,arg[4],false,lmp); - if (narg == 6) cut_coul_one = utils::numeric(FLERR,arg[5],false,lmp); + if (narg >= 5) cut_coul_one = cut_lj_one = utils::numeric(FLERR, arg[4], false, lmp); + if (narg == 6) cut_coul_one = utils::numeric(FLERR, arg[5], false, lmp); int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { epsilon[i][j] = epsilon_one; sigma[i][j] = sigma_one; cut_lj[i][j] = cut_lj_one; @@ -242,7 +243,7 @@ void PairLJCutCoulCut::coeff(int narg, char **arg) } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -251,10 +252,9 @@ void PairLJCutCoulCut::coeff(int narg, char **arg) void PairLJCutCoulCut::init_style() { - if (!atom->q_flag) - error->all(FLERR,"Pair style lj/cut/coul/cut requires atom attribute q"); + if (!atom->q_flag) error->all(FLERR, "Pair style lj/cut/coul/cut requires atom attribute q"); - neighbor->request(this,instance_me); + neighbor->add_request(this); } /* ---------------------------------------------------------------------- @@ -264,26 +264,26 @@ void PairLJCutCoulCut::init_style() double PairLJCutCoulCut::init_one(int i, int j) { if (setflag[i][j] == 0) { - epsilon[i][j] = mix_energy(epsilon[i][i],epsilon[j][j], - sigma[i][i],sigma[j][j]); - sigma[i][j] = mix_distance(sigma[i][i],sigma[j][j]); - cut_lj[i][j] = mix_distance(cut_lj[i][i],cut_lj[j][j]); - cut_coul[i][j] = mix_distance(cut_coul[i][i],cut_coul[j][j]); + epsilon[i][j] = mix_energy(epsilon[i][i], epsilon[j][j], sigma[i][i], sigma[j][j]); + sigma[i][j] = mix_distance(sigma[i][i], sigma[j][j]); + cut_lj[i][j] = mix_distance(cut_lj[i][i], cut_lj[j][j]); + cut_coul[i][j] = mix_distance(cut_coul[i][i], cut_coul[j][j]); } - double cut = MAX(cut_lj[i][j],cut_coul[i][j]); + double cut = MAX(cut_lj[i][j], cut_coul[i][j]); cut_ljsq[i][j] = cut_lj[i][j] * cut_lj[i][j]; cut_coulsq[i][j] = cut_coul[i][j] * cut_coul[i][j]; - lj1[i][j] = 48.0 * epsilon[i][j] * pow(sigma[i][j],12.0); - lj2[i][j] = 24.0 * epsilon[i][j] * pow(sigma[i][j],6.0); - lj3[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j],12.0); - lj4[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j],6.0); + lj1[i][j] = 48.0 * epsilon[i][j] * pow(sigma[i][j], 12.0); + lj2[i][j] = 24.0 * epsilon[i][j] * pow(sigma[i][j], 6.0); + lj3[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j], 12.0); + lj4[i][j] = 4.0 * epsilon[i][j] * pow(sigma[i][j], 6.0); if (offset_flag && (cut_lj[i][j] > 0.0)) { double ratio = sigma[i][j] / cut_lj[i][j]; - offset[i][j] = 4.0 * epsilon[i][j] * (pow(ratio,12.0) - pow(ratio,6.0)); - } else offset[i][j] = 0.0; + offset[i][j] = 4.0 * epsilon[i][j] * (pow(ratio, 12.0) - pow(ratio, 6.0)); + } else + offset[i][j] = 0.0; cut_ljsq[j][i] = cut_ljsq[i][j]; cut_coulsq[j][i] = cut_coulsq[i][j]; @@ -300,23 +300,23 @@ double PairLJCutCoulCut::init_one(int i, int j) int *type = atom->type; int nlocal = atom->nlocal; - double count[2],all[2]; + double count[2], all[2]; count[0] = count[1] = 0.0; for (int k = 0; k < nlocal; k++) { if (type[k] == i) count[0] += 1.0; if (type[k] == j) count[1] += 1.0; } - MPI_Allreduce(count,all,2,MPI_DOUBLE,MPI_SUM,world); + MPI_Allreduce(count, all, 2, MPI_DOUBLE, MPI_SUM, world); - double sig2 = sigma[i][j]*sigma[i][j]; - double sig6 = sig2*sig2*sig2; - double rc3 = cut_lj[i][j]*cut_lj[i][j]*cut_lj[i][j]; - double rc6 = rc3*rc3; - double rc9 = rc3*rc6; - etail_ij = 8.0*MY_PI*all[0]*all[1]*epsilon[i][j] * - sig6 * (sig6 - 3.0*rc6) / (9.0*rc9); - ptail_ij = 16.0*MY_PI*all[0]*all[1]*epsilon[i][j] * - sig6 * (2.0*sig6 - 3.0*rc6) / (9.0*rc9); + double sig2 = sigma[i][j] * sigma[i][j]; + double sig6 = sig2 * sig2 * sig2; + double rc3 = cut_lj[i][j] * cut_lj[i][j] * cut_lj[i][j]; + double rc6 = rc3 * rc3; + double rc9 = rc3 * rc6; + etail_ij = + 8.0 * MY_PI * all[0] * all[1] * epsilon[i][j] * sig6 * (sig6 - 3.0 * rc6) / (9.0 * rc9); + ptail_ij = 16.0 * MY_PI * all[0] * all[1] * epsilon[i][j] * sig6 * (2.0 * sig6 - 3.0 * rc6) / + (9.0 * rc9); } return cut; @@ -330,15 +330,15 @@ void PairLJCutCoulCut::write_restart(FILE *fp) { write_restart_settings(fp); - int i,j; + int i, j; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - fwrite(&setflag[i][j],sizeof(int),1,fp); + fwrite(&setflag[i][j], sizeof(int), 1, fp); if (setflag[i][j]) { - fwrite(&epsilon[i][j],sizeof(double),1,fp); - fwrite(&sigma[i][j],sizeof(double),1,fp); - fwrite(&cut_lj[i][j],sizeof(double),1,fp); - fwrite(&cut_coul[i][j],sizeof(double),1,fp); + fwrite(&epsilon[i][j], sizeof(double), 1, fp); + fwrite(&sigma[i][j], sizeof(double), 1, fp); + fwrite(&cut_lj[i][j], sizeof(double), 1, fp); + fwrite(&cut_coul[i][j], sizeof(double), 1, fp); } } } @@ -352,23 +352,23 @@ void PairLJCutCoulCut::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) for (j = i; j <= atom->ntypes; j++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][j],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][j], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][j], 1, MPI_INT, 0, world); if (setflag[i][j]) { if (me == 0) { - utils::sfread(FLERR,&epsilon[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&sigma[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_lj[i][j],sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul[i][j],sizeof(double),1,fp,nullptr,error); + utils::sfread(FLERR, &epsilon[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &sigma[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_lj[i][j], sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul[i][j], sizeof(double), 1, fp, nullptr, error); } - MPI_Bcast(&epsilon[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&sigma[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_lj[i][j],1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul[i][j],1,MPI_DOUBLE,0,world); + MPI_Bcast(&epsilon[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&sigma[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_lj[i][j], 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul[i][j], 1, MPI_DOUBLE, 0, world); } } } @@ -379,11 +379,11 @@ void PairLJCutCoulCut::read_restart(FILE *fp) void PairLJCutCoulCut::write_restart_settings(FILE *fp) { - fwrite(&cut_lj_global,sizeof(double),1,fp); - fwrite(&cut_coul_global,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); - fwrite(&tail_flag,sizeof(int),1,fp); + fwrite(&cut_lj_global, sizeof(double), 1, fp); + fwrite(&cut_coul_global, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); + fwrite(&tail_flag, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -393,17 +393,17 @@ void PairLJCutCoulCut::write_restart_settings(FILE *fp) void PairLJCutCoulCut::read_restart_settings(FILE *fp) { if (comm->me == 0) { - utils::sfread(FLERR,&cut_lj_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_coul_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&tail_flag,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &cut_lj_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_coul_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &tail_flag, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&cut_lj_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_coul_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); - MPI_Bcast(&tail_flag,1,MPI_INT,0,world); + MPI_Bcast(&cut_lj_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_coul_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&tail_flag, 1, MPI_INT, 0, world); } /* ---------------------------------------------------------------------- @@ -412,8 +412,7 @@ void PairLJCutCoulCut::read_restart_settings(FILE *fp) void PairLJCutCoulCut::write_data(FILE *fp) { - for (int i = 1; i <= atom->ntypes; i++) - fprintf(fp,"%d %g %g\n",i,epsilon[i][i],sigma[i][i]); + for (int i = 1; i <= atom->ntypes; i++) fprintf(fp, "%d %g %g\n", i, epsilon[i][i], sigma[i][i]); } /* ---------------------------------------------------------------------- @@ -424,37 +423,36 @@ void PairLJCutCoulCut::write_data_all(FILE *fp) { for (int i = 1; i <= atom->ntypes; i++) for (int j = i; j <= atom->ntypes; j++) - fprintf(fp,"%d %d %g %g %g\n",i,j,epsilon[i][j],sigma[i][j],cut_lj[i][j]); + fprintf(fp, "%d %d %g %g %g\n", i, j, epsilon[i][j], sigma[i][j], cut_lj[i][j]); } /* ---------------------------------------------------------------------- */ -double PairLJCutCoulCut::single(int i, int j, int itype, int jtype, - double rsq, - double factor_coul, double factor_lj, - double &fforce) +double PairLJCutCoulCut::single(int i, int j, int itype, int jtype, double rsq, double factor_coul, + double factor_lj, double &fforce) { - double r2inv,r6inv,forcecoul,forcelj,phicoul,philj; + double r2inv, r6inv, forcecoul, forcelj, phicoul, philj; - r2inv = 1.0/rsq; + r2inv = 1.0 / rsq; if (rsq < cut_coulsq[itype][jtype]) - forcecoul = force->qqrd2e * atom->q[i]*atom->q[j]*sqrt(r2inv); - else forcecoul = 0.0; + forcecoul = force->qqrd2e * atom->q[i] * atom->q[j] * sqrt(r2inv); + else + forcecoul = 0.0; if (rsq < cut_ljsq[itype][jtype]) { - r6inv = r2inv*r2inv*r2inv; - forcelj = r6inv * (lj1[itype][jtype]*r6inv - lj2[itype][jtype]); - } else forcelj = 0.0; - fforce = (factor_coul*forcecoul + factor_lj*forcelj) * r2inv; + r6inv = r2inv * r2inv * r2inv; + forcelj = r6inv * (lj1[itype][jtype] * r6inv - lj2[itype][jtype]); + } else + forcelj = 0.0; + fforce = (factor_coul * forcecoul + factor_lj * forcelj) * r2inv; double eng = 0.0; if (rsq < cut_coulsq[itype][jtype]) { - phicoul = force->qqrd2e * atom->q[i]*atom->q[j]*sqrt(r2inv); - eng += factor_coul*phicoul; + phicoul = force->qqrd2e * atom->q[i] * atom->q[j] * sqrt(r2inv); + eng += factor_coul * phicoul; } if (rsq < cut_ljsq[itype][jtype]) { - philj = r6inv*(lj3[itype][jtype]*r6inv-lj4[itype][jtype]) - - offset[itype][jtype]; - eng += factor_lj*philj; + philj = r6inv * (lj3[itype][jtype] * r6inv - lj4[itype][jtype]) - offset[itype][jtype]; + eng += factor_lj * philj; } return eng; @@ -465,8 +463,8 @@ double PairLJCutCoulCut::single(int i, int j, int itype, int jtype, void *PairLJCutCoulCut::extract(const char *str, int &dim) { dim = 2; - if (strcmp(str,"cut_coul") == 0) return (void *) cut_coul; - if (strcmp(str,"epsilon") == 0) return (void *) epsilon; - if (strcmp(str,"sigma") == 0) return (void *) sigma; + if (strcmp(str, "cut_coul") == 0) return (void *) cut_coul; + if (strcmp(str, "epsilon") == 0) return (void *) epsilon; + if (strcmp(str, "sigma") == 0) return (void *) sigma; return nullptr; } diff --git a/src/pair_zbl.cpp b/src/pair_zbl.cpp index 9e2f368f84..292b3e8ad0 100644 --- a/src/pair_zbl.cpp +++ b/src/pair_zbl.cpp @@ -1,4 +1,3 @@ -// clang-format off /* ---------------------------------------------------------------------- LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator https://www.lammps.org/, Sandia National Laboratories @@ -18,18 +17,18 @@ #include "pair_zbl.h" -#include - #include "atom.h" #include "comm.h" #include "error.h" #include "force.h" #include "memory.h" -#include "neighbor.h" #include "neigh_list.h" +#include "neighbor.h" #include "pair_zbl_const.h" +#include + // From J.F. Zeigler, J. P. Biersack and U. Littmark, // "The Stopping and Range of Ions in Matter" volume 1, Pergamon, 1985. @@ -38,7 +37,8 @@ using namespace PairZBLConstants; /* ---------------------------------------------------------------------- */ -PairZBL::PairZBL(LAMMPS *lmp) : Pair(lmp) { +PairZBL::PairZBL(LAMMPS *lmp) : Pair(lmp) +{ writedata = 1; } @@ -70,13 +70,13 @@ PairZBL::~PairZBL() void PairZBL::compute(int eflag, int vflag) { - int i,j,ii,jj,inum,jnum,itype,jtype; - double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,r,t,fswitch,eswitch; - int *ilist,*jlist,*numneigh,**firstneigh; + int i, j, ii, jj, inum, jnum, itype, jtype; + double xtmp, ytmp, ztmp, delx, dely, delz, evdwl, fpair; + double rsq, r, t, fswitch, eswitch; + int *ilist, *jlist, *numneigh, **firstneigh; evdwl = 0.0; - ev_init(eflag,vflag); + ev_init(eflag, vflag); double **x = atom->x; double **f = atom->f; @@ -107,7 +107,7 @@ void PairZBL::compute(int eflag, int vflag) delx = xtmp - x[j][0]; dely = ytmp - x[j][1]; delz = ztmp - x[j][2]; - rsq = delx*delx + dely*dely + delz*delz; + rsq = delx * delx + dely * dely + delz * delz; jtype = type[j]; if (rsq < cut_globalsq) { @@ -116,33 +116,30 @@ void PairZBL::compute(int eflag, int vflag) if (rsq > cut_innersq) { t = r - cut_inner; - fswitch = t*t * - (sw1[itype][jtype] + sw2[itype][jtype]*t); + fswitch = t * t * (sw1[itype][jtype] + sw2[itype][jtype] * t); fpair += fswitch; } - fpair *= -1.0/r; - f[i][0] += delx*fpair; - f[i][1] += dely*fpair; - f[i][2] += delz*fpair; + fpair *= -1.0 / r; + f[i][0] += delx * fpair; + f[i][1] += dely * fpair; + f[i][2] += delz * fpair; if (newton_pair || j < nlocal) { - f[j][0] -= delx*fpair; - f[j][1] -= dely*fpair; - f[j][2] -= delz*fpair; + f[j][0] -= delx * fpair; + f[j][1] -= dely * fpair; + f[j][2] -= delz * fpair; } if (eflag) { evdwl = e_zbl(r, itype, jtype); evdwl += sw5[itype][jtype]; if (rsq > cut_innersq) { - eswitch = t*t*t * - (sw3[itype][jtype] + sw4[itype][jtype]*t); + eswitch = t * t * t * (sw3[itype][jtype] + sw4[itype][jtype] * t); evdwl += eswitch; } } - if (evflag) ev_tally(i,j,nlocal,newton_pair, - evdwl,0.0,fpair,delx,dely,delz); + if (evflag) ev_tally(i, j, nlocal, newton_pair, evdwl, 0.0, fpair, delx, dely, delz); } } } @@ -157,26 +154,25 @@ void PairZBL::compute(int eflag, int vflag) void PairZBL::allocate() { allocated = 1; - int n = atom->ntypes; + const int np1 = atom->ntypes + 1; - memory->create(setflag,n+1,n+1,"pair:setflag"); - for (int i = 1; i <= n; i++) - for (int j = i; j <= n; j++) - setflag[i][j] = 0; + memory->create(setflag, np1, np1, "pair:setflag"); + for (int i = 1; i < np1; i++) + for (int j = i; j < np1; j++) setflag[i][j] = 0; - memory->create(cutsq,n+1,n+1,"pair:cutsq"); + memory->create(cutsq, np1, np1, "pair:cutsq"); - memory->create(z,n+1,"pair:z"); - memory->create(d1a,n+1,n+1,"pair:d1a"); - memory->create(d2a,n+1,n+1,"pair:d2a"); - memory->create(d3a,n+1,n+1,"pair:d3a"); - memory->create(d4a,n+1,n+1,"pair:d4a"); - memory->create(zze,n+1,n+1,"pair:zze"); - memory->create(sw1,n+1,n+1,"pair:sw1"); - memory->create(sw2,n+1,n+1,"pair:sw2"); - memory->create(sw3,n+1,n+1,"pair:sw3"); - memory->create(sw4,n+1,n+1,"pair:sw4"); - memory->create(sw5,n+1,n+1,"pair:sw5"); + memory->create(z, np1, "pair:z"); + memory->create(d1a, np1, np1, "pair:d1a"); + memory->create(d2a, np1, np1, "pair:d2a"); + memory->create(d3a, np1, np1, "pair:d3a"); + memory->create(d4a, np1, np1, "pair:d4a"); + memory->create(zze, np1, np1, "pair:zze"); + memory->create(sw1, np1, np1, "pair:sw1"); + memory->create(sw2, np1, np1, "pair:sw2"); + memory->create(sw3, np1, np1, "pair:sw3"); + memory->create(sw4, np1, np1, "pair:sw4"); + memory->create(sw5, np1, np1, "pair:sw5"); } /* ---------------------------------------------------------------------- @@ -185,15 +181,13 @@ void PairZBL::allocate() void PairZBL::settings(int narg, char **arg) { - if (narg != 2) error->all(FLERR,"Illegal pair_style command"); + if (narg != 2) error->all(FLERR, "Illegal pair_style command"); - cut_inner = utils::numeric(FLERR,arg[0],false,lmp); - cut_global = utils::numeric(FLERR,arg[1],false,lmp); + cut_inner = utils::numeric(FLERR, arg[0], false, lmp); + cut_global = utils::numeric(FLERR, arg[1], false, lmp); - if (cut_inner <= 0.0 ) - error->all(FLERR,"Illegal pair_style command"); - if (cut_inner > cut_global) - error->all(FLERR,"Illegal pair_style command"); + if (cut_inner <= 0.0) error->all(FLERR, "Illegal pair_style command"); + if (cut_inner > cut_global) error->all(FLERR, "Illegal pair_style command"); } /* ---------------------------------------------------------------------- @@ -205,28 +199,26 @@ void PairZBL::coeff(int narg, char **arg) { double z_one, z_two; - if (narg != 4) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (narg != 4) error->all(FLERR, "Incorrect args for pair coefficients"); if (!allocated) allocate(); - int ilo,ihi; - utils::bounds(FLERR,arg[0],1,atom->ntypes,ilo,ihi,error); + int ilo, ihi; + utils::bounds(FLERR, arg[0], 1, atom->ntypes, ilo, ihi, error); - int jlo,jhi; - utils::bounds(FLERR,arg[1],1,atom->ntypes,jlo,jhi,error); + int jlo, jhi; + utils::bounds(FLERR, arg[1], 1, atom->ntypes, jlo, jhi, error); - z_one = utils::numeric(FLERR,arg[2],false,lmp); - z_two = utils::numeric(FLERR,arg[3],false,lmp); + z_one = utils::numeric(FLERR, arg[2], false, lmp); + z_two = utils::numeric(FLERR, arg[3], false, lmp); // set flag for each i-j pair // set z-parameter only for i-i pairs int count = 0; for (int i = ilo; i <= ihi; i++) { - for (int j = MAX(jlo,i); j <= jhi; j++) { + for (int j = MAX(jlo, i); j <= jhi; j++) { if (i == j) { - if (z_one != z_two) - error->all(FLERR,"Incorrect args for pair coefficients"); + if (z_one != z_two) error->all(FLERR, "Incorrect args for pair coefficients"); z[i] = z_one; } setflag[i][j] = 1; @@ -235,7 +227,7 @@ void PairZBL::coeff(int narg, char **arg) } } - if (count == 0) error->all(FLERR,"Incorrect args for pair coefficients"); + if (count == 0) error->all(FLERR, "Incorrect args for pair coefficients"); } /* ---------------------------------------------------------------------- @@ -244,7 +236,7 @@ void PairZBL::coeff(int narg, char **arg) void PairZBL::init_style() { - neighbor->request(this,instance_me); + neighbor->add_request(this); cut_innersq = cut_inner * cut_inner; cut_globalsq = cut_global * cut_global; @@ -256,8 +248,7 @@ void PairZBL::init_style() double PairZBL::init_one(int i, int j) { - if (setflag[i][j] == 0) - set_coeff(i, j, z[i], z[j]); + if (setflag[i][j] == 0) set_coeff(i, j, z[i], z[j]); return cut_global; } @@ -272,8 +263,8 @@ void PairZBL::write_restart(FILE *fp) int i; for (i = 1; i <= atom->ntypes; i++) { - fwrite(&setflag[i][i],sizeof(int),1,fp); - if (setflag[i][i]) fwrite(&z[i],sizeof(double),1,fp); + fwrite(&setflag[i][i], sizeof(int), 1, fp); + if (setflag[i][i]) fwrite(&z[i], sizeof(double), 1, fp); } } @@ -286,20 +277,19 @@ void PairZBL::read_restart(FILE *fp) read_restart_settings(fp); allocate(); - int i,j; + int i, j; int me = comm->me; for (i = 1; i <= atom->ntypes; i++) { - if (me == 0) utils::sfread(FLERR,&setflag[i][i],sizeof(int),1,fp,nullptr,error); - MPI_Bcast(&setflag[i][i],1,MPI_INT,0,world); + if (me == 0) utils::sfread(FLERR, &setflag[i][i], sizeof(int), 1, fp, nullptr, error); + MPI_Bcast(&setflag[i][i], 1, MPI_INT, 0, world); if (setflag[i][i]) { - if (me == 0) utils::sfread(FLERR,&z[i],sizeof(double),1,fp,nullptr,error); - MPI_Bcast(&z[i],1,MPI_DOUBLE,0,world); + if (me == 0) utils::sfread(FLERR, &z[i], sizeof(double), 1, fp, nullptr, error); + MPI_Bcast(&z[i], 1, MPI_DOUBLE, 0, world); } } for (i = 1; i <= atom->ntypes; i++) - for (j = 1; j <= atom->ntypes; j++) - set_coeff(i,j,z[i],z[j]); + for (j = 1; j <= atom->ntypes; j++) set_coeff(i, j, z[i], z[j]); } /* ---------------------------------------------------------------------- @@ -308,11 +298,11 @@ void PairZBL::read_restart(FILE *fp) void PairZBL::write_restart_settings(FILE *fp) { - fwrite(&cut_global,sizeof(double),1,fp); - fwrite(&cut_inner,sizeof(double),1,fp); - fwrite(&offset_flag,sizeof(int),1,fp); - fwrite(&mix_flag,sizeof(int),1,fp); - fwrite(&tail_flag,sizeof(int),1,fp); + fwrite(&cut_global, sizeof(double), 1, fp); + fwrite(&cut_inner, sizeof(double), 1, fp); + fwrite(&offset_flag, sizeof(int), 1, fp); + fwrite(&mix_flag, sizeof(int), 1, fp); + fwrite(&tail_flag, sizeof(int), 1, fp); } /* ---------------------------------------------------------------------- @@ -323,17 +313,17 @@ void PairZBL::read_restart_settings(FILE *fp) { int me = comm->me; if (me == 0) { - utils::sfread(FLERR,&cut_global,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&cut_inner,sizeof(double),1,fp,nullptr,error); - utils::sfread(FLERR,&offset_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&mix_flag,sizeof(int),1,fp,nullptr,error); - utils::sfread(FLERR,&tail_flag,sizeof(int),1,fp,nullptr,error); + utils::sfread(FLERR, &cut_global, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &cut_inner, sizeof(double), 1, fp, nullptr, error); + utils::sfread(FLERR, &offset_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &mix_flag, sizeof(int), 1, fp, nullptr, error); + utils::sfread(FLERR, &tail_flag, sizeof(int), 1, fp, nullptr, error); } - MPI_Bcast(&cut_global,1,MPI_DOUBLE,0,world); - MPI_Bcast(&cut_inner,1,MPI_DOUBLE,0,world); - MPI_Bcast(&offset_flag,1,MPI_INT,0,world); - MPI_Bcast(&mix_flag,1,MPI_INT,0,world); - MPI_Bcast(&tail_flag,1,MPI_INT,0,world); + MPI_Bcast(&cut_global, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&cut_inner, 1, MPI_DOUBLE, 0, world); + MPI_Bcast(&offset_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&mix_flag, 1, MPI_INT, 0, world); + MPI_Bcast(&tail_flag, 1, MPI_INT, 0, world); } /* ---------------------------------------------------------------------- @@ -342,8 +332,7 @@ void PairZBL::read_restart_settings(FILE *fp) void PairZBL::write_data(FILE *fp) { - for (int i = 1; i <= atom->ntypes; i++) - fprintf(fp,"%d %g %g\n",i,z[i],z[i]); + for (int i = 1; i <= atom->ntypes; i++) fprintf(fp, "%d %g %g\n", i, z[i], z[i]); } /* ---------------------------------------------------------------------- @@ -353,33 +342,29 @@ void PairZBL::write_data(FILE *fp) void PairZBL::write_data_all(FILE *fp) { for (int i = 1; i <= atom->ntypes; i++) - for (int j = i; j <= atom->ntypes; j++) - fprintf(fp,"%d %d %g %g\n",i,j,z[i],z[j]); + for (int j = i; j <= atom->ntypes; j++) fprintf(fp, "%d %d %g %g\n", i, j, z[i], z[j]); } /* ---------------------------------------------------------------------- */ -double PairZBL::single(int /*i*/, int /*j*/, int itype, int jtype, double rsq, - double /*dummy1*/, double /*dummy2*/, - double &fforce) +double PairZBL::single(int /*i*/, int /*j*/, int itype, int jtype, double rsq, double /*dummy1*/, + double /*dummy2*/, double &fforce) { - double phi,r,t,eswitch,fswitch; + double phi, r, t, eswitch, fswitch; r = sqrt(rsq); fforce = dzbldr(r, itype, jtype); if (rsq > cut_innersq) { t = r - cut_inner; - fswitch = t*t * - (sw1[itype][jtype] + sw2[itype][jtype]*t); + fswitch = t * t * (sw1[itype][jtype] + sw2[itype][jtype] * t); fforce += fswitch; } - fforce *= -1.0/r; + fforce *= -1.0 / r; phi = e_zbl(r, itype, jtype); phi += sw5[itype][jtype]; if (rsq > cut_innersq) { - eswitch = t*t*t * - (sw3[itype][jtype] + sw4[itype][jtype]*t); + eswitch = t * t * t * (sw3[itype][jtype] + sw4[itype][jtype] * t); phi += eswitch; } @@ -390,55 +375,56 @@ double PairZBL::single(int /*i*/, int /*j*/, int itype, int jtype, double rsq, compute ZBL pair energy ------------------------------------------------------------------------- */ -double PairZBL::e_zbl(double r, int i, int j) { +double PairZBL::e_zbl(double r, int i, int j) +{ double d1aij = d1a[i][j]; double d2aij = d2a[i][j]; double d3aij = d3a[i][j]; double d4aij = d4a[i][j]; double zzeij = zze[i][j]; - double rinv = 1.0/r; + double rinv = 1.0 / r; - double sum = c1*exp(-d1aij*r); - sum += c2*exp(-d2aij*r); - sum += c3*exp(-d3aij*r); - sum += c4*exp(-d4aij*r); + double sum = c1 * exp(-d1aij * r); + sum += c2 * exp(-d2aij * r); + sum += c3 * exp(-d3aij * r); + sum += c4 * exp(-d4aij * r); - double result = zzeij*sum*rinv; + double result = zzeij * sum * rinv; return result; } - /* ---------------------------------------------------------------------- compute ZBL first derivative ------------------------------------------------------------------------- */ -double PairZBL::dzbldr(double r, int i, int j) { +double PairZBL::dzbldr(double r, int i, int j) +{ double d1aij = d1a[i][j]; double d2aij = d2a[i][j]; double d3aij = d3a[i][j]; double d4aij = d4a[i][j]; double zzeij = zze[i][j]; - double rinv = 1.0/r; + double rinv = 1.0 / r; - double e1 = exp(-d1aij*r); - double e2 = exp(-d2aij*r); - double e3 = exp(-d3aij*r); - double e4 = exp(-d4aij*r); + double e1 = exp(-d1aij * r); + double e2 = exp(-d2aij * r); + double e3 = exp(-d3aij * r); + double e4 = exp(-d4aij * r); - double sum = c1*e1; - sum += c2*e2; - sum += c3*e3; - sum += c4*e4; + double sum = c1 * e1; + sum += c2 * e2; + sum += c3 * e3; + sum += c4 * e4; - double sum_p = -c1*d1aij*e1; - sum_p -= c2*d2aij*e2; - sum_p -= c3*d3aij*e3; - sum_p -= c4*d4aij*e4; + double sum_p = -c1 * d1aij * e1; + sum_p -= c2 * d2aij * e2; + sum_p -= c3 * d3aij * e3; + sum_p -= c4 * d4aij * e4; - double result = zzeij*(sum_p - sum*rinv)*rinv; + double result = zzeij * (sum_p - sum * rinv) * rinv; return result; } @@ -447,37 +433,37 @@ double PairZBL::dzbldr(double r, int i, int j) { compute ZBL second derivative ------------------------------------------------------------------------- */ -double PairZBL::d2zbldr2(double r, int i, int j) { +double PairZBL::d2zbldr2(double r, int i, int j) +{ double d1aij = d1a[i][j]; double d2aij = d2a[i][j]; double d3aij = d3a[i][j]; double d4aij = d4a[i][j]; double zzeij = zze[i][j]; - double rinv = 1.0/r; + double rinv = 1.0 / r; - double e1 = exp(-d1aij*r); - double e2 = exp(-d2aij*r); - double e3 = exp(-d3aij*r); - double e4 = exp(-d4aij*r); + double e1 = exp(-d1aij * r); + double e2 = exp(-d2aij * r); + double e3 = exp(-d3aij * r); + double e4 = exp(-d4aij * r); - double sum = c1*e1; - sum += c2*e2; - sum += c3*e3; - sum += c4*e4; + double sum = c1 * e1; + sum += c2 * e2; + sum += c3 * e3; + sum += c4 * e4; - double sum_p = c1*e1*d1aij; - sum_p += c2*e2*d2aij; - sum_p += c3*e3*d3aij; - sum_p += c4*e4*d4aij; + double sum_p = c1 * e1 * d1aij; + sum_p += c2 * e2 * d2aij; + sum_p += c3 * e3 * d3aij; + sum_p += c4 * e4 * d4aij; - double sum_pp = c1*e1*d1aij*d1aij; - sum_pp += c2*e2*d2aij*d2aij; - sum_pp += c3*e3*d3aij*d3aij; - sum_pp += c4*e4*d4aij*d4aij; + double sum_pp = c1 * e1 * d1aij * d1aij; + sum_pp += c2 * e2 * d2aij * d2aij; + sum_pp += c3 * e3 * d3aij * d3aij; + sum_pp += c4 * e4 * d4aij * d4aij; - double result = zzeij*(sum_pp + 2.0*sum_p*rinv + - 2.0*sum*rinv*rinv)*rinv; + double result = zzeij * (sum_pp + 2.0 * sum_p * rinv + 2.0 * sum * rinv * rinv) * rinv; return result; } @@ -488,12 +474,12 @@ double PairZBL::d2zbldr2(double r, int i, int j) { void PairZBL::set_coeff(int i, int j, double zi, double zj) { - double ainv = (pow(zi,pzbl) + pow(zj,pzbl))/(a0*force->angstrom); - d1a[i][j] = d1*ainv; - d2a[i][j] = d2*ainv; - d3a[i][j] = d3*ainv; - d4a[i][j] = d4*ainv; - zze[i][j] = zi*zj*force->qqr2e*force->qelectron*force->qelectron; + double ainv = (pow(zi, pzbl) + pow(zj, pzbl)) / (a0 * force->angstrom); + d1a[i][j] = d1 * ainv; + d2a[i][j] = d2 * ainv; + d3a[i][j] = d3 * ainv; + d4a[i][j] = d4 * ainv; + zze[i][j] = zi * zj * force->qqr2e * force->qelectron * force->qelectron; d1a[j][i] = d1a[i][j]; d2a[j][i] = d2a[i][j]; @@ -529,14 +515,14 @@ void PairZBL::set_coeff(int i, int j, double zi, double zj) double fcp = dzbldr(cut_global, i, j); double fcpp = d2zbldr2(cut_global, i, j); - double swa = (-3.0*fcp + tc*fcpp)/(tc*tc); - double swb = ( 2.0*fcp - tc*fcpp)/(tc*tc*tc); - double swc = -fc + (tc/2.0)*fcp - (tc*tc/12.0)*fcpp; + double swa = (-3.0 * fcp + tc * fcpp) / (tc * tc); + double swb = (2.0 * fcp - tc * fcpp) / (tc * tc * tc); + double swc = -fc + (tc / 2.0) * fcp - (tc * tc / 12.0) * fcpp; sw1[i][j] = swa; sw2[i][j] = swb; - sw3[i][j] = swa/3.0; - sw4[i][j] = swb/4.0; + sw3[i][j] = swa / 3.0; + sw4[i][j] = swb / 4.0; sw5[i][j] = swc; sw1[j][i] = sw1[i][j]; @@ -545,4 +531,3 @@ void PairZBL::set_coeff(int i, int j, double zi, double zj) sw4[j][i] = sw4[i][j]; sw5[j][i] = sw5[i][j]; } - diff --git a/unittest/force-styles/CMakeLists.txt b/unittest/force-styles/CMakeLists.txt index 934c110b1f..85546c1510 100644 --- a/unittest/force-styles/CMakeLists.txt +++ b/unittest/force-styles/CMakeLists.txt @@ -75,6 +75,7 @@ else() set(FORCE_TEST_ENVIRONMENT PYTHONPATH=${TEST_INPUT_FOLDER}:$ENV{PYTHONPATH}) endif() list(APPEND FORCE_TEST_ENVIRONMENT "PYTHONUNBUFFERED=1") +list(APPEND FORCE_TEST_ENVIRONMENT "OMP_PROC_BIND=false") list(APPEND FORCE_TEST_ENVIRONMENT "LAMMPS_POTENTIALS=${LAMMPS_POTENTIALS_DIR}") get_property(BUILD_IS_MULTI_CONFIG GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG) if(BUILD_IS_MULTI_CONFIG) diff --git a/unittest/force-styles/tests/angle-charmm.yaml b/unittest/force-styles/tests/angle-charmm.yaml index 973e89169b..52e78abaf6 100644 --- a/unittest/force-styles/tests/angle-charmm.yaml +++ b/unittest/force-styles/tests/angle-charmm.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:23 2021 +lammps_version: 17 Feb 2022 epsilon: 1e-12 +skip_tests: prerequisites: ! | atom full angle charmm @@ -14,73 +14,73 @@ angle_coeff: ! | 2 46.1 111.3 0.0 0.000 3 40.0 120.0 35.0 2.410 4 33.0 108.5 30.0 2.163 -equilibrium: 4 1.9216075064457565 1.9425514574696887 2.0943951023931953 1.8936822384138474 +equilibrium: 4 1.9216075064457567 1.9425514574696887 2.0943951023931953 1.8936822384138476 extract: ! "" natoms: 29 -init_energy: 85.4248638845977 +init_energy: 85.42486388459771 init_stress: ! |2- - 1.8143089201050887e+02 -4.4008327668528100e+00 1.1809359848490450e+02 1.3470039754098281e+02 9.3127587748087279e+01 2.3868960580224421e+01 + 1.8143089201050884e+02 -4.4008327668528047e+00 1.1809359848490450e+02 1.3470039754098283e+02 9.3127587748087336e+01 2.3868960580224417e+01 init_forces: ! |2 - 1 3.8386618977092809e+01 9.2563644890222108e+00 -2.2416069655629478e+01 - 2 4.8047222128896552e+00 5.8908874219218736e+00 -3.6078250436995862e+00 - 3 2.6714408920784543e+00 -2.3742017076932243e-02 2.1100086635874408e+01 - 4 -1.9280446193919857e+01 -1.0907565986617040e+01 -2.0121340659982309e+01 - 5 -1.8343508172093760e+01 -4.1071023429215984e+01 1.6108594011594683e+01 - 6 2.1238309901668043e+01 5.7121253219257824e+00 -1.6787970380345595e+01 + 1 3.8386618977092809e+01 9.2563644890222072e+00 -2.2416069655629496e+01 + 2 4.8047222128896561e+00 5.8908874219218834e+00 -3.6078250436995782e+00 + 3 2.6714408920784418e+00 -2.3742017076909150e-02 2.1100086635874433e+01 + 4 -1.9280446193919854e+01 -1.0907565986617049e+01 -2.0121340659982323e+01 + 5 -1.8343508172093753e+01 -4.1071023429215998e+01 1.6108594011594683e+01 + 6 2.1238309901668035e+01 5.7121253219257753e+00 -1.6787970380345595e+01 7 -2.5311264980599468e+01 1.9532283354226724e+01 -2.4286994823128929e+01 - 8 1.0452003565543395e+01 -2.3201291666991558e+01 9.0068263361646899e+01 + 8 1.0452003565543388e+01 -2.3201291666991573e+01 9.0068263361646899e+01 9 -1.5916624143704812e+01 1.6483610301406415e+01 -4.1516194400253736e-01 - 10 1.5262370040243479e+01 1.7209374979747956e+01 -5.0097168024346068e+01 + 10 1.5262370040243503e+01 1.7209374979747970e+01 -5.0097168024346075e+01 11 -2.1025039799233362e+01 -6.8138721666064477e+00 9.3257489337892920e+00 - 12 -3.7942492100969893e+00 -1.8949256479033437e+01 7.2924357616797710e+00 - 13 2.6829248438599908e+01 -1.8477615701199301e+01 7.6270643598239811e+00 - 14 -9.1419604634794620e+00 -5.8258733174381518e+00 -3.5139934203515040e+01 - 15 -3.9745927947694284e+00 2.5196516981363281e+01 3.2110867442129567e+01 - 16 -2.9503839293712968e+00 2.5409363689785007e+01 -7.2255876751122914e+00 - 17 9.3355659152692783e-02 5.7971422477959977e-01 -3.5350080967767701e+00 - 18 7.0507994374434446e-02 7.3680637947826888e-01 -2.9901987340388825e+00 - 19 -1.8729001948214922e+01 -1.6361947190261777e+01 -3.2134590021289293e+00 - 20 1.8658493953840487e+01 1.5625140810783508e+01 6.2036577361678118e+00 - 21 1.5269813353706816e+00 1.9115283296031365e+00 -5.7126680835892021e+00 - 22 -2.4212822369319898e+01 -1.1732635537541306e+01 -7.1373318326447102e+00 - 23 2.2685841033949217e+01 9.8211072079381694e+00 1.2849999916233912e+01 - 24 -5.8307622758841404e-01 2.2664518498581661e+00 -1.3493584963979171e+00 - 25 -1.9566415223447844e+01 -1.2547949048865153e+01 -1.0241193948074248e+01 - 26 2.0149491451036258e+01 1.0281497199006987e+01 1.1590552444472165e+01 - 27 -1.2828590583680111e-01 1.0531267905268624e+00 -3.5872993954368049e-01 - 28 -2.1397316777571888e+01 -6.8536308873550515e+00 -1.0104593869135021e+01 - 29 2.1525602683408689e+01 5.8005040968281891e+00 1.0463323808678702e+01 -run_energy: 85.0418773515778 + 12 -3.7942492100969689e+00 -1.8949256479033416e+01 7.2924357616797462e+00 + 13 2.6829248438599905e+01 -1.8477615701199312e+01 7.6270643598239891e+00 + 14 -9.1419604634794709e+00 -5.8258733174381589e+00 -3.5139934203515040e+01 + 15 -3.9745927947694355e+00 2.5196516981363274e+01 3.2110867442129582e+01 + 16 -2.9503839293713172e+00 2.5409363689785017e+01 -7.2255876751122869e+00 + 17 9.3355659152699166e-02 5.7971422477959100e-01 -3.5350080967767656e+00 + 18 7.0507994374434446e-02 7.3680637947827243e-01 -2.9901987340389060e+00 + 19 -1.8729001948214929e+01 -1.6361947190261784e+01 -3.2134590021289191e+00 + 20 1.8658493953840495e+01 1.5625140810783511e+01 6.2036577361678251e+00 + 21 1.5269813353706887e+00 1.9115283296031436e+00 -5.7126680835892234e+00 + 22 -2.4212822369319909e+01 -1.1732635537541313e+01 -7.1373318326447031e+00 + 23 2.2685841033949220e+01 9.8211072079381694e+00 1.2849999916233926e+01 + 24 -5.8307622758841759e-01 2.2664518498581856e+00 -1.3493584963979277e+00 + 25 -1.9566415223447848e+01 -1.2547949048865167e+01 -1.0241193948074246e+01 + 26 2.0149491451036265e+01 1.0281497199006981e+01 1.1590552444472173e+01 + 27 -1.2828590583680111e-01 1.0531267905268855e+00 -3.5872993954368759e-01 + 28 -2.1397316777571895e+01 -6.8536308873550649e+00 -1.0104593869135021e+01 + 29 2.1525602683408696e+01 5.8005040968281794e+00 1.0463323808678709e+01 +run_energy: 85.04187735157775 run_stress: ! |2- - 1.8012121267556859e+02 -4.6946144659715401e+00 1.1788231937577407e+02 1.3413231562226755e+02 9.2660175182735685e+01 2.3291837947470942e+01 + 1.8012121267556856e+02 -4.6946144659715507e+00 1.1788231937577407e+02 1.3413231562226755e+02 9.2660175182735713e+01 2.3291837947470960e+01 run_forces: ! |2 - 1 3.8118215247385578e+01 9.3158891150979617e+00 -2.2235196779381894e+01 - 2 4.7446383048075313e+00 5.6766508464956900e+00 -3.6982594464011989e+00 - 3 3.1149110433173788e+00 -2.9235876910292546e-01 2.0771850131756278e+01 - 4 -1.9213776668483394e+01 -1.0713679638456888e+01 -1.9827377096781120e+01 - 5 -1.8462986210023516e+01 -4.0912757647333258e+01 1.6016557702839879e+01 - 6 2.1320408843036898e+01 5.6489845377932966e+00 -1.6840267466256492e+01 + 1 3.8118215247385585e+01 9.3158891150979528e+00 -2.2235196779381909e+01 + 2 4.7446383048075331e+00 5.6766508464957006e+00 -3.6982594464011900e+00 + 3 3.1149110433173663e+00 -2.9235876910289882e-01 2.0771850131756295e+01 + 4 -1.9213776668483387e+01 -1.0713679638456899e+01 -1.9827377096781134e+01 + 5 -1.8462986210023505e+01 -4.0912757647333265e+01 1.6016557702839879e+01 + 6 2.1320408843036891e+01 5.6489845377932895e+00 -1.6840267466256492e+01 7 -2.5337148538378756e+01 1.9575167714362749e+01 -2.4211425008511085e+01 - 8 1.0402500234579088e+01 -2.3124673095658373e+01 9.0001704276300842e+01 + 8 1.0402500234579081e+01 -2.3124673095658380e+01 9.0001704276300842e+01 9 -1.5935169154860102e+01 1.6504102172504812e+01 -4.0325180892868806e-01 - 10 1.5361132526764665e+01 1.6972436102402419e+01 -5.0009834334305353e+01 + 10 1.5361132526764687e+01 1.6972436102402433e+01 -5.0009834334305346e+01 11 -2.1009023103269463e+01 -6.7853788579354752e+00 9.3150254065112641e+00 - 12 -4.1242681396404217e+00 -1.8884325060764713e+01 7.5941409807812175e+00 - 13 2.6716685384920325e+01 -1.8479210646320460e+01 7.6519504974846377e+00 - 14 -8.9813963745393934e+00 -5.6081411585049104e+00 -3.4974606169627144e+01 - 15 -3.9068665424157736e+00 2.5127983108798688e+01 3.1708967596018880e+01 - 16 -2.8902838051274999e+00 2.5379491745385284e+01 -7.2873773066545091e+00 - 17 8.2426951926853897e-02 5.9981953123609699e-01 -3.5726011748455146e+00 - 18 6.2973687099251663e-02 6.3250354487009020e-01 -2.5567134127911926e+00 - 19 -1.8456670000846625e+01 -1.6104493093882169e+01 -3.3376194263865493e+00 - 20 1.8393696313747373e+01 1.5471989549012079e+01 5.8943328391777419e+00 - 21 1.4361256154637871e+00 1.7851691643692806e+00 -5.3662421470650266e+00 - 22 -2.4004457378745911e+01 -1.1572072140686995e+01 -7.2248711252066702e+00 - 23 2.2568331763282124e+01 9.7869029763177142e+00 1.2591113272271697e+01 - 24 -5.1634756740144283e-01 2.0044573777520096e+00 -1.1921659540752660e+00 - 25 -1.9528421728171214e+01 -1.2408015443757698e+01 -1.0307901340145479e+01 - 26 2.0044769295572657e+01 1.0403558066005688e+01 1.1500067294220745e+01 - 27 -1.1702126880387453e-01 9.5304786947607312e-01 -3.2276094262571320e-01 - 28 -2.1371463893292912e+01 -6.8023506048817319e+00 -1.0118342451922880e+01 - 29 2.1488485162096786e+01 5.8493027354056588e+00 1.0441103394548593e+01 + 12 -4.1242681396404004e+00 -1.8884325060764695e+01 7.5941409807811837e+00 + 13 2.6716685384920318e+01 -1.8479210646320471e+01 7.6519504974846466e+00 + 14 -8.9813963745394023e+00 -5.6081411585049210e+00 -3.4974606169627137e+01 + 15 -3.9068665424157807e+00 2.5127983108798684e+01 3.1708967596018894e+01 + 16 -2.8902838051275208e+00 2.5379491745385291e+01 -7.2873773066545056e+00 + 17 8.2426951926860337e-02 5.9981953123608811e-01 -3.5726011748455102e+00 + 18 6.2973687099255216e-02 6.3250354487009375e-01 -2.5567134127912157e+00 + 19 -1.8456670000846632e+01 -1.6104493093882176e+01 -3.3376194263865395e+00 + 20 1.8393696313747377e+01 1.5471989549012083e+01 5.8943328391777552e+00 + 21 1.4361256154637942e+00 1.7851691643692877e+00 -5.3662421470650470e+00 + 22 -2.4004457378745922e+01 -1.1572072140687002e+01 -7.2248711252066622e+00 + 23 2.2568331763282128e+01 9.7869029763177142e+00 1.2591113272271709e+01 + 24 -5.1634756740144638e-01 2.0044573777520309e+00 -1.1921659540752767e+00 + 25 -1.9528421728171217e+01 -1.2408015443757712e+01 -1.0307901340145477e+01 + 26 2.0044769295572664e+01 1.0403558066005681e+01 1.1500067294220754e+01 + 27 -1.1702126880387453e-01 9.5304786947609621e-01 -3.2276094262572208e-01 + 28 -2.1371463893292919e+01 -6.8023506048817461e+00 -1.0118342451922880e+01 + 29 2.1488485162096794e+01 5.8493027354056499e+00 1.0441103394548602e+01 ... diff --git a/unittest/force-styles/tests/angle-class2.yaml b/unittest/force-styles/tests/angle-class2.yaml index 0b50cce4f6..ae2e3ff5ee 100644 --- a/unittest/force-styles/tests/angle-class2.yaml +++ b/unittest/force-styles/tests/angle-class2.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 14 Dec 2021 -date_generated: Tue Dec 21 11:26:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 1e-12 skip_tests: prerequisites: ! | @@ -22,73 +22,73 @@ angle_coeff: ! | 1 ba 20.0 0.0 1.5 1.5 3 ba 10.0 10.0 1.5 1.5 4 ba 0.0 20.0 1.5 1.5 -equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 +equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 extract: ! "" natoms: 29 -init_energy: 46.440896837749044 +init_energy: 46.44089683774903 init_stress: ! |2- - 1.1893382158997322e+02 -8.8291447119046992e+01 -1.8868912456859972e+00 1.1299617626314146e+02 -8.5358891009896780e+00 7.6967639957246794e+00 + 1.1893382158997319e+02 -8.8291447119047007e+01 -1.8868912456860043e+00 1.1299617626314139e+02 -8.5358891009898059e+00 7.6967639957246767e+00 init_forces: ! |2 - 1 4.9843771864003834e+01 3.0925122596911816e+00 -3.5312722193312226e+01 - 2 -7.6547115157834666e-01 -6.1978334793953476e+00 -4.9838162348189323e+00 - 3 -2.0132137208074248e+01 6.1565994561526715e+01 5.8548546756498347e+01 - 4 -1.1800898073962109e+01 -2.7342191490108263e+01 3.6024091179236257e+00 - 5 -3.5756372747916700e+01 -5.0661360858658405e+01 -1.9085859271498553e+01 - 6 5.0734800121225135e+01 -1.5633459340466136e+01 -3.6451541950394720e+01 - 7 -1.8030285239813821e+01 1.7009172193091111e+01 1.5544411167675971e+00 - 8 -1.5632958318497042e+01 -2.1571227015465091e+01 7.4636601692831320e+01 - 9 -1.4606126670427546e+01 1.7088847325775880e+01 3.5265027966992157e+00 - 10 4.9412614063426892e+00 3.2891848318072718e+01 -5.8999099084298045e+01 + 1 4.9843771864003813e+01 3.0925122596912038e+00 -3.5312722193312169e+01 + 2 -7.6547115157835133e-01 -6.1978334793953787e+00 -4.9838162348189563e+00 + 3 -2.0132137208074187e+01 6.1565994561526658e+01 5.8548546756498297e+01 + 4 -1.1800898073962115e+01 -2.7342191490108249e+01 3.6024091179236541e+00 + 5 -3.5756372747916728e+01 -5.0661360858658362e+01 -1.9085859271498556e+01 + 6 5.0734800121225135e+01 -1.5633459340466121e+01 -3.6451541950394727e+01 + 7 -1.8030285239813821e+01 1.7009172193091111e+01 1.5544411167675989e+00 + 8 -1.5632958318497032e+01 -2.1571227015465091e+01 7.4636601692831306e+01 + 9 -1.4606126670427546e+01 1.7088847325775880e+01 3.5265027966992148e+00 + 10 4.9412614063426377e+00 3.2891848318072718e+01 -5.8999099084298024e+01 11 -2.0537012066379056e+01 -7.0930129287428976e+00 7.5068656204459945e+00 - 12 1.3804183606931298e+01 6.4447653590032914e+00 -2.7232856026007504e+01 - 13 3.5360349619705711e-01 9.1396982628926138e-01 4.4753951517849107e+00 - 14 9.6171168365401805e+00 -1.2052302426663841e+01 -3.9493877514992031e+00 - 15 6.4860723734536965e+00 -7.3468753785680629e+00 2.2291265160011950e+01 - 16 -2.1230106290243054e+00 1.3874285421512146e+01 6.8398804299585079e+00 - 17 3.6034624009792791e+00 -4.9831323468942506e+00 3.0333746689077179e+00 - 18 8.4504245756073892e-01 5.5042293626682808e+00 -2.1046811461460457e+01 - 19 -6.5342341140829419e+00 -7.9348302620004993e+00 8.7785874834232587e+00 - 20 5.6891916565222029e+00 2.4306008993322186e+00 1.2268223978037199e+01 - 21 7.8687847056106097e+00 9.2247825951126554e+00 -2.6147407661059020e+01 - 22 -1.3528173582118603e+01 -8.9511461518324538e+00 8.6148798736605858e+00 - 23 5.6593888765079932e+00 -2.7363644328020120e-01 1.7532527787398436e+01 - 24 -4.3228091413199312e+00 1.8218035887352222e+01 -1.0563459250035294e+01 - 25 -4.1518972409293955e+00 -1.2576945219214169e+01 1.7476216234117312e+00 - 26 8.4747063822493267e+00 -5.6410906681380535e+00 8.8158376266235621e+00 - 27 -1.9941459534406549e+00 1.7618141002760062e+01 -5.9162802776486032e+00 - 28 -4.8714180504657234e+00 -1.0506429973856317e+01 1.3714179563487131e-01 - 29 6.8655640039063783e+00 -7.1117110289037466e+00 5.7791384820137317e+00 -run_energy: 46.04254213414856 + 12 1.3804183606931208e+01 6.4447653590032559e+00 -2.7232856026007383e+01 + 13 3.5360349619706588e-01 9.1396982628928802e-01 4.4753951517848503e+00 + 14 9.6171168365402409e+00 -1.2052302426663832e+01 -3.9493877514992173e+00 + 15 6.4860723734537205e+00 -7.3468753785680603e+00 2.2291265160011921e+01 + 16 -2.1230106290242547e+00 1.3874285421512122e+01 6.8398804299585017e+00 + 17 3.6034624009792626e+00 -4.9831323468942275e+00 3.0333746689077010e+00 + 18 8.4504245756073360e-01 5.5042293626682657e+00 -2.1046811461460404e+01 + 19 -6.5342341140829223e+00 -7.9348302620004780e+00 8.7785874834232374e+00 + 20 5.6891916565221887e+00 2.4306008993322124e+00 1.2268223978037167e+01 + 21 7.8687847056105955e+00 9.2247825951126377e+00 -2.6147407661058978e+01 + 22 -1.3528173582118580e+01 -8.9511461518324378e+00 8.6148798736605734e+00 + 23 5.6593888765079843e+00 -2.7363644328020054e-01 1.7532527787398404e+01 + 24 -4.3228091413199223e+00 1.8218035887352180e+01 -1.0563459250035271e+01 + 25 -4.1518972409293831e+00 -1.2576945219214139e+01 1.7476216234117292e+00 + 26 8.4747063822493054e+00 -5.6410906681380393e+00 8.8158376266235408e+00 + 27 -1.9941459534406523e+00 1.7618141002760016e+01 -5.9162802776485890e+00 + 28 -4.8714180504657065e+00 -1.0506429973856289e+01 1.3714179563487300e-01 + 29 6.8655640039063588e+00 -7.1117110289037271e+00 5.7791384820137157e+00 +run_energy: 46.04254213414853 run_stress: ! |2- - 1.1725321346181148e+02 -8.7851127936553254e+01 -1.2820805825603960e+00 1.1164348489319656e+02 -9.3238396977559397e+00 6.5868867241338807e+00 + 1.1725321346181143e+02 -8.7851127936553269e+01 -1.2820805825604045e+00 1.1164348489319646e+02 -9.3238396977560285e+00 6.5868867241338478e+00 run_forces: ! |2 - 1 4.9310488854556048e+01 3.4204699131043999e+00 -3.4719646460390109e+01 - 2 -8.0299294685685085e-01 -6.5454065929116556e+00 -5.2863994125400326e+00 - 3 -1.9344188743451483e+01 6.1008236345827427e+01 5.7990450617574737e+01 - 4 -1.1820915021801847e+01 -2.6960419197209372e+01 3.9252515610422387e+00 - 5 -3.5905034771726200e+01 -5.0435101635947014e+01 -1.9146824911182328e+01 - 6 5.0729278972279332e+01 -1.5703691297521928e+01 -3.6490325001299325e+01 - 7 -1.8043757960499846e+01 1.7038616039733434e+01 1.5516900804512148e+00 - 8 -1.5552591757457865e+01 -2.1589081417070179e+01 7.4580844287823936e+01 - 9 -1.4632487393832747e+01 1.7116771489893083e+01 3.5369114786793467e+00 - 10 5.0177324966376649e+00 3.2655409113932286e+01 -5.8914010758009439e+01 - 11 -2.0526018243356614e+01 -7.0603095274350611e+00 7.4991583014498691e+00 - 12 1.3523522841409502e+01 6.2514718031216852e+00 -2.6685798485651077e+01 - 13 3.0043046271322960e-01 7.8431109074530148e-01 4.5328635576848786e+00 - 14 9.6740453376714228e+00 -1.1603919453433887e+01 -3.9205080570168040e+00 - 15 6.5345442098934683e+00 -7.2391735244141353e+00 2.1740136588792641e+01 - 16 -2.0494434617404407e+00 1.3825958913895089e+01 6.7881976680816249e+00 - 17 3.5873871255632257e+00 -4.9641420643094554e+00 3.0180089445086313e+00 - 18 7.9531230378610207e-01 5.2629626454507630e+00 -2.0172279025467247e+01 - 19 -6.1997999385006839e+00 -7.5645533008417640e+00 8.4605118212170112e+00 - 20 5.4044876347145818e+00 2.3015906553910015e+00 1.1711767204250236e+01 - 21 7.6462499201271452e+00 8.9238366526271982e+00 -2.5489460284469285e+01 - 22 -1.3116044133706563e+01 -8.6583255717724796e+00 8.4434021193141291e+00 - 23 5.4697942135794175e+00 -2.6551108085471875e-01 1.7046058165155156e+01 - 24 -4.2497082139356905e+00 1.7742951256065766e+01 -1.0303002556901220e+01 - 25 -3.9777181755411437e+00 -1.2246864111150519e+01 1.7323644652289971e+00 - 26 8.2274263894768342e+00 -5.4960871449152453e+00 8.5706380916722225e+00 - 27 -2.0048516565658536e+00 1.7446299537442144e+01 -5.8315780788096188e+00 - 28 -4.7894277572886974e+00 -1.0406054769833135e+01 1.3027326655161572e-01 - 29 6.7942794138545510e+00 -7.0402447676090096e+00 5.7013048122580035e+00 + 1 4.9310488854556034e+01 3.4204699131044167e+00 -3.4719646460390052e+01 + 2 -8.0299294685685418e-01 -6.5454065929116858e+00 -5.2863994125400593e+00 + 3 -1.9344188743451443e+01 6.1008236345827335e+01 5.7990450617574652e+01 + 4 -1.1820915021801859e+01 -2.6960419197209340e+01 3.9252515610422742e+00 + 5 -3.5905034771726228e+01 -5.0435101635946978e+01 -1.9146824911182321e+01 + 6 5.0729278972279346e+01 -1.5703691297521907e+01 -3.6490325001299311e+01 + 7 -1.8043757960499843e+01 1.7038616039733434e+01 1.5516900804512135e+00 + 8 -1.5552591757457833e+01 -2.1589081417070172e+01 7.4580844287823922e+01 + 9 -1.4632487393832745e+01 1.7116771489893079e+01 3.5369114786793459e+00 + 10 5.0177324966375947e+00 3.2655409113932265e+01 -5.8914010758009418e+01 + 11 -2.0526018243356610e+01 -7.0603095274350611e+00 7.4991583014498673e+00 + 12 1.3523522841409452e+01 6.2514718031216390e+00 -2.6685798485651006e+01 + 13 3.0043046271324048e-01 7.8431109074532956e-01 4.5328635576848546e+00 + 14 9.6740453376714513e+00 -1.1603919453433868e+01 -3.9205080570168072e+00 + 15 6.5345442098934887e+00 -7.2391735244141309e+00 2.1740136588792609e+01 + 16 -2.0494434617403918e+00 1.3825958913895064e+01 6.7881976680816187e+00 + 17 3.5873871255632093e+00 -4.9641420643094323e+00 3.0180089445086140e+00 + 18 7.9531230378609674e-01 5.2629626454507479e+00 -2.0172279025467198e+01 + 19 -6.1997999385006652e+00 -7.5645533008417436e+00 8.4605118212169934e+00 + 20 5.4044876347145685e+00 2.3015906553909957e+00 1.1711767204250204e+01 + 21 7.6462499201271328e+00 8.9238366526271822e+00 -2.5489460284469246e+01 + 22 -1.3116044133706540e+01 -8.6583255717724636e+00 8.4434021193141167e+00 + 23 5.4697942135794069e+00 -2.6551108085471853e-01 1.7046058165155127e+01 + 24 -4.2497082139356825e+00 1.7742951256065716e+01 -1.0303002556901196e+01 + 25 -3.9777181755411322e+00 -1.2246864111150487e+01 1.7323644652289949e+00 + 26 8.2274263894768147e+00 -5.4960871449152311e+00 8.5706380916722011e+00 + 27 -2.0048516565658518e+00 1.7446299537442094e+01 -5.8315780788096037e+00 + 28 -4.7894277572886796e+00 -1.0406054769833107e+01 1.3027326655161764e-01 + 29 6.7942794138545315e+00 -7.0402447676089874e+00 5.7013048122579857e+00 ... diff --git a/unittest/force-styles/tests/angle-class2_p6.yaml b/unittest/force-styles/tests/angle-class2_p6.yaml index 367dc2f450..065b3cb348 100644 --- a/unittest/force-styles/tests/angle-class2_p6.yaml +++ b/unittest/force-styles/tests/angle-class2_p6.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 14 Dec 2021 -date_generated: Tue Dec 21 11:26:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 5e-13 skip_tests: prerequisites: ! | @@ -22,73 +22,73 @@ angle_coeff: ! | 1 ba 20.0 0.0 1.5 1.5 3 ba 10.0 10.0 1.5 1.5 4 ba 0.0 20.0 1.5 1.5 -equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 +equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 extract: ! "" natoms: 29 -init_energy: 46.440802879647805 +init_energy: 46.44080287964778 init_stress: ! |2- - 1.1893137300688346e+02 -8.8292852846966269e+01 -1.8830369346769591e+00 1.1299640161336661e+02 -8.5357507162235464e+00 7.6984154056027378e+00 + 1.1893137300688339e+02 -8.8292852846966298e+01 -1.8830369346769484e+00 1.1299640161336652e+02 -8.5357507162236566e+00 7.6984154056027361e+00 init_forces: ! |2 - 1 4.9843888867383036e+01 3.0919808206030721e+00 -3.5311373179346681e+01 - 2 -7.6547138150424543e-01 -6.1978353410493483e+00 -4.9838177318164663e+00 - 3 -2.0133026476712903e+01 6.1564484240393824e+01 5.8546474701306153e+01 - 4 -1.1800938660819003e+01 -2.7342192898717585e+01 3.6024657641736728e+00 - 5 -3.5755844374603512e+01 -5.0659575042462862e+01 -1.9085218337836995e+01 - 6 5.0735338623572588e+01 -1.5634063045804186e+01 -3.6453557303514501e+01 - 7 -1.8030037186030640e+01 1.7008949856719713e+01 1.5544953754976136e+00 - 8 -1.5631909549634866e+01 -2.1569309751931716e+01 7.4640481484122148e+01 - 9 -1.4606116746275049e+01 1.7088845087132935e+01 3.5265010989798080e+00 - 10 4.9396801101823433e+00 3.2889776085852560e+01 -5.8999793708728561e+01 - 11 -2.0536178089795950e+01 -7.0922505905966178e+00 7.5061958159305604e+00 - 12 1.3803472075865960e+01 6.4452957521954772e+00 -2.7233422277061912e+01 - 13 3.5360433418053783e-01 9.1397190361994329e-01 4.4753960144004115e+00 - 14 9.6170274864467693e+00 -1.2052366363084635e+01 -3.9493583144003042e+00 - 15 6.4860666434559526e+00 -7.3468740092959814e+00 2.2291260899220667e+01 - 16 -2.1230180699866263e+00 1.3874295634189895e+01 6.8398950350932433e+00 - 17 3.6034623942756108e+00 -4.9831323377644736e+00 3.0333746639811334e+00 - 18 8.4504245006193557e-01 5.5042292843060157e+00 -2.1046811143441026e+01 - 19 -6.5342340222655810e+00 -7.9348301476147052e+00 8.7785873472291236e+00 - 20 5.6891915722036455e+00 2.4306008633086891e+00 1.2268223796211903e+01 - 21 7.8687833650945196e+00 9.2247809170080028e+00 -2.6147402645985622e+01 - 22 -1.3528171195048888e+01 -8.9511445243295924e+00 8.6148781007624322e+00 - 23 5.6593878299543681e+00 -2.7363639267841045e-01 1.7532524545223190e+01 - 24 -4.3228091005958014e+00 1.8218035729055110e+01 -1.0563459155791266e+01 - 25 -4.1518972082628096e+00 -1.2576945109768744e+01 1.7476216055126070e+00 - 26 8.4747063088586110e+00 -5.6410906192863681e+00 8.8158375502786583e+00 - 27 -1.9941459528172638e+00 1.7618140997642513e+01 -5.9162802759053958e+00 - 28 -4.8714180491026431e+00 -1.0506429970796459e+01 1.3714179556379100e-01 - 29 6.8655640019199069e+00 -7.1117110268460557e+00 5.7791384803416053e+00 -run_energy: 46.04245232805462 + 1 4.9843888867383015e+01 3.0919808206030872e+00 -3.5311373179346624e+01 + 2 -7.6547138150424920e-01 -6.1978353410493758e+00 -4.9838177318164902e+00 + 3 -2.0133026476712857e+01 6.1564484240393746e+01 5.8546474701306124e+01 + 4 -1.1800938660819003e+01 -2.7342192898717560e+01 3.6024657641736915e+00 + 5 -3.5755844374603534e+01 -5.0659575042462826e+01 -1.9085218337836995e+01 + 6 5.0735338623572602e+01 -1.5634063045804170e+01 -3.6453557303514508e+01 + 7 -1.8030037186030640e+01 1.7008949856719717e+01 1.5544953754976154e+00 + 8 -1.5631909549634852e+01 -2.1569309751931709e+01 7.4640481484122134e+01 + 9 -1.4606116746275049e+01 1.7088845087132931e+01 3.5265010989798085e+00 + 10 4.9396801101822838e+00 3.2889776085852553e+01 -5.8999793708728539e+01 + 11 -2.0536178089795950e+01 -7.0922505905966178e+00 7.5061958159305595e+00 + 12 1.3803472075865866e+01 6.4452957521954453e+00 -2.7233422277061791e+01 + 13 3.5360433418054760e-01 9.1397190361996983e-01 4.4753960144003520e+00 + 14 9.6170274864468333e+00 -1.2052366363084626e+01 -3.9493583144003184e+00 + 15 6.4860666434559757e+00 -7.3468740092959797e+00 2.2291260899220639e+01 + 16 -2.1230180699865731e+00 1.3874295634189869e+01 6.8398950350932370e+00 + 17 3.6034623942755939e+00 -4.9831323377644505e+00 3.0333746639811157e+00 + 18 8.4504245006193024e-01 5.5042292843059997e+00 -2.1046811143440969e+01 + 19 -6.5342340222655615e+00 -7.9348301476146830e+00 8.7785873472291005e+00 + 20 5.6891915722036313e+00 2.4306008633086833e+00 1.2268223796211871e+01 + 21 7.8687833650945063e+00 9.2247809170079869e+00 -2.6147402645985579e+01 + 22 -1.3528171195048865e+01 -8.9511445243295782e+00 8.6148781007624180e+00 + 23 5.6593878299543583e+00 -2.7363639267840956e-01 1.7532524545223161e+01 + 24 -4.3228091005957916e+00 1.8218035729055067e+01 -1.0563459155791243e+01 + 25 -4.1518972082627981e+00 -1.2576945109768713e+01 1.7476216055126050e+00 + 26 8.4747063088585897e+00 -5.6410906192863539e+00 8.8158375502786370e+00 + 27 -1.9941459528172620e+00 1.7618140997642467e+01 -5.9162802759053807e+00 + 28 -4.8714180491026253e+00 -1.0506429970796431e+01 1.3714179556379275e-01 + 29 6.8655640019198874e+00 -7.1117110268460362e+00 5.7791384803415884e+00 +run_energy: 46.042452328054594 run_stress: ! |2- - 1.1725078883087194e+02 -8.7852531332776422e+01 -1.2782508811995987e+00 1.1164371026778049e+02 -9.3237176305934248e+00 6.5885234111489295e+00 + 1.1725078883087188e+02 -8.7852531332776451e+01 -1.2782508811996294e+00 1.1164371026778038e+02 -9.3237176305935101e+00 6.5885234111489037e+00 run_forces: ! |2 - 1 4.9310604335655682e+01 3.4199456337672487e+00 -3.4718316191911107e+01 - 2 -8.0299317271452264e-01 -6.5454081333117653e+00 -5.2864006747626604e+00 - 3 -1.9345060126536442e+01 6.1006753750400470e+01 5.7988403049659411e+01 - 4 -1.1820957153105841e+01 -2.6960422682106536e+01 3.9253092142830135e+00 - 5 -3.5904516097808205e+01 -5.0433344031821314e+01 -1.9146190690682918e+01 - 6 5.0729808044888514e+01 -1.5704289267936588e+01 -3.6492333161602460e+01 - 7 -1.8043506480508537e+01 1.7038390298430201e+01 1.5517454554100727e+00 - 8 -1.5551557230614444e+01 -2.1587186230569777e+01 7.4584717878493251e+01 - 9 -1.4632477702925939e+01 1.7116769814092336e+01 3.5369096257061594e+00 - 10 5.0161578855418893e+00 3.2653366582115979e+01 -5.8914707964769292e+01 - 11 -2.0525187366514267e+01 -7.0595502886286221e+00 7.4984902661515953e+00 - 12 1.3522823846822945e+01 6.2519930281569955e+00 -2.6686365074578834e+01 - 13 3.0043118312382699e-01 7.8431307047186760e-01 4.5328641811452499e+00 - 14 9.6739544192178748e+00 -1.1603985265483198e+01 -3.9204779603734119e+00 - 15 6.5345389143893406e+00 -7.2391722622226151e+00 2.1740132205563690e+01 - 16 -2.0494503520587521e+00 1.3825967887607892e+01 6.7882109957643362e+00 - 17 3.5873870531468781e+00 -4.9641419029625879e+00 3.0180088465038910e+00 - 18 7.9531229968056927e-01 5.2629626038099762e+00 -2.0172278856982508e+01 - 19 -6.1997998900621667e+00 -7.5645532403308380e+00 8.4605117488474431e+00 - 20 5.4044875903815974e+00 2.3015906365208618e+00 1.1711767108135064e+01 - 21 7.6462488915955822e+00 8.9238353733854954e+00 -2.5489456437353834e+01 - 22 -1.3116042308945529e+01 -8.6583243315139509e+00 8.4434007553408890e+00 - 23 5.4697934173499467e+00 -2.6551104187154384e-01 1.7046055682012945e+01 - 24 -4.2497081893768893e+00 1.7742951160854016e+01 -1.0303002500248269e+01 - 25 -3.9777181560986339e+00 -1.2246864045350220e+01 1.7323644544198329e+00 - 26 8.2274263454755232e+00 -5.4960871155037951e+00 8.5706380458284350e+00 - 27 -2.0048516561480048e+00 1.7446299534047586e+01 -5.8315780776594286e+00 - 28 -4.7894277563898591e+00 -1.0406054767803472e+01 1.3027326650644638e-01 - 29 6.7942794125378638e+00 -7.0402447662441157e+00 5.7013048111529825e+00 + 1 4.9310604335655675e+01 3.4199456337672629e+00 -3.4718316191911057e+01 + 2 -8.0299317271452653e-01 -6.5454081333117946e+00 -5.2864006747626835e+00 + 3 -1.9345060126536413e+01 6.1006753750400385e+01 5.7988403049659354e+01 + 4 -1.1820957153105855e+01 -2.6960422682106511e+01 3.9253092142830441e+00 + 5 -3.5904516097808234e+01 -5.0433344031821257e+01 -1.9146190690682918e+01 + 6 5.0729808044888529e+01 -1.5704289267936559e+01 -3.6492333161602460e+01 + 7 -1.8043506480508533e+01 1.7038390298430201e+01 1.5517454554100727e+00 + 8 -1.5551557230614433e+01 -2.1587186230569756e+01 7.4584717878493237e+01 + 9 -1.4632477702925939e+01 1.7116769814092336e+01 3.5369096257061590e+00 + 10 5.0161578855418476e+00 3.2653366582115964e+01 -5.8914707964769271e+01 + 11 -2.0525187366514270e+01 -7.0595502886286194e+00 7.4984902661515953e+00 + 12 1.3522823846822874e+01 6.2519930281569565e+00 -2.6686365074578760e+01 + 13 3.0043118312383787e-01 7.8431307047189580e-01 4.5328641811452268e+00 + 14 9.6739544192179032e+00 -1.1603985265483175e+01 -3.9204779603734159e+00 + 15 6.5345389143893629e+00 -7.2391722622226151e+00 2.1740132205563661e+01 + 16 -2.0494503520587024e+00 1.3825967887607865e+01 6.7882109957643282e+00 + 17 3.5873870531468612e+00 -4.9641419029625649e+00 3.0180088465038741e+00 + 18 7.9531229968056660e-01 5.2629626038099619e+00 -2.0172278856982462e+01 + 19 -6.1997998900621516e+00 -7.5645532403308184e+00 8.4605117488474235e+00 + 20 5.4044875903815850e+00 2.3015906365208560e+00 1.1711767108135039e+01 + 21 7.6462488915955644e+00 8.9238353733854758e+00 -2.5489456437353780e+01 + 22 -1.3116042308945500e+01 -8.6583243315139331e+00 8.4434007553408730e+00 + 23 5.4697934173499361e+00 -2.6551104187154317e-01 1.7046055682012906e+01 + 24 -4.2497081893768822e+00 1.7742951160853970e+01 -1.0303002500248244e+01 + 25 -3.9777181560986214e+00 -1.2246864045350190e+01 1.7323644544198307e+00 + 26 8.2274263454755037e+00 -5.4960871155037818e+00 8.5706380458284137e+00 + 27 -2.0048516561480003e+00 1.7446299534047537e+01 -5.8315780776594144e+00 + 28 -4.7894277563898440e+00 -1.0406054767803441e+01 1.3027326650644755e-01 + 29 6.7942794125378443e+00 -7.0402447662440961e+00 5.7013048111529665e+00 ... diff --git a/unittest/force-styles/tests/angle-cosine.yaml b/unittest/force-styles/tests/angle-cosine.yaml index 3b80dfe647..5a59fcce86 100644 --- a/unittest/force-styles/tests/angle-cosine.yaml +++ b/unittest/force-styles/tests/angle-cosine.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:23 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full angle cosine @@ -17,7 +18,7 @@ angle_coeff: ! | equilibrium: 4 3.141592653589793 3.141592653589793 3.141592653589793 3.141592653589793 extract: ! "" natoms: 29 -init_energy: 1347.86708569396 +init_energy: 1347.8670856939623 init_stress: ! |2- 9.7042018787767176e+01 -4.8524910053092775e+01 -4.8517108734674437e+01 2.1991310128767722e+02 1.5350601447035655e+02 4.9763634294547245e+01 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 -1.3169752428031160e+01 1.0811335053602835e+02 -3.6826995619636030e+01 28 -2.8796447607995553e+01 -6.4642561032416026e+01 1.5016412228095177e+00 29 4.1966200036026713e+01 -4.3470789503612323e+01 3.5325354396826512e+01 -run_energy: 1345.58352455998 +run_energy: 1345.583524559977 run_stress: ! |2- 9.6442128885179770e+01 -4.8453952330886217e+01 -4.7988176554293645e+01 2.1952791027456863e+02 1.5268865805166467e+02 4.9751785588281081e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-cosine_delta.yaml b/unittest/force-styles/tests/angle-cosine_delta.yaml index 1141e4ceff..e56a51c9f0 100644 --- a/unittest/force-styles/tests/angle-cosine_delta.yaml +++ b/unittest/force-styles/tests/angle-cosine_delta.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:23 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full angle cosine/delta @@ -14,73 +15,73 @@ angle_coeff: ! | 2 45.0 111.0 3 50.0 120.0 4 100.0 108.5 -equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 +equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 extract: ! "" natoms: 29 -init_energy: 20.6509813301781 +init_energy: 20.65098133017812 init_stress: ! |2- - 4.0957903125808464e+01 -2.2499632589286239e+01 -1.8458270536522210e+01 3.4849378298981229e+01 -4.9327943096382150e+00 -2.6124108916945312e+00 + 4.0957903125808471e+01 -2.2499632589286236e+01 -1.8458270536522217e+01 3.4849378298981264e+01 -4.9327943096381759e+00 -2.6124108916945294e+00 init_forces: ! |2 - 1 1.6023996455832314e+01 2.4226311046592235e+00 -1.8589204266697926e+01 - 2 -9.3711866901465601e-02 -7.5876216223296211e-01 -6.1013759002635126e-01 - 3 -6.0380408211030923e-01 2.6993032298913725e+01 2.7951913775716804e+01 - 4 -4.3564633502451349e+00 -1.0062417183984063e+01 2.1642186242701555e+00 - 5 -1.5386439746171837e+01 -2.3440313238754001e+01 -1.0067874149174443e+01 - 6 9.6873286040902009e+00 6.5740743013877889e-02 -2.6313308270088607e+00 + 1 1.6023996455832325e+01 2.4226311046592137e+00 -1.8589204266697958e+01 + 2 -9.3711866901463381e-02 -7.5876216223294790e-01 -6.1013759002633705e-01 + 3 -6.0380408211033587e-01 2.6993032298913775e+01 2.7951913775716850e+01 + 4 -4.3564633502451269e+00 -1.0062417183984081e+01 2.1642186242701338e+00 + 5 -1.5386439746171822e+01 -2.3440313238754023e+01 -1.0067874149174445e+01 + 6 9.6873286040901903e+00 6.5740743013867231e-02 -2.6313308270088624e+00 7 -4.1923658452230708e+00 3.7873664481235689e+00 -9.2297211491112741e-01 - 8 -4.1328674241018017e+00 -1.3752082356191012e+01 9.4169257319147466e+00 + 8 -4.1328674241018124e+00 -1.3752082356191019e+01 9.4169257319147519e+00 9 -5.2849046978682424e+00 5.1551127779597277e+00 -6.0440022931290430e-02 - 10 8.5785584536205288e+00 1.9092658049053338e+01 -1.3500832217121994e+01 + 10 8.5785584536205555e+00 1.9092658049053345e+01 -1.3500832217122007e+01 11 -8.2548956740792931e+00 -3.8384442674446007e+00 4.3703985032254611e+00 - 12 -2.2390516462227898e+00 -2.4339015686808949e+00 -5.7125783103934324e+00 - 13 7.0748633959584506e-01 1.7495942830019429e+00 8.1749690284176868e-01 - 14 5.0293855034635966e+00 -4.3347315249911311e+00 -2.2794877131015276e+00 - 15 4.2836129602031878e+00 -2.6803643297135773e+00 7.8342386854077528e+00 - 16 -1.6475295059196176e+00 4.5975354658004237e+00 4.3681254253354007e-01 - 17 1.8816655220378866e+00 -2.5626545385335806e+00 1.3828524454567201e+00 - 18 1.6064693296025112e-01 1.6787555240920562e+00 -6.8129331975319971e+00 - 19 -1.9670041679005834e+00 -2.4504879220906073e+00 2.9176882347101909e+00 - 20 1.8063572349403323e+00 7.7173239799855109e-01 3.8952449628218062e+00 - 21 2.3714039975200185e+00 2.9686059791249670e+00 -8.8717809550958471e+00 - 22 -4.2227815913111986e+00 -2.8790902397071338e+00 3.1362978814995550e+00 - 23 1.8513775937911801e+00 -8.9515739417833140e-02 5.7354830735962921e+00 - 24 -1.4568411370574417e+00 5.6628278324597723e+00 -3.3714304805753397e+00 - 25 -1.1685952378028404e+00 -3.9152363566022146e+00 6.4031275969728974e-01 - 26 2.6254363748602820e+00 -1.7475914758575577e+00 2.7311177208780499e+00 - 27 -6.3244441950917540e-01 5.1918732409438526e+00 -1.7685243510997071e+00 - 28 -1.3828773692511795e+00 -3.1042973063575339e+00 7.2112563744889890e-02 - 29 2.0153217887603549e+00 -2.0875759345863187e+00 1.6964117873548172e+00 -run_energy: 20.5727973982101 + 12 -2.2390516462227508e+00 -2.4339015686808576e+00 -5.7125783103934751e+00 + 13 7.0748633959583906e-01 1.7495942830019229e+00 8.1749690284178111e-01 + 14 5.0293855034635815e+00 -4.3347315249911471e+00 -2.2794877131015205e+00 + 15 4.2836129602031709e+00 -2.6803643297135835e+00 7.8342386854077670e+00 + 16 -1.6475295059196460e+00 4.5975354658004379e+00 4.3681254253354895e-01 + 17 1.8816655220378973e+00 -2.5626545385335930e+00 1.3828524454567255e+00 + 18 1.6064693296025290e-01 1.6787555240920624e+00 -6.8129331975320220e+00 + 19 -1.9670041679005905e+00 -2.4504879220906162e+00 2.9176882347102016e+00 + 20 1.8063572349403376e+00 7.7173239799855375e-01 3.8952449628218204e+00 + 21 2.3714039975200247e+00 2.9686059791249759e+00 -8.8717809550958702e+00 + 22 -4.2227815913112092e+00 -2.8790902397071427e+00 3.1362978814995639e+00 + 23 1.8513775937911845e+00 -8.9515739417833418e-02 5.7354830735963063e+00 + 24 -1.4568411370574479e+00 5.6628278324597936e+00 -3.3714304805753512e+00 + 25 -1.1685952378028448e+00 -3.9152363566022288e+00 6.4031275969729240e-01 + 26 2.6254363748602927e+00 -1.7475914758575648e+00 2.7311177208780588e+00 + 27 -6.3244441950917718e-01 5.1918732409438757e+00 -1.7685243510997146e+00 + 28 -1.3828773692511866e+00 -3.1042973063575481e+00 7.2112563744890223e-02 + 29 2.0153217887603638e+00 -2.0875759345863276e+00 1.6964117873548243e+00 +run_energy: 20.572797398210106 run_stress: ! |2- - 4.0414601145881797e+01 -2.2259720000355941e+01 -1.8154881145525859e+01 3.4356097430708736e+01 -5.1760682620031746e+00 -3.0219001073831366e+00 + 4.0414601145881797e+01 -2.2259720000355955e+01 -1.8154881145525852e+01 3.4356097430708779e+01 -5.1760682620031364e+00 -3.0219001073831251e+00 run_forces: ! |2 - 1 1.5854493147994463e+01 2.5625041903632990e+00 -1.8403707584219074e+01 - 2 -1.0778147157154860e-01 -8.7954374413254754e-01 -7.1033263283978343e-01 - 3 -3.5903740231366399e-01 2.6747382244473819e+01 2.7776094765308599e+01 - 4 -4.3667455132583095e+00 -9.9043336720964916e+00 2.2554137013680173e+00 - 5 -1.5435306686274910e+01 -2.3368620551346389e+01 -1.0071205010683155e+01 - 6 9.7004722937708081e+00 2.8185574443378769e-02 -2.6469111215932317e+00 + 1 1.5854493147994468e+01 2.5625041903632799e+00 -1.8403707584219106e+01 + 2 -1.0778147157154638e-01 -8.7954374413252623e-01 -7.1033263283976922e-01 + 3 -3.5903740231368531e-01 2.6747382244473858e+01 2.7776094765308645e+01 + 4 -4.3667455132582980e+00 -9.9043336720965058e+00 2.2554137013679947e+00 + 5 -1.5435306686274892e+01 -2.3368620551346410e+01 -1.0071205010683158e+01 + 6 9.7004722937707939e+00 2.8185574443369887e-02 -2.6469111215932326e+00 7 -4.2051376166149819e+00 3.8059875922956321e+00 -9.2948254913796591e-01 - 8 -4.0811558306056366e+00 -1.3725195219352727e+01 9.4305267102762294e+00 + 8 -4.0811558306056437e+00 -1.3725195219352738e+01 9.4305267102762365e+00 9 -5.3018040121457650e+00 5.1712375236873847e+00 -5.5170438746634645e-02 - 10 8.5884631851414461e+00 1.8977169595422655e+01 -1.3503733846157104e+01 + 10 8.5884631851414728e+00 1.8977169595422669e+01 -1.3503733846157115e+01 11 -8.2489793835708181e+00 -3.8307795657532537e+00 4.3670355271621792e+00 - 12 -2.2854196014067192e+00 -2.5730964210485894e+00 -5.5327026624884059e+00 - 13 6.8857552776933595e-01 1.7099649678302427e+00 8.4476951940004152e-01 - 14 5.0388676050555610e+00 -4.1380632752237574e+00 -2.2619786920581975e+00 - 15 4.2713089863647529e+00 -2.6164691252678391e+00 7.6327855841331669e+00 - 16 -1.6264161996020330e+00 4.5902884407035538e+00 4.2906258286847176e-01 - 17 1.8756029712680160e+00 -2.5566185549983746e+00 1.3795361474068404e+00 - 18 1.5949074618033343e-01 1.6020315457790026e+00 -6.4757984092122172e+00 - 19 -1.8652368265982293e+00 -2.3286173150011660e+00 2.7801057275919874e+00 - 20 1.7057460804178959e+00 7.2658576922216334e-01 3.6956926816202298e+00 - 21 2.3015994659382839e+00 2.8609989652412136e+00 -8.6002184142673883e+00 - 22 -4.0843967543541453e+00 -2.7748751066344628e+00 3.0465239349836288e+00 - 23 1.7827972884158614e+00 -8.6123858606750758e-02 5.5536944792837595e+00 - 24 -1.4105671680157137e+00 5.4757757163247867e+00 -3.2567653472769451e+00 - 25 -1.1213719131694582e+00 -3.7848791001392357e+00 6.1939772997236853e-01 - 26 2.5319390811851719e+00 -1.6908966161855510e+00 2.6373676173045766e+00 - 27 -6.3028932344593258e-01 5.1333019072248991e+00 -1.7384473964198532e+00 - 28 -1.3620336377103737e+00 -3.0692701554272013e+00 6.6735136389115601e-02 - 29 1.9923229611563062e+00 -2.0640317517976978e+00 1.6717122600307377e+00 + 12 -2.2854196014066837e+00 -2.5730964210485521e+00 -5.5327026624884477e+00 + 13 6.8857552776933151e-01 1.7099649678302227e+00 8.4476951940005041e-01 + 14 5.0388676050555423e+00 -4.1380632752237698e+00 -2.2619786920581912e+00 + 15 4.2713089863647395e+00 -2.6164691252678471e+00 7.6327855841331855e+00 + 16 -1.6264161996020632e+00 4.5902884407035716e+00 4.2906258286847709e-01 + 17 1.8756029712680284e+00 -2.5566185549983906e+00 1.3795361474068475e+00 + 18 1.5949074618033343e-01 1.6020315457790089e+00 -6.4757984092122420e+00 + 19 -1.8652368265982364e+00 -2.3286173150011749e+00 2.7801057275919980e+00 + 20 1.7057460804179030e+00 7.2658576922216600e-01 3.6956926816202440e+00 + 21 2.3015994659382928e+00 2.8609989652412211e+00 -8.6002184142674114e+00 + 22 -4.0843967543541595e+00 -2.7748751066344699e+00 3.0465239349836377e+00 + 23 1.7827972884158667e+00 -8.6123858606751036e-02 5.5536944792837737e+00 + 24 -1.4105671680157181e+00 5.4757757163248080e+00 -3.2567653472769562e+00 + 25 -1.1213719131694626e+00 -3.7848791001392499e+00 6.1939772997237075e-01 + 26 2.5319390811851807e+00 -1.6908966161855581e+00 2.6373676173045855e+00 + 27 -6.3028932344593613e-01 5.1333019072249222e+00 -1.7384473964198608e+00 + 28 -1.3620336377103808e+00 -3.0692701554272155e+00 6.6735136389115879e-02 + 29 1.9923229611563169e+00 -2.0640317517977067e+00 1.6717122600307448e+00 ... diff --git a/unittest/force-styles/tests/angle-cosine_shift.yaml b/unittest/force-styles/tests/angle-cosine_shift.yaml index 507f75e70e..786deddb66 100644 --- a/unittest/force-styles/tests/angle-cosine_shift.yaml +++ b/unittest/force-styles/tests/angle-cosine_shift.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:23 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 1e-12 +skip_tests: prerequisites: ! | atom full angle cosine/shift @@ -17,7 +18,7 @@ angle_coeff: ! | equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138474 extract: ! "" natoms: 29 -init_energy: -2039.67450933491 +init_energy: -2039.6745093349107 init_stress: ! |2- 2.2236590310678018e+01 -2.1731920007845627e+01 -5.0467030283239134e-01 2.2818792439800895e+01 -6.9536967934807379e+00 -2.1412469755446228e-01 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 -7.1800548840952522e-02 5.8942625899320822e-01 -2.0077814766093691e-01 28 -1.5699617393892926e-01 -3.5242662198670610e-01 8.1868406068466293e-03 29 2.2879672277988178e-01 -2.3699963700650206e-01 1.9259130705409028e-01 -run_energy: -2039.70992482657 +run_energy: -2039.7099248265658 run_stress: ! |2- 2.1884369028041654e+01 -2.1572961501206787e+01 -3.1140752683487311e-01 2.2503542416936284e+01 -7.1010323713779107e+00 -4.7667733522911088e-01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-cosine_shift_exp.yaml b/unittest/force-styles/tests/angle-cosine_shift_exp.yaml index f237af9bb2..86128da693 100644 --- a/unittest/force-styles/tests/angle-cosine_shift_exp.yaml +++ b/unittest/force-styles/tests/angle-cosine_shift_exp.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:24 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full angle cosine/shift/exp @@ -50,7 +51,7 @@ init_forces: ! |2 27 -1.6606843149042227e-01 1.3632917281328529e+00 -4.6438241208243458e-01 28 -3.6311851060900069e-01 -8.1513215809039241e-01 1.8935451056965480e-02 29 5.2918694209942296e-01 -5.4815957004246063e-01 4.4544696102546910e-01 -run_energy: -2037.80459205009 +run_energy: -2037.8045920500874 run_stress: ! |2- 3.0879668883081692e+01 -4.0694932235648714e+01 9.8152633525670350e+00 2.4448196341774814e+01 -4.5553409231643682e+00 5.0039677219877552e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-cosine_squared.yaml b/unittest/force-styles/tests/angle-cosine_squared.yaml index ad00a9e357..9f3ceef385 100644 --- a/unittest/force-styles/tests/angle-cosine_squared.yaml +++ b/unittest/force-styles/tests/angle-cosine_squared.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:24 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full angle cosine/squared @@ -14,73 +15,73 @@ angle_coeff: ! | 2 45.0 111.0 3 50.0 120.0 4 100.0 108.5 -equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 +equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 extract: ! "" natoms: 29 -init_energy: 36.0116244857696 +init_energy: 36.01162448576962 init_stress: ! |2- - 8.2725682858254814e+01 -6.8273473783801748e+01 -1.4452209074453092e+01 7.7211820652748884e+01 -2.5730361871697109e+01 -4.8550526943318175e+00 + 8.2725682858254856e+01 -6.8273473783801762e+01 -1.4452209074453098e+01 7.7211820652748969e+01 -2.5730361871697024e+01 -4.8550526943318051e+00 init_forces: ! |2 - 1 3.9967364035766614e+01 8.6912955121737934e+00 -3.1895072718403561e+01 - 2 -9.6870113058109242e-01 -7.8433371215415635e+00 -6.3070024406835765e+00 - 3 -9.2887870880926160e-01 5.3520449092007297e+01 5.1945694004505512e+01 - 4 -1.3446595520418755e+01 -2.2181069771530421e+01 1.0187597408474065e+01 - 5 -3.9879387313832964e+01 -4.8090587210852910e+01 -2.2283342123406275e+01 - 6 3.5485163529718072e+01 -5.1574456061476726e+00 -1.9921134582499548e+01 + 1 3.9967364035766622e+01 8.6912955121737685e+00 -3.1895072718403618e+01 + 2 -9.6870113058108842e-01 -7.8433371215415324e+00 -6.3070024406835508e+00 + 3 -9.2887870880929801e-01 5.3520449092007375e+01 5.1945694004505597e+01 + 4 -1.3446595520418740e+01 -2.2181069771530449e+01 1.0187597408474025e+01 + 5 -3.9879387313832936e+01 -4.8090587210852945e+01 -2.2283342123406275e+01 + 6 3.5485163529718058e+01 -5.1574456061476903e+00 -1.9921134582499548e+01 7 -1.3113357770588081e+01 1.1704818642812134e+01 -2.8585672059625198e+00 - 8 -7.5834275795270720e+00 -2.7651000658863325e+01 5.5534056932796943e+01 + 8 -7.5834275795270933e+00 -2.7651000658863346e+01 5.5534056932796958e+01 9 -1.3472959118352961e+01 1.3914938083600443e+01 -3.4218403222459060e-01 - 10 1.2247520733235257e+01 4.1033325862807835e+01 -5.0764387285481298e+01 + 10 1.2247520733235303e+01 4.1033325862807864e+01 -5.0764387285481320e+01 11 -1.9071008591398073e+01 -6.9550786949759864e+00 8.9310415097292459e+00 - 12 -9.1828648227777592e+00 -9.9772460049552834e+00 -8.2675858964899156e+00 - 13 2.5145600252057134e+00 6.3654259163401878e+00 -1.8817284503284260e-01 - 14 1.4059070105311534e+01 -8.7509516574437978e+00 -6.1079079436202699e+00 - 15 1.1315677074901217e+01 -5.6933727403424861e+00 1.6802631741136203e+01 - 16 7.2828609161904678e-01 8.8805455458996914e+00 4.5572456695616639e+00 - 17 1.3295389605285770e+00 -1.8107091889879334e+00 9.7708980760073227e-01 - 18 1.4133855043441645e-01 1.4769835186809783e+00 -5.9940771018886343e+00 - 19 -1.7305871495119738e+00 -2.1559603061393431e+00 2.5670071511139465e+00 - 20 1.5892485990775573e+00 6.7897678745836465e-01 3.4270699507746878e+00 - 21 3.1048427588597933e+00 3.8867501226417454e+00 -1.1615686270844733e+01 - 22 -5.5288229503451953e+00 -3.7695485426384652e+00 4.1063065497000011e+00 - 23 2.4239801914854020e+00 -1.1720158000328018e-01 7.5093797211447315e+00 - 24 -1.1665841097451561e+00 4.5345815666033644e+00 -2.6997159303819025e+00 - 25 -9.3576753186569328e-01 -3.1351754170904935e+00 5.1273860390755299e-01 - 26 2.1023516416108494e+00 -1.3994061495128705e+00 2.1869773264743495e+00 - 27 -2.5470038587839250e-01 2.0908906413094188e+00 -7.1222675189387996e-01 - 28 -5.5691755465898818e-01 -1.2501742404876248e+00 2.9041441818330599e-02 - 29 8.1161794053738068e-01 -8.4071640082179400e-01 6.8318531007554939e-01 -run_energy: 35.7964731709877 + 12 -9.1828648227776988e+00 -9.9772460049552336e+00 -8.2675858964899867e+00 + 13 2.5145600252057023e+00 6.3654259163401594e+00 -1.8817284503281773e-01 + 14 1.4059070105311509e+01 -8.7509516574438209e+00 -6.1079079436202601e+00 + 15 1.1315677074901195e+01 -5.6933727403424967e+00 1.6802631741136228e+01 + 16 7.2828609161899882e-01 8.8805455458997216e+00 4.5572456695616728e+00 + 17 1.3295389605285957e+00 -1.8107091889879587e+00 9.7708980760074582e-01 + 18 1.4133855043441823e-01 1.4769835186809903e+00 -5.9940771018886831e+00 + 19 -1.7305871495119884e+00 -2.1559603061393608e+00 2.5670071511139674e+00 + 20 1.5892485990775702e+00 6.7897678745837042e-01 3.4270699507747162e+00 + 21 3.1048427588598053e+00 3.8867501226417613e+00 -1.1615686270844780e+01 + 22 -5.5288229503452175e+00 -3.7695485426384807e+00 4.1063065497000180e+00 + 23 2.4239801914854122e+00 -1.1720158000328063e-01 7.5093797211447626e+00 + 24 -1.1665841097451679e+00 4.5345815666034062e+00 -2.6997159303819274e+00 + 25 -9.3576753186570205e-01 -3.1351754170905228e+00 5.1273860390755788e-01 + 26 2.1023516416108698e+00 -1.3994061495128833e+00 2.1869773264743695e+00 + 27 -2.5470038587839849e-01 2.0908906413094668e+00 -7.1222675189389639e-01 + 28 -5.5691755465900084e-01 -1.2501742404876537e+00 2.9041441818331265e-02 + 29 8.1161794053739933e-01 -8.4071640082181331e-01 6.8318531007556516e-01 +run_energy: 35.79647317098771 run_stress: ! |2- - 8.1386079163985897e+01 -6.7672385446129056e+01 -1.3713693717856859e+01 7.5931272732679375e+01 -2.6246397151461188e+01 -5.8523230432862601e+00 + 8.1386079163985940e+01 -6.7672385446129070e+01 -1.3713693717856865e+01 7.5931272732679474e+01 -2.6246397151461110e+01 -5.8523230432862299e+00 run_forces: ! |2 - 1 3.9504298737934299e+01 9.0362064390205923e+00 -3.1339457751434480e+01 - 2 -1.0002265079899280e+00 -8.1563440981107718e+00 -6.5866597501694137e+00 - 3 -2.9707237672744302e-01 5.2915623881067980e+01 5.1462135248962241e+01 - 4 -1.3474759165646581e+01 -2.1796354081389847e+01 1.0404041775592727e+01 - 5 -3.9969510582025805e+01 -4.7883964205194445e+01 -2.2295653940762463e+01 - 6 3.5513144692452883e+01 -5.2230478544001331e+00 -1.9967331414759983e+01 + 1 3.9504298737934313e+01 9.0362064390205674e+00 -3.1339457751434537e+01 + 2 -1.0002265079899235e+00 -8.1563440981107398e+00 -6.5866597501693889e+00 + 3 -2.9707237672747233e-01 5.2915623881068072e+01 5.1462135248962333e+01 + 4 -1.3474759165646567e+01 -2.1796354081389875e+01 1.0404041775592695e+01 + 5 -3.9969510582025791e+01 -4.7883964205194495e+01 -2.2295653940762470e+01 + 6 3.5513144692452862e+01 -5.2230478544001508e+00 -1.9967331414759990e+01 7 -1.3141080293140208e+01 1.1737017796016362e+01 -2.8719233967504918e+00 - 8 -7.5072163530686016e+00 -2.7612742492512091e+01 5.5531252764148959e+01 + 8 -7.5072163530686158e+00 -2.7612742492512112e+01 5.5531252764148974e+01 9 -1.3496615614426194e+01 1.3939678288256896e+01 -3.3102772174179584e-01 - 10 1.2306280437647038e+01 4.0751132927235759e+01 -5.0707025556664895e+01 + 10 1.2306280437647091e+01 4.0751132927235773e+01 -5.0707025556664917e+01 11 -1.9057013299568268e+01 -6.9239381290868431e+00 8.9185294031013740e+00 - 12 -9.2656690702987667e+00 -1.0263709057962135e+01 -7.8624630945648750e+00 - 13 2.4489502984114528e+00 6.2284887545653573e+00 -8.8034212951717095e-02 - 14 1.4050613823675080e+01 -8.2707042101779802e+00 -6.0540825820707997e+00 - 15 1.1284464526661036e+01 -5.5287408576449808e+00 1.6299463854690750e+01 - 16 7.8869229788968109e-01 8.8407924519403771e+00 4.5226970079595503e+00 - 17 1.3127184482203083e+00 -1.7893955516240998e+00 9.6553936741530322e-01 - 18 1.2694956105094679e-01 1.2751722153999723e+00 -5.1545565105565174e+00 - 19 -1.4846968851065028e+00 -1.8535321439652668e+00 2.2128825320928631e+00 - 20 1.3577473240555560e+00 5.7835992856529450e-01 2.9416739784636539e+00 - 21 2.9244787860493995e+00 3.6352659652262287e+00 -1.0927678024393749e+01 - 22 -5.1895978704720935e+00 -3.5257644330904849e+00 3.8710622844172722e+00 - 23 2.2651190844226941e+00 -1.0950153213574376e-01 7.0566157399764782e+00 - 24 -1.0411087961103460e+00 4.0415481427544702e+00 -2.4037464775633905e+00 - 25 -8.2768762397509377e-01 -2.7935515297939277e+00 4.5714842187279736e-01 - 26 1.8687964200854397e+00 -1.2479966129605424e+00 1.9465980556905931e+00 - 27 -2.3770330946966578e-01 1.9359478428067436e+00 -6.5562900876955288e-01 - 28 -5.1370135722491139e-01 -1.1575378709264035e+00 2.5153324043681036e-02 - 29 7.5140466669457717e-01 -7.7840997188034011e-01 6.3047568472587190e-01 + 12 -9.2656690702987063e+00 -1.0263709057962082e+01 -7.8624630945649550e+00 + 13 2.4489502984114413e+00 6.2284887545653271e+00 -8.8034212951693114e-02 + 14 1.4050613823675054e+01 -8.2707042101780051e+00 -6.0540825820707909e+00 + 15 1.1284464526661015e+01 -5.5287408576449932e+00 1.6299463854690782e+01 + 16 7.8869229788963136e-01 8.8407924519404091e+00 4.5226970079595601e+00 + 17 1.3127184482203269e+00 -1.7893955516241253e+00 9.6553936741531721e-01 + 18 1.2694956105094768e-01 1.2751722153999840e+00 -5.1545565105565654e+00 + 19 -1.4846968851065168e+00 -1.8535321439652841e+00 2.2128825320928840e+00 + 20 1.3577473240555691e+00 5.7835992856529994e-01 2.9416739784636818e+00 + 21 2.9244787860494128e+00 3.6352659652262442e+00 -1.0927678024393799e+01 + 22 -5.1895978704721166e+00 -3.5257644330905000e+00 3.8710622844172891e+00 + 23 2.2651190844227038e+00 -1.0950153213574421e-01 7.0566157399765093e+00 + 24 -1.0411087961103569e+00 4.0415481427545128e+00 -2.4037464775634154e+00 + 25 -8.2768762397510254e-01 -2.7935515297939570e+00 4.5714842187280236e-01 + 26 1.8687964200854594e+00 -1.2479966129605558e+00 1.9465980556906133e+00 + 27 -2.3770330946967155e-01 1.9359478428067920e+00 -6.5562900876956920e-01 + 28 -5.1370135722492427e-01 -1.1575378709264323e+00 2.5153324043681646e-02 + 29 7.5140466669459582e-01 -7.7840997188035954e-01 6.3047568472588755e-01 ... diff --git a/unittest/force-styles/tests/angle-cross.yaml b/unittest/force-styles/tests/angle-cross.yaml index 5e5db1d8cb..61ae6c4748 100644 --- a/unittest/force-styles/tests/angle-cross.yaml +++ b/unittest/force-styles/tests/angle-cross.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:24 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full angle cross @@ -17,7 +18,7 @@ angle_coeff: ! | equilibrium: 4 1.8675022996339325 1.911135530933791 1.7139133254584316 1.7435839227423353 extract: ! "" natoms: 29 -init_energy: -138.932277153618 +init_energy: -138.93227715361755 init_stress: ! |- -4.2805178950841440e+02 -6.8931627675603272e+02 -1.3391464673179194e+03 1.7315796064284467e+02 -4.7373177498509762e+01 -1.2493656046964831e+02 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 4.7585743845211717e+01 1.8785871750636648e+01 2.1506067119647888e+01 28 -4.9785651292999155e+01 1.9503981519706528e+00 -2.8387090726034970e+01 29 2.1999074477874405e+00 -2.0736269902607301e+01 6.8810236063870809e+00 -run_energy: -143.17285626124 +run_energy: -143.17285626124033 run_stress: ! |- -4.2136943025425171e+02 -6.8143523471945389e+02 -1.3373080481523612e+03 1.7225234470532837e+02 -5.0415065989752279e+01 -1.2628092326319543e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-fourier.yaml b/unittest/force-styles/tests/angle-fourier.yaml index 487458bf60..61165c5a92 100644 --- a/unittest/force-styles/tests/angle-fourier.yaml +++ b/unittest/force-styles/tests/angle-fourier.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:24 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full angle fourier @@ -17,7 +18,7 @@ angle_coeff: ! | equilibrium: 4 3.141592653589793 1.5707963267948966 1.5707963267948966 1.8234765819369754 extract: ! "" natoms: 29 -init_energy: 400.840366320102 +init_energy: 400.84036632010225 init_stress: ! |- -3.4848246942069039e+01 -6.9916377270952140e+01 1.0476462421302121e+02 7.3441393659189799e+01 -2.0375978361282911e+01 1.2021327066292979e+01 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 400.532578826681 +run_energy: 400.53257882668106 run_stress: ! |- -3.5033990243752221e+01 -6.9683360450913014e+01 1.0471735069466519e+02 7.3091958599418575e+01 -2.0600460353197874e+01 1.1646840154687229e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-gaussian.yaml b/unittest/force-styles/tests/angle-gaussian.yaml index dd11d73b1f..0022862384 100644 --- a/unittest/force-styles/tests/angle-gaussian.yaml +++ b/unittest/force-styles/tests/angle-gaussian.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:24 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full angle gaussian @@ -17,7 +18,7 @@ angle_coeff: ! | equilibrium: 4 1.5376350710070041 1.4887658519511628 1.5376350710070041 1.4887658519511628 extract: ! "" natoms: 29 -init_energy: 57.7940091589437 +init_energy: 57.794009158943744 init_stress: ! |2- 1.8540667929702014e-02 -2.1128225814185397e-02 2.5875578844833853e-03 1.9120388327532396e-02 4.4564216146325795e-03 9.8400107526492309e-03 init_forces: ! |2 @@ -52,12 +53,12 @@ init_forces: ! |2 29 3.6388435810152746e-03 -3.7693048980153125e-03 3.0630230753232656e-03 run_energy: 57.7939328926191 run_stress: ! |2- - 1.8333297775264226e-02 -2.1096486667701031e-02 2.7631888924368117e-03 1.9016013391593267e-02 4.3940373471828961e-03 9.6831700037143531e-03 + 1.8333297775264226e-02 -2.1096486667701031e-02 2.7631888924368117e-03 1.9016013391593270e-02 4.3940373471828970e-03 9.6831700037143548e-03 run_forces: ! |2 - 1 1.9869422162142472e-03 -1.9353557824978272e-04 -2.3006702071328641e-03 + 1 1.9869422162142486e-03 -1.9353557824978353e-04 -2.3006702071328633e-03 2 3.3476059893797837e-05 2.7319932557553025e-04 2.2063210015606759e-04 - 3 -3.4876540425126176e-04 2.0590710647431592e-03 3.3392846732858885e-03 - 4 -4.7868102566407460e-04 -1.0516647507108046e-03 2.6031681319326416e-04 + 3 -3.4876540425126285e-04 2.0590710647431618e-03 3.3392846732858885e-03 + 4 -4.7868102566407493e-04 -1.0516647507108072e-03 2.6031681319326361e-04 5 -1.6499221858598965e-03 -1.9312689427161936e-03 -9.0479891915083840e-04 6 7.7122074651881124e-03 -8.1501276471632952e-03 -1.0025269020742612e-02 7 -4.2683877840090532e-03 3.8176212404067746e-03 -9.3444409464597659e-04 diff --git a/unittest/force-styles/tests/angle-harmonic.yaml b/unittest/force-styles/tests/angle-harmonic.yaml index 6e884a40e0..dee700aa2c 100644 --- a/unittest/force-styles/tests/angle-harmonic.yaml +++ b/unittest/force-styles/tests/angle-harmonic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:24 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 7.5e-13 +skip_tests: prerequisites: ! | atom full angle harmonic @@ -14,73 +15,73 @@ angle_coeff: ! | 2 45.0 111.0 3 50.0 120.0 4 100.0 108.5 -equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 +equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 extract: ! "" natoms: 29 -init_energy: 41.530817896491 +init_energy: 41.53081789649104 init_stress: ! |2- - 8.9723357320869255e+01 -8.7188643750026529e+01 -2.5347135708427588e+00 9.2043419883119697e+01 -2.8187238090404989e+01 -1.5291148024927028e+00 + 8.9723357320869297e+01 -8.7188643750026529e+01 -2.5347135708427655e+00 9.2043419883119782e+01 -2.8187238090404904e+01 -1.5291148024926793e+00 init_forces: ! |2 - 1 4.7865489310693519e+01 7.8760925902181782e+00 -3.2694525514709809e+01 - 2 -1.1124882516177386e+00 -9.0075464203887741e+00 -7.2431691227364725e+00 - 3 -5.9057050592858884e+00 5.3263619873546183e+01 5.2353380124691370e+01 - 4 -1.6032230038990651e+01 -2.4560529343731371e+01 1.2891625920422349e+01 - 5 -4.4802331573497668e+01 -4.8300919461089343e+01 -2.3310767889219321e+01 - 6 4.7083124388174838e+01 -9.5212933434476135e+00 -3.2526392870546800e+01 + 1 4.7865489310693540e+01 7.8760925902181516e+00 -3.2694525514709866e+01 + 2 -1.1124882516177341e+00 -9.0075464203887403e+00 -7.2431691227364459e+00 + 3 -5.9057050592859328e+00 5.3263619873546261e+01 5.2353380124691469e+01 + 4 -1.6032230038990633e+01 -2.4560529343731403e+01 1.2891625920422307e+01 + 5 -4.4802331573497639e+01 -4.8300919461089379e+01 -2.3310767889219324e+01 + 6 4.7083124388174824e+01 -9.5212933434476312e+00 -3.2526392870546800e+01 7 -1.6208182775476303e+01 1.4458587960739102e+01 -3.5314745459502710e+00 - 8 -6.5664612141880827e+00 -2.5126850154274180e+01 8.2187944731423329e+01 + 8 -6.5664612141881040e+00 -2.5126850154274202e+01 8.2187944731423329e+01 9 -1.5504395262358301e+01 1.6121044185227817e+01 -4.2007069622477866e-01 - 10 9.9863759179364777e+00 4.1873540105704535e+01 -6.6085640966037388e+01 + 10 9.9863759179365275e+00 4.1873540105704549e+01 -6.6085640966037403e+01 11 -2.0441876158908627e+01 -6.5186824168985984e+00 9.0023620309811072e+00 - 12 -1.0772126658369636e+01 -1.0807367300158273e+01 -9.6049647456797036e+00 - 13 2.8847886813946415e+00 7.2973241014859491e+00 -1.0414233993845645e-01 - 14 1.5267407478336423e+01 -9.4754911480231527e+00 -6.6307012925544306e+00 - 15 1.2402914209534794e+01 -6.2644630791613860e+00 1.8484576795819905e+01 - 16 3.8927757686513598e-01 1.0690061587911142e+01 6.1542759189377589e+00 - 17 1.4664194297570587e+00 -1.9971277376602155e+00 1.0776844613215855e+00 - 18 1.5785371874873189e-01 1.6495665212200037e+00 -6.6944747776989910e+00 - 19 -1.9328033033421517e+00 -2.4078805870919515e+00 2.8669575541313312e+00 - 20 1.7749495845934198e+00 7.5831406587194772e-01 3.8275172235676602e+00 - 21 3.4186149299343622e+00 4.2795410364249307e+00 -1.2789555411020601e+01 - 22 -6.0875600315279446e+00 -4.1504951869796436e+00 4.5212856070195588e+00 - 23 2.6689451015935823e+00 -1.2904584944528708e-01 8.2682698040010418e+00 - 24 -1.3053945393770472e+00 5.0741459325182818e+00 -3.0209518576072751e+00 - 25 -1.0471133765834191e+00 -3.5082261409793545e+00 5.7374874908500728e-01 - 26 2.3525079159604663e+00 -1.5659197915389276e+00 2.4472031085222676e+00 - 27 -2.8720725187343144e-01 2.3577465459556626e+00 -8.0312673032167137e-01 - 28 -6.2799575211499037e-01 -1.4097313073755557e+00 3.2747938980615732e-02 - 29 9.1520300398842180e-01 -9.4801523858010661e-01 7.7037879134105569e-01 -run_energy: 41.2832373902946 + 12 -1.0772126658369565e+01 -1.0807367300158219e+01 -9.6049647456797871e+00 + 13 2.8847886813946291e+00 7.2973241014859198e+00 -1.0414233993842981e-01 + 14 1.5267407478336393e+01 -9.4754911480231776e+00 -6.6307012925544200e+00 + 15 1.2402914209534773e+01 -6.2644630791613967e+00 1.8484576795819933e+01 + 16 3.8927757686508357e-01 1.0690061587911176e+01 6.1542759189377696e+00 + 17 1.4664194297570785e+00 -1.9971277376602425e+00 1.0776844613215999e+00 + 18 1.5785371874873322e-01 1.6495665212200166e+00 -6.6944747776990434e+00 + 19 -1.9328033033421670e+00 -2.4078805870919706e+00 2.8669575541313534e+00 + 20 1.7749495845934338e+00 7.5831406587195394e-01 3.8275172235676900e+00 + 21 3.4186149299343742e+00 4.2795410364249484e+00 -1.2789555411020650e+01 + 22 -6.0875600315279677e+00 -4.1504951869796605e+00 4.5212856070195766e+00 + 23 2.6689451015935934e+00 -1.2904584944528752e-01 8.2682698040010738e+00 + 24 -1.3053945393770587e+00 5.0741459325183271e+00 -3.0209518576073018e+00 + 25 -1.0471133765834284e+00 -3.5082261409793856e+00 5.7374874908501228e-01 + 26 2.3525079159604871e+00 -1.5659197915389413e+00 2.4472031085222894e+00 + 27 -2.8720725187343754e-01 2.3577465459557132e+00 -8.0312673032168869e-01 + 28 -6.2799575211500369e-01 -1.4097313073755862e+00 3.2747938980616453e-02 + 29 9.1520300398844123e-01 -9.4801523858012704e-01 7.7037879134107223e-01 +run_energy: 41.28323739029463 run_stress: ! |2- - 8.8236221596506653e+01 -8.6492260623309548e+01 -1.7439609731970818e+00 9.0601855980531212e+01 -2.8735005690485036e+01 -2.6097632235197925e+00 + 8.8236221596506681e+01 -8.6492260623309562e+01 -1.7439609731970940e+00 9.0601855980531312e+01 -2.8735005690484968e+01 -2.6097632235197477e+00 run_forces: ! |2 - 1 4.7316793853445823e+01 8.2815577813110419e+00 -3.2021703111755414e+01 - 2 -1.1508196824491370e+00 -9.3814982172707779e+00 -7.5761211707510405e+00 - 3 -5.1083163691832354e+00 5.2667553294971555e+01 5.1784852458007521e+01 - 4 -1.6078177452606020e+01 -2.4156048365236188e+01 1.3140924677013139e+01 - 5 -4.4915734474022308e+01 -4.8095168640411785e+01 -2.3331149037574153e+01 - 6 4.7077916942842364e+01 -9.5906213020089943e+00 -3.2570331503075479e+01 + 1 4.7316793853445830e+01 8.2815577813110188e+00 -3.2021703111755464e+01 + 2 -1.1508196824491330e+00 -9.3814982172707460e+00 -7.5761211707510139e+00 + 3 -5.1083163691832576e+00 5.2667553294971619e+01 5.1784852458007592e+01 + 4 -1.6078177452605999e+01 -2.4156048365236213e+01 1.3140924677013103e+01 + 5 -4.4915734474022280e+01 -4.8095168640411821e+01 -2.3331149037574161e+01 + 6 4.7077916942842350e+01 -9.5906213020090156e+00 -3.2570331503075487e+01 7 -1.6228599672412471e+01 1.4485102617342370e+01 -3.5441153194985300e+00 - 8 -6.5097893981550552e+00 -2.5117582302614508e+01 8.2131369512415986e+01 + 8 -6.5097893981550730e+00 -2.5117582302614530e+01 8.2131369512416001e+01 9 -1.5527440970965937e+01 1.6147270375910470e+01 -4.0812004993325646e-01 - 10 1.0070812216240931e+01 4.1571532807578770e+01 -6.5968810328796309e+01 + 10 1.0070812216240984e+01 4.1571532807578805e+01 -6.5968810328796337e+01 11 -2.0431584971707451e+01 -6.4817395192247664e+00 8.9879981618991636e+00 - 12 -1.0884695976714742e+01 -1.1067390190389069e+01 -9.1551242768939716e+00 - 13 2.8052913970098916e+00 7.1296301666595223e+00 1.3173039168658640e-02 - 14 1.5254877537873556e+01 -8.9700095533297102e+00 -6.5719846903613259e+00 - 15 1.2392009100171009e+01 -6.0827695435257185e+00 1.7929674392339564e+01 - 16 4.7158712437382944e-01 1.0631038523396501e+01 6.0960085687560248e+00 - 17 1.4458707962589461e+00 -1.9708579331587084e+00 1.0634586790394374e+00 - 18 1.4201882413835776e-01 1.4265339757773212e+00 -5.7663956896747468e+00 - 19 -1.6609130686729214e+00 -2.0735307593210943e+00 2.4755525101126916e+00 - 20 1.5188942445345637e+00 6.4699678354377321e-01 3.2908431795620547e+00 - 21 3.2242729509516277e+00 4.0079233768385976e+00 -1.2047892238650938e+01 - 22 -5.7215184687399532e+00 -3.8871624402883245e+00 4.2679223469272056e+00 - 23 2.4972455177883255e+00 -1.2076093655027353e-01 7.7799698917237325e+00 - 24 -1.1661978296905358e+00 4.5271404898674401e+00 -2.6925565853369919e+00 - 25 -9.2712094527151212e-01 -3.1291890525016810e+00 5.1208215565053306e-01 - 26 2.0933187749620479e+00 -1.3979514373657593e+00 2.1804744296864591e+00 - 27 -2.6804542538019893e-01 2.1830651328697592e+00 -7.3931790038943679e-01 - 28 -5.7927072943126978e-01 -1.3052929090347605e+00 2.8365455885795143e-02 - 29 8.4731615481146871e-01 -8.7777222383499887e-01 7.1095244450364159e-01 + 12 -1.0884695976714678e+01 -1.1067390190389006e+01 -9.1551242768940568e+00 + 13 2.8052913970098801e+00 7.1296301666594912e+00 1.3173039168682621e-02 + 14 1.5254877537873529e+01 -8.9700095533297350e+00 -6.5719846903613162e+00 + 15 1.2392009100170984e+01 -6.0827695435257292e+00 1.7929674392339596e+01 + 16 4.7158712437377481e-01 1.0631038523396533e+01 6.0960085687560355e+00 + 17 1.4458707962589659e+00 -1.9708579331587350e+00 1.0634586790394520e+00 + 18 1.4201882413835909e-01 1.4265339757773337e+00 -5.7663956896747992e+00 + 19 -1.6609130686729365e+00 -2.0735307593211125e+00 2.4755525101127143e+00 + 20 1.5188942445345774e+00 6.4699678354377899e-01 3.2908431795620849e+00 + 21 3.2242729509516406e+00 4.0079233768386153e+00 -1.2047892238650988e+01 + 22 -5.7215184687399772e+00 -3.8871624402883409e+00 4.2679223469272234e+00 + 23 2.4972455177883366e+00 -1.2076093655027398e-01 7.7799698917237645e+00 + 24 -1.1661978296905471e+00 4.5271404898674854e+00 -2.6925565853370195e+00 + 25 -9.2712094527152167e-01 -3.1291890525017125e+00 5.1208215565053827e-01 + 26 2.0933187749620688e+00 -1.3979514373657731e+00 2.1804744296864813e+00 + 27 -2.6804542538020537e-01 2.1830651328698103e+00 -7.3931790038945400e-01 + 28 -5.7927072943128310e-01 -1.3052929090347909e+00 2.8365455885795865e-02 + 29 8.4731615481148848e-01 -8.7777222383501941e-01 7.1095244450365813e-01 ... diff --git a/unittest/force-styles/tests/angle-hybrid.yaml b/unittest/force-styles/tests/angle-hybrid.yaml index a46c6c69e4..c301f0bd21 100644 --- a/unittest/force-styles/tests/angle-hybrid.yaml +++ b/unittest/force-styles/tests/angle-hybrid.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:24 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full angle harmonic @@ -15,73 +16,73 @@ angle_coeff: ! | 2 cosine/shift 45.0 111.0 3 cosine/shift 50.0 120.0 4 harmonic 100.0 108.5 -equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 +equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 extract: ! "" natoms: 29 -init_energy: -669.446517131318 +init_energy: -669.4465171313176 init_stress: ! |2- - 1.1051961830323793e+02 -7.7252863271262299e+01 -3.3266755031975606e+01 7.0840668443491779e+01 -3.2285179825521766e+01 -8.4954399672475240e+00 + 1.1051961830323796e+02 -7.7252863271262314e+01 -3.3266755031975620e+01 7.0840668443491879e+01 -3.2285179825521674e+01 -8.4954399672475063e+00 init_forces: ! |2 - 1 4.7865489310693519e+01 7.8760925902181782e+00 -3.2694525514709809e+01 - 2 -1.1124882516177386e+00 -9.0075464203887741e+00 -7.2431691227364725e+00 - 3 -7.8464038683293458e+00 5.3597306198902082e+01 4.5949203134963497e+01 - 4 -1.7139238879078722e+01 -2.2545410094742259e+01 1.5248026546532433e+01 - 5 -4.3688256328733658e+01 -4.9752032532686762e+01 -2.3529307815343643e+01 - 6 2.8648764882943190e+01 1.2337790027065864e+01 -5.2639289744319786e+00 + 1 4.7865489310693540e+01 7.8760925902181516e+00 -3.2694525514709866e+01 + 2 -1.1124882516177341e+00 -9.0075464203887403e+00 -7.2431691227364459e+00 + 3 -7.8464038683293884e+00 5.3597306198902160e+01 4.5949203134963597e+01 + 4 -1.7139238879078704e+01 -2.2545410094742291e+01 1.5248026546532390e+01 + 5 -4.3688256328733630e+01 -4.9752032532686798e+01 -2.3529307815343646e+01 + 6 2.8648764882943176e+01 1.2337790027065846e+01 -5.2639289744319822e+00 7 -4.0343336515091934e+00 3.5987946950438578e+00 -8.7899903829119208e-01 - 8 -1.6174053254902834e+01 -2.2525177258640070e+01 3.0320903941419374e+01 + 8 -1.6174053254902855e+01 -2.2525177258640088e+01 3.0320903941419388e+01 9 -3.8661516758898671e+00 4.0199545660210578e+00 -1.0475700025519963e-01 - 10 -3.0032116527868182e+00 4.1994567576444879e+01 -2.5298415596686368e+01 + 10 -3.0032116527867685e+00 4.1994567576444901e+01 -2.5298415596686390e+01 11 -5.0638585095561384e+00 -1.5891547554535275e+00 2.2144297567629816e+00 - 12 -6.1790965307809529e+00 -1.1264206622804947e+01 -1.1188782345140234e+01 - 13 3.4429826666366048e+00 8.7466730778639725e+00 -9.1039098685779152e-01 - 14 8.3991712605582194e+00 -1.5193439937013558e+01 -4.4309323454131615e+00 - 15 1.5624743100389253e+01 -5.1855624450998707e+00 1.5692344788719437e+01 - 16 2.6595219522074176e+00 6.8884790729300924e+00 1.0406161101465226e+00 - 17 1.4664194297570587e+00 -1.9971277376602155e+00 1.0776844613215855e+00 - 18 1.5785371874873189e-01 1.6495665212200037e+00 -6.6944747776989910e+00 - 19 -1.9328033033421517e+00 -2.4078805870919515e+00 2.8669575541313312e+00 - 20 1.7749495845934198e+00 7.5831406587194772e-01 3.8275172235676602e+00 - 21 3.4186149299343622e+00 4.2795410364249307e+00 -1.2789555411020601e+01 - 22 -6.0875600315279446e+00 -4.1504951869796436e+00 4.5212856070195588e+00 - 23 2.6689451015935823e+00 -1.2904584944528708e-01 8.2682698040010418e+00 - 24 -1.3053945393770472e+00 5.0741459325182818e+00 -3.0209518576072751e+00 - 25 -1.0471133765834191e+00 -3.5082261409793545e+00 5.7374874908500728e-01 - 26 2.3525079159604663e+00 -1.5659197915389276e+00 2.4472031085222676e+00 - 27 -2.8720725187343144e-01 2.3577465459556626e+00 -8.0312673032167137e-01 - 28 -6.2799575211499037e-01 -1.4097313073755557e+00 3.2747938980615732e-02 - 29 9.1520300398842180e-01 -9.4801523858010661e-01 7.7037879134105569e-01 + 12 -6.1790965307808854e+00 -1.1264206622804886e+01 -1.1188782345140316e+01 + 13 3.4429826666365924e+00 8.7466730778639423e+00 -9.1039098685776532e-01 + 14 8.3991712605581892e+00 -1.5193439937013583e+01 -4.4309323454131508e+00 + 15 1.5624743100389232e+01 -5.1855624450998814e+00 1.5692344788719465e+01 + 16 2.6595219522073652e+00 6.8884790729301244e+00 1.0406161101465337e+00 + 17 1.4664194297570785e+00 -1.9971277376602425e+00 1.0776844613215999e+00 + 18 1.5785371874873322e-01 1.6495665212200166e+00 -6.6944747776990434e+00 + 19 -1.9328033033421670e+00 -2.4078805870919706e+00 2.8669575541313534e+00 + 20 1.7749495845934338e+00 7.5831406587195394e-01 3.8275172235676900e+00 + 21 3.4186149299343742e+00 4.2795410364249484e+00 -1.2789555411020650e+01 + 22 -6.0875600315279677e+00 -4.1504951869796605e+00 4.5212856070195766e+00 + 23 2.6689451015935934e+00 -1.2904584944528752e-01 8.2682698040010738e+00 + 24 -1.3053945393770587e+00 5.0741459325183271e+00 -3.0209518576073018e+00 + 25 -1.0471133765834284e+00 -3.5082261409793856e+00 5.7374874908501228e-01 + 26 2.3525079159604871e+00 -1.5659197915389413e+00 2.4472031085222894e+00 + 27 -2.8720725187343754e-01 2.3577465459557132e+00 -8.0312673032168869e-01 + 28 -6.2799575211500369e-01 -1.4097313073755862e+00 3.2747938980616453e-02 + 29 9.1520300398844123e-01 -9.4801523858012704e-01 7.7037879134107223e-01 run_energy: -669.682915883011 run_stress: ! |2- - 1.0910827460635431e+02 -7.6717747945181756e+01 -3.2390526661172551e+01 6.9397333601070585e+01 -3.2919024520896613e+01 -9.3879103935841197e+00 + 1.0910827460635434e+02 -7.6717747945181770e+01 -3.2390526661172565e+01 6.9397333601070656e+01 -3.2919024520896521e+01 -9.3879103935840877e+00 run_forces: ! |2 - 1 4.7317043425228775e+01 8.2803400468351640e+00 -3.2022741474282327e+01 - 2 -1.1507396121610043e+00 -9.3800428273681664e+00 -7.5750298470193211e+00 - 3 -7.0722723744612948e+00 5.3120552129380108e+01 4.5464393600034171e+01 - 4 -1.7156487213177229e+01 -2.2199431380438227e+01 1.5423862413015085e+01 - 5 -4.3774148945103477e+01 -4.9580631677813287e+01 -2.3555256603215724e+01 - 6 2.8582136701975742e+01 1.2250206029073558e+01 -5.2918320968928203e+00 + 1 4.7317043425228789e+01 8.2803400468351374e+00 -3.2022741474282384e+01 + 2 -1.1507396121609998e+00 -9.3800428273681327e+00 -7.5750298470192945e+00 + 3 -7.0722723744613241e+00 5.3120552129380208e+01 4.5464393600034256e+01 + 4 -1.7156487213177211e+01 -2.2199431380438263e+01 1.5423862413015042e+01 + 5 -4.3774148945103462e+01 -4.9580631677813329e+01 -2.3555256603215732e+01 + 6 2.8582136701975720e+01 1.2250206029073537e+01 -5.2918320968928239e+00 7 -4.0433921589706658e+00 3.6088512198553104e+00 -8.8346207971269153e-01 - 8 -1.6100382908522299e+01 -2.2479778216429441e+01 3.0308685247449411e+01 + 8 -1.6100382908522313e+01 -2.2479778216429455e+01 3.0308685247449418e+01 9 -3.8765997707298476e+00 4.0314231532636722e+00 -1.0094598622123530e-01 - 10 -3.0127554499097524e+00 4.1839118845102284e+01 -2.5278694388259829e+01 + 10 -3.0127554499096991e+00 4.1839118845102313e+01 -2.5278694388259844e+01 11 -5.0636093903406154e+00 -1.5836940795577710e+00 2.2122864002357181e+00 - 12 -6.0437037739721182e+00 -1.1714116472236709e+01 -1.0834285417835348e+01 - 13 3.3948471920723367e+00 8.6692910641428309e+00 -8.5533159046844065e-01 - 14 8.3711862952624507e+00 -1.4706373371942306e+01 -4.3599928418467879e+00 - 15 1.5472767163774250e+01 -5.0378189247377430e+00 1.5256421410739964e+01 - 16 2.7028526717416108e+00 6.8630083227935339e+00 1.0230239724999741e+00 - 17 1.4532581472931438e+00 -1.9809038599228157e+00 1.0688992817802037e+00 - 18 1.4201882413835776e-01 1.4265339757773212e+00 -5.7663956896747468e+00 - 19 -1.6609130686729214e+00 -2.0735307593210943e+00 2.4755525101126916e+00 - 20 1.5188942445345637e+00 6.4699678354377321e-01 3.2908431795620547e+00 - 21 3.2242729509516277e+00 4.0079233768385976e+00 -1.2047892238650938e+01 - 22 -5.7215184687399532e+00 -3.8871624402883245e+00 4.2679223469272056e+00 - 23 2.4972455177883255e+00 -1.2076093655027353e-01 7.7799698917237325e+00 - 24 -1.1661978296905358e+00 4.5271404898674401e+00 -2.6925565853369919e+00 - 25 -9.2712094527151212e-01 -3.1291890525016810e+00 5.1208215565053306e-01 - 26 2.0933187749620479e+00 -1.3979514373657593e+00 2.1804744296864591e+00 - 27 -2.6804542538019893e-01 2.1830651328697592e+00 -7.3931790038943679e-01 - 28 -5.7927072943126978e-01 -1.3052929090347605e+00 2.8365455885795143e-02 - 29 8.4731615481146871e-01 -8.7777222383499887e-01 7.1095244450364159e-01 + 12 -6.0437037739720525e+00 -1.1714116472236649e+01 -1.0834285417835430e+01 + 13 3.3948471920723255e+00 8.6692910641428007e+00 -8.5533159046841445e-01 + 14 8.3711862952624205e+00 -1.4706373371942330e+01 -4.3599928418467790e+00 + 15 1.5472767163774225e+01 -5.0378189247377554e+00 1.5256421410739998e+01 + 16 2.7028526717415566e+00 6.8630083227935659e+00 1.0230239724999848e+00 + 17 1.4532581472931634e+00 -1.9809038599228423e+00 1.0688992817802181e+00 + 18 1.4201882413835909e-01 1.4265339757773337e+00 -5.7663956896747992e+00 + 19 -1.6609130686729365e+00 -2.0735307593211125e+00 2.4755525101127143e+00 + 20 1.5188942445345774e+00 6.4699678354377899e-01 3.2908431795620849e+00 + 21 3.2242729509516406e+00 4.0079233768386153e+00 -1.2047892238650988e+01 + 22 -5.7215184687399772e+00 -3.8871624402883409e+00 4.2679223469272234e+00 + 23 2.4972455177883366e+00 -1.2076093655027398e-01 7.7799698917237645e+00 + 24 -1.1661978296905471e+00 4.5271404898674854e+00 -2.6925565853370195e+00 + 25 -9.2712094527152167e-01 -3.1291890525017125e+00 5.1208215565053827e-01 + 26 2.0933187749620688e+00 -1.3979514373657731e+00 2.1804744296864813e+00 + 27 -2.6804542538020537e-01 2.1830651328698103e+00 -7.3931790038945400e-01 + 28 -5.7927072943128310e-01 -1.3052929090347909e+00 2.8365455885795865e-02 + 29 8.4731615481148848e-01 -8.7777222383501941e-01 7.1095244450365813e-01 ... diff --git a/unittest/force-styles/tests/angle-mm3.yaml b/unittest/force-styles/tests/angle-mm3.yaml index cf857f86d5..731ca836cc 100644 --- a/unittest/force-styles/tests/angle-mm3.yaml +++ b/unittest/force-styles/tests/angle-mm3.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:24 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full angle mm3 @@ -17,7 +18,7 @@ angle_coeff: ! | equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 extract: ! "" natoms: 29 -init_energy: 44.7246154856262 +init_energy: 44.72461548562619 init_stress: ! |2- 9.6483539484715550e+01 -7.3120175237333257e+01 -2.3363364247382318e+01 9.6221737253953094e+01 -3.1311135458252629e+01 -1.7557146927751774e+01 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 -2.9077025434585668e-01 2.3869960050754981e+00 -8.1309006692665386e-01 28 -6.3578646910720737e-01 -1.4272199888098533e+00 3.3154199570463894e-02 29 9.2655672345306406e-01 -9.5977601626564502e-01 7.7993586735619003e-01 -run_energy: 44.3963062209567 +run_energy: 44.39630622095668 run_stress: ! |2- 9.4780140946000415e+01 -7.2437928047641378e+01 -2.2342212898359016e+01 9.4615808363649876e+01 -3.1856450072762396e+01 -1.8642069063830736e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-quartic.yaml b/unittest/force-styles/tests/angle-quartic.yaml index b28882840d..6ded709e84 100644 --- a/unittest/force-styles/tests/angle-quartic.yaml +++ b/unittest/force-styles/tests/angle-quartic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:25 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 7.5e-13 +skip_tests: prerequisites: ! | atom full angle quartic @@ -50,7 +51,7 @@ init_forces: ! |2 27 -2.8661525615948458e-01 2.3528867249007490e+00 -8.0147131396639093e-01 28 -6.2670131824814423e-01 -1.4068255489507977e+00 3.2680438458290273e-02 29 9.1331657440762881e-01 -9.4606117594995109e-01 7.6879087550810066e-01 -run_energy: 40.8070328565151 +run_energy: 40.807032856515114 run_stress: ! |2- 8.7762099497944007e+01 -8.3994526348801116e+01 -3.7675731491429025e+00 9.0047666438661253e+01 -2.6521811185253604e+01 -2.8086171333623424e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-table_linear.yaml b/unittest/force-styles/tests/angle-table_linear.yaml index 979750b11c..58e676e8d5 100644 --- a/unittest/force-styles/tests/angle-table_linear.yaml +++ b/unittest/force-styles/tests/angle-table_linear.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:25 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full angle table @@ -14,10 +15,10 @@ angle_coeff: ! | 2 ${input_dir}/angle_table.txt harmonic_2 3 ${input_dir}/angle_table.txt harmonic_3 4 ${input_dir}/angle_table.txt harmonic_4 -equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 +equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 extract: ! "" natoms: 29 -init_energy: 41.5339263499027 +init_energy: 41.53392634990271 init_stress: ! |2- 8.9723357320869255e+01 -8.7188643750026586e+01 -2.5347135708426856e+00 9.2043419883119654e+01 -2.8187238090404925e+01 -1.5291148024925465e+00 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 -2.8720725187343266e-01 2.3577465459556737e+00 -8.0312673032167514e-01 28 -6.2799575211499314e-01 -1.4097313073755624e+00 3.2747938980615898e-02 29 9.1520300398842580e-01 -9.4801523858011116e-01 7.7037879134105924e-01 -run_energy: 41.2864477972198 +run_energy: 41.286447797219786 run_stress: ! |2- 8.8236221596506653e+01 -8.6492260623309619e+01 -1.7439609731970602e+00 9.0601855980531255e+01 -2.8735005690484979e+01 -2.6097632235196491e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-table_spline.yaml b/unittest/force-styles/tests/angle-table_spline.yaml index 7adb7240ec..2677e7501d 100644 --- a/unittest/force-styles/tests/angle-table_spline.yaml +++ b/unittest/force-styles/tests/angle-table_spline.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:25 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full angle table @@ -14,10 +15,10 @@ angle_coeff: ! | 2 ${input_dir}/angle_table.txt harmonic_2 3 ${input_dir}/angle_table.txt harmonic_3 4 ${input_dir}/angle_table.txt harmonic_4 -equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 +equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 extract: ! "" natoms: 29 -init_energy: 41.530817896491 +init_energy: 41.530817896491016 init_stress: ! |2- 8.9723357320869255e+01 -8.7188643750026586e+01 -2.5347135708426856e+00 9.2043419883119654e+01 -2.8187238090404925e+01 -1.5291148024925465e+00 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 -2.8720725187343266e-01 2.3577465459556737e+00 -8.0312673032167514e-01 28 -6.2799575211499314e-01 -1.4097313073755624e+00 3.2747938980615898e-02 29 9.1520300398842580e-01 -9.4801523858011116e-01 7.7037879134105924e-01 -run_energy: 41.2832373902946 +run_energy: 41.28323739029464 run_stress: ! |2- 8.8236221596506653e+01 -8.6492260623309605e+01 -1.7439609731970425e+00 9.0601855980531241e+01 -2.8735005690484972e+01 -2.6097632235196544e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/angle-zero.yaml b/unittest/force-styles/tests/angle-zero.yaml index b2f1a0ec90..078b40b329 100644 --- a/unittest/force-styles/tests/angle-zero.yaml +++ b/unittest/force-styles/tests/angle-zero.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:25 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 1e-14 +skip_tests: prerequisites: ! | atom full angle zero @@ -14,7 +15,7 @@ angle_coeff: ! | 2 111 3 120 4 108.5 -equilibrium: 4 1.9216075064457565 1.9373154697137058 2.0943951023931953 1.8936822384138474 +equilibrium: 4 1.9216075064457567 1.9373154697137058 2.0943951023931953 1.8936822384138476 extract: ! "" natoms: 29 init_energy: 0 diff --git a/unittest/force-styles/tests/atomic-pair-adp.yaml b/unittest/force-styles/tests/atomic-pair-adp.yaml index 852fa103b6..ffd494bf74 100644 --- a/unittest/force-styles/tests/atomic-pair-adp.yaml +++ b/unittest/force-styles/tests/atomic-pair-adp.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:08:58 2021 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair adp pre_commands: ! "" @@ -13,7 +14,7 @@ pair_coeff: ! | * * AlCu.adp Al Cu extract: ! "" natoms: 32 -init_vdwl: -96.3621905354495 +init_vdwl: -96.36219053544953 init_coul: 0 init_stress: ! |2- 1.0950940963019309e+02 9.8793143617200286e+01 8.2868514028589203e+01 4.4674243524583641e+00 -1.6359979177752422e+00 3.1824061950082316e+00 diff --git a/unittest/force-styles/tests/atomic-pair-atm.yaml b/unittest/force-styles/tests/atomic-pair-atm.yaml index 76189db0aa..1f378c37a7 100644 --- a/unittest/force-styles/tests/atomic-pair-atm.yaml +++ b/unittest/force-styles/tests/atomic-pair-atm.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:08:58 2021 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | pair atm pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * * 25.0 extract: ! "" natoms: 32 -init_vdwl: 4.29790007480121 +init_vdwl: 4.2979000748012135 init_coul: 0 init_stress: ! |2- 1.2907320878711678e+01 1.2784310537300177e+01 1.2989469257199106e+01 3.2388109042463260e-02 4.8727763023580862e-03 -4.0982848248419549e-03 @@ -52,7 +53,7 @@ init_forces: ! |2 30 -5.4737231063771909e-02 -7.4768574267284921e-04 -7.9319198647640782e-02 31 -1.6935816002065361e-02 -1.0547543496314456e-01 5.0982604012348082e-02 32 -1.2390716429105794e-01 -7.2578142947119742e-02 -4.1957221348949782e-02 -run_vdwl: 4.2978376627225 +run_vdwl: 4.297837662722496 run_coul: 0 run_stress: ! |2- 1.2906967061285989e+01 1.2784294465524448e+01 1.2989277437691916e+01 3.2259383532254583e-02 4.8758996531777293e-03 -4.1128361419111841e-03 diff --git a/unittest/force-styles/tests/atomic-pair-beck.yaml b/unittest/force-styles/tests/atomic-pair-beck.yaml index 5416d2eb4f..b9f05cd4d7 100644 --- a/unittest/force-styles/tests/atomic-pair-beck.yaml +++ b/unittest/force-styles/tests/atomic-pair-beck.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 2e-12 +skip_tests: prerequisites: ! | pair beck pre_commands: ! "" @@ -12,7 +13,7 @@ pair_coeff: ! | * * 399.671876712 0.0000867636112694 0.675 4.390 0.0003746 extract: ! "" natoms: 32 -init_vdwl: 1.66849238207407 +init_vdwl: 1.6684923820740662 init_coul: 0 init_stress: ! |2- 6.1946492027972404e+00 6.0610401681504031e+00 5.8874026063063027e+00 2.0726580449163334e-01 -2.1210358381150402e-02 -8.9415206710373632e-02 @@ -49,7 +50,7 @@ init_forces: ! |2 30 -4.2587399053040723e-02 -3.0047441564997463e-02 -8.4420708024142574e-02 31 -2.0646215864156710e-02 -1.1590109109011101e-01 7.4785523155347783e-02 32 -1.9351936790460383e-01 -6.3281924064284692e-02 -2.2278650486481616e-02 -run_vdwl: 1.66842323237505 +run_vdwl: 1.6684232323750492 run_coul: 0 run_stress: ! |2- 6.1945945010955059e+00 6.0608213175977346e+00 5.8870610876826692e+00 2.0713170028170666e-01 -2.1315978613950362e-02 -8.9579347008543392e-02 diff --git a/unittest/force-styles/tests/atomic-pair-born.yaml b/unittest/force-styles/tests/atomic-pair-born.yaml index 52fcbef141..b2fed716da 100644 --- a/unittest/force-styles/tests/atomic-pair-born.yaml +++ b/unittest/force-styles/tests/atomic-pair-born.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair born pre_commands: ! "" @@ -12,7 +13,7 @@ pair_coeff: ! | * * 6.08 0.317 2.340 24.18 11.51 extract: ! "" natoms: 32 -init_vdwl: 836.893711811487 +init_vdwl: 836.8937118114866 init_coul: 0 init_stress: ! |2- 2.1907762159508770e+03 2.1533146615415390e+03 2.1384803888060319e+03 3.1458958046100697e+01 -5.2331768978302460e+00 -1.2410855173406260e+01 @@ -49,7 +50,7 @@ init_forces: ! |2 30 -1.2005631838887281e+01 -6.4092999695138637e+00 -1.9850411539058847e+01 31 -5.5566952298732328e+00 -2.8420402803389738e+01 1.7818115115845121e+01 32 -4.3603353069761802e+01 -1.4618745302080386e+01 -5.8614805227083417e+00 -run_vdwl: 836.525645079158 +run_vdwl: 836.5256450791583 run_coul: 0 run_stress: ! |2- 2.1900813819406562e+03 2.1526856543612221e+03 2.1377858496227304e+03 3.1265932019331444e+01 -5.2753088928534844e+00 -1.2351730282986319e+01 diff --git a/unittest/force-styles/tests/atomic-pair-buck_coul_cut_qeq_point.yaml b/unittest/force-styles/tests/atomic-pair-buck_coul_cut_qeq_point.yaml index d79bfd9955..576885a6ef 100644 --- a/unittest/force-styles/tests/atomic-pair-buck_coul_cut_qeq_point.yaml +++ b/unittest/force-styles/tests/atomic-pair-buck_coul_cut_qeq_point.yaml @@ -1,9 +1,9 @@ --- -lammps_version: 8 Apr 2021 -date_generated: Tue Apr 20 14:47:51 2021 -epsilon: 7.5e-13 +lammps_version: 17 Feb 2022 tags: unstable -skip_tests: intel single gpu +date_generated: Fri Mar 18 22:17:36 2022 +epsilon: 7.5e-13 +skip_tests: gpu intel single prerequisites: ! | pair buck/coul/cut fix qeq/point diff --git a/unittest/force-styles/tests/atomic-pair-buck_coul_cut_qeq_shielded.yaml b/unittest/force-styles/tests/atomic-pair-buck_coul_cut_qeq_shielded.yaml index 9b8773c67e..b66f8900e4 100644 --- a/unittest/force-styles/tests/atomic-pair-buck_coul_cut_qeq_shielded.yaml +++ b/unittest/force-styles/tests/atomic-pair-buck_coul_cut_qeq_shielded.yaml @@ -1,9 +1,9 @@ --- -lammps_version: 8 Apr 2021 -date_generated: Tue Apr 20 14:48:00 2021 -epsilon: 7.5e-13 +lammps_version: 17 Feb 2022 tags: unstable -skip_tests: intel single gpu +date_generated: Fri Mar 18 22:17:37 2022 +epsilon: 7.5e-13 +skip_tests: gpu intel single prerequisites: ! | pair buck/coul/cut fix qeq/shielded diff --git a/unittest/force-styles/tests/atomic-pair-colloid.yaml b/unittest/force-styles/tests/atomic-pair-colloid.yaml index b666021c91..36f82618ad 100644 --- a/unittest/force-styles/tests/atomic-pair-colloid.yaml +++ b/unittest/force-styles/tests/atomic-pair-colloid.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-14 skip_tests: single prerequisites: ! | @@ -22,7 +22,7 @@ pair_coeff: ! | 2 2 10.0 1.0 0.0 0.0 2.5 extract: ! "" natoms: 27 -init_vdwl: -0.250320882681727 +init_vdwl: -0.2503208826817271 init_coul: 0 init_stress: ! |2- 1.6687682615057471e+00 1.1747891073356403e+01 1.0083450567161805e+00 -5.5144333681331359e+00 3.4548099128807436e-01 2.8508471154795298e+00 @@ -54,7 +54,7 @@ init_forces: ! |2 25 -1.1259499193288544e-01 1.6395143300644177e-02 -9.0439962448757879e-04 26 1.0304882476745540e-01 7.8050496446500431e-03 1.9255643852370385e-02 27 -4.3346315050731818e-02 -2.2993111981455712e-02 -1.1392238078737215e-02 -run_vdwl: 0.546631276624111 +run_vdwl: 0.5466312766241107 run_coul: 0 run_stress: ! |2- 5.6665057159424279e+00 1.4285058934754080e+01 5.9048859060593220e+00 -8.4818814420023418e+00 5.2881315002023017e+00 -1.1970976964673827e+00 diff --git a/unittest/force-styles/tests/atomic-pair-colloid_multi.yaml b/unittest/force-styles/tests/atomic-pair-colloid_multi.yaml index d224977a3e..5356238240 100644 --- a/unittest/force-styles/tests/atomic-pair-colloid_multi.yaml +++ b/unittest/force-styles/tests/atomic-pair-colloid_multi.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-14 skip_tests: single prerequisites: ! | @@ -22,68 +22,68 @@ pair_coeff: ! | 2 2 10.0 1.0 0.0 0.0 2.5 extract: ! "" natoms: 27 -init_vdwl: -0.250320882681727 +init_vdwl: -0.25032088268172703 init_coul: 0 init_stress: ! |2- - 1.6687682615057460e+00 1.1747891073356403e+01 1.0083450567161796e+00 -5.5144333681331261e+00 3.4548099128807747e-01 2.8508471154795298e+00 + 1.6687682615057429e+00 1.1747891073356412e+01 1.0083450567161802e+00 -5.5144333681331181e+00 3.4548099128807563e-01 2.8508471154795316e+00 init_forces: ! |2 - 1 4.2502214537152215e-02 6.8580119035896499e-03 -6.8677100496229715e-02 - 2 -2.4409971231138453e-04 -5.8282143696384295e-05 1.8044935805594862e-05 - 3 -1.5879676810899343e-02 -1.3312213962585376e-02 -1.1959790230130810e-02 - 4 5.4778343227770802e-04 -2.4424984321614867e-02 -3.6445490162239011e-02 + 1 4.2502214537152215e-02 6.8580119035896491e-03 -6.8677100496229701e-02 + 2 -2.4409971231138501e-04 -5.8282143696384431e-05 1.8044935805594903e-05 + 3 -1.5879676810899353e-02 -1.3312213962585400e-02 -1.1959790230130819e-02 + 4 5.4778343227770455e-04 -2.4424984321614870e-02 -3.6445490162239004e-02 5 7.4458982140296174e-04 5.3043116325023304e-05 1.1848540218007477e-04 - 6 2.2466945989092868e+00 -1.1355562227620619e+00 2.3685617789648643e+00 + 6 2.2466945989092872e+00 -1.1355562227620619e+00 2.3685617789648648e+00 7 -2.9420817632825613e-03 -7.4830177547552715e-04 -1.2326317038179183e-03 - 8 1.0456973881919887e-01 -2.8794438516942737e-02 -1.0767233651978719e-02 + 8 1.0456973881919887e-01 -2.8794438516942737e-02 -1.0767233651978722e-02 9 -1.8842568296905022e-02 1.7092235687070117e-02 -1.4248069827099535e-02 - 10 1.8278642893333091e-04 4.1941592242561833e-04 9.8624961124789412e-05 - 11 2.5605560774882609e-02 -1.0270993584697993e-01 -1.1452001476172027e-01 - 12 -1.7190177814447429e+00 4.3689733469585290e+00 1.2971816478430653e+00 + 10 1.8278642893333118e-04 4.1941592242561681e-04 9.8624961124790605e-05 + 11 2.5605560774882581e-02 -1.0270993584697991e-01 -1.1452001476172027e-01 + 12 -1.7190177814447427e+00 4.3689733469585290e+00 1.2971816478430653e+00 13 -1.4111675314136360e-01 4.2420896699357280e-02 -6.2611143561577903e-02 14 -4.1487669742220991e-02 -9.8022075695912841e-03 1.5709450788901494e-01 - 15 1.8296904307488300e+00 -4.3363458812930853e+00 -1.2757754576582720e+00 + 15 1.8296904307488295e+00 -4.3363458812930844e+00 -1.2757754576582720e+00 16 1.2006895887469950e-03 8.6089636114693700e-04 4.8031493704482794e-05 - 17 6.1663662317927744e-04 -2.9235023723413574e-04 3.5387343984160432e-03 + 17 6.1663662317927733e-04 -2.9235023723413580e-04 3.5387343984160432e-03 18 -3.6474070486619430e-02 -2.2991550342271461e-02 1.6164948715920169e-02 19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 20 -6.4513560799741325e-03 -1.0256280577842596e-03 -6.5496554886125568e-04 - 21 6.2575756583543186e-03 1.1941945764063822e-03 8.5597303165342044e-04 - 22 -8.0641944111498032e-04 1.1943078425573997e-04 -9.8433130461350886e-04 + 21 6.2575756583543186e-03 1.1941945764063822e-03 8.5597303165342033e-04 + 22 -8.0641944111498043e-04 1.1943078425573997e-04 -9.8433130461350886e-04 23 -2.2951590782728504e+00 1.1606385208734131e+00 -2.3600356755963983e+00 - 24 7.2701432066201888e-02 7.6224922982964599e-02 1.0727212071804376e-01 - 25 -1.1259499193288544e-01 1.6395143300644177e-02 -9.0439962448757879e-04 - 26 1.0304882476745540e-01 7.8050496446500431e-03 1.9255643852370385e-02 - 27 -4.3346315050731818e-02 -2.2993111981455712e-02 -1.1392238078737215e-02 -run_vdwl: 0.546631276624111 + 24 7.2701432066201707e-02 7.6224922982964544e-02 1.0727212071804376e-01 + 25 -1.1259499193288544e-01 1.6395143300644177e-02 -9.0439962448757869e-04 + 26 1.0304882476745546e-01 7.8050496446500344e-03 1.9255643852370354e-02 + 27 -4.3346315050731707e-02 -2.2993111981455643e-02 -1.1392238078737184e-02 +run_vdwl: 0.5466312766241109 run_coul: 0 run_stress: ! |2- - 5.6665057159424261e+00 1.4285058934754046e+01 5.9048859060592864e+00 -8.4818814420023330e+00 5.2881315002022999e+00 -1.1970976964673721e+00 + 5.6665057159424252e+00 1.4285058934754080e+01 5.9048859060592900e+00 -8.4818814420023365e+00 5.2881315002022946e+00 -1.1970976964673801e+00 run_forces: ! |2 - 1 4.0537507872915053e-02 1.0013640201526581e-02 -7.4355259432510867e-02 - 2 -2.4485071669905174e-04 -5.6491959787860711e-05 1.5762341909211182e-05 - 3 -1.6525210356374609e-02 -1.0700896145717292e-02 -1.2466738605043475e-02 - 4 5.0895222294109008e-04 -3.7419904027191128e-02 -5.2521332284172585e-02 + 1 4.0537507872915053e-02 1.0013640201526579e-02 -7.4355259432510881e-02 + 2 -2.4485071669905206e-04 -5.6491959787860786e-05 1.5762341909211202e-05 + 3 -1.6525210356374616e-02 -1.0700896145717309e-02 -1.2466738605043484e-02 + 4 5.0895222294109789e-04 -3.7419904027191121e-02 -5.2521332284172599e-02 5 8.5578946640613943e-04 8.0514060368271588e-05 1.6089100898761854e-04 - 6 1.0911859985057569e+01 -7.9829483219779931e+00 1.1645117315742235e+01 + 6 1.0911859985057569e+01 -7.9829483219779931e+00 1.1645117315742233e+01 7 -4.1062783933935344e-03 -1.1807936887044740e-03 -1.9906886909716228e-03 - 8 1.5636388167915602e-01 -2.6781130173509270e-02 -6.1357481353796735e-03 + 8 1.5636388167915602e-01 -2.6781130173509270e-02 -6.1357481353796744e-03 9 -1.5567285888326367e-02 1.4722366247268760e-02 -1.1953767152526074e-02 - 10 1.8805531793129058e-04 3.7820400166769451e-04 1.4614304834967826e-04 - 11 -1.4864493912733895e-03 -1.0424975640019393e-01 -1.0816074777358398e-01 + 10 1.8805531793129033e-04 3.7820400166769559e-04 1.4614304834967718e-04 + 11 -1.4864493912734866e-03 -1.0424975640019385e-01 -1.0816074777358381e-01 12 -1.4904584977612405e+00 4.2295428937341466e+00 1.1884379359045367e+00 13 -1.1886876552110689e-01 2.9541662205201678e-02 -4.8308607756838103e-02 14 -4.1308859452544304e-02 -1.3119548152383659e-02 1.5120405320455541e-01 - 15 1.5979084315924958e+00 -4.1789376696435205e+00 -1.1491971372792293e+00 + 15 1.5979084315924958e+00 -4.1789376696435196e+00 -1.1491971372792293e+00 16 9.0310163053403483e-04 6.6079222833706974e-04 3.6708366832548456e-05 - 17 1.8715075729367327e-03 2.1147818438203180e-04 4.1547470949003804e-03 + 17 1.8715075729367327e-03 2.1147818438203175e-04 4.1547470949003804e-03 18 -3.0456290625962980e-02 -1.9427008524387373e-02 1.3856334852879893e-02 19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 20 -6.8134551323710407e-03 -9.2563232531751437e-04 -2.5011200860506922e-04 - 21 6.5798593112743053e-03 1.0885497409975236e-03 5.0300594748037915e-04 - 22 -7.0187004021510127e-04 1.0724877221923711e-04 -8.7584649012749057e-04 - 23 -1.0963098689741106e+01 8.0069723546503813e+00 -1.1637002224325434e+01 - 24 4.2791276882802765e-02 7.5413656281613686e-02 9.2510054641217671e-02 + 21 6.5798593112743053e-03 1.0885497409975234e-03 5.0300594748037904e-04 + 22 -7.0187004021510192e-04 1.0724877221923722e-04 -8.7584649012749144e-04 + 23 -1.0963098689741106e+01 8.0069723546503830e+00 -1.1637002224325434e+01 + 24 4.2791276882802834e-02 7.5413656281613589e-02 9.2510054641217560e-02 25 -1.6396876440827662e-01 1.5180752630598059e-02 -5.8364823335845528e-03 - 26 1.2677571346204658e-01 9.1980780160170368e-03 2.1458873742780715e-02 + 26 1.2677571346204658e-01 9.1980780160170368e-03 2.1458873742780722e-02 27 -3.3538794640120287e-02 -1.7365037936021697e-02 -8.5471336286569340e-03 ... diff --git a/unittest/force-styles/tests/atomic-pair-colloid_multi_tri.yaml b/unittest/force-styles/tests/atomic-pair-colloid_multi_tri.yaml index fa52a37ce7..c5bcda1c9a 100644 --- a/unittest/force-styles/tests/atomic-pair-colloid_multi_tri.yaml +++ b/unittest/force-styles/tests/atomic-pair-colloid_multi_tri.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-13 skip_tests: single prerequisites: ! | @@ -26,65 +26,65 @@ natoms: 27 init_vdwl: -0.250320882681715 init_coul: 0 init_stress: ! |2- - 1.6687682615058241e+00 1.1747891073356824e+01 1.0083450567162384e+00 -5.5144333681333002e+00 3.4548099128804161e-01 2.8508471154796613e+00 + 1.6687682615058166e+00 1.1747891073356826e+01 1.0083450567162291e+00 -5.5144333681332895e+00 3.4548099128804100e-01 2.8508471154796506e+00 init_forces: ! |2 - 1 4.2502214537152139e-02 6.8580119035896794e-03 -6.8677100496229632e-02 + 1 4.2502214537152139e-02 6.8580119035896777e-03 -6.8677100496229618e-02 2 -2.4409971231138493e-04 -5.8282143696384329e-05 1.8044935805594828e-05 - 3 -1.5879676810899381e-02 -1.3312213962585501e-02 -1.1959790230130862e-02 - 4 5.4778343227773751e-04 -2.4424984321614905e-02 -3.6445490162238962e-02 + 3 -1.5879676810899346e-02 -1.3312213962585421e-02 -1.1959790230130829e-02 + 4 5.4778343227773751e-04 -2.4424984321614926e-02 -3.6445490162238969e-02 5 7.4458982140296185e-04 5.3043116325022762e-05 1.1848540218007482e-04 - 6 2.2466945989093152e+00 -1.1355562227620701e+00 2.3685617789648945e+00 + 6 2.2466945989093152e+00 -1.1355562227620704e+00 2.3685617789648945e+00 7 -2.9420817632825631e-03 -7.4830177547552694e-04 -1.2326317038179192e-03 - 8 1.0456973881919868e-01 -2.8794438516942699e-02 -1.0767233651978712e-02 + 8 1.0456973881919868e-01 -2.8794438516942696e-02 -1.0767233651978710e-02 9 -1.8842568296904984e-02 1.7092235687070075e-02 -1.4248069827099497e-02 10 1.8278642893333129e-04 4.1941592242561638e-04 9.8624961124791906e-05 - 11 2.5605560774882380e-02 -1.0270993584698010e-01 -1.1452001476172038e-01 + 11 2.5605560774882352e-02 -1.0270993584698007e-01 -1.1452001476172038e-01 12 -1.7190177814448016e+00 4.3689733469586800e+00 1.2971816478431131e+00 13 -1.4111675314136379e-01 4.2420896699357342e-02 -6.2611143561578070e-02 14 -4.1487669742221053e-02 -9.8022075695912807e-03 1.5709450788901488e-01 - 15 1.8296904307488884e+00 -4.3363458812932363e+00 -1.2757754576583198e+00 + 15 1.8296904307488877e+00 -4.3363458812932354e+00 -1.2757754576583200e+00 16 1.2006895887469950e-03 8.6089636114693700e-04 4.8031493704482679e-05 - 17 6.1663662317927549e-04 -2.9235023723413927e-04 3.5387343984160471e-03 + 17 6.1663662317927538e-04 -2.9235023723413927e-04 3.5387343984160467e-03 18 -3.6474070486619471e-02 -2.2991550342271464e-02 1.6164948715920183e-02 19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 20 -6.4513560799741325e-03 -1.0256280577842611e-03 -6.5496554886125568e-04 - 21 6.2575756583543186e-03 1.1941945764063838e-03 8.5597303165342044e-04 - 22 -8.0641944111497544e-04 1.1943078425573959e-04 -9.8433130461350322e-04 + 21 6.2575756583543186e-03 1.1941945764063840e-03 8.5597303165342033e-04 + 22 -8.0641944111497815e-04 1.1943078425573998e-04 -9.8433130461350604e-04 23 -2.2951590782728784e+00 1.1606385208734213e+00 -2.3600356755964280e+00 - 24 7.2701432066201735e-02 7.6224922982964224e-02 1.0727212071804387e-01 - 25 -1.1259499193288525e-01 1.6395143300644142e-02 -9.0439962448757977e-04 - 26 1.0304882476745569e-01 7.8050496446502114e-03 1.9255643852370365e-02 - 27 -4.3346315050731436e-02 -2.2993111981455479e-02 -1.1392238078737104e-02 -run_vdwl: 0.546631276624125 + 24 7.2701432066201777e-02 7.6224922982964405e-02 1.0727212071804407e-01 + 25 -1.1259499193288525e-01 1.6395143300644142e-02 -9.0439962448757988e-04 + 26 1.0304882476745592e-01 7.8050496446501715e-03 1.9255643852370247e-02 + 27 -4.3346315050731700e-02 -2.2993111981455646e-02 -1.1392238078737184e-02 +run_vdwl: 0.5466312766241253 run_coul: 0 run_stress: ! |2- - 5.6665057159425141e+00 1.4285058934754488e+01 5.9048859060595005e+00 -8.4818814420024662e+00 5.2881315002023204e+00 -1.1970976964672442e+00 + 5.6665057159425096e+00 1.4285058934754492e+01 5.9048859060594117e+00 -8.4818814420024538e+00 5.2881315002023177e+00 -1.1970976964672473e+00 run_forces: ! |2 - 1 4.0537507872915039e-02 1.0013640201526628e-02 -7.4355259432510909e-02 + 1 4.0537507872915039e-02 1.0013640201526628e-02 -7.4355259432510895e-02 2 -2.4485071669905233e-04 -5.6491959787860793e-05 1.5762341909211158e-05 - 3 -1.6525210356374626e-02 -1.0700896145717401e-02 -1.2466738605043531e-02 - 4 5.0895222294107621e-04 -3.7419904027191864e-02 -5.2521332284173328e-02 + 3 -1.6525210356374637e-02 -1.0700896145717426e-02 -1.2466738605043538e-02 + 4 5.0895222294106493e-04 -3.7419904027191808e-02 -5.2521332284173307e-02 5 8.5578946640613932e-04 8.0514060368270612e-05 1.6089100898761840e-04 - 6 1.0911859985057617e+01 -7.9829483219779238e+00 1.1645117315742368e+01 + 6 1.0911859985057617e+01 -7.9829483219779247e+00 1.1645117315742368e+01 7 -4.1062783933935310e-03 -1.1807936887044700e-03 -1.9906886909716232e-03 - 8 1.5636388167915585e-01 -2.6781130173509173e-02 -6.1357481353797629e-03 + 8 1.5636388167915585e-01 -2.6781130173509173e-02 -6.1357481353797663e-03 9 -1.5567285888326300e-02 1.4722366247268678e-02 -1.1953767152526006e-02 - 10 1.8805531793129020e-04 3.7820400166769380e-04 1.4614304834967978e-04 - 11 -1.4864493912745413e-03 -1.0424975640019400e-01 -1.0816074777358338e-01 - 12 -1.4904584977612991e+00 4.2295428937343154e+00 1.1884379359045845e+00 - 13 -1.1886876552110487e-01 2.9541662205201210e-02 -4.8308607756837312e-02 + 10 1.8805531793128995e-04 3.7820400166769499e-04 1.4614304834967859e-04 + 11 -1.4864493912745413e-03 -1.0424975640019399e-01 -1.0816074777358338e-01 + 12 -1.4904584977612991e+00 4.2295428937343154e+00 1.1884379359045842e+00 + 13 -1.1886876552110640e-01 2.9541662205201574e-02 -4.8308607756837901e-02 14 -4.1308859452544325e-02 -1.3119548152383642e-02 1.5120405320455521e-01 - 15 1.5979084315925551e+00 -4.1789376696436884e+00 -1.1491971372792762e+00 + 15 1.5979084315925547e+00 -4.1789376696436875e+00 -1.1491971372792762e+00 16 9.0310163053403689e-04 6.6079222833707125e-04 3.6708366832548463e-05 - 17 1.8715075729367286e-03 2.1147818438202660e-04 4.1547470949003795e-03 + 17 1.8715075729367283e-03 2.1147818438202654e-04 4.1547470949003804e-03 18 -3.0456290625963053e-02 -1.9427008524387408e-02 1.3856334852879930e-02 19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 20 -6.8134551323710381e-03 -9.2563232531751730e-04 -2.5011200860506922e-04 - 21 6.5798593112743045e-03 1.0885497409975256e-03 5.0300594748037633e-04 - 22 -7.0187004021510387e-04 1.0724877221923791e-04 -8.7584649012749393e-04 + 21 6.5798593112743045e-03 1.0885497409975258e-03 5.0300594748037622e-04 + 22 -7.0187004021510181e-04 1.0724877221923757e-04 -8.7584649012749144e-04 23 -1.0963098689741154e+01 8.0069723546503138e+00 -1.1637002224325569e+01 - 24 4.2791276882800683e-02 7.5413656281613561e-02 9.2510054641216644e-02 + 24 4.2791276882802154e-02 7.5413656281613117e-02 9.2510054641217143e-02 25 -1.6396876440827649e-01 1.5180752630597804e-02 -5.8364823335845511e-03 - 26 1.2677571346204791e-01 9.1980780160173560e-03 2.1458873742780590e-02 - 27 -3.3538794640120474e-02 -1.7365037936021819e-02 -8.5471336286569739e-03 + 26 1.2677571346204786e-01 9.1980780160173664e-03 2.1458873742780608e-02 + 27 -3.3538794640120356e-02 -1.7365037936021746e-02 -8.5471336286569392e-03 ... diff --git a/unittest/force-styles/tests/atomic-pair-colloid_tiled.yaml b/unittest/force-styles/tests/atomic-pair-colloid_tiled.yaml index 62e85584e7..292b9e0fdd 100644 --- a/unittest/force-styles/tests/atomic-pair-colloid_tiled.yaml +++ b/unittest/force-styles/tests/atomic-pair-colloid_tiled.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-14 skip_tests: single prerequisites: ! | @@ -22,68 +22,68 @@ pair_coeff: ! | 2 2 10.0 1.0 0.0 0.0 2.5 extract: ! "" natoms: 27 -init_vdwl: -0.250320882681727 +init_vdwl: -0.25032088268172703 init_coul: 0 init_stress: ! |2- - 1.6687682615057460e+00 1.1747891073356403e+01 1.0083450567161796e+00 -5.5144333681331261e+00 3.4548099128807747e-01 2.8508471154795298e+00 + 1.6687682615057429e+00 1.1747891073356412e+01 1.0083450567161802e+00 -5.5144333681331181e+00 3.4548099128807563e-01 2.8508471154795316e+00 init_forces: ! |2 - 1 4.2502214537152215e-02 6.8580119035896499e-03 -6.8677100496229715e-02 - 2 -2.4409971231138453e-04 -5.8282143696384295e-05 1.8044935805594862e-05 - 3 -1.5879676810899343e-02 -1.3312213962585376e-02 -1.1959790230130810e-02 - 4 5.4778343227770802e-04 -2.4424984321614867e-02 -3.6445490162239011e-02 + 1 4.2502214537152215e-02 6.8580119035896491e-03 -6.8677100496229701e-02 + 2 -2.4409971231138501e-04 -5.8282143696384431e-05 1.8044935805594903e-05 + 3 -1.5879676810899353e-02 -1.3312213962585400e-02 -1.1959790230130819e-02 + 4 5.4778343227770455e-04 -2.4424984321614870e-02 -3.6445490162239004e-02 5 7.4458982140296174e-04 5.3043116325023304e-05 1.1848540218007477e-04 - 6 2.2466945989092868e+00 -1.1355562227620619e+00 2.3685617789648643e+00 + 6 2.2466945989092872e+00 -1.1355562227620619e+00 2.3685617789648648e+00 7 -2.9420817632825613e-03 -7.4830177547552715e-04 -1.2326317038179183e-03 - 8 1.0456973881919887e-01 -2.8794438516942737e-02 -1.0767233651978719e-02 + 8 1.0456973881919887e-01 -2.8794438516942737e-02 -1.0767233651978722e-02 9 -1.8842568296905022e-02 1.7092235687070117e-02 -1.4248069827099535e-02 - 10 1.8278642893333091e-04 4.1941592242561833e-04 9.8624961124789412e-05 - 11 2.5605560774882609e-02 -1.0270993584697993e-01 -1.1452001476172027e-01 - 12 -1.7190177814447429e+00 4.3689733469585290e+00 1.2971816478430653e+00 + 10 1.8278642893333118e-04 4.1941592242561681e-04 9.8624961124790605e-05 + 11 2.5605560774882581e-02 -1.0270993584697991e-01 -1.1452001476172027e-01 + 12 -1.7190177814447427e+00 4.3689733469585290e+00 1.2971816478430653e+00 13 -1.4111675314136360e-01 4.2420896699357280e-02 -6.2611143561577903e-02 14 -4.1487669742220991e-02 -9.8022075695912841e-03 1.5709450788901494e-01 - 15 1.8296904307488300e+00 -4.3363458812930853e+00 -1.2757754576582720e+00 + 15 1.8296904307488295e+00 -4.3363458812930844e+00 -1.2757754576582720e+00 16 1.2006895887469950e-03 8.6089636114693700e-04 4.8031493704482794e-05 - 17 6.1663662317927744e-04 -2.9235023723413574e-04 3.5387343984160432e-03 + 17 6.1663662317927733e-04 -2.9235023723413580e-04 3.5387343984160432e-03 18 -3.6474070486619430e-02 -2.2991550342271461e-02 1.6164948715920169e-02 19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 20 -6.4513560799741325e-03 -1.0256280577842596e-03 -6.5496554886125568e-04 - 21 6.2575756583543186e-03 1.1941945764063822e-03 8.5597303165342044e-04 - 22 -8.0641944111498032e-04 1.1943078425573997e-04 -9.8433130461350886e-04 + 21 6.2575756583543186e-03 1.1941945764063822e-03 8.5597303165342033e-04 + 22 -8.0641944111498043e-04 1.1943078425573997e-04 -9.8433130461350886e-04 23 -2.2951590782728504e+00 1.1606385208734131e+00 -2.3600356755963983e+00 - 24 7.2701432066201888e-02 7.6224922982964599e-02 1.0727212071804376e-01 - 25 -1.1259499193288544e-01 1.6395143300644177e-02 -9.0439962448757879e-04 - 26 1.0304882476745540e-01 7.8050496446500431e-03 1.9255643852370385e-02 - 27 -4.3346315050731818e-02 -2.2993111981455712e-02 -1.1392238078737215e-02 -run_vdwl: 0.546631276624111 + 24 7.2701432066201707e-02 7.6224922982964544e-02 1.0727212071804376e-01 + 25 -1.1259499193288544e-01 1.6395143300644177e-02 -9.0439962448757869e-04 + 26 1.0304882476745546e-01 7.8050496446500344e-03 1.9255643852370354e-02 + 27 -4.3346315050731707e-02 -2.2993111981455643e-02 -1.1392238078737184e-02 +run_vdwl: 0.5466312766241109 run_coul: 0 run_stress: ! |2- - 5.6665057159424261e+00 1.4285058934754046e+01 5.9048859060592864e+00 -8.4818814420023330e+00 5.2881315002022999e+00 -1.1970976964673721e+00 + 5.6665057159424252e+00 1.4285058934754080e+01 5.9048859060592900e+00 -8.4818814420023365e+00 5.2881315002022946e+00 -1.1970976964673801e+00 run_forces: ! |2 - 1 4.0537507872915053e-02 1.0013640201526581e-02 -7.4355259432510867e-02 - 2 -2.4485071669905174e-04 -5.6491959787860711e-05 1.5762341909211182e-05 - 3 -1.6525210356374609e-02 -1.0700896145717292e-02 -1.2466738605043475e-02 - 4 5.0895222294109008e-04 -3.7419904027191128e-02 -5.2521332284172585e-02 + 1 4.0537507872915053e-02 1.0013640201526579e-02 -7.4355259432510881e-02 + 2 -2.4485071669905206e-04 -5.6491959787860786e-05 1.5762341909211202e-05 + 3 -1.6525210356374616e-02 -1.0700896145717309e-02 -1.2466738605043484e-02 + 4 5.0895222294109789e-04 -3.7419904027191121e-02 -5.2521332284172599e-02 5 8.5578946640613943e-04 8.0514060368271588e-05 1.6089100898761854e-04 - 6 1.0911859985057569e+01 -7.9829483219779931e+00 1.1645117315742235e+01 + 6 1.0911859985057569e+01 -7.9829483219779931e+00 1.1645117315742233e+01 7 -4.1062783933935344e-03 -1.1807936887044740e-03 -1.9906886909716228e-03 - 8 1.5636388167915602e-01 -2.6781130173509270e-02 -6.1357481353796735e-03 + 8 1.5636388167915602e-01 -2.6781130173509270e-02 -6.1357481353796744e-03 9 -1.5567285888326367e-02 1.4722366247268760e-02 -1.1953767152526074e-02 - 10 1.8805531793129058e-04 3.7820400166769451e-04 1.4614304834967826e-04 - 11 -1.4864493912733895e-03 -1.0424975640019393e-01 -1.0816074777358398e-01 + 10 1.8805531793129033e-04 3.7820400166769559e-04 1.4614304834967718e-04 + 11 -1.4864493912734866e-03 -1.0424975640019385e-01 -1.0816074777358381e-01 12 -1.4904584977612405e+00 4.2295428937341466e+00 1.1884379359045367e+00 13 -1.1886876552110689e-01 2.9541662205201678e-02 -4.8308607756838103e-02 14 -4.1308859452544304e-02 -1.3119548152383659e-02 1.5120405320455541e-01 - 15 1.5979084315924958e+00 -4.1789376696435205e+00 -1.1491971372792293e+00 + 15 1.5979084315924958e+00 -4.1789376696435196e+00 -1.1491971372792293e+00 16 9.0310163053403483e-04 6.6079222833706974e-04 3.6708366832548456e-05 - 17 1.8715075729367327e-03 2.1147818438203180e-04 4.1547470949003804e-03 + 17 1.8715075729367327e-03 2.1147818438203175e-04 4.1547470949003804e-03 18 -3.0456290625962980e-02 -1.9427008524387373e-02 1.3856334852879893e-02 19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 20 -6.8134551323710407e-03 -9.2563232531751437e-04 -2.5011200860506922e-04 - 21 6.5798593112743053e-03 1.0885497409975236e-03 5.0300594748037915e-04 - 22 -7.0187004021510127e-04 1.0724877221923711e-04 -8.7584649012749057e-04 - 23 -1.0963098689741106e+01 8.0069723546503813e+00 -1.1637002224325434e+01 - 24 4.2791276882802765e-02 7.5413656281613686e-02 9.2510054641217671e-02 + 21 6.5798593112743053e-03 1.0885497409975234e-03 5.0300594748037904e-04 + 22 -7.0187004021510192e-04 1.0724877221923722e-04 -8.7584649012749144e-04 + 23 -1.0963098689741106e+01 8.0069723546503830e+00 -1.1637002224325434e+01 + 24 4.2791276882802834e-02 7.5413656281613589e-02 9.2510054641217560e-02 25 -1.6396876440827662e-01 1.5180752630598059e-02 -5.8364823335845528e-03 - 26 1.2677571346204658e-01 9.1980780160170368e-03 2.1458873742780715e-02 + 26 1.2677571346204658e-01 9.1980780160170368e-03 2.1458873742780722e-02 27 -3.3538794640120287e-02 -1.7365037936021697e-02 -8.5471336286569340e-03 ... diff --git a/unittest/force-styles/tests/atomic-pair-colloid_tiled_tri.yaml b/unittest/force-styles/tests/atomic-pair-colloid_tiled_tri.yaml index b3f0b7a06d..b4ee393144 100644 --- a/unittest/force-styles/tests/atomic-pair-colloid_tiled_tri.yaml +++ b/unittest/force-styles/tests/atomic-pair-colloid_tiled_tri.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-13 skip_tests: single prerequisites: ! | @@ -26,65 +26,65 @@ natoms: 27 init_vdwl: -0.250320882681715 init_coul: 0 init_stress: ! |2- - 1.6687682615058241e+00 1.1747891073356824e+01 1.0083450567162384e+00 -5.5144333681333002e+00 3.4548099128804161e-01 2.8508471154796613e+00 + 1.6687682615058166e+00 1.1747891073356826e+01 1.0083450567162291e+00 -5.5144333681332895e+00 3.4548099128804100e-01 2.8508471154796506e+00 init_forces: ! |2 - 1 4.2502214537152139e-02 6.8580119035896794e-03 -6.8677100496229632e-02 + 1 4.2502214537152139e-02 6.8580119035896777e-03 -6.8677100496229618e-02 2 -2.4409971231138493e-04 -5.8282143696384329e-05 1.8044935805594828e-05 - 3 -1.5879676810899381e-02 -1.3312213962585501e-02 -1.1959790230130862e-02 - 4 5.4778343227773751e-04 -2.4424984321614905e-02 -3.6445490162238962e-02 + 3 -1.5879676810899346e-02 -1.3312213962585421e-02 -1.1959790230130829e-02 + 4 5.4778343227773751e-04 -2.4424984321614926e-02 -3.6445490162238969e-02 5 7.4458982140296185e-04 5.3043116325022762e-05 1.1848540218007482e-04 - 6 2.2466945989093152e+00 -1.1355562227620701e+00 2.3685617789648945e+00 + 6 2.2466945989093152e+00 -1.1355562227620704e+00 2.3685617789648945e+00 7 -2.9420817632825631e-03 -7.4830177547552694e-04 -1.2326317038179192e-03 - 8 1.0456973881919868e-01 -2.8794438516942699e-02 -1.0767233651978712e-02 + 8 1.0456973881919868e-01 -2.8794438516942696e-02 -1.0767233651978710e-02 9 -1.8842568296904984e-02 1.7092235687070075e-02 -1.4248069827099497e-02 10 1.8278642893333129e-04 4.1941592242561638e-04 9.8624961124791906e-05 - 11 2.5605560774882380e-02 -1.0270993584698010e-01 -1.1452001476172038e-01 + 11 2.5605560774882352e-02 -1.0270993584698007e-01 -1.1452001476172038e-01 12 -1.7190177814448016e+00 4.3689733469586800e+00 1.2971816478431131e+00 13 -1.4111675314136379e-01 4.2420896699357342e-02 -6.2611143561578070e-02 14 -4.1487669742221053e-02 -9.8022075695912807e-03 1.5709450788901488e-01 - 15 1.8296904307488884e+00 -4.3363458812932363e+00 -1.2757754576583198e+00 + 15 1.8296904307488877e+00 -4.3363458812932354e+00 -1.2757754576583200e+00 16 1.2006895887469950e-03 8.6089636114693700e-04 4.8031493704482679e-05 - 17 6.1663662317927549e-04 -2.9235023723413927e-04 3.5387343984160471e-03 + 17 6.1663662317927538e-04 -2.9235023723413927e-04 3.5387343984160467e-03 18 -3.6474070486619471e-02 -2.2991550342271464e-02 1.6164948715920183e-02 19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 20 -6.4513560799741325e-03 -1.0256280577842611e-03 -6.5496554886125568e-04 - 21 6.2575756583543186e-03 1.1941945764063838e-03 8.5597303165342044e-04 - 22 -8.0641944111497544e-04 1.1943078425573959e-04 -9.8433130461350322e-04 + 21 6.2575756583543186e-03 1.1941945764063840e-03 8.5597303165342033e-04 + 22 -8.0641944111497815e-04 1.1943078425573998e-04 -9.8433130461350604e-04 23 -2.2951590782728784e+00 1.1606385208734213e+00 -2.3600356755964280e+00 - 24 7.2701432066201735e-02 7.6224922982964224e-02 1.0727212071804387e-01 - 25 -1.1259499193288525e-01 1.6395143300644142e-02 -9.0439962448757977e-04 - 26 1.0304882476745569e-01 7.8050496446502114e-03 1.9255643852370365e-02 - 27 -4.3346315050731436e-02 -2.2993111981455479e-02 -1.1392238078737104e-02 -run_vdwl: 0.546631276624125 + 24 7.2701432066201777e-02 7.6224922982964405e-02 1.0727212071804407e-01 + 25 -1.1259499193288525e-01 1.6395143300644142e-02 -9.0439962448757988e-04 + 26 1.0304882476745592e-01 7.8050496446501715e-03 1.9255643852370247e-02 + 27 -4.3346315050731700e-02 -2.2993111981455646e-02 -1.1392238078737184e-02 +run_vdwl: 0.5466312766241253 run_coul: 0 run_stress: ! |2- - 5.6665057159425141e+00 1.4285058934754488e+01 5.9048859060595005e+00 -8.4818814420024662e+00 5.2881315002023204e+00 -1.1970976964672442e+00 + 5.6665057159425096e+00 1.4285058934754492e+01 5.9048859060594117e+00 -8.4818814420024538e+00 5.2881315002023177e+00 -1.1970976964672473e+00 run_forces: ! |2 - 1 4.0537507872915039e-02 1.0013640201526628e-02 -7.4355259432510909e-02 + 1 4.0537507872915039e-02 1.0013640201526628e-02 -7.4355259432510895e-02 2 -2.4485071669905233e-04 -5.6491959787860793e-05 1.5762341909211158e-05 - 3 -1.6525210356374626e-02 -1.0700896145717401e-02 -1.2466738605043531e-02 - 4 5.0895222294107621e-04 -3.7419904027191864e-02 -5.2521332284173328e-02 + 3 -1.6525210356374637e-02 -1.0700896145717426e-02 -1.2466738605043538e-02 + 4 5.0895222294106493e-04 -3.7419904027191808e-02 -5.2521332284173307e-02 5 8.5578946640613932e-04 8.0514060368270612e-05 1.6089100898761840e-04 - 6 1.0911859985057617e+01 -7.9829483219779238e+00 1.1645117315742368e+01 + 6 1.0911859985057617e+01 -7.9829483219779247e+00 1.1645117315742368e+01 7 -4.1062783933935310e-03 -1.1807936887044700e-03 -1.9906886909716232e-03 - 8 1.5636388167915585e-01 -2.6781130173509173e-02 -6.1357481353797629e-03 + 8 1.5636388167915585e-01 -2.6781130173509173e-02 -6.1357481353797663e-03 9 -1.5567285888326300e-02 1.4722366247268678e-02 -1.1953767152526006e-02 - 10 1.8805531793129020e-04 3.7820400166769380e-04 1.4614304834967978e-04 - 11 -1.4864493912745413e-03 -1.0424975640019400e-01 -1.0816074777358338e-01 - 12 -1.4904584977612991e+00 4.2295428937343154e+00 1.1884379359045845e+00 - 13 -1.1886876552110487e-01 2.9541662205201210e-02 -4.8308607756837312e-02 + 10 1.8805531793128995e-04 3.7820400166769499e-04 1.4614304834967859e-04 + 11 -1.4864493912745413e-03 -1.0424975640019399e-01 -1.0816074777358338e-01 + 12 -1.4904584977612991e+00 4.2295428937343154e+00 1.1884379359045842e+00 + 13 -1.1886876552110640e-01 2.9541662205201574e-02 -4.8308607756837901e-02 14 -4.1308859452544325e-02 -1.3119548152383642e-02 1.5120405320455521e-01 - 15 1.5979084315925551e+00 -4.1789376696436884e+00 -1.1491971372792762e+00 + 15 1.5979084315925547e+00 -4.1789376696436875e+00 -1.1491971372792762e+00 16 9.0310163053403689e-04 6.6079222833707125e-04 3.6708366832548463e-05 - 17 1.8715075729367286e-03 2.1147818438202660e-04 4.1547470949003795e-03 + 17 1.8715075729367283e-03 2.1147818438202654e-04 4.1547470949003804e-03 18 -3.0456290625963053e-02 -1.9427008524387408e-02 1.3856334852879930e-02 19 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 20 -6.8134551323710381e-03 -9.2563232531751730e-04 -2.5011200860506922e-04 - 21 6.5798593112743045e-03 1.0885497409975256e-03 5.0300594748037633e-04 - 22 -7.0187004021510387e-04 1.0724877221923791e-04 -8.7584649012749393e-04 + 21 6.5798593112743045e-03 1.0885497409975258e-03 5.0300594748037622e-04 + 22 -7.0187004021510181e-04 1.0724877221923757e-04 -8.7584649012749144e-04 23 -1.0963098689741154e+01 8.0069723546503138e+00 -1.1637002224325569e+01 - 24 4.2791276882800683e-02 7.5413656281613561e-02 9.2510054641216644e-02 + 24 4.2791276882802154e-02 7.5413656281613117e-02 9.2510054641217143e-02 25 -1.6396876440827649e-01 1.5180752630597804e-02 -5.8364823335845511e-03 - 26 1.2677571346204791e-01 9.1980780160173560e-03 2.1458873742780590e-02 - 27 -3.3538794640120474e-02 -1.7365037936021819e-02 -8.5471336286569739e-03 + 26 1.2677571346204786e-01 9.1980780160173664e-03 2.1458873742780608e-02 + 27 -3.3538794640120356e-02 -1.7365037936021746e-02 -8.5471336286569392e-03 ... diff --git a/unittest/force-styles/tests/atomic-pair-eam.yaml b/unittest/force-styles/tests/atomic-pair-eam.yaml index 9c8c3ba8cd..48162991d9 100644 --- a/unittest/force-styles/tests/atomic-pair-eam.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:00 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 6e-12 skip_tests: single prerequisites: ! | @@ -15,7 +15,7 @@ pair_coeff: ! | 2 2 Cu_u3.eam extract: ! "" natoms: 32 -init_vdwl: -368.582927487109 +init_vdwl: -368.58292748710903 init_coul: 0 init_stress: ! |- -3.9250135569983178e+02 -4.6446788990492507e+02 -4.1339651642484176e+02 1.9400736722937040e+01 1.1111963280257418e+00 1.2102392154667420e+01 @@ -52,7 +52,7 @@ init_forces: ! |2 30 -3.1599376372206285e+00 1.2411259590817284e+01 -3.3705452712365678e+00 31 -4.7553805255326385e+00 2.0807423151379889e+00 9.7968713347922520e+00 32 4.7774045900241520e+00 -3.5862707137300642e+00 -3.6201646908068756e+00 -run_vdwl: -368.628082866892 +run_vdwl: -368.6280828668923 run_coul: 0 run_stress: ! |- -3.9249694064943384e+02 -4.6446111054680068e+02 -4.1341521022304943e+02 1.9383267246544207e+01 1.1036774867522274e+00 1.2092041596769240e+01 diff --git a/unittest/force-styles/tests/atomic-pair-eam_alloy.yaml b/unittest/force-styles/tests/atomic-pair-eam_alloy.yaml index 5ec5bef372..ba626fb100 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_alloy.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_alloy.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:00 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-12 skip_tests: single prerequisites: ! | @@ -13,7 +13,7 @@ pair_coeff: ! | * * CuNi.eam.alloy Cu Ni extract: ! "" natoms: 32 -init_vdwl: -118.717513292074 +init_vdwl: -118.71751329207396 init_coul: 0 init_stress: ! |2- 5.1014257789320709e+01 4.8593729597995065e+01 4.7112736045420640e+01 3.5405588622315474e+00 -1.0857130886013302e+00 -2.7579846998321549e+00 @@ -50,7 +50,7 @@ init_forces: ! |2 30 -7.7628811007199061e-01 -1.1864112261858684e+00 -1.7057845890523824e+00 31 -5.5170344013648301e-02 -2.3455335239818620e+00 1.3686542848487442e+00 32 -4.4069686170352860e+00 -9.2275646480965812e-01 -2.8237489589371051e-01 -run_vdwl: -118.721845820838 +run_vdwl: -118.72184582083834 run_coul: 0 run_stress: ! |2- 5.1008838955726937e+01 4.8584006717520772e+01 4.7099721534677649e+01 3.5410070434379857e+00 -1.0820463688123025e+00 -2.7574764800554417e+00 diff --git a/unittest/force-styles/tests/atomic-pair-eam_alloy_real.yaml b/unittest/force-styles/tests/atomic-pair-eam_alloy_real.yaml index bff08e048b..a0a1191cc5 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_alloy_real.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_alloy_real.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:00 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 7.5e-12 skip_tests: single prerequisites: ! | @@ -14,7 +14,7 @@ pair_coeff: ! | * * CuNi.eam.alloy Cu Ni extract: ! "" natoms: 32 -init_vdwl: -2737.69103243002 +init_vdwl: -2737.6910324300247 init_coul: 0 init_stress: ! |2- 1.1764167914493003e+03 1.1205980824873511e+03 1.0864455580995223e+03 8.1647231129873333e+01 -2.5037139879634061e+01 -6.3600641311730442e+01 @@ -51,7 +51,7 @@ init_forces: ! |2 30 -1.7901630000432078e+01 -2.7359294215609122e+01 -3.9336329099287752e+01 31 -1.2722584214742627e+00 -5.4089290760925913e+01 3.1561919199814835e+01 32 -1.0162711573460497e+02 -2.1279270671809819e+01 -6.5117201231272759e+00 -run_vdwl: -2737.72416936454 +run_vdwl: -2737.724169364543 run_coul: 0 run_stress: ! |2- 1.1764787620345819e+03 1.1205547781193936e+03 1.0863293163772205e+03 8.1706260194005594e+01 -2.4940094344791824e+01 -6.3614824113069091e+01 diff --git a/unittest/force-styles/tests/atomic-pair-eam_cd.yaml b/unittest/force-styles/tests/atomic-pair-eam_cd.yaml index 915253dce7..857081b808 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_cd.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_cd.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:00 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-12 skip_tests: single prerequisites: ! | @@ -14,7 +14,7 @@ pair_coeff: ! | * * FeCr.cdeam Fe Cr extract: ! "" natoms: 32 -init_vdwl: -77.4194811493259 +init_vdwl: -77.41948114932589 init_coul: 0 init_stress: ! |2- 2.9506366554526057e+01 2.9183156291462467e+01 2.2317338076293908e+01 7.8583791220531909e+00 -9.3405164902515037e-01 8.4666514895851674e-01 @@ -51,7 +51,7 @@ init_forces: ! |2 30 -4.8386802956274799e-01 6.7845093285518510e-01 -7.2822185494105651e-01 31 -8.5629870279800413e-01 -1.3626475979016444e+00 2.4555267483126282e+00 32 -2.6135587355983043e+00 -1.5330500443455732e+00 -6.7557011932914857e-01 -run_vdwl: -77.4214727154924 +run_vdwl: -77.42147271549238 run_coul: 0 run_stress: ! |2- 2.9493005554949598e+01 2.9172864836203829e+01 2.2312049668403862e+01 7.8487811034540371e+00 -9.4002654430986221e-01 8.4333891294706553e-01 diff --git a/unittest/force-styles/tests/atomic-pair-eam_cd_old.yaml b/unittest/force-styles/tests/atomic-pair-eam_cd_old.yaml index a7fa727b7f..acf9d3013e 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_cd_old.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_cd_old.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:00 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-12 skip_tests: single prerequisites: ! | @@ -14,7 +14,7 @@ pair_coeff: ! | * * FeCr.cdeam Fe Cr extract: ! "" natoms: 32 -init_vdwl: -77.3566448928927 +init_vdwl: -77.35664489289273 init_coul: 0 init_stress: ! |2- 2.9405509133096274e+01 2.9077568336065784e+01 2.2113739361139935e+01 7.8904933627522267e+00 -9.3663625990408816e-01 8.1130320719355153e-01 @@ -51,7 +51,7 @@ init_forces: ! |2 30 -4.8103274177570204e-01 6.7765823339012321e-01 -7.2776907743413610e-01 31 -8.5335875768564051e-01 -1.3518208677019026e+00 2.4663641279666662e+00 32 -2.6142628689137353e+00 -1.5189868845729886e+00 -6.7390297673000232e-01 -run_vdwl: -77.3586232494724 +run_vdwl: -77.35862324947242 run_coul: 0 run_stress: ! |2- 2.9392159617306476e+01 2.9067390891336895e+01 2.2108618910688079e+01 7.8809332873995865e+00 -9.4254846573098539e-01 8.0805977962507369e-01 diff --git a/unittest/force-styles/tests/atomic-pair-eam_cd_real.yaml b/unittest/force-styles/tests/atomic-pair-eam_cd_real.yaml index abe25cff95..288aecfcbb 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_cd_real.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_cd_real.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:00 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-12 skip_tests: single prerequisites: ! | @@ -15,7 +15,7 @@ pair_coeff: ! | * * FeCr.cdeam Fe Cr extract: ! "" natoms: 32 -init_vdwl: -1785.33573859861 +init_vdwl: -1785.3357385986067 init_coul: 0 init_stress: ! |2- 6.8043301174259761e+02 6.7297960563391200e+02 5.1465006825793444e+02 1.8121853680469479e+02 -2.1539743820861666e+01 1.9524563154151824e+01 @@ -52,7 +52,7 @@ init_forces: ! |2 30 -1.1158262405262278e+01 1.5645450981201224e+01 -1.6793195768740453e+01 31 -1.9746718194509157e+01 -3.1423401701143103e+01 5.6625794900273171e+01 32 -6.0270099286644076e+01 -3.5352975667087023e+01 -1.5579017839726909e+01 -run_vdwl: -1785.32443012494 +run_vdwl: -1785.3244301249376 run_coul: 0 run_stress: ! |2- 6.8033307307183838e+02 6.7295080184729852e+02 5.1465049023351878e+02 1.8108364252022736e+02 -2.1656087785470721e+01 1.9438707865457804e+01 diff --git a/unittest/force-styles/tests/atomic-pair-eam_fs.yaml b/unittest/force-styles/tests/atomic-pair-eam_fs.yaml index 88b2512214..f70de1ca34 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_fs.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_fs.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:01 2021 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-12 skip_tests: single prerequisites: ! | @@ -14,7 +14,7 @@ pair_coeff: ! | * * AlFe_mm.eam.fs Al Fe extract: ! "" natoms: 32 -init_vdwl: -108.262111462389 +init_vdwl: -108.2621114623893 init_coul: 0 init_stress: ! |2- 9.9880622051717296e+01 9.1747240726677930e+01 8.7601365289659455e+01 5.9087784401945047e+00 -2.1299937451008777e+00 3.4718249594388439e-01 @@ -51,7 +51,7 @@ init_forces: ! |2 30 -1.0374660230195671e+00 -1.1402475422746554e+00 -1.7211546087860548e+00 31 -1.0712777798403222e-01 -2.4507774686205819e+00 1.0846841028356100e+00 32 -4.7946208495149687e+00 -2.9144866547588686e+00 -1.3852412930860005e+00 -run_vdwl: -108.277148649431 +run_vdwl: -108.27714864943073 run_coul: 0 run_stress: ! |2- 9.9846864346759972e+01 9.1717939805174794e+01 8.7564501381757196e+01 5.9037090269161174e+00 -2.1310430207577928e+00 3.4797921426392381e-01 diff --git a/unittest/force-styles/tests/atomic-pair-eam_fs_real.yaml b/unittest/force-styles/tests/atomic-pair-eam_fs_real.yaml index 290a567708..fb1f8b60c9 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_fs_real.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_fs_real.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:01 2021 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 7.5e-12 skip_tests: single prerequisites: ! | @@ -15,7 +15,7 @@ pair_coeff: ! | * * AlFe_mm.eam.fs Al Fe extract: ! "" natoms: 32 -init_vdwl: -2496.58372622189 +init_vdwl: -2496.583726221894 init_coul: 0 init_stress: ! |2- 2.3033019789742661e+03 2.1157417403924674e+03 2.0201355767292255e+03 1.3625967475023566e+02 -4.9118825128602921e+01 8.0062189596547757e+00 @@ -52,7 +52,7 @@ init_forces: ! |2 30 -2.3924536059675400e+01 -2.6294734320753790e+01 -3.9690770192486177e+01 31 -2.4704253734659591e+00 -5.6516273903225319e+01 2.5013410902965866e+01 32 -1.1056658903666084e+02 -6.7209662311916517e+01 -3.1944424716035719e+01 -run_vdwl: -2496.65480914656 +run_vdwl: -2496.654809146559 run_coul: 0 run_stress: ! |2- 2.3031173686359612e+03 2.1155351475115854e+03 2.0198681219493476e+03 1.3623771207922428e+02 -4.9117004849463832e+01 7.9864065254956884e+00 diff --git a/unittest/force-styles/tests/atomic-pair-eam_he.yaml b/unittest/force-styles/tests/atomic-pair-eam_he.yaml index f2bf098b2f..fb2f00ca58 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_he.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_he.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:01 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-12 skip_tests: single prerequisites: ! | @@ -13,7 +13,7 @@ pair_coeff: ! | * * PdHHe.eam.he Pd He extract: ! "" natoms: 32 -init_vdwl: -15.3146152609365 +init_vdwl: -15.314615260936534 init_coul: 0 init_stress: ! |2- 1.0127679615895376e+02 9.3559970433415444e+01 9.1432412459889193e+01 4.0035576925472673e+00 -9.7686923241135581e-01 2.8980241224200443e+00 @@ -50,7 +50,7 @@ init_forces: ! |2 30 1.1712105233973889e-01 -6.9110122964840481e-01 9.5437848811806628e-02 31 1.9388288555816860e-01 -2.0146460156127194e-01 -2.0863139798712499e-01 32 -8.8731897202011578e-01 -3.3482718789714783e+00 -1.5659784019873610e+00 -run_vdwl: -15.3236335310355 +run_vdwl: -15.323633531035549 run_coul: 0 run_stress: ! |2- 1.0125543392557182e+02 9.3539230810233988e+01 9.1388997082229878e+01 4.0040941706030253e+00 -9.7826716756924303e-01 2.9018476991088571e+00 diff --git a/unittest/force-styles/tests/atomic-pair-eam_he_real.yaml b/unittest/force-styles/tests/atomic-pair-eam_he_real.yaml index b2b198486e..d4cc177b32 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_he_real.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_he_real.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:02 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 7.5e-12 skip_tests: single prerequisites: ! | @@ -14,7 +14,7 @@ pair_coeff: ! | * * PdHHe.eam.he Pd He extract: ! "" natoms: 32 -init_vdwl: -353.163435640974 +init_vdwl: -353.1634356409743 init_coul: 0 init_stress: ! |2- 2.3354985203865667e+03 2.1575442826183294e+03 2.1084816277194832e+03 9.2324238343315059e+01 -2.2527140800613445e+01 6.6830027278251166e+01 @@ -51,7 +51,7 @@ init_forces: ! |2 30 2.7008757664122220e+00 -1.5937173770267322e+01 2.2008491889792485e+00 31 4.4710457826753673e+00 -4.6458843160683996e+00 -4.8111545762194012e+00 32 -2.0462062632899592e+01 -7.7212987730343386e+01 -3.6112321671970648e+01 -run_vdwl: -353.230598025017 +run_vdwl: -353.2305980250169 run_coul: 0 run_stress: ! |2- 2.3352018947327042e+03 2.1575803047701361e+03 2.1079997407908877e+03 9.2286943467903825e+01 -2.2591362673321409e+01 6.6981941401935686e+01 diff --git a/unittest/force-styles/tests/atomic-pair-eam_real.yaml b/unittest/force-styles/tests/atomic-pair-eam_real.yaml index 4d95f04edc..1e0ba40a26 100644 --- a/unittest/force-styles/tests/atomic-pair-eam_real.yaml +++ b/unittest/force-styles/tests/atomic-pair-eam_real.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:02 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:37 2022 epsilon: 5e-12 skip_tests: single prerequisites: ! | @@ -15,7 +15,7 @@ pair_coeff: ! | 2 2 Cu_u3.eam extract: ! "" natoms: 32 -init_vdwl: -8499.72465987996 +init_vdwl: -8499.724659879963 init_coul: 0 init_stress: ! |- -9.0512967456823608e+03 -1.0710884534079103e+04 -9.5331506234443168e+03 4.4739163983539112e+02 2.5624797371065153e+01 2.7908780729994214e+02 @@ -52,7 +52,7 @@ init_forces: ! |2 30 -7.2869896720070074e+01 2.8621045994576787e+02 -7.7726624384065360e+01 31 -1.0966168562269873e+02 4.7983060114616165e+01 2.2592123146266928e+02 32 1.1016957264107174e+02 -8.2701371521245974e+01 -8.3482985240425492e+01 -run_vdwl: -8499.63392113313 +run_vdwl: -8499.633921133134 run_coul: 0 run_stress: ! |- -9.0505794012029874e+03 -1.0710658449701059e+04 -9.5327589626093231e+03 4.4723194233718323e+02 2.5525028652344783e+01 2.7889354001643403e+02 diff --git a/unittest/force-styles/tests/atomic-pair-edip.yaml b/unittest/force-styles/tests/atomic-pair-edip.yaml index 9d01cbaf18..78d533f2b6 100644 --- a/unittest/force-styles/tests/atomic-pair-edip.yaml +++ b/unittest/force-styles/tests/atomic-pair-edip.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable -date_generated: Fri Feb 26 23:09:02 2021 -epsilon: 7e-9 +date_generated: Fri Mar 18 22:17:38 2022 +epsilon: 7e-09 +skip_tests: prerequisites: ! | pair edip pre_commands: ! | @@ -25,7 +26,7 @@ pair_coeff: ! | * * Si.edip Si extract: ! "" natoms: 64 -init_vdwl: -182.014209144965 +init_vdwl: -182.0142091449655 init_coul: 0 init_stress: ! |- -4.2173568991101043e+01 1.2184021199203226e+01 -3.1098538904940661e+01 -6.2316960880482128e+01 -1.4775210621376691e+00 6.1691884248437241e+01 @@ -94,7 +95,7 @@ init_forces: ! |2 62 2.0868620672462157e+00 1.8643759502358841e+00 -4.5632350322176931e+00 63 -3.5570738268026387e+00 2.5008543365267459e+00 1.1838424424360452e+00 64 5.2916520498671140e+00 -6.4110346546503774e+00 2.1951485692450277e+00 -run_vdwl: -182.051160424237 +run_vdwl: -182.05116042423737 run_coul: 0 run_stress: ! |- -4.1363752167737658e+01 1.2469786385410774e+01 -3.0444360293629781e+01 -6.2113035093307580e+01 -1.3949777252200883e+00 6.1189275714908646e+01 diff --git a/unittest/force-styles/tests/atomic-pair-eim.yaml b/unittest/force-styles/tests/atomic-pair-eim.yaml index e705e88614..081e1b4ae3 100644 --- a/unittest/force-styles/tests/atomic-pair-eim.yaml +++ b/unittest/force-styles/tests/atomic-pair-eim.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:02 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 2e-11 +skip_tests: prerequisites: ! | pair eim pre_commands: ! "" @@ -13,7 +14,7 @@ pair_coeff: ! | * * Na Li ffield.eim Li Na extract: ! "" natoms: 32 -init_vdwl: 156.973813987572 +init_vdwl: 156.97381398757182 init_coul: 0 init_stress: ! |2- 3.9849889936779880e+02 3.9964339700077471e+02 4.2394135449088486e+02 1.1463564258428973e+00 -1.0274413432821488e+01 -1.2970065269285907e+01 @@ -50,7 +51,7 @@ init_forces: ! |2 30 -4.4268691057672088e-01 1.8614184084637593e+00 -3.0635131466682086e+00 31 3.1796191004214864e+00 -2.9038638862283421e+00 1.3534160908852291e+01 32 -1.5023162437974118e+01 -1.0281185077172976e+00 1.4167924044403386e+00 -run_vdwl: 156.543907523153 +run_vdwl: 156.54390752315328 run_coul: 0 run_stress: ! |2- 3.9785327522503184e+02 3.9895469050745766e+02 4.2324893277634811e+02 1.1324454072042596e+00 -1.0273666048004785e+01 -1.2969144723625490e+01 diff --git a/unittest/force-styles/tests/atomic-pair-gauss.yaml b/unittest/force-styles/tests/atomic-pair-gauss.yaml index 7d4c2029db..9a6e489ed8 100644 --- a/unittest/force-styles/tests/atomic-pair-gauss.yaml +++ b/unittest/force-styles/tests/atomic-pair-gauss.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:02 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | pair gauss pre_commands: ! "" @@ -13,7 +14,7 @@ pair_coeff: ! | 2 2 0.005 1.1 extract: ! "" natoms: 32 -init_vdwl: -0.563282655796335 +init_vdwl: -0.5632826557963347 init_coul: 0 init_stress: ! |- -7.1147683670454420e-01 -6.1895022673299749e-01 -7.1191426374517874e-01 -1.3771409096140666e-03 8.9168242763744339e-05 -4.5069108788046326e-03 diff --git a/unittest/force-styles/tests/atomic-pair-hybrid-eam.yaml b/unittest/force-styles/tests/atomic-pair-hybrid-eam.yaml index 86b03d3a34..161eb4ed75 100644 --- a/unittest/force-styles/tests/atomic-pair-hybrid-eam.yaml +++ b/unittest/force-styles/tests/atomic-pair-hybrid-eam.yaml @@ -1,8 +1,8 @@ --- -lammps_version: 8 Apr 2021 -date_generated: Mon Apr 19 08:49:08 2021 -epsilon: 2e-10 +lammps_version: 17 Feb 2022 tags: unstable +date_generated: Fri Mar 18 22:17:38 2022 +epsilon: 2e-10 skip_tests: single prerequisites: ! | pair eam/fs diff --git a/unittest/force-styles/tests/atomic-pair-hybrid-eam_fs.yaml b/unittest/force-styles/tests/atomic-pair-hybrid-eam_fs.yaml index 8b9cd93505..0f270b7ce9 100644 --- a/unittest/force-styles/tests/atomic-pair-hybrid-eam_fs.yaml +++ b/unittest/force-styles/tests/atomic-pair-hybrid-eam_fs.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 8 Apr 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Mon Apr 19 08:49:08 2021 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 5e-12 skip_tests: single prerequisites: ! | diff --git a/unittest/force-styles/tests/atomic-pair-lj_relres.yaml b/unittest/force-styles/tests/atomic-pair-lj_relres.yaml index 704bb46785..873713d9e9 100644 --- a/unittest/force-styles/tests/atomic-pair-lj_relres.yaml +++ b/unittest/force-styles/tests/atomic-pair-lj_relres.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Sun Feb 28 23:32:03 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair lj/relres pre_commands: ! "" @@ -14,7 +15,7 @@ pair_coeff: ! | 2 2 0.00121585 3.905 0.00121585 3.905 extract: ! "" natoms: 32 -init_vdwl: 278.180950996338 +init_vdwl: 278.1809509963377 init_coul: 0 init_stress: ! |2- 1.1877397131221412e+03 1.1638761902735005e+03 1.0939934354329380e+03 6.8492993891187240e+01 -3.1686913926055702e+00 -3.0318931219574608e+01 @@ -51,7 +52,7 @@ init_forces: ! |2 30 -8.3053344792491117e+00 -6.7854505410487436e+00 -1.9926676569327796e+01 31 -3.9722675775001202e+00 -2.6202171362782902e+01 1.7034787150328516e+01 32 -4.7637017675627781e+01 -1.6616078530154439e+01 -4.7018745333836263e+00 -run_vdwl: 277.787230338519 +run_vdwl: 277.7872303385192 run_coul: 0 run_stress: ! |2- 1.1861045479571328e+03 1.1621545499754693e+03 1.0925950582629255e+03 6.7871794269310669e+01 -3.2811225906376507e+00 -3.0119921761225132e+01 diff --git a/unittest/force-styles/tests/atomic-pair-meam.yaml b/unittest/force-styles/tests/atomic-pair-meam.yaml index 70bb16a330..2fb166ed54 100644 --- a/unittest/force-styles/tests/atomic-pair-meam.yaml +++ b/unittest/force-styles/tests/atomic-pair-meam.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:03 2021 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 2.5e-12 +skip_tests: prerequisites: ! | pair meam pre_commands: ! | @@ -16,7 +17,7 @@ pair_coeff: ! | extract: ! | scale 2 natoms: 32 -init_vdwl: -45.2270369233974 +init_vdwl: -45.22703692339744 init_coul: 0 init_stress: ! |2- 1.5974961690562833e+02 1.6798912455681204e+02 1.6589208101977775e+02 5.1496570430146571e+00 1.6587548782772799e+01 5.0320981727091478e+00 @@ -53,7 +54,7 @@ init_forces: ! |2 30 7.7479118765962562e-01 -2.0113378117527199e+00 -1.1752517279578472e+00 31 -3.0187614250981643e-01 -1.9390174634551343e+00 1.0383705899546767e+00 32 -1.2004071740323694e+00 -1.7334188099495886e+00 -2.1413667718607474e+00 -run_vdwl: -45.2391567908444 +run_vdwl: -45.23915679084442 run_coul: 0 run_stress: ! |2- 1.5974816998957081e+02 1.6797053429091017e+02 1.6585129043852777e+02 5.1231901045278549e+00 1.6504160483904446e+01 5.0433930663133388e+00 diff --git a/unittest/force-styles/tests/atomic-pair-meam_spline.yaml b/unittest/force-styles/tests/atomic-pair-meam_spline.yaml index 0de2fba11c..41594474b7 100644 --- a/unittest/force-styles/tests/atomic-pair-meam_spline.yaml +++ b/unittest/force-styles/tests/atomic-pair-meam_spline.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:03 2021 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | pair meam/spline pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * TiO.meam.spline Ti O extract: ! "" natoms: 32 -init_vdwl: -135.560024161516 +init_vdwl: -135.5600241615158 init_coul: 0 init_stress: ! |- -1.3297046320597394e+02 -1.4273111356143593e+02 -1.2149083711144338e+02 -9.2199335163098581e+00 -2.3179321272432521e+01 3.4312876715331697e+01 @@ -52,7 +53,7 @@ init_forces: ! |2 30 2.0771077210589186e+00 -4.6709171948180614e+00 1.3782704353736193e+00 31 1.4867111163388858e+00 2.4196890137058618e+00 -1.3329156106123738e+00 32 4.0861876180074033e+00 5.5424831866167956e-01 -2.5681732500505770e+00 -run_vdwl: -135.569915239339 +run_vdwl: -135.56991523933854 run_coul: 0 run_stress: ! |- -1.3297571706861984e+02 -1.4278817708715408e+02 -1.2149323096249972e+02 -9.2133160597589718e+00 -2.3180777117992285e+01 3.4338894527841632e+01 diff --git a/unittest/force-styles/tests/atomic-pair-meam_sw_spline.yaml b/unittest/force-styles/tests/atomic-pair-meam_sw_spline.yaml index 13f1761f8f..0cc9619847 100644 --- a/unittest/force-styles/tests/atomic-pair-meam_sw_spline.yaml +++ b/unittest/force-styles/tests/atomic-pair-meam_sw_spline.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable -date_generated: Fri Feb 26 23:09:03 2021 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair meam/sw/spline pre_commands: ! | @@ -25,7 +26,7 @@ pair_coeff: ! | * * Si.b.meam.sw.spline Si extract: ! "" natoms: 64 -init_vdwl: -110.468577308835 +init_vdwl: -110.4685773088353 init_coul: 0 init_stress: ! |2- 2.0342092779841650e+02 2.9353890615210491e+02 1.9138584169384231e+02 -1.3797329301045073e+02 6.0306018863011829e+01 1.2377595362950453e+02 @@ -94,7 +95,7 @@ init_forces: ! |2 62 3.3475883989333277e+00 1.8378592752954344e+00 -7.1680291906892242e+00 63 -7.7783175923354015e+00 3.7799886336365374e+00 1.0295328521877045e+00 64 3.7357026805307170e+00 -1.3007690662030017e+01 -6.0208957069512170e+00 -run_vdwl: -111.226309291836 +run_vdwl: -111.22630929183559 run_coul: 0 run_stress: ! |2- 2.0268172075658492e+02 2.9202363331200354e+02 1.9043000043817165e+02 -1.3707745415338965e+02 6.0598083239028021e+01 1.2285776451761184e+02 diff --git a/unittest/force-styles/tests/atomic-pair-momb.yaml b/unittest/force-styles/tests/atomic-pair-momb.yaml index 2ee1c80ff0..ecf81fe737 100644 --- a/unittest/force-styles/tests/atomic-pair-momb.yaml +++ b/unittest/force-styles/tests/atomic-pair-momb.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:03 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 2.5e-12 +skip_tests: prerequisites: ! | pair momb pre_commands: ! "" @@ -12,7 +13,7 @@ pair_coeff: ! | * * 6.08 0.317 2.340 24.18 11.51 extract: ! "" natoms: 32 -init_vdwl: -10463.8858411894 +init_vdwl: -10463.885841189409 init_coul: 0 init_stress: ! |- -4.5982351309125661e+03 -4.6159516977505191e+03 -4.5897073530458192e+03 -1.3518810495042906e+01 2.8104075512935403e+00 4.2970059621415224e+00 @@ -49,7 +50,7 @@ init_forces: ! |2 30 -1.2442109923751410e-01 -1.0770559238740045e+00 3.1395720300646190e-02 31 9.2984933250948032e-02 -1.8228335119987582e+00 2.3781726323623342e-01 32 -1.2461785964541576e+00 -5.4977549941894166e-01 8.3509737369560444e-01 -run_vdwl: -10465.7423386717 +run_vdwl: -10465.74233867168 run_coul: 0 run_stress: ! |- -4.5988993884891906e+03 -4.6177101080149896e+03 -4.5915627861079975e+03 -1.2437349307689638e+01 1.7003970965698816e+00 6.1002478300203276e+00 diff --git a/unittest/force-styles/tests/atomic-pair-polymorphic_eam.yaml b/unittest/force-styles/tests/atomic-pair-polymorphic_eam.yaml index b1335906c4..e8a29f76ba 100644 --- a/unittest/force-styles/tests/atomic-pair-polymorphic_eam.yaml +++ b/unittest/force-styles/tests/atomic-pair-polymorphic_eam.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:04 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:38 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | pair polymorphic pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * CuTa_eam.poly Cu Ta extract: ! "" natoms: 32 -init_vdwl: -112.540387935517 +init_vdwl: -112.54038793551683 init_coul: 0 init_stress: ! |2- 1.3377418322776046e+02 1.3013604387391047e+02 1.3325935858051224e+02 1.3759975178496845e+01 -5.1138734367336625e-01 -8.4676793711767679e+00 @@ -52,7 +53,7 @@ init_forces: ! |2 30 -1.1772953098090733e+00 3.5197586410261525e+00 -3.5507225884796605e+00 31 6.9641430977980212e-01 -2.4233846293906267e+00 1.1255702676228792e+01 32 -8.7713084366180301e+00 3.3637284067716072e-01 5.2446663030603202e-01 -run_vdwl: -112.561397617355 +run_vdwl: -112.56139761735514 run_coul: 0 run_stress: ! |2- 1.3369777615744354e+02 1.3004752994085680e+02 1.3320208526824615e+02 1.3747668586704531e+01 -5.2218775435270448e-01 -8.4749563526951750e+00 diff --git a/unittest/force-styles/tests/atomic-pair-reaxff-acks2.yaml b/unittest/force-styles/tests/atomic-pair-reaxff-acks2.yaml index 0026e9d715..a805de7029 100644 --- a/unittest/force-styles/tests/atomic-pair-reaxff-acks2.yaml +++ b/unittest/force-styles/tests/atomic-pair-reaxff-acks2.yaml @@ -1,8 +1,8 @@ --- -lammps_version: 31 Aug 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable -date_generated: Tue Sep 21 15:02:20 2021 -epsilon: 7.5e-9 +date_generated: Fri Mar 18 22:17:38 2022 +epsilon: 7.5e-09 skip_tests: omp prerequisites: ! | pair reaxff diff --git a/unittest/force-styles/tests/atomic-pair-reaxff_noqeq.yaml b/unittest/force-styles/tests/atomic-pair-reaxff_noqeq.yaml index f02caf13cc..64812a6edf 100644 --- a/unittest/force-styles/tests/atomic-pair-reaxff_noqeq.yaml +++ b/unittest/force-styles/tests/atomic-pair-reaxff_noqeq.yaml @@ -1,9 +1,8 @@ --- -lammps_version: 30 Jul 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable -date_generated: Mon Aug 23 20:32:04 2021 +date_generated: Fri Mar 18 22:29:51 2022 epsilon: 2e-11 -tags: unstable skip_tests: prerequisites: ! | pair reaxff diff --git a/unittest/force-styles/tests/atomic-pair-reaxff_tabulate.yaml b/unittest/force-styles/tests/atomic-pair-reaxff_tabulate.yaml index b8d662829b..f8331f0aac 100644 --- a/unittest/force-styles/tests/atomic-pair-reaxff_tabulate.yaml +++ b/unittest/force-styles/tests/atomic-pair-reaxff_tabulate.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 30 Jul 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable, noWindows -date_generated: Mon Aug 23 20:32:05 2021 +date_generated: Fri Mar 18 22:17:41 2022 epsilon: 1e-12 skip_tests: prerequisites: ! | diff --git a/unittest/force-styles/tests/atomic-pair-reaxff_tabulate_flag.yaml b/unittest/force-styles/tests/atomic-pair-reaxff_tabulate_flag.yaml index cc75136ead..e84f1549d7 100644 --- a/unittest/force-styles/tests/atomic-pair-reaxff_tabulate_flag.yaml +++ b/unittest/force-styles/tests/atomic-pair-reaxff_tabulate_flag.yaml @@ -1,7 +1,7 @@ --- lammps_version: 17 Feb 2022 tags: slow, unstable, noWindows -date_generated: Fri Mar 4 16:03:19 2022 +date_generated: Fri Mar 18 22:17:41 2022 epsilon: 1e-10 skip_tests: prerequisites: ! | @@ -37,142 +37,142 @@ pair_coeff: ! | * * ffield.reax.mattsson H C O extract: ! "" natoms: 64 -init_vdwl: -3296.3503506626625 -init_coul: -327.06551252279456 +init_vdwl: -3296.3503506626616 +init_coul: -327.0655125227951 init_stress: ! |- - -1.0522112314767783e+03 -1.2629480788300502e+03 -8.6765541430814096e+02 -2.5149818635818667e+02 2.0624598409312171e+02 -6.4309968343212176e+02 + -1.0522112314767739e+03 -1.2629480788300507e+03 -8.6765541430813960e+02 -2.5149818635818815e+02 2.0624598409312082e+02 -6.4309968343211722e+02 init_forces: ! |2 - 1 -8.8484559491556311e+01 -2.5824737864573919e+01 1.0916228789487879e+02 - 2 -1.1227736122977259e+02 -1.8092349731667591e+02 -2.2420586526897358e+02 - 3 -1.7210817575848930e+02 1.8292439782307812e+02 1.3552618819707996e+01 - 4 3.2997500231077133e+01 -5.1076027616179566e+01 9.0475628837081729e+01 - 5 1.8144778146276320e+02 1.6797701000584901e+01 -8.1725507301130719e+01 - 6 1.3634094180728027e+02 -3.0056789473999606e+02 2.9661495129812735e+01 - 7 -5.3287158661290654e+01 -1.2872927610193426e+02 -1.6347871108898190e+02 - 8 -1.5334883257588743e+02 4.0171483324132673e+01 1.5317461163040247e+02 - 9 1.8364155867626707e+01 8.1986572088184730e+01 2.8272397798085997e+01 - 10 8.4246730110716001e+01 1.4177487113457059e+02 1.2330079878579895e+02 - 11 -4.3218423112503736e+01 6.5551082199269430e+01 1.3464882148701872e+02 - 12 -9.7317470492946029e+01 -2.6234999414165394e+01 7.2277941881737986e+00 - 13 -6.3183329836750751e+01 -4.7368101002963456e+01 -3.7592654029327335e+01 - 14 7.8642975316494343e+01 -6.7997612991911723e+01 -9.9044775614588801e+01 - 15 -6.6373732796047989e+01 2.1787558547533163e+02 8.0103149369097395e+01 - 16 1.9216166082224797e+02 5.3228015320736127e+01 6.6260214054225145e+01 - 17 1.4496007689503486e+02 -3.9700923044581373e+01 -9.7503851828125278e+01 - 18 -4.4989550233791114e+01 -1.9360605894359682e+02 1.1274792197022767e+02 - 19 2.6657528138946049e+02 3.7189510796653087e+02 -3.3847307488286714e+02 - 20 -7.6341040242475458e+01 -8.8478925962195476e+01 1.3557778211945350e+00 - 21 -7.1188591900927975e+01 -5.1591439985149563e+01 -1.2279442803768845e+02 - 22 1.5504836733040739e+02 -1.3094504458747133e+02 8.1474408030773787e+01 - 23 7.8015302036850315e+01 -1.3272310040531950e+01 -2.2771427736555761e+01 - 24 -2.0546718065740683e+02 2.1611071031056338e+02 -1.2423208053538573e+02 - 25 -1.1402686646199389e+02 1.9100238121127509e+02 -8.3504908417575109e+01 - 26 2.8663576552100710e+02 -2.1773884754172596e+02 2.3144300100085047e+02 - 27 -6.3247409025600724e+01 6.9122196748088982e+01 1.8606936744368682e+02 - 28 -3.5426011056021354e+00 3.8764809029448436e+01 3.2874001946771685e+01 - 29 -7.1069178571898220e+01 3.5485903180456084e+01 2.7311648896337775e+01 - 30 -1.7036987830119276e+02 -1.9851827590032582e+02 -1.1511401829122866e+02 - 31 -1.3970409889743564e+02 1.6660943915627308e+02 -1.2913930522474990e+02 - 32 2.7179130444097289e+01 -6.0169059447608035e+01 -1.7669495182016857e+02 - 33 -6.2659679124097778e+01 -6.4422131921802787e+01 6.4150928205326551e+01 - 34 -2.2119065265688906e+01 1.0450386886831188e+02 -7.3998379587547575e+01 - 35 2.6982987783289082e+02 -2.1519317040004481e+02 1.3051628460667428e+02 - 36 1.0368628874510237e+02 1.8817377639771817e+02 -1.9748944223862600e+02 - 37 -1.8009522406830379e+02 1.2993653092252060e+02 -6.3523043394127292e+01 - 38 -2.9571205878459318e+02 1.0441609933480134e+02 1.5582204859043426e+02 - 39 8.7398805727037910e+01 -6.0025559644662437e+01 2.2209742009840294e+01 - 40 2.0540672579010501e+01 -1.0735874009092470e+02 5.8655918369889896e+01 - 41 -5.8895846271433264e+01 1.1852345624580526e+01 -6.6147257724520202e+01 - 42 -9.6895512314625066e+01 3.8928741136637001e+01 -7.5791929957169600e+01 - 43 2.2476051812062838e+02 9.5505204283227684e+01 1.2309042240718360e+02 - 44 8.9817373579481654e+01 -1.0616333580629222e+02 -8.6321519086261901e+01 - 45 1.7202629662563513e+01 1.2890307246702790e+02 5.2916171301120244e+01 - 46 1.3547783972599857e+01 -2.9276223331262678e+01 2.2187412696868783e+01 - 47 3.3389762514713034e+01 -1.9217585014964843e+02 -6.9956213241084782e+01 - 48 7.3631720332058023e+01 -2.0953007324684350e+02 -2.3183566221369460e+01 - 49 -3.7589944473226200e+02 -2.4083165714761812e+01 1.0770339502610176e+02 - 50 3.8603083564804351e+01 -7.3616481568807856e+01 9.0414065019653634e+01 - 51 1.3736420686697048e+02 -1.0204157331499390e+02 1.5813725581140869e+02 - 52 -1.0797257051088970e+02 1.1876975735152035e+02 -1.3295758126487456e+02 - 53 -5.3807540206216466e+01 3.3259462625846481e+02 -3.8426832264377708e-03 - 54 -1.0690184616179764e+01 6.2820270853641873e+01 1.8343158343322312e+02 - 55 1.1231900459987538e+02 -1.7906654831317351e+02 7.6533681064342247e+01 - 56 -4.1027190034880718e+01 -1.4085413191126113e+02 3.7483064289929565e+01 - 57 9.9904315214043478e+01 7.0938939080466696e+01 -6.8654961257655216e+01 - 58 -2.7563642882025157e+01 -6.7445498717118166e+00 -1.8442640542825114e+01 - 59 -6.6628933617811725e+01 1.0613066354106411e+02 8.7736153919801964e+01 - 60 -1.7748415247445266e+01 6.3757605316885879e+01 -1.5086907478327478e+02 - 61 -3.3560907195794982e+01 -1.0076987083174131e+02 -7.4536106106935335e+01 - 62 1.5883428926665676e+01 -5.8433760297919051e+00 2.8392494016028817e+01 - 63 1.3294494001299771e+02 -1.2724568063769999e+02 -6.4886848316829841e+01 - 64 1.0738157273931067e+02 1.2062173788161793e+02 7.4541400611720690e+01 -run_vdwl: -3296.3468823779367 -run_coul: -327.065399507389 + 1 -8.8484559491556382e+01 -2.5824737864573983e+01 1.0916228789487873e+02 + 2 -1.1227736122977277e+02 -1.8092349731667605e+02 -2.2420586526897370e+02 + 3 -1.7210817575848947e+02 1.8292439782307875e+02 1.3552618819708533e+01 + 4 3.2997500231077154e+01 -5.1076027616179601e+01 9.0475628837081842e+01 + 5 1.8144778146276349e+02 1.6797701000585050e+01 -8.1725507301130364e+01 + 6 1.3634094180728192e+02 -3.0056789473999623e+02 2.9661495129810405e+01 + 7 -5.3287158661290789e+01 -1.2872927610193449e+02 -1.6347871108898252e+02 + 8 -1.5334883257588743e+02 4.0171483324132680e+01 1.5317461163040250e+02 + 9 1.8364155867626959e+01 8.1986572088184701e+01 2.8272397798085894e+01 + 10 8.4246730110715987e+01 1.4177487113457067e+02 1.2330079878579899e+02 + 11 -4.3218423112503842e+01 6.5551082199269587e+01 1.3464882148701912e+02 + 12 -9.7317470492945631e+01 -2.6234999414165472e+01 7.2277941881737764e+00 + 13 -6.3183329836750836e+01 -4.7368101002963598e+01 -3.7592654029327193e+01 + 14 7.8642975316494244e+01 -6.7997612991911694e+01 -9.9044775614588744e+01 + 15 -6.6373732796047932e+01 2.1787558547533155e+02 8.0103149369097338e+01 + 16 1.9216166082224782e+02 5.3228015320736134e+01 6.6260214054225131e+01 + 17 1.4496007689503503e+02 -3.9700923044581437e+01 -9.7503851828125505e+01 + 18 -4.4989550233791071e+01 -1.9360605894359685e+02 1.1274792197022768e+02 + 19 2.6657528138946020e+02 3.7189510796653042e+02 -3.3847307488286617e+02 + 20 -7.6341040242475444e+01 -8.8478925962195433e+01 1.3557778211944747e+00 + 21 -7.1188591900927975e+01 -5.1591439985149663e+01 -1.2279442803768826e+02 + 22 1.5504836733040739e+02 -1.3094504458747130e+02 8.1474408030773745e+01 + 23 7.8015302036850684e+01 -1.3272310040531675e+01 -2.2771427736555765e+01 + 24 -2.0546718065740677e+02 2.1611071031056295e+02 -1.2423208053538556e+02 + 25 -1.1402686646199388e+02 1.9100238121127512e+02 -8.3504908417575137e+01 + 26 2.8663576552100676e+02 -2.1773884754172562e+02 2.3144300100085067e+02 + 27 -6.3247409025600703e+01 6.9122196748089010e+01 1.8606936744368679e+02 + 28 -3.5426011056020812e+00 3.8764809029448422e+01 3.2874001946771756e+01 + 29 -7.1069178571897908e+01 3.5485903180455900e+01 2.7311648896337541e+01 + 30 -1.7036987830119247e+02 -1.9851827590032605e+02 -1.1511401829122852e+02 + 31 -1.3970409889743564e+02 1.6660943915627317e+02 -1.2913930522474985e+02 + 32 2.7179130444097446e+01 -6.0169059447608205e+01 -1.7669495182016888e+02 + 33 -6.2659679124097771e+01 -6.4422131921802787e+01 6.4150928205326565e+01 + 34 -2.2119065265688945e+01 1.0450386886831190e+02 -7.3998379587547589e+01 + 35 2.6982987783289036e+02 -2.1519317040004464e+02 1.3051628460667473e+02 + 36 1.0368628874510270e+02 1.8817377639771777e+02 -1.9748944223862577e+02 + 37 -1.8009522406830411e+02 1.2993653092252046e+02 -6.3523043394127271e+01 + 38 -2.9571205878459335e+02 1.0441609933480150e+02 1.5582204859043446e+02 + 39 8.7398805727037654e+01 -6.0025559644662380e+01 2.2209742009840170e+01 + 40 2.0540672579010515e+01 -1.0735874009092471e+02 5.8655918369889903e+01 + 41 -5.8895846271433207e+01 1.1852345624580465e+01 -6.6147257724520060e+01 + 42 -9.6895512314625066e+01 3.8928741136637136e+01 -7.5791929957169501e+01 + 43 2.2476051812062840e+02 9.5505204283227812e+01 1.2309042240718378e+02 + 44 8.9817373579481696e+01 -1.0616333580629221e+02 -8.6321519086262015e+01 + 45 1.7202629662563449e+01 1.2890307246702787e+02 5.2916171301120116e+01 + 46 1.3547783972599687e+01 -2.9276223331262454e+01 2.2187412696868645e+01 + 47 3.3389762514712750e+01 -1.9217585014964845e+02 -6.9956213241085010e+01 + 48 7.3631720332058350e+01 -2.0953007324684327e+02 -2.3183566221369695e+01 + 49 -3.7589944473226365e+02 -2.4083165714761193e+01 1.0770339502610332e+02 + 50 3.8603083564804365e+01 -7.3616481568807856e+01 9.0414065019653606e+01 + 51 1.3736420686697036e+02 -1.0204157331499393e+02 1.5813725581140881e+02 + 52 -1.0797257051088971e+02 1.1876975735152031e+02 -1.3295758126487445e+02 + 53 -5.3807540206216601e+01 3.3259462625846481e+02 -3.8426832264590871e-03 + 54 -1.0690184616179629e+01 6.2820270853641588e+01 1.8343158343322301e+02 + 55 1.1231900459987541e+02 -1.7906654831317354e+02 7.6533681064342233e+01 + 56 -4.1027190034880071e+01 -1.4085413191126139e+02 3.7483064289929089e+01 + 57 9.9904315214043436e+01 7.0938939080466611e+01 -6.8654961257655273e+01 + 58 -2.7563642882025118e+01 -6.7445498717118797e+00 -1.8442640542825089e+01 + 59 -6.6628933617811782e+01 1.0613066354106414e+02 8.7736153919801936e+01 + 60 -1.7748415247445365e+01 6.3757605316886128e+01 -1.5086907478327481e+02 + 61 -3.3560907195794940e+01 -1.0076987083174126e+02 -7.4536106106935293e+01 + 62 1.5883428926665619e+01 -5.8433760297918971e+00 2.8392494016028731e+01 + 63 1.3294494001299765e+02 -1.2724568063770006e+02 -6.4886848316829756e+01 + 64 1.0738157273931063e+02 1.2062173788161793e+02 7.4541400611720547e+01 +run_vdwl: -3296.346882377935 +run_coul: -327.0653995073889 run_stress: ! |- - -1.0521225462933094e+03 -1.2628780139897610e+03 -8.6757617693170891e+02 -2.5158592653599595e+02 2.0619472152439258e+02 -6.4312943979319141e+02 + -1.0521225462933053e+03 -1.2628780139897558e+03 -8.6757617693171233e+02 -2.5158592653599607e+02 2.0619472152439226e+02 -6.4312943979318675e+02 run_forces: ! |2 - 1 -8.8486129396000166e+01 -2.5824483374468670e+01 1.0916517213634302e+02 - 2 -1.1227648453174439e+02 -1.8093214754186079e+02 -2.2420118533941442e+02 - 3 -1.7210894875994904e+02 1.8292263268450841e+02 1.3551979435674342e+01 - 4 3.2999405001001634e+01 -5.1077312719540167e+01 9.0478579144055772e+01 - 5 1.8144963583124775e+02 1.6798391906829387e+01 -8.1723378082079023e+01 - 6 1.3640835897739180e+02 -3.0059507544861378e+02 2.9594750460791829e+01 - 7 -5.3287619129788197e+01 -1.2872953167027578e+02 -1.6348317368624896e+02 - 8 -1.5334990952322417e+02 4.0171746946782790e+01 1.5317542403105386e+02 - 9 1.8362961213920698e+01 8.1984428717781981e+01 2.8273598253031487e+01 - 10 8.4245458094792369e+01 1.4177227430519417e+02 1.2329899933660860e+02 - 11 -4.3217035356327358e+01 6.5547850976490437e+01 1.3463983671941662e+02 - 12 -9.7319343004584653e+01 -2.6236499899243690e+01 7.2232061905837615e+00 - 13 -6.3184735475527191e+01 -4.7368090836529937e+01 -3.7590268076048019e+01 - 14 7.8642680121812262e+01 -6.7994653297660548e+01 -9.9042134233426268e+01 - 15 -6.6371195967091907e+01 2.1787700653340673e+02 8.0102624694811539e+01 - 16 1.9215832443893075e+02 5.3231888618096207e+01 6.6253846562708489e+01 - 17 1.4496126989603599e+02 -3.9700366098755531e+01 -9.7506725874205443e+01 - 18 -4.4989211400009481e+01 -1.9360716191976402e+02 1.1274798810456159e+02 - 19 2.6657546213783030e+02 3.7189369483259844e+02 -3.3847202166066995e+02 - 20 -7.6352829159886937e+01 -8.8469178952293859e+01 1.3384778816960481e+00 - 21 -7.1188597560669123e+01 -5.1592404200753641e+01 -1.2279357314243131e+02 - 22 1.5504965184742042e+02 -1.3094582932681607e+02 8.1473922626951364e+01 - 23 7.8017376001381663e+01 -1.3263023728618043e+01 -2.2771654676285653e+01 - 24 -2.0547634460481828e+02 2.1612342044351524e+02 -1.2423651650061259e+02 - 25 -1.1402944116092229e+02 1.9100648219390607e+02 -8.3505645569840254e+01 - 26 2.8664542299412386e+02 -2.1774609219882657e+02 2.3144720166991996e+02 - 27 -6.3243843868032563e+01 6.9123801262967206e+01 1.8607035157681565e+02 - 28 -3.5444604842081140e+00 3.8760531647711296e+01 3.2869123667284754e+01 - 29 -7.1069494158200598e+01 3.5486459158788925e+01 2.7311657876198531e+01 - 30 -1.7037059987991734e+02 -1.9851840131670701e+02 -1.1511410156294959e+02 - 31 -1.3970663440086241e+02 1.6660841802304265e+02 -1.2914070628113083e+02 - 32 2.7179939937123105e+01 -6.0162678551463884e+01 -1.7668459764112279e+02 - 33 -6.2659124615696278e+01 -6.4421915847949109e+01 6.4151176691093482e+01 - 34 -2.2118740875414915e+01 1.0450303589341836e+02 -7.3997370482692659e+01 - 35 2.6987081482971496e+02 -2.1523754104001341e+02 1.3052736086177524e+02 - 36 1.0368798521809144e+02 1.8816694370717582e+02 -1.9748485159165222e+02 - 37 -1.8012152563997313e+02 1.2997662140310993e+02 -6.3547259053662522e+01 - 38 -2.9571525697590329e+02 1.0441941743732623e+02 1.5582112543443273e+02 - 39 8.7399620724583841e+01 -6.0025787992404162e+01 2.2209357601285014e+01 - 40 2.0541458171950477e+01 -1.0735817059033120e+02 5.8656280350522032e+01 - 41 -5.8893965304960815e+01 1.1850504754255629e+01 -6.6138932258972176e+01 - 42 -9.6894702780974512e+01 3.8926449644122947e+01 -7.5794133002818526e+01 - 43 2.2475651760389809e+02 9.5503072846826768e+01 1.2308683766845004e+02 - 44 8.9821846939836348e+01 -1.0615882525758133e+02 -8.6326896770196470e+01 - 45 1.7193681344320954e+01 1.2889564928825573e+02 5.2922372841304153e+01 - 46 1.3549091739277978e+01 -2.9276447091759906e+01 2.2187152043657633e+01 - 47 3.3389460345593953e+01 -1.9217121673024195e+02 -6.9954603582949176e+01 - 48 7.3644268618797824e+01 -2.0953201921818757e+02 -2.3192562071377562e+01 - 49 -3.7593958318939679e+02 -2.4028439106858276e+01 1.0779151134440338e+02 - 50 3.8603926624309238e+01 -7.3615255297997734e+01 9.0412505212301156e+01 - 51 1.3736689552205240e+02 -1.0204490780180460e+02 1.5814099219642884e+02 - 52 -1.0797151154268900e+02 1.1876989597627048e+02 -1.3296150756378307e+02 - 53 -5.3843453069379677e+01 3.3257024143948763e+02 -2.3416395286659508e-02 - 54 -1.0678049522660388e+01 6.2807424617051886e+01 1.8344969045861680e+02 - 55 1.1232135576105590e+02 -1.7906994470562014e+02 7.6534265234549295e+01 - 56 -4.1035945990490148e+01 -1.4084577238057466e+02 3.7489705598222940e+01 - 57 9.9903872061949016e+01 7.0936213558029195e+01 -6.8656338416446374e+01 - 58 -2.7563844572722473e+01 -6.7426705471903592e+00 -1.8442803060446948e+01 - 59 -6.6637290503326199e+01 1.0613630918456350e+02 8.7741455199743768e+01 - 60 -1.7749706497443679e+01 6.3756413885649771e+01 -1.5086911682893657e+02 - 61 -3.3559889608753309e+01 -1.0076809277084797e+02 -7.4536003122045500e+01 - 62 1.5883833834736830e+01 -5.8439916924713566e+00 2.8393403991140676e+01 - 63 1.3294237052897739e+02 -1.2724619636182949e+02 -6.4882384014241481e+01 - 64 1.0738250214939015e+02 1.2062290362869132e+02 7.4541927445538889e+01 + 1 -8.8486129396000024e+01 -2.5824483374468659e+01 1.0916517213634297e+02 + 2 -1.1227648453174452e+02 -1.8093214754186096e+02 -2.2420118533941474e+02 + 3 -1.7210894875994919e+02 1.8292263268450859e+02 1.3551979435673994e+01 + 4 3.2999405001001179e+01 -5.1077312719540231e+01 9.0478579144055786e+01 + 5 1.8144963583124817e+02 1.6798391906829522e+01 -8.1723378082078895e+01 + 6 1.3640835897739544e+02 -3.0059507544861526e+02 2.9594750460787722e+01 + 7 -5.3287619129788126e+01 -1.2872953167027580e+02 -1.6348317368624893e+02 + 8 -1.5334990952322408e+02 4.0171746946782811e+01 1.5317542403105384e+02 + 9 1.8362961213920283e+01 8.1984428717781938e+01 2.8273598253031842e+01 + 10 8.4245458094792667e+01 1.4177227430519451e+02 1.2329899933660883e+02 + 11 -4.3217035356327344e+01 6.5547850976490480e+01 1.3463983671941662e+02 + 12 -9.7319343004584368e+01 -2.6236499899243547e+01 7.2232061905835634e+00 + 13 -6.3184735475527845e+01 -4.7368090836530385e+01 -3.7590268076047799e+01 + 14 7.8642680121811978e+01 -6.7994653297660861e+01 -9.9042134233426623e+01 + 15 -6.6371195967091822e+01 2.1787700653340664e+02 8.0102624694811567e+01 + 16 1.9215832443892984e+02 5.3231888618095191e+01 6.6253846562709271e+01 + 17 1.4496126989603567e+02 -3.9700366098754984e+01 -9.7506725874204676e+01 + 18 -4.4989211400009445e+01 -1.9360716191976400e+02 1.1274798810456160e+02 + 19 2.6657546213783013e+02 3.7189369483259810e+02 -3.3847202166066938e+02 + 20 -7.6352829159886866e+01 -8.8469178952293888e+01 1.3384778816960941e+00 + 21 -7.1188597560668626e+01 -5.1592404200752988e+01 -1.2279357314243077e+02 + 22 1.5504965184742042e+02 -1.3094582932681604e+02 8.1473922626951349e+01 + 23 7.8017376001382075e+01 -1.3263023728617453e+01 -2.2771654676285650e+01 + 24 -2.0547634460481828e+02 2.1612342044351584e+02 -1.2423651650061315e+02 + 25 -1.1402944116092222e+02 1.9100648219390598e+02 -8.3505645569840212e+01 + 26 2.8664542299412409e+02 -2.1774609219882660e+02 2.3144720166992016e+02 + 27 -6.3243843868032656e+01 6.9123801262967206e+01 1.8607035157681563e+02 + 28 -3.5444604842081215e+00 3.8760531647711197e+01 3.2869123667284832e+01 + 29 -7.1069494158200399e+01 3.5486459158788790e+01 2.7311657876198385e+01 + 30 -1.7037059987991728e+02 -1.9851840131670684e+02 -1.1511410156294964e+02 + 31 -1.3970663440086241e+02 1.6660841802304273e+02 -1.2914070628113075e+02 + 32 2.7179939937123169e+01 -6.0162678551463856e+01 -1.7668459764112271e+02 + 33 -6.2659124615696278e+01 -6.4421915847949094e+01 6.4151176691093468e+01 + 34 -2.2118740875414911e+01 1.0450303589341824e+02 -7.3997370482692702e+01 + 35 2.6987081482971610e+02 -2.1523754104001401e+02 1.3052736086177433e+02 + 36 1.0368798521809174e+02 1.8816694370717531e+02 -1.9748485159165185e+02 + 37 -1.8012152563997321e+02 1.2997662140310976e+02 -6.3547259053662522e+01 + 38 -2.9571525697590181e+02 1.0441941743732498e+02 1.5582112543443168e+02 + 39 8.7399620724583912e+01 -6.0025787992404332e+01 2.2209357601285220e+01 + 40 2.0541458171950481e+01 -1.0735817059033118e+02 5.8656280350522010e+01 + 41 -5.8893965304960851e+01 1.1850504754255528e+01 -6.6138932258972062e+01 + 42 -9.6894702780974654e+01 3.8926449644123046e+01 -7.5794133002818327e+01 + 43 2.2475651760389815e+02 9.5503072846826939e+01 1.2308683766845016e+02 + 44 8.9821846939836348e+01 -1.0615882525758136e+02 -8.6326896770196470e+01 + 45 1.7193681344320908e+01 1.2889564928825573e+02 5.2922372841304046e+01 + 46 1.3549091739277930e+01 -2.9276447091759820e+01 2.2187152043657580e+01 + 47 3.3389460345593911e+01 -1.9217121673024212e+02 -6.9954603582949275e+01 + 48 7.3644268618798534e+01 -2.0953201921818703e+02 -2.3192562071378255e+01 + 49 -3.7593958318940093e+02 -2.4028439106856851e+01 1.0779151134440758e+02 + 50 3.8603926624309118e+01 -7.3615255297997692e+01 9.0412505212301113e+01 + 51 1.3736689552205237e+02 -1.0204490780180465e+02 1.5814099219642898e+02 + 52 -1.0797151154268903e+02 1.1876989597627045e+02 -1.3296150756378304e+02 + 53 -5.3843453069379898e+01 3.3257024143948752e+02 -2.3416395286623981e-02 + 54 -1.0678049522660420e+01 6.2807424617051971e+01 1.8344969045861674e+02 + 55 1.1232135576105584e+02 -1.7906994470562006e+02 7.6534265234549238e+01 + 56 -4.1035945990491449e+01 -1.4084577238057412e+02 3.7489705598223743e+01 + 57 9.9903872061949045e+01 7.0936213558029181e+01 -6.8656338416446431e+01 + 58 -2.7563844572722548e+01 -6.7426705471903254e+00 -1.8442803060446984e+01 + 59 -6.6637290503326170e+01 1.0613630918456353e+02 8.7741455199743655e+01 + 60 -1.7749706497443636e+01 6.3756413885649643e+01 -1.5086911682893643e+02 + 61 -3.3559889608753323e+01 -1.0076809277084797e+02 -7.4536003122045486e+01 + 62 1.5883833834736718e+01 -5.8439916924713371e+00 2.8393403991140676e+01 + 63 1.3294237052897660e+02 -1.2724619636182842e+02 -6.4882384014242263e+01 + 64 1.0738250214939008e+02 1.2062290362869123e+02 7.4541927445538832e+01 ... diff --git a/unittest/force-styles/tests/atomic-pair-table_bitmap.yaml b/unittest/force-styles/tests/atomic-pair-table_bitmap.yaml index e9df0744c6..e6aee11771 100644 --- a/unittest/force-styles/tests/atomic-pair-table_bitmap.yaml +++ b/unittest/force-styles/tests/atomic-pair-table_bitmap.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:09 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:41 2022 epsilon: 2e-12 +skip_tests: prerequisites: ! | pair table pre_commands: ! "" @@ -12,7 +13,7 @@ pair_coeff: ! | * * ${input_dir}/pair_table_bitmap.txt beck_1_1 extract: ! "" natoms: 32 -init_vdwl: 1.66863069929167 +init_vdwl: 1.668630699291665 init_coul: 0 init_stress: ! |2- 6.1952827280949752e+00 6.0616458078803026e+00 5.8879068387604203e+00 2.0730193733654706e-01 -2.1217457971568116e-02 -8.9424946009241696e-02 @@ -49,7 +50,7 @@ init_forces: ! |2 30 -4.2584465166652936e-02 -3.0054615946788474e-02 -8.4428957096643942e-02 31 -2.0649926244740491e-02 -1.1590442114762316e-01 7.4794527710849712e-02 32 -1.9354598378544019e-01 -6.3287613853627508e-02 -2.2278111493111191e-02 -run_vdwl: 1.66856268800034 +run_vdwl: 1.6685626880003446 run_coul: 0 run_stress: ! |2- 6.1952311663382620e+00 6.0614392437022566e+00 5.8875647278117054e+00 2.0717006197774884e-01 -2.1333105104445964e-02 -8.9586451595579902e-02 diff --git a/unittest/force-styles/tests/atomic-pair-table_linear.yaml b/unittest/force-styles/tests/atomic-pair-table_linear.yaml index 2a0e88e8ca..412f03970e 100644 --- a/unittest/force-styles/tests/atomic-pair-table_linear.yaml +++ b/unittest/force-styles/tests/atomic-pair-table_linear.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:10 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:41 2022 epsilon: 2e-12 +skip_tests: prerequisites: ! | pair table pre_commands: ! "" @@ -14,7 +15,7 @@ pair_coeff: ! | 2 2 ${input_dir}/pair_table_beck.txt beck_2_2 extract: ! "" natoms: 32 -init_vdwl: 1.66849758741132 +init_vdwl: 1.668497587411317 init_coul: 0 init_stress: ! |2- 6.1946715433684973e+00 6.0610621944595691e+00 5.8874237884568794e+00 2.0726669272562587e-01 -2.1210093847498168e-02 -8.9416411707758034e-02 @@ -51,7 +52,7 @@ init_forces: ! |2 30 -4.2587368463202192e-02 -3.0047436022746527e-02 -8.4421201266270535e-02 31 -2.0646231349659299e-02 -1.1590205379082782e-01 7.4785818423894770e-02 32 -1.9352068689594826e-01 -6.3282139756026798e-02 -2.2278655095207611e-02 -run_vdwl: 1.66842874884356 +run_vdwl: 1.6684287488435634 run_coul: 0 run_stress: ! |2- 6.1946185356811014e+00 6.0608444906913288e+00 5.8870835095750591e+00 2.0713242742857005e-01 -2.1315300788911050e-02 -8.9580203233208117e-02 diff --git a/unittest/force-styles/tests/atomic-pair-table_lookup.yaml b/unittest/force-styles/tests/atomic-pair-table_lookup.yaml index 8752fa49a8..e148e2dadb 100644 --- a/unittest/force-styles/tests/atomic-pair-table_lookup.yaml +++ b/unittest/force-styles/tests/atomic-pair-table_lookup.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:10 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:42 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair table pre_commands: ! "" @@ -14,7 +15,7 @@ pair_coeff: ! | 2 2 ${input_dir}/pair_table_beck.txt beck_2_2 extract: ! "" natoms: 32 -init_vdwl: 1.66822081098814 +init_vdwl: 1.668220810988136 init_coul: 0 init_stress: ! |2- 6.1925708391090373e+00 6.0607873158796632e+00 5.8866502515961283e+00 2.0635047994864009e-01 -2.2304749096038870e-02 -8.9977381381968910e-02 @@ -51,7 +52,7 @@ init_forces: ! |2 30 -4.2678491461167409e-02 -3.0167096740169222e-02 -8.4323491798094938e-02 31 -2.0446963122925290e-02 -1.1577119295225209e-01 7.4834425292344492e-02 32 -1.9338210089853922e-01 -6.2777766271189708e-02 -2.2198626823726184e-02 -run_vdwl: 1.66836471086472 +run_vdwl: 1.6683647108647246 run_coul: 0 run_stress: ! |2- 6.1942043291654469e+00 6.0612653540830586e+00 5.8861497905111531e+00 2.0800105441755243e-01 -2.1762342247091705e-02 -9.1029111210449057e-02 diff --git a/unittest/force-styles/tests/atomic-pair-table_spline.yaml b/unittest/force-styles/tests/atomic-pair-table_spline.yaml index 9fce2192a5..1162de1a00 100644 --- a/unittest/force-styles/tests/atomic-pair-table_spline.yaml +++ b/unittest/force-styles/tests/atomic-pair-table_spline.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:10 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:42 2022 epsilon: 2e-12 +skip_tests: prerequisites: ! | pair table pre_commands: ! "" @@ -14,7 +15,7 @@ pair_coeff: ! | 2 2 ${input_dir}/pair_table_beck.txt beck_2_2 extract: ! "" natoms: 32 -init_vdwl: 1.66849237317226 +init_vdwl: 1.6684923731722567 init_coul: 0 init_stress: ! |2- 6.1946491697735437e+00 6.0610401365658024e+00 5.8874025724620429e+00 2.0726580316940962e-01 -2.1210361695457737e-02 -8.9415208770840096e-02 @@ -51,7 +52,7 @@ init_forces: ! |2 30 -4.2587398133307960e-02 -3.0047443784418228e-02 -8.4420705386072381e-02 31 -2.0646215207926085e-02 -1.1590108886476506e-01 7.4785520470549566e-02 32 -1.9351936740994052e-01 -6.3281923890906297e-02 -2.2278650628172247e-02 -run_vdwl: 1.66842322373739 +run_vdwl: 1.6684232237373946 run_coul: 0 run_stress: ! |2- 6.1945944680219887e+00 6.0608212867624980e+00 5.8870610546441418e+00 2.0713169827359051e-01 -2.1315981269016338e-02 -8.9579349983669246e-02 diff --git a/unittest/force-styles/tests/atomic-pair-yukawa_colloid.yaml b/unittest/force-styles/tests/atomic-pair-yukawa_colloid.yaml index d807696e63..b0dc86ce0c 100644 --- a/unittest/force-styles/tests/atomic-pair-yukawa_colloid.yaml +++ b/unittest/force-styles/tests/atomic-pair-yukawa_colloid.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:10 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:42 2022 epsilon: 2e-13 skip_tests: single prerequisites: ! | @@ -24,7 +24,7 @@ pair_coeff: ! | 2 2 1.0 extract: ! "" natoms: 27 -init_vdwl: 1707.69163115118 +init_vdwl: 1707.691631151183 init_coul: 0 init_stress: ! |2- 2.4925595248180834e+03 1.1916297836190974e+04 4.2828223324219935e+03 -6.2926457403782319e+02 -1.7226034441498136e+03 5.5422724571118408e+02 @@ -56,7 +56,7 @@ init_forces: ! |2 25 3.9091258782696285e+00 -3.5326654057532719e-01 4.7334165925855037e-01 26 -6.0742511180270498e+01 2.1819250139897854e+01 -8.7460910512647203e+00 27 5.1550993740012451e+01 2.7042786325070402e+01 1.3526090147715118e+01 -run_vdwl: 1323.07868576666 +run_vdwl: 1323.0786857666649 run_coul: 0 run_stress: ! |2- 2.1967177306554954e+03 8.5663931752326953e+03 3.8861287529537371e+03 -4.2921958355450886e+02 -1.4997587809515621e+03 2.8001183019458591e+02 diff --git a/unittest/force-styles/tests/bond-class2.yaml b/unittest/force-styles/tests/bond-class2.yaml index a7c9d37cf3..42c73346a6 100644 --- a/unittest/force-styles/tests/bond-class2.yaml +++ b/unittest/force-styles/tests/bond-class2.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 4e-13 +skip_tests: prerequisites: ! | atom full bond class2 @@ -19,7 +20,7 @@ equilibrium: 5 1.42 1.1 1.3 1.2 0.97 extract: ! | r0 1 natoms: 29 -init_energy: 26.4298596421327 +init_energy: 26.429859642132705 init_stress: ! |- -3.0141734112468595e+02 -3.1150388091129679e+02 -2.6058470202224748e+02 -1.9292943555936553e+01 -1.4107089561246062e+00 1.2759470887440076e+01 init_forces: ! |2 @@ -52,7 +53,7 @@ init_forces: ! |2 27 2.2674229580362422e+00 3.6953663496240573e+01 -8.8003614900515856e+00 28 2.1551008635816927e+01 -9.2616399704789991e+00 1.4581621559271095e+01 29 -2.3818431593853170e+01 -2.7692023525761574e+01 -5.7812600692195097e+00 -run_energy: 26.0946187265871 +run_energy: 26.09461872658714 run_stress: ! |- -2.9913778299462206e+02 -3.1023436598826180e+02 -2.6088287404513943e+02 -1.8712697455436544e+01 -1.1958498347651703e-01 1.3198910331468596e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-fene.yaml b/unittest/force-styles/tests/bond-fene.yaml index 00b66e2466..88c02574cb 100644 --- a/unittest/force-styles/tests/bond-fene.yaml +++ b/unittest/force-styles/tests/bond-fene.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond fene @@ -20,7 +21,7 @@ extract: ! | kappa 1 r0 1 natoms: 29 -init_energy: 7104.90048646724 +init_energy: 7104.900486467235 init_stress: ! |- -4.9948251498286945e+03 -4.7340263125122983e+03 -6.8013808554851912e+03 -2.4245897042972433e+02 -6.6838292208179359e+02 -4.4352973682370884e+02 init_forces: ! |2 @@ -53,7 +54,7 @@ init_forces: ! |2 27 -7.4105937747798123e+01 6.5722929360523858e+02 -2.2054278458154329e+02 28 4.6683896868291521e+02 -2.0062608322401542e+02 3.1586777609755433e+02 29 -3.9273303093511709e+02 -4.5660321038122316e+02 -9.5324991516011053e+01 -run_energy: 7049.62378855647 +run_energy: 7049.623788556474 run_stress: ! |- -4.9516947557536578e+03 -4.6967963286139684e+03 -6.7329756531097837e+03 -2.3212662371402772e+02 -6.5980197715716599e+02 -4.4431032503962462e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-fene_expand.yaml b/unittest/force-styles/tests/bond-fene_expand.yaml index f29213e126..fc859d477c 100644 --- a/unittest/force-styles/tests/bond-fene_expand.yaml +++ b/unittest/force-styles/tests/bond-fene_expand.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond fene/expand @@ -18,7 +19,7 @@ bond_coeff: ! | equilibrium: 5 1.5550000000000002 1.117 1.321 1.3139999999999998 1.06 extract: ! "" natoms: 29 -init_energy: 5926.02085912429 +init_energy: 5926.020859124294 init_stress: ! |- -4.4174665507749878e+03 -4.2320578947897247e+03 -5.8644836994169109e+03 -1.6285898653137428e+02 -6.2814567943242105e+02 -3.6789143362234518e+02 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 -6.3329315340599010e+01 5.6398417998805996e+02 -1.8910602077885551e+02 28 4.0041383936090841e+02 -1.7207959413995059e+02 2.7092388905417050e+02 29 -3.3708452402030940e+02 -3.9190458584810938e+02 -8.1817868275314979e+01 -run_energy: 5884.76273364903 +run_energy: 5884.762733649028 run_stress: ! |- -4.3845231413255087e+03 -4.2028636554336808e+03 -5.8135612975015601e+03 -1.5544208427397948e+02 -6.2071051485646331e+02 -3.6919986493529041e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-fene_nm.yaml b/unittest/force-styles/tests/bond-fene_nm.yaml index 3877257e18..c6be31a1c3 100644 --- a/unittest/force-styles/tests/bond-fene_nm.yaml +++ b/unittest/force-styles/tests/bond-fene_nm.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 27 Oct 2021 -date_generated: Fri Dec 3 14:19:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 2.5e-13 skip_tests: prerequisites: ! | @@ -23,7 +23,7 @@ extract: ! | natoms: 29 init_energy: 7104.538647187164 init_stress: ! |- - -4.9973815323625913e+03 -4.7361840472269523e+03 -6.8040395883503370e+03 -2.4269128277669373e+02 -6.6891138241387910e+02 -4.4331343074095361e+02 + -4.9973815323625913e+03 -4.7361840472269523e+03 -6.8040395883503370e+03 -2.4269128277669367e+02 -6.6891138241387910e+02 -4.4331343074095361e+02 init_forces: ! |2 1 1.5241450143465187e+02 -3.0525977546573915e+02 -6.3458098267970195e+02 2 -3.5350460570830404e+02 -2.9090700339261923e+02 4.1606484768643804e+02 @@ -56,7 +56,7 @@ init_forces: ! |2 29 -3.9296232463985876e+02 -4.5686979412503501e+02 -9.5380646168758574e+01 run_energy: 7049.171322970109 run_stress: ! |- - -4.9544161293431789e+03 -4.6990550365348445e+03 -6.7357951494828403e+03 -2.3243877860807157e+02 -6.6038849056571530e+02 -4.4410638672086759e+02 + -4.9544161293431789e+03 -4.6990550365348445e+03 -6.7357951494828403e+03 -2.3243877860807152e+02 -6.6038849056571541e+02 -4.4410638672086759e+02 run_forces: ! |2 1 1.4925184076342319e+02 -3.0497744106969486e+02 -6.2784067871414572e+02 2 -3.5055563426526174e+02 -2.8969290648665157e+02 4.1046831743568976e+02 diff --git a/unittest/force-styles/tests/bond-gaussian.yaml b/unittest/force-styles/tests/bond-gaussian.yaml index 944ff630c6..e6e259b32a 100644 --- a/unittest/force-styles/tests/bond-gaussian.yaml +++ b/unittest/force-styles/tests/bond-gaussian.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 1e-12 +skip_tests: prerequisites: ! | atom full bond gaussian @@ -18,7 +19,7 @@ bond_coeff: ! | equilibrium: 5 1.45 1.37 1.61 2.45 2.85 extract: ! "" natoms: 29 -init_energy: 194.978038221632 +init_energy: 194.9780382216324 init_stress: ! |- -2.4024989684355553e+01 -3.8521513996632500e+01 -1.0851224048428129e+01 1.2562604359180053e+01 1.3677283516797356e+01 4.3206731051245653e+00 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 -1.5677247388593395e-295 -1.8232011058192963e-295 -3.8038051984576450e-296 28 -3.2483754529644398e-299 1.3960035208884715e-299 -2.1978823514938368e-299 29 1.5680495764046360e-295 1.8230615054672073e-295 3.8060030808091389e-296 -run_energy: 194.96889016686 +run_energy: 194.9688901668597 run_stress: ! |- -2.4084235648269384e+01 -3.8596877573973650e+01 -1.0971337511117875e+01 1.2627485208541385e+01 1.3589007837800324e+01 4.4518443361436777e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-gromos.yaml b/unittest/force-styles/tests/bond-gromos.yaml index 13ad366fed..a2f7e7ef3e 100644 --- a/unittest/force-styles/tests/bond-gromos.yaml +++ b/unittest/force-styles/tests/bond-gromos.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full bond gromos @@ -20,7 +21,7 @@ extract: ! | kappa 1 r0 1 natoms: 29 -init_energy: 33.7093041764133 +init_energy: 33.70930417641326 init_stress: ! |- -4.9434621198085694e+02 -8.4488926562658799e+02 -5.9511281447935380e+02 4.2664504799973329e+01 1.0460761950422788e+02 -3.0526296320246485e+02 init_forces: ! |2 @@ -53,7 +54,7 @@ init_forces: ! |2 27 2.7144514843627896e+01 2.5934786050804597e+01 8.1210486636920063e+00 28 -3.5319623664811428e+00 1.5178762340275660e+00 -2.3897600089130737e+00 29 -2.3612552477146753e+01 -2.7452662284832162e+01 -5.7312886547789326e+00 -run_energy: 32.0991086197953 +run_energy: 32.09910861979532 run_stress: ! |- -4.8073464794278550e+02 -8.2777900460692445e+02 -5.9322822048461876e+02 4.4602479100490783e+01 1.0572617600226262e+02 -2.9197894291678909e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-harmonic.yaml b/unittest/force-styles/tests/bond-harmonic.yaml index a277586a2e..9ee14c07b9 100644 --- a/unittest/force-styles/tests/bond-harmonic.yaml +++ b/unittest/force-styles/tests/bond-harmonic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond harmonic @@ -20,7 +21,7 @@ extract: ! | kappa 1 r0 1 natoms: 29 -init_energy: 4.78937402460125 +init_energy: 4.789374024601252 init_stress: ! |- -7.8339576416581650e+01 -1.1712828041794818e+02 -9.5949529209186267e+01 -7.1916460767231181e+00 8.3588128261115031e+00 -4.3565947473672914e+01 init_forces: ! |2 @@ -53,7 +54,7 @@ init_forces: ! |2 27 6.6999960289138851e+00 6.3808952243186141e+00 2.0100808779497248e+00 28 -8.8466157439236681e-01 3.8018717064230995e-01 -5.9857060538593476e-01 29 -5.8153344545215182e+00 -6.7610823949609244e+00 -1.4115102725637900e+00 -run_energy: 4.7237520119515 +run_energy: 4.723752011951501 run_stress: ! |- -7.6702592470736434e+01 -1.1639544474609609e+02 -9.6841110072418118e+01 -6.8952957303727382e+00 9.8789736990719863e+00 -4.2701363825407341e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-harmonic_shift.yaml b/unittest/force-styles/tests/bond-harmonic_shift.yaml index 9726574bee..7a41c2c3cd 100644 --- a/unittest/force-styles/tests/bond-harmonic_shift.yaml +++ b/unittest/force-styles/tests/bond-harmonic_shift.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:22 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond harmonic/shift @@ -18,7 +19,7 @@ bond_coeff: ! | equilibrium: 5 1.5 1.1 1.3 1.2 1 extract: ! "" natoms: 29 -init_energy: -9395.51998238922 +init_energy: -9395.519982389222 init_stress: ! |- -7.4157725479720014e+01 -1.0985432613306406e+02 -9.0786041395098124e+01 -1.2882237218533907e+01 3.8669006214694366e+00 -4.3423090375618628e+01 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 6.6999960289138851e+00 6.3808952243186141e+00 2.0100808779497248e+00 28 -8.8466157439236681e-01 3.8018717064230995e-01 -5.9857060538593476e-01 29 -5.8153344545215182e+00 -6.7610823949609244e+00 -1.4115102725637900e+00 -run_energy: -9395.58703375226 +run_energy: -9395.587033752257 run_stress: ! |- -7.2589447210536790e+01 -1.0904313328767000e+02 -9.1935234541261991e+01 -1.2612420335553994e+01 5.3299965845050163e+00 -4.2659944975395902e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-hybrid.yaml b/unittest/force-styles/tests/bond-hybrid.yaml index 44d4579aa2..295f8eaceb 100644 --- a/unittest/force-styles/tests/bond-hybrid.yaml +++ b/unittest/force-styles/tests/bond-hybrid.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:22 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond morse @@ -19,7 +20,7 @@ bond_coeff: ! | equilibrium: 5 1.5 1.1 1.3 1.2 1 extract: ! "" natoms: 29 -init_energy: 4.63957309438403 +init_energy: 4.6395730943840325 init_stress: ! |- -9.1714487491693831e+01 -1.1475291850911708e+02 -9.7902687629822026e+01 3.3666145598018780e+00 2.9841452462201108e+00 -4.0641761740546514e+01 init_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-mm3.yaml b/unittest/force-styles/tests/bond-mm3.yaml index 4e4c2c19d3..eb7443f1c2 100644 --- a/unittest/force-styles/tests/bond-mm3.yaml +++ b/unittest/force-styles/tests/bond-mm3.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:22 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond mm3 @@ -18,7 +19,7 @@ bond_coeff: ! | equilibrium: 5 1.5 1.1 1.3 1.2 1 extract: ! "" natoms: 29 -init_energy: 4.24726500827314 +init_energy: 4.247265008273143 init_stress: ! |- -6.7744998484360764e+01 -9.5585989576869679e+01 -8.3988124269631498e+01 -8.3514180518301018e+00 7.6430554343700976e+00 -3.5840387791140266e+01 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 6.4855564979522047e+00 6.1247764189743465e+00 1.9598858571712741e+00 28 -8.8893502113952572e-01 3.8202370302341726e-01 -6.0146206092167276e-01 29 -5.5966214768126790e+00 -6.5068001219977640e+00 -1.3584237962496013e+00 -run_energy: 4.19044466577423 +run_energy: 4.190444665774225 run_stress: ! |- -6.6268610382869184e+01 -9.5040491696347843e+01 -8.5107222328949291e+01 -8.0841795048724130e+00 9.0152703577335060e+00 -3.5164253155520257e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-morse.yaml b/unittest/force-styles/tests/bond-morse.yaml index ba76e2f153..d17e1db97e 100644 --- a/unittest/force-styles/tests/bond-morse.yaml +++ b/unittest/force-styles/tests/bond-morse.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:22 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond morse @@ -19,7 +20,7 @@ equilibrium: 5 1.5 1.1 1.3 1.2 1 extract: ! | r0 1 natoms: 29 -init_energy: 5.60715454070921 +init_energy: 5.607154540709207 init_stress: ! |- -1.1365471352755087e+02 -1.3117272554114714e+02 -1.4763909124402684e+02 4.5922194837084724e+00 1.3188910497152156e+01 -4.9709355153349769e+01 init_forces: ! |2 @@ -52,7 +53,7 @@ init_forces: ! |2 27 9.3440280239221600e+00 8.8903193246933316e+00 2.8056881098030990e+00 28 -1.2392285181626443e+00 5.3256386141007839e-01 -8.3847404001650405e-01 29 -8.1047995057595159e+00 -9.4228831861034106e+00 -1.9672140697865950e+00 -run_energy: 5.50926684761431 +run_energy: 5.509266847614305 run_stress: ! |- -1.1113687839145564e+02 -1.3016150889234359e+02 -1.4923388171903545e+02 4.8767723596840229e+00 1.5143403262342982e+01 -4.8751226987843182e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-nonlinear.yaml b/unittest/force-styles/tests/bond-nonlinear.yaml index ef4f59df5b..ae52190dd9 100644 --- a/unittest/force-styles/tests/bond-nonlinear.yaml +++ b/unittest/force-styles/tests/bond-nonlinear.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:22 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full bond nonlinear @@ -18,7 +19,7 @@ bond_coeff: ! | equilibrium: 5 1.5 1.1 1.3 1.2 1 extract: ! "" natoms: 29 -init_energy: 1.94517280328209 +init_energy: 1.9451728032820943 init_stress: ! |- -4.6285156743941478e+01 -4.7612744010814460e+01 -5.4259238719546723e+01 -6.1403939411158568e+00 1.2501743297533752e-01 -1.4681360384097960e+01 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 5.5379883350610015e+00 5.2743959614633891e+00 1.6614192482961685e+00 28 -7.3112718591878911e-01 3.1420509745216413e-01 -4.9468774835180696e-01 29 -4.8068611491422129e+00 -5.5886010589155530e+00 -1.1667314999443616e+00 -run_energy: 1.91075164149706 +run_energy: 1.9107516414970596 run_stress: ! |- -4.4707234295634244e+01 -4.7122785809543416e+01 -5.4247920545231537e+01 -6.0088885887139973e+00 1.7708076256400471e+00 -1.4186901411651000e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-quartic.yaml b/unittest/force-styles/tests/bond-quartic.yaml index 9d49991d5a..99cd52149f 100644 --- a/unittest/force-styles/tests/bond-quartic.yaml +++ b/unittest/force-styles/tests/bond-quartic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:22 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond quartic @@ -24,7 +25,7 @@ bond_coeff: ! | equilibrium: 5 0.97 0.97 0.97 0.97 0.97 extract: ! "" natoms: 29 -init_energy: 167209.410281733 +init_energy: 167209.41028173303 init_stress: ! |2- 1.1753456675032635e+05 1.3835980307256946e+05 1.5724445231627452e+05 -2.7936859754795376e+04 -1.2046754178952258e+03 5.6387492312733202e+03 init_forces: ! |2 @@ -57,7 +58,7 @@ init_forces: ! |2 27 8.5984161170060497e+02 -5.9701302410694389e+03 2.1078126071300521e+03 28 -4.3769632510310885e+03 1.8810190502032892e+03 -2.9614958067113644e+03 29 3.5171216393304835e+03 4.0891111908661501e+03 8.5368319958131212e+02 -run_energy: 149949.975299821 +run_energy: 149949.97529982057 run_stress: ! |2- 1.1559313036629684e+05 1.3470803777015215e+05 1.4770452427692583e+05 -3.0214612515800167e+04 -2.7173569285153673e+02 8.0043369128736695e+03 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-table_linear.yaml b/unittest/force-styles/tests/bond-table_linear.yaml index b2ffe6360a..2776121733 100644 --- a/unittest/force-styles/tests/bond-table_linear.yaml +++ b/unittest/force-styles/tests/bond-table_linear.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:22 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond table @@ -18,7 +19,7 @@ bond_coeff: ! | equilibrium: 5 1.5 1.1 1.3 1.2 1 extract: ! "" natoms: 29 -init_energy: 4.83475893645922 +init_energy: 4.834758936459218 init_stress: ! |- -7.8339576416560021e+01 -1.1712828041795603e+02 -9.5949529209341051e+01 -7.1916460767468138e+00 8.3588128261263588e+00 -4.3565947473665872e+01 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 6.6999960289139739e+00 6.3808952243177526e+00 2.0100808779500099e+00 28 -8.8466157439297377e-01 3.8018717064257085e-01 -5.9857060538634543e-01 29 -5.8153344545210004e+00 -6.7610823949603231e+00 -1.4115102725636643e+00 -run_energy: 4.76945838689915 +run_energy: 4.769458386899153 run_stress: ! |- -7.6702592470712077e+01 -1.1639544474610237e+02 -9.6841110072560340e+01 -6.8952957303959987e+00 9.8789736990903076e+00 -4.2701363825397813e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/bond-table_spline.yaml b/unittest/force-styles/tests/bond-table_spline.yaml index 3b4ffe462e..2ec6f03910 100644 --- a/unittest/force-styles/tests/bond-table_spline.yaml +++ b/unittest/force-styles/tests/bond-table_spline.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:23 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:51 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full bond table @@ -18,7 +19,7 @@ bond_coeff: ! | equilibrium: 5 1.5 1.1 1.3 1.2 1 extract: ! "" natoms: 29 -init_energy: 4.78937402460163 +init_energy: 4.789374024601631 init_stress: ! |- -7.8339576416559382e+01 -1.1712828041795541e+02 -9.5949529209340994e+01 -7.1916460767470944e+00 8.3588128261270160e+00 -4.3565947473665510e+01 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 6.6999960289139757e+00 6.3808952243177517e+00 2.0100808779500108e+00 28 -8.8466157439297488e-01 3.8018717064257129e-01 -5.9857060538634621e-01 29 -5.8153344545210004e+00 -6.7610823949603231e+00 -1.4115102725636643e+00 -run_energy: 4.72375201195192 +run_energy: 4.7237520119519205 run_stress: ! |- -7.6702592470711849e+01 -1.1639544474610187e+02 -9.6841110072560610e+01 -6.8952957303961480e+00 9.8789736990907233e+00 -4.2701363825397443e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-charmm.yaml b/unittest/force-styles/tests/dihedral-charmm.yaml index 471e85de89..ddba14cb4f 100644 --- a/unittest/force-styles/tests/dihedral-charmm.yaml +++ b/unittest/force-styles/tests/dihedral-charmm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:34 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral charmm @@ -20,7 +21,7 @@ dihedral_coeff: ! | 5 19.0 3 90 1.0 extract: ! "" natoms: 29 -init_energy: 1317.95984412099 +init_energy: 1317.959844120986 init_stress: ! |2- 1.1266474992363544e+02 -1.4270359924600960e+01 -9.8394389999034431e+01 -1.4122826669412839e+02 1.1178234052730829e+02 -5.8711817976295805e+01 init_forces: ! |2 @@ -53,7 +54,7 @@ init_forces: ! |2 27 -1.3095161641895547e+00 -1.2565785999785013e+00 1.5351009379260916e-01 28 6.7218786721800217e-01 7.6800634603799567e-01 -1.7119977008252721e-01 29 1.1932647806568950e+00 6.9156748341000629e-01 4.6792179831738293e-02 -run_energy: 1317.13089096787 +run_energy: 1317.1308909678705 run_stress: ! |2- 1.1432326918192217e+02 -1.5602913994604187e+01 -9.8720355187318063e+01 -1.4093459949789184e+02 1.1435885495687606e+02 -5.7664013010033671e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-charmmfsw.yaml b/unittest/force-styles/tests/dihedral-charmmfsw.yaml index 0f0a76c8de..fa8e706578 100644 --- a/unittest/force-styles/tests/dihedral-charmmfsw.yaml +++ b/unittest/force-styles/tests/dihedral-charmmfsw.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:34 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral charmmfsw @@ -20,7 +21,7 @@ dihedral_coeff: ! | 5 19.0 3 90 1.0 extract: ! "" natoms: 29 -init_energy: 1317.95984412099 +init_energy: 1317.959844120986 init_stress: ! |2- 1.1266474992363544e+02 -1.4270359924600960e+01 -9.8394389999034431e+01 -1.4122826669412839e+02 1.1178234052730829e+02 -5.8711817976295805e+01 init_forces: ! |2 @@ -53,7 +54,7 @@ init_forces: ! |2 27 -7.5085140414840501e-01 -2.1332740916449014e-01 -3.4556428061080330e-01 28 3.0509542011027740e-01 4.6221002204910822e-02 8.8498260667955922e-02 29 1.1311031171809240e+00 4.1894808967987129e-01 6.1703656720310460e-02 -run_energy: 1317.13142783318 +run_energy: 1317.131427833181 run_stress: ! |2- 1.1432271538886499e+02 -1.5603844203952541e+01 -9.8718871184912416e+01 -1.4093580634465189e+02 1.1435865928680047e+02 -5.7664143378423546e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-class2.yaml b/unittest/force-styles/tests/dihedral-class2.yaml index 9dfcc918a5..b041d4ebcb 100644 --- a/unittest/force-styles/tests/dihedral-class2.yaml +++ b/unittest/force-styles/tests/dihedral-class2.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:34 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 8e-13 +skip_tests: prerequisites: ! | atom full dihedral class2 @@ -18,7 +19,7 @@ dihedral_coeff: ! | * bb13 75 1.4 1.4 extract: ! "" natoms: 29 -init_energy: 3355.00747173759 +init_energy: 3355.0074717375933 init_stress: ! |2- 2.1875123407705587e+01 -7.3463171958190321e+02 7.0422332087828568e+02 -2.0890942199873339e+02 -3.6451752675970380e+02 1.3400265327626121e+02 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 3232.22368557986 +run_energy: 3232.2236855798583 run_stress: ! |2- 3.4186200218682700e+01 -7.5351720154542477e+02 5.8894003293457865e+02 -1.4452761583493597e+02 -3.8479488337510423e+02 1.2221118941124658e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-cosine_shift_exp.yaml b/unittest/force-styles/tests/dihedral-cosine_shift_exp.yaml index 806a65bd8a..e6c88e5906 100644 --- a/unittest/force-styles/tests/dihedral-cosine_shift_exp.yaml +++ b/unittest/force-styles/tests/dihedral-cosine_shift_exp.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:34 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral cosine/shift/exp @@ -17,7 +18,7 @@ dihedral_coeff: ! | 5 19 90 2.1 extract: ! "" natoms: 29 -init_energy: -252.253036379603 +init_energy: -252.25303637960297 init_stress: ! |2- 1.2648173379127915e+01 9.8987186508472114e+00 -2.2546892029975140e+01 -4.8774048841283184e+00 2.3394385854749725e+01 8.0008046681362437e+00 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: -252.29533087732 +run_energy: -252.2953308773198 run_stress: ! |2- 1.2679233523358512e+01 9.9049911944774891e+00 -2.2584224717836005e+01 -4.9222953229219746e+00 2.3439232765403958e+01 8.0455044326920557e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-fourier.yaml b/unittest/force-styles/tests/dihedral-fourier.yaml index 84b5d8f920..14f8e3d5c4 100644 --- a/unittest/force-styles/tests/dihedral-fourier.yaml +++ b/unittest/force-styles/tests/dihedral-fourier.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:35 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral fourier @@ -17,7 +18,7 @@ dihedral_coeff: ! | 5 5 75 1 120 42 2 140 35 2 160 21 2 110 10 2 20 extract: ! "" natoms: 29 -init_energy: 4237.11651056645 +init_energy: 4237.116510566447 init_stress: ! |- -1.3707440529302690e+02 -1.1775005714687839e+02 2.5482446243990526e+02 -6.0912155352783621e+01 -5.1858430299845004e+01 6.0101035915715130e+01 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 4233.36580637715 +run_energy: 4233.365806377151 run_stress: ! |- -1.3658608701216593e+02 -1.1640355380892572e+02 2.5298964082109160e+02 -5.9498600086177774e+01 -5.3758494802170190e+01 5.9305904454019270e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-harmonic.yaml b/unittest/force-styles/tests/dihedral-harmonic.yaml index 6c54a96142..4b2a33b78a 100644 --- a/unittest/force-styles/tests/dihedral-harmonic.yaml +++ b/unittest/force-styles/tests/dihedral-harmonic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:35 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral harmonic @@ -17,7 +18,7 @@ dihedral_coeff: ! | 5 19.0 -1 3 extract: ! "" natoms: 29 -init_energy: 789.17395858648 +init_energy: 789.1739585864799 init_stress: ! |- -6.2042484436524219e+01 1.2714037725306221e+02 -6.5097892816538135e+01 2.6648135399224223e+01 1.3495574921305175e+02 1.6236422290928121e+02 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 786.186635855008 +run_energy: 786.1866358550078 run_stress: ! |- -6.1891690150881182e+01 1.2738938495389695e+02 -6.5497694803015833e+01 2.6197221636385819e+01 1.3475397071041999e+02 1.6145289649182780e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-helix.yaml b/unittest/force-styles/tests/dihedral-helix.yaml index f775cd2164..e2372c8809 100644 --- a/unittest/force-styles/tests/dihedral-helix.yaml +++ b/unittest/force-styles/tests/dihedral-helix.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:35 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 4e-13 +skip_tests: prerequisites: ! | atom full dihedral helix @@ -17,7 +18,7 @@ dihedral_coeff: ! | 5 19 90 13 extract: ! "" natoms: 29 -init_energy: 4634.43654570767 +init_energy: 4634.436545707672 init_stress: ! |- -8.0823732518007063e+01 9.9479187244686372e+01 -1.8655454726675949e+01 3.1101576556766464e+01 7.4461883645297817e+01 4.1747530138691431e+01 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 4604.29767615419 +run_energy: 4604.297676154192 run_stress: ! |- -7.9493088618049043e+01 1.0569468868590617e+02 -2.6201600067857370e+01 4.3225252542366661e+01 6.6510401367367706e+01 3.7958321007398133e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-hybrid.yaml b/unittest/force-styles/tests/dihedral-hybrid.yaml index 4747958fab..4c499a8511 100644 --- a/unittest/force-styles/tests/dihedral-hybrid.yaml +++ b/unittest/force-styles/tests/dihedral-hybrid.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:35 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral harmonic @@ -18,7 +19,7 @@ dihedral_coeff: ! | 5 opls 19 90 13 15 extract: ! "" natoms: 29 -init_energy: 1501.66406241746 +init_energy: 1501.6640624174602 init_stress: ! |- -2.4645376253219257e+02 2.3613233899749815e+01 2.2284052863244389e+02 -1.0599361078821747e+02 1.5465939277742063e+02 2.1207702997596056e+02 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 1495.65001965091 +run_energy: 1495.650019650912 run_stress: ! |- -2.4383465439885845e+02 2.5649599381834832e+01 2.1818505501701961e+02 -1.0616938394760371e+02 1.5358337500265804e+02 2.1056893001808325e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-multi_harmonic.yaml b/unittest/force-styles/tests/dihedral-multi_harmonic.yaml index 71c5c1927a..567e61ad7f 100644 --- a/unittest/force-styles/tests/dihedral-multi_harmonic.yaml +++ b/unittest/force-styles/tests/dihedral-multi_harmonic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:35 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full dihedral multi/harmonic @@ -17,7 +18,7 @@ dihedral_coeff: ! | 5 19 90 13 15 58 extract: ! "" natoms: 29 -init_energy: 2854.98573165667 +init_energy: 2854.9857316566695 init_stress: ! |2- 1.5681915450818258e+02 1.8843677355938829e+02 -3.4525592806757135e+02 1.8730498639126836e+02 3.9598161309144100e+00 -4.8403883145099769e+01 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 2849.07207400097 +run_energy: 2849.0720740009674 run_stress: ! |2- 1.6000445937817227e+02 1.9195362353354110e+02 -3.5195808291171227e+02 1.9139433603598457e+02 1.5540720550179767e+00 -4.9876733950141848e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-nharmonic.yaml b/unittest/force-styles/tests/dihedral-nharmonic.yaml index 564864a636..6d0e4c0bc3 100644 --- a/unittest/force-styles/tests/dihedral-nharmonic.yaml +++ b/unittest/force-styles/tests/dihedral-nharmonic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:35 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral nharmonic @@ -17,7 +18,7 @@ dihedral_coeff: ! | 5 5 75 42 35 21 10 extract: ! "" natoms: 29 -init_energy: 2981.00073511673 +init_energy: 2981.000735116725 init_stress: ! |2- 9.7597564011001154e+01 5.1552482481468100e+00 -1.0275281225914760e+02 1.8493829126960399e+01 -2.0812476993720594e+01 -1.8522149185389509e+01 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 2980.50579322915 +run_energy: 2980.505793229148 run_stress: ! |2- 9.7895434490619337e+01 5.4213709524395828e+00 -1.0331680544305857e+02 1.8675877873066675e+01 -2.0991434453341569e+01 -1.8585983190992422e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-opls.yaml b/unittest/force-styles/tests/dihedral-opls.yaml index 03164e2c36..7cf3578d1e 100644 --- a/unittest/force-styles/tests/dihedral-opls.yaml +++ b/unittest/force-styles/tests/dihedral-opls.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:35 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral opls @@ -17,7 +18,7 @@ dihedral_coeff: ! | 5 19 90 13 15 extract: ! "" natoms: 29 -init_energy: 2260.68345252858 +init_energy: 2260.6834525285753 init_stress: ! |- -3.2511829957222659e+02 -2.5747791683620072e+01 3.5086609125584744e+02 -1.7284868467618747e+02 2.1513133474621105e+02 1.2517993158427078e+02 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 2256.24323239172 +run_energy: 2256.2432323917246 run_stress: ! |- -3.2088111205783395e+02 -2.5173179880186485e+01 3.4605429193802195e+02 -1.7344996511494091e+02 2.1594264221200305e+02 1.2609209164416541e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-quadratic.yaml b/unittest/force-styles/tests/dihedral-quadratic.yaml index e335e7d822..21ddf42df0 100644 --- a/unittest/force-styles/tests/dihedral-quadratic.yaml +++ b/unittest/force-styles/tests/dihedral-quadratic.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: unstable -date_generated: Fri Feb 26 23:09:35 2021 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 1e-12 +skip_tests: prerequisites: ! | atom full dihedral quadratic @@ -18,7 +19,7 @@ dihedral_coeff: ! | 5 85 120 extract: ! "" natoms: 29 -init_energy: 6216.3143470666 +init_energy: 6216.314347066598 init_stress: ! |2- 6.9779660668723466e+01 -3.5532909094858701e+02 2.8554943027986320e+02 -4.9195840209475091e+02 7.3625341259057109e+02 -5.7010808043243844e+02 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 6196.72060735877 +run_energy: 6196.720607358772 run_stress: ! |2- 7.0261972144691427e+01 -3.5373405634218659e+02 2.8347208419750029e+02 -4.8865483402926805e+02 7.2876073597774234e+02 -5.6606999011775088e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-table_cut_linear.yaml b/unittest/force-styles/tests/dihedral-table_cut_linear.yaml index 00894aecdb..5c8f53e31f 100644 --- a/unittest/force-styles/tests/dihedral-table_cut_linear.yaml +++ b/unittest/force-styles/tests/dihedral-table_cut_linear.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Mar 2021 +lammps_version: 17 Feb 2022 tags: unstable -date_generated: Tue Mar 23 08:05:02 202 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | atom full dihedral table/cut @@ -51,7 +52,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 549.782031215547 +run_energy: 549.7820312155467 run_stress: ! |- -7.5056949042919044e+01 1.3698944188847955e+02 -6.1932492845560127e+01 3.3581673544215263e+01 1.2888596290133776e+02 1.9565093507759894e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-table_cut_spline.yaml b/unittest/force-styles/tests/dihedral-table_cut_spline.yaml index 2fabbed8f9..be637652a0 100644 --- a/unittest/force-styles/tests/dihedral-table_cut_spline.yaml +++ b/unittest/force-styles/tests/dihedral-table_cut_spline.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Tue Mar 23 08:06:45 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full dihedral table/cut @@ -17,7 +18,7 @@ dihedral_coeff: ! | 5 aat 0.25 170 175 ${input_dir}/harmonic_dihedral.txt HARMONIC_5 extract: ! "" natoms: 29 -init_energy: 552.218725263499 +init_energy: 552.2187252634994 init_stress: ! |- -7.4019824552159534e+01 1.3649499111894895e+02 -6.2475166566789284e+01 3.4617375151088808e+01 1.3019745657214429e+02 1.9709007795400348e+02 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 549.770211120194 +run_energy: 549.7702111201936 run_stress: ! |- -7.5054671721636595e+01 1.3699895801893166e+02 -6.1944286297295179e+01 3.3587137063275613e+01 1.2891678447538322e+02 1.9568224888755336e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-table_linear.yaml b/unittest/force-styles/tests/dihedral-table_linear.yaml index d114e86b81..e79aee7d47 100644 --- a/unittest/force-styles/tests/dihedral-table_linear.yaml +++ b/unittest/force-styles/tests/dihedral-table_linear.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Mar 2021 +lammps_version: 17 Feb 2022 tags: unstable -date_generated: Mon Mar 22 21:19:05 202 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full dihedral table @@ -18,7 +19,7 @@ dihedral_coeff: ! | 5 ${input_dir}/harmonic_dihedral.txt HARMONIC_5 extract: ! "" natoms: 29 -init_energy: 789.184256783584 +init_energy: 789.1842567835844 init_stress: ! |- -1.6165501104216639e+02 -7.4114380315441565e+01 2.3576939135760787e+02 -2.3488521541598647e+02 3.4341737187983938e+02 -1.5959461001900144e+02 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 786.199103735512 +run_energy: 786.1991037355119 run_stress: ! |- -1.5979555001643004e+02 -7.4781079673606996e+01 2.3457662969003690e+02 -2.3349637150864024e+02 3.4159374485946643e+02 -1.5956254217954015e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/dihedral-table_spline.yaml b/unittest/force-styles/tests/dihedral-table_spline.yaml index 17c90b86d3..a9537906b5 100644 --- a/unittest/force-styles/tests/dihedral-table_spline.yaml +++ b/unittest/force-styles/tests/dihedral-table_spline.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Mon Mar 22 21:19:05 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | atom full dihedral table @@ -50,16 +51,16 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 786.186636054773 +run_energy: 786.1866360547726 run_stress: ! |- -1.5982910389343505e+02 -7.4774149450379937e+01 2.3460325334381506e+02 -2.3353349487854388e+02 3.4161194489304893e+02 -1.5958869300328692e+02 run_forces: ! |2 1 -2.2302877568136338e+01 4.0672550148970281e+01 -9.0501596555606994e+01 2 -7.6795596366469354e+00 3.9696255711631245e+00 -3.7581781934774909e+00 - 3 9.2113037896352481e+01 -1.3743858578373496e+02 8.2424527928857074e+01 - 4 -4.8297128431903225e+01 -8.1171172458509702e+00 6.4789088257516795e+01 + 3 9.2113037896352495e+01 -1.3743858578373496e+02 8.2424527928857074e+01 + 4 -4.8297128431903239e+01 -8.1171172458509915e+00 6.4789088257516795e+01 5 -6.2249945655197145e+01 2.2813353706915890e+01 -5.3758960971523750e+00 - 6 9.1082266941280153e+01 1.3760435384789912e+02 -3.9497610389853719e+01 + 6 9.1082266941280153e+01 1.3760435384789918e+02 -3.9497610389853719e+01 7 -4.6896901941201634e+01 -5.0626903993409201e+01 8.3785409954385486e+00 8 2.2272760597411565e+02 1.5895499661752211e+02 5.7194518486415930e+01 9 -1.3424389468966993e+00 5.5961120653727576e+00 -1.0522843110369067e+00 diff --git a/unittest/force-styles/tests/fix-timestep-adapt_coul.yaml b/unittest/force-styles/tests/fix-timestep-adapt_coul.yaml index f0ec2f1292..9462c78d14 100644 --- a/unittest/force-styles/tests/fix-timestep-adapt_coul.yaml +++ b/unittest/force-styles/tests/fix-timestep-adapt_coul.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Thu Mar 25 14:07:45 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix adapt @@ -46,33 +47,33 @@ run_pos: ! |2 28 -2.7409194780982360e+00 -4.0232390590132754e+00 1.5874446954442702e+00 29 -1.3169303967683006e+00 -3.6019395338314788e+00 2.2736834157327834e+00 run_vel: ! |2 - 1 3.2647934948866072e-03 -1.0659515509476220e-03 -3.5596416446573862e-03 - 2 6.5461183155830240e-04 5.3408204488965814e-04 3.7281153774905299e-03 - 3 5.5824606761867453e-04 6.8767077705354802e-03 2.6081254050903369e-03 - 4 -3.0104306057251481e-03 -6.3737880755571717e-03 -5.7689309472175711e-04 - 5 -1.0695603162793169e-02 -9.3124438941875488e-03 -3.5561825582117166e-03 - 6 9.7217275192988716e-04 2.4037242875343898e-03 -1.4804194461220557e-03 + 1 3.2647934948866076e-03 -1.0659515509476238e-03 -3.5596416446573905e-03 + 2 6.5461183155830381e-04 5.3408204488966540e-04 3.7281153774905355e-03 + 3 5.5824606761867193e-04 6.8767077705354836e-03 2.6081254050903430e-03 + 4 -3.0104306057251447e-03 -6.3737880755571769e-03 -5.7689309472176372e-04 + 5 -1.0695603162793162e-02 -9.3124438941875540e-03 -3.5561825582117188e-03 + 6 9.7217275192988553e-04 2.4037242875343890e-03 -1.4804194461220559e-03 7 -9.8813125701116859e-04 7.1676860005907047e-05 -4.9726864557309155e-04 - 8 5.7695861497255153e-04 -2.8105851335220203e-03 5.2330664783477206e-03 + 8 5.7695861497255034e-04 -2.8105851335220216e-03 5.2330664783477206e-03 9 -1.4995649604676725e-03 3.1649947790849786e-06 2.0412648677152027e-03 - 10 1.5839012837707146e-03 3.0321007338515189e-03 -4.0872484640111792e-03 + 10 1.5839012837707183e-03 3.0321007338515206e-03 -4.0872484640111810e-03 11 -4.7758918532801661e-03 -2.6593274143911529e-03 -1.1550198582046794e-03 - 12 9.0128567357444442e-04 -1.2761751259519178e-03 -2.0871137241467094e-03 - 13 2.1567295863873783e-03 5.8607859346030983e-03 -7.1626599947017036e-04 - 14 3.5355218381749455e-03 -5.7850299516532602e-03 -3.4518030258956843e-03 - 15 -1.7110094580322296e-03 -6.3503642729395085e-03 5.8528583997245172e-03 - 16 -1.3548756014535996e-03 1.4721717701533786e-03 3.4684968840172224e-03 - 17 1.2456371869895035e-03 7.2712506650925211e-05 -1.0263875344785681e-03 - 18 -7.6671852987712384e-04 -6.2725590016584319e-04 -1.7887461816215443e-03 - 19 1.5144560879023705e-03 -2.7339688331763923e-03 8.2529894052008699e-03 - 20 3.1192665056846264e-03 3.0118796973856330e-03 3.9267694079263664e-03 - 21 -8.3441863827979606e-04 5.2127470504020413e-04 -1.3858761585700890e-03 - 22 -3.4781949993989694e-03 -3.5196597997799125e-03 6.4236038889072932e-03 - 23 -1.5073299456798523e-04 -5.2285186251896619e-03 4.8604614163606421e-03 - 24 -6.9684359242923175e-05 1.0646658518855285e-03 -9.5542384314521332e-04 - 25 5.4585615099357566e-03 -5.7013984855115978e-03 3.7920245454784174e-03 - 26 -1.8076492725572590e-03 -4.1945707008573113e-03 4.0407648570027713e-03 - 27 -3.5547747026063570e-05 1.1321728960280906e-03 -6.3187029759558986e-04 - 28 -4.2637774879869998e-05 -1.6726973615869391e-03 2.4434056859341056e-03 - 29 -3.5302833519675510e-03 -2.4353648747156768e-03 2.8116576375086392e-03 + 12 9.0128567357444941e-04 -1.2761751259519132e-03 -2.0871137241467146e-03 + 13 2.1567295863873757e-03 5.8607859346030888e-03 -7.1626599947016516e-04 + 14 3.5355218381749398e-03 -5.7850299516532654e-03 -3.4518030258956825e-03 + 15 -1.7110094580322357e-03 -6.3503642729395094e-03 5.8528583997245216e-03 + 16 -1.3548756014536032e-03 1.4721717701533812e-03 3.4684968840172237e-03 + 17 1.2456371869895037e-03 7.2712506650923897e-05 -1.0263875344785674e-03 + 18 -7.6671852987712384e-04 -6.2725590016584210e-04 -1.7887461816215476e-03 + 19 1.5144560879023672e-03 -2.7339688331763957e-03 8.2529894052008734e-03 + 20 3.1192665056846299e-03 3.0118796973856356e-03 3.9267694079263725e-03 + 21 -8.3441863827979530e-04 5.2127470504020510e-04 -1.3858761585700918e-03 + 22 -3.4781949993989733e-03 -3.5196597997799173e-03 6.4236038889072984e-03 + 23 -1.5073299456798317e-04 -5.2285186251896619e-03 4.8604614163606516e-03 + 24 -6.9684359242923826e-05 1.0646658518855307e-03 -9.5542384314521462e-04 + 25 5.4585615099357531e-03 -5.7013984855116048e-03 3.7920245454784174e-03 + 26 -1.8076492725572549e-03 -4.1945707008573139e-03 4.0407648570027765e-03 + 27 -3.5547747026063855e-05 1.1321728960280930e-03 -6.3187029759559127e-04 + 28 -4.2637774879872790e-05 -1.6726973615869458e-03 2.4434056859341064e-03 + 29 -3.5302833519675466e-03 -2.4353648747156820e-03 2.8116576375086435e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-adapt_hybrid.yaml b/unittest/force-styles/tests/fix-timestep-adapt_hybrid.yaml index d1d8c51ec5..1d5e2321ac 100644 --- a/unittest/force-styles/tests/fix-timestep-adapt_hybrid.yaml +++ b/unittest/force-styles/tests/fix-timestep-adapt_hybrid.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Thu Mar 25 14:01:17 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix adapt @@ -45,33 +46,33 @@ run_pos: ! |2 28 -3.0374110711029547e+00 -3.8950976773182124e+00 1.3869509742028494e+00 29 -1.0900141540951092e+00 -3.3361017662313661e+00 2.3288506481859019e+00 run_vel: ! |2 - 1 -2.6363966609802322e-02 -2.1121682067821074e-02 3.6083903537541533e-02 - 2 1.1439082425218627e-01 9.6059686259844332e-02 -1.2808582493334400e-01 - 3 4.1111553959541365e-02 4.8218907676123458e-03 -2.0053345127339979e-02 - 4 -1.1200342113854607e-01 2.3479218026487367e-02 -7.8322526982440521e-02 - 5 -3.8701176979056742e-02 -5.4238808461352553e-02 1.3872068929223944e-01 - 6 -1.2123879257604515e-02 1.8312769875475924e-02 1.5946869603522588e-02 + 1 -2.6363966609802322e-02 -2.1121682067821074e-02 3.6083903537541526e-02 + 2 1.1439082425218627e-01 9.6059686259844387e-02 -1.2808582493334400e-01 + 3 4.1111553959541365e-02 4.8218907676123527e-03 -2.0053345127339976e-02 + 4 -1.1200342113854607e-01 2.3479218026487357e-02 -7.8322526982440521e-02 + 5 -3.8701176979056735e-02 -5.4238808461352567e-02 1.3872068929223944e-01 + 6 -1.2123879257604515e-02 1.8312769875475921e-02 1.5946869603522588e-02 7 -2.8033909635229349e-04 -4.1270986674540478e-03 -2.1849258860351647e-02 - 8 -1.0170253112050078e-02 -1.7528863700725254e-02 -4.2491773012772370e-02 + 8 -1.0170253112050082e-02 -1.7528863700725254e-02 -4.2491773012772370e-02 9 4.5241065101710616e-02 5.1469831376004180e-02 2.0995899436627763e-01 - 10 1.8368003566726739e-02 1.4179451083200369e-02 2.9470727636806446e-02 + 10 1.8368003566726739e-02 1.4179451083200371e-02 2.9470727636806446e-02 11 -3.2659358322720752e-02 -7.3493919093785873e-02 -1.1457396195350034e-01 - 12 -2.1332063889491135e-02 -2.8577988202947827e-02 2.3932097053094816e-02 - 13 1.2690181040869375e-01 -4.2622009579717637e-02 -3.2122980905022864e-03 - 14 -4.3986665577866770e-02 4.1189150738941797e-03 -1.2884939606320925e-01 - 15 -5.1087806082402770e-03 1.2103885273247751e-01 5.1598463273012998e-02 - 16 7.2721700595591750e-03 -5.1107380318211630e-03 -1.6206172124102816e-02 - 17 -4.5383051620802401e-03 3.8550131312268723e-03 1.5203146179855118e-02 + 12 -2.1332063889491139e-02 -2.8577988202947824e-02 2.3932097053094813e-02 + 13 1.2690181040869375e-01 -4.2622009579717637e-02 -3.2122980905022816e-03 + 14 -4.3986665577866770e-02 4.1189150738941763e-03 -1.2884939606320925e-01 + 15 -5.1087806082402831e-03 1.2103885273247751e-01 5.1598463273013012e-02 + 16 7.2721700595591698e-03 -5.1107380318211586e-03 -1.6206172124102816e-02 + 17 -4.5383051620802393e-03 3.8550131312268714e-03 1.5203146179855118e-02 18 -3.4035600174367278e-03 -1.6724199163900926e-02 5.8534078947667954e-02 - 19 -1.2309357029421318e-01 -8.2342186011711699e-02 -1.4270564232030267e-01 + 19 -1.2309357029421318e-01 -8.2342186011711713e-02 -1.4270564232030267e-01 20 1.3831939524791759e-01 1.4683346823701657e-01 -8.6190510762895065e-02 21 -1.8190109221215101e-02 -2.0433705925500686e-02 5.9790597332019774e-02 22 -1.2248854674722252e-01 -3.2562959165287515e-02 -1.7942350258565937e-01 - 23 1.8820938314857302e-01 1.0738920901878871e-01 -5.3571267428950652e-02 + 23 1.8820938314857302e-01 1.0738920901878871e-01 -5.3571267428950645e-02 24 1.3241508666550663e-02 -5.5202622564252735e-02 3.1590984003367552e-02 - 25 -1.6538995535147813e-01 2.1577200806135906e-02 -1.3992038866639564e-01 - 26 1.1598773628387443e-01 1.9315924859017630e-01 1.7906411933036825e-02 + 25 -1.6538995535147813e-01 2.1577200806135888e-02 -1.3992038866639564e-01 + 26 1.1598773628387445e-01 1.9315924859017630e-01 1.7906411933036832e-02 27 9.5161140946472839e-03 -6.0207807869183290e-02 2.1271816291477584e-02 - 28 -1.8165131190419664e-01 7.5944941014218031e-02 -1.2012012232111549e-01 + 28 -1.8165131190419664e-01 7.5944941014218018e-02 -1.2012012232111549e-01 29 1.3987378313944554e-01 1.6482908858701009e-01 3.7930623655713772e-02 ... diff --git a/unittest/force-styles/tests/fix-timestep-adapt_pair.yaml b/unittest/force-styles/tests/fix-timestep-adapt_pair.yaml index 58b25f6012..620b06268c 100644 --- a/unittest/force-styles/tests/fix-timestep-adapt_pair.yaml +++ b/unittest/force-styles/tests/fix-timestep-adapt_pair.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Thu Mar 25 14:01:17 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix adapt @@ -45,33 +46,33 @@ run_pos: ! |2 28 -3.0374110711029547e+00 -3.8950976773182124e+00 1.3869509742028494e+00 29 -1.0900141540951092e+00 -3.3361017662313661e+00 2.3288506481859019e+00 run_vel: ! |2 - 1 -2.6363966609802322e-02 -2.1121682067821074e-02 3.6083903537541533e-02 - 2 1.1439082425218627e-01 9.6059686259844332e-02 -1.2808582493334400e-01 - 3 4.1111553959541365e-02 4.8218907676123458e-03 -2.0053345127339979e-02 - 4 -1.1200342113854607e-01 2.3479218026487367e-02 -7.8322526982440521e-02 - 5 -3.8701176979056742e-02 -5.4238808461352553e-02 1.3872068929223944e-01 - 6 -1.2123879257604515e-02 1.8312769875475924e-02 1.5946869603522588e-02 + 1 -2.6363966609802322e-02 -2.1121682067821074e-02 3.6083903537541526e-02 + 2 1.1439082425218627e-01 9.6059686259844387e-02 -1.2808582493334400e-01 + 3 4.1111553959541365e-02 4.8218907676123527e-03 -2.0053345127339976e-02 + 4 -1.1200342113854607e-01 2.3479218026487357e-02 -7.8322526982440521e-02 + 5 -3.8701176979056735e-02 -5.4238808461352567e-02 1.3872068929223944e-01 + 6 -1.2123879257604515e-02 1.8312769875475921e-02 1.5946869603522588e-02 7 -2.8033909635229349e-04 -4.1270986674540478e-03 -2.1849258860351647e-02 - 8 -1.0170253112050078e-02 -1.7528863700725254e-02 -4.2491773012772370e-02 + 8 -1.0170253112050082e-02 -1.7528863700725254e-02 -4.2491773012772370e-02 9 4.5241065101710616e-02 5.1469831376004180e-02 2.0995899436627763e-01 - 10 1.8368003566726739e-02 1.4179451083200369e-02 2.9470727636806446e-02 + 10 1.8368003566726739e-02 1.4179451083200371e-02 2.9470727636806446e-02 11 -3.2659358322720752e-02 -7.3493919093785873e-02 -1.1457396195350034e-01 - 12 -2.1332063889491135e-02 -2.8577988202947827e-02 2.3932097053094816e-02 - 13 1.2690181040869375e-01 -4.2622009579717637e-02 -3.2122980905022864e-03 - 14 -4.3986665577866770e-02 4.1189150738941797e-03 -1.2884939606320925e-01 - 15 -5.1087806082402770e-03 1.2103885273247751e-01 5.1598463273012998e-02 - 16 7.2721700595591750e-03 -5.1107380318211630e-03 -1.6206172124102816e-02 - 17 -4.5383051620802401e-03 3.8550131312268723e-03 1.5203146179855118e-02 + 12 -2.1332063889491139e-02 -2.8577988202947824e-02 2.3932097053094813e-02 + 13 1.2690181040869375e-01 -4.2622009579717637e-02 -3.2122980905022816e-03 + 14 -4.3986665577866770e-02 4.1189150738941763e-03 -1.2884939606320925e-01 + 15 -5.1087806082402831e-03 1.2103885273247751e-01 5.1598463273013012e-02 + 16 7.2721700595591698e-03 -5.1107380318211586e-03 -1.6206172124102816e-02 + 17 -4.5383051620802393e-03 3.8550131312268714e-03 1.5203146179855118e-02 18 -3.4035600174367278e-03 -1.6724199163900926e-02 5.8534078947667954e-02 - 19 -1.2309357029421318e-01 -8.2342186011711699e-02 -1.4270564232030267e-01 + 19 -1.2309357029421318e-01 -8.2342186011711713e-02 -1.4270564232030267e-01 20 1.3831939524791759e-01 1.4683346823701657e-01 -8.6190510762895065e-02 21 -1.8190109221215101e-02 -2.0433705925500686e-02 5.9790597332019774e-02 22 -1.2248854674722252e-01 -3.2562959165287515e-02 -1.7942350258565937e-01 - 23 1.8820938314857302e-01 1.0738920901878871e-01 -5.3571267428950652e-02 + 23 1.8820938314857302e-01 1.0738920901878871e-01 -5.3571267428950645e-02 24 1.3241508666550663e-02 -5.5202622564252735e-02 3.1590984003367552e-02 - 25 -1.6538995535147813e-01 2.1577200806135906e-02 -1.3992038866639564e-01 - 26 1.1598773628387443e-01 1.9315924859017630e-01 1.7906411933036825e-02 + 25 -1.6538995535147813e-01 2.1577200806135888e-02 -1.3992038866639564e-01 + 26 1.1598773628387445e-01 1.9315924859017630e-01 1.7906411933036832e-02 27 9.5161140946472839e-03 -6.0207807869183290e-02 2.1271816291477584e-02 - 28 -1.8165131190419664e-01 7.5944941014218031e-02 -1.2012012232111549e-01 + 28 -1.8165131190419664e-01 7.5944941014218018e-02 -1.2012012232111549e-01 29 1.3987378313944554e-01 1.6482908858701009e-01 3.7930623655713772e-02 ... diff --git a/unittest/force-styles/tests/fix-timestep-addforce_const.yaml b/unittest/force-styles/tests/fix-timestep-addforce_const.yaml index 47786b33fe..6e189e4724 100644 --- a/unittest/force-styles/tests/fix-timestep-addforce_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-addforce_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 9e-12 +skip_tests: prerequisites: ! | atom full fix addforce @@ -11,15 +12,15 @@ post_commands: ! | fix test solute addforce 0.0 -0.1 0.1 input_file: in.fourmol natoms: 29 -global_scalar: 1.48901835738129 +global_scalar: 1.4890183573812936 global_vector: ! |- - 3 0.030822392996626036 0.026014193882019754 -0.017708991389909556 + 3 0.030822392996469716 0.02601419388193449 -0.01770899138985982 run_pos: ! |2 1 -2.7045575291334861e-01 2.4912098953869757e+00 -1.6695239815574214e-01 - 2 3.1004076900710170e-01 2.9612149597462425e+00 -8.5464329005027972e-01 + 2 3.1004076900710170e-01 2.9612149597462425e+00 -8.5464329005027961e-01 3 -7.0398549308743119e-01 1.2305439518786667e+00 -6.2776812583732400e-01 4 -1.5818160726875390e+00 1.4837199951274893e+00 -1.2538503621778578e+00 - 5 -9.0719748669903200e-01 9.2650033697311973e-01 3.9956266031649879e-01 + 5 -9.0719748669903200e-01 9.2650033697311962e-01 3.9956266031649879e-01 6 2.4831714249110262e-01 2.8312325631591767e-01 -1.2314165454625041e+00 7 3.4143527198959711e-01 -2.2651747674360529e-02 -2.5292238033565768e+00 8 1.1743553514271237e+00 -4.8863828453992741e-01 -6.3782817835070349e-01 @@ -33,7 +34,7 @@ run_pos: ! |2 16 2.6747030089515893e+00 -2.4124189004358674e+00 -2.3428869709464669e-02 17 2.2153577487661584e+00 -2.0898037210104183e+00 1.1963203850079958e+00 18 2.1369701704121455e+00 3.0158507413641966e+00 -3.5179348337229994e+00 - 19 1.5355837136088100e+00 2.6255292355377717e+00 -4.2353987779882338e+00 + 19 1.5355837136088097e+00 2.6255292355377717e+00 -4.2353987779882338e+00 20 2.7727573005679371e+00 3.6923910449611110e+00 -3.9330842459134390e+00 21 4.9040128073204006e+00 -4.0752348172958719e+00 -3.6210314709889815e+00 22 4.3582355554440877e+00 -4.2126119427287128e+00 -4.4612844196313990e+00 @@ -45,33 +46,33 @@ run_pos: ! |2 28 -2.7473562684513193e+00 -4.0200819932379153e+00 1.5830052163433885e+00 29 -1.3126000191359226e+00 -3.5962518039482334e+00 2.2746342468737333e+00 run_vel: ! |2 - 1 8.1702613218438691e-03 1.6510191351429417e-02 4.7964973237771503e-03 - 2 5.4511084170875343e-03 5.1590481528437813e-03 -1.4175058774793692e-03 - 3 -8.2297881733875439e-03 -1.2933678261753652e-02 -4.0910944229037285e-03 - 4 -3.7701876602396953e-03 -6.5929809185369939e-03 -1.0979051123824390e-03 - 5 -1.1021655940056645e-02 -9.9111987493572112e-03 -2.8208515585563172e-03 - 6 -3.9676769272842236e-02 4.6810118626188314e-02 3.7155184099431124e-02 + 1 8.1702613218438691e-03 1.6510191351429417e-02 4.7964973237771451e-03 + 2 5.4511084170875343e-03 5.1590481528437900e-03 -1.4175058774793638e-03 + 3 -8.2297881733875457e-03 -1.2933678261753647e-02 -4.0910944229037233e-03 + 4 -3.7701876602396918e-03 -6.5929809185370008e-03 -1.0979051123824488e-03 + 5 -1.1021655940056644e-02 -9.9111987493572268e-03 -2.8208515585563180e-03 + 6 -3.9676769272842242e-02 4.6810118626188314e-02 3.7155184099431124e-02 7 9.1033245554758080e-04 -1.0133704610200299e-02 -5.1562858164992204e-02 - 8 7.9067086761695892e-03 -3.3567238353401636e-03 3.4563427326757518e-02 + 8 7.9067086761695892e-03 -3.3567238353401641e-03 3.4563427326757518e-02 9 1.5640463507800002e-03 3.7153745906232053e-03 1.5067137863525135e-02 10 2.9201431684716742e-02 -2.9256524162078218e-02 -1.5011015513636336e-02 11 -4.7836707031183607e-03 -3.7689744526784260e-03 -2.3257693833597559e-03 - 12 2.2697215661243897e-03 -3.5503408953511771e-04 -3.0568221042131718e-03 - 13 2.7530266001101656e-03 5.7964078805919205e-03 -7.7394765650209171e-04 - 14 3.5245514557562165e-03 -5.8145427341994562e-03 -3.9275617105511392e-03 - 15 -1.8548103902428440e-03 -5.8759259808655083e-03 6.3145508812191310e-03 - 16 1.8681562217261326e-02 -1.3269471066222347e-02 -4.5631826406699355e-02 - 17 -1.2896316924809444e-02 9.7475788915801498e-03 3.7301887298077194e-02 - 18 -8.0065794732626385e-04 -8.6270472984577718e-04 -1.4483040728194251e-03 - 19 1.2452390837669909e-03 -2.5061097114590261e-03 7.2998631002926129e-03 - 20 3.5930060230919166e-03 3.6938860311325015e-03 3.2322732685912069e-03 - 21 -1.4689220371368486e-03 -2.7352129777820513e-04 7.0581624254054305e-04 - 22 -7.0694199254559926e-03 -4.2577148925067674e-03 2.8079117615819173e-04 - 23 6.0446963117369709e-03 -1.4000131614987045e-03 2.5819754847190117e-03 - 24 3.1926367840560363e-04 -9.9445664816168633e-04 1.4999996925784762e-04 - 25 1.3789754450351514e-04 -4.4335894890997355e-03 -8.1808136802931375e-04 - 26 2.0485904034793470e-03 2.7813358633281375e-03 4.3245727149043870e-03 - 27 4.5604120382313504e-04 -1.0305523020532397e-03 2.1188058344304351e-04 - 28 -6.2544520861381259e-03 1.4127711176493136e-03 -1.8429821884921316e-03 - 29 6.4110631547740983e-04 3.1273432720868841e-03 3.7253671104628787e-03 + 12 2.2697215661243945e-03 -3.5503408953511338e-04 -3.0568221042131774e-03 + 13 2.7530266001101621e-03 5.7964078805919127e-03 -7.7394765650208618e-04 + 14 3.5245514557562104e-03 -5.8145427341994614e-03 -3.9275617105511366e-03 + 15 -1.8548103902428477e-03 -5.8759259808655127e-03 6.3145508812191397e-03 + 16 1.8681562217261312e-02 -1.3269471066222347e-02 -4.5631826406699355e-02 + 17 -1.2896316924809444e-02 9.7475788915801480e-03 3.7301887298077194e-02 + 18 -8.0065794732626396e-04 -8.6270472984577697e-04 -1.4483040728194281e-03 + 19 1.2452390837669896e-03 -2.5061097114590300e-03 7.2998631002926199e-03 + 20 3.5930060230919183e-03 3.6938860311325041e-03 3.2322732685912134e-03 + 21 -1.4689220371368469e-03 -2.7352129777820421e-04 7.0581624254054034e-04 + 22 -7.0694199254559935e-03 -4.2577148925067691e-03 2.8079117615819541e-04 + 23 6.0446963117369744e-03 -1.4000131614987045e-03 2.5819754847190186e-03 + 24 3.1926367840560309e-04 -9.9445664816168416e-04 1.4999996925784607e-04 + 25 1.3789754450351340e-04 -4.4335894890997424e-03 -8.1808136802931331e-04 + 26 2.0485904034793514e-03 2.7813358633281340e-03 4.3245727149043940e-03 + 27 4.5604120382313477e-04 -1.0305523020532369e-03 2.1188058344304264e-04 + 28 -6.2544520861381294e-03 1.4127711176493071e-03 -1.8429821884921316e-03 + 29 6.4110631547741482e-04 3.1273432720868794e-03 3.7253671104628822e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-addforce_variable.yaml b/unittest/force-styles/tests/fix-timestep-addforce_variable.yaml index 78f260bd39..95a2c1de24 100644 --- a/unittest/force-styles/tests/fix-timestep-addforce_variable.yaml +++ b/unittest/force-styles/tests/fix-timestep-addforce_variable.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-11 +skip_tests: prerequisites: ! | atom full fix addforce @@ -16,9 +17,9 @@ post_commands: ! | fix test solute addforce v_xforce 0.0 v_zforce input_file: in.fourmol natoms: 29 -global_scalar: -66.6128081721324 +global_scalar: -66.61280817213238 global_vector: ! |- - 3 0.030822805860552194 0.026012717110660333 -0.017710664092739137 + 3 0.03082280586049535 0.026012717110660333 -0.017710664092760453 run_pos: ! |2 1 -2.7047214228789879e-01 2.4912159473897288e+00 -1.6695741351125751e-01 2 3.1010217675350321e-01 2.9612343643897283e+00 -8.5465678502037923e-01 @@ -27,7 +28,7 @@ run_pos: ! |2 5 -9.0738248321725767e-01 9.2652118661051119e-01 3.9954717998547740e-01 6 2.4833938838692704e-01 2.8312848343353764e-01 -1.2314198266861847e+00 7 3.4145305574459789e-01 -2.2646551615904693e-02 -2.5292277033981856e+00 - 8 1.1744251519295958e+00 -4.8863301930795239e-01 -6.3783420180106931e-01 + 8 1.1744251519295958e+00 -4.8863301930795244e-01 -6.3783420180106931e-01 9 1.3803393322923716e+00 -2.5274719088138620e-01 2.8354262280984910e-01 10 2.0512157806659483e+00 -1.4604034995894550e+00 -9.8323457702970984e-01 11 1.7881766053556223e+00 -1.9921867592459330e+00 -1.8890557966324570e+00 @@ -50,33 +51,33 @@ run_pos: ! |2 28 -2.7473562684515755e+00 -4.0200819932380565e+00 1.5830052163434851e+00 29 -1.3126000191366660e+00 -3.5962518039487934e+00 2.2746342468743648e+00 run_vel: ! |2 - 1 8.1542005804048114e-03 1.6516352657195144e-02 4.7916994861873716e-03 - 2 5.5108616996518527e-03 5.1769592855304752e-03 -1.4262044196006701e-03 - 3 -8.2819560524694975e-03 -1.2925874484803790e-02 -4.0962172584282129e-03 - 4 -4.0886380039043026e-03 -6.5733036630979845e-03 -1.1077208107759873e-03 - 5 -1.1204698339013554e-02 -9.8903762469767197e-03 -2.8335724171420786e-03 + 1 8.1542005804048131e-03 1.6516352657195140e-02 4.7916994861873672e-03 + 2 5.5108616996518527e-03 5.1769592855304813e-03 -1.4262044196006638e-03 + 3 -8.2819560524695010e-03 -1.2925874484803783e-02 -4.0962172584282086e-03 + 4 -4.0886380039042974e-03 -6.5733036630979897e-03 -1.1077208107759967e-03 + 5 -1.1204698339013552e-02 -9.8903762469767318e-03 -2.8335724171420795e-03 6 -3.9653324695987140e-02 4.6814090441761887e-02 3.7154219827738325e-02 7 9.2811228899244145e-04 -1.0128521447666933e-02 -5.1566014310509153e-02 - 8 7.9768414397017682e-03 -3.3521215541620886e-03 3.4557180732453542e-02 + 8 7.9768414397017665e-03 -3.3521215541620908e-03 3.4557180732453542e-02 9 1.8506084396989573e-03 3.7365307043657862e-03 1.5049937691527137e-02 - 10 2.9339781785645530e-02 -2.9244335397845489e-02 -1.5013285041501756e-02 + 10 2.9339781785645540e-02 -2.9244335397845485e-02 -1.5013285041501763e-02 11 -4.4111732898708574e-03 -3.7490441708152595e-03 -2.3402341830182269e-03 - 12 2.4919774686993339e-03 -3.4986602016114646e-04 -3.0596868750942985e-03 - 13 3.5708757570142549e-03 5.8192695094192127e-03 -7.8509643584213180e-04 - 14 4.0624997491302594e-03 -5.7912127152414828e-03 -3.9424433676611033e-03 - 15 -1.2427000878928462e-03 -5.8549223934944352e-03 6.3005021988472203e-03 - 16 1.8865114672276220e-02 -1.3261139374878017e-02 -4.5632510336419303e-02 - 17 -1.2778996290317002e-02 9.7520044246185329e-03 3.7296098445722708e-02 - 18 -8.0065793587999099e-04 -8.6270472146121331e-04 -1.4483040775306573e-03 - 19 1.2452390841875935e-03 -2.5061097103150493e-03 7.2998630994791933e-03 - 20 3.5930060235755922e-03 3.6938860311851785e-03 3.2322732685174278e-03 - 21 -1.4689220453590402e-03 -2.7352127317486851e-04 7.0581626525379880e-04 - 22 -7.0694199252635138e-03 -4.2577148916858000e-03 2.8079117743316296e-04 - 23 6.0446963107027478e-03 -1.4000131600045436e-03 2.5819754862959378e-03 - 24 3.1926368204184148e-04 -9.9445664667548433e-04 1.4999997209784617e-04 - 25 1.3789754604908935e-04 -4.4335894874218615e-03 -8.1808136451897351e-04 - 26 2.0485904036966728e-03 2.7813358634892773e-03 4.3245727150655168e-03 - 27 4.5604118959923195e-04 -1.0305523122762120e-03 2.1188059030274769e-04 - 28 -6.2544520866959210e-03 1.4127711173635808e-03 -1.8429821883176730e-03 - 29 6.4110631389697711e-04 3.1273432708352981e-03 3.7253671117315453e-03 + 12 2.4919774686993374e-03 -3.4986602016114261e-04 -3.0596868750943046e-03 + 13 3.5708757570142541e-03 5.8192695094192023e-03 -7.8509643584212660e-04 + 14 4.0624997491302533e-03 -5.7912127152414923e-03 -3.9424433676610998e-03 + 15 -1.2427000878928501e-03 -5.8549223934944387e-03 6.3005021988472264e-03 + 16 1.8865114672276220e-02 -1.3261139374878016e-02 -4.5632510336419303e-02 + 17 -1.2778996290317002e-02 9.7520044246185295e-03 3.7296098445722715e-02 + 18 -8.0065793587999099e-04 -8.6270472146121298e-04 -1.4483040775306591e-03 + 19 1.2452390841875905e-03 -2.5061097103150523e-03 7.2998630994791950e-03 + 20 3.5930060235755939e-03 3.6938860311851807e-03 3.2322732685174326e-03 + 21 -1.4689220453590398e-03 -2.7352127317486764e-04 7.0581626525379620e-04 + 22 -7.0694199252635190e-03 -4.2577148916858052e-03 2.8079117743316730e-04 + 23 6.0446963107027504e-03 -1.4000131600045436e-03 2.5819754862959447e-03 + 24 3.1926368204184083e-04 -9.9445664667548216e-04 1.4999997209784476e-04 + 25 1.3789754604908724e-04 -4.4335894874218667e-03 -8.1808136451897307e-04 + 26 2.0485904036966767e-03 2.7813358634892747e-03 4.3245727150655203e-03 + 27 4.5604118959923152e-04 -1.0305523122762093e-03 2.1188059030274683e-04 + 28 -6.2544520866959228e-03 1.4127711173635743e-03 -1.8429821883176730e-03 + 29 6.4110631389698155e-04 3.1273432708352946e-03 3.7253671117315483e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-addtorque_const.yaml b/unittest/force-styles/tests/fix-timestep-addtorque_const.yaml index a1e0c30d62..4635ae5485 100644 --- a/unittest/force-styles/tests/fix-timestep-addtorque_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-addtorque_const.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 14:22:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2.5e-11 skip_tests: prerequisites: ! | @@ -12,9 +12,9 @@ post_commands: ! | fix test solute addtorque 0.0 -0.1 0.1 input_file: in.fourmol natoms: 29 -global_scalar: 0.03956049051638778 +global_scalar: 0.03956049051638787 global_vector: ! |- - 3 0.02948441541406055 0.004458628473514636 -0.07131104480401973 + 3 0.029484415414145815 0.004458628473543058 -0.07131104480436079 run_pos: ! |2 1 -2.7045608765305873e-01 2.4912155300266194e+00 -1.6695862419419480e-01 2 3.1003988022271212e-01 2.9612351370415912e+00 -8.5466347382340779e-01 @@ -27,7 +27,7 @@ run_pos: ! |2 9 1.3800521862844288e+00 -2.5274734046648356e-01 2.8353984607063565e-01 10 2.0510767216424219e+00 -1.4604061647703297e+00 -9.8323736879838897e-01 11 1.7878036788887381e+00 -1.9921859718974058e+00 -1.8890602543966724e+00 - 12 3.0063008891314627e+00 -4.9013314727151508e-01 -1.6231892870803049e+00 + 12 3.0063008891314627e+00 -4.9013314727151502e-01 -1.6231892870803049e+00 13 4.0515405206097315e+00 -8.9201960028948268e-01 -1.6399997820565750e+00 14 2.6066967494963826e+00 -4.1789208605424438e-01 -2.6633998865546138e+00 15 2.9695286693280316e+00 5.5422635676528331e-01 -1.2342015684967804e+00 @@ -46,33 +46,33 @@ run_pos: ! |2 28 -2.7473562684513411e+00 -4.0200819932379330e+00 1.5830052163433954e+00 29 -1.3126000191359861e+00 -3.5962518039482929e+00 2.2746342468737843e+00 run_vel: ! |2 - 1 8.1700851351787680e-03 1.6515949908476435e-02 4.7901234026000820e-03 - 2 5.4497368734153350e-03 5.1788473112242134e-03 -1.4371398142926089e-03 - 3 -8.2300340000758081e-03 -1.2926916688743221e-02 -4.0987886606318937e-03 - 4 -3.7699831386057837e-03 -6.5726828161593578e-03 -1.1190176423498614e-03 - 5 -1.1022344766928559e-02 -9.8911887500188686e-03 -2.8415919891788752e-03 + 1 8.1700851351787680e-03 1.6515949908476428e-02 4.7901234026000786e-03 + 2 5.4497368734153367e-03 5.1788473112242212e-03 -1.4371398142926037e-03 + 3 -8.2300340000758115e-03 -1.2926916688743214e-02 -4.0987886606318850e-03 + 4 -3.7699831386057803e-03 -6.5726828161593630e-03 -1.1190176423498696e-03 + 5 -1.1022344766928555e-02 -9.8911887500188755e-03 -2.8415919891788760e-03 6 -3.9676608280663724e-02 4.6816984996815900e-02 3.7148317783925591e-02 7 9.1071086597237054e-04 -1.0128400725142215e-02 -5.1568394733748101e-02 - 8 7.9064759226637506e-03 -3.3507269525917005e-03 3.4557045104308584e-02 + 8 7.9064759226637506e-03 -3.3507269525917013e-03 3.4557045104308584e-02 9 1.5641808529388477e-03 3.7364256461355199e-03 1.5047399262833255e-02 - 10 2.9201650498711828e-02 -2.9249371181362224e-02 -1.5017994712903047e-02 + 10 2.9201650498711831e-02 -2.9249371181362220e-02 -1.5017994712903049e-02 11 -4.7831130712487260e-03 -3.7477860269310944e-03 -2.3464216614065801e-03 - 12 2.2698304112799771e-03 -3.4738441424437080e-04 -3.0635558749914937e-03 - 13 2.7533982742218282e-03 5.8176203696077644e-03 -7.9390708609842597e-04 - 14 3.5250323942210967e-03 -5.7935475830105648e-03 -3.9473720437509336e-03 - 15 -1.8548438082234538e-03 -5.8552466365824583e-03 6.2944792336588409e-03 - 16 1.8681607173873734e-02 -1.3262252352501631e-02 -4.5638578270038387e-02 - 17 -1.2896467059015511e-02 9.7527432145300234e-03 3.7296482932975175e-02 - 18 -8.0065794839826582e-04 -8.6270473206014454e-04 -1.4483040698187947e-03 - 19 1.2452390836164592e-03 -2.5061097118798349e-03 7.2998631009701491e-03 - 20 3.5930060229627742e-03 3.6938860309263127e-03 3.2322732687855120e-03 - 21 -1.4689220370382708e-03 -2.7352129765913181e-04 7.0581624212404624e-04 - 22 -7.0694199254613017e-03 -4.2577148924905920e-03 2.8079117613999638e-04 - 23 6.0446963117407456e-03 -1.4000131614812878e-03 2.5819754846997636e-03 - 24 3.1926367907031124e-04 -9.9445664749458563e-04 1.4999996967894329e-04 - 25 1.3789754520737371e-04 -4.4335894884316232e-03 -8.1808136711778898e-04 - 26 2.0485904035277458e-03 2.7813358633862833e-03 4.3245727149281441e-03 - 27 4.5604120294022731e-04 -1.0305523026852440e-03 2.1188058381360966e-04 - 28 -6.2544520861857683e-03 1.4127711176150314e-03 -1.8429821884794460e-03 - 29 6.4110631534307870e-04 3.1273432719597966e-03 3.7253671105664863e-03 + 12 2.2698304112799828e-03 -3.4738441424436690e-04 -3.0635558749914989e-03 + 13 2.7533982742218247e-03 5.8176203696077601e-03 -7.9390708609842033e-04 + 14 3.5250323942210902e-03 -5.7935475830105708e-03 -3.9473720437509336e-03 + 15 -1.8548438082234590e-03 -5.8552466365824627e-03 6.2944792336588487e-03 + 16 1.8681607173873724e-02 -1.3262252352501627e-02 -4.5638578270038387e-02 + 17 -1.2896467059015509e-02 9.7527432145300217e-03 3.7296482932975175e-02 + 18 -8.0065794839826549e-04 -8.6270473206014389e-04 -1.4483040698187975e-03 + 19 1.2452390836164558e-03 -2.5061097118798388e-03 7.2998631009701534e-03 + 20 3.5930060229627768e-03 3.6938860309263127e-03 3.2322732687855189e-03 + 21 -1.4689220370382697e-03 -2.7352129765913094e-04 7.0581624212404353e-04 + 22 -7.0694199254613052e-03 -4.2577148924905946e-03 2.8079117613999963e-04 + 23 6.0446963117407500e-03 -1.4000131614812878e-03 2.5819754846997697e-03 + 24 3.1926367907031059e-04 -9.9445664749458346e-04 1.4999996967894185e-04 + 25 1.3789754520737122e-04 -4.4335894884316275e-03 -8.1808136711778823e-04 + 26 2.0485904035277497e-03 2.7813358633862794e-03 4.3245727149281484e-03 + 27 4.5604120294022703e-04 -1.0305523026852416e-03 2.1188058381360880e-04 + 28 -6.2544520861857718e-03 1.4127711176150247e-03 -1.8429821884794458e-03 + 29 6.4110631534308282e-04 3.1273432719597922e-03 3.7253671105664898e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-addtorque_variable.yaml b/unittest/force-styles/tests/fix-timestep-addtorque_variable.yaml index d3e3f92083..568d0439f2 100644 --- a/unittest/force-styles/tests/fix-timestep-addtorque_variable.yaml +++ b/unittest/force-styles/tests/fix-timestep-addtorque_variable.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 14:26:01 2021 -epsilon: 2e-11 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 +epsilon: 5e-11 skip_tests: prerequisites: ! | atom full @@ -16,14 +16,14 @@ post_commands: ! | fix test solute addtorque v_xforce 0.0 v_zforce input_file: in.fourmol natoms: 29 -global_scalar: 0.040192344862746324 +global_scalar: 0.04019234486274616 global_vector: ! |- - 3 0.029484377941315643 0.004458348825806979 -0.07131114647916093 + 3 0.02948437794124459 0.004458348825863823 -0.07131114647904724 run_pos: ! |2 1 -2.7045461263773218e-01 2.4912173168201677e+00 -1.6696274532928165e-01 2 3.1004052413574945e-01 2.9612352165094689e+00 -8.5466948427723322e-01 3 -7.0398514700197223e-01 1.2305514740305539e+00 -6.2777633916539544e-01 - 4 -1.5818162423457216e+00 1.4837399920103735e+00 -1.2538717040018597e+00 + 4 -1.5818162423457216e+00 1.4837399920103733e+00 -1.2538717040018597e+00 5 -9.0719611552425128e-01 9.2652376949202220e-01 3.9954186488341453e-01 6 2.4831672574192637e-01 2.8312927890145700e-01 -1.2314232633009583e+00 7 3.4143338526825445e-01 -2.2650090205246415e-02 -2.5292285243563257e+00 @@ -50,33 +50,33 @@ run_pos: ! |2 28 -2.7473562684513420e+00 -4.0200819932379330e+00 1.5830052163433950e+00 29 -1.3126000191359821e+00 -3.5962518039482925e+00 2.2746342468737826e+00 run_vel: ! |2 - 1 8.1715038471805498e-03 1.6517702761528009e-02 4.7859997746321067e-03 - 2 5.4503179713409474e-03 5.1789072777174887e-03 -1.4431316168817382e-03 - 3 -8.2294952065699659e-03 -1.2926116506680038e-02 -4.0994800698084749e-03 - 4 -3.7702426960160408e-03 -6.5731295285995084e-03 -1.1190865089059298e-03 - 5 -1.1020475329056929e-02 -9.8880027104014442e-03 -2.8413084775740691e-03 + 1 8.1715038471805498e-03 1.6517702761528009e-02 4.7859997746320998e-03 + 2 5.4503179713409474e-03 5.1789072777174991e-03 -1.4431316168817324e-03 + 3 -8.2294952065699693e-03 -1.2926116506680033e-02 -4.0994800698084697e-03 + 4 -3.7702426960160356e-03 -6.5731295285995136e-03 -1.1190865089059393e-03 + 5 -1.1020475329056922e-02 -9.8880027104014546e-03 -2.8413084775740700e-03 6 -3.9677137318111941e-02 4.6816134139098450e-02 3.7148540792980043e-02 7 9.0844368987863977e-04 -1.0132095604865266e-02 -5.1567636305637793e-02 - 8 7.9066183357430729e-03 -3.3503801392424809e-03 3.4557749983800908e-02 + 8 7.9066183357430729e-03 -3.3503801392424830e-03 3.4557749983800908e-02 9 1.5656401036142562e-03 3.7388603039389670e-03 1.5047280366985395e-02 - 10 2.9201153816488620e-02 -2.9249946103697275e-02 -1.5016274817450501e-02 + 10 2.9201153816488624e-02 -2.9249946103697275e-02 -1.5016274817450504e-02 11 -4.7849597510623036e-03 -3.7503854403682655e-03 -2.3431228504617210e-03 - 12 2.2686557921418379e-03 -3.4963168920308706e-04 -3.0653391271188305e-03 - 13 2.7521148018537969e-03 5.8151152207486893e-03 -7.9617831244930821e-04 - 14 3.5224627166930943e-03 -5.7980843766694372e-03 -3.9487861880922372e-03 - 15 -1.8552798945069447e-03 -5.8566124351604847e-03 6.2903445086971016e-03 - 16 1.8682244050164797e-02 -1.3260714393376980e-02 -4.5635521819500181e-02 - 17 -1.2894174676721371e-02 9.7570482748997739e-03 3.7299431774810592e-02 - 18 -8.0065794985635782e-04 -8.6270473333768262e-04 -1.4483040689709219e-03 - 19 1.2452390835506406e-03 -2.5061097118679156e-03 7.2998631010534921e-03 - 20 3.5930060229084934e-03 3.6938860309016657e-03 3.2322732688339346e-03 - 21 -1.4689220369302289e-03 -2.7352129762041533e-04 7.0581624194444154e-04 - 22 -7.0694199254599495e-03 -4.2577148924868363e-03 2.8079117613292169e-04 - 23 6.0446963117425125e-03 -1.4000131614743960e-03 2.5819754846962157e-03 - 24 3.1926367941798267e-04 -9.9445664753694237e-04 1.4999996979033864e-04 - 25 1.3789754566438797e-04 -4.4335894881603827e-03 -8.1808136664127291e-04 - 26 2.0485904035507274e-03 2.7813358634013181e-03 4.3245727149403366e-03 - 27 4.5604120268971426e-04 -1.0305523027678266e-03 2.1188058390995772e-04 - 28 -6.2544520861874025e-03 1.4127711176147907e-03 -1.8429821884809686e-03 - 29 6.4110631535004535e-04 3.1273432719582093e-03 3.7253671105630646e-03 + 12 2.2686557921418422e-03 -3.4963168920308294e-04 -3.0653391271188361e-03 + 13 2.7521148018537947e-03 5.8151152207486841e-03 -7.9617831244930301e-04 + 14 3.5224627166930878e-03 -5.7980843766694424e-03 -3.9487861880922355e-03 + 15 -1.8552798945069490e-03 -5.8566124351604890e-03 6.2903445086971094e-03 + 16 1.8682244050164797e-02 -1.3260714393376975e-02 -4.5635521819500181e-02 + 17 -1.2894174676721371e-02 9.7570482748997704e-03 3.7299431774810592e-02 + 18 -8.0065794985635782e-04 -8.6270473333768197e-04 -1.4483040689709252e-03 + 19 1.2452390835506375e-03 -2.5061097118679178e-03 7.2998631010534974e-03 + 20 3.5930060229084982e-03 3.6938860309016675e-03 3.2322732688339403e-03 + 21 -1.4689220369302289e-03 -2.7352129762041452e-04 7.0581624194443904e-04 + 22 -7.0694199254599539e-03 -4.2577148924868372e-03 2.8079117613292667e-04 + 23 6.0446963117425151e-03 -1.4000131614743960e-03 2.5819754846962226e-03 + 24 3.1926367941798202e-04 -9.9445664753693998e-04 1.4999996979033728e-04 + 25 1.3789754566438634e-04 -4.4335894881603879e-03 -8.1808136664127205e-04 + 26 2.0485904035507313e-03 2.7813358634013151e-03 4.3245727149403392e-03 + 27 4.5604120268971388e-04 -1.0305523027678237e-03 2.1188058390995691e-04 + 28 -6.2544520861874068e-03 1.4127711176147842e-03 -1.8429821884809684e-03 + 29 6.4110631535004947e-04 3.1273432719582041e-03 3.7253671105630681e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-aveforce_const.yaml b/unittest/force-styles/tests/fix-timestep-aveforce_const.yaml index 34c6afbbf5..da0a9ea195 100644 --- a/unittest/force-styles/tests/fix-timestep-aveforce_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-aveforce_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-11 +skip_tests: prerequisites: ! | atom full fix aveforce @@ -12,7 +13,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 global_vector: ! |- - 3 0.030693239277496787 0.026836713504508225 -0.017872771454378267 + 3 0.030693239277468365 0.02683671350456507 -0.017872771454392478 run_pos: ! |2 1 -2.7837937276378577e-01 2.4738323337395633e+00 -1.7244628118937513e-01 2 3.0739712238693778e-01 2.9607606438663985e+00 -8.4971558628080046e-01 @@ -44,33 +45,33 @@ run_pos: ! |2 28 -2.7473562684449138e+00 -4.0200819932443128e+00 1.5830052163349162e+00 29 -1.3126000190352287e+00 -3.5962518039727378e+00 2.2746342468394127e+00 run_vel: ! |2 - 1 7.7878588734526198e-04 5.8382345680427130e-04 -2.1588360870901697e-04 - 2 2.7133298635754447e-03 4.6080941432587817e-03 3.6012143490662431e-03 - 3 -1.2735533433080959e-03 1.6040104178824128e-03 -3.2928787663304100e-04 - 4 -9.2790908405729388e-04 -1.2743370998098266e-03 -4.0998381156616033e-03 - 5 -1.1797079389975749e-03 7.3369545190079568e-04 8.9682557646519266e-05 - 6 -3.0901428918666851e-04 1.2686815717087763e-03 8.0263701588449308e-04 - 7 -1.1028454231743601e-04 -7.7279598321444340e-04 -7.6700101339104750e-04 - 8 3.9071065119356116e-04 -8.2032217860919109e-04 1.5725797910453806e-04 - 9 1.2479299632287711e-03 -2.6813940130008974e-03 1.1324196703928796e-03 - 10 4.5021559737281377e-04 4.8844497171634344e-04 -2.2646836122846916e-04 - 11 -3.6939982362589797e-04 -1.5494557630536987e-03 -2.8969796085021034e-03 - 12 1.0852092126307005e-03 -6.5651598379105566e-04 -1.2902212798795269e-03 - 13 4.0758327867858645e-03 3.4838016716369673e-03 -7.6258549719693985e-04 - 14 -1.3799533732466697e-04 -4.0861534316170862e-03 -3.9126867377128425e-03 - 15 -4.3297938711093853e-03 -3.2008147343211384e-03 3.2244512840176650e-03 - 16 -9.6589991406029584e-05 -5.0702273154864109e-04 1.5014598698974305e-03 - 17 6.5701621273287663e-04 3.6121026772938211e-04 8.4012943587149819e-04 - 18 -8.0066194144632968e-04 -8.6271665406919022e-04 -1.4482973852517659e-03 - 19 1.2452388413347042e-03 -2.5061108560376941e-03 7.2998638677115694e-03 - 20 3.5930058301559932e-03 3.6938856643002412e-03 3.2322734436995241e-03 - 21 -1.4689171694767468e-03 -2.7352531122827996e-04 7.0581004752321775e-04 - 22 -7.0694198156340390e-03 -4.2577150557873162e-03 2.8079073381937999e-04 - 23 6.0446966473114254e-03 -1.4000132185293601e-03 2.5819751444891522e-03 - 24 3.1926504097853274e-04 -9.9445515850083571e-04 1.5000252605154639e-04 - 25 1.3789938296094050e-04 -4.4335889216404701e-03 -8.1807768663880035e-04 - 26 2.0485906001141111e-03 2.7813359981121301e-03 4.3245729315533402e-03 - 27 4.5604045866279167e-04 -1.0305531425500631e-03 2.1187980949232823e-04 - 28 -6.2544520799773665e-03 1.4127711082282343e-03 -1.8429822100198981e-03 - 29 6.4110649930657559e-04 3.1273432105699108e-03 3.7253670414334056e-03 + 1 7.7878588734526220e-04 5.8382345680427087e-04 -2.1588360870901702e-04 + 2 2.7133298635754447e-03 4.6080941432587817e-03 3.6012143490662413e-03 + 3 -1.2735533433080959e-03 1.6040104178824115e-03 -3.2928787663304089e-04 + 4 -9.2790908405729398e-04 -1.2743370998098275e-03 -4.0998381156616033e-03 + 5 -1.1797079389975747e-03 7.3369545190079502e-04 8.9682557646519117e-05 + 6 -3.0901428918666873e-04 1.2686815717087750e-03 8.0263701588449308e-04 + 7 -1.1028454231743600e-04 -7.7279598321444340e-04 -7.6700101339104750e-04 + 8 3.9071065119356110e-04 -8.2032217860919152e-04 1.5725797910453801e-04 + 9 1.2479299632287713e-03 -2.6813940130008991e-03 1.1324196703928796e-03 + 10 4.5021559737281355e-04 4.8844497171634312e-04 -2.2646836122846922e-04 + 11 -3.6939982362589775e-04 -1.5494557630536996e-03 -2.8969796085021051e-03 + 12 1.0852092126307005e-03 -6.5651598379105598e-04 -1.2902212798795274e-03 + 13 4.0758327867858627e-03 3.4838016716369656e-03 -7.6258549719693985e-04 + 14 -1.3799533732466700e-04 -4.0861534316170862e-03 -3.9126867377128425e-03 + 15 -4.3297938711093871e-03 -3.2008147343211401e-03 3.2244512840176633e-03 + 16 -9.6589991406029570e-05 -5.0702273154864142e-04 1.5014598698974300e-03 + 17 6.5701621273287674e-04 3.6121026772938173e-04 8.4012943587149819e-04 + 18 -8.0066194144632946e-04 -8.6271665406918968e-04 -1.4482973852517689e-03 + 19 1.2452388413347010e-03 -2.5061108560376988e-03 7.2998638677115729e-03 + 20 3.5930058301559954e-03 3.6938856643002420e-03 3.2322734436995297e-03 + 21 -1.4689171694767459e-03 -2.7352531122827909e-04 7.0581004752321504e-04 + 22 -7.0694198156340459e-03 -4.2577150557873223e-03 2.8079073381938514e-04 + 23 6.0446966473114263e-03 -1.4000132185293601e-03 2.5819751444891592e-03 + 24 3.1926504097853198e-04 -9.9445515850083333e-04 1.5000252605154509e-04 + 25 1.3789938296093833e-04 -4.4335889216404753e-03 -8.1807768663879959e-04 + 26 2.0485906001141158e-03 2.7813359981121266e-03 4.3245729315533419e-03 + 27 4.5604045866279140e-04 -1.0305531425500601e-03 2.1187980949232739e-04 + 28 -6.2544520799773700e-03 1.4127711082282278e-03 -1.8429822100198981e-03 + 29 6.4110649930657960e-04 3.1273432105699073e-03 3.7253670414334103e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-aveforce_variable.yaml b/unittest/force-styles/tests/fix-timestep-aveforce_variable.yaml index 6b52979777..13d36800f6 100644 --- a/unittest/force-styles/tests/fix-timestep-aveforce_variable.yaml +++ b/unittest/force-styles/tests/fix-timestep-aveforce_variable.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2.5e-11 +skip_tests: prerequisites: ! | atom full fix aveforce @@ -17,7 +18,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 global_vector: ! |- - 3 0.030693295891580874 0.026836837377516076 -0.017872935896505737 + 3 0.03069329589166614 0.026836837377629763 -0.017872935896761533 run_pos: ! |2 1 -2.7837937276374769e-01 2.4738383080233710e+00 -1.7245068722373783e-01 2 3.0739712238707101e-01 2.9607815224227170e+00 -8.4973098421627558e-01 @@ -49,33 +50,33 @@ run_pos: ! |2 28 -2.7473562684449337e+00 -4.0200819932443297e+00 1.5830052163349233e+00 29 -1.3126000190352873e+00 -3.5962518039727915e+00 2.2746342468394607e+00 run_vel: ! |2 - 1 7.7878588741877761e-04 5.8979774068710158e-04 -2.1946817916036033e-04 - 2 2.7133298638323611e-03 4.6289726998393786e-03 3.5886872146927650e-03 - 3 -1.2735533432223637e-03 1.6109775390378514e-03 -3.3346814946816518e-04 - 4 -9.2790908380037786e-04 -1.2534585432292294e-03 -4.1123652500350801e-03 - 5 -1.1797079387406584e-03 7.5457400848139206e-04 7.7155423273043028e-05 - 6 -3.0901428910093626e-04 1.2756486928642149e-03 7.9845674304936847e-04 - 7 -1.1028454225307708e-04 -7.6756578695323120e-04 -7.7013913125426926e-04 - 8 3.9071065126707630e-04 -8.1434789472636080e-04 1.5367340865319470e-04 - 9 1.2479299634856876e-03 -2.6605154564203013e-03 1.1198925360194041e-03 - 10 4.5021559745854603e-04 4.9541209287178283e-04 -2.3064863406359372e-04 - 11 -3.6939982336898174e-04 -1.5285772064731016e-03 -2.9095067428755814e-03 - 12 1.0852092127164327e-03 -6.4954886263561627e-04 -1.2944015527146522e-03 - 13 4.0758327870427770e-03 3.5046802282175634e-03 -7.7511263157041598e-04 - 14 -1.3799533706775074e-04 -4.0652748750364892e-03 -3.9252138720863193e-03 - 15 -4.3297938708524728e-03 -3.1799361777405423e-03 3.2119241496441869e-03 - 16 -9.6589991320297327e-05 -5.0005561039320170e-04 1.4972795970623052e-03 - 17 6.5701621279723595e-04 3.6644046399059415e-04 8.3699131800827643e-04 - 18 -8.0066194243028337e-04 -8.6271665609198686e-04 -1.4482973824143013e-03 - 19 1.2452388412111663e-03 -2.5061108564126315e-03 7.2998638683177165e-03 - 20 3.5930058300387754e-03 3.6938856641123463e-03 3.2322734438806778e-03 - 21 -1.4689171692235884e-03 -2.7352531129250528e-04 7.0581004700135796e-04 - 22 -7.0694198156331864e-03 -4.2577150557810617e-03 2.8079073379265798e-04 - 23 6.0446966473247238e-03 -1.4000132185192382e-03 2.5819751444644172e-03 - 24 3.1926504141381389e-04 -9.9445515800801552e-04 1.5000252615930676e-04 - 25 1.3789938340469859e-04 -4.4335889211184667e-03 -8.1807768613931969e-04 - 26 2.0485906001419412e-03 2.7813359981542908e-03 4.3245729315573517e-03 - 27 4.5604045784400024e-04 -1.0305531431206094e-03 2.1187980985975486e-04 - 28 -6.2544520800211943e-03 1.4127711081968837e-03 -1.8429822100071731e-03 - 29 6.4110649918605221e-04 3.1273432104571073e-03 3.7253670415284034e-03 + 1 7.7878588741877718e-04 5.8979774068710147e-04 -2.1946817916036038e-04 + 2 2.7133298638323611e-03 4.6289726998393812e-03 3.5886872146927650e-03 + 3 -1.2735533432223633e-03 1.6109775390378517e-03 -3.3346814946816551e-04 + 4 -9.2790908380037710e-04 -1.2534585432292305e-03 -4.1123652500350783e-03 + 5 -1.1797079387406582e-03 7.5457400848139163e-04 7.7155423273042703e-05 + 6 -3.0901428910093615e-04 1.2756486928642151e-03 7.9845674304936836e-04 + 7 -1.1028454225307697e-04 -7.6756578695323120e-04 -7.7013913125426926e-04 + 8 3.9071065126707651e-04 -8.1434789472636091e-04 1.5367340865319465e-04 + 9 1.2479299634856878e-03 -2.6605154564203009e-03 1.1198925360194039e-03 + 10 4.5021559745854614e-04 4.9541209287178316e-04 -2.3064863406359378e-04 + 11 -3.6939982336898147e-04 -1.5285772064731027e-03 -2.9095067428755814e-03 + 12 1.0852092127164332e-03 -6.4954886263561594e-04 -1.2944015527146522e-03 + 13 4.0758327870427788e-03 3.5046802282175638e-03 -7.7511263157041619e-04 + 14 -1.3799533706775039e-04 -4.0652748750364866e-03 -3.9252138720863175e-03 + 15 -4.3297938708524710e-03 -3.1799361777405419e-03 3.2119241496441869e-03 + 16 -9.6589991320297165e-05 -5.0005561039320138e-04 1.4972795970623052e-03 + 17 6.5701621279723585e-04 3.6644046399059399e-04 8.3699131800827643e-04 + 18 -8.0066194243028337e-04 -8.6271665609198632e-04 -1.4482973824143039e-03 + 19 1.2452388412111631e-03 -2.5061108564126350e-03 7.2998638683177200e-03 + 20 3.5930058300387754e-03 3.6938856641123507e-03 3.2322734438806830e-03 + 21 -1.4689171692235880e-03 -2.7352531129250441e-04 7.0581004700135536e-04 + 22 -7.0694198156331951e-03 -4.2577150557810669e-03 2.8079073379266232e-04 + 23 6.0446966473247255e-03 -1.4000132185192382e-03 2.5819751444644229e-03 + 24 3.1926504141381330e-04 -9.9445515800801335e-04 1.5000252615930530e-04 + 25 1.3789938340469658e-04 -4.4335889211184702e-03 -8.1807768613931838e-04 + 26 2.0485906001419456e-03 2.7813359981542891e-03 4.3245729315573578e-03 + 27 4.5604045784399975e-04 -1.0305531431206070e-03 2.1187980985975404e-04 + 28 -6.2544520800211960e-03 1.4127711081968774e-03 -1.8429822100071731e-03 + 29 6.4110649918605622e-04 3.1273432104571043e-03 3.7253670415284051e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-drag.yaml b/unittest/force-styles/tests/fix-timestep-drag.yaml index b7e61ab3ad..69fa64ca49 100644 --- a/unittest/force-styles/tests/fix-timestep-drag.yaml +++ b/unittest/force-styles/tests/fix-timestep-drag.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full fix drag @@ -44,33 +45,33 @@ run_pos: ! |2 28 -2.7473562684516057e+00 -4.0200819932381568e+00 1.5830052163434070e+00 29 -1.3126000191368539e+00 -3.5962518039489728e+00 2.2746342468742613e+00 run_vel: ! |2 - 1 8.5245692419034496e-03 1.6054359615288082e-02 4.6835706342010699e-03 - 2 6.4469181534162982e-03 3.3572509925720315e-03 -1.5167252018059632e-03 - 3 -7.6446099104923171e-03 -1.3347273672018593e-02 -4.1697832271252889e-03 - 4 -2.0567476876389777e-03 -7.6669151224523120e-03 -1.0198053461907023e-03 - 5 -9.3569552193218820e-03 -1.0882851843050193e-02 -3.5334700439280074e-03 + 1 8.5245692419034496e-03 1.6054359615288078e-02 4.6835706342010664e-03 + 2 6.4469181534162999e-03 3.3572509925720367e-03 -1.5167252018059574e-03 + 3 -7.6446099104923197e-03 -1.3347273672018592e-02 -4.1697832271252828e-03 + 4 -2.0567476876389729e-03 -7.6669151224523190e-03 -1.0198053461907117e-03 + 5 -9.3569552193218750e-03 -1.0882851843050203e-02 -3.5334700439280079e-03 6 -3.9106465978160643e-02 4.6496857496481636e-02 3.7247257153434250e-02 7 1.3059086080740997e-03 -1.0323892210522569e-02 -5.1314637706566767e-02 - 8 8.4142216534211708e-03 -3.5565684772021233e-03 3.4400630540566565e-02 + 8 8.4142216534211708e-03 -3.5565684772021241e-03 3.4400630540566572e-02 9 2.7821506314630175e-03 2.9127766895719028e-03 1.3711312410369396e-02 - 10 2.9245154884128457e-02 -2.9289778535465768e-02 -1.5017110420116284e-02 + 10 2.9245154884128464e-02 -2.9289778535465775e-02 -1.5017110420116284e-02 11 -3.9376008935933897e-03 -2.3830258447108204e-03 -1.1504378141809892e-03 - 12 1.8415493135460349e-03 -7.1221479538782968e-04 -2.6222068799362790e-03 - 13 8.7397591637950823e-04 5.6786568476995458e-03 -4.6959188559560803e-05 - 14 3.2686129061490826e-03 -6.4777672751304824e-03 -2.0572626109492988e-03 - 15 -2.5621680789948958e-03 -7.7318113961355357e-03 6.6113139508743373e-03 - 16 1.8591880620408622e-02 -1.2716970618980200e-02 -4.6060427771778933e-02 - 17 -1.2865567938515562e-02 9.9920280977181166e-03 3.6850337974210626e-02 - 18 -8.0065795856943756e-04 -8.6270476392988284e-04 -1.4483040184797788e-03 - 19 1.2452390810585108e-03 -2.5061097098477390e-03 7.2998631044990988e-03 - 20 3.5930060212105096e-03 3.6938860319506088e-03 3.2322732695887410e-03 - 21 -1.4689220629138253e-03 -2.7352129045937475e-04 7.0581626051508884e-04 - 22 -7.0694199261113391e-03 -4.2577148925603400e-03 2.8079117696165005e-04 - 23 6.0446963112475265e-03 -1.4000131635613822e-03 2.5819754846041587e-03 - 24 3.1926370424225161e-04 -9.9445667906353295e-04 1.4999995101417848e-04 - 25 1.3789756975914627e-04 -4.4335895072924450e-03 -8.1808136260541489e-04 - 26 2.0485904046666191e-03 2.7813358617992980e-03 4.3245727148598393e-03 - 27 4.5604117722843052e-04 -1.0305523146029992e-03 2.1188058296474420e-04 - 28 -6.2544520868644485e-03 1.4127711171995772e-03 -1.8429821885457452e-03 - 29 6.4110631343027393e-04 3.1273432703629624e-03 3.7253671115222839e-03 + 12 1.8415493135460392e-03 -7.1221479538782599e-04 -2.6222068799362824e-03 + 13 8.7397591637950627e-04 5.6786568476995388e-03 -4.6959188559555559e-05 + 14 3.2686129061490756e-03 -6.4777672751304858e-03 -2.0572626109492979e-03 + 15 -2.5621680789949001e-03 -7.7318113961355383e-03 6.6113139508743451e-03 + 16 1.8591880620408618e-02 -1.2716970618980193e-02 -4.6060427771778933e-02 + 17 -1.2865567938515560e-02 9.9920280977181114e-03 3.6850337974210626e-02 + 18 -8.0065795856943756e-04 -8.6270476392988208e-04 -1.4483040184797812e-03 + 19 1.2452390810585078e-03 -2.5061097098477442e-03 7.2998631044991014e-03 + 20 3.5930060212105179e-03 3.6938860319506088e-03 3.2322732695887475e-03 + 21 -1.4689220629138244e-03 -2.7352129045937388e-04 7.0581626051508613e-04 + 22 -7.0694199261113425e-03 -4.2577148925603452e-03 2.8079117696165341e-04 + 23 6.0446963112475291e-03 -1.4000131635613822e-03 2.5819754846041656e-03 + 24 3.1926370424225096e-04 -9.9445667906353057e-04 1.4999995101417707e-04 + 25 1.3789756975914497e-04 -4.4335895072924554e-03 -8.1808136260541446e-04 + 26 2.0485904046666234e-03 2.7813358617992958e-03 4.3245727148598419e-03 + 27 4.5604117722843030e-04 -1.0305523146029965e-03 2.1188058296474322e-04 + 28 -6.2544520868644520e-03 1.4127711171995712e-03 -1.8429821885457452e-03 + 29 6.4110631343027870e-04 3.1273432703629580e-03 3.7253671115222860e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-efield_const.yaml b/unittest/force-styles/tests/fix-timestep-efield_const.yaml index cd0fe2b7d4..cd813997e2 100644 --- a/unittest/force-styles/tests/fix-timestep-efield_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-efield_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full fix efield @@ -11,7 +12,7 @@ post_commands: ! | fix test solute efield 0.0 -0.1 0.1 input_file: in.fourmol natoms: 29 -global_scalar: -0.0309186331146529 +global_scalar: -0.030918633114652927 global_vector: ! |- 3 0 -2.220446049250313e-16 2.220446049250313e-16 run_pos: ! |2 @@ -45,33 +46,33 @@ run_pos: ! |2 28 -2.7473562684513779e+00 -4.0200819932379650e+00 1.5830052163433976e+00 29 -1.3126000191359843e+00 -3.5962518039484861e+00 2.2746342468738585e+00 run_vel: ! |2 - 1 8.1658312222614646e-03 1.6575957150422170e-02 4.7291974403202474e-03 - 2 5.4638876708023813e-03 5.0404029111476428e-03 -1.3039774181753362e-03 - 3 -8.2285460105815302e-03 -1.2921801247052930e-02 -4.0992611431015791e-03 - 4 -3.7708744841912518e-03 -6.6156123307326772e-03 -1.0763844399678049e-03 - 5 -1.1020911952034362e-02 -9.9319392840069506e-03 -2.7996700321696261e-03 - 6 -3.9693502572798259e-02 4.6742328405570743e-02 3.7202597389078947e-02 + 1 8.1658312222614663e-03 1.6575957150422167e-02 4.7291974403202448e-03 + 2 5.4638876708023821e-03 5.0404029111476506e-03 -1.3039774181753307e-03 + 3 -8.2285460105815302e-03 -1.2921801247052923e-02 -4.0992611431015756e-03 + 4 -3.7708744841912487e-03 -6.6156123307326833e-03 -1.0763844399678132e-03 + 5 -1.1020911952034354e-02 -9.9319392840069663e-03 -2.7996700321696274e-03 + 6 -3.9693502572798259e-02 4.6742328405570736e-02 3.7202597389078947e-02 7 9.0976114937484250e-04 -1.0062942346953162e-02 -5.1616508395410758e-02 - 8 7.9254327404120941e-03 -3.2975389442540591e-03 3.4504402492869846e-02 + 8 7.9254327404120941e-03 -3.2975389442540595e-03 3.4504402492869846e-02 9 1.5591017009909064e-03 3.5830453659612422e-03 1.5180501660659096e-02 - 10 2.9199490526855283e-02 -2.9258641689434345e-02 -1.5005297297757592e-02 + 10 2.9199490526855283e-02 -2.9258641689434338e-02 -1.5005297297757594e-02 11 -4.7836605087433386e-03 -3.7914729059920198e-03 -2.3035595838662840e-03 - 12 2.2697954637435815e-03 -3.0717924023358897e-04 -3.1050775042142822e-03 - 13 2.7523035532740622e-03 5.7750272572238007e-03 -7.5235664623991686e-04 - 14 3.5240740939544283e-03 -5.8353371764581739e-03 -3.9081837862824610e-03 - 15 -1.8549049501666013e-03 -5.8961708769767586e-03 6.3361117899020389e-03 - 16 1.8685917131732021e-02 -1.3347834929626306e-02 -4.5570644533488594e-02 + 12 2.2697954637435859e-03 -3.0717924023358485e-04 -3.1050775042142892e-03 + 13 2.7523035532740596e-03 5.7750272572237955e-03 -7.5235664623991166e-04 + 14 3.5240740939544214e-03 -5.8353371764581791e-03 -3.9081837862824593e-03 + 15 -1.8549049501666087e-03 -5.8961708769767604e-03 6.3361117899020467e-03 + 16 1.8685917131732017e-02 -1.3347834929626302e-02 -4.5570644533488594e-02 17 -1.2900152726318757e-02 9.8178161596953993e-03 3.7244993882472807e-02 - 18 -8.0065793345388101e-04 -8.6270471230818417e-04 -1.4483040707563401e-03 - 19 1.2452390842995860e-03 -2.5061097113172727e-03 7.2998631014686019e-03 - 20 3.5930060230102119e-03 3.6938860309017859e-03 3.2322732690522947e-03 - 21 -1.4689220346471620e-03 -2.7352130047668497e-04 7.0581623957410920e-04 - 22 -7.0694199254063691e-03 -4.2577148925930204e-03 2.8079117595076379e-04 - 23 6.0446963119010670e-03 -1.4000131615444645e-03 2.5819754845290213e-03 - 24 3.1926368357823061e-04 -9.9445664356196707e-04 1.4999997179198450e-04 - 25 1.3789755154242284e-04 -4.4335894822910811e-03 -8.1808135929846795e-04 - 26 2.0485904038928852e-03 2.7813358638196090e-03 4.3245727151208606e-03 - 27 4.5604119916965496e-04 -1.0305523051824404e-03 2.1188058452236688e-04 - 28 -6.2544520862769949e-03 1.4127711175481120e-03 -1.8429821884839940e-03 - 29 6.4110631531125509e-04 3.1273432715248186e-03 3.7253671107199673e-03 + 18 -8.0065793345388101e-04 -8.6270471230818341e-04 -1.4483040707563421e-03 + 19 1.2452390842995829e-03 -2.5061097113172779e-03 7.2998631014686054e-03 + 20 3.5930060230102141e-03 3.6938860309017889e-03 3.2322732690523012e-03 + 21 -1.4689220346471620e-03 -2.7352130047668410e-04 7.0581623957410638e-04 + 22 -7.0694199254063778e-03 -4.2577148925930248e-03 2.8079117595076618e-04 + 23 6.0446963119010697e-03 -1.4000131615444645e-03 2.5819754845290274e-03 + 24 3.1926368357822996e-04 -9.9445664356196447e-04 1.4999997179198298e-04 + 25 1.3789755154241975e-04 -4.4335894822910855e-03 -8.1808135929846665e-04 + 26 2.0485904038928891e-03 2.7813358638196055e-03 4.3245727151208667e-03 + 27 4.5604119916965464e-04 -1.0305523051824380e-03 2.1188058452236590e-04 + 28 -6.2544520862769975e-03 1.4127711175481057e-03 -1.8429821884839938e-03 + 29 6.4110631531126019e-04 3.1273432715248138e-03 3.7253671107199712e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-efield_region.yaml b/unittest/force-styles/tests/fix-timestep-efield_region.yaml index 6312ce5d52..425715662f 100644 --- a/unittest/force-styles/tests/fix-timestep-efield_region.yaml +++ b/unittest/force-styles/tests/fix-timestep-efield_region.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full fix efield @@ -12,7 +13,7 @@ post_commands: ! | fix test solute efield 0.1 0.1 0.1 region half input_file: in.fourmol natoms: 29 -global_scalar: -2.82714020161747 +global_scalar: -2.8271402016174743 global_vector: ! |- 3 0.714877019 0.714877019 0.714877019 run_pos: ! |2 @@ -27,7 +28,7 @@ run_pos: ! |2 9 1.3801987212014966e+00 -2.5260185032175775e-01 2.8367288614627556e-01 10 2.0510893382844797e+00 -1.4603963461183076e+00 -9.8322611646863767e-01 11 1.7878463761660366e+00 -1.9921439817804589e+00 -1.8890176081342092e+00 - 12 3.0062586771306821e+00 -4.9017539959445050e-01 -1.6232318847185860e+00 + 12 3.0062586771306821e+00 -4.9017539959445044e-01 -1.6232318847185860e+00 13 4.0515821577162132e+00 -8.9197763947222353e-01 -1.6399580523514123e+00 14 2.6067389840655895e+00 -4.1784951184010455e-01 -2.6633592107831059e+00 15 2.9695708184747542e+00 5.5426725757257678e-01 -1.2341598570495227e+00 @@ -46,33 +47,33 @@ run_pos: ! |2 28 -2.7473562684514778e+00 -4.0200819932382421e+00 1.5830052163435122e+00 29 -1.3126000191360516e+00 -3.5962518039482134e+00 2.2746342468738145e+00 run_vel: ! |2 - 1 8.1708759711752958e-03 1.6517639874638810e-02 4.7902879389058409e-03 - 2 5.5964331165927984e-03 5.3239383069183105e-03 -1.2861059284729429e-03 - 3 -8.2292637161143368e-03 -1.2926128087381875e-02 -4.0984161443673259e-03 - 4 -3.7697526145864229e-03 -6.5725127853647463e-03 -1.1187560499435342e-03 - 5 -1.1022006462580936e-02 -9.8906385073934296e-03 -2.8410749782010361e-03 + 1 8.1708759711752958e-03 1.6517639874638803e-02 4.7902879389058383e-03 + 2 5.5964331165928010e-03 5.3239383069183174e-03 -1.2861059284729379e-03 + 3 -8.2292637161143385e-03 -1.2926128087381868e-02 -4.0984161443673190e-03 + 4 -3.7697526145864203e-03 -6.5725127853647532e-03 -1.1187560499435428e-03 + 5 -1.1022006462580933e-02 -9.8906385073934400e-03 -2.8410749782010374e-03 6 -3.9598958324881833e-02 4.6903198210396124e-02 3.7196915155023061e-02 7 8.4653619788661286e-04 -1.0186461918106198e-02 -5.1609252834488979e-02 - 8 7.8471683791752362e-03 -3.4193297369123168e-03 3.4507457170165151e-02 + 8 7.8471683791752362e-03 -3.4193297369123185e-03 3.4507457170165158e-02 9 1.7075694205393060e-03 3.8777304373514634e-03 1.5162863367694195e-02 - 10 2.9215614627888367e-02 -2.9240701545949585e-02 -1.5006701597915329e-02 + 10 2.9215614627888371e-02 -2.9240701545949585e-02 -1.5006701597915331e-02 11 -4.7405866731533054e-03 -3.7068192956066894e-03 -2.3045121721450906e-03 - 12 2.2290126422970825e-03 -3.8809497069253120e-04 -3.1047965880797814e-03 - 13 2.7935114371385704e-03 5.8586940588092251e-03 -7.5304481929042090e-04 - 14 3.5665654501702746e-03 -5.7512922858593378e-03 -3.9089424767000374e-03 - 15 -1.8139594485811754e-03 -5.8166150528014193e-03 6.3351631624150124e-03 - 16 1.8770941362463107e-02 -1.3183631365002510e-02 -4.5573108750104258e-02 + 12 2.2290126422970882e-03 -3.8809497069252936e-04 -3.1047965880797871e-03 + 13 2.7935114371385656e-03 5.8586940588092199e-03 -7.5304481929041526e-04 + 14 3.5665654501702681e-03 -5.7512922858593447e-03 -3.9089424767000339e-03 + 15 -1.8139594485811785e-03 -5.8166150528014193e-03 6.3351631624150211e-03 + 16 1.8770941362463107e-02 -1.3183631365002509e-02 -4.5573108750104258e-02 17 -1.2963606226862703e-02 9.6937549225388098e-03 3.7247063085491160e-02 - 18 -8.0065796921844994e-04 -8.6270475993526418e-04 -1.4483040616159735e-03 - 19 1.2452390834561430e-03 -2.5061097124141865e-03 7.2998631012994994e-03 - 20 3.5930060224885862e-03 3.6938860305007854e-03 3.2322732691378781e-03 - 21 -1.4689220363177683e-03 -2.7352129611332791e-04 7.0581624058295759e-04 - 22 -7.0694199254319415e-03 -4.2577148923730575e-03 2.8079117602693323e-04 - 23 6.0446963117453010e-03 -1.4000131613672306e-03 2.5819754846776403e-03 - 24 3.1926367807141154e-04 -9.9445664297286625e-04 1.4999997144977685e-04 - 25 1.3789754489252698e-04 -4.4335894881614478e-03 -8.1808136766960940e-04 - 26 2.0485904035389369e-03 2.7813358635286707e-03 4.3245727149205070e-03 - 27 4.5604120798144014e-04 -1.0305522996113447e-03 2.1188058145417001e-04 - 28 -6.2544520867286492e-03 1.4127711163406059e-03 -1.8429821880090427e-03 - 29 6.4110631523949554e-04 3.1273432721623307e-03 3.7253671106301785e-03 + 18 -8.0065796921844994e-04 -8.6270475993526386e-04 -1.4483040616159765e-03 + 19 1.2452390834561400e-03 -2.5061097124141904e-03 7.2998631012995028e-03 + 20 3.5930060224885880e-03 3.6938860305007859e-03 3.2322732691378846e-03 + 21 -1.4689220363177679e-03 -2.7352129611332704e-04 7.0581624058295520e-04 + 22 -7.0694199254319476e-03 -4.2577148923730610e-03 2.8079117602693740e-04 + 23 6.0446963117453019e-03 -1.4000131613672311e-03 2.5819754846776472e-03 + 24 3.1926367807141095e-04 -9.9445664297286387e-04 1.4999997144977533e-04 + 25 1.3789754489252400e-04 -4.4335894881614539e-03 -8.1808136766960723e-04 + 26 2.0485904035389413e-03 2.7813358635286672e-03 4.3245727149205113e-03 + 27 4.5604120798143971e-04 -1.0305522996113419e-03 2.1188058145416930e-04 + 28 -6.2544520867286501e-03 1.4127711163405999e-03 -1.8429821880090427e-03 + 29 6.4110631523949934e-04 3.1273432721623264e-03 3.7253671106301819e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-efield_variable.yaml b/unittest/force-styles/tests/fix-timestep-efield_variable.yaml index 13d43663a2..6fa0a5c3a6 100644 --- a/unittest/force-styles/tests/fix-timestep-efield_variable.yaml +++ b/unittest/force-styles/tests/fix-timestep-efield_variable.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full fix efield @@ -23,11 +24,11 @@ run_pos: ! |2 1 -2.7027400245078581e-01 2.4912153249078419e+00 -1.6697700443575972e-01 2 3.1048749486212474e-01 2.9612319277095587e+00 -8.5462053704633356e-01 3 -7.0396772680066944e-01 1.2305526755591596e+00 -6.2777642045596149e-01 - 4 -1.5824860848056050e+00 1.4837398302849329e+00 -1.2538569667673247e+00 + 4 -1.5824860848056050e+00 1.4837398302849327e+00 -1.2538569667673247e+00 5 -9.0757993752489052e-01 9.2652163008811883e-01 3.9955221840945537e-01 - 6 2.4852099131944910e-01 2.8317067680803382e-01 -1.2314300371517362e+00 + 6 2.4852099131944916e-01 2.8317067680803382e-01 -1.2314300371517362e+00 7 3.4122393850807675e-01 -2.2647043078559723e-02 -2.5292463070655042e+00 - 8 1.1736619374984054e+00 -4.8869795492559864e-01 -6.3782418043583033e-01 + 8 1.1736619374984054e+00 -4.8869795492559864e-01 -6.3782418043583022e-01 9 1.3820994096581318e+00 -2.5274636248018068e-01 2.8354473804497693e-01 10 2.0512740715388391e+00 -1.4603791284511956e+00 -9.8321922256073901e-01 11 1.7885787906888206e+00 -1.9921888630304032e+00 -1.8890504465547326e+00 @@ -50,33 +51,33 @@ run_pos: ! |2 28 -2.7473562684520521e+00 -4.0200819932381933e+00 1.5830052163436978e+00 29 -1.3126000191401406e+00 -3.5962518039484013e+00 2.2746342468762424e+00 run_vel: ! |2 - 1 8.3523967935972103e-03 1.6515254595637210e-02 4.7615576657187740e-03 - 2 5.8941247186566573e-03 5.1722227122822729e-03 -1.3701427920022045e-03 - 3 -8.2167795197999102e-03 -1.2923450588576822e-02 -4.1004252694225637e-03 - 4 -4.4263651845063944e-03 -6.5742418325391780e-03 -1.0955970988773293e-03 - 5 -1.1398448905979301e-02 -9.8894689730743470e-03 -2.8263847809119726e-03 - 6 -3.9500939815668816e-02 4.6887414365051332e-02 3.7133775134254372e-02 - 7 6.9842523048380210e-04 -1.0129392818228253e-02 -5.1594363495221347e-02 - 8 7.2583991981464554e-03 -3.4658371736488790e-03 3.4580276362563410e-02 - 9 3.6026391644265357e-03 3.7375102720979456e-03 1.5034460098373453e-02 - 10 2.9376323673810063e-02 -2.9204189651235786e-02 -1.4984527368425801e-02 - 11 -4.0094188700564738e-03 -3.7533811174124457e-03 -2.3323227192170864e-03 - 12 1.0565849247321641e-03 -3.4812418704812298e-04 -3.0814227273971671e-03 - 13 4.3770864839260638e-03 5.8265173175360068e-03 -7.6851845061109492e-04 - 14 4.6081612697984418e-03 -5.7771463173504787e-03 -3.9509511241893639e-03 - 15 -6.2134887575598235e-04 -5.8525914810640773e-03 6.3025497777745550e-03 - 16 2.0803569505133360e-02 -1.3197664214971509e-02 -4.5435603305981419e-02 + 1 8.3523967935972103e-03 1.6515254595637210e-02 4.7615576657187714e-03 + 2 5.8941247186566573e-03 5.1722227122822807e-03 -1.3701427920021986e-03 + 3 -8.2167795197999119e-03 -1.2923450588576815e-02 -4.1004252694225585e-03 + 4 -4.4263651845063874e-03 -6.5742418325391832e-03 -1.0955970988773401e-03 + 5 -1.1398448905979295e-02 -9.8894689730743574e-03 -2.8263847809119743e-03 + 6 -3.9500939815668802e-02 4.6887414365051332e-02 3.7133775134254386e-02 + 7 6.9842523048380231e-04 -1.0129392818228253e-02 -5.1594363495221361e-02 + 8 7.2583991981464485e-03 -3.4658371736488846e-03 3.4580276362563396e-02 + 9 3.6026391644265426e-03 3.7375102720979521e-03 1.5034460098373481e-02 + 10 2.9376323673810063e-02 -2.9204189651235765e-02 -1.4984527368425798e-02 + 11 -4.0094188700564755e-03 -3.7533811174124440e-03 -2.3323227192170864e-03 + 12 1.0565849247321684e-03 -3.4812418704811908e-04 -3.0814227273971736e-03 + 13 4.3770864839260621e-03 5.8265173175360025e-03 -7.6851845061108928e-04 + 14 4.6081612697984357e-03 -5.7771463173504857e-03 -3.9509511241893622e-03 + 15 -6.2134887575598864e-04 -5.8525914810640808e-03 6.3025497777745602e-03 + 16 2.0803569505133360e-02 -1.3197664214971504e-02 -4.5435603305981419e-02 17 -1.4238304956511698e-02 9.7135426337891535e-03 3.7140948224551232e-02 - 18 -8.0065803006974627e-04 -8.6270481571213320e-04 -1.4483040143169691e-03 - 19 1.2452390814642351e-03 -2.5061097171182813e-03 7.2998631074280744e-03 - 20 3.5930060197966484e-03 3.6938860290210949e-03 3.2322732711840487e-03 - 21 -1.4689220487945122e-03 -2.7352130624666045e-04 7.0581629574099176e-04 - 22 -7.0694199251650509e-03 -4.2577148930188899e-03 2.8079117843705367e-04 - 23 6.0446963110170528e-03 -1.4000131639167685e-03 2.5819754871353857e-03 - 24 3.1926366718644761e-04 -9.9445664582025525e-04 1.4999995653372880e-04 - 25 1.3789753947330636e-04 -4.4335894948247575e-03 -8.1808139114999978e-04 - 26 2.0485904025981235e-03 2.7813358628321228e-03 4.3245727135970856e-03 - 27 4.5604125878886102e-04 -1.0305522515611551e-03 2.1188057217212713e-04 - 28 -6.2544520876729806e-03 1.4127711164508253e-03 -1.8429821875256109e-03 - 29 6.4110630762060597e-04 3.1273432725178038e-03 3.7253671155107219e-03 + 18 -8.0065803006974627e-04 -8.6270481571213244e-04 -1.4483040143169715e-03 + 19 1.2452390814642318e-03 -2.5061097171182860e-03 7.2998631074280762e-03 + 20 3.5930060197966501e-03 3.6938860290210949e-03 3.2322732711840547e-03 + 21 -1.4689220487945117e-03 -2.7352130624665958e-04 7.0581629574098927e-04 + 22 -7.0694199251650578e-03 -4.2577148930188916e-03 2.8079117843705611e-04 + 23 6.0446963110170554e-03 -1.4000131639167685e-03 2.5819754871353917e-03 + 24 3.1926366718644695e-04 -9.9445664582025264e-04 1.4999995653372725e-04 + 25 1.3789753947330381e-04 -4.4335894948247627e-03 -8.1808139114999815e-04 + 26 2.0485904025981279e-03 2.7813358628321202e-03 4.3245727135970882e-03 + 27 4.5604125878886070e-04 -1.0305522515611520e-03 2.1188057217212626e-04 + 28 -6.2544520876729867e-03 1.4127711164508190e-03 -1.8429821875256107e-03 + 29 6.4110630762061020e-04 3.1273432725177990e-03 3.7253671155107236e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-heat.yaml b/unittest/force-styles/tests/fix-timestep-heat.yaml index a93468f7e8..80b679aa1f 100644 --- a/unittest/force-styles/tests/fix-timestep-heat.yaml +++ b/unittest/force-styles/tests/fix-timestep-heat.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix heat @@ -11,7 +12,7 @@ post_commands: ! | fix test solute heat 1 1.0 input_file: in.fourmol natoms: 29 -global_scalar: 1.00047909696244 +global_scalar: 1.0004790969624442 run_pos: ! |2 1 -2.7039206272739091e-01 2.4913335723666430e+00 -1.6693130167273956e-01 2 3.1013122348985955e-01 2.9613751388101677e+00 -8.5458433717516069e-01 @@ -43,33 +44,33 @@ run_pos: ! |2 28 -2.7473562684515067e+00 -4.0200819932382315e+00 1.5830052163435726e+00 29 -1.3126000191364291e+00 -3.5962518039481113e+00 2.2746342468739411e+00 run_vel: ! |2 - 1 8.2204608846539063e-03 1.6609471633394227e-02 4.8128871791763917e-03 - 2 5.5163240898145052e-03 5.2749242611661324e-03 -1.3910506666667750e-03 - 3 -8.2968732116620123e-03 -1.2964295167853673e-02 -4.1206310536427739e-03 - 4 -3.8075264813344049e-03 -6.6260296630510657e-03 -1.1834405018499720e-03 - 5 -1.1103832677307980e-02 -9.9325952920669251e-03 -2.8549252069661464e-03 - 6 -3.9875428900868530e-02 4.7062440053367148e-02 3.7335213186391325e-02 + 1 8.2204608846539063e-03 1.6609471633394223e-02 4.8128871791763882e-03 + 2 5.5163240898145061e-03 5.2749242611661376e-03 -1.3910506666667691e-03 + 3 -8.2968732116620175e-03 -1.2964295167853662e-02 -4.1206310536427669e-03 + 4 -3.8075264813344015e-03 -6.6260296630510744e-03 -1.1834405018499813e-03 + 5 -1.1103832677307969e-02 -9.9325952920669390e-03 -2.8549252069661473e-03 + 6 -3.9875428900868537e-02 4.7062440053367148e-02 3.7335213186391325e-02 7 9.0741330040784577e-04 -1.0188152669802473e-02 -5.1829007032815316e-02 8 7.9419910892669122e-03 -3.3766493400557498e-03 3.4733301026857920e-02 9 1.5898395946189422e-03 3.7172994488528194e-03 1.5152458824495398e-02 10 2.9353482911759612e-02 -2.9391229060219796e-02 -1.5100207371312614e-02 11 -4.8178704017648438e-03 -3.7907264886197748e-03 -2.3997682360441179e-03 - 12 2.2945908731372960e-03 -3.6071943605981907e-04 -3.0991093100832916e-03 - 13 2.8239515248589409e-03 5.9007175306100825e-03 -8.0904600793516176e-04 - 14 3.5388608678313949e-03 -5.8841838864859214e-03 -4.0237635208516974e-03 - 15 -1.9334721535550830e-03 -5.9333328189870010e-03 6.3750701628706554e-03 - 16 1.8769054658204255e-02 -1.3336664426271041e-02 -4.5837568812631971e-02 - 17 -1.2953171556495174e-02 9.8061425326315191e-03 3.7494465334416853e-02 - 18 -8.0065792982680743e-04 -8.6270466210164353e-04 -1.4483041097384591e-03 - 19 1.2452390849353537e-03 -2.5061097043873317e-03 7.2998630959149723e-03 - 20 3.5930060239749706e-03 3.6938860332742119e-03 3.2322732677889567e-03 - 21 -1.4689220680373268e-03 -2.7352126917984138e-04 7.0581627972699640e-04 - 22 -7.0694199262180185e-03 -4.2577148912323459e-03 2.8079117893057252e-04 - 23 6.0446963095191139e-03 -1.4000131608108272e-03 2.5819754868763563e-03 - 24 3.1926367011384128e-04 -9.9445665566967991e-04 1.4999995210148749e-04 - 25 1.3789753264027645e-04 -4.4335894916714301e-03 -8.1808139380915132e-04 - 26 2.0485904021562374e-03 2.7813358625549847e-03 4.3245727133461040e-03 - 27 4.5604120739958147e-04 -1.0305522979156413e-03 2.1188058932601896e-04 - 28 -6.2544520867527879e-03 1.4127711163464771e-03 -1.8429821878681780e-03 - 29 6.4110631457159361e-04 3.1273432723974521e-03 3.7253671108839165e-03 + 12 2.2945908731373007e-03 -3.6071943605981463e-04 -3.0991093100832976e-03 + 13 2.8239515248589375e-03 5.9007175306100756e-03 -8.0904600793515634e-04 + 14 3.5388608678313884e-03 -5.8841838864859275e-03 -4.0237635208516930e-03 + 15 -1.9334721535550891e-03 -5.9333328189870010e-03 6.3750701628706606e-03 + 16 1.8769054658204248e-02 -1.3336664426271041e-02 -4.5837568812631971e-02 + 17 -1.2953171556495174e-02 9.8061425326315173e-03 3.7494465334416853e-02 + 18 -8.0065792982680743e-04 -8.6270466210164277e-04 -1.4483041097384619e-03 + 19 1.2452390849353508e-03 -2.5061097043873352e-03 7.2998630959149793e-03 + 20 3.5930060239749719e-03 3.6938860332742149e-03 3.2322732677889624e-03 + 21 -1.4689220680373254e-03 -2.7352126917984051e-04 7.0581627972699358e-04 + 22 -7.0694199262180263e-03 -4.2577148912323485e-03 2.8079117893057540e-04 + 23 6.0446963095191156e-03 -1.4000131608108272e-03 2.5819754868763633e-03 + 24 3.1926367011384085e-04 -9.9445665566967731e-04 1.4999995210148600e-04 + 25 1.3789753264027612e-04 -4.4335894916714379e-03 -8.1808139380914991e-04 + 26 2.0485904021562418e-03 2.7813358625549825e-03 4.3245727133461075e-03 + 27 4.5604120739958114e-04 -1.0305522979156385e-03 2.1188058932601804e-04 + 28 -6.2544520867527896e-03 1.4127711163464713e-03 -1.8429821878681776e-03 + 29 6.4110631457159751e-04 3.1273432723974469e-03 3.7253671108839199e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-heat_region.yaml b/unittest/force-styles/tests/fix-timestep-heat_region.yaml index 9c8f740456..bafb639288 100644 --- a/unittest/force-styles/tests/fix-timestep-heat_region.yaml +++ b/unittest/force-styles/tests/fix-timestep-heat_region.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full fix heat @@ -12,7 +13,7 @@ post_commands: ! | fix test solute heat 1 1.0 region half input_file: in.fourmol natoms: 29 -global_scalar: 1.00050043255327 +global_scalar: 1.0005004325532707 run_pos: ! |2 1 -2.7045516854545643e-01 2.4912167937864709e+00 -1.6695868522994808e-01 2 3.1012617560237793e-01 2.9613834371126906e+00 -8.5458315336628909e-01 @@ -28,7 +29,7 @@ run_pos: ! |2 12 3.0063294371894229e+00 -4.9014686486039077e-01 -1.6232434055398743e+00 13 4.0516460250452999e+00 -8.9189262415286041e-01 -1.6400272144528243e+00 14 2.6067032009635347e+00 -4.1802400079391500e-01 -2.6635239882033113e+00 - 15 2.9693983903025920e+00 5.5411639147029756e-01 -1.2340872509024579e+00 + 15 2.9693983903025920e+00 5.5411639147029745e-01 -1.2340872509024579e+00 16 2.6748251207092570e+00 -2.4125155700112826e+00 -2.3741759570257169e-02 17 2.2152664499600916e+00 -2.0897128530550053e+00 1.1966066554673667e+00 18 2.1369701704203949e+00 3.0158507413960924e+00 -3.5179348337433018e+00 @@ -44,33 +45,33 @@ run_pos: ! |2 28 -2.7473562684515063e+00 -4.0200819932382226e+00 1.5830052163435782e+00 29 -1.3126000191364560e+00 -3.5962518039480784e+00 2.2746342468739522e+00 run_vel: ! |2 - 1 8.1713962875410717e-03 1.6517945647642824e-02 4.7898933561615793e-03 - 2 5.5095519596435414e-03 5.2773074753686890e-03 -1.3870456038348009e-03 - 3 -8.2362259603719554e-03 -1.2919723153061063e-02 -4.0940961198097777e-03 - 4 -3.7697810082129427e-03 -6.5725964216033200e-03 -1.1188515654343757e-03 - 5 -1.1022290474803397e-02 -9.8903287993508948e-03 -2.8409899187084964e-03 - 6 -3.9886816732150651e-02 4.7075046515431755e-02 3.7339317277500464e-02 + 1 8.1713962875410717e-03 1.6517945647642824e-02 4.7898933561615767e-03 + 2 5.5095519596435414e-03 5.2773074753686942e-03 -1.3870456038347948e-03 + 3 -8.2362259603719571e-03 -1.2919723153061061e-02 -4.0940961198097717e-03 + 4 -3.7697810082129384e-03 -6.5725964216033252e-03 -1.1188515654343843e-03 + 5 -1.1022290474803393e-02 -9.8903287993509018e-03 -2.8409899187084972e-03 + 6 -3.9886816732150651e-02 4.7075046515431755e-02 3.7339317277500457e-02 7 9.0276635550386880e-04 -1.0186959206607624e-02 -5.1841633648081399e-02 - 8 7.9388736789968942e-03 -3.3742708995381609e-03 3.4736964735818832e-02 - 9 1.5863501003969612e-03 3.7198864635328466e-03 1.5153559452646726e-02 - 10 2.9354733202945054e-02 -2.9393160374179380e-02 -1.5106209164545806e-02 + 8 7.9388736789968925e-03 -3.3742708995381609e-03 3.4736964735818832e-02 + 9 1.5863501003969616e-03 3.7198864635328457e-03 1.5153559452646726e-02 + 10 2.9354733202945054e-02 -2.9393160374179380e-02 -1.5106209164545808e-02 11 -4.8236546630161829e-03 -3.7889846952872887e-03 -2.4047486728993660e-03 - 12 2.2910776416666390e-03 -3.5784362521244621e-04 -3.1033633017964381e-03 - 13 2.8222434313042825e-03 5.9073526148816164e-03 -8.1250421746043272e-04 - 14 3.5349142603834597e-03 -5.8843039888813340e-03 -4.0296209225974041e-03 - 15 -1.9410409672033242e-03 -5.9329655599777795e-03 6.3753187167065965e-03 - 16 1.8767835151863348e-02 -1.3336066982564815e-02 -4.5847831610948575e-02 - 17 -1.2959756512480821e-02 9.8115334427568059e-03 3.7498986341988394e-02 - 18 -8.0065793226746817e-04 -8.6270466929210703e-04 -1.4483041112966397e-03 - 19 1.2452390846436621e-03 -2.5061097049724470e-03 7.2998630961219231e-03 - 20 3.5930060240726503e-03 3.6938860330500011e-03 3.2322732675016358e-03 - 21 -1.4689220686475331e-03 -2.7352126893593113e-04 7.0581627989192426e-04 - 22 -7.0694199262534164e-03 -4.2577148912042589e-03 2.8079117896760648e-04 - 23 6.0446963094815875e-03 -1.4000131608149012e-03 2.5819754868879928e-03 - 24 3.1926367355502542e-04 -9.9445666196931650e-04 1.4999996018086635e-04 - 25 1.3789754403736464e-04 -4.4335894907964954e-03 -8.1808137008148229e-04 - 26 2.0485904030824865e-03 2.7813358626968899e-03 4.3245727146194084e-03 - 27 4.5604120757971478e-04 -1.0305522973693762e-03 2.1188058947067844e-04 - 28 -6.2544520867522093e-03 1.4127711163589287e-03 -1.8429821878561329e-03 - 29 6.4110631452801183e-04 3.1273432724636127e-03 3.7253671109057549e-03 + 12 2.2910776416666429e-03 -3.5784362521244252e-04 -3.1033633017964433e-03 + 13 2.8222434313042778e-03 5.9073526148816120e-03 -8.1250421746042751e-04 + 14 3.5349142603834532e-03 -5.8843039888813366e-03 -4.0296209225974041e-03 + 15 -1.9410409672033296e-03 -5.9329655599777830e-03 6.3753187167065999e-03 + 16 1.8767835151863345e-02 -1.3336066982564813e-02 -4.5847831610948575e-02 + 17 -1.2959756512480821e-02 9.8115334427568042e-03 3.7498986341988394e-02 + 18 -8.0065793226746817e-04 -8.6270466929210703e-04 -1.4483041112966426e-03 + 19 1.2452390846436588e-03 -2.5061097049724501e-03 7.2998630961219283e-03 + 20 3.5930060240726533e-03 3.6938860330500011e-03 3.2322732675016414e-03 + 21 -1.4689220686475322e-03 -2.7352126893593031e-04 7.0581627989192187e-04 + 22 -7.0694199262534242e-03 -4.2577148912042633e-03 2.8079117896760887e-04 + 23 6.0446963094815901e-03 -1.4000131608149012e-03 2.5819754868879998e-03 + 24 3.1926367355502482e-04 -9.9445666196931390e-04 1.4999996018086488e-04 + 25 1.3789754403736436e-04 -4.4335894907965006e-03 -8.1808137008148197e-04 + 26 2.0485904030824904e-03 2.7813358626968872e-03 4.3245727146194101e-03 + 27 4.5604120757971461e-04 -1.0305522973693732e-03 2.1188058947067749e-04 + 28 -6.2544520867522111e-03 1.4127711163589227e-03 -1.8429821878561329e-03 + 29 6.4110631452801551e-04 3.1273432724636097e-03 3.7253671109057562e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-lineforce.yaml b/unittest/force-styles/tests/fix-timestep-lineforce.yaml index fbb3a4f16f..475c19588c 100644 --- a/unittest/force-styles/tests/fix-timestep-lineforce.yaml +++ b/unittest/force-styles/tests/fix-timestep-lineforce.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full fix lineforce @@ -17,7 +18,7 @@ run_pos: ! |2 3 -6.9154139084899435e-01 1.2419093013965214e+00 -6.2301037840695084e-01 4 -1.5777219980722552e+00 1.4877297466842043e+00 -1.2569536794947382e+00 5 -8.9686176133721041e-01 9.3667375360152727e-01 4.0241536507077341e-01 - 6 2.4187643018172986e-01 2.8137527281719688e-01 -1.2827179207187822e+00 + 6 2.4187643018172983e-01 2.8137527281719688e-01 -1.2827179207187822e+00 7 3.4888968696070871e-01 -1.9574766140810270e-02 -2.4648556750396611e+00 8 1.1700700116485798e+00 -4.9055203303004813e-01 -6.7629554485072030e-01 9 1.3769323892363057e+00 -2.5567637681710637e-01 2.7099996788468578e-01 @@ -31,7 +32,7 @@ run_pos: ! |2 17 2.2147336796985106e+00 -2.0839825355487163e+00 1.1508647411842645e+00 18 2.1369701668211705e+00 3.0158507354092841e+00 -3.5179348300192350e+00 19 1.5355837133162105e+00 2.6255292349750459e+00 -4.2353987775013850e+00 - 20 2.7727573004706496e+00 3.6923910448203534e+00 -3.9330842458549418e+00 + 20 2.7727573004706501e+00 3.6923910448203534e+00 -3.9330842458549418e+00 21 4.9040128085316370e+00 -4.0752348182698377e+00 -3.6210314723588679e+00 22 4.3582355554781591e+00 -4.2126119427718338e+00 -4.4612844197357928e+00 23 5.7439382850104428e+00 -3.5821957939485429e+00 -3.8766361296721872e+00 @@ -42,33 +43,33 @@ run_pos: ! |2 28 -2.7473562684628376e+00 -4.0200819932583673e+00 1.5830052163452122e+00 29 -1.3126000190823151e+00 -3.5962518040270703e+00 2.2746342468932106e+00 run_vel: ! |2 - 1 -4.3140527484594746e-03 5.6824341135763229e-03 -2.2179517633030531e-04 - 2 3.8387318479547123e-03 3.5028638595743628e-03 3.5805549693846352e-03 - 3 3.5549115594213148e-03 -3.2177232397003451e-03 -3.3618185901550799e-04 - 4 4.2062914030212880e-04 -2.6027036234744037e-03 -4.1204974953432108e-03 - 5 -5.9826989976337309e-04 1.7242911336143920e-04 6.9023177964912290e-05 - 6 -4.7030037731245006e-02 4.7996436258913769e-02 7.9574303350202582e-04 + 1 -4.3140527484594746e-03 5.6824341135763221e-03 -2.2179517633030531e-04 + 2 3.8387318479547088e-03 3.5028638595743641e-03 3.5805549693846352e-03 + 3 3.5549115594213101e-03 -3.2177232397003408e-03 -3.3618185901550799e-04 + 4 4.2062914030213368e-04 -2.6027036234744089e-03 -4.1204974953432108e-03 + 5 -5.9826989976336572e-04 1.7242911336143161e-04 6.9023177964912290e-05 + 6 -4.7030037731245020e-02 4.7996436258913783e-02 7.9574303350202582e-04 7 8.9195030470518074e-03 -9.7975304477113234e-03 -7.7217630460203659e-04 - 8 3.4583643953017412e-03 -3.8822039017500556e-03 1.5134641148324972e-04 + 8 3.4583643953017417e-03 -3.8822039017500560e-03 1.5134641148324972e-04 9 -1.9735549817944953e-03 5.6026263271721452e-04 1.1117602907112732e-03 - 10 3.1245782059958940e-02 -3.0300390245723133e-02 -2.3336234361093645e-04 + 10 3.1245782059958944e-02 -3.0300390245723133e-02 -2.3336234361093645e-04 11 -1.2906159323544824e-03 -6.0806795363026894e-04 -2.9176389881837113e-03 - 12 1.5681117851482783e-03 -1.1326873111619808e-03 -1.2971152622619948e-03 - 13 2.2505263784070363e-03 5.3292797807106404e-03 -7.8324487687854666e-04 - 14 2.5779062957764927e-03 -6.7818833640233989e-03 -3.9333461173944500e-03 - 15 -1.7570865506312888e-03 -5.7533503541043916e-03 3.2037919043360571e-03 - 16 2.2661700215489858e-02 -2.3258581693297874e-02 1.4945658875149626e-03 - 17 -1.6313130994007091e-02 1.7336410599341715e-02 8.3495414466050911e-04 - 18 -8.0066494115686076e-04 -8.6271629743541454e-04 -1.4482968680445980e-03 - 19 1.2452384863200344e-03 -2.5061108181328616e-03 7.2998640410367197e-03 - 20 3.5930057707802038e-03 3.6938856855613894e-03 3.2322734443129349e-03 - 21 -1.4689196610081362e-03 -2.7352321971665781e-04 7.0581358845536485e-04 - 22 -7.0694198609778059e-03 -4.2577149778400721e-03 2.8079095995765845e-04 - 23 6.0446964813450615e-03 -1.4000131942163694e-03 2.5819753239915600e-03 - 24 3.1926486529862619e-04 -9.9445497704521131e-04 1.5000285732363959e-04 - 25 1.3789932399959270e-04 -4.4335885499470640e-03 -8.1807734292074145e-04 - 26 2.0485906041322823e-03 2.7813360325769916e-03 4.3245729568679604e-03 - 27 4.5604051689362323e-04 -1.0305530019109705e-03 2.1187997350255913e-04 - 28 -6.2544521154417818e-03 1.4127710799290672e-03 -1.8429821887643318e-03 - 29 6.4110640450759117e-04 3.1273431034146669e-03 3.7253671510608082e-03 + 12 1.5681117851482787e-03 -1.1326873111619808e-03 -1.2971152622619948e-03 + 13 2.2505263784070371e-03 5.3292797807106378e-03 -7.8324487687854666e-04 + 14 2.5779062957764923e-03 -6.7818833640233989e-03 -3.9333461173944500e-03 + 15 -1.7570865506312894e-03 -5.7533503541043899e-03 3.2037919043360571e-03 + 16 2.2661700215489848e-02 -2.3258581693297867e-02 1.4945658875149626e-03 + 17 -1.6313130994007091e-02 1.7336410599341712e-02 8.3495414466050911e-04 + 18 -8.0066494115685772e-04 -8.6271629743541118e-04 -1.4482968680446010e-03 + 19 1.2452384863200325e-03 -2.5061108181328633e-03 7.2998640410367214e-03 + 20 3.5930057707801951e-03 3.6938856855613807e-03 3.2322734443129449e-03 + 21 -1.4689196610081358e-03 -2.7352321971665689e-04 7.0581358845536236e-04 + 22 -7.0694198609778163e-03 -4.2577149778400790e-03 2.8079095995766284e-04 + 23 6.0446964813450641e-03 -1.4000131942163694e-03 2.5819753239915669e-03 + 24 3.1926486529862554e-04 -9.9445497704520893e-04 1.5000285732363818e-04 + 25 1.3789932399959059e-04 -4.4335885499470692e-03 -8.1807734292074113e-04 + 26 2.0485906041322875e-03 2.7813360325769894e-03 4.3245729568679664e-03 + 27 4.5604051689362274e-04 -1.0305530019109679e-03 2.1187997350255832e-04 + 28 -6.2544521154417852e-03 1.4127710799290611e-03 -1.8429821887643318e-03 + 29 6.4110640450759497e-04 3.1273431034146621e-03 3.7253671510608121e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-momentum.yaml b/unittest/force-styles/tests/fix-timestep-momentum.yaml index de60504db5..4918468c43 100644 --- a/unittest/force-styles/tests/fix-timestep-momentum.yaml +++ b/unittest/force-styles/tests/fix-timestep-momentum.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:58 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full fix momentum @@ -21,11 +22,11 @@ run_pos: ! |2 7 3.4128930295285081e-01 -2.2476292538227062e-02 -2.5291651920281844e+00 8 1.1741971987803124e+00 -4.8867181447314112e-01 -6.3781284375079017e-01 9 1.3798402136907204e+00 -2.5291599400215098e-01 2.8360404837916814e-01 - 10 2.0510248340781456e+00 -1.4603119912874782e+00 -9.8334408772854798e-01 + 10 2.0510248340781456e+00 -1.4603119912874780e+00 -9.8334408772854798e-01 11 1.7878340499906251e+00 -1.9919672711077894e+00 -1.8892624915574769e+00 - 12 3.0061739654045461e+00 -4.8983606213249270e-01 -1.6231114207152253e+00 + 12 3.0061739654045461e+00 -4.8983606213249264e-01 -1.6231114207152253e+00 13 4.0514549483020454e+00 -8.9161510285045298e-01 -1.6399533074575032e+00 - 14 2.6065958826476647e+00 -4.1746861259418605e-01 -2.6633228782182292e+00 + 14 2.6065958826476643e+00 -4.1746861259418605e-01 -2.6633228782182292e+00 15 2.9692844634545099e+00 5.5445862375426869e-01 -1.2339555368349708e+00 16 2.6747143873239354e+00 -2.4124125103945868e+00 -2.3678910780687939e-02 17 2.2152990283697127e+00 -2.0900254002918404e+00 1.1961127110799876e+00 @@ -42,33 +43,33 @@ run_pos: ! |2 28 -2.7473562684512465e+00 -4.0200819932376648e+00 1.5830052163432808e+00 29 -1.3126000191361060e+00 -3.5962518039478280e+00 2.2746342468735210e+00 run_vel: ! |2 - 1 7.7005442506551877e-03 1.6254943208678482e-02 5.2391698406439582e-03 - 2 4.9551716496531390e-03 5.0854323247987695e-03 -8.9320618875762662e-04 - 3 -8.5622241438673939e-03 -1.3158926269051859e-02 -3.8634909838605675e-03 - 4 -4.1063467058791185e-03 -6.7914727352814137e-03 -8.7233097556554398e-04 - 5 -1.1357391107616042e-02 -1.0307731333056340e-02 -2.6620008997986443e-03 - 6 -3.9891343495354357e-02 4.6788381459479139e-02 3.7259878616184190e-02 - 7 7.6440155294794422e-04 -9.9578168202591223e-03 -5.1503981227747637e-02 - 8 7.7481602383358290e-03 -3.3909462811272393e-03 3.4578349442072526e-02 - 9 1.3519497393498418e-03 3.5673054551750251e-03 1.5111979253235670e-02 - 10 2.9149953529739807e-02 -2.9154244515251084e-02 -1.5125050483704399e-02 - 11 -4.7527059304964623e-03 -3.5292468331570128e-03 -2.5486863981522955e-03 - 12 2.1428332421376153e-03 -5.0254211758299884e-05 -2.9856095438332143e-03 - 13 2.6677223913325137e-03 6.2221432827748654e-03 -7.4731632349203420e-04 - 14 3.4241029250251733e-03 -5.3700577020918414e-03 -3.8703343879204050e-03 - 15 -2.0991482435032353e-03 -5.6230508996015878e-03 6.5404618732815469e-03 - 16 1.8692958611369770e-02 -1.3262292808347639e-02 -4.5881360301899522e-02 - 17 -1.2955019770133578e-02 9.5253088675540769e-03 3.7093990195146913e-02 - 18 -8.0065786143888450e-04 -8.6270469849956098e-04 -1.4483041677008143e-03 - 19 1.2452390909960223e-03 -2.5061097108460230e-03 7.2998630856396024e-03 - 20 3.5930060275390276e-03 3.6938860325705287e-03 3.2322732637322096e-03 - 21 -1.4689220309278663e-03 -2.7352131892528189e-04 7.0581623729667694e-04 - 22 -7.0694199253179147e-03 -4.2577148934110857e-03 2.8079117556050300e-04 - 23 6.0446963126470979e-03 -1.4000131627188064e-03 2.5819754838770485e-03 - 24 3.1926365427529342e-04 -9.9445665072252177e-04 1.4999998574684873e-04 - 25 1.3789751822613832e-04 -4.4335895024089156e-03 -8.1808136833231562e-04 - 26 2.0485904030163515e-03 2.7813358630790546e-03 4.3245727163037546e-03 - 27 4.5604121009814566e-04 -1.0305522934457038e-03 2.1188057606121659e-04 - 28 -6.2544520858826367e-03 1.4127711184825813e-03 -1.8429821888491355e-03 - 29 6.4110631499494420e-04 3.1273432734981381e-03 3.7253671097253116e-03 + 1 7.7005442506551895e-03 1.6254943208678478e-02 5.2391698406439539e-03 + 2 4.9551716496531381e-03 5.0854323247987790e-03 -8.9320618875761968e-04 + 3 -8.5622241438673974e-03 -1.3158926269051853e-02 -3.8634909838605601e-03 + 4 -4.1063467058791167e-03 -6.7914727352814232e-03 -8.7233097556555135e-04 + 5 -1.1357391107616039e-02 -1.0307731333056345e-02 -2.6620008997986456e-03 + 6 -3.9891343495354364e-02 4.6788381459479132e-02 3.7259878616184190e-02 + 7 7.6440155294794346e-04 -9.9578168202591223e-03 -5.1503981227747637e-02 + 8 7.7481602383358238e-03 -3.3909462811272388e-03 3.4578349442072526e-02 + 9 1.3519497393498416e-03 3.5673054551750242e-03 1.5111979253235670e-02 + 10 2.9149953529739814e-02 -2.9154244515251081e-02 -1.5125050483704399e-02 + 11 -4.7527059304964623e-03 -3.5292468331570115e-03 -2.5486863981522946e-03 + 12 2.1428332421376201e-03 -5.0254211758299464e-05 -2.9856095438332187e-03 + 13 2.6677223913325011e-03 6.2221432827748585e-03 -7.4731632349203344e-04 + 14 3.4241029250251728e-03 -5.3700577020918466e-03 -3.8703343879204024e-03 + 15 -2.0991482435032400e-03 -5.6230508996015852e-03 6.5404618732815521e-03 + 16 1.8692958611369766e-02 -1.3262292808347637e-02 -4.5881360301899522e-02 + 17 -1.2955019770133577e-02 9.5253088675540751e-03 3.7093990195146913e-02 + 18 -8.0065786143888450e-04 -8.6270469849956000e-04 -1.4483041677008169e-03 + 19 1.2452390909960193e-03 -2.5061097108460260e-03 7.2998630856396110e-03 + 20 3.5930060275390276e-03 3.6938860325705296e-03 3.2322732637322152e-03 + 21 -1.4689220309278652e-03 -2.7352131892528103e-04 7.0581623729667423e-04 + 22 -7.0694199253179190e-03 -4.2577148934110900e-03 2.8079117556050544e-04 + 23 6.0446963126471005e-03 -1.4000131627188064e-03 2.5819754838770541e-03 + 24 3.1926365427529282e-04 -9.9445665072251939e-04 1.4999998574684737e-04 + 25 1.3789751822613664e-04 -4.4335895024089226e-03 -8.1808136833231475e-04 + 26 2.0485904030163558e-03 2.7813358630790525e-03 4.3245727163037607e-03 + 27 4.5604121009814528e-04 -1.0305522934457014e-03 2.1188057606121567e-04 + 28 -6.2544520858826393e-03 1.4127711184825750e-03 -1.8429821888491351e-03 + 29 6.4110631499494800e-04 3.1273432734981333e-03 3.7253671097253129e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-momentum_chunk.yaml b/unittest/force-styles/tests/fix-timestep-momentum_chunk.yaml index 9151c9f4aa..151dc337c8 100644 --- a/unittest/force-styles/tests/fix-timestep-momentum_chunk.yaml +++ b/unittest/force-styles/tests/fix-timestep-momentum_chunk.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | atom full fix momentum/chunk @@ -13,10 +14,10 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_pos: ! |2 - 1 -2.7045559776940059e-01 2.4912159905942945e+00 -1.6695851787754792e-01 + 1 -2.7045559776940054e-01 2.4912159905942945e+00 -1.6695851787754792e-01 2 3.1004029573983188e-01 2.9612354631105791e+00 -8.5466363036594983e-01 3 -7.0398551402051845e-01 1.2305509955829790e+00 -6.2777526943157458e-01 - 4 -1.5818159336498527e+00 1.4837407818931581e+00 -1.2538710836059535e+00 + 4 -1.5818159336498525e+00 1.4837407818931581e+00 -1.2538710836059535e+00 5 -9.0719763672748088e-01 9.2652103885793269e-01 3.9954210488439806e-01 6 2.4831720522392728e-01 2.8313021495830565e-01 -1.2314233331566868e+00 7 3.4143527642025906e-01 -2.2646551012341816e-02 -2.5292291415057555e+00 @@ -24,7 +25,7 @@ run_pos: ! |2 9 1.3800524229492390e+00 -2.5274721030435859e-01 2.8353985887000682e-01 10 2.0510765220351503e+00 -1.4604063740164097e+00 -9.8323745079722358e-01 11 1.7878031944362351e+00 -1.9921863272879650e+00 -1.8890602447585003e+00 - 12 3.0063007039363794e+00 -4.9013350498506214e-01 -1.6231898107164899e+00 + 12 3.0063007039363794e+00 -4.9013350498506209e-01 -1.6231898107164899e+00 13 4.0515402959203435e+00 -8.9202011605777409e-01 -1.6400005529900739e+00 14 2.6066963345537824e+00 -4.1789253965268658e-01 -2.6634003608790460e+00 15 2.9695287185713339e+00 5.5422613165265810e-01 -1.2342022021788850e+00 @@ -34,7 +35,7 @@ run_pos: ! |2 19 1.5347324041794299e+00 2.6269830802828062e+00 -4.2364139965880332e+00 20 2.7733999524106205e+00 3.6919554439456537e+00 -3.9335794185327781e+00 21 4.9054080935531896e+00 -4.0749170558994008e+00 -3.6221798333564097e+00 - 22 4.3598334200959119e+00 -4.2110652924725507e+00 -4.4627584709128509e+00 + 22 4.3598334200959119e+00 -4.2110652924725516e+00 -4.4627584709128509e+00 23 5.7436581434986254e+00 -3.5782602539408330e+00 -3.8762571951349565e+00 24 2.0680638887755789e+00 3.1522780027243096e+00 3.1544857033001050e+00 25 1.3029441343422379e+00 3.2687312534589186e+00 2.5117363129771140e+00 @@ -43,33 +44,33 @@ run_pos: ! |2 28 -2.7473562684513411e+00 -4.0200819932379330e+00 1.5830052163433954e+00 29 -1.3126000191360072e+00 -3.5962518039483111e+00 2.2746342468737759e+00 run_vel: ! |2 - 1 8.1705743682217672e-03 1.6516406260336319e-02 4.7902265526728180e-03 - 2 5.4501493470307926e-03 5.1791699444061756e-03 -1.4372931390219934e-03 - 3 -8.2298293123878579e-03 -1.2926551614512290e-02 -4.0984180762662524e-03 - 4 -3.7699042588338477e-03 -6.5722892093522259e-03 -1.1184640351803122e-03 - 5 -1.1021961003142667e-02 -9.8906780902275216e-03 -2.8410737807552959e-03 - 6 -3.9676663245182972e-02 4.6817061399691134e-02 3.7148492025503965e-02 + 1 8.1705743682217672e-03 1.6516406260336316e-02 4.7902265526728180e-03 + 2 5.4501493470307995e-03 5.1791699444061869e-03 -1.4372931390219958e-03 + 3 -8.2298293123878579e-03 -1.2926551614512286e-02 -4.0984180762662472e-03 + 4 -3.7699042588338508e-03 -6.5722892093522320e-03 -1.1184640351803209e-03 + 5 -1.1021961003142663e-02 -9.8906780902275337e-03 -2.8410737807552976e-03 + 6 -3.9676663245182972e-02 4.6817061399691128e-02 3.7148492025503965e-02 7 9.1033955088063920e-04 -1.0128524318392149e-02 -5.1568251854024527e-02 - 8 7.9064711503765879e-03 -3.3507255030852494e-03 3.4557098539932794e-02 + 8 7.9064711503765879e-03 -3.3507255030852507e-03 3.4557098539932794e-02 9 1.5644176092493192e-03 3.7365546094037198e-03 1.5047408819177203e-02 - 10 2.9201446758876440e-02 -2.9249578700648277e-02 -1.5018077360191942e-02 + 10 2.9201446758876443e-02 -2.9249578700648277e-02 -1.5018077360191942e-02 11 -4.7835961770116330e-03 -3.7481384912218460e-03 -2.3464104010745344e-03 - 12 2.2696451917719684e-03 -3.4774159319509286e-04 -3.0640769620418336e-03 - 13 2.7531740485974765e-03 5.8171061891998613e-03 -7.9467453244699132e-04 - 14 3.5246182353144665e-03 -5.7939995507701909e-03 -3.9478431158352766e-03 - 15 -1.8547943638585198e-03 -5.8554729933366269e-03 6.2938485145085385e-03 - 16 1.8681499911911231e-02 -1.3262466144640238e-02 -4.5638651340895918e-02 - 17 -1.2896269995828089e-02 9.7527665190860428e-03 3.7296535378544979e-02 - 18 -1.1597964643950771e-03 -5.5275601117699602e-04 -2.2596898317004273e-03 - 19 3.9437769178642850e-04 -1.0524992231078548e-03 6.2843375981024080e-03 - 20 4.2354440002654982e-03 3.2590603306157590e-03 2.7361770536408364e-03 - 21 -7.3166083961043220e-05 4.3153693824293766e-05 -4.4291122723026888e-04 - 22 -5.4710524890446760e-03 -2.7110168901437028e-03 -1.1941441295444857e-03 - 23 5.7631260838904861e-03 2.5387505366123607e-03 2.9622129851031927e-03 - 24 -5.4151131048706092e-04 -5.0897084827800265e-05 -4.0258550718128802e-04 - 25 -1.4539138931934654e-03 -2.2135919688303011e-03 -2.6583939032311793e-04 - 26 3.6155869873532292e-03 2.4167693664445132e-03 1.8729309544673661e-03 - 27 4.5604120293354369e-04 -1.0305523026922869e-03 2.1188058381354328e-04 - 28 -6.2544520861855194e-03 1.4127711176146755e-03 -1.8429821884794262e-03 - 29 6.4110631527495069e-04 3.1273432719001841e-03 3.7253671105393661e-03 + 12 2.2696451917719757e-03 -3.4774159319509237e-04 -3.0640769620418396e-03 + 13 2.7531740485974656e-03 5.8171061891998518e-03 -7.9467453244698449e-04 + 14 3.5246182353144600e-03 -5.7939995507701944e-03 -3.9478431158352766e-03 + 15 -1.8547943638585241e-03 -5.8554729933366252e-03 6.2938485145085446e-03 + 16 1.8681499911911228e-02 -1.3262466144640236e-02 -4.5638651340895918e-02 + 17 -1.2896269995828089e-02 9.7527665190860393e-03 3.7296535378544979e-02 + 18 -1.1597964643950771e-03 -5.5275601117699526e-04 -2.2596898317004304e-03 + 19 3.9437769178642676e-04 -1.0524992231078579e-03 6.2843375981024132e-03 + 20 4.2354440002655000e-03 3.2590603306157590e-03 2.7361770536408433e-03 + 21 -7.3166083961044914e-05 4.3153693824293562e-05 -4.4291122723027332e-04 + 22 -5.4710524890446708e-03 -2.7110168901437054e-03 -1.1941441295444720e-03 + 23 5.7631260838904852e-03 2.5387505366123641e-03 2.9622129851031966e-03 + 24 -5.4151131048706168e-04 -5.0897084827797866e-05 -4.0258550718128949e-04 + 25 -1.4539138931934671e-03 -2.2135919688303076e-03 -2.6583939032311647e-04 + 26 3.6155869873532340e-03 2.4167693664445106e-03 1.8729309544673709e-03 + 27 4.5604120293354342e-04 -1.0305523026922843e-03 2.1188058381354233e-04 + 28 -6.2544520861855229e-03 1.4127711176146699e-03 -1.8429821884794258e-03 + 29 6.4110631527495459e-04 3.1273432719001802e-03 3.7253671105393687e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-nph.yaml b/unittest/force-styles/tests/fix-timestep-nph.yaml index a21fe19fa8..dbf4064b74 100644 --- a/unittest/force-styles/tests/fix-timestep-nph.yaml +++ b/unittest/force-styles/tests/fix-timestep-nph.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full fix nph @@ -10,7 +11,7 @@ post_commands: ! | fix test solute nph aniso 1.0 1.0 100.0 ptemp ${t_target} fixedpoint 0.0 0.0 0.0 couple xy input_file: in.fourmol natoms: 29 -global_scalar: 157.324342558061 +global_scalar: 157.32434255806083 global_vector: ! |- 24 0.03782582730845563 0.03782582730845563 0.08149262752796986 0.028119558903421393 0.028119558903421393 0.0527171493109954 0.10922307816947409 0.0034329971508844604 -0.00019663936227634895 0.16528845193168182 0.011258118934021979 -0.0001767050030808935 0.002791882968285112 0.002791882968285112 0.002791882968285112 23.569551012162435 23.569551012162435 82.8396274600218 0.021704883273300262 0.000682207493931851 -3.9076305819928785e-05 27.145514121895616 0.12593449698077608 3.1024924904494816e-05 run_pos: ! |2 @@ -44,23 +45,23 @@ run_pos: ! |2 28 -2.8463050790215982e+00 -4.1757254084039737e+00 1.7172628242784782e+00 29 -1.3613559351366451e+00 -3.7380527823491150e+00 2.4606149196874831e+00 run_vel: ! |2 - 1 7.6565961842874073e-03 1.3080850909322607e-02 1.8328859839073495e-03 - 2 1.8760112180452771e-03 2.5666078592533645e-03 2.8834568739837534e-03 - 3 -6.5747711080207339e-03 -9.4370588251179374e-03 -2.2745325502991423e-03 - 4 -1.6365708631326022e-03 -6.6432508563253638e-03 1.1218655930945432e-03 - 5 -1.0089064293266134e-02 -8.6234651250773377e-03 -6.6697198186027517e-03 + 1 7.6565961842874073e-03 1.3080850909322607e-02 1.8328859839073454e-03 + 2 1.8760112180452781e-03 2.5666078592533705e-03 2.8834568739837586e-03 + 3 -6.5747711080207374e-03 -9.4370588251179340e-03 -2.2745325502991362e-03 + 4 -1.6365708631325968e-03 -6.6432508563253681e-03 1.1218655930945358e-03 + 5 -1.0089064293266130e-02 -8.6234651250773463e-03 -6.6697198186027526e-03 6 -3.1528934756543614e-02 3.7022817627879213e-02 2.3911067453951655e-02 7 3.1550265512229187e-04 -7.1593752877010097e-03 -3.6173540781531920e-02 - 8 6.3829935675636983e-03 -2.2482453728018686e-03 2.9450232742979827e-02 + 8 6.3829935675636983e-03 -2.2482453728018704e-03 2.9450232742979830e-02 9 -4.9925369016013505e-04 1.4791155501508453e-03 5.5387020254672173e-03 - 10 2.4586222989032260e-02 -2.3830859019713581e-02 -1.2874036642974162e-02 + 10 2.4586222989032267e-02 -2.3830859019713581e-02 -1.2874036642974164e-02 11 -3.7917501131674294e-03 -2.0254850167193911e-03 1.1948750164912784e-03 - 12 1.6115495437094157e-03 -5.9368868615678578e-04 -3.2386570228979113e-03 - 13 7.2282620116543097e-04 6.3326083256349738e-03 -4.8419465393188376e-04 - 14 4.5044534232601069e-03 -5.6181937891921357e-03 4.8663106449362627e-04 - 15 -1.7355580844387413e-03 -7.7347714440367385e-03 4.7018833249165889e-03 - 16 1.2717480374927991e-02 -8.6072327917308192e-03 -3.1454404079186371e-02 - 17 -8.8793881732904117e-03 6.9626162171521405e-03 2.5474225553719757e-02 + 12 1.6115495437094196e-03 -5.9368868615678166e-04 -3.2386570228979165e-03 + 13 7.2282620116542664e-04 6.3326083256349660e-03 -4.8419465393187915e-04 + 14 4.5044534232601009e-03 -5.6181937891921418e-03 4.8663106449362735e-04 + 15 -1.7355580844387460e-03 -7.7347714440367385e-03 4.7018833249165976e-03 + 16 1.2717480374927991e-02 -8.6072327917308174e-03 -3.1454404079186371e-02 + 17 -8.8793881732904100e-03 6.9626162171521379e-03 2.5474225553719761e-02 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-nph_sphere.yaml b/unittest/force-styles/tests/fix-timestep-nph_sphere.yaml index 5740f1c772..bd4a0129a0 100644 --- a/unittest/force-styles/tests/fix-timestep-nph_sphere.yaml +++ b/unittest/force-styles/tests/fix-timestep-nph_sphere.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 14:13:03 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 2e-13 skip_tests: prerequisites: ! | @@ -18,7 +18,7 @@ input_file: in.dipole natoms: 29 global_scalar: 2.6530736625996387 global_vector: ! |- - 24 -0.00029360717345345503 -0.00029360717345345503 -0.009802195812217975 -0.0002295892446149489 -0.0002295892446149489 -0.009426150676164043 0.00038215586827905577 -0.0001999367873398407 -0.00019998672264189484 0.0013055190397921652 -0.00019964191319805292 -0.00019997330643321473 -0.00016957632738679295 -0.00016957632738679295 -0.00016957632738679295 0.0015712213802849902 0.0015712213802849902 2.6485187819688587 7.59422701888457e-05 -3.973157233782066e-05 -3.974149551450151e-05 0.0016934776411678706 3.960194290753771e-05 3.973352558103608e-05 + 24 -0.0002936071734534549 -0.0002936071734534549 -0.009802195812217975 -0.0002295892446149488 -0.0002295892446149488 -0.009426150676164043 0.00038215586827905577 -0.0001999367873398407 -0.00019998672264189484 0.0013055190397921652 -0.00019964191319805292 -0.00019997330643321473 -0.00016957632738679295 -0.00016957632738679295 -0.00016957632738679295 0.001571221380284989 0.001571221380284989 2.6485187819688587 7.59422701888457e-05 -3.973157233782066e-05 -3.974149551450151e-05 0.0016934776411678706 3.960194290753771e-05 3.973352558103608e-05 run_pos: ! |2 1 -2.7827104751341025e-01 2.4732379209353574e+00 -1.7098367287678773e-01 2 3.0951603206194456e-01 2.9505189917751125e+00 -8.3691694167351027e-01 @@ -50,23 +50,23 @@ run_pos: ! |2 28 -2.7398474814917915e+00 -4.0195447873597807e+00 1.5674291899980410e+00 29 -1.3104384550303312e+00 -3.5982420074671468e+00 2.2459227533114134e+00 run_vel: ! |2 - 1 8.0241784898899828e-04 7.1649810278735088e-04 -4.3254783495965635e-04 - 2 4.9920840652361133e-03 -4.7901355269901027e-03 8.0415105059913512e-03 - 3 -1.0246626622144124e-03 1.9728648029617435e-03 -4.1786270885854984e-04 - 4 -2.5514266874426907e-03 -3.8470310506856666e-04 -7.6419956671648741e-03 - 5 -1.0997203136770472e-02 -1.1100959801421180e-02 7.4710776737198642e-03 - 6 -9.6097534134826279e-05 1.3350328233459241e-03 5.6128607413785875e-04 + 1 8.0241784898899828e-04 7.1649810278735077e-04 -4.3254783495965662e-04 + 2 4.9920840652361133e-03 -4.7901355269901000e-03 8.0415105059913512e-03 + 3 -1.0246626622144124e-03 1.9728648029617439e-03 -4.1786270885854951e-04 + 4 -2.5514266874426881e-03 -3.8470310506856980e-04 -7.6419956671648758e-03 + 5 -1.0997203136770465e-02 -1.1100959801421185e-02 7.4710776737198633e-03 + 6 -9.6097534134826346e-05 1.3350328233459241e-03 5.6128607413785875e-04 7 -4.3022722269905067e-05 -6.9147676609541530e-04 -7.0822487621355530e-04 8 2.6656323611303379e-04 -6.4929896813388250e-04 6.8721556911616026e-04 9 4.0217754987332526e-03 -9.3762987441709713e-03 -1.8217220558355389e-02 - 10 3.9241017078855858e-04 7.9179015547129058e-04 -1.8323030547845353e-04 + 10 3.9241017078855885e-04 7.9179015547129058e-04 -1.8323030547845367e-04 11 -4.1986571777318281e-03 -7.2528133986728104e-03 -6.9700940876634846e-03 - 12 1.1518085352395188e-03 -7.7797212668168330e-04 -1.7491524590193147e-03 - 13 -1.1763167453607102e-03 2.1016758888847365e-03 -7.0140970399881785e-04 - 14 3.4959302252370928e-03 -8.0425729559116862e-03 2.4731781160335117e-03 - 15 -4.0163275838685725e-03 2.2205560641154126e-04 1.6595018075308821e-02 - 16 -2.0953855224036227e-04 -3.5810043463447037e-04 1.8771712621666707e-03 - 17 6.8683193653879806e-04 3.2771494523541208e-04 6.5315694215737502e-04 + 12 1.1518085352395190e-03 -7.7797212668168298e-04 -1.7491524590193149e-03 + 13 -1.1763167453607117e-03 2.1016758888847335e-03 -7.0140970399881471e-04 + 14 3.4959302252370907e-03 -8.0425729559116862e-03 2.4731781160335130e-03 + 15 -4.0163275838685742e-03 2.2205560641153996e-04 1.6595018075308821e-02 + 16 -2.0953855224036243e-04 -3.5810043463447016e-04 1.8771712621666709e-03 + 17 6.8683193653879806e-04 3.2771494523541197e-04 6.5315694215737502e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-npt_aniso.yaml b/unittest/force-styles/tests/fix-timestep-npt_aniso.yaml index b7d7a2a32e..978b59cdbf 100644 --- a/unittest/force-styles/tests/fix-timestep-npt_aniso.yaml +++ b/unittest/force-styles/tests/fix-timestep-npt_aniso.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 4e-11 +skip_tests: prerequisites: ! | atom full fix npt @@ -10,9 +11,9 @@ post_commands: ! | fix test solute npt temp 50.0 ${t_target} 1.0 aniso 1.0 1.0 100.0 drag 0.01 flip no input_file: in.fourmol natoms: 29 -global_scalar: 343.095604765377 +global_scalar: 343.09560476537735 global_vector: ! |- - 36 1.4104106041871818 5.544125660512262 27.686084418162828 0.7043226445808922 1.523498251021069 24.83175835256217 0.059984390584387294 0.05988360800662691 0.1289951938025459 0.033166868532850516 0.032616875459535025 0.060704622622279256 0.31065873375184067 0.031231059239067528 4.6799092315332296e-05 0.38632917344330703 0.08291085151805419 0.0013258269540048562 23.54333018009125 1.1017323658211893 5.501797245253877 4.140336471802744 0.230619999607791 61.267194471795534 0.004636061307993073 0.004636061307993073 0.004636061307993073 24.59260327356766 23.7837469738805 82.38328256037414 0.061734311712517385 0.006206257016797189 9.299946980294684e-06 111.22164657602883 5.122678041400132 0.0013099297283524043 + 36 1.4104106041871818 5.544125660512261 27.68608441816282 0.7043226445808926 1.5234982510210697 24.83175835256217 0.0599843905843873 0.05988360800662691 0.1289951938025459 0.033166868532850516 0.03261687545953501 0.060704622622279256 0.31065873375184067 0.031231059239067528 4.6799092315332296e-05 0.38632917344330703 0.08291085151805419 0.0013258269540048562 23.54333018009125 1.101732365821189 5.501797245253876 4.1403364718027476 0.2306199996077912 61.267194471795534 0.004636061307993073 0.004636061307993073 0.004636061307993073 24.59260327356766 23.783746973880483 82.38328256037414 0.061734311712517385 0.006206257016797189 9.299946980294684e-06 111.22164657602883 5.122678041400132 0.0013099297283524043 run_pos: ! |2 1 -3.8261786782382412e-01 2.6468375260657648e+00 -1.1358866558857095e-01 2 2.3224967663088947e-01 3.1501493306692314e+00 -8.8938943152906980e-01 @@ -44,23 +45,23 @@ run_pos: ! |2 28 -3.0012899885135189e+00 -4.2569536621455875e+00 1.8816161875271611e+00 29 -1.4830692409518882e+00 -3.8095196882276410e+00 2.6611315389212198e+00 run_vel: ! |2 - 1 3.3240330987135813e-03 4.3348472804384443e-03 -7.7000850356568598e-04 - 2 -1.7788564989713377e-03 -1.3033340996862442e-03 3.3101416084626834e-03 - 3 -2.0736106571327740e-03 -2.9833723016999126e-03 3.0677418793886486e-06 - 4 7.7912294662807273e-04 -3.0921958393268071e-03 2.8549261268555064e-03 - 5 -4.1587002273456653e-03 -3.6518175878378690e-03 -5.8605014494220939e-03 - 6 -1.0673219518891219e-02 1.2095185080065048e-02 3.5954871446313933e-03 - 7 -1.3016092142144198e-04 -1.5438536332060906e-03 -8.6626684342265125e-03 - 8 2.0883538800072188e-03 -3.1837196665129652e-04 1.1801128542985692e-02 - 9 -1.6065275717747234e-03 1.4851083434963298e-04 -2.5301349369061935e-03 - 10 9.3031302344406246e-03 -8.6622025962185441e-03 -5.3718824903226719e-03 - 11 -1.2019843168147525e-03 4.3918657625861092e-04 3.4618217803594302e-03 - 12 1.7788144047621368e-04 -2.6878343649230967e-04 -1.5175167351688945e-03 - 13 -1.8807030955883249e-03 2.7155375226017805e-03 9.8699039446766083e-05 - 14 2.9038215261273626e-03 -1.7898438773840987e-03 3.8737544018497979e-03 - 15 1.8059365653976903e-04 -4.3808636795798338e-03 7.4140416456126444e-04 - 16 2.6156852337186408e-03 -1.2844226093444698e-03 -7.6689169374931799e-03 - 17 -2.0276918149482290e-03 1.6195218336326309e-03 5.6072249357656126e-03 + 1 3.3240330987135817e-03 4.3348472804384443e-03 -7.7000850356568728e-04 + 2 -1.7788564989713368e-03 -1.3033340996862408e-03 3.3101416084626860e-03 + 3 -2.0736106571327749e-03 -2.9833723016999092e-03 3.0677418793910034e-06 + 4 7.7912294662807469e-04 -3.0921958393268102e-03 2.8549261268555029e-03 + 5 -4.1587002273456644e-03 -3.6518175878378738e-03 -5.8605014494220956e-03 + 6 -1.0673219518891219e-02 1.2095185080065050e-02 3.5954871446313950e-03 + 7 -1.3016092142144198e-04 -1.5438536332060908e-03 -8.6626684342265125e-03 + 8 2.0883538800072180e-03 -3.1837196665129744e-04 1.1801128542985692e-02 + 9 -1.6065275717747239e-03 1.4851083434963298e-04 -2.5301349369061940e-03 + 10 9.3031302344406264e-03 -8.6622025962185441e-03 -5.3718824903226745e-03 + 11 -1.2019843168147527e-03 4.3918657625861092e-04 3.4618217803594302e-03 + 12 1.7788144047621568e-04 -2.6878343649230777e-04 -1.5175167351688976e-03 + 13 -1.8807030955883262e-03 2.7155375226017779e-03 9.8699039446768441e-05 + 14 2.9038215261273596e-03 -1.7898438773841011e-03 3.8737544018497992e-03 + 15 1.8059365653976702e-04 -4.3808636795798364e-03 7.4140416456126748e-04 + 16 2.6156852337186399e-03 -1.2844226093444693e-03 -7.6689169374931799e-03 + 17 -2.0276918149482290e-03 1.6195218336326300e-03 5.6072249357656135e-03 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-npt_iso.yaml b/unittest/force-styles/tests/fix-timestep-npt_iso.yaml index 1a47662b76..812fec0c41 100644 --- a/unittest/force-styles/tests/fix-timestep-npt_iso.yaml +++ b/unittest/force-styles/tests/fix-timestep-npt_iso.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 2e-12 +skip_tests: prerequisites: ! | atom full fix npt @@ -10,7 +11,7 @@ post_commands: ! | fix test solute npt temp 50.0 ${t_target} 1.0 iso 1.0 1.0 100.0 dilate solute input_file: in.fourmol natoms: 29 -global_scalar: 394.052580100464 +global_scalar: 394.05258010046373 global_vector: ! |- 28 1.4984570204083703 5.727668251607705 30.006785365785095 0.755949606916964 1.5716837282414435 27.238363703562367 0.0887726458699618 0.04948138278794819 0.29647653888194264 0.027838608034509143 -1.2684933237431522e-05 0.39157825633023396 0.07798523077702334 0.0010654320610989716 25.013048177187418 1.1382060724972116 5.962968492435009 4.7695567904527465 0.24543888024081967 73.71826005814913 0.015019759138686235 164.21033059328448 0.058916016445900686 0.005532106840485039 -2.520758431847661e-06 114.264532425479 4.532095302918083 0.000845913261377488 run_pos: ! |2 @@ -44,23 +45,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 2.7344298948821458e-03 3.1581468104380935e-03 -7.1843120411167717e-04 - 2 -1.7078379474947108e-03 -1.6409070859861360e-03 2.6128987225916729e-03 - 3 -1.4420164647255642e-03 -1.7442912543734887e-03 -7.0745062575908337e-05 - 4 1.3055902518738962e-03 -3.2440606689853393e-03 2.3536117576802057e-03 - 5 -3.7768785005134814e-03 -3.4050691962219590e-03 -4.3060378047272488e-03 - 6 -9.6303105059201439e-03 1.1636424089177611e-02 8.0882426998230839e-03 + 1 2.7344298948821458e-03 3.1581468104380922e-03 -7.1843120411167857e-04 + 2 -1.7078379474947108e-03 -1.6409070859861328e-03 2.6128987225916755e-03 + 3 -1.4420164647255659e-03 -1.7442912543734863e-03 -7.0745062575905911e-05 + 4 1.3055902518738980e-03 -3.2440606689853424e-03 2.3536117576802018e-03 + 5 -3.7768785005134796e-03 -3.4050691962219629e-03 -4.3060378047272497e-03 + 6 -9.6303105059201456e-03 1.1636424089177611e-02 8.0882426998230839e-03 7 -9.1197836178494661e-06 -2.0548971114176177e-03 -1.1561711720116066e-02 - 8 2.3717342384511060e-03 -1.1724667732074462e-03 9.9981918637160709e-03 + 8 2.3717342384511056e-03 -1.1724667732074469e-03 9.9981918637160726e-03 9 -1.0596786897297246e-03 6.2180807146028599e-04 -1.9949136612792850e-04 - 10 7.6866979670994649e-03 -6.4210563260423160e-03 -4.6594157108994479e-03 + 10 7.6866979670994649e-03 -6.4210563260423143e-03 -4.6594157108994479e-03 11 -1.2201636757560200e-03 4.4492192830042360e-04 2.4485003896230857e-03 - 12 2.6440970729963017e-04 -2.5426715254078699e-04 -9.8591736348869791e-04 - 13 -2.9186187764568771e-03 2.9250796003296472e-03 -1.0409641755324341e-04 - 14 2.7357332424176799e-03 -1.8075638409764203e-03 2.3417976176845772e-03 - 15 2.7042452512660167e-04 -4.9830656916804491e-03 8.0004168431170792e-04 - 16 3.2285718415043510e-03 -1.6540417724780236e-03 -1.0034443516953472e-02 - 17 -2.5912230280785136e-03 1.9472241032175749e-03 7.5710821795849197e-03 + 12 2.6440970729963207e-04 -2.5426715254078509e-04 -9.8591736348870051e-04 + 13 -2.9186187764568784e-03 2.9250796003296433e-03 -1.0409641755324121e-04 + 14 2.7357332424176773e-03 -1.8075638409764242e-03 2.3417976176845780e-03 + 15 2.7042452512659944e-04 -4.9830656916804500e-03 8.0004168431171041e-04 + 16 3.2285718415043492e-03 -1.6540417724780231e-03 -1.0034443516953472e-02 + 17 -2.5912230280785127e-03 1.9472241032175738e-03 7.5710821795849197e-03 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-npt_sphere_aniso.yaml b/unittest/force-styles/tests/fix-timestep-npt_sphere_aniso.yaml index e920859bf2..82bff3f533 100644 --- a/unittest/force-styles/tests/fix-timestep-npt_sphere_aniso.yaml +++ b/unittest/force-styles/tests/fix-timestep-npt_sphere_aniso.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 14:10:26 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 4e-13 skip_tests: prerequisites: ! | @@ -16,9 +16,9 @@ post_commands: ! | fix test solute npt/sphere temp 50.0 ${t_target} 1.0 aniso 1.0 1.0 100.0 drag 0.01 flip no input_file: in.dipole natoms: 29 -global_scalar: 12.096663886115614 +global_scalar: 12.096663886115623 global_vector: ! |- - 36 0.18697665312191866 1.3884401940983198 -1.143641040188949 0.09347675524754455 2.0071422867094624 0.425406696845947 -0.002573189219691047 0.001618379686061744 -0.017497577807990692 -0.0020955754000787424 0.0015446684493233807 -0.01488781896977487 0.0026972315134052606 -0.00023072428193059388 -0.00023289107491333692 0.005208648473644532 -0.00022780275682141358 -0.00023637594502603685 6.35369750884944 0.2759117656261481 -0.22726511374584485 0.14846237885657246 0.40028504859566 0.017981325048433597 -0.0002999716767593198 -0.0002999716767593198 -0.0002999716767593198 0.09817527997528167 0.053341609668296035 4.95516047425249 0.0005359956534890073 -4.5849683890516504e-05 -4.6280270443798504e-05 0.020217358264846576 3.867161073461921e-05 4.1637137703144936e-05 + 36 0.1869766531219188 1.3884401940983202 -1.143641040188948 0.09347675524754469 2.007142286709465 0.4254066968459499 -0.0025731892196910453 0.0016183796860617433 -0.017497577807990692 -0.0020955754000787407 0.00154466844932338 -0.01488781896977487 0.0026972315134052606 -0.00023072428193059388 -0.00023289107491333692 0.005208648473644532 -0.00022780275682141358 -0.00023637594502603685 6.353697508849446 0.2759117656261482 -0.22726511374584468 0.1484623788565729 0.40028504859566105 0.017981325048433843 -0.0002999716767593198 -0.0002999716767593198 -0.0002999716767593198 0.0981752799752815 0.053341609668295986 4.95516047425249 0.0005359956534890073 -4.5849683890516504e-05 -4.6280270443798504e-05 0.020217358264846576 3.867161073461921e-05 4.1637137703144936e-05 run_pos: ! |2 1 -2.7397105633323537e-01 2.4781785743666527e+00 -1.7980596873158383e-01 2 3.1208634768681343e-01 2.9563521874575622e+00 -8.4152963592209495e-01 @@ -50,23 +50,23 @@ run_pos: ! |2 28 -2.7298172127749782e+00 -4.0269250728459882e+00 1.5452330932758489e+00 29 -1.3036629303295193e+00 -3.6048159970063285e+00 2.2185254278264974e+00 run_vel: ! |2 - 1 6.6645514337822221e-04 6.0192577730141313e-04 -3.7299030694254784e-04 - 2 4.4186462683745379e-03 -4.6840896920226378e-03 6.9463033422740798e-03 - 3 -8.2788283512656344e-04 1.6664323303816279e-03 -3.6067014934863578e-04 - 4 -2.3360131422093121e-03 -2.4652356574843070e-04 -6.7612095269435086e-03 - 5 -9.9515654282019365e-03 -1.0186535017680890e-02 7.0490084717633062e-03 - 6 -6.3804753331014364e-05 1.1107780038266840e-03 4.6244242981496376e-04 - 7 -3.0142488152500502e-05 -5.6684692709220647e-04 -5.9335396255129238e-04 - 8 2.1070083677950853e-04 -5.2394803973737354e-04 6.1467530744658834e-04 - 9 3.6195183545487957e-03 -8.3369682502568449e-03 -1.6601527132808564e-02 - 10 3.2079212235368499e-04 6.8314953697639453e-04 -1.4658709900665793e-04 - 11 -3.7785845503841000e-03 -6.5404736905947487e-03 -6.2889329470937156e-03 - 12 9.6291409057966675e-04 -6.5439203151497114e-04 -1.4918221706275553e-03 - 13 -1.3242589815117614e-03 1.6385138464187446e-03 -5.7720431286344945e-04 - 14 3.1480939042203069e-03 -7.0000358651570562e-03 2.4177974139595096e-03 - 15 -3.3454335023896100e-03 4.4058024755002902e-04 1.4883635219226482e-02 - 16 -1.7846013433072078e-04 -2.8806672944350740e-04 1.5882710120078808e-03 - 17 5.7176195253866985e-04 2.6935646129835840e-04 5.3688215217051862e-04 + 1 6.6645514337822221e-04 6.0192577730141302e-04 -3.7299030694254800e-04 + 2 4.4186462683745379e-03 -4.6840896920226343e-03 6.9463033422740798e-03 + 3 -8.2788283512656355e-04 1.6664323303816283e-03 -3.6067014934863556e-04 + 4 -2.3360131422093099e-03 -2.4652356574843341e-04 -6.7612095269435129e-03 + 5 -9.9515654282019347e-03 -1.0186535017680895e-02 7.0490084717633053e-03 + 6 -6.3804753331014364e-05 1.1107780038266837e-03 4.6244242981496387e-04 + 7 -3.0142488152500515e-05 -5.6684692709220636e-04 -5.9335396255129249e-04 + 8 2.1070083677950848e-04 -5.2394803973737354e-04 6.1467530744658834e-04 + 9 3.6195183545487952e-03 -8.3369682502568449e-03 -1.6601527132808564e-02 + 10 3.2079212235368532e-04 6.8314953697639464e-04 -1.4658709900665799e-04 + 11 -3.7785845503840996e-03 -6.5404736905947487e-03 -6.2889329470937165e-03 + 12 9.6291409057966740e-04 -6.5439203151497081e-04 -1.4918221706275551e-03 + 13 -1.3242589815117630e-03 1.6385138464187414e-03 -5.7720431286344674e-04 + 14 3.1480939042203030e-03 -7.0000358651570562e-03 2.4177974139595096e-03 + 15 -3.3454335023896131e-03 4.4058024755002799e-04 1.4883635219226489e-02 + 16 -1.7846013433072094e-04 -2.8806672944350730e-04 1.5882710120078808e-03 + 17 5.7176195253866985e-04 2.6935646129835835e-04 5.3688215217051862e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-npt_sphere_iso.yaml b/unittest/force-styles/tests/fix-timestep-npt_sphere_iso.yaml index 4af29dd4d2..8632b803f0 100644 --- a/unittest/force-styles/tests/fix-timestep-npt_sphere_iso.yaml +++ b/unittest/force-styles/tests/fix-timestep-npt_sphere_iso.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 14:07:35 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 2e-13 skip_tests: prerequisites: ! | @@ -16,9 +16,9 @@ post_commands: ! | fix test solute npt/sphere temp 50.0 ${t_target} 1.0 iso 1.0 1.0 100.0 dilate solute input_file: in.dipole natoms: 29 -global_scalar: 9.042301471806704 +global_scalar: 9.042301471806708 global_vector: ! |- - 28 0.18636415542051687 1.4201480914539844 -1.1292034459301248 0.09086316406911908 1.9990627120668838 0.47615124832482836 -0.006387790127403963 -0.00558070983166458 0.0010748001531976797 -0.00023261555228169703 -0.00023292456865841747 0.0020841825580977056 -0.00023513173250148996 -0.00023642170879896256 6.33288408078452 0.28221278023295704 -0.22439606534154316 0.14027648316892297 0.3970689103168122 0.02252697627211299 -0.000934258230287154 2.0887944455121046 0.00021358500655954555 -4.6225518401838857e-05 -4.628692634326172e-05 0.0032370232941587745 4.1199960358459955e-05 4.165326165323854e-05 + 28 0.1863641554205169 1.420148091453985 -1.1292034459301246 0.09086316406911916 1.9990627120668834 0.47615124832482786 -0.006387790127403963 -0.00558070983166458 0.0010748001531976797 -0.00023261555228169703 -0.00023292456865841747 0.0020841825580977056 -0.00023513173250148996 -0.00023642170879896256 6.332884080784521 0.28221278023295715 -0.2243960653415431 0.14027648316892322 0.39706891031681196 0.02252697627211294 -0.000934258230287154 2.0887944455121046 0.00021358500655954555 -4.6225518401838857e-05 -4.628692634326172e-05 0.0032370232941587745 4.1199960358459955e-05 4.165326165323854e-05 run_pos: ! |2 1 -2.6730556919536941e-01 2.4568877649772691e+00 -1.7525449543283766e-01 2 3.1651774679036304e-01 2.9312403511996870e+00 -8.4441875599840355e-01 @@ -50,22 +50,22 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 6.7245251088027865e-04 6.1138248355858786e-04 -3.7339702570044316e-04 - 2 4.4052559672891761e-03 -4.6696302057353334e-03 6.9799826311338995e-03 - 3 -8.4229974223012048e-04 1.6692222625580451e-03 -3.4811445486190162e-04 - 4 -2.3115850080186913e-03 -2.1921753106846686e-04 -6.6129202326324832e-03 - 5 -9.9270913083732166e-03 -1.0162835960427118e-02 6.6835450876805242e-03 - 6 -6.3349132255598122e-05 1.1213920888471765e-03 4.3957112467583707e-04 + 1 6.7245251088027887e-04 6.1138248355858786e-04 -3.7339702570044338e-04 + 2 4.4052559672891761e-03 -4.6696302057353299e-03 6.9799826311339004e-03 + 3 -8.4229974223012048e-04 1.6692222625580460e-03 -3.4811445486190135e-04 + 4 -2.3115850080186896e-03 -2.1921753106846976e-04 -6.6129202326324875e-03 + 5 -9.9270913083732166e-03 -1.0162835960427124e-02 6.6835450876805242e-03 + 6 -6.3349132255598176e-05 1.1213920888471765e-03 4.3957112467583707e-04 7 -3.0550264536359436e-05 -5.7212395421602175e-04 -5.7852611868756802e-04 - 8 2.1230260290084165e-04 -5.2946150247993511e-04 6.1002092957609434e-04 + 8 2.1230260290084160e-04 -5.2946150247993511e-04 6.1002092957609434e-04 9 3.5835237205891044e-03 -8.2976423766382163e-03 -1.6569654205811610e-02 - 10 3.2215400971380426e-04 6.7777051599916360e-04 -1.4690970683667580e-04 + 10 3.2215400971380464e-04 6.7777051599916360e-04 -1.4690970683667591e-04 11 -3.8262569070299369e-03 -6.4899437483942309e-03 -6.0625717608142051e-03 - 12 9.6903366708958464e-04 -6.5830810892723965e-04 -1.4851103246954730e-03 - 13 -1.3051803182304376e-03 1.5782109043276473e-03 -5.7359190198993340e-04 - 14 3.1570944675627780e-03 -6.9925437658747572e-03 2.5670995049832728e-03 - 15 -3.3107454411357711e-03 5.6059336622465798e-04 1.4845717250576752e-02 - 16 -1.8030723242303480e-04 -2.9205235801445944e-04 1.5828900167446096e-03 + 12 9.6903366708958486e-04 -6.5830810892723922e-04 -1.4851103246954738e-03 + 13 -1.3051803182304389e-03 1.5782109043276430e-03 -5.7359190198993059e-04 + 14 3.1570944675627741e-03 -6.9925437658747589e-03 2.5670995049832746e-03 + 15 -3.3107454411357724e-03 5.6059336622465679e-04 1.4845717250576757e-02 + 16 -1.8030723242303502e-04 -2.9205235801445917e-04 1.5828900167446096e-03 17 5.7535428047488272e-04 2.7096053960059093e-04 5.2484092395923122e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 diff --git a/unittest/force-styles/tests/fix-timestep-npt_sphere_tri.yaml b/unittest/force-styles/tests/fix-timestep-npt_sphere_tri.yaml index 204f09bdbf..66f3aca713 100644 --- a/unittest/force-styles/tests/fix-timestep-npt_sphere_tri.yaml +++ b/unittest/force-styles/tests/fix-timestep-npt_sphere_tri.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 14:15:09 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 1e-12 skip_tests: prerequisites: ! | @@ -19,55 +19,55 @@ input_file: in.dipole natoms: 29 global_scalar: 12.427074202242965 global_vector: ! |- - 48 0.18732599278123144 1.4327704185774879 -1.114350363106168 0.09281449313807318 2.0096876527033785 0.5168928407675009 -0.00258727803156183 0.0016072198861910659 -0.017515031066905426 -0.0006359696254764614 0.003684960047314246 0.0014630140342537605 -0.0021206674795814034 0.0015249288501334088 -0.014917163613204729 -0.0004705411201213485 0.003272044118682347 0.0012260895045759764 0.0021598960215781717 -0.0002313961526710642 -0.00023292466339283792 0.004804856034402303 -0.0002297564102730591 -0.00023642225051889441 6.365568501757152 0.2847210975358988 -0.22144445077120098 0.14636618463898685 0.4013009387004219 0.026546916334714173 -0.0003006594610783624 -0.0003006594610783624 -0.0003006594610783624 0 0 0 0.10054042535473215 0.051986996480227275 4.974713468580724 0.004949835079328575 0.23935023979298692 0.033607786910456634 0.00042921598453834873 -4.5983198494216164e-05 -4.628694516894922e-05 0.017204223259431568 3.9337756237346446e-05 4.1653452536114995e-05 + 48 0.18732599278123133 1.4327704185774883 -1.1143503631061675 0.09281449313807297 2.0096876527033753 0.5168928407674991 -0.0025872780315617993 0.0016072198861910548 -0.017515031066905436 -0.0006359696254764761 0.003684960047314241 0.00146301403425373 -0.0021206674795813452 0.001524928850133378 -0.014917163613204762 -0.0004705411201213999 0.003272044118682296 0.001226089504575895 0.0021598960215781725 -0.0002313961526710642 -0.00023292466339283792 0.0048048560344023045 -0.0002297564102730591 -0.00023642225051889441 6.365568501757148 0.2847210975358989 -0.22144445077120087 0.1463661846389862 0.40130093870042066 0.02654691633471399 -0.0003006594610783624 -0.0003006594610783624 -0.0003006594610783624 0 0 0 0.10054042535472664 0.05198699648022517 4.974713468580746 0.004949835079329656 0.2393502397929795 0.03360778691045218 0.0004292159845383489 -4.5983198494216164e-05 -4.628694516894922e-05 0.01720422325943158 3.9337756237346446e-05 4.1653452536114995e-05 run_pos: ! |2 1 -2.3019540006487116e-01 2.4731491152481908e+00 -1.7981254448987816e-01 - 2 3.5408091994147828e-01 2.9517458018683023e+00 -8.4154317667398715e-01 - 3 -6.5053832938525158e-01 1.2449512560553124e+00 -6.2241599186766017e-01 - 4 -1.5342078390356910e+00 1.4884208596718249e+00 -1.2480276360391489e+00 - 5 -8.5668136613463908e-01 9.2234546360780989e-01 3.9231452398524702e-01 - 6 3.3322113863941816e-01 2.2597463982145172e-01 -1.2709694160975076e+00 - 7 3.7475098107547922e-01 -1.3724988393778226e-02 -2.4320792823935395e+00 - 8 1.2031137603847428e+00 -4.9024585938175047e-01 -6.7426808576801633e-01 + 2 3.5408091994147828e-01 2.9517458018682987e+00 -8.4154317667398715e-01 + 3 -6.5053832938524980e-01 1.2449512560553124e+00 -6.2241599186766017e-01 + 4 -1.5342078390356919e+00 1.4884208596718214e+00 -1.2480276360391489e+00 + 5 -8.5668136613463730e-01 9.2234546360780989e-01 3.9231452398524702e-01 + 6 3.3322113863941460e-01 2.2597463982144994e-01 -1.2709694160975076e+00 + 7 3.7475098107547833e-01 -1.3724988393778226e-02 -2.4320792823935395e+00 + 8 1.2031137603847464e+00 -4.9024585938175047e-01 -6.7426808576801633e-01 9 1.4241784975508018e+00 -2.7021689756584077e-01 2.3803620252476776e-01 - 10 2.0530428396862863e+00 -1.4336868349895742e+00 -9.6110246210374406e-01 + 10 2.0530428396862863e+00 -1.4336868349895733e+00 -9.6110246210374406e-01 11 1.8188729850824128e+00 -2.0021830794840838e+00 -1.8707494276865724e+00 - 12 3.0352703768848617e+00 -4.9511047953296927e-01 -1.6037322028476977e+00 - 13 4.0741331374345862e+00 -9.0138890701479291e-01 -1.6215524267381634e+00 + 12 3.0352703768848599e+00 -4.9511047953297194e-01 -1.6037322028476977e+00 + 13 4.0741331374345844e+00 -9.0138890701479379e-01 -1.6215524267381634e+00 14 2.6340159931331169e+00 -4.2299939057361513e-01 -2.6207532717282440e+00 15 3.0012113993627043e+00 5.5766796064899893e-01 -1.2140224834055351e+00 - 16 2.6858185719984924e+00 -2.4051713466577018e+00 2.5220211520086799e-02 - 17 2.2721660250726234e+00 -2.1105589725251424e+00 1.1204022912329368e+00 - 18 2.1691096725020014e+00 3.0200034523915207e+00 -3.4652251395628202e+00 - 19 1.5638692354297250e+00 2.6337150067951516e+00 -4.1837327833568496e+00 + 16 2.6858185719984888e+00 -2.4051713466577018e+00 2.5220211520086799e-02 + 17 2.2721660250726270e+00 -2.1105589725251424e+00 1.1204022912329368e+00 + 18 2.1691096725020067e+00 3.0200034523915207e+00 -3.4652251395628202e+00 + 19 1.5638692354297206e+00 2.6337150067951516e+00 -4.1837327833568496e+00 20 2.7925636956819009e+00 3.6869563744341303e+00 -3.8799004126527885e+00 - 21 4.9191678730049482e+00 -4.0841855614113536e+00 -3.5688686765499709e+00 - 22 4.3795875951964049e+00 -4.2141688660389169e+00 -4.3978133092346745e+00 - 23 5.7478464814125925e+00 -3.5844338072573851e+00 -3.8248183325717333e+00 + 21 4.9191678730049482e+00 -4.0841855614113509e+00 -3.5688686765499709e+00 + 22 4.3795875951964014e+00 -4.2141688660389169e+00 -4.3978133092346745e+00 + 23 5.7478464814125978e+00 -3.5844338072573851e+00 -3.8248183325717333e+00 24 2.1237696561245585e+00 3.1501013360303496e+00 3.0904476168033845e+00 - 25 1.3550047845470798e+00 3.2744376408481486e+00 2.4555407382440482e+00 - 26 2.6362472864936741e+00 4.0116438051188350e+00 3.1473576257765501e+00 - 27 -1.9103797042670241e+00 -4.3687665159467368e+00 2.0633187830108284e+00 - 28 -2.6890947459520786e+00 -4.0329898501364472e+00 1.5451958805107964e+00 - 29 -1.2598435219755979e+00 -3.6113182514368392e+00 2.2184764640185506e+00 + 25 1.3550047845470763e+00 3.2744376408481468e+00 2.4555407382440482e+00 + 26 2.6362472864936795e+00 4.0116438051188350e+00 3.1473576257765501e+00 + 27 -1.9103797042670241e+00 -4.3687665159467350e+00 2.0633187830108284e+00 + 28 -2.6890947459520760e+00 -4.0329898501364472e+00 1.5451958805107964e+00 + 29 -1.2598435219755979e+00 -3.6113182514368400e+00 2.2184764640185506e+00 run_vel: ! |2 - 1 6.6502876613817082e-04 6.0137715630290980e-04 -3.7231857614918843e-04 - 2 4.4310732749849807e-03 -4.6860518880721177e-03 6.9172213803384546e-03 - 3 -8.2879932936262243e-04 1.6675520063217351e-03 -3.6230664453296304e-04 - 4 -2.3009589595040800e-03 -2.4940767601862660e-04 -6.7114948439266726e-03 - 5 -9.9666600062292155e-03 -1.0192454842315551e-02 7.0756875873893990e-03 - 6 -6.6466948691939917e-05 1.1100485529839292e-03 4.6221787716926307e-04 - 7 -2.6664287463237775e-05 -5.6727672702013357e-04 -5.9340251907992480e-04 - 8 2.1069461419280906e-04 -5.2276533772721134e-04 6.1543942080566686e-04 - 9 3.5880864338549735e-03 -8.3291497817817063e-03 -1.6629312246477155e-02 - 10 3.2193494737598778e-04 6.8203760452628442e-04 -1.4590168253026390e-04 - 11 -3.7645937681506135e-03 -6.5457646086291817e-03 -6.2933396080559123e-03 - 12 9.6775971858663302e-04 -6.5412431179954719e-04 -1.4911729864314899e-03 - 13 -1.3236241180578610e-03 1.6172374806127389e-03 -6.1192476666209494e-04 - 14 3.1820466835757177e-03 -7.0137200098607851e-03 2.4247294180746613e-03 - 15 -3.3775929249580004e-03 4.3714311542648139e-04 1.4901523418484797e-02 - 16 -1.8137388689900202e-04 -2.8790510242829407e-04 1.5850222165835173e-03 - 17 5.6799086787378021e-04 2.7020817344844677e-04 5.3751629851417229e-04 + 1 6.6502876613817082e-04 6.0137715630290990e-04 -3.7231857614918870e-04 + 2 4.4310732749849834e-03 -4.6860518880721125e-03 6.9172213803384598e-03 + 3 -8.2879932936262470e-04 1.6675520063217355e-03 -3.6230664453296249e-04 + 4 -2.3009589595040579e-03 -2.4940767601862654e-04 -6.7114948439266622e-03 + 5 -9.9666600062292034e-03 -1.0192454842315554e-02 7.0756875873893878e-03 + 6 -6.6466948691936705e-05 1.1100485529839253e-03 4.6221787716926475e-04 + 7 -2.6664287463238046e-05 -5.6727672702013335e-04 -5.9340251907992480e-04 + 8 2.1069461419280237e-04 -5.2276533772720711e-04 6.1543942080566469e-04 + 9 3.5880864338550958e-03 -8.3291497817817185e-03 -1.6629312246477103e-02 + 10 3.2193494737599299e-04 6.8203760452628106e-04 -1.4590168253026371e-04 + 11 -3.7645937681506248e-03 -6.5457646086291748e-03 -6.2933396080559157e-03 + 12 9.6775971858663215e-04 -6.5412431179954632e-04 -1.4911729864314906e-03 + 13 -1.3236241180578574e-03 1.6172374806127285e-03 -6.1192476666208843e-04 + 14 3.1820466835757160e-03 -7.0137200098607964e-03 2.4247294180746626e-03 + 15 -3.3775929249580030e-03 4.3714311542646252e-04 1.4901523418484804e-02 + 16 -1.8137388689900037e-04 -2.8790510242829455e-04 1.5850222165835152e-03 + 17 5.6799086787377967e-04 2.7020817344844704e-04 5.3751629851417294e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-npt_tri.yaml b/unittest/force-styles/tests/fix-timestep-npt_tri.yaml index c2a4da9695..4d61eebe27 100644 --- a/unittest/force-styles/tests/fix-timestep-npt_tri.yaml +++ b/unittest/force-styles/tests/fix-timestep-npt_tri.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full fix npt @@ -11,57 +12,57 @@ post_commands: ! | fix test solute npt temp 50.0 ${t_target} 1.0 tri 1.0 1.0 100.0 nreset 2 input_file: in.fourmol natoms: 29 -global_scalar: 354.174797856098 +global_scalar: 354.17479785609765 global_vector: ! |- - 48 1.3901404465408471 5.463126417846173 27.522868094744837 0.6808509272696268 1.432899560678195 24.73621155835892 0.059175794171946315 0.058864829843401814 0.12700748296200176 0.02134537927441898 -0.006866713927713234 -0.03517153788806217 0.03214843910942283 0.03135716661218002 0.05847613666451851 0.010015733944968137 -0.004026286211139594 -0.020364872327366976 0.32458573874717506 0.03420953094338522 0.00010301961702814269 0.40071682483624077 0.09021935542363528 0.0016272628807846479 23.20496983817849 1.0856361420490914 5.469362788109317 3.86897924261614 0.20400675418492722 60.79661790199697 0.004555933286932949 0.004555933286932949 0.004555933286932949 0 0 0 23.105498800354294 21.982100664555755 76.44567329133054 2.242648057096569 0.36241390540377744 9.27169098501188 0.06450189547628359 0.006798140909455242 2.0472127318975922e-05 119.66012864844495 6.065599766319885 0.0019732846899264155 + 48 1.3901404465408473 5.463126417846174 27.522868094744837 0.6808509272696283 1.4328995606781998 24.736211558358928 0.05917579417194633 0.058864829843401786 0.12700748296200173 0.02134537927441893 -0.006866713927713233 -0.0351715378880622 0.03214843910942284 0.031357166612180014 0.058476136664518466 0.01001573394496806 -0.004026286211139567 -0.02036487232736701 0.32458573874717506 0.03420953094338522 0.00010301961702814269 0.4007168248362407 0.09021935542363528 0.0016272628807846479 23.204969838178492 1.0856361420490914 5.469362788109317 3.8689792426161564 0.20400675418492864 60.796617901997 0.004555933286932949 0.004555933286932949 0.004555933286932949 0 0 0 23.105498800354304 21.982100664555748 76.44567329133042 2.242648057096534 0.3624139054037726 9.27169098501191 0.06450189547628359 0.006798140909455242 2.0472127318975922e-05 119.66012864844491 6.065599766319885 0.0019732846899264155 run_pos: ! |2 - 1 -8.2271095985417642e-01 2.8289040859356991e+00 -1.1444756137720979e-01 - 2 -2.2035635832079414e-01 3.3160751622563218e+00 -8.8905665482321261e-01 - 3 -1.2238603220542110e+00 1.4989718911440786e+00 -6.2960577288309949e-01 - 4 -2.1611221536569811e+00 1.7480881759848010e+00 -1.3403837766858420e+00 - 5 -1.4356691651007525e+00 1.1969702774741524e+00 5.3174391336542293e-01 - 6 -1.5108221335914251e-01 4.4052153861184706e-01 -1.3548809313045158e+00 - 7 -5.9343459000764653e-02 1.2678140836872487e-01 -2.7489180271273321e+00 - 8 8.2373588231584893e-01 -3.3113650682317708e-01 -6.6671329415243719e-01 - 9 1.0285358664778927e+00 -6.3178215420583328e-02 3.8810870422627808e-01 - 10 1.7789213377484181e+00 -1.3532218104220428e+00 -1.0278171354490055e+00 - 11 1.5477736014686165e+00 -1.9530744276614485e+00 -2.0605735545184318e+00 - 12 2.7783142187942573e+00 -3.5681522115235254e-01 -1.7618063829238526e+00 - 13 3.8999744941062673e+00 -7.8691757348410274e-01 -1.7815725217013947e+00 - 14 2.3605564873379432e+00 -3.0049710242015149e-01 -2.9379309538662390e+00 + 1 -8.2271095985417642e-01 2.8289040859356973e+00 -1.1444756137720979e-01 + 2 -2.2035635832079592e-01 3.3160751622563200e+00 -8.8905665482321261e-01 + 3 -1.2238603220542110e+00 1.4989718911440821e+00 -6.2960577288309949e-01 + 4 -2.1611221536569811e+00 1.7480881759848028e+00 -1.3403837766858420e+00 + 5 -1.4356691651007543e+00 1.1969702774741560e+00 5.3174391336542293e-01 + 6 -1.5108221335914163e-01 4.4052153861184529e-01 -1.3548809313045158e+00 + 7 -5.9343459000765542e-02 1.2678140836872309e-01 -2.7489180271273321e+00 + 8 8.2373588231584893e-01 -3.3113650682317619e-01 -6.6671329415243719e-01 + 9 1.0285358664778919e+00 -6.3178215420581552e-02 3.8810870422627808e-01 + 10 1.7789213377484181e+00 -1.3532218104220402e+00 -1.0278171354490055e+00 + 11 1.5477736014686165e+00 -1.9530744276614502e+00 -2.0605735545184318e+00 + 12 2.7783142187942538e+00 -3.5681522115234898e-01 -1.7618063829238526e+00 + 13 3.8999744941062673e+00 -7.8691757348410363e-01 -1.7815725217013947e+00 + 14 2.3605564873379414e+00 -3.0049710242014971e-01 -2.9379309538662390e+00 15 2.7016025982848415e+00 7.6160196277114700e-01 -1.3273631127257124e+00 - 16 2.4717220178567558e+00 -2.3468671157596894e+00 9.1129832810088018e-02 + 16 2.4717220178567541e+00 -2.3468671157597010e+00 9.1129832810088018e-02 17 1.9885567143510166e+00 -1.9964324174322527e+00 1.4061647002816908e+00 18 1.7437183504864624e+00 3.3191498740328864e+00 -3.9127655905861678e+00 - 19 1.1235512691983933e+00 2.8925305004060426e+00 -4.7429923420674971e+00 - 20 2.3860672377151531e+00 4.0152665693893148e+00 -4.3919177720148843e+00 + 19 1.1235512691983898e+00 2.8925305004060444e+00 -4.7429923420674971e+00 + 20 2.3860672377151513e+00 4.0152665693893166e+00 -4.3919177720148843e+00 21 4.9453770477508119e+00 -4.2062128928889155e+00 -4.0325244237288675e+00 22 4.3864597623851278e+00 -4.3641236143384550e+00 -4.9903597585314996e+00 - 23 5.8105852095737784e+00 -3.6832694508636497e+00 -4.3282711054755429e+00 - 24 1.6113221591166269e+00 3.6172003657621623e+00 3.6622337059457593e+00 - 25 7.9642706990481837e-01 3.7333401645409854e+00 2.9286066111857547e+00 - 26 2.1223957638352413e+00 4.5309037460235295e+00 3.7279925218535261e+00 + 23 5.8105852095737749e+00 -3.6832694508636479e+00 -4.3282711054755429e+00 + 24 1.6113221591166269e+00 3.6172003657621641e+00 3.6622337059457593e+00 + 25 7.9642706990481837e-01 3.7333401645409872e+00 2.9286066111857547e+00 + 26 2.1223957638352431e+00 4.5309037460235295e+00 3.7279925218535261e+00 27 -2.3762434607634804e+00 -4.3698568738308285e+00 2.4753989625747312e+00 - 28 -3.2113212683802930e+00 -4.0269614699099696e+00 1.8767143168008165e+00 - 29 -1.7154699038294128e+00 -3.5639796658377056e+00 2.6546817559911258e+00 + 28 -3.2113212683802930e+00 -4.0269614699099714e+00 1.8767143168008165e+00 + 29 -1.7154699038294092e+00 -3.5639796658377065e+00 2.6546817559911258e+00 run_vel: ! |2 - 1 3.4379305599169844e-03 4.4303982887116036e-03 -6.5575090200992549e-04 - 2 -1.1857500286034856e-03 -6.4830194142741920e-04 2.8991421024851778e-03 - 3 -2.1154260546112497e-03 -3.3682136360151430e-03 -1.9294633718208677e-04 - 4 7.6092841426322790e-04 -3.2320184833153956e-03 2.7687800582063332e-03 - 5 -4.2732628342744957e-03 -4.1024661501998941e-03 -5.6627078010461117e-03 - 6 -1.0456549709936754e-02 1.1983105787743460e-02 3.6784105742361638e-03 - 7 -2.6132479696988121e-04 -1.3704375278698535e-03 -8.5781100824109287e-03 - 8 2.8751673617313503e-03 -1.2411443046752859e-03 1.1404387868407946e-02 - 9 -1.4768312187112003e-03 -7.1556281131933587e-05 -2.5861880084100675e-03 - 10 7.9726344243349050e-03 -7.6603150802256759e-03 -4.9260913574675621e-03 - 11 -1.3701886309654468e-03 5.8427841384912200e-04 3.5680693565126702e-03 - 12 3.8071638085887614e-04 -1.2274982267917827e-04 -1.6378029597235305e-03 - 13 -2.1573898217946193e-03 3.1719111017936398e-03 2.9806487190873061e-04 - 14 2.7537600422888457e-03 -1.6565936767524096e-03 3.7884151775862789e-03 - 15 5.5156122958171854e-04 -4.6689017429546913e-03 5.9598028358420622e-04 - 16 2.2455587308391760e-03 -9.7951134916580778e-04 -7.0867451131982279e-03 - 17 -1.7750442749204370e-03 1.3834451904214627e-03 5.2407088936868079e-03 + 1 3.4379305599169844e-03 4.4303982887116270e-03 -6.5575090200990728e-04 + 2 -1.1857500286034551e-03 -6.4830194142739058e-04 2.8991421024851497e-03 + 3 -2.1154260546112531e-03 -3.3682136360151903e-03 -1.9294633718209986e-04 + 4 7.6092841426323062e-04 -3.2320184833153952e-03 2.7687800582063262e-03 + 5 -4.2732628342744871e-03 -4.1024661501998898e-03 -5.6627078010461169e-03 + 6 -1.0456549709936855e-02 1.1983105787743550e-02 3.6784105742360984e-03 + 7 -2.6132479696987996e-04 -1.3704375278698546e-03 -8.5781100824109269e-03 + 8 2.8751673617314309e-03 -1.2411443046753629e-03 1.1404387868408002e-02 + 9 -1.4768312187112094e-03 -7.1556281131925103e-05 -2.5861880084100696e-03 + 10 7.9726344243349224e-03 -7.6603150802257306e-03 -4.9260913574675578e-03 + 11 -1.3701886309654427e-03 5.8427841384918423e-04 3.5680693565126932e-03 + 12 3.8071638085890357e-04 -1.2274982267928566e-04 -1.6378029597235398e-03 + 13 -2.1573898217946918e-03 3.1719111017937222e-03 2.9806487190874742e-04 + 14 2.7537600422888357e-03 -1.6565936767523506e-03 3.7884151775862832e-03 + 15 5.5156122958172852e-04 -4.6689017429545560e-03 5.9598028358422552e-04 + 16 2.2455587308391253e-03 -9.7951134916571844e-04 -7.0867451131981802e-03 + 17 -1.7750442749204121e-03 1.3834451904214348e-03 5.2407088936867593e-03 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-nve.yaml b/unittest/force-styles/tests/fix-timestep-nve.yaml index 09d1efe402..d4ef80962e 100644 --- a/unittest/force-styles/tests/fix-timestep-nve.yaml +++ b/unittest/force-styles/tests/fix-timestep-nve.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix nve @@ -11,7 +12,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_pos: ! |2 - 1 -2.7045559764772636e-01 2.4912159908661540e+00 -1.6695851750890131e-01 + 1 -2.7045559764772636e-01 2.4912159908661540e+00 -1.6695851750890134e-01 2 3.1004029572800829e-01 2.9612354631162883e+00 -8.5466363035055182e-01 3 -7.0398551409567367e-01 1.2305509955796761e+00 -6.2777526927691529e-01 4 -1.5818159336524433e+00 1.4837407818931854e+00 -1.2538710836034257e+00 @@ -41,23 +42,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 8.1705745750215355e-03 1.6516406624177568e-02 4.7902269490513868e-03 - 2 5.4501493264497653e-03 5.1791699524041815e-03 -1.4372931188098787e-03 - 3 -8.2298293869533436e-03 -1.2926551603583580e-02 -4.0984178763235155e-03 - 4 -3.7699042632974781e-03 -6.5722892095585973e-03 -1.1184640307556036e-03 - 5 -1.1021961013432620e-02 -9.8906780949598663e-03 -2.8410737767347810e-03 + 1 8.1705745750215355e-03 1.6516406624177568e-02 4.7902269490513816e-03 + 2 5.4501493264497653e-03 5.1791699524041859e-03 -1.4372931188098724e-03 + 3 -8.2298293869533471e-03 -1.2926551603583568e-02 -4.0984178763235103e-03 + 4 -3.7699042632974764e-03 -6.5722892095586034e-03 -1.1184640307556133e-03 + 5 -1.1021961013432616e-02 -9.8906780949598733e-03 -2.8410737767347836e-03 6 -3.9676663388061570e-02 4.6817061143308802e-02 3.7148492456495326e-02 7 9.1034010711748495e-04 -1.0128523385947431e-02 -5.1568251957150528e-02 - 8 7.9064711492041421e-03 -3.3507255912560113e-03 3.4557098774889522e-02 + 8 7.9064711492041403e-03 -3.3507255912560130e-03 3.4557098774889522e-02 9 1.5644176103896980e-03 3.7365546026078196e-03 1.5047408831488810e-02 - 10 2.9201446724707314e-02 -2.9249578666046938e-02 -1.5018077196173912e-02 + 10 2.9201446724707314e-02 -2.9249578666046938e-02 -1.5018077196173917e-02 11 -4.7835962161678980e-03 -3.7481384556453390e-03 -2.3464103658842415e-03 - 12 2.2696453478564904e-03 -3.4774151000032896e-04 -3.0640766808544008e-03 - 13 2.7531740679274997e-03 5.8171062119749114e-03 -7.9467451203005246e-04 - 14 3.5246182394862565e-03 -5.7939995493321060e-03 -3.9478430939281998e-03 - 15 -1.8547943547235282e-03 -5.8554729996935272e-03 6.2938485237843443e-03 + 12 2.2696453478564947e-03 -3.4774151000032500e-04 -3.0640766808544074e-03 + 13 2.7531740679274967e-03 5.8171062119749019e-03 -7.9467451203004726e-04 + 14 3.5246182394862522e-03 -5.7939995493321130e-03 -3.9478430939281980e-03 + 15 -1.8547943547235332e-03 -5.8554729996935298e-03 6.2938485237843487e-03 16 1.8681499891767241e-02 -1.3262466107722061e-02 -4.5638651214503466e-02 - 17 -1.2896270000483427e-02 9.7527665388161232e-03 3.7296535433762990e-02 + 17 -1.2896270000483427e-02 9.7527665388161214e-03 3.7296535433762990e-02 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-nve_limit.yaml b/unittest/force-styles/tests/fix-timestep-nve_limit.yaml index 1efd576e57..01c3d48c46 100644 --- a/unittest/force-styles/tests/fix-timestep-nve_limit.yaml +++ b/unittest/force-styles/tests/fix-timestep-nve_limit.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix nve/limit @@ -21,7 +22,7 @@ run_pos: ! |2 7 3.4131519586188186e-01 -2.1332927950157451e-02 -2.5226710871848397e+00 8 1.1745681001086989e+00 -4.8880555510768764e-01 -6.3767047336122595e-01 9 1.3800388768125751e+00 -2.5273044808068107e-01 2.8354022342291846e-01 - 10 2.0507159009620417e+00 -1.4600439328150543e+00 -9.8304531314454335e-01 + 10 2.0507159009620417e+00 -1.4600439328150543e+00 -9.8304531314454346e-01 11 1.7878036263333670e+00 -1.9921873120582470e+00 -1.8890597602487673e+00 12 3.0063008847742978e+00 -4.9013357181531525e-01 -1.6231896519255256e+00 13 4.0515402963264480e+00 -8.9202011521631330e-01 -1.6400005533730235e+00 @@ -42,23 +43,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 8.1732003057504062e-03 1.6514828420489739e-02 4.7872115825042917e-03 - 2 5.4501984055902123e-03 5.1793290501538332e-03 -1.4372006388551327e-03 - 3 -8.0610739455692880e-03 -1.3095521561394886e-02 -4.2266823695085408e-03 - 4 -3.7739182466966399e-03 -6.5640956178167256e-03 -1.1086873700633861e-03 - 5 -1.1014317623957239e-02 -9.8992879261119594e-03 -2.8426784786513113e-03 + 1 8.1732003057504079e-03 1.6514828420489739e-02 4.7872115825042883e-03 + 2 5.4501984055902123e-03 5.1793290501538410e-03 -1.4372006388551266e-03 + 3 -8.0610739455692897e-03 -1.3095521561394883e-02 -4.2266823695085338e-03 + 4 -3.7739182466966373e-03 -6.5640956178167334e-03 -1.1086873700633948e-03 + 5 -1.1014317623957232e-02 -9.8992879261119680e-03 -2.8426784786513121e-03 6 -2.2746202359584897e-02 2.6501461285527265e-02 1.9500841724102939e-02 7 7.1795466366918702e-04 -7.6899595133329566e-03 -3.9247280973135144e-02 - 8 8.5447554616147666e-03 -3.8712033854644231e-03 3.5042706956272054e-02 - 9 1.5218732877891332e-03 3.7909074575394179e-03 1.5051828340156633e-02 - 10 2.6568059693981929e-02 -2.6610736060597027e-02 -1.3638435775786530e-02 + 8 8.5447554616147666e-03 -3.8712033854644235e-03 3.5042706956272054e-02 + 9 1.5218732877891330e-03 3.7909074575394179e-03 1.5051828340156633e-02 + 10 2.6568059693981932e-02 -2.6610736060597023e-02 -1.3638435775786533e-02 11 -4.7814685417362354e-03 -3.7519869862352338e-03 -2.3422093312329933e-03 - 12 2.2701033959982354e-03 -3.4790952380024665e-04 -3.0630012321413635e-03 - 13 2.7530737198003781e-03 5.8168334149720693e-03 -7.9452451180343049e-04 - 14 3.5246400957674416e-03 -5.7940527015023580e-03 -3.9478518870560801e-03 - 15 -1.8545510957970676e-03 -5.8553785322346154e-03 6.2936138897817578e-03 - 16 1.4662001099180024e-02 -1.0397429516967713e-02 -3.5734005977602519e-02 - 17 -1.2697780981636615e-02 9.5993773334601788e-03 3.6696298354905482e-02 + 12 2.2701033959982393e-03 -3.4790952380024274e-04 -3.0630012321413696e-03 + 13 2.7530737198003755e-03 5.8168334149720615e-03 -7.9452451180342528e-04 + 14 3.5246400957674364e-03 -5.7940527015023641e-03 -3.9478518870560775e-03 + 15 -1.8545510957970737e-03 -5.8553785322346206e-03 6.2936138897817682e-03 + 16 1.4662001099180023e-02 -1.0397429516967715e-02 -3.5734005977602519e-02 + 17 -1.2697780981636615e-02 9.5993773334601771e-03 3.6696298354905482e-02 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-nve_sphere.yaml b/unittest/force-styles/tests/fix-timestep-nve_sphere.yaml index 1fe8a812eb..4b815ef384 100644 --- a/unittest/force-styles/tests/fix-timestep-nve_sphere.yaml +++ b/unittest/force-styles/tests/fix-timestep-nve_sphere.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 12:41:14 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 5e-14 skip_tests: prerequisites: ! | @@ -47,23 +47,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 8.0441098013536900e-04 7.1566696890217009e-04 -4.3319530641127324e-04 - 2 4.9019924927833974e-03 -4.7801485992371370e-03 8.0763763167138476e-03 - 3 -1.0296827041707426e-03 1.9681821177098759e-03 -4.0661362502986804e-04 - 4 -2.4750904667702697e-03 -4.0142184848872032e-04 -7.4645414457473590e-03 - 5 -1.0920223377262468e-02 -1.0990650916587269e-02 7.1259821326181468e-03 - 6 -9.5250936177773552e-05 1.3338845867289183e-03 5.4216231888479466e-04 + 1 8.0441098013536900e-04 7.1566696890217009e-04 -4.3319530641127335e-04 + 2 4.9019924927833974e-03 -4.7801485992371362e-03 8.0763763167138545e-03 + 3 -1.0296827041707426e-03 1.9681821177098759e-03 -4.0661362502986771e-04 + 4 -2.4750904667702675e-03 -4.0142184848872351e-04 -7.4645414457473643e-03 + 5 -1.0920223377262466e-02 -1.0990650916587272e-02 7.1259821326181468e-03 + 6 -9.5250936177773566e-05 1.3338845867289183e-03 5.4216231888479466e-04 7 -4.3622272484028061e-05 -6.9095838256533388e-04 -6.9347553685684493e-04 - 8 2.6770309186413690e-04 -6.5039173203211467e-04 6.8080720281545992e-04 + 8 2.6770309186413674e-04 -6.5039173203211488e-04 6.8080720281545992e-04 9 3.9551108074098729e-03 -9.3129436730056761e-03 -1.8150317067617373e-02 - 10 3.9268045122209340e-04 7.8613414593941687e-04 -1.8443604077645874e-04 + 10 3.9268045122209367e-04 7.8613414593941687e-04 -1.8443604077645880e-04 11 -4.1884490183000996e-03 -7.1206276521598860e-03 -6.7115880881258904e-03 - 12 1.1515461519926514e-03 -7.7600056283407166e-04 -1.7352241098650576e-03 - 13 -1.2037022170798477e-03 2.1033375439546342e-03 -6.8928778601845260e-04 - 14 3.5046339401241938e-03 -8.0020522800663806e-03 2.6034033369112244e-03 - 15 -3.9825896439104544e-03 1.5687388979248470e-04 1.6410860063121452e-02 - 16 -2.1359275515571647e-04 -3.5441416299211270e-04 1.8682699034667436e-03 - 17 6.8808524051577229e-04 3.2653076879221409e-04 6.4078607994587291e-04 + 12 1.1515461519926520e-03 -7.7600056283407145e-04 -1.7352241098650581e-03 + 13 -1.2037022170798494e-03 2.1033375439546294e-03 -6.8928778601844956e-04 + 14 3.5046339401241904e-03 -8.0020522800663824e-03 2.6034033369112244e-03 + 15 -3.9825896439104579e-03 1.5687388979248248e-04 1.6410860063121452e-02 + 16 -2.1359275515571666e-04 -3.5441416299211248e-04 1.8682699034667436e-03 + 17 6.8808524051577229e-04 3.2653076879221409e-04 6.4078607994587312e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-nve_sphere_dipole.yaml b/unittest/force-styles/tests/fix-timestep-nve_sphere_dipole.yaml index 7cfd558fc6..af28b5ee60 100644 --- a/unittest/force-styles/tests/fix-timestep-nve_sphere_dipole.yaml +++ b/unittest/force-styles/tests/fix-timestep-nve_sphere_dipole.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 12:43:06 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 5e-14 skip_tests: prerequisites: ! | @@ -47,22 +47,22 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 8.0473659311712108e-04 7.1569249347906304e-04 -4.3342870018006228e-04 - 2 4.8898479203602872e-03 -4.7827042023383688e-03 8.0841799193837570e-03 - 3 -1.0294756367549977e-03 1.9683076071813901e-03 -4.0617066185945041e-04 - 4 -2.4747982635460672e-03 -4.0369263662479052e-04 -7.4617063284330544e-03 - 5 -1.0926646593906211e-02 -1.0990152085046804e-02 7.1139929395277867e-03 - 6 -9.5067271206254357e-05 1.3336935657649613e-03 5.4214461928120254e-04 + 1 8.0473659311712108e-04 7.1569249347906293e-04 -4.3342870018006266e-04 + 2 4.8898479203602872e-03 -4.7827042023383653e-03 8.0841799193837622e-03 + 3 -1.0294756367549977e-03 1.9683076071813905e-03 -4.0617066185945003e-04 + 4 -2.4747982635460650e-03 -4.0369263662479350e-04 -7.4617063284330562e-03 + 5 -1.0926646593906205e-02 -1.0990152085046808e-02 7.1139929395277850e-03 + 6 -9.5067271206254411e-05 1.3336935657649609e-03 5.4214461928120254e-04 7 -4.3586025236289389e-05 -6.9109610170650215e-04 -6.9337762329437880e-04 8 2.6803899143798955e-04 -6.5040541267279931e-04 6.8116655292381478e-04 9 3.9386905614672216e-03 -9.3112400668916677e-03 -1.8163977072531323e-02 - 10 3.9247060772836694e-04 7.8592522562680438e-04 -1.8488118631442108e-04 + 10 3.9247060772836721e-04 7.8592522562680449e-04 -1.8488118631442108e-04 11 -4.1794652638823824e-03 -7.0974426331113054e-03 -6.7076698172827591e-03 - 12 1.1514884390152254e-03 -7.7558890534918008e-04 -1.7352975395072082e-03 - 13 -1.2091918935275513e-03 2.1057712474429301e-03 -6.8173220473209369e-04 - 14 3.4935556917242987e-03 -8.0116807211232811e-03 2.6013722731623311e-03 - 15 -3.9745580146274316e-03 1.4335430630176018e-04 1.6407163363653991e-02 - 16 -2.1348158583193162e-04 -3.5449321712298289e-04 1.8683099741508020e-03 + 12 1.1514884390152259e-03 -7.7558890534917975e-04 -1.7352975395072093e-03 + 13 -1.2091918935275532e-03 2.1057712474429279e-03 -6.8173220473209044e-04 + 14 3.4935556917242974e-03 -8.0116807211232828e-03 2.6013722731623324e-03 + 15 -3.9745580146274334e-03 1.4335430630175937e-04 1.6407163363653991e-02 + 16 -2.1348158583193186e-04 -3.5449321712298289e-04 1.8683099741508020e-03 17 6.8803503268433628e-04 3.2662083176268592e-04 6.4072364607846313e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 diff --git a/unittest/force-styles/tests/fix-timestep-nve_sphere_dipole_dlm.yaml b/unittest/force-styles/tests/fix-timestep-nve_sphere_dipole_dlm.yaml index 1ce4c2874d..e259476ef3 100644 --- a/unittest/force-styles/tests/fix-timestep-nve_sphere_dipole_dlm.yaml +++ b/unittest/force-styles/tests/fix-timestep-nve_sphere_dipole_dlm.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 12:43:20 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 5e-14 skip_tests: prerequisites: ! | @@ -47,23 +47,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 8.0473659314045311e-04 7.1569249348053799e-04 -4.3342870019477203e-04 - 2 4.8898479194970758e-03 -4.7827042025493354e-03 8.0841799198950962e-03 - 3 -1.0294756367398522e-03 1.9683076071843977e-03 -4.0617066181897204e-04 - 4 -2.4747982635401470e-03 -4.0369263670034553e-04 -7.4617063284663802e-03 - 5 -1.0926646594371465e-02 -1.0990152084938037e-02 7.1139929386532276e-03 - 6 -9.5067271190104420e-05 1.3336935657507988e-03 5.4214461927831791e-04 + 1 8.0473659314045311e-04 7.1569249348053788e-04 -4.3342870019477209e-04 + 2 4.8898479194970776e-03 -4.7827042025493328e-03 8.0841799198950980e-03 + 3 -1.0294756367398522e-03 1.9683076071843977e-03 -4.0617066181897172e-04 + 4 -2.4747982635401457e-03 -4.0369263670034846e-04 -7.4617063284663837e-03 + 5 -1.0926646594371462e-02 -1.0990152084938042e-02 7.1139929386532267e-03 + 6 -9.5067271190104528e-05 1.3336935657507986e-03 5.4214461927831791e-04 7 -4.3586025231105304e-05 -6.9109610172221191e-04 -6.9337762328493019e-04 8 2.6803899146373794e-04 -6.5040541267551654e-04 6.8116655294853557e-04 9 3.9386905601377338e-03 -9.3112400666159056e-03 -1.8163977073503805e-02 - 10 3.9247060769256279e-04 7.8592522559452823e-04 -1.8488118637534628e-04 + 10 3.9247060769256306e-04 7.8592522559452823e-04 -1.8488118637534633e-04 11 -4.1794652628278275e-03 -7.0974426301502243e-03 -6.7076698165187305e-03 - 12 1.1514884390163194e-03 -7.7558890532261485e-04 -1.7352975395074867e-03 - 13 -1.2091918941598313e-03 2.1057712476065032e-03 -6.8173220414898873e-04 - 14 3.4935556908446308e-03 -8.0116807223612942e-03 2.6013722730781601e-03 - 15 -3.9745580139864201e-03 1.4335430539960903e-04 1.6407163363297207e-02 - 16 -2.1348158581808034e-04 -3.5449321713051474e-04 1.8683099741583738e-03 - 17 6.8803503267879525e-04 3.2662083177018096e-04 6.4072364607216479e-04 + 12 1.1514884390163200e-03 -7.7558890532261431e-04 -1.7352975395074880e-03 + 13 -1.2091918941598333e-03 2.1057712476064984e-03 -6.8173220414898580e-04 + 14 3.4935556908446269e-03 -8.0116807223612977e-03 2.6013722730781614e-03 + 15 -3.9745580139864218e-03 1.4335430539960781e-04 1.6407163363297207e-02 + 16 -2.1348158581808053e-04 -3.5449321713051474e-04 1.8683099741583740e-03 + 17 6.8803503267879525e-04 3.2662083177018096e-04 6.4072364607216500e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-nvt.yaml b/unittest/force-styles/tests/fix-timestep-nvt.yaml index 500bb47c76..d1e832f84b 100644 --- a/unittest/force-styles/tests/fix-timestep-nvt.yaml +++ b/unittest/force-styles/tests/fix-timestep-nvt.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix nvt @@ -10,7 +11,7 @@ post_commands: ! | fix test solute nvt temp 50.0 ${t_target} 1.0 mtk no tchain 1 input_file: in.fourmol natoms: 29 -global_scalar: 161.082193606418 +global_scalar: 161.08219360641812 global_vector: ! |- 4 6.3653490700601365 4.587389017747112 60.7164687353389 100.36572487107922 run_pos: ! |2 @@ -27,7 +28,7 @@ run_pos: ! |2 11 1.7913946552248519e+00 -1.9888180233714230e+00 -1.8859590750369315e+00 12 3.0041472088806827e+00 -4.8958548297015908e-01 -1.6203323200317881e+00 13 4.0473595725538498e+00 -8.9804811680951135e-01 -1.6390213905369104e+00 - 14 2.6042857752267574e+00 -4.1148107203534806e-01 -2.6584020615701607e+00 + 14 2.6042857752267574e+00 -4.1148107203534812e-01 -2.6584020615701607e+00 15 2.9731795843276339e+00 5.6016006278471708e-01 -1.2404481641085223e+00 16 2.6589894088512205e+00 -2.4010363080271988e+00 1.5175729949308553e-02 17 2.2261096224365753e+00 -2.0982906145850206e+00 1.1642076197266931e+00 @@ -44,23 +45,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 7.8424070606032009e-04 1.6957423585177817e-03 5.3293987045553042e-04 - 2 2.8408938974665233e-04 6.3401186822596671e-05 -5.0702412121826309e-04 - 3 -7.1943682951293387e-04 -1.5812016081414803e-03 -4.2848459956300902e-04 - 4 -2.9398452847843030e-04 -5.5105638181201155e-04 3.0356108858991924e-04 - 5 -1.0153174695903785e-03 -1.0991397270447010e-03 -2.9745984673366986e-04 + 1 7.8424070606032030e-04 1.6957423585177813e-03 5.3293987045553010e-04 + 2 2.8408938974665244e-04 6.3401186822597389e-05 -5.0702412121826255e-04 + 3 -7.1943682951293409e-04 -1.5812016081414801e-03 -4.2848459956300848e-04 + 4 -2.9398452847842992e-04 -5.5105638181201231e-04 3.0356108858991843e-04 + 5 -1.0153174695903780e-03 -1.0991397270447016e-03 -2.9745984673366997e-04 6 -4.2616664324255076e-03 4.9166230021219599e-03 3.9281549764140266e-03 7 1.2690465637066298e-04 -1.0201658940305772e-03 -5.4345368878308906e-03 - 8 8.3338080594941018e-04 -2.8041016920393470e-04 3.6768915167210169e-03 + 8 8.3338080594941007e-04 -2.8041016920393481e-04 3.6768915167210169e-03 9 1.2557498735649483e-05 6.4724399795980240e-04 1.3767564856324000e-03 - 10 3.0640515606253464e-03 -3.1769374504099761e-03 -1.5482422096535847e-03 + 10 3.0640515606253473e-03 -3.1769374504099761e-03 -1.5482422096535847e-03 11 -4.5803506169263681e-04 -2.2647716135831678e-04 6.0288357252089534e-05 - 12 1.2114752302890638e-04 3.5392382149094706e-05 -1.8260516713062942e-04 - 13 -1.2777289076283452e-04 2.4386857088712753e-04 -2.2245290738142125e-06 - 14 3.7600485089664203e-04 -1.9387476208267205e-04 -1.5847965685025904e-05 - 15 2.5123165119885843e-04 -2.8708143347183168e-04 3.3015492480754400e-04 - 16 2.0107337298668473e-03 -1.3643226191731759e-03 -5.0826514203549545e-03 - 17 -1.4578784011733559e-03 1.0116087441418126e-03 3.9228519733530611e-03 + 12 1.2114752302890675e-04 3.5392382149095113e-05 -1.8260516713063002e-04 + 13 -1.2777289076283479e-04 2.4386857088712685e-04 -2.2245290738136458e-06 + 14 3.7600485089664144e-04 -1.9387476208267260e-04 -1.5847965685025684e-05 + 15 2.5123165119885789e-04 -2.8708143347183190e-04 3.3015492480754460e-04 + 16 2.0107337298668473e-03 -1.3643226191731757e-03 -5.0826514203549545e-03 + 17 -1.4578784011733559e-03 1.0116087441418124e-03 3.9228519733530611e-03 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-nvt_sphere.yaml b/unittest/force-styles/tests/fix-timestep-nvt_sphere.yaml index 475cca40dd..994da49410 100644 --- a/unittest/force-styles/tests/fix-timestep-nvt_sphere.yaml +++ b/unittest/force-styles/tests/fix-timestep-nvt_sphere.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 30 Jul 2021 -date_generated: Sun Aug 22 14:04:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 5e-14 skip_tests: prerequisites: ! | @@ -16,9 +16,9 @@ post_commands: ! | fix test solute nvt/sphere temp 50.0 ${t_target} 1.0 mtk no tchain 1 input_file: in.dipole natoms: 29 -global_scalar: 9.924697652139482 +global_scalar: 9.924697652139484 global_vector: ! |- - 4 0.43730807201701893 0.3665139279582142 8.603313153695396 1.321384498444087 + 4 0.437308072017019 0.3665139279582143 8.603313153695396 1.3213844984440877 run_pos: ! |2 1 -2.7857754700604942e-01 2.4737788516853181e+00 -1.7257396330013031e-01 2 3.0850115944710327e-01 2.9513142622511719e+00 -8.4681556480583575e-01 @@ -50,23 +50,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 5.2257770354932154e-04 4.7726828362807159e-04 -3.0522943208439779e-04 - 2 3.4303751874469003e-03 -4.2180945960503015e-03 5.7574961491201398e-03 - 3 -6.3573466121110811e-04 1.3140213521350944e-03 -2.7079367477976345e-04 - 4 -1.7843971684490102e-03 -1.5758975301724453e-04 -5.2242082857429815e-03 - 5 -8.2227072251703434e-03 -8.5099569970796176e-03 5.4461443188764114e-03 - 6 -3.5789209403806848e-05 8.6848093647978709e-04 3.1971012031399495e-04 - 7 -2.0124049923183828e-05 -4.3697732547062844e-04 -4.3839548145203488e-04 - 8 1.5805774595943576e-04 -4.0027425549530725e-04 5.0330078142215727e-04 - 9 2.8822403754462044e-03 -6.8160818050074937e-03 -1.4036982183720429e-02 - 10 2.4663804309963576e-04 5.4279437979848030e-04 -1.1317926570306191e-04 - 11 -3.1643374866053933e-03 -5.2717858128617659e-03 -4.7921591091986638e-03 - 12 7.5165507333444870e-04 -5.1625440836408566e-04 -1.1731908604625757e-03 - 13 -1.4118493310107778e-03 1.1905767851418953e-03 -4.3306400341166124e-04 - 14 2.7000698448074820e-03 -5.6421006571202859e-03 2.4657183892946815e-03 - 15 -2.5296352230596542e-03 4.9931947404907172e-04 1.2186033148767310e-02 - 16 -1.5201520334258555e-04 -2.1134042562761171e-04 1.2515192941693037e-03 - 17 4.4810518325242047e-04 2.0606663095337985e-04 3.9041801229218047e-04 + 1 5.2257770354932143e-04 4.7726828362807121e-04 -3.0522943208439774e-04 + 2 3.4303751874469003e-03 -4.2180945960502980e-03 5.7574961491201398e-03 + 3 -6.3573466121110811e-04 1.3140213521350942e-03 -2.7079367477976328e-04 + 4 -1.7843971684490083e-03 -1.5758975301724681e-04 -5.2242082857429824e-03 + 5 -8.2227072251703382e-03 -8.5099569970796211e-03 5.4461443188764105e-03 + 6 -3.5789209403806882e-05 8.6848093647978698e-04 3.1971012031399484e-04 + 7 -2.0124049923183825e-05 -4.3697732547062816e-04 -4.3839548145203471e-04 + 8 1.5805774595943574e-04 -4.0027425549530720e-04 5.0330078142215716e-04 + 9 2.8822403754462040e-03 -6.8160818050074920e-03 -1.4036982183720428e-02 + 10 2.4663804309963582e-04 5.4279437979848041e-04 -1.1317926570306191e-04 + 11 -3.1643374866053924e-03 -5.2717858128617642e-03 -4.7921591091986630e-03 + 12 7.5165507333444881e-04 -5.1625440836408545e-04 -1.1731908604625759e-03 + 13 -1.4118493310107784e-03 1.1905767851418925e-03 -4.3306400341165912e-04 + 14 2.7000698448074781e-03 -5.6421006571202893e-03 2.4657183892946829e-03 + 15 -2.5296352230596542e-03 4.9931947404907107e-04 1.2186033148767308e-02 + 16 -1.5201520334258572e-04 -2.1134042562761163e-04 1.2515192941693033e-03 + 17 4.4810518325242042e-04 2.0606663095337982e-04 3.9041801229218036e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-oneway.yaml b/unittest/force-styles/tests/fix-timestep-oneway.yaml index 654507882e..c592517d8e 100644 --- a/unittest/force-styles/tests/fix-timestep-oneway.yaml +++ b/unittest/force-styles/tests/fix-timestep-oneway.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full fix oneway @@ -43,33 +44,33 @@ run_pos: ! |2 28 -2.7473562684363926e+00 -4.0200819932238128e+00 1.5830052163318067e+00 29 -1.3126000191174594e+00 -3.5962518039167004e+00 2.2746342468404586e+00 run_vel: ! |2 - 1 8.1326174405685538e-03 1.6373582405067897e-02 4.8585182845455712e-03 - 2 5.8837270552731073e-03 -3.8462177816659640e-03 -1.8252141024960109e-03 - 3 -7.9399681860454797e-03 -1.3357358988237270e-02 -4.2730671715123869e-03 - 4 -3.7780113133276580e-03 -6.5743891894956162e-03 -1.1035572233443962e-03 - 5 -1.1085221038212844e-02 -9.8001947813787463e-03 -2.8273871920293852e-03 + 1 8.1326174405685573e-03 1.6373582405067897e-02 4.8585182845455677e-03 + 2 5.8837270552731073e-03 -3.8462177816659575e-03 -1.8252141024960047e-03 + 3 -7.9399681860454849e-03 -1.3357358988237261e-02 -4.2730671715123817e-03 + 4 -3.7780113133276537e-03 -6.5743891894956214e-03 -1.1035572233444046e-03 + 5 -1.1085221038212837e-02 -9.8001947813787568e-03 -2.8273871920293865e-03 6 -4.4609854497583340e-02 -9.7839249254203604e-05 3.6924991223868768e-02 7 1.0934231181106860e-03 -1.0089285632286154e-02 -5.3249469251759558e-02 - 8 1.1560535930914618e-02 -5.6066644056948153e-03 3.6822039089518199e-02 + 8 1.1560535930914618e-02 -5.6066644056948171e-03 3.6822039089518199e-02 9 1.4771202752655284e-03 -5.6592086266267754e-04 1.5171444723794314e-02 - 10 2.9271043168403336e-02 -2.9358480133029913e-02 -1.5005615223104311e-02 + 10 2.9271043168403340e-02 -2.9358480133029913e-02 -1.5005615223104311e-02 11 -4.7875281915863753e-03 -3.7453316510457036e-03 -2.3468300203430535e-03 - 12 2.2834176839311377e-03 -4.3515859810651467e-04 -3.0819324216779676e-03 - 13 2.6230282912195722e-03 -2.0881180762184043e-03 -7.5926690606763453e-04 - 14 3.5152226503095563e-03 -5.7947608006153036e-03 -3.9443660790893708e-03 - 15 -1.7252289081148742e-03 -5.8594002554889441e-03 6.3130243598528216e-03 - 16 1.8891310917764224e-02 -1.3304701477320883e-02 -4.6130643779722584e-02 - 17 -1.3044825131788665e-02 -1.0948885072697287e-04 3.7651903933941855e-02 - 18 -8.0065345596261577e-04 -8.6270011841448470e-04 -1.4483096327016056e-03 - 19 1.2452394264962181e-03 -2.5061092911310904e-03 7.2998623124420486e-03 - 20 3.5930061968237606e-03 3.6938862165703744e-03 3.2322730789814671e-03 - 21 -1.4689223169009637e-03 -2.7352105166082084e-04 7.0581656206526917e-04 - 22 -7.0694199349272012e-03 -4.2577148814134033e-03 2.8079119193959233e-04 - 23 6.0446962950641515e-03 -1.4000131542342578e-03 2.5819754985491735e-03 - 24 3.1926393975974753e-04 -9.9445602961140004e-04 1.5000082490018062e-04 - 25 1.3789760155372187e-04 -4.4335894098053909e-03 -8.1808118996691559e-04 - 26 2.0485904240939170e-03 2.7813358894480207e-03 4.3245727380701038e-03 - 27 4.5604203985628975e-04 -1.0305518414984829e-03 2.1188012356040164e-04 - 28 -6.2544520512869215e-03 1.4127711484694747e-03 -1.8429822119848576e-03 - 29 6.4110636043558319e-04 3.1273433469853644e-03 3.7253670393426058e-03 + 12 2.2834176839311420e-03 -4.3515859810651017e-04 -3.0819324216779733e-03 + 13 2.6230282912195688e-03 -2.0881180762184074e-03 -7.5926690606762932e-04 + 14 3.5152226503095498e-03 -5.7947608006153079e-03 -3.9443660790893708e-03 + 15 -1.7252289081148792e-03 -5.8594002554889476e-03 6.3130243598528294e-03 + 16 1.8891310917764220e-02 -1.3304701477320879e-02 -4.6130643779722584e-02 + 17 -1.3044825131788663e-02 -1.0948885072697235e-04 3.7651903933941855e-02 + 18 -8.0065345596261577e-04 -8.6270011841448415e-04 -1.4483096327016088e-03 + 19 1.2452394264962151e-03 -2.5061092911310952e-03 7.2998623124420564e-03 + 20 3.5930061968237636e-03 3.6938862165703753e-03 3.2322730789814728e-03 + 21 -1.4689223169009630e-03 -2.7352105166082003e-04 7.0581656206526657e-04 + 22 -7.0694199349272046e-03 -4.2577148814134051e-03 2.8079119193959450e-04 + 23 6.0446962950641524e-03 -1.4000131542342578e-03 2.5819754985491805e-03 + 24 3.1926393975974682e-04 -9.9445602961139765e-04 1.5000082490017926e-04 + 25 1.3789760155372079e-04 -4.4335894098053996e-03 -8.1808118996691461e-04 + 26 2.0485904240939209e-03 2.7813358894480185e-03 4.3245727380701055e-03 + 27 4.5604203985628942e-04 -1.0305518414984800e-03 2.1188012356040075e-04 + 28 -6.2544520512869250e-03 1.4127711484694684e-03 -1.8429822119848574e-03 + 29 6.4110636043558720e-04 3.1273433469853605e-03 3.7253670393426097e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-planeforce.yaml b/unittest/force-styles/tests/fix-timestep-planeforce.yaml index ba1b93f9f2..05f20d6009 100644 --- a/unittest/force-styles/tests/fix-timestep-planeforce.yaml +++ b/unittest/force-styles/tests/fix-timestep-planeforce.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full fix planeforce @@ -42,33 +43,33 @@ run_pos: ! |2 28 -2.7473562684343000e+00 -4.0200819932242773e+00 1.5830052163335984e+00 29 -1.3126000190933165e+00 -3.5962518038945435e+00 2.2746342468225560e+00 run_vel: ! |2 - 1 1.2684230994165607e-02 1.2495256261514619e-02 4.9930344501754736e-03 - 2 4.3518220414975614e-03 6.2675117562013419e-03 -1.5418810814943006e-03 - 3 -1.2234130921634355e-02 -9.3495843960724277e-03 -4.6324540534036238e-03 - 4 -5.0386193262248391e-03 -5.3641219069569283e-03 -1.1886832268516150e-03 - 5 -1.1443756309854350e-02 -9.5094274839355366e-03 -2.8606259908498174e-03 - 6 1.9687920319066405e-03 3.5534706571735291e-03 3.2968368883068665e-02 + 1 1.2684230994165607e-02 1.2495256261514619e-02 4.9930344501754684e-03 + 2 4.3518220414975658e-03 6.2675117562013480e-03 -1.5418810814942943e-03 + 3 -1.2234130921634355e-02 -9.3495843960724259e-03 -4.6324540534036160e-03 + 4 -5.0386193262248399e-03 -5.3641219069569283e-03 -1.1886832268516237e-03 + 5 -1.1443756309854352e-02 -9.5094274839355383e-03 -2.8606259908498187e-03 + 6 1.9687920319066405e-03 3.5534706571735282e-03 3.2968368883068665e-02 7 -4.4609712390029990e-03 -5.1182407403250344e-03 -5.3884713264266998e-02 - 8 3.9019842162219044e-03 2.6969390843091471e-03 4.2232422670644892e-02 + 8 3.9019842162219039e-03 2.6969390843091462e-03 4.2232422670644892e-02 9 4.7081329435379928e-03 7.9973440232876945e-04 1.5395337548004654e-02 - 10 -3.0261769585336135e-04 -2.5740555713842149e-04 -1.6356926331032737e-02 + 10 -3.0261769585336010e-04 -2.5740555713841905e-04 -1.6356926331032737e-02 11 -3.5476678248804613e-03 -4.7067983292878183e-03 -2.1440510485219223e-03 - 12 1.8144360490014990e-03 7.9693616951164063e-05 -3.0607029773290864e-03 - 13 4.4624855231916059e-03 3.8913798430631526e-03 -7.3471490153043995e-04 - 14 8.5951634791463845e-04 -3.0677163113573365e-03 -3.9476830462698825e-03 - 15 -4.3865629825187444e-03 -3.2366584107100553e-03 6.2106171937144185e-03 - 16 3.0917841316903611e-03 2.6883341559191675e-03 -4.9093430472400619e-02 - 17 -1.5592872047137272e-03 -1.8498512101422430e-03 3.9767639007755935e-02 - 18 -8.0065510115642151e-04 -8.6270510525007294e-04 -1.4483045867941069e-03 - 19 1.2452394050314463e-03 -2.5061097539385720e-03 7.2998629486265044e-03 - 20 3.5930060787009634e-03 3.6938860117779037e-03 3.2322732684341988e-03 - 21 -1.4689196268240781e-03 -2.7352333342171262e-04 7.0581285552551100e-04 - 22 -7.0694198802010982e-03 -4.2577149698438668e-03 2.8079095849804981e-04 - 23 6.0446964726305220e-03 -1.4000131857275601e-03 2.5819753138166994e-03 - 24 3.1926383007563959e-04 -9.9445695130458991e-04 1.4999956095861883e-04 - 25 1.3789758971327935e-04 -4.4335898697816581e-03 -8.1808174043568002e-04 - 26 2.0485903968908386e-03 2.7813358254351185e-03 4.3245726870644327e-03 - 27 4.5604117355176098e-04 -1.0305523817712768e-03 2.1188043533291564e-04 - 28 -6.2544520533999292e-03 1.4127711444285823e-03 -1.8429822080647299e-03 - 29 6.4110639769257973e-04 3.1273433780430434e-03 3.7253670085370728e-03 + 12 1.8144360490015025e-03 7.9693616951168387e-05 -3.0607029773290929e-03 + 13 4.4624855231915981e-03 3.8913798430631479e-03 -7.3471490153043475e-04 + 14 8.5951634791463281e-04 -3.0677163113573412e-03 -3.9476830462698807e-03 + 15 -4.3865629825187505e-03 -3.2366584107100587e-03 6.2106171937144246e-03 + 16 3.0917841316903615e-03 2.6883341559191662e-03 -4.9093430472400619e-02 + 17 -1.5592872047137270e-03 -1.8498512101422441e-03 3.9767639007755935e-02 + 18 -8.0065510115642151e-04 -8.6270510525007229e-04 -1.4483045867941095e-03 + 19 1.2452394050314430e-03 -2.5061097539385751e-03 7.2998629486265071e-03 + 20 3.5930060787009665e-03 3.6938860117779037e-03 3.2322732684342049e-03 + 21 -1.4689196268240774e-03 -2.7352333342171170e-04 7.0581285552550840e-04 + 22 -7.0694198802011025e-03 -4.2577149698438703e-03 2.8079095849805306e-04 + 23 6.0446964726305254e-03 -1.4000131857275601e-03 2.5819753138167051e-03 + 24 3.1926383007563900e-04 -9.9445695130458709e-04 1.4999956095861745e-04 + 25 1.3789758971327707e-04 -4.4335898697816659e-03 -8.1808174043567947e-04 + 26 2.0485903968908425e-03 2.7813358254351155e-03 4.3245726870644362e-03 + 27 4.5604117355176071e-04 -1.0305523817712738e-03 2.1188043533291488e-04 + 28 -6.2544520533999309e-03 1.4127711444285763e-03 -1.8429822080647292e-03 + 29 6.4110639769258428e-04 3.1273433780430403e-03 3.7253670085370767e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-press_berendsen_iso.yaml b/unittest/force-styles/tests/fix-timestep-press_berendsen_iso.yaml index c5bed62746..e466d6a259 100644 --- a/unittest/force-styles/tests/fix-timestep-press_berendsen_iso.yaml +++ b/unittest/force-styles/tests/fix-timestep-press_berendsen_iso.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:59 2022 epsilon: 2e-12 +skip_tests: prerequisites: ! | atom full fix press/berendsen @@ -42,23 +43,23 @@ run_pos: ! |2 28 -2.9552202082294778e+00 -4.2155356436588987e+00 1.6932958531971636e+00 29 -1.4526234281463211e+00 -3.7726615685777620e+00 2.4133434299397827e+00 run_vel: ! |2 - 1 6.8612579444768231e-03 9.3588988693932805e-03 -2.4583492777823684e-04 - 2 -5.0360784274195033e-04 2.9726176692813336e-04 5.5601612371459462e-03 - 3 -4.7155832907463452e-03 -5.2759387113087341e-03 -1.2616380301006356e-03 - 4 9.0720438238635814e-04 -7.5770223054582126e-03 2.0478412627257941e-03 - 5 -9.5789948666970045e-03 -7.8707074219574475e-03 -7.9287843977473432e-03 - 6 -2.5864536864176637e-02 3.1782714744452420e-02 2.5357940964759636e-02 + 1 6.8612579444768248e-03 9.3588988693932753e-03 -2.4583492777824047e-04 + 2 -5.0360784274194989e-04 2.9726176692814176e-04 5.5601612371459531e-03 + 3 -4.7155832907463469e-03 -5.2759387113087263e-03 -1.2616380301006297e-03 + 4 9.0720438238636259e-04 -7.5770223054582187e-03 2.0478412627257863e-03 + 5 -9.5789948666969976e-03 -7.8707074219574562e-03 -7.9287843977473450e-03 + 6 -2.5864536864176644e-02 3.1782714744452420e-02 2.5357940964759636e-02 7 1.7503976604491542e-04 -6.5115623482965013e-03 -3.3939736089235235e-02 - 8 6.1789956534982508e-03 -3.2385611493897320e-03 2.5198707320088474e-02 + 8 6.1789956534982482e-03 -3.2385611493897324e-03 2.5198707320088474e-02 9 -1.0477317219362496e-03 8.0710832498008555e-04 3.3332742003808645e-03 - 10 2.0007827220591145e-02 -1.7400965483689801e-02 -1.1413325470549929e-02 + 10 2.0007827220591152e-02 -1.7400965483689801e-02 -1.1413325470549929e-02 11 -3.3990745583665129e-03 -7.3619037098941514e-04 2.4449145139565686e-03 - 12 1.3760114048527200e-03 -8.1425901890779418e-04 -2.9046493957496202e-03 - 13 -2.5828376034205732e-03 7.7834697286519742e-03 -6.8243437049079190e-04 - 14 5.4336022535973862e-03 -6.1421574327034621e-03 1.3592225966609420e-03 - 15 -1.7549740615613416e-03 -1.1133323565619430e-02 4.2071260576439420e-03 - 16 1.0367443974825941e-02 -6.4589866626159186e-03 -2.8766731056347843e-02 - 17 -7.5963042220266912e-03 6.0593621716489411e-03 2.3127705683585555e-02 + 12 1.3760114048527239e-03 -8.1425901890779028e-04 -2.9046493957496254e-03 + 13 -2.5828376034205762e-03 7.7834697286519646e-03 -6.8243437049078735e-04 + 14 5.4336022535973819e-03 -6.1421574327034691e-03 1.3592225966609459e-03 + 15 -1.7549740615613455e-03 -1.1133323565619434e-02 4.2071260576439480e-03 + 16 1.0367443974825937e-02 -6.4589866626159160e-03 -2.8766731056347843e-02 + 17 -7.5963042220266912e-03 6.0593621716489403e-03 2.3127705683585555e-02 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-python_move_nve.yaml b/unittest/force-styles/tests/fix-timestep-python_move_nve.yaml index 04bd81670b..c4f391d2bd 100644 --- a/unittest/force-styles/tests/fix-timestep-python_move_nve.yaml +++ b/unittest/force-styles/tests/fix-timestep-python_move_nve.yaml @@ -1,8 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Wed Mar 24 18:57:26 2021 -skip_tests: static +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 9e-12 +skip_tests: static prerequisites: ! | atom full fix python/move @@ -12,7 +12,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_pos: ! |2 - 1 -2.7045559775384037e-01 2.4912159905679729e+00 -1.6695851791541885e-01 + 1 -2.7045559775384032e-01 2.4912159905679729e+00 -1.6695851791541888e-01 2 3.1004029573899528e-01 2.9612354631094391e+00 -8.5466363037021464e-01 3 -7.0398551400789477e-01 1.2305509955830618e+00 -6.2777526944456274e-01 4 -1.5818159336499285e+00 1.4837407818929933e+00 -1.2538710836062004e+00 @@ -23,7 +23,7 @@ run_pos: ! |2 9 1.3800524229500313e+00 -2.5274721030406683e-01 2.8353985887095157e-01 10 2.0510765220543883e+00 -1.4604063740302866e+00 -9.8323745081712954e-01 11 1.7878031944442556e+00 -1.9921863272948861e+00 -1.8890602447625777e+00 - 12 3.0063007039340053e+00 -4.9013350496963298e-01 -1.6231898107386229e+00 + 12 3.0063007039340053e+00 -4.9013350496963293e-01 -1.6231898107386229e+00 13 4.0515402959192999e+00 -8.9202011606653986e-01 -1.6400005529924957e+00 14 2.6066963345543819e+00 -4.1789253965514150e-01 -2.6634003608794394e+00 15 2.9695287185712913e+00 5.5422613165234036e-01 -1.2342022021790127e+00 @@ -42,33 +42,33 @@ run_pos: ! |2 28 -2.7473562684513411e+00 -4.0200819932379330e+00 1.5830052163433954e+00 29 -1.3126000191359855e+00 -3.5962518039482929e+00 2.2746342468737835e+00 run_vel: ! |2 - 1 8.1705744183262364e-03 1.6516406176274288e-02 4.7902264318912978e-03 - 2 5.4501493445687759e-03 5.1791699408496334e-03 -1.4372931530376651e-03 - 3 -8.2298292722385643e-03 -1.2926551614621381e-02 -4.0984181178163881e-03 - 4 -3.7699042590093588e-03 -6.5722892098813799e-03 -1.1184640360133230e-03 - 5 -1.1021961004346586e-02 -9.8906780939335987e-03 -2.8410737829284395e-03 + 1 8.1705744183262364e-03 1.6516406176274288e-02 4.7902264318912926e-03 + 2 5.4501493445687802e-03 5.1791699408496412e-03 -1.4372931530376623e-03 + 3 -8.2298292722385660e-03 -1.2926551614621376e-02 -4.0984181178163829e-03 + 4 -3.7699042590093549e-03 -6.5722892098813894e-03 -1.1184640360133316e-03 + 5 -1.1021961004346581e-02 -9.8906780939336057e-03 -2.8410737829284403e-03 6 -3.9676663166400034e-02 4.6817061464710256e-02 3.7148491979476124e-02 7 9.1033953013898580e-04 -1.0128524411938794e-02 -5.1568251805019748e-02 - 8 7.9064712058855707e-03 -3.3507254552631767e-03 3.4557098492564629e-02 + 8 7.9064712058855690e-03 -3.3507254552631780e-03 3.4557098492564629e-02 9 1.5644176117320923e-03 3.7365546102722164e-03 1.5047408822037646e-02 - 10 2.9201446820573174e-02 -2.9249578745486147e-02 -1.5018077424322538e-02 + 10 2.9201446820573178e-02 -2.9249578745486140e-02 -1.5018077424322538e-02 11 -4.7835961513517560e-03 -3.7481385134185206e-03 -2.3464104142290089e-03 - 12 2.2696451841920521e-03 -3.4774154398129479e-04 -3.0640770327796806e-03 - 13 2.7531740451953168e-03 5.8171061612840667e-03 -7.9467454022160518e-04 - 14 3.5246182371994252e-03 -5.7939995585585468e-03 -3.9478431172751344e-03 - 15 -1.8547943640122894e-03 -5.8554729942777743e-03 6.2938485140538649e-03 - 16 1.8681499973445245e-02 -1.3262466204585335e-02 -4.5638651457003243e-02 + 12 2.2696451841920568e-03 -3.4774154398129457e-04 -3.0640770327796858e-03 + 13 2.7531740451953108e-03 5.8171061612840597e-03 -7.9467454022159878e-04 + 14 3.5246182371994187e-03 -5.7939995585585477e-03 -3.9478431172751327e-03 + 15 -1.8547943640122935e-03 -5.8554729942777743e-03 6.2938485140538684e-03 + 16 1.8681499973445235e-02 -1.3262466204585334e-02 -4.5638651457003243e-02 17 -1.2896269981100382e-02 9.7527665265956451e-03 3.7296535360836762e-02 - 18 -8.0065794848261610e-04 -8.6270473212554395e-04 -1.4483040697508738e-03 - 19 1.2452390836182623e-03 -2.5061097118772701e-03 7.2998631009712975e-03 - 20 3.5930060229597042e-03 3.6938860309252966e-03 3.2322732687893028e-03 - 21 -1.4689220370766550e-03 -2.7352129761527741e-04 7.0581624215243391e-04 - 22 -7.0694199254630339e-03 -4.2577148924878554e-03 2.8079117614251796e-04 - 23 6.0446963117374913e-03 -1.4000131614795382e-03 2.5819754847014255e-03 - 24 3.1926367902287940e-04 -9.9445664749276438e-04 1.4999996959365452e-04 - 25 1.3789754514814662e-04 -4.4335894884532569e-03 -8.1808136725080281e-04 - 26 2.0485904035217549e-03 2.7813358633835984e-03 4.3245727149206692e-03 - 27 4.5604120293369857e-04 -1.0305523026921137e-03 2.1188058381358511e-04 - 28 -6.2544520861855116e-03 1.4127711176146942e-03 -1.8429821884794269e-03 - 29 6.4110631534401762e-04 3.1273432719593867e-03 3.7253671105656715e-03 + 18 -8.0065794848261610e-04 -8.6270473212554319e-04 -1.4483040697508770e-03 + 19 1.2452390836182592e-03 -2.5061097118772731e-03 7.2998631009713044e-03 + 20 3.5930060229597050e-03 3.6938860309252974e-03 3.2322732687893093e-03 + 21 -1.4689220370766539e-03 -2.7352129761527654e-04 7.0581624215243131e-04 + 22 -7.0694199254630382e-03 -4.2577148924878589e-03 2.8079117614252034e-04 + 23 6.0446963117374939e-03 -1.4000131614795382e-03 2.5819754847014316e-03 + 24 3.1926367902287880e-04 -9.9445664749276200e-04 1.4999996959365322e-04 + 25 1.3789754514814532e-04 -4.4335894884532673e-03 -8.1808136725080173e-04 + 26 2.0485904035217588e-03 2.7813358633835962e-03 4.3245727149206761e-03 + 27 4.5604120293369840e-04 -1.0305523026921111e-03 2.1188058381358413e-04 + 28 -6.2544520861855151e-03 1.4127711176146879e-03 -1.8429821884794260e-03 + 29 6.4110631534402174e-04 3.1273432719593824e-03 3.7253671105656736e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-rattle_angle.yaml b/unittest/force-styles/tests/fix-timestep-rattle_angle.yaml index 9c432c8db8..6b484fc57f 100644 --- a/unittest/force-styles/tests/fix-timestep-rattle_angle.yaml +++ b/unittest/force-styles/tests/fix-timestep-rattle_angle.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:55 2021 -epsilon: 9e-10 +lammps_version: 17 Feb 2022 tags: unstable +date_generated: Fri Mar 18 22:18:00 2022 +epsilon: 9e-10 +skip_tests: prerequisites: ! | atom full fix rattle @@ -46,23 +47,23 @@ run_pos: ! |2 28 -2.7473562684513424e+00 -4.0200819932379339e+00 1.5830052163433954e+00 29 -1.3126000191366676e+00 -3.5962518039489830e+00 2.2746342468733833e+00 run_vel: ! |2 - 1 8.1705729507146642e-03 1.6516406093744641e-02 4.7902279090199888e-03 - 2 5.4501493276694407e-03 5.1791698760542655e-03 -1.4372929651720373e-03 - 3 -8.2298303446991499e-03 -1.2926552110646281e-02 -4.0984171815350119e-03 - 4 -3.7699042793691621e-03 -6.5722892086671888e-03 -1.1184640147877227e-03 - 5 -1.1021961023179821e-02 -9.8906780808723574e-03 -2.8410737186752391e-03 - 6 -3.9676664596302022e-02 4.6817059618450917e-02 3.7148492579484563e-02 + 1 8.1705729507146642e-03 1.6516406093744638e-02 4.7902279090199828e-03 + 2 5.4501493276694415e-03 5.1791698760542690e-03 -1.4372929651720336e-03 + 3 -8.2298303446991534e-03 -1.2926552110646276e-02 -4.0984171815350067e-03 + 4 -3.7699042793691595e-03 -6.5722892086671914e-03 -1.1184640147877303e-03 + 5 -1.1021961023179814e-02 -9.8906780808723678e-03 -2.8410737186752412e-03 + 6 -3.9676664596302022e-02 4.6817059618450910e-02 3.7148492579484563e-02 7 9.1034031301509934e-04 -1.0128522664904629e-02 -5.1568252954671358e-02 - 8 7.9064703413713518e-03 -3.3507265483952130e-03 3.4557099321061970e-02 + 8 7.9064703413713484e-03 -3.3507265483952134e-03 3.4557099321061970e-02 9 1.5644176069499445e-03 3.7365546445246702e-03 1.5047408832397751e-02 - 10 2.9201446099433200e-02 -2.9249578511256979e-02 -1.5018076911020584e-02 + 10 2.9201446099433204e-02 -2.9249578511256979e-02 -1.5018076911020585e-02 11 -4.7835964007472438e-03 -3.7481383012996799e-03 -2.3464103653896319e-03 - 12 2.2696453008391368e-03 -3.4774279616439630e-04 -3.0640765817961158e-03 - 13 2.7531739986205606e-03 5.8171065863360273e-03 -7.9467449090663456e-04 - 14 3.5246182341718787e-03 -5.7939994947008291e-03 -3.9478431580931327e-03 - 15 -1.8547943904014324e-03 -5.8554729842982909e-03 6.2938484741557809e-03 - 16 1.8681498891538882e-02 -1.3262465322856017e-02 -4.5638650127800932e-02 - 17 -1.2896270312366209e-02 9.7527665732632350e-03 3.7296535866542128e-02 + 12 2.2696453008391403e-03 -3.4774279616439196e-04 -3.0640765817961219e-03 + 13 2.7531739986205576e-03 5.8171065863360186e-03 -7.9467449090662935e-04 + 14 3.5246182341718722e-03 -5.7939994947008352e-03 -3.9478431580931301e-03 + 15 -1.8547943904014381e-03 -5.8554729842982918e-03 6.2938484741557853e-03 + 16 1.8681498891538879e-02 -1.3262465322856017e-02 -4.5638650127800932e-02 + 17 -1.2896270312366207e-02 9.7527665732632350e-03 3.7296535866542128e-02 18 3.6201701458125901e-04 -3.1019809770901913e-04 8.1201763681395124e-04 19 8.5112360015621527e-04 -1.4603353796945311e-03 1.0305254865262262e-03 20 -6.5417978223454955e-04 4.4256253979791337e-04 4.7856455882856112e-04 @@ -72,7 +73,7 @@ run_vel: ! |2 24 8.5788311101024021e-04 -9.4446252118115083e-04 5.5288135210022535e-04 25 1.6004033600709000e-03 -2.2093786373070566e-03 -5.4710565574674660e-04 26 -1.5640453234916207e-03 3.5755082486241615e-04 2.4453236849039262e-03 - 27 4.5604120291777391e-04 -1.0305523027099432e-03 2.1188058380935704e-04 - 28 -6.2544520861865490e-03 1.4127711176129324e-03 -1.8429821884795277e-03 - 29 6.4110631474916110e-04 3.1273432713407900e-03 3.7253671102111473e-03 + 27 4.5604120291777359e-04 -1.0305523027099401e-03 2.1188058380935623e-04 + 28 -6.2544520861865507e-03 1.4127711176129259e-03 -1.8429821884795275e-03 + 29 6.4110631474916446e-04 3.1273432713407865e-03 3.7253671102111486e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-rattle_bond.yaml b/unittest/force-styles/tests/fix-timestep-rattle_bond.yaml index fcf9c20ab8..c8cfc43bb9 100644 --- a/unittest/force-styles/tests/fix-timestep-rattle_bond.yaml +++ b/unittest/force-styles/tests/fix-timestep-rattle_bond.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 1.5e-10 +skip_tests: prerequisites: ! | atom full fix rattle @@ -13,13 +14,13 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |2- - 3.9891557115890999e+00 3.7983351717152480e+00 7.6152694943743228e+01 5.7163462651523300e-01 3.0839737670745507e+01 3.0066936263232019e+01 + 3.9891557116166902e+00 3.7983351717164044e+00 7.6152694943746113e+01 5.7163462651704755e-01 3.0839737670732816e+01 3.0066936263199256e+01 run_pos: ! |2 - 1 -2.6863205200662160e-01 2.4924200251053037e+00 -1.6940797171640173e-01 + 1 -2.6863205200662160e-01 2.4924200251053037e+00 -1.6940797171640176e-01 2 3.0314855494325726e-01 2.9555142432096928e+00 -8.4661597718762538e-01 - 3 -7.0471630526135653e-01 1.2320076232474173e+00 -6.3059972306932599e-01 + 3 -7.0471630526135665e-01 1.2320076232474173e+00 -6.3059972306932599e-01 4 -1.5777965340711875e+00 1.4826179820456016e+00 -1.2510232575394136e+00 - 5 -9.0838614372574067e-01 9.2479324973625643e-01 4.0580653202950134e-01 + 5 -9.0838614372574056e-01 9.2479324973625643e-01 4.0580653202950134e-01 6 2.4793967906065856e-01 2.8343287430301523e-01 -1.2316652319085841e+00 7 3.4143850947000237e-01 -2.2651528366236746e-02 -2.5292473574049552e+00 8 1.1730749609547400e+00 -4.9001540353149170e-01 -6.4332649946665266e-01 @@ -45,33 +46,33 @@ run_pos: ! |2 28 -2.7473562684591109e+00 -4.0200819932508631e+00 1.5830052163456609e+00 29 -1.3126000191565619e+00 -3.5962518039874860e+00 2.2746342468906682e+00 run_vel: ! |2 - 1 7.7370763703885981e-03 1.5916623177089917e-02 5.0460584330822480e-03 - 2 6.5186940562006425e-03 6.0087223948100997e-03 -2.7579528931744326e-03 - 3 -7.3639039999207805e-03 -1.2783111443358818e-02 -3.3210723356919430e-03 - 4 -5.8962208660568623e-03 -5.9658659155316252e-03 -2.6327244609218236e-03 - 5 -1.0929657512764205e-02 -9.6585946726249240e-03 -3.0956201839590124e-03 - 6 -4.0123707366837992e-02 4.7187394112882822e-02 3.6871538264127757e-02 + 1 7.7370763703885972e-03 1.5916623177089917e-02 5.0460584330822445e-03 + 2 6.5186940562006442e-03 6.0087223948101067e-03 -2.7579528931744287e-03 + 3 -7.3639039999207788e-03 -1.2783111443358811e-02 -3.3210723356919382e-03 + 4 -5.8962208660568579e-03 -5.9658659155316304e-03 -2.6327244609218271e-03 + 5 -1.0929657512764201e-02 -9.6585946726249344e-03 -3.0956201839590124e-03 + 6 -4.0123707366837999e-02 4.7187394112882822e-02 3.6871538264127757e-02 7 9.1133487010599461e-04 -1.0132608633652495e-02 -5.1595915280728183e-02 - 8 7.0088514431851422e-03 -4.2477252839068919e-03 3.0986345119599783e-02 + 8 7.0088514431851413e-03 -4.2477252839068927e-03 3.0986345119599783e-02 9 4.6374036922998555e-03 7.0470301756850907e-03 2.8627719728916035e-02 - 10 3.0611231933355295e-02 -2.7617219870000733e-02 -1.2129568539940891e-02 - 11 -7.2060626580151164e-03 -9.4599495517301499e-03 -1.1803018293165211e-02 - 12 1.5103726570079637e-03 -8.6499790408050452e-04 -2.9343732292293413e-03 - 13 4.0387984545004179e-03 5.5920103447542734e-03 -9.5141435774168603e-04 - 14 3.7449566583612186e-03 -5.7205267373051458e-03 -4.1285172459609044e-03 - 15 -1.6192412735192771e-03 -4.5860921043834090e-03 6.6371157403290462e-03 - 16 1.8683716258419525e-02 -1.3263096088946387e-02 -4.5607321000772597e-02 - 17 -1.2893753425925242e-02 9.7485795481257100e-03 3.7300775385778646e-02 - 18 -8.0065894051881104e-04 -8.6270684963651997e-04 -1.4483015146944853e-03 - 19 1.2452389852680510e-03 -2.5061098313021958e-03 7.2998634573395622e-03 - 20 3.5930058838403115e-03 3.6938858373569165e-03 3.2322734729320975e-03 - 21 -1.4689219027528956e-03 -2.7352134530947029e-04 7.0581593448005339e-04 - 22 -7.0694199260273143e-03 -4.2577148857392598e-03 2.8079115157198279e-04 - 23 6.0446963222438397e-03 -1.4000131442962716e-03 2.5819754631691500e-03 - 24 3.1926442964369685e-04 -9.9445591935644600e-04 1.5000033448111914e-04 - 25 1.3789825021844792e-04 -4.4335889596263511e-03 -8.1808100227326449e-04 - 26 2.0485904735292599e-03 2.7813359659683385e-03 4.3245727170611618e-03 - 27 4.5604110580961207e-04 -1.0305524671180935e-03 2.1188063421234097e-04 - 28 -6.2544520944132998e-03 1.4127711036803850e-03 -1.8429821866102578e-03 - 29 6.4110628696208052e-04 3.1273432221612541e-03 3.7253671295737062e-03 + 10 3.0611231933355295e-02 -2.7617219870000747e-02 -1.2129568539940891e-02 + 11 -7.2060626580151173e-03 -9.4599495517301551e-03 -1.1803018293165216e-02 + 12 1.5103726570079676e-03 -8.6499790408049997e-04 -2.9343732292293465e-03 + 13 4.0387984545004188e-03 5.5920103447542682e-03 -9.5141435774168082e-04 + 14 3.7449566583612104e-03 -5.7205267373051502e-03 -4.1285172459609052e-03 + 15 -1.6192412735192840e-03 -4.5860921043834090e-03 6.6371157403290531e-03 + 16 1.8683716258419514e-02 -1.3263096088946387e-02 -4.5607321000772597e-02 + 17 -1.2893753425925242e-02 9.7485795481257083e-03 3.7300775385778646e-02 + 18 -8.0065894051881104e-04 -8.6270684963651932e-04 -1.4483015146944881e-03 + 19 1.2452389852680478e-03 -2.5061098313021992e-03 7.2998634573395666e-03 + 20 3.5930058838403154e-03 3.6938858373569169e-03 3.2322734729321036e-03 + 21 -1.4689219027528948e-03 -2.7352134530946943e-04 7.0581593448005079e-04 + 22 -7.0694199260273186e-03 -4.2577148857392616e-03 2.8079115157198702e-04 + 23 6.0446963222438423e-03 -1.4000131442962716e-03 2.5819754631691569e-03 + 24 3.1926442964369620e-04 -9.9445591935644361e-04 1.5000033448111768e-04 + 25 1.3789825021844635e-04 -4.4335889596263606e-03 -8.1808100227326308e-04 + 26 2.0485904735292647e-03 2.7813359659683355e-03 4.3245727170611661e-03 + 27 4.5604110580961169e-04 -1.0305524671180911e-03 2.1188063421234002e-04 + 28 -6.2544520944133042e-03 1.4127711036803785e-03 -1.8429821866102578e-03 + 29 6.4110628696208540e-04 3.1273432221612493e-03 3.7253671295737097e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-restrain.yaml b/unittest/force-styles/tests/fix-timestep-restrain.yaml index c6806c3176..795f6ca161 100644 --- a/unittest/force-styles/tests/fix-timestep-restrain.yaml +++ b/unittest/force-styles/tests/fix-timestep-restrain.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full fix restrain @@ -11,7 +12,7 @@ post_commands: ! | fix test solute restrain bond 2 4 100 150 2.4 2.4 angle 17 16 9 50.0 50.0 90.0 dihedral 3 8 16 17 50.0 40.0 -20.0 mult 2 lbound 11 14 100 100 2.0 2.5 input_file: in.fourmol natoms: 29 -global_scalar: 114.558406487374 +global_scalar: 114.55840648737437 global_vector: ! |- 3 0.15090319643872077 29.7021302625337 0 run_pos: ! |2 @@ -45,33 +46,33 @@ run_pos: ! |2 28 -2.7473562684518900e+00 -4.0200819932394678e+00 1.5830052163448296e+00 29 -1.3126000191312155e+00 -3.5962518039512497e+00 2.2746342468749279e+00 run_vel: ! |2 - 1 8.1022100178321614e-03 1.6328281959885026e-02 4.7314374413107135e-03 - 2 4.5940682030656153e-03 4.5179487515869879e-03 -1.6492594876204641e-03 - 3 -1.0161733102094436e-02 -1.4885269465719279e-02 -5.7039539110871965e-03 - 4 -2.9901007762410878e-03 -5.8980329887710573e-03 -9.8331520465552193e-04 - 5 -1.1061568499201441e-02 -9.9086761770475866e-03 -2.8614934490067238e-03 + 1 8.1022100178321631e-03 1.6328281959885022e-02 4.7314374413107100e-03 + 2 4.5940682030656162e-03 4.5179487515869974e-03 -1.6492594876204591e-03 + 3 -1.0161733102094438e-02 -1.4885269465719275e-02 -5.7039539110871913e-03 + 4 -2.9901007762410843e-03 -5.8980329887710660e-03 -9.8331520465552995e-04 + 5 -1.1061568499201434e-02 -9.9086761770475970e-03 -2.8614934490067243e-03 6 -3.9565523265972971e-02 4.6643044826882023e-02 3.7231494152594087e-02 7 9.1355628194479644e-04 -1.0132838137040103e-02 -5.1562272233471963e-02 - 8 1.1189041509141819e-02 2.5814492073717143e-04 3.7070457285878981e-02 + 8 1.1189041509141819e-02 2.5814492073717072e-04 3.7070457285878981e-02 9 2.2009572911783439e-03 4.7021819574224214e-03 1.1881801075700039e-02 - 10 2.9048157037522303e-02 -2.9179902077483610e-02 -1.5011547220722683e-02 + 10 2.9048157037522306e-02 -2.9179902077483607e-02 -1.5011547220722683e-02 11 -1.0220934050981722e-02 -1.4181485625590975e-02 2.8408980086852727e-03 - 12 2.2745816514919519e-03 -3.2425287073352247e-04 -3.1217236187068317e-03 - 13 2.7546696470429769e-03 5.8201711310770085e-03 -7.7669587326760676e-04 - 14 8.9625817039363492e-03 4.6540637267909590e-03 -9.0167435844691127e-03 - 15 -1.8357901021329049e-03 -5.8749842521648755e-03 6.3484355960452691e-03 - 16 1.3892112812942791e-02 -1.4698281213197547e-02 -4.7202487444587202e-02 - 17 -1.0775499116201853e-02 9.1311247375589679e-03 3.8266520862089155e-02 - 18 -8.0065786570119820e-04 -8.6270484590307529e-04 -1.4483039596991482e-03 - 19 1.2452390942963225e-03 -2.5061097232459439e-03 7.2998631133481661e-03 - 20 3.5930060234228762e-03 3.6938860225129936e-03 3.2322732747491053e-03 - 21 -1.4689220123599992e-03 -2.7352137958004327e-04 7.0581614585149164e-04 - 22 -7.0694199258456263e-03 -4.2577148958047985e-03 2.8079117150769023e-04 - 23 6.0446963153580249e-03 -1.4000131639527451e-03 2.5819754778255285e-03 - 24 3.1926373851903702e-04 -9.9445676589627100e-04 1.4999989504315482e-04 - 25 1.3789757621990772e-04 -4.4335894995587806e-03 -8.1808134678553054e-04 - 26 2.0485904040079606e-03 2.7813358574358283e-03 4.3245727129295258e-03 - 27 4.5604114832609600e-04 -1.0305523974737125e-03 2.1188063937668003e-04 - 28 -6.2544520873339133e-03 1.4127711141935970e-03 -1.8429821854305474e-03 - 29 6.4110632411710838e-04 3.1273432646939294e-03 3.7253671132179739e-03 + 12 2.2745816514919575e-03 -3.2425287073351852e-04 -3.1217236187068365e-03 + 13 2.7546696470429756e-03 5.8201711310770050e-03 -7.7669587326760134e-04 + 14 8.9625817039363422e-03 4.6540637267909546e-03 -9.0167435844691092e-03 + 15 -1.8357901021329073e-03 -5.8749842521648773e-03 6.3484355960452734e-03 + 16 1.3892112812942784e-02 -1.4698281213197547e-02 -4.7202487444587202e-02 + 17 -1.0775499116201853e-02 9.1311247375589662e-03 3.8266520862089169e-02 + 18 -8.0065786570119820e-04 -8.6270484590307474e-04 -1.4483039596991515e-03 + 19 1.2452390942963194e-03 -2.5061097232459469e-03 7.2998631133481730e-03 + 20 3.5930060234228779e-03 3.6938860225129958e-03 3.2322732747491110e-03 + 21 -1.4689220123599981e-03 -2.7352137958004235e-04 7.0581614585148915e-04 + 22 -7.0694199258456315e-03 -4.2577148958048028e-03 2.8079117150769261e-04 + 23 6.0446963153580266e-03 -1.4000131639527451e-03 2.5819754778255355e-03 + 24 3.1926373851903637e-04 -9.9445676589626840e-04 1.4999989504315336e-04 + 25 1.3789757621990642e-04 -4.4335894995587866e-03 -8.1808134678552924e-04 + 26 2.0485904040079650e-03 2.7813358574358253e-03 4.3245727129295301e-03 + 27 4.5604114832609573e-04 -1.0305523974737097e-03 2.1188063937667922e-04 + 28 -6.2544520873339159e-03 1.4127711141935907e-03 -1.8429821854305474e-03 + 29 6.4110632411711304e-04 3.1273432646939255e-03 3.7253671132179778e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-rigid_group.yaml b/unittest/force-styles/tests/fix-timestep-rigid_group.yaml index 9646f73313..e28e0abb08 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_group.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_group.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid @@ -13,26 +14,26 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -1.4245356937318884e+03 -1.4496493315649705e+03 -3.6144360984225009e+03 8.4840626828644258e+02 2.0318336761611707e+02 -6.0622397707970117e+02 -global_scalar: 15.7115214231781 + -1.4245356937318884e+03 -1.4496493315649691e+03 -3.6144360984224995e+03 8.4840626828644076e+02 2.0318336761611761e+02 -6.0622397707970140e+02 +global_scalar: 15.711521423178082 run_pos: ! |2 - 1 -2.7899546863891489e-01 2.4731857340328216e+00 -1.7290667740242327e-01 - 2 3.0296221610264151e-01 2.9517129916957532e+00 -8.5798904387773267e-01 - 3 -6.9368802364134807e-01 1.2445115421754180e+00 -6.2281111198650496e-01 - 4 -1.5764879647103154e+00 1.4919714415841261e+00 -1.2492069414674631e+00 - 5 -8.9434512967430058e-01 9.3651699743510919e-01 4.0191726558261187e-01 - 6 2.9454439634451712e-01 2.2724545792543988e-01 -1.2845195053960272e+00 - 7 3.4049112903270107e-01 -9.4655678322462800e-03 -2.4634480020857055e+00 - 8 1.1644354555804874e+00 -4.8367776650961330e-01 -6.7663643940735863e-01 - 9 1.3781717822696467e+00 -2.5332509530010694e-01 2.6864954436590061e-01 - 10 2.0186368606041896e+00 -1.4285861423625787e+00 -9.6712491252780097e-01 - 11 1.7929137227577463e+00 -1.9875455388407417e+00 -1.8836565352266530e+00 - 12 3.0032775230399609e+00 -4.8983022415173938e-01 -1.6190248017343634e+00 - 13 4.0448964162125947e+00 -9.0213155122390887e-01 -1.6385398399479545e+00 - 14 2.6035151245015831e+00 -4.0874995493219152e-01 -2.6555999074786603e+00 - 15 2.9761196776172318e+00 5.6287237454108718e-01 -1.2442626196083382e+00 - 16 2.6517373021566177e+00 -2.3957035508393694e+00 3.3389262100692485e-02 - 17 2.2311114924744970e+00 -2.1018393228798504e+00 1.1496088522377548e+00 + 1 -2.7899546863891400e-01 2.4731857340328229e+00 -1.7290667740242271e-01 + 2 3.0296221610264262e-01 2.9517129916957545e+00 -8.5798904387773245e-01 + 3 -6.9368802364134741e-01 1.2445115421754194e+00 -6.2281111198650418e-01 + 4 -1.5764879647103154e+00 1.4919714415841279e+00 -1.2492069414674623e+00 + 5 -8.9434512967429969e-01 9.3651699743511030e-01 4.0191726558261276e-01 + 6 2.9454439634451712e-01 2.2724545792544038e-01 -1.2845195053960268e+00 + 7 3.4049112903270051e-01 -9.4655678322458359e-03 -2.4634480020857055e+00 + 8 1.1644354555804874e+00 -4.8367776650961336e-01 -6.7663643940735863e-01 + 9 1.3781717822696469e+00 -2.5332509530010694e-01 2.6864954436590061e-01 + 10 2.0186368606041896e+00 -1.4285861423625796e+00 -9.6712491252780131e-01 + 11 1.7929137227577452e+00 -1.9875455388407426e+00 -1.8836565352266534e+00 + 12 3.0032775230399604e+00 -4.8983022415174027e-01 -1.6190248017343642e+00 + 13 4.0448964162125947e+00 -9.0213155122391020e-01 -1.6385398399479558e+00 + 14 2.6035151245015822e+00 -4.0874995493219213e-01 -2.6555999074786607e+00 + 15 2.9761196776172318e+00 5.6287237454108674e-01 -1.2442626196083388e+00 + 16 2.6517373021566168e+00 -2.3957035508393707e+00 3.3389262100692263e-02 + 17 2.2311114924744970e+00 -2.1018393228798513e+00 1.1496088522377543e+00 18 2.1390642573201784e+00 3.0164773560693781e+00 -3.5143984803853878e+00 19 1.5353246655146278e+00 2.6305911186316133e+00 -4.2455871034737074e+00 20 2.7649421538938390e+00 3.6818603528430849e+00 -3.9364115785985550e+00 @@ -46,32 +47,32 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 4.7093289825842486e-04 2.6351122778447826e-04 -4.4905093064114855e-04 - 2 4.9594625316470495e-04 9.4561370489630651e-05 -5.4581359894047721e-04 - 3 3.3306085115756092e-04 2.3224943880673270e-04 -2.3659455671746018e-04 - 4 3.3692327392261152e-04 2.1926810694051195e-04 -2.4716631558862522e-04 - 5 3.3642542694185980e-04 4.1797578013265732e-04 -1.8011341766657692e-04 - 6 2.0926869754934785e-04 2.6449308951578490e-05 -1.0508938983871839e-04 - 7 1.4629043007907975e-04 -1.6873376665350062e-04 -6.8354048774351260e-05 - 8 1.5844101624224894e-04 3.7728761274000044e-05 -1.9162715667091402e-05 - 9 2.1299362072601955e-04 1.6917140529157490e-04 -6.3528165037845781e-05 - 10 5.4261629412254793e-05 -9.4655528376811116e-05 1.0511362869146627e-04 - 11 -3.2194160796502263e-05 -2.2025095264758662e-04 2.0300202946212347e-04 - 12 1.2640586304750418e-04 -2.9851080445665042e-04 -7.9476371818246096e-05 - 13 8.4523575162143095e-05 -4.0583135407330485e-04 -4.7551111331700809e-05 - 14 9.9954050381271487e-05 -4.2610816481298213e-04 -7.9255633594379828e-05 - 15 2.4417481119789889e-04 -2.3521002264677933e-04 -2.4875318161048917e-04 - 16 -9.0958138549662281e-06 3.7774817121223831e-06 2.4035199548835009e-04 - 17 5.7507224523612284e-05 2.2629217444843761e-04 2.0686920072684746e-04 - 18 2.9220264989359801e-04 -6.2478376436796276e-04 8.4222594596602355e-04 - 19 2.0572616567799155e-04 -5.0334424271726661e-04 8.4953929443210658e-04 - 20 4.1224811789512974e-04 -7.4115205416011565e-04 8.3678612337507910e-04 - 21 -1.0671858777656390e-03 -1.1531171045499513e-03 7.3720674900162170e-04 - 22 -1.1066511338291712e-03 -1.0433933757600460e-03 7.4544544325708584e-04 - 23 -9.7629260480941536e-04 -1.3100872491594103e-03 7.2687284219704793e-04 - 24 4.3308126651259350e-04 -6.6527658087322768e-04 8.4451298670663606e-04 - 25 4.4565811905442927e-04 -5.1298436273584263e-04 8.5878867884521559e-04 - 26 5.9865972692022809e-04 -7.6385263287080348e-04 8.4259943226842155e-04 + 1 4.7093289825842508e-04 2.6351122778447809e-04 -4.4905093064114883e-04 + 2 4.9594625316470506e-04 9.4561370489630299e-05 -5.4581359894047775e-04 + 3 3.3306085115756103e-04 2.3224943880673259e-04 -2.3659455671746018e-04 + 4 3.3692327392261152e-04 2.1926810694051179e-04 -2.4716631558862516e-04 + 5 3.3642542694186002e-04 4.1797578013265738e-04 -1.8011341766657675e-04 + 6 2.0926869754934769e-04 2.6449308951578185e-05 -1.0508938983871811e-04 + 7 1.4629043007907940e-04 -1.6873376665350122e-04 -6.8354048774350921e-05 + 8 1.5844101624224881e-04 3.7728761273999780e-05 -1.9162715667090996e-05 + 9 2.1299362072601952e-04 1.6917140529157474e-04 -6.3528165037845483e-05 + 10 5.4261629412254495e-05 -9.4655528376811482e-05 1.0511362869146690e-04 + 11 -3.2194160796502724e-05 -2.2025095264758716e-04 2.0300202946212429e-04 + 12 1.2640586304750378e-04 -2.9851080445665107e-04 -7.9476371818245798e-05 + 13 8.4523575162142608e-05 -4.0583135407330561e-04 -4.7551111331700511e-05 + 14 9.9954050381270972e-05 -4.2610816481298294e-04 -7.9255633594379530e-05 + 15 2.4417481119789862e-04 -2.3521002264677992e-04 -2.4875318161048917e-04 + 16 -9.0958138549664992e-06 3.7774817121222391e-06 2.4035199548835096e-04 + 17 5.7507224523612230e-05 2.2629217444843764e-04 2.0686920072684822e-04 + 18 2.9220264989359833e-04 -6.2478376436796265e-04 8.4222594596602366e-04 + 19 2.0572616567799188e-04 -5.0334424271726639e-04 8.4953929443210648e-04 + 20 4.1224811789513022e-04 -7.4115205416011554e-04 8.3678612337507920e-04 + 21 -1.0671858777656393e-03 -1.1531171045499515e-03 7.3720674900162159e-04 + 22 -1.1066511338291710e-03 -1.0433933757600460e-03 7.4544544325708573e-04 + 23 -9.7629260480941525e-04 -1.3100872491594103e-03 7.2687284219704804e-04 + 24 4.3308126651259312e-04 -6.6527658087322801e-04 8.4451298670663606e-04 + 25 4.4565811905442889e-04 -5.1298436273584285e-04 8.5878867884521559e-04 + 26 5.9865972692022765e-04 -7.6385263287080381e-04 8.4259943226842166e-04 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_molecule.yaml b/unittest/force-styles/tests/fix-timestep-rigid_molecule.yaml index bf27b25c5d..d667942e49 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_molecule.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_molecule.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid @@ -13,7 +14,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -4.9200116134789894e+01 -2.6907707565987600e+01 -6.0080860422279923e+00 -2.5620423972101459e+01 -1.3450224059984031e+01 -1.4947288487004347e+00 + -4.9200116134789873e+01 -2.6907707565987707e+01 -6.0080860422278581e+00 -2.5620423972101300e+01 -1.3450224059983967e+01 -1.4947288487003760e+00 global_scalar: 18.3405601674144 run_pos: ! |2 1 -2.7993683669226832e-01 2.4726588069312840e+00 -1.7200860244148433e-01 @@ -63,15 +64,15 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 3.6149625095704908e-04 -3.1032459262908286e-04 8.1043030117346042e-04 + 18 3.6149625095704914e-04 -3.1032459262908286e-04 8.1043030117346052e-04 19 8.5103884665345452e-04 -1.4572280596788108e-03 1.0163621287634116e-03 - 20 -6.5204659278590683e-04 4.3989037444289853e-04 4.9909839028507890e-04 - 21 -1.3888125881903923e-03 -3.1978049143082407e-04 1.1455681499836646e-03 - 22 -1.6084223477729508e-03 -1.5355394240821113e-03 1.4772010826232373e-03 - 23 2.6392672378805081e-04 -3.9375414431174812e-03 -3.6991583139728051e-04 - 24 8.6062827067890236e-04 -9.4179873474469237e-04 5.5396395550012442e-04 - 25 1.5933645477487542e-03 -2.2139156625681699e-03 -5.5078029695647488e-04 - 26 -1.5679561743998840e-03 3.5146224354726122e-04 2.4446924193334474e-03 + 20 -6.5204659278590683e-04 4.3989037444289853e-04 4.9909839028507901e-04 + 21 -1.3888125881903923e-03 -3.1978049143082385e-04 1.1455681499836646e-03 + 22 -1.6084223477729510e-03 -1.5355394240821117e-03 1.4772010826232375e-03 + 23 2.6392672378805124e-04 -3.9375414431174821e-03 -3.6991583139728095e-04 + 24 8.6062827067890247e-04 -9.4179873474469237e-04 5.5396395550012453e-04 + 25 1.5933645477487538e-03 -2.2139156625681695e-03 -5.5078029695647401e-04 + 26 -1.5679561743998840e-03 3.5146224354726100e-04 2.4446924193334478e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_molecule_tri.yaml b/unittest/force-styles/tests/fix-timestep-rigid_molecule_tri.yaml index 3a3f0cd59a..304db9fd60 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_molecule_tri.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_molecule_tri.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full fix rigid @@ -14,8 +15,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -4.9200116134788829e+01 -2.6907707565985422e+01 -6.0080860422273261e+00 -2.5620423972099612e+01 -1.3450224059983762e+01 -1.4947288487001149e+00 -global_scalar: 18.3405601674143 + -4.9200116134788658e+01 -2.6907707565985344e+01 -6.0080860422268874e+00 -2.5620423972099733e+01 -1.3450224059983656e+01 -1.4947288487000705e+00 +global_scalar: 18.340560167414306 run_pos: ! |2 1 -2.7993683669226854e-01 2.4726588069312836e+00 -1.7200860244148508e-01 2 3.0197083955402171e-01 2.9515239068888608e+00 -8.5689735572907555e-01 @@ -38,7 +39,7 @@ run_pos: ! |2 19 1.5366124997074566e+00 2.6286809834111740e+00 -4.2452547844370239e+00 20 2.7628161763455852e+00 3.6842251687634775e+00 -3.9370881219352558e+00 21 4.9036621347791245e+00 -4.0757648442838557e+00 -3.6192617654515900e+00 - 22 4.3655322291888483e+00 -4.2084949965552569e+00 -4.4622011117402334e+00 + 22 4.3655322291888465e+00 -4.2084949965552569e+00 -4.4622011117402334e+00 23 5.7380414793463101e+00 -3.5841969195032686e+00 -3.8827839830470232e+00 24 2.0701314765323913e+00 3.1499370533342308e+00 3.1565324852522920e+00 25 1.3030170721374770e+00 3.2711173927682236e+00 2.5081940917429755e+00 @@ -64,14 +65,14 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 3.6149625095704670e-04 -3.1032459262907857e-04 8.1043030117346052e-04 - 19 8.5103884665345799e-04 -1.4572280596788108e-03 1.0163621287634071e-03 - 20 -6.5204659278590292e-04 4.3989037444289630e-04 4.9909839028508204e-04 - 21 -1.3888125881903854e-03 -3.1978049143082060e-04 1.1455681499836594e-03 - 22 -1.6084223477729519e-03 -1.5355394240820970e-03 1.4772010826232353e-03 - 23 2.6392672378803975e-04 -3.9375414431174552e-03 -3.6991583139727889e-04 - 24 8.6062827067889835e-04 -9.4179873474469346e-04 5.5396395550012497e-04 - 25 1.5933645477487516e-03 -2.2139156625681669e-03 -5.5078029695647564e-04 + 18 3.6149625095704681e-04 -3.1032459262907857e-04 8.1043030117346074e-04 + 19 8.5103884665345820e-04 -1.4572280596788108e-03 1.0163621287634073e-03 + 20 -6.5204659278590271e-04 4.3989037444289630e-04 4.9909839028508215e-04 + 21 -1.3888125881903852e-03 -3.1978049143082049e-04 1.1455681499836594e-03 + 22 -1.6084223477729513e-03 -1.5355394240820970e-03 1.4772010826232351e-03 + 23 2.6392672378803975e-04 -3.9375414431174569e-03 -3.6991583139727910e-04 + 24 8.6062827067889835e-04 -9.4179873474469346e-04 5.5396395550012518e-04 + 25 1.5933645477487516e-03 -2.2139156625681669e-03 -5.5078029695647542e-04 26 -1.5679561743998831e-03 3.5146224354726187e-04 2.4446924193334495e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_nph.yaml b/unittest/force-styles/tests/fix-timestep-rigid_nph.yaml index 4b4f53b240..c80a70b428 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_nph.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_nph.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/nph @@ -13,8 +14,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |2- - 4.3578059172167876e+01 1.7275105166465064e+01 6.7372361276630770e+01 5.1985075049901859e+01 -2.0990677389800858e+01 -7.5321398101845993e+00 -global_scalar: 29.023636440848 + 4.3578059172167876e+01 1.7275105166465000e+01 6.7372361276631054e+01 5.1985075049901745e+01 -2.0990677389800993e+01 -7.5321398101844359e+00 +global_scalar: 29.023636440847998 run_pos: ! |2 1 -6.3472039825517168e-01 3.0113983126282058e+00 -8.8148450172235826e-02 2 6.4798884173500326e-02 3.5870486860057795e+00 -9.1146271255434463e-01 @@ -63,15 +64,15 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 3.0094600491564739e-04 -2.4312792027781274e-04 6.5542049134062323e-04 - 19 7.4731683462770054e-04 -1.2894119671278408e-03 8.4327024053533386e-04 - 20 -6.2333686369976584e-04 4.4115361641690066e-04 3.7135656431834237e-04 - 21 -1.1457423793218525e-03 -1.7337748161437973e-04 9.4510018429417686e-04 - 22 -1.3457150581639319e-03 -1.2816797357047460e-03 1.2470992250388101e-03 - 23 3.6277645415306540e-04 -3.4719859048227848e-03 -4.3796817853449140e-04 - 24 7.2410992462873655e-04 -7.6012809744767037e-04 4.3327155128124932e-04 - 25 1.3921349892629666e-03 -1.9207002802664867e-03 -5.7453335109528100e-04 - 26 -1.4901465947638008e-03 4.2012923457099966e-04 2.1578545404178414e-03 + 18 3.0094600491564739e-04 -2.4312792027781263e-04 6.5542049134062323e-04 + 19 7.4731683462770076e-04 -1.2894119671278408e-03 8.4327024053533397e-04 + 20 -6.2333686369976551e-04 4.4115361641690044e-04 3.7135656431834220e-04 + 21 -1.1457423793218525e-03 -1.7337748161437940e-04 9.4510018429417686e-04 + 22 -1.3457150581639313e-03 -1.2816797357047471e-03 1.2470992250388096e-03 + 23 3.6277645415306518e-04 -3.4719859048227848e-03 -4.3796817853449118e-04 + 24 7.2410992462873655e-04 -7.6012809744767037e-04 4.3327155128124943e-04 + 25 1.3921349892629666e-03 -1.9207002802664867e-03 -5.7453335109528090e-04 + 26 -1.4901465947638008e-03 4.2012923457099966e-04 2.1578545404178418e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_nph_small.yaml b/unittest/force-styles/tests/fix-timestep-rigid_nph_small.yaml index 6a7fa3c8a5..3894815950 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_nph_small.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_nph_small.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 6.5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/nph/small @@ -13,7 +14,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |2- - 2.7340318973870428e+01 4.7963870091858531e+00 6.8884396847592484e+01 2.9853310007358978e+01 -1.0857139901347637e+01 -5.1889756561453346e+00 + 2.7340318973870396e+01 4.7963870091858283e+00 6.8884396847592512e+01 2.9853310007358935e+01 -1.0857139901347722e+01 -5.1889756561454785e+00 global_scalar: 9.77678786310451 run_pos: ! |2 1 -5.1121862036604515e-01 2.8134872171079977e+00 -4.8993015395518924e-02 @@ -63,15 +64,15 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 3.1638284997073288e-04 -2.6313163919070400e-04 6.1054395248656961e-04 - 19 7.6494647252307629e-04 -1.3190724749214317e-03 7.9947132612985744e-04 - 20 -6.1620104632513885e-04 4.2577138774295257e-04 3.2526261653548683e-04 - 21 -1.2063428871524097e-03 -2.2879409878999576e-04 8.9132836538734455e-04 - 22 -1.4151473871894464e-03 -1.3502255393198256e-03 1.1972773109437851e-03 - 23 3.1280366109607172e-04 -3.5563936893394407e-03 -4.9548546532774947e-04 - 24 7.5594375541558048e-04 -8.1321043994394464e-04 3.9340911295780760e-04 - 25 1.4373446731689036e-03 -1.9778020567486213e-03 -6.1842201918304457e-04 - 26 -1.4806168650325995e-03 3.7766934274110835e-04 2.1280924225288347e-03 + 18 3.1638284997073272e-04 -2.6313163919070405e-04 6.1054395248656961e-04 + 19 7.6494647252307673e-04 -1.3190724749214326e-03 7.9947132612985723e-04 + 20 -6.1620104632513929e-04 4.2577138774295274e-04 3.2526261653548693e-04 + 21 -1.2063428871524097e-03 -2.2879409878999576e-04 8.9132836538734445e-04 + 22 -1.4151473871894464e-03 -1.3502255393198256e-03 1.1972773109437849e-03 + 23 3.1280366109607172e-04 -3.5563936893394407e-03 -4.9548546532774958e-04 + 24 7.5594375541558026e-04 -8.1321043994394464e-04 3.9340911295780739e-04 + 25 1.4373446731689036e-03 -1.9778020567486213e-03 -6.1842201918304478e-04 + 26 -1.4806168650325999e-03 3.7766934274110835e-04 2.1280924225288342e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_npt.yaml b/unittest/force-styles/tests/fix-timestep-rigid_npt.yaml index 2b1fbc73b5..f5965e53ff 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_npt.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_npt.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/npt @@ -12,8 +13,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -1.6326314448663304e+03 -1.4727331978532306e+03 -3.8557370515932275e+03 5.5052891601644728e+02 4.7346742977310510e+02 -6.2035591882122242e+02 -global_scalar: 106.866830724741 + -1.6326314448663306e+03 -1.4727331978532295e+03 -3.8557370515932275e+03 5.5052891601644615e+02 4.7346742977310657e+02 -6.2035591882122355e+02 +global_scalar: 106.86683072474125 run_pos: ! |2 1 -2.6314711410922875e-01 2.4664715027241684e+00 -1.7093568570875561e-01 2 3.1632911015968190e-01 2.9434731493852482e+00 -8.5432214735778889e-01 @@ -27,7 +28,7 @@ run_pos: ! |2 10 2.0239883243193546e+00 -1.4252201368162511e+00 -9.6228264545891751e-01 11 1.7991233925769246e+00 -1.9828365722517098e+00 -1.8762366544355809e+00 12 3.0044710092992837e+00 -4.8928363303895761e-01 -1.6126944183951402e+00 - 13 4.0415308387392486e+00 -9.0061411581930262e-01 -1.6321139880363669e+00 + 13 4.0415308387392486e+00 -9.0061411581930262e-01 -1.6321139880363660e+00 14 2.6064005411338655e+00 -4.0859653026870735e-01 -2.6465043951812621e+00 15 2.9775904824773907e+00 5.6065407887877150e-01 -1.2391617757503752e+00 16 2.6542663248057963e+00 -2.3895844048756363e+00 3.5746598094128501e-02 @@ -45,32 +46,32 @@ run_pos: ! |2 28 -2.6026086128772454e+00 -3.9329047688996304e+00 1.5399898445636406e+00 29 -1.2195954744860957e+00 -3.5211468177700818e+00 2.2116264666073615e+00 run_vel: ! |2 - 1 1.2393084479630032e-03 7.0215195817154908e-04 -1.1910956210640377e-03 - 2 1.3060936199988530e-03 2.5041119719347138e-04 -1.4496302699051106e-03 - 3 8.7069732478159932e-04 6.1866591813748793e-04 -6.2317312592554438e-04 - 4 8.8100215742025042e-04 5.8380213791515870e-04 -6.5145037264846355e-04 - 5 8.7979303397991721e-04 1.1152950208762108e-03 -4.7231382224758082e-04 - 6 5.3965146863311749e-04 6.8643008418756997e-05 -2.7149223435848598e-04 - 7 3.7117679682181569e-04 -4.5322194777211666e-04 -1.7317402888850959e-04 - 8 4.0378854177636355e-04 9.9015358993666161e-05 -4.1783685861269487e-05 - 9 5.4970639315540587e-04 4.5048022318729201e-04 -1.6045108899919846e-04 - 10 1.2521448037946088e-04 -2.5472783650533852e-04 2.9052485920877543e-04 - 11 -1.0599027352488030e-04 -5.9051612835384288e-04 5.5226010155799091e-04 - 12 3.1798607399623077e-04 -7.9980833669012060e-04 -2.0274707260294395e-04 - 13 2.0597404142686724e-04 -1.0865778699535142e-03 -1.1731137935659032e-04 - 14 2.4719215573349167e-04 -1.1410575874168849e-03 -2.0209037936298269e-04 - 15 6.3286464043726856e-04 -6.3068988069288280e-04 -6.5527927471360488e-04 - 16 -4.4100406048952316e-05 8.6869240444182845e-06 6.5198761255923058e-04 - 17 1.3407421346950843e-04 6.0357565278263792e-04 5.6233596575975002e-04 - 18 7.9277804690569055e-04 -1.5618239874425177e-03 2.1367192719678593e-03 - 19 5.6167660797942721e-04 -1.2371794194922850e-03 2.1562222137424718e-03 - 20 1.1137406410123482e-03 -1.8729421751430327e-03 2.1222207985340819e-03 - 21 -2.8426953558137735e-03 -2.9730185469781377e-03 1.8564402246257746e-03 - 22 -2.9480844379790160e-03 -2.6797216173769355e-03 1.8784164631754769e-03 - 23 -2.5997293519674954e-03 -3.3926375081633348e-03 1.8288830284141457e-03 - 24 1.1689404599043950e-03 -1.6701257754515664e-03 2.1428138286394673e-03 + 1 1.2393084479630034e-03 7.0215195817155049e-04 -1.1910956210640397e-03 + 2 1.3060936199988536e-03 2.5041119719347224e-04 -1.4496302699051125e-03 + 3 8.7069732478159932e-04 6.1866591813748923e-04 -6.2317312592554579e-04 + 4 8.8100215742025064e-04 5.8380213791516000e-04 -6.5145037264846529e-04 + 5 8.7979303397991678e-04 1.1152950208762130e-03 -4.7231382224758212e-04 + 6 5.3965146863311727e-04 6.8643008418757634e-05 -2.7149223435848658e-04 + 7 3.7117679682181569e-04 -4.5322194777211656e-04 -1.7317402888851005e-04 + 8 4.0378854177636284e-04 9.9015358993666757e-05 -4.1783685861269460e-05 + 9 5.4970639315540500e-04 4.5048022318729304e-04 -1.6045108899919851e-04 + 10 1.2521448037945991e-04 -2.5472783650533836e-04 2.9052485920877619e-04 + 11 -1.0599027352488127e-04 -5.9051612835384309e-04 5.5226010155799178e-04 + 12 3.1798607399623040e-04 -7.9980833669012115e-04 -2.0274707260294341e-04 + 13 2.0597404142686670e-04 -1.0865778699535151e-03 -1.1731137935658918e-04 + 14 2.4719215573349161e-04 -1.1410575874168858e-03 -2.0209037936298231e-04 + 15 6.3286464043726845e-04 -6.3068988069288313e-04 -6.5527927471360488e-04 + 16 -4.4100406048953834e-05 8.6869240444187047e-06 6.5198761255923199e-04 + 17 1.3407421346950653e-04 6.0357565278263911e-04 5.6233596575975121e-04 + 18 7.9277804690569076e-04 -1.5618239874425175e-03 2.1367192719678593e-03 + 19 5.6167660797942776e-04 -1.2371794194922848e-03 2.1562222137424714e-03 + 20 1.1137406410123489e-03 -1.8729421751430327e-03 2.1222207985340819e-03 + 21 -2.8426953558137740e-03 -2.9730185469781381e-03 1.8564402246257748e-03 + 22 -2.9480844379790165e-03 -2.6797216173769360e-03 1.8784164631754769e-03 + 23 -2.5997293519674958e-03 -3.3926375081633348e-03 1.8288830284141459e-03 + 24 1.1689404599043950e-03 -1.6701257754515662e-03 2.1428138286394673e-03 25 1.2027302640333160e-03 -1.2630861421196525e-03 2.1808987508670514e-03 - 26 1.6116362268906777e-03 -1.9337182438138849e-03 2.1377249582867847e-03 + 26 1.6116362268906780e-03 -1.9337182438138849e-03 2.1377249582867843e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_npt_small.yaml b/unittest/force-styles/tests/fix-timestep-rigid_npt_small.yaml index 008499c206..3b13658e19 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_npt_small.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_npt_small.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/npt/small @@ -12,8 +13,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -8.7531774769722233e+01 5.5811525017967618e+00 -5.5468297744356789e+01 -1.5316306343483367e+02 1.4641268097314369e+02 1.7263710089631282e+01 -global_scalar: 77.7898343029329 + -8.7531774769722489e+01 5.5811525017966304e+00 -5.5468297744356747e+01 -1.5316306343483370e+02 1.4641268097314367e+02 1.7263710089631324e+01 +global_scalar: 77.78983430293286 run_pos: ! |2 1 -4.6333219629007161e-01 2.7511450055070625e+00 -1.2865946102806269e-01 2 1.7937148390204793e-01 3.2800405238539234e+00 -8.8510337855738808e-01 @@ -62,15 +63,15 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 7.2384391131466962e-04 -6.0015829212802744e-04 1.5957533238990557e-03 - 19 1.7583138222551382e-03 -3.0158245948490800e-03 2.0310435058142466e-03 - 20 -1.4153552732353322e-03 9.7835305930749246e-04 9.3881222516217452e-04 + 18 7.2384391131466940e-04 -6.0015829212802722e-04 1.5957533238990559e-03 + 19 1.7583138222551384e-03 -3.0158245948490804e-03 2.0310435058142470e-03 + 20 -1.4153552732353322e-03 9.7835305930749246e-04 9.3881222516217474e-04 21 -2.7591188772323472e-03 -5.1180650802276303e-04 2.2758295071994400e-03 22 -3.2319732401280494e-03 -3.0809796427949646e-03 2.9861065768383484e-03 23 6.9767443123301817e-04 -8.1543313142268207e-03 -8.9929522742256325e-04 - 24 1.7345816999787503e-03 -1.8508160062822960e-03 1.0723416147087285e-03 - 25 3.2855417755407170e-03 -4.5284294762327620e-03 -1.2529299007822620e-03 - 26 -3.4004728795728927e-03 8.5952140737749570e-04 5.0505027847540657e-03 + 24 1.7345816999787505e-03 -1.8508160062822962e-03 1.0723416147087287e-03 + 25 3.2855417755407162e-03 -4.5284294762327620e-03 -1.2529299007822618e-03 + 26 -3.4004728795728936e-03 8.5952140737749613e-04 5.0505027847540665e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_nve_group.yaml b/unittest/force-styles/tests/fix-timestep-rigid_nve_group.yaml index a78dd6c421..b20d639fd4 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_nve_group.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_nve_group.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/nve @@ -13,8 +14,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -1.4245356938011612e+03 -1.4496493316650422e+03 -3.6144360982532016e+03 8.4840626794792297e+02 2.0318336802442892e+02 -6.0622397695978816e+02 -global_scalar: 15.7115214231781 + -1.4245356938011610e+03 -1.4496493316650424e+03 -3.6144360982532016e+03 8.4840626794792252e+02 2.0318336802442886e+02 -6.0622397695978805e+02 +global_scalar: 15.711521423178128 run_pos: ! |2 1 -2.7899546863905123e-01 2.4731857340327181e+00 -1.7290667740231969e-01 2 3.0296221610252227e-01 2.9517129916957194e+00 -8.5798904387756503e-01 @@ -46,32 +47,32 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 4.7093289825841293e-04 2.6351122778450878e-04 -4.4905093064113820e-04 - 2 4.9594625316469953e-04 9.4561370489667690e-05 -5.4581359894048231e-04 - 3 3.3306085115754900e-04 2.3224943880673573e-04 -2.3659455671744771e-04 - 4 3.3692327392259743e-04 2.1926810694050262e-04 -2.4716631558861427e-04 - 5 3.3642542694184180e-04 4.1797578013266394e-04 -1.8011341766654835e-04 - 6 2.0926869754934465e-04 2.6449308951570318e-05 -1.0508938983871884e-04 - 7 1.4629043007908249e-04 -1.6873376665352393e-04 -6.8354048774366371e-05 - 8 1.5844101624224789e-04 3.7728761273996988e-05 -1.9162715667088746e-05 - 9 2.1299362072601516e-04 1.6917140529158729e-04 -6.3528165037833679e-05 - 10 5.4261629412260051e-05 -9.4655528376821931e-05 1.0511362869146147e-04 - 11 -3.2194160796493915e-05 -2.2025095264761762e-04 2.0300202946211090e-04 - 12 1.2640586304751801e-04 -2.9851080445664316e-04 -7.9476371818270898e-05 - 13 8.4523575162162963e-05 -4.0583135407329249e-04 -4.7551111331733104e-05 - 14 9.9954050381287994e-05 -4.2610816481298853e-04 -7.9255633594414862e-05 - 15 2.4417481119791065e-04 -2.3521002264675271e-04 -2.4875318161051281e-04 - 16 -9.0958138549621353e-06 3.7774817121143600e-06 2.4035199548835649e-04 - 17 5.7507224523608761e-05 2.2629217444844084e-04 2.0686920072687044e-04 - 18 2.9220264989358500e-04 -6.2478376436791039e-04 8.4222594596602756e-04 - 19 2.0572616567796797e-04 -5.0334424271721316e-04 8.4953929443210886e-04 - 20 4.1224811789512605e-04 -7.4115205416005038e-04 8.3678612337508614e-04 - 21 -1.0671858777656232e-03 -1.1531171045500114e-03 7.3720674900161617e-04 - 22 -1.1066511338291647e-03 -1.0433933757601002e-03 7.4544544325707944e-04 - 23 -9.7629260480938673e-04 -1.3100872491594617e-03 7.2687284219704544e-04 - 24 4.3308126651259079e-04 -6.6527658087322801e-04 8.4451298670663660e-04 - 25 4.4565811905441442e-04 -5.1298436273583461e-04 8.5878867884521515e-04 - 26 5.9865972692023438e-04 -7.6385263287079188e-04 8.4259943226842502e-04 + 1 4.7093289825841293e-04 2.6351122778450888e-04 -4.4905093064113717e-04 + 2 4.9594625316469964e-04 9.4561370489668111e-05 -5.4581359894048111e-04 + 3 3.3306085115754910e-04 2.3224943880673595e-04 -2.3659455671744723e-04 + 4 3.3692327392259764e-04 2.1926810694050300e-04 -2.4716631558861373e-04 + 5 3.3642542694184180e-04 4.1797578013266372e-04 -1.8011341766654800e-04 + 6 2.0926869754934492e-04 2.6449308951570887e-05 -1.0508938983871866e-04 + 7 1.4629043007908284e-04 -1.6873376665352296e-04 -6.8354048774366290e-05 + 8 1.5844101624224813e-04 3.7728761273997381e-05 -1.9162715667088780e-05 + 9 2.1299362072601532e-04 1.6917140529158732e-04 -6.3528165037833598e-05 + 10 5.4261629412260376e-05 -9.4655528376821362e-05 1.0511362869146115e-04 + 11 -3.2194160796493454e-05 -2.2025095264761673e-04 2.0300202946211041e-04 + 12 1.2640586304751833e-04 -2.9851080445664229e-04 -7.9476371818270762e-05 + 13 8.4523575162163329e-05 -4.0583135407329152e-04 -4.7551111331733064e-05 + 14 9.9954050381288400e-05 -4.2610816481298728e-04 -7.9255633594414740e-05 + 15 2.4417481119791087e-04 -2.3521002264675206e-04 -2.4875318161051227e-04 + 16 -9.0958138549618100e-06 3.7774817121146141e-06 2.4035199548835590e-04 + 17 5.7507224523608950e-05 2.2629217444844056e-04 2.0686920072686990e-04 + 18 2.9220264989358538e-04 -6.2478376436791018e-04 8.4222594596602778e-04 + 19 2.0572616567796829e-04 -5.0334424271721273e-04 8.4953929443210897e-04 + 20 4.1224811789512659e-04 -7.4115205416005016e-04 8.3678612337508636e-04 + 21 -1.0671858777656236e-03 -1.1531171045500116e-03 7.3720674900161585e-04 + 22 -1.1066511338291651e-03 -1.0433933757601002e-03 7.4544544325707912e-04 + 23 -9.7629260480938717e-04 -1.3100872491594619e-03 7.2687284219704522e-04 + 24 4.3308126651259090e-04 -6.6527658087322823e-04 8.4451298670663681e-04 + 25 4.4565811905441464e-04 -5.1298436273583472e-04 8.5878867884521526e-04 + 26 5.9865972692023459e-04 -7.6385263287079232e-04 8.4259943226842524e-04 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_nve_molecule.yaml b/unittest/force-styles/tests/fix-timestep-rigid_nve_molecule.yaml index 32a3f6af71..839ac060a5 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_nve_molecule.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_nve_molecule.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/nve @@ -13,8 +14,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -4.9200114774917928e+01 -2.6907707694141234e+01 -6.0080872444876876e+00 -2.5620425756344922e+01 -1.3450222538011758e+01 -1.4947348732783965e+00 -global_scalar: 18.3405601673644 + -4.9200114774918006e+01 -2.6907707694141354e+01 -6.0080872444875970e+00 -2.5620425756344780e+01 -1.3450222538011893e+01 -1.4947348732785031e+00 +global_scalar: 18.340560167364448 run_pos: ! |2 1 -2.7993683669226832e-01 2.4726588069312840e+00 -1.7200860244148433e-01 2 3.0197083955402204e-01 2.9515239068888608e+00 -8.5689735572907566e-01 @@ -63,15 +64,15 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 3.6149625094898083e-04 -3.1032459262177046e-04 8.1043030117471950e-04 - 19 8.5103884664914189e-04 -1.4572280597118458e-03 1.0163621287571445e-03 - 20 -6.5204659274939046e-04 4.3989037444674766e-04 4.9909839028631543e-04 - 21 -1.3888125888095134e-03 -3.1978049191290828e-04 1.1455681505629727e-03 - 22 -1.6084223473476298e-03 -1.5355394235202365e-03 1.4772010819351848e-03 - 23 2.6392672583440695e-04 -3.9375414417551127e-03 -3.6991583302200246e-04 - 24 8.6062827046548757e-04 -9.4179873487668705e-04 5.5396395555797225e-04 - 25 1.5933645478462869e-03 -2.2139156628290971e-03 -5.5078029723781006e-04 - 26 -1.5679561736454228e-03 3.5146224433513598e-04 2.4446924193838983e-03 + 18 3.6149625094898067e-04 -3.1032459262177040e-04 8.1043030117471950e-04 + 19 8.5103884664914254e-04 -1.4572280597118469e-03 1.0163621287571445e-03 + 20 -6.5204659274939057e-04 4.3989037444674739e-04 4.9909839028631532e-04 + 21 -1.3888125888095134e-03 -3.1978049191290817e-04 1.1455681505629727e-03 + 22 -1.6084223473476296e-03 -1.5355394235202363e-03 1.4772010819351844e-03 + 23 2.6392672583440717e-04 -3.9375414417551127e-03 -3.6991583302200246e-04 + 24 8.6062827046548790e-04 -9.4179873487668705e-04 5.5396395555797203e-04 + 25 1.5933645478462865e-03 -2.2139156628290975e-03 -5.5078029723780941e-04 + 26 -1.5679561736454237e-03 3.5146224433513641e-04 2.4446924193838983e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_nve_single.yaml b/unittest/force-styles/tests/fix-timestep-rigid_nve_single.yaml index 85aa11e3e0..854e8b4d45 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_nve_single.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_nve_single.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/nve @@ -13,8 +14,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -1.3754817467882772e+03 -1.4228425246441275e+03 -3.6087196200592480e+03 8.7407043142559348e+02 2.1665316510426322e+02 -6.0480791467747576e+02 -global_scalar: 4.53142303857033 + -1.3754817467882767e+03 -1.4228425246441275e+03 -3.6087196200592489e+03 8.7407043142559303e+02 2.1665316510426268e+02 -6.0480791467747542e+02 +global_scalar: 4.531423038570333 run_pos: ! |2 1 -2.7899546859706881e-01 2.4731857340427750e+00 -1.7290667720866193e-01 2 3.0296221616781649e-01 2.9517129917211218e+00 -8.5798904365338713e-01 @@ -46,23 +47,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 4.7093296226164512e-04 2.6351124312060207e-04 -4.4905063547613525e-04 - 2 4.9594635271876732e-04 9.4561409237174874e-05 -5.4581325723053746e-04 - 3 3.3306088119081914e-04 2.3224949911015690e-04 -2.3659435306899615e-04 - 4 3.3692332940285356e-04 2.1926824120528714e-04 -2.4716611858555419e-04 - 5 3.3642541894622217e-04 4.1797578053944228e-04 -1.8011323945926297e-04 - 6 2.0926870695908053e-04 2.6449376032433595e-05 -1.0508922741401471e-04 - 7 1.4629046128363337e-04 -1.6873362379725315e-04 -6.8353900724086707e-05 - 8 1.5844098346817900e-04 3.7728756087615784e-05 -1.9162577392846985e-05 - 9 2.1299357198252555e-04 1.6917133003967901e-04 -6.3528006071188276e-05 - 10 5.4261569071252172e-05 -9.4655546204709209e-05 1.0511372702289220e-04 - 11 -3.2194218121513158e-05 -2.2025090185605299e-04 2.0300208519291455e-04 - 12 1.2640585449265077e-04 -2.9851081600945932e-04 -7.9476186245599193e-05 - 13 8.4523551795123811e-05 -4.0583140303606844e-04 -4.7550925831962043e-05 - 14 9.9954071734182138e-05 -4.2610809338914323e-04 -7.9255453072695788e-05 - 15 2.4417483202631259e-04 -2.3521005781666340e-04 -2.4875292755154174e-04 - 16 -9.0959360838789561e-06 3.7773746063112143e-06 2.4035204669043016e-04 - 17 5.7507084250803752e-05 2.2629200960629542e-04 2.0686926033796743e-04 + 1 4.7093296226164550e-04 2.6351124312060223e-04 -4.4905063547613568e-04 + 2 4.9594635271876775e-04 9.4561409237174846e-05 -5.4581325723053790e-04 + 3 3.3306088119081919e-04 2.3224949911015709e-04 -2.3659435306899653e-04 + 4 3.3692332940285361e-04 2.1926824120528752e-04 -2.4716611858555457e-04 + 5 3.3642541894622217e-04 4.1797578053944250e-04 -1.8011323945926332e-04 + 6 2.0926870695908031e-04 2.6449376032433555e-05 -1.0508922741401509e-04 + 7 1.4629046128363305e-04 -1.6873362379725323e-04 -6.8353900724087087e-05 + 8 1.5844098346817862e-04 3.7728756087615553e-05 -1.9162577392847385e-05 + 9 2.1299357198252531e-04 1.6917133003967874e-04 -6.3528006071188683e-05 + 10 5.4261569071251603e-05 -9.4655546204709643e-05 1.0511372702289179e-04 + 11 -3.2194218121513917e-05 -2.2025090185605342e-04 2.0300208519291412e-04 + 12 1.2640585449265036e-04 -2.9851081600945991e-04 -7.9476186245599681e-05 + 13 8.4523551795123310e-05 -4.0583140303606936e-04 -4.7550925831962545e-05 + 14 9.9954071734181717e-05 -4.2610809338914382e-04 -7.9255453072696249e-05 + 15 2.4417483202631243e-04 -2.3521005781666407e-04 -2.4875292755154228e-04 + 16 -9.0959360838797421e-06 3.7773746063106756e-06 2.4035204669042973e-04 + 17 5.7507084250803101e-05 2.2629200960629499e-04 2.0686926033796699e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_nve_small.yaml b/unittest/force-styles/tests/fix-timestep-rigid_nve_small.yaml index 87655f456b..664921b147 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_nve_small.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_nve_small.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/nve/small @@ -13,8 +14,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -4.9200114774917928e+01 -2.6907707694141234e+01 -6.0080872444876876e+00 -2.5620425756344922e+01 -1.3450222538011758e+01 -1.4947348732783965e+00 -global_scalar: 0.50073187196632 + -4.9200114774918006e+01 -2.6907707694141354e+01 -6.0080872444875970e+00 -2.5620425756344780e+01 -1.3450222538011893e+01 -1.4947348732785031e+00 +global_scalar: 0.5007318719663203 run_pos: ! |2 1 -2.7993683669226832e-01 2.4726588069312840e+00 -1.7200860244148433e-01 2 3.0197083955402204e-01 2.9515239068888608e+00 -8.5689735572907566e-01 @@ -63,15 +64,15 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 3.6149625094898083e-04 -3.1032459262177046e-04 8.1043030117471950e-04 - 19 8.5103884664914189e-04 -1.4572280597118458e-03 1.0163621287571445e-03 - 20 -6.5204659274939046e-04 4.3989037444674766e-04 4.9909839028631543e-04 - 21 -1.3888125888095134e-03 -3.1978049191290828e-04 1.1455681505629727e-03 - 22 -1.6084223473476298e-03 -1.5355394235202365e-03 1.4772010819351848e-03 - 23 2.6392672583440695e-04 -3.9375414417551127e-03 -3.6991583302200246e-04 - 24 8.6062827046548757e-04 -9.4179873487668705e-04 5.5396395555797225e-04 - 25 1.5933645478462869e-03 -2.2139156628290971e-03 -5.5078029723781006e-04 - 26 -1.5679561736454228e-03 3.5146224433513598e-04 2.4446924193838983e-03 + 18 3.6149625094898067e-04 -3.1032459262177040e-04 8.1043030117471950e-04 + 19 8.5103884664914254e-04 -1.4572280597118469e-03 1.0163621287571445e-03 + 20 -6.5204659274939057e-04 4.3989037444674739e-04 4.9909839028631532e-04 + 21 -1.3888125888095134e-03 -3.1978049191290817e-04 1.1455681505629727e-03 + 22 -1.6084223473476296e-03 -1.5355394235202363e-03 1.4772010819351844e-03 + 23 2.6392672583440717e-04 -3.9375414417551127e-03 -3.6991583302200246e-04 + 24 8.6062827046548790e-04 -9.4179873487668705e-04 5.5396395555797203e-04 + 25 1.5933645478462865e-03 -2.2139156628290975e-03 -5.5078029723780941e-04 + 26 -1.5679561736454237e-03 3.5146224433513641e-04 2.4446924193838983e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_nvt.yaml b/unittest/force-styles/tests/fix-timestep-rigid_nvt.yaml index be224eb6ad..a49508ca15 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_nvt.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_nvt.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/nvt @@ -12,8 +13,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -1.3123962047757550e+03 -1.3675423591710455e+03 -3.5468492999583855e+03 7.8271738572396384e+02 2.6480486115495091e+02 -7.6950536863736306e+02 -global_scalar: 68.0865964742317 + -1.3123962047757550e+03 -1.3675423591710460e+03 -3.5468492999583855e+03 7.8271738572396373e+02 2.6480486115495069e+02 -7.6950536863736306e+02 +global_scalar: 68.08659647423171 run_pos: ! |2 1 -2.7802951913990959e-01 2.4737132264311215e+00 -1.7381271738602289e-01 2 3.0397800832473609e-01 2.9519031941431444e+00 -8.5908822750267100e-01 @@ -45,23 +46,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 1.8443993556501194e-03 1.0121779580014880e-03 -1.7361326034900004e-03 - 2 1.9401022924558353e-03 3.6428754787592717e-04 -2.1069540627804630e-03 - 3 1.3158623602983117e-03 8.9265747656461518e-04 -9.2144725682164765e-04 - 4 1.3306255280096098e-03 8.4281508655990065e-04 -9.6194026572564277e-04 - 5 1.3289682243410694e-03 1.6048237018834058e-03 -7.0511232123071578e-04 - 6 8.4113718611833759e-04 1.0389683283144291e-04 -4.1697370456874000e-04 - 7 5.9950574545626460e-04 -6.4437674895215539e-04 -2.7586696717582770e-04 - 8 6.4634547270651889e-04 1.4734228826522393e-04 -8.7540766366731677e-05 - 9 8.5561404484505246e-04 6.5123532540337949e-04 -2.5782947158524541e-04 - 10 2.4688038968480883e-04 -3.5995975344065598e-04 3.8912416843275036e-04 - 11 -8.4672359473207540e-05 -8.4134349031640384e-04 7.6463157764214765e-04 - 12 5.2321633256319677e-04 -1.1418047427480885e-03 -3.1842516233562650e-04 - 13 3.6258187754908706e-04 -1.5531581259494627e-03 -1.9590476904013686e-04 - 14 4.2166181631324295e-04 -1.6310415916630534e-03 -3.1740232809360442e-04 - 15 9.7471807923383419e-04 -8.9939841790992849e-04 -9.6757308853409715e-04 - 16 4.1534888649229478e-06 1.7705740202855492e-05 9.0753010117813307e-04 - 17 2.5969943716026037e-04 8.7075266710270329e-04 7.7887058799645153e-04 + 1 1.8443993556501188e-03 1.0121779580014884e-03 -1.7361326034900006e-03 + 2 1.9401022924558343e-03 3.6428754787592733e-04 -2.1069540627804634e-03 + 3 1.3158623602983108e-03 8.9265747656461540e-04 -9.2144725682164657e-04 + 4 1.3306255280096089e-03 8.4281508655990054e-04 -9.6194026572564146e-04 + 5 1.3289682243410692e-03 1.6048237018834067e-03 -7.0511232123071470e-04 + 6 8.4113718611833661e-04 1.0389683283144290e-04 -4.1697370456873913e-04 + 7 5.9950574545626287e-04 -6.4437674895215604e-04 -2.7586696717582678e-04 + 8 6.4634547270651834e-04 1.4734228826522431e-04 -8.7540766366730972e-05 + 9 8.5561404484505246e-04 6.5123532540338036e-04 -2.5782947158524498e-04 + 10 2.4688038968480818e-04 -3.5995975344065565e-04 3.8912416843275122e-04 + 11 -8.4672359473208624e-05 -8.4134349031640394e-04 7.6463157764214873e-04 + 12 5.2321633256319569e-04 -1.1418047427480882e-03 -3.1842516233562688e-04 + 13 3.6258187754908603e-04 -1.5531581259494627e-03 -1.9590476904013767e-04 + 14 4.2166181631324117e-04 -1.6310415916630540e-03 -3.1740232809360453e-04 + 15 9.7471807923383321e-04 -8.9939841790992827e-04 -9.6757308853409824e-04 + 16 4.1534888649229478e-06 1.7705740202856454e-05 9.0753010117813394e-04 + 17 2.5969943716026096e-04 8.7075266710270492e-04 7.7887058799645239e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_nvt_small.yaml b/unittest/force-styles/tests/fix-timestep-rigid_nvt_small.yaml index b0e0040070..6068993094 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_nvt_small.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_nvt_small.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/nvt/small @@ -12,8 +13,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -1.4827261116680450e+02 -1.8411194349753366e+01 -1.0752762859308652e+02 -2.1814511477016262e+02 1.7027764307147635e+02 2.1058942244057143e+01 -global_scalar: 0.953260955473961 + -1.4827261116680472e+02 -1.8411194349753309e+01 -1.0752762859308649e+02 -2.1814511477016276e+02 1.7027764307147623e+02 2.1058942244057214e+01 +global_scalar: 0.9532609554739606 run_pos: ! |2 1 -2.7993683669226832e-01 2.4726588069312840e+00 -1.7200860244148433e-01 2 3.0197083955402204e-01 2.9515239068888608e+00 -8.5689735572907566e-01 @@ -62,15 +63,15 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 7.8522439440007548e-04 -6.6826115062653757e-04 1.7528441282153480e-03 - 19 1.8628941719211860e-03 -3.1840047051916367e-03 2.2062694140207390e-03 - 20 -1.4430972531298200e-03 9.7564145841628493e-04 1.0686492192569896e-03 - 21 -3.0047717246574372e-03 -6.6139343888744952e-04 2.4784169377340712e-03 - 22 -3.4980341571643780e-03 -3.3380963325930985e-03 3.2191613979274045e-03 - 23 5.9333930569297963e-04 -8.6231086219834985e-03 -8.2692040355627789e-04 - 24 1.8727912311097637e-03 -2.0349136820274911e-03 1.1951471753018509e-03 - 25 3.4887365958745937e-03 -4.8232966889391275e-03 -1.2263764490291341e-03 - 26 -3.4770258010749858e-03 7.8662050223200905e-04 5.3381090661352281e-03 + 18 7.8522439440007537e-04 -6.6826115062653757e-04 1.7528441282153480e-03 + 19 1.8628941719211862e-03 -3.1840047051916367e-03 2.2062694140207390e-03 + 20 -1.4430972531298200e-03 9.7564145841628493e-04 1.0686492192569898e-03 + 21 -3.0047717246574385e-03 -6.6139343888744974e-04 2.4784169377340712e-03 + 22 -3.4980341571643784e-03 -3.3380963325931002e-03 3.2191613979274040e-03 + 23 5.9333930569297746e-04 -8.6231086219834968e-03 -8.2692040355627789e-04 + 24 1.8727912311097641e-03 -2.0349136820274911e-03 1.1951471753018509e-03 + 25 3.4887365958745920e-03 -4.8232966889391266e-03 -1.2263764490291313e-03 + 26 -3.4770258010749858e-03 7.8662050223200905e-04 5.3381090661352298e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_single.yaml b/unittest/force-styles/tests/fix-timestep-rigid_single.yaml index 4622e159d2..02acb437d9 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_single.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_single.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 7.5e-13 +skip_tests: prerequisites: ! | atom full fix rigid @@ -13,8 +14,8 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -1.3754817466835989e+03 -1.4228425246166139e+03 -3.6087196201914344e+03 8.7407043149698939e+02 2.1665316519769868e+02 -6.0480791462033017e+02 -global_scalar: 4.53142303857029 + -1.3754817466835989e+03 -1.4228425246166137e+03 -3.6087196201914348e+03 8.7407043149698916e+02 2.1665316519769885e+02 -6.0480791462033073e+02 +global_scalar: 4.531423038570297 run_pos: ! |2 1 -2.7899546859693136e-01 2.4731857340428784e+00 -1.7290667720876285e-01 2 3.0296221616793728e-01 2.9517129917211546e+00 -8.5798904365355155e-01 @@ -46,23 +47,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 4.7093296226165726e-04 2.6351124312057247e-04 -4.4905063547614652e-04 - 2 4.9594635271877252e-04 9.4561409237138173e-05 -5.4581325723053399e-04 - 3 3.3306088119083085e-04 2.3224949911015443e-04 -2.3659435306900835e-04 - 4 3.3692332940286711e-04 2.1926824120529689e-04 -2.4716611858556487e-04 - 5 3.3642541894624033e-04 4.1797578053943675e-04 -1.8011323945929070e-04 - 6 2.0926870695908275e-04 2.6449376032441517e-05 -1.0508922741401380e-04 - 7 1.4629046128362901e-04 -1.6873362379723092e-04 -6.8353900724071163e-05 - 8 1.5844098346817922e-04 3.7728756087618725e-05 -1.9162577392849018e-05 - 9 2.1299357198252964e-04 1.6917133003966706e-04 -6.3528006071199931e-05 - 10 5.4261569071245721e-05 -9.4655546204699004e-05 1.0511372702289778e-04 - 11 -3.2194218121523377e-05 -2.2025090185602322e-04 2.0300208519292837e-04 - 12 1.2640585449263546e-04 -2.9851081600946783e-04 -7.9476186245574907e-05 - 13 8.4523551795102276e-05 -4.0583140303608237e-04 -4.7550925831930506e-05 - 14 9.9954071734163652e-05 -4.2610809338913862e-04 -7.9255453072661283e-05 - 15 2.4417483202629974e-04 -2.3521005781669077e-04 -2.4875292755151935e-04 - 16 -9.0959360838839976e-06 3.7773746063190714e-06 2.4035204669042517e-04 - 17 5.7507084250807059e-05 2.2629200960629290e-04 2.0686926033794590e-04 + 1 4.7093296226165759e-04 2.6351124312057290e-04 -4.4905063547614669e-04 + 2 4.9594635271877263e-04 9.4561409237138512e-05 -5.4581325723053421e-04 + 3 3.3306088119083101e-04 2.3224949911015481e-04 -2.3659435306900835e-04 + 4 3.3692332940286717e-04 2.1926824120529722e-04 -2.4716611858556465e-04 + 5 3.3642541894624077e-04 4.1797578053943724e-04 -1.8011323945929064e-04 + 6 2.0926870695908283e-04 2.6449376032441855e-05 -1.0508922741401397e-04 + 7 1.4629046128362884e-04 -1.6873362379723068e-04 -6.8353900724071325e-05 + 8 1.5844098346817943e-04 3.7728756087619084e-05 -1.9162577392849316e-05 + 9 2.1299357198253002e-04 1.6917133003966749e-04 -6.3528006071200284e-05 + 10 5.4261569071245856e-05 -9.4655546204698666e-05 1.0511372702289738e-04 + 11 -3.2194218121523431e-05 -2.2025090185602293e-04 2.0300208519292805e-04 + 12 1.2640585449263546e-04 -2.9851081600946745e-04 -7.9476186245575585e-05 + 13 8.4523551795102263e-05 -4.0583140303608199e-04 -4.7550925831931374e-05 + 14 9.9954071734163435e-05 -4.2610809338913835e-04 -7.9255453072661880e-05 + 15 2.4417483202629980e-04 -2.3521005781669047e-04 -2.4875292755152005e-04 + 16 -9.0959360838836724e-06 3.7773746063194780e-06 2.4035204669042463e-04 + 17 5.7507084250807628e-05 2.2629200960629336e-04 2.0686926033794547e-04 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-rigid_small.yaml b/unittest/force-styles/tests/fix-timestep-rigid_small.yaml index 837363d059..92754f85f5 100644 --- a/unittest/force-styles/tests/fix-timestep-rigid_small.yaml +++ b/unittest/force-styles/tests/fix-timestep-rigid_small.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix rigid/small @@ -13,7 +14,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 run_stress: ! |- - -4.9200116134789894e+01 -2.6907707565987600e+01 -6.0080860422279923e+00 -2.5620423972101459e+01 -1.3450224059984031e+01 -1.4947288487004347e+00 + -4.9200116134789873e+01 -2.6907707565987707e+01 -6.0080860422278581e+00 -2.5620423972101300e+01 -1.3450224059983967e+01 -1.4947288487003760e+00 global_scalar: 18.3405601674144 run_pos: ! |2 1 -2.7993683669226832e-01 2.4726588069312840e+00 -1.7200860244148433e-01 @@ -63,15 +64,15 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 3.6149625095704908e-04 -3.1032459262908286e-04 8.1043030117346042e-04 + 18 3.6149625095704914e-04 -3.1032459262908286e-04 8.1043030117346052e-04 19 8.5103884665345452e-04 -1.4572280596788108e-03 1.0163621287634116e-03 - 20 -6.5204659278590683e-04 4.3989037444289853e-04 4.9909839028507890e-04 - 21 -1.3888125881903923e-03 -3.1978049143082407e-04 1.1455681499836646e-03 - 22 -1.6084223477729508e-03 -1.5355394240821113e-03 1.4772010826232373e-03 - 23 2.6392672378805081e-04 -3.9375414431174812e-03 -3.6991583139728051e-04 - 24 8.6062827067890236e-04 -9.4179873474469237e-04 5.5396395550012442e-04 - 25 1.5933645477487542e-03 -2.2139156625681699e-03 -5.5078029695647488e-04 - 26 -1.5679561743998840e-03 3.5146224354726122e-04 2.4446924193334474e-03 + 20 -6.5204659278590683e-04 4.3989037444289853e-04 4.9909839028507901e-04 + 21 -1.3888125881903923e-03 -3.1978049143082385e-04 1.1455681499836646e-03 + 22 -1.6084223477729510e-03 -1.5355394240821117e-03 1.4772010826232375e-03 + 23 2.6392672378805124e-04 -3.9375414431174821e-03 -3.6991583139728095e-04 + 24 8.6062827067890247e-04 -9.4179873474469237e-04 5.5396395550012453e-04 + 25 1.5933645477487538e-03 -2.2139156625681695e-03 -5.5078029695647401e-04 + 26 -1.5679561743998840e-03 3.5146224354726100e-04 2.4446924193334478e-03 27 -2.6510179146429716e-04 3.6306203629019116e-04 -5.6235585400647747e-04 28 -2.3068708109787484e-04 -8.5663070212203200e-04 2.1302563179109169e-03 29 -2.5054744388303732e-03 -1.6773997805290820e-04 2.8436699761004796e-03 diff --git a/unittest/force-styles/tests/fix-timestep-setforce_const.yaml b/unittest/force-styles/tests/fix-timestep-setforce_const.yaml index 05ea1b2adb..5c403f690e 100644 --- a/unittest/force-styles/tests/fix-timestep-setforce_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-setforce_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:00 2022 epsilon: 2e-11 +skip_tests: prerequisites: ! | atom full fix setforce @@ -12,7 +13,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 global_vector: ! |- - 3 0.031196595768662405 0.027176378299685666 -0.018248127488959653 + 3 0.031196595768690827 0.027176378299486714 -0.018248127489101762 run_pos: ! |2 1 -2.7837948059450057e-01 2.4915057595127261e+00 -1.7244621851040967e-01 2 3.0739674554684748e-01 2.9612812082059410e+00 -8.4971536723424157e-01 @@ -44,33 +45,33 @@ run_pos: ! |2 28 -2.7473562684448014e+00 -4.0200819932539504e+00 1.5830052163387485e+00 29 -1.3126000190074181e+00 -3.5962518039956493e+00 2.2746342468316909e+00 run_vel: ! |2 - 1 7.7867804888392077e-04 1.7047228530841809e-02 -2.1582089259505630e-04 - 2 2.7129529964126462e-03 5.2784482698423644e-03 3.6014335254494771e-03 - 3 -1.2736791029204805e-03 -1.3974541598892314e-02 -3.2921473803217605e-04 - 4 -9.2828595122009308e-04 -6.6991688238371011e-03 -4.0996189392783757e-03 - 5 -1.1800848061603740e-03 -1.0047153968619136e-02 8.9901734029750995e-05 + 1 7.7867804888392077e-04 1.7047228530841802e-02 -2.1582089259505630e-04 + 2 2.7129529964126462e-03 5.2784482698423705e-03 3.6014335254494771e-03 + 3 -1.2736791029204805e-03 -1.3974541598892304e-02 -3.2921473803217605e-04 + 4 -9.2828595122009308e-04 -6.6991688238371080e-03 -4.0996189392783757e-03 + 5 -1.1800848061603740e-03 -1.0047153968619141e-02 8.9901734029750995e-05 6 -3.0914004879905335e-04 5.9226312312574469e-02 8.0271015448535863e-04 7 -1.1037894966874103e-04 -1.6457202942861592e-02 -7.6694610847002475e-04 - 8 3.9060281273221989e-04 -3.3092081140500625e-03 1.5732069521849873e-04 + 8 3.9060281273221989e-04 -3.3092081140500642e-03 1.5732069521849873e-04 9 1.2475530960659720e-03 3.1932872333445845e-03 1.1326388467761117e-03 - 10 4.5008983776042893e-04 -3.2706161456987362e-02 -2.2639522262760407e-04 + 10 4.5008983776042893e-04 -3.2706161456987355e-02 -2.2639522262760407e-04 11 -3.6977669078869707e-04 -3.8208979405711181e-03 -2.8967604321188693e-03 - 12 1.0850834530183159e-03 -5.9865405325318095e-04 -1.2901481412786638e-03 - 13 4.0754559196230639e-03 5.8000556188644737e-03 -7.6236632081370817e-04 - 14 -1.3837220448746613e-04 -5.8513645592199954e-03 -3.9124675613296149e-03 - 15 -4.3301707382721859e-03 -5.7874916835632612e-03 3.2246704604008991e-03 - 16 -9.6715751018414326e-05 -2.0337180407622942e-02 1.5015330084982936e-03 - 17 6.5692180538157174e-04 1.5347761197837848e-02 8.4018434079252094e-04 - 18 -8.0066836980328829e-04 -8.6272352268198973e-04 -1.4482916287850436e-03 - 19 1.2452384523271498e-03 -2.5061112055692661e-03 7.2998645869741070e-03 - 20 3.5930056005389279e-03 3.6938854790338886e-03 3.2322736694535342e-03 - 21 -1.4689186150745120e-03 -2.7352475069894054e-04 7.0581153530664112e-04 - 22 -7.0694198605565570e-03 -4.2577150334417316e-03 2.8079083578864353e-04 - 23 6.0446965741464556e-03 -1.4000132401387128e-03 2.5819752034683392e-03 - 24 3.1926469085296537e-04 -9.9445460268275231e-04 1.5000192558511910e-04 - 25 1.3789867280959912e-04 -4.4335884662300897e-03 -8.1807894939305860e-04 - 26 2.0485905358907184e-03 2.7813360186345780e-03 4.3245728521738580e-03 - 27 4.5604013457189150e-04 -1.0305533784689190e-03 2.1187984562018490e-04 - 28 -6.2544520812349144e-03 1.4127710889363602e-03 -1.8429822031806322e-03 - 29 6.4110655335636812e-04 3.1273431604200374e-03 3.7253670254479500e-03 + 12 1.0850834530183159e-03 -5.9865405325317640e-04 -1.2901481412786638e-03 + 13 4.0754559196230639e-03 5.8000556188644685e-03 -7.6236632081370817e-04 + 14 -1.3837220448746613e-04 -5.8513645592200006e-03 -3.9124675613296149e-03 + 15 -4.3301707382721859e-03 -5.7874916835632629e-03 3.2246704604008991e-03 + 16 -9.6715751018414326e-05 -2.0337180407622935e-02 1.5015330084982936e-03 + 17 6.5692180538157174e-04 1.5347761197837846e-02 8.4018434079252094e-04 + 18 -8.0066836980328829e-04 -8.6272352268198854e-04 -1.4482916287850455e-03 + 19 1.2452384523271467e-03 -2.5061112055692713e-03 7.2998645869741087e-03 + 20 3.5930056005389287e-03 3.6938854790338886e-03 3.2322736694535398e-03 + 21 -1.4689186150745113e-03 -2.7352475069893978e-04 7.0581153530663884e-04 + 22 -7.0694198605565622e-03 -4.2577150334417351e-03 2.8079083578864597e-04 + 23 6.0446965741464600e-03 -1.4000132401387130e-03 2.5819752034683461e-03 + 24 3.1926469085296483e-04 -9.9445460268274993e-04 1.5000192558511764e-04 + 25 1.3789867280959787e-04 -4.4335884662300967e-03 -8.1807894939305785e-04 + 26 2.0485905358907227e-03 2.7813360186345745e-03 4.3245728521738623e-03 + 27 4.5604013457189118e-04 -1.0305533784689164e-03 2.1187984562018409e-04 + 28 -6.2544520812349170e-03 1.4127710889363543e-03 -1.8429822031806320e-03 + 29 6.4110655335637300e-04 3.1273431604200330e-03 3.7253670254479539e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-setforce_region.yaml b/unittest/force-styles/tests/fix-timestep-setforce_region.yaml index 50eafa8f6a..0dbcd601ca 100644 --- a/unittest/force-styles/tests/fix-timestep-setforce_region.yaml +++ b/unittest/force-styles/tests/fix-timestep-setforce_region.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full fix setforce @@ -13,7 +14,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 global_vector: ! |- - 3 30.2599905309868 33.68278530642225 -29.246531241430393 + 3 30.259990530986737 33.6827853064222 -29.24653124143034 run_pos: ! |2 1 -2.7049035247384523e-01 2.4911810898708389e+00 -1.6691641634960069e-01 2 3.0739674554684748e-01 2.9607811923110940e+00 -8.4973624579030649e-01 @@ -45,11 +46,11 @@ run_pos: ! |2 28 -2.7473562684439594e+00 -4.0200819932414040e+00 1.5830052163325192e+00 29 -1.3126000190355391e+00 -3.5962518039701115e+00 2.2746342468355896e+00 run_vel: ! |2 - 1 8.0968238327908306e-03 1.6439353504426914e-02 4.8774271710863440e-03 + 1 8.0968238327908306e-03 1.6439353504426914e-02 4.8774271710863406e-03 2 2.7129529964126462e-03 4.6286427111164284e-03 3.5805549693846352e-03 - 3 -7.3249068559002473e-03 -1.3819430195421816e-02 -4.7723976289498213e-03 - 4 -3.7880669939802302e-03 -6.5262112276744154e-03 -1.0623014289922296e-03 - 5 -1.0968756474139221e-02 -9.9481298518413509e-03 -2.8555668881870850e-03 + 3 -7.3249068559002499e-03 -1.3819430195421808e-02 -4.7723976289498152e-03 + 4 -3.7880669939802259e-03 -6.5262112276744232e-03 -1.0623014289922381e-03 + 5 -1.0968756474139217e-02 -9.9481298518413579e-03 -2.8555668881870863e-03 6 -3.0914004879905335e-04 1.2755385764678133e-03 7.9574303350202582e-04 7 -1.1037894966874103e-04 -7.6764845099077425e-04 -7.7217630460203659e-04 8 3.9060281273221989e-04 -8.1444231918053418e-04 1.5134641148324972e-04 @@ -62,16 +63,16 @@ run_vel: ! |2 15 -4.3301707382721859e-03 -3.1802661664634938e-03 3.2037919043360571e-03 16 -9.6715751018414326e-05 -5.0016572678960377e-04 1.4945658875149626e-03 17 6.5692180538157174e-04 3.6635779995305095e-04 8.3495414466050911e-04 - 18 -8.0066124075139065e-04 -8.6271573462520822e-04 -1.4482975502198103e-03 - 19 1.2452389135116637e-03 -2.5061107963827616e-03 7.2998638022685452e-03 - 20 3.5930058351021075e-03 3.6938856958711494e-03 3.2322734653392029e-03 - 21 -1.4689171694079451e-03 -2.7352531109399892e-04 7.0581004713133645e-04 - 22 -7.0694198156406830e-03 -4.2577150557698900e-03 2.8079073380301450e-04 - 23 6.0446966473130361e-03 -1.4000132185117897e-03 2.5819751444708279e-03 - 24 3.1926444029166840e-04 -9.9445445081424041e-04 1.5000138266644348e-04 - 25 1.3789768148904548e-04 -4.4335891153916762e-03 -8.1808099807448656e-04 - 26 2.0485904659168050e-03 2.7813359700824256e-03 4.3245727588882886e-03 - 27 4.5604046194129701e-04 -1.0305531094668544e-03 2.1187977265303768e-04 - 28 -6.2544520782408771e-03 1.4127711142458772e-03 -1.8429822149784341e-03 - 29 6.4110649875996400e-04 3.1273432160629365e-03 3.7253670337420121e-03 + 18 -8.0066124075139022e-04 -8.6271573462520725e-04 -1.4482975502198134e-03 + 19 1.2452389135116607e-03 -2.5061107963827646e-03 7.2998638022685487e-03 + 20 3.5930058351021092e-03 3.6938856958711498e-03 3.2322734653392089e-03 + 21 -1.4689171694079451e-03 -2.7352531109399800e-04 7.0581004713133385e-04 + 22 -7.0694198156406899e-03 -4.2577150557698926e-03 2.8079073380301775e-04 + 23 6.0446966473130369e-03 -1.4000132185117897e-03 2.5819751444708348e-03 + 24 3.1926444029166775e-04 -9.9445445081423824e-04 1.5000138266644207e-04 + 25 1.3789768148904391e-04 -4.4335891153916814e-03 -8.1808099807448580e-04 + 26 2.0485904659168089e-03 2.7813359700824226e-03 4.3245727588882930e-03 + 27 4.5604046194129674e-04 -1.0305531094668518e-03 2.1187977265303687e-04 + 28 -6.2544520782408788e-03 1.4127711142458712e-03 -1.8429822149784341e-03 + 29 6.4110649875996845e-04 3.1273432160629330e-03 3.7253670337420138e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-setforce_variable.yaml b/unittest/force-styles/tests/fix-timestep-setforce_variable.yaml index 00a1b270f9..e0ca6792a8 100644 --- a/unittest/force-styles/tests/fix-timestep-setforce_variable.yaml +++ b/unittest/force-styles/tests/fix-timestep-setforce_variable.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:58 2021 -epsilon: 1e-11 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 +epsilon: 2e-11 +skip_tests: prerequisites: ! | atom full fix setforce @@ -17,7 +18,7 @@ post_commands: ! | input_file: in.fourmol natoms: 29 global_vector: ! |- - 3 0.031197043446070438 0.027174896355546707 -0.0182497728803952 + 3 0.031197043446169914 0.027174896355347755 -0.01824977288043783 run_pos: ! |2 1 -2.7839620481540395e-01 2.4915057673839494e+00 -1.7245062454466442e-01 2 3.0745979269788315e-01 2.9612799003321073e+00 -8.4973076516933943e-01 @@ -49,33 +50,33 @@ run_pos: ! |2 28 -2.7473562684450474e+00 -4.0200819932540828e+00 1.5830052163388388e+00 29 -1.3126000190081526e+00 -3.5962518039961902e+00 2.2746342468323033e+00 run_vel: ! |2 - 1 7.6195382798044376e-04 1.7047294266563661e-02 -2.1940546283620574e-04 - 2 2.7760001474483962e-03 5.2757744130340666e-03 3.5889063918105712e-03 - 3 -1.3220555707422056e-03 -1.3973728740579328e-02 -3.3339501062217507e-04 - 4 -1.2575744817904762e-03 -6.7002024022163554e-03 -4.1121460729172752e-03 - 5 -1.3669515604046946e-03 -1.0047013360250249e-02 7.7374600390847764e-05 + 1 7.6195382798044376e-04 1.7047294266563658e-02 -2.1940546283620574e-04 + 2 2.7760001474483962e-03 5.2757744130340709e-03 3.5889063918105712e-03 + 3 -1.3220555707422056e-03 -1.3973728740579320e-02 -3.3339501062217507e-04 + 4 -1.2575744817904762e-03 -6.7002024022163606e-03 -4.1121460729172752e-03 + 5 -1.3669515604046946e-03 -1.0047013360250255e-02 7.7374600390847764e-05 6 -2.8864792900532157e-04 5.9222680386688660e-02 7.9852988189535858e-04 7 -9.2585889864279630e-05 -1.6457340485619719e-02 -7.7008422614923192e-04 8 4.6015056791200718e-04 -3.3109316498999594e-03 1.5373612497734929e-04 9 1.5352065637273457e-03 3.1937624988604553e-03 1.1201117131372088e-03 - 10 5.9072315037472388e-04 -3.2700043246480542e-02 -2.3057549521760353e-04 + 10 5.9072315037472388e-04 -3.2700043246480535e-02 -2.3057549521760353e-04 11 4.5712368059701517e-06 -3.8214916428847890e-03 -2.9092875657577752e-03 - 12 1.2943078231358680e-03 -6.0079494716434921e-04 -1.2943284138686624e-03 - 13 4.9199365930735345e-03 5.8023312918586692e-03 -7.7489345445261120e-04 - 14 4.0516243615214899e-04 -5.8486182036653431e-03 -3.9249946949685144e-03 - 15 -3.7089018420464036e-03 -5.7868019097368261e-03 3.2121433267619931e-03 - 16 8.8035257588441089e-05 -2.0334633672149962e-02 1.4973527359082950e-03 - 17 7.7360729694572576e-04 1.5346061058559362e-02 8.3704622311331378e-04 - 18 -8.0066835867995026e-04 -8.6272351468143541e-04 -1.4482916352603645e-03 - 19 1.2452384527498459e-03 -2.5061112043225221e-03 7.2998645858971855e-03 - 20 3.5930056010593471e-03 3.6938854791676847e-03 3.2322736692798068e-03 - 21 -1.4689186242560829e-03 -2.7352472551473247e-04 7.0581155868180371e-04 - 22 -7.0694198604028301e-03 -4.2577150325890274e-03 2.8079083711864800e-04 - 23 6.0446965730643750e-03 -1.4000132386422566e-03 2.5819752050698025e-03 - 24 3.1926469474555008e-04 -9.9445460100738717e-04 1.5000192930508560e-04 - 25 1.3789867459853888e-04 -4.4335884646610046e-03 -8.1807894538992332e-04 - 26 2.0485905361409002e-03 2.7813360188135763e-03 4.3245728523802927e-03 - 27 4.5604012089853278e-04 -1.0305533883296402e-03 2.1187985225197545e-04 - 28 -6.2544520817733613e-03 1.4127710886673889e-03 -1.8429822030169415e-03 - 29 6.4110655177640171e-04 3.1273431592077948e-03 3.7253670266864263e-03 + 12 1.2943078231358680e-03 -6.0079494716434487e-04 -1.2943284138686624e-03 + 13 4.9199365930735345e-03 5.8023312918586631e-03 -7.7489345445261120e-04 + 14 4.0516243615214899e-04 -5.8486182036653449e-03 -3.9249946949685144e-03 + 15 -3.7089018420464036e-03 -5.7868019097368269e-03 3.2121433267619931e-03 + 16 8.8035257588441089e-05 -2.0334633672149955e-02 1.4973527359082950e-03 + 17 7.7360729694572576e-04 1.5346061058559360e-02 8.3704622311331378e-04 + 18 -8.0066835867995026e-04 -8.6272351468143443e-04 -1.4482916352603677e-03 + 19 1.2452384527498427e-03 -2.5061112043225260e-03 7.2998645858971898e-03 + 20 3.5930056010593527e-03 3.6938854791676852e-03 3.2322736692798138e-03 + 21 -1.4689186242560820e-03 -2.7352472551473166e-04 7.0581155868180122e-04 + 22 -7.0694198604028362e-03 -4.2577150325890300e-03 2.8079083711865115e-04 + 23 6.0446965730643759e-03 -1.4000132386422566e-03 2.5819752050698095e-03 + 24 3.1926469474554949e-04 -9.9445460100738479e-04 1.5000192930508409e-04 + 25 1.3789867459853780e-04 -4.4335884646610141e-03 -8.1807894538992257e-04 + 26 2.0485905361409045e-03 2.7813360188135737e-03 4.3245728523802944e-03 + 27 4.5604012089853251e-04 -1.0305533883296378e-03 2.1187985225197450e-04 + 28 -6.2544520817733639e-03 1.4127710886673822e-03 -1.8429822030169415e-03 + 29 6.4110655177640583e-04 3.1273431592077918e-03 3.7253670266864289e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-shake_angle.yaml b/unittest/force-styles/tests/fix-timestep-shake_angle.yaml index 0b6c1f7093..b085b79069 100644 --- a/unittest/force-styles/tests/fix-timestep-shake_angle.yaml +++ b/unittest/force-styles/tests/fix-timestep-shake_angle.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:58 2021 +lammps_version: 17 Feb 2022 tags: unstable +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 9e-10 +skip_tests: prerequisites: ! | atom full fix shake @@ -19,7 +20,7 @@ run_pos: ! |2 1 -2.7045559935221097e-01 2.4912159904412490e+00 -1.6695851634760922e-01 2 3.1004029578877490e-01 2.9612354630874571e+00 -8.5466363025011627e-01 3 -7.0398551512563190e-01 1.2305509950678348e+00 -6.2777526850896104e-01 - 4 -1.5818159336526965e+00 1.4837407818978032e+00 -1.2538710835933191e+00 + 4 -1.5818159336526965e+00 1.4837407818978030e+00 -1.2538710835933191e+00 5 -9.0719763671886688e-01 9.2652103888784798e-01 3.9954210492830977e-01 6 2.4831720377219527e-01 2.8313021315702191e-01 -1.2314233326160173e+00 7 3.4143527702622728e-01 -2.2646549532188483e-02 -2.5292291427264142e+00 @@ -31,7 +32,7 @@ run_pos: ! |2 13 4.0515402958586257e+00 -8.9202011560301075e-01 -1.6400005529400123e+00 14 2.6066963345427290e+00 -4.1789253956770167e-01 -2.6634003609341543e+00 15 2.9695287185432337e+00 5.5422613169503154e-01 -1.2342022022205887e+00 - 16 2.6747029683763714e+00 -2.4124119045309693e+00 -2.3435744689915879e-02 + 16 2.6747029683763714e+00 -2.4124119045309693e+00 -2.3435744689915872e-02 17 2.2153577782070029e+00 -2.0897985186673269e+00 1.1963150798970605e+00 18 2.1373900776598025e+00 3.0170538458090777e+00 -3.5215797395691513e+00 19 1.5430025676356878e+00 2.6303296449526830e+00 -4.2266668834026815e+00 @@ -46,23 +47,23 @@ run_pos: ! |2 28 -2.7473562684513424e+00 -4.0200819932379339e+00 1.5830052163433954e+00 29 -1.3126000191366676e+00 -3.5962518039489830e+00 2.2746342468733833e+00 run_vel: ! |2 - 1 8.1705729507146694e-03 1.6516406093744648e-02 4.7902279090199758e-03 - 2 5.4501493276694424e-03 5.1791698760542673e-03 -1.4372929651720338e-03 - 3 -8.2298303446991464e-03 -1.2926552110646276e-02 -4.0984171815350275e-03 - 4 -3.7699042793691569e-03 -6.5722892086671888e-03 -1.1184640147877201e-03 - 5 -1.1021961023179821e-02 -9.8906780808723557e-03 -2.8410737186752395e-03 + 1 8.1705729507146711e-03 1.6516406093744648e-02 4.7902279090199715e-03 + 2 5.4501493276694433e-03 5.1791698760542708e-03 -1.4372929651720304e-03 + 3 -8.2298303446991482e-03 -1.2926552110646266e-02 -4.0984171815350223e-03 + 4 -3.7699042793691542e-03 -6.5722892086671966e-03 -1.1184640147877288e-03 + 5 -1.1021961023179812e-02 -9.8906780808723626e-03 -2.8410737186752412e-03 6 -3.9676664596302008e-02 4.6817059618450937e-02 3.7148492579484528e-02 7 9.1034031301506118e-04 -1.0128522664904683e-02 -5.1568252954671344e-02 - 8 7.9064703413713640e-03 -3.3507265483952125e-03 3.4557099321061942e-02 + 8 7.9064703413713640e-03 -3.3507265483952143e-03 3.4557099321061942e-02 9 1.5644176069499448e-03 3.7365546445246702e-03 1.5047408832397751e-02 - 10 2.9201446099433169e-02 -2.9249578511256962e-02 -1.5018076911020577e-02 + 10 2.9201446099433176e-02 -2.9249578511256966e-02 -1.5018076911020580e-02 11 -4.7835964007472464e-03 -3.7481383012996786e-03 -2.3464103653896310e-03 - 12 2.2696453008391230e-03 -3.4774279616438269e-04 -3.0640765817961284e-03 - 13 2.7531739986205606e-03 5.8171065863360308e-03 -7.9467449090663456e-04 - 14 3.5246182341718778e-03 -5.7939994947008274e-03 -3.9478431580931327e-03 - 15 -1.8547943904014333e-03 -5.8554729842982909e-03 6.2938484741557809e-03 - 16 1.8681498891538875e-02 -1.3262465322856009e-02 -4.5638650127800932e-02 - 17 -1.2896270312366209e-02 9.7527665732632315e-03 3.7296535866542121e-02 + 12 2.2696453008391273e-03 -3.4774279616437863e-04 -3.0640765817961345e-03 + 13 2.7531739986205572e-03 5.8171065863360221e-03 -7.9467449090662935e-04 + 14 3.5246182341718722e-03 -5.7939994947008352e-03 -3.9478431580931310e-03 + 15 -1.8547943904014381e-03 -5.8554729842982909e-03 6.2938484741557853e-03 + 16 1.8681498891538868e-02 -1.3262465322856010e-02 -4.5638650127800925e-02 + 17 -1.2896270312366209e-02 9.7527665732632281e-03 3.7296535866542121e-02 18 3.6201702653131140e-04 -3.1019808758173800e-04 8.1201764037217537e-04 19 8.5112357208489992e-04 -1.4603354100514621e-03 1.0305255073350999e-03 20 -6.5417980186682713e-04 4.4256252972757129e-04 4.7856452381576193e-04 @@ -72,7 +73,7 @@ run_vel: ! |2 24 8.5788312813832768e-04 -9.4446247923316430e-04 5.5288134920163914e-04 25 1.6004032839658105e-03 -2.2093787045529070e-03 -5.4710568918423246e-04 26 -1.5640453157606073e-03 3.5755072465497545e-04 2.4453237299123754e-03 - 27 4.5604120291777391e-04 -1.0305523027099432e-03 2.1188058380935704e-04 - 28 -6.2544520861865490e-03 1.4127711176129324e-03 -1.8429821884795277e-03 - 29 6.4110631474916110e-04 3.1273432713407900e-03 3.7253671102111473e-03 + 27 4.5604120291777359e-04 -1.0305523027099401e-03 2.1188058380935623e-04 + 28 -6.2544520861865507e-03 1.4127711176129259e-03 -1.8429821884795275e-03 + 29 6.4110631474916446e-04 3.1273432713407861e-03 3.7253671102111486e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-shake_bond.yaml b/unittest/force-styles/tests/fix-timestep-shake_bond.yaml index 3da01fa5b8..49ac1c050a 100644 --- a/unittest/force-styles/tests/fix-timestep-shake_bond.yaml +++ b/unittest/force-styles/tests/fix-timestep-shake_bond.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:58 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 5e-11 +skip_tests: prerequisites: ! | atom full fix shake @@ -45,33 +46,33 @@ run_pos: ! |2 28 -2.7473562684591109e+00 -4.0200819932508631e+00 1.5830052163456609e+00 29 -1.3126000191565619e+00 -3.5962518039874860e+00 2.2746342468906682e+00 run_vel: ! |2 - 1 7.7374089697702340e-03 1.5916892554636120e-02 5.0456645075959315e-03 - 2 6.5175317085631830e-03 6.0077809909591315e-03 -2.7565762268061691e-03 - 3 -7.3639495008649726e-03 -1.2783103383496114e-02 -3.3210885167291849e-03 - 4 -5.8960928588029050e-03 -5.9659026594337371e-03 -2.6326334955469629e-03 - 5 -1.0929649166221467e-02 -9.6585820819745337e-03 -3.0956626591882317e-03 + 1 7.7374089697702349e-03 1.5916892554636117e-02 5.0456645075959289e-03 + 2 6.5175317085631838e-03 6.0077809909591384e-03 -2.7565762268061626e-03 + 3 -7.3639495008649743e-03 -1.2783103383496109e-02 -3.3210885167291788e-03 + 4 -5.8960928588029007e-03 -5.9659026594337458e-03 -2.6326334955469716e-03 + 5 -1.0929649166221458e-02 -9.6585820819745406e-03 -3.0956626591882338e-03 6 -4.0123707366825134e-02 4.7187394112873600e-02 3.6871538264118715e-02 7 9.1133487010605738e-04 -1.0132608633652593e-02 -5.1595915280729321e-02 - 8 7.0089143878456980e-03 -4.2476532224071028e-03 3.0986626913844219e-02 + 8 7.0089143878456972e-03 -4.2476532224071037e-03 3.0986626913844219e-02 9 4.6371837171993438e-03 7.0467783396206997e-03 2.8626734931872490e-02 10 3.0610207065038343e-02 -2.7619291009667819e-02 -1.2133094808158711e-02 11 -7.2029914080563463e-03 -9.4537429127199805e-03 -1.1792451031601467e-02 - 12 1.5104136100256851e-03 -8.6488026266383442e-04 -2.9343726025856101e-03 - 13 4.0386002756917826e-03 5.5920871347548079e-03 -9.5141171089924864e-04 - 14 3.7450160863088276e-03 -5.7205370491546937e-03 -4.1283641103704487e-03 - 15 -1.6192252475286013e-03 -4.5865111215587151e-03 6.6369580798579545e-03 - 16 1.8683716258411448e-02 -1.3263096088951513e-02 -4.5607321000770314e-02 - 17 -1.2893753425925471e-02 9.7485795481259876e-03 3.7300775385779875e-02 - 18 -8.0065894051881148e-04 -8.6270684963651867e-04 -1.4483015146944855e-03 - 19 1.2452389852680510e-03 -2.5061098313021958e-03 7.2998634573395622e-03 - 20 3.5930058838403115e-03 3.6938858373569165e-03 3.2322734729320975e-03 - 21 -1.4689219027528956e-03 -2.7352134530947056e-04 7.0581593448005328e-04 - 22 -7.0694199260273143e-03 -4.2577148857392598e-03 2.8079115157198279e-04 - 23 6.0446963222438397e-03 -1.4000131442962716e-03 2.5819754631691500e-03 - 24 3.1926442964369691e-04 -9.9445591935644600e-04 1.5000033448111903e-04 - 25 1.3789825021844792e-04 -4.4335889596263511e-03 -8.1808100227326449e-04 - 26 2.0485904735292599e-03 2.7813359659683385e-03 4.3245727170611618e-03 - 27 4.5604110580961207e-04 -1.0305524671180935e-03 2.1188063421234097e-04 - 28 -6.2544520944132998e-03 1.4127711036803850e-03 -1.8429821866102578e-03 - 29 6.4110628696208052e-04 3.1273432221612541e-03 3.7253671295737062e-03 + 12 1.5104136100256896e-03 -8.6488026266383019e-04 -2.9343726025856140e-03 + 13 4.0386002756917791e-03 5.5920871347548019e-03 -9.5141171089924332e-04 + 14 3.7450160863088220e-03 -5.7205370491546980e-03 -4.1283641103704470e-03 + 15 -1.6192252475286063e-03 -4.5865111215587168e-03 6.6369580798579597e-03 + 16 1.8683716258411441e-02 -1.3263096088951510e-02 -4.5607321000770314e-02 + 17 -1.2893753425925469e-02 9.7485795481259876e-03 3.7300775385779882e-02 + 18 -8.0065894051881126e-04 -8.6270684963651845e-04 -1.4483015146944883e-03 + 19 1.2452389852680478e-03 -2.5061098313021992e-03 7.2998634573395666e-03 + 20 3.5930058838403154e-03 3.6938858373569169e-03 3.2322734729321036e-03 + 21 -1.4689219027528943e-03 -2.7352134530946970e-04 7.0581593448005068e-04 + 22 -7.0694199260273186e-03 -4.2577148857392616e-03 2.8079115157198702e-04 + 23 6.0446963222438423e-03 -1.4000131442962716e-03 2.5819754631691569e-03 + 24 3.1926442964369620e-04 -9.9445591935644361e-04 1.5000033448111768e-04 + 25 1.3789825021844635e-04 -4.4335889596263606e-03 -8.1808100227326308e-04 + 26 2.0485904735292647e-03 2.7813359659683355e-03 4.3245727170611661e-03 + 27 4.5604110580961169e-04 -1.0305524671180913e-03 2.1188063421234002e-04 + 28 -6.2544520944133042e-03 1.4127711036803785e-03 -1.8429821866102578e-03 + 29 6.4110628696208540e-04 3.1273432221612493e-03 3.7253671295737097e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-smd_couple.yaml b/unittest/force-styles/tests/fix-timestep-smd_couple.yaml index 7207392b84..9b9c5d93bf 100644 --- a/unittest/force-styles/tests/fix-timestep-smd_couple.yaml +++ b/unittest/force-styles/tests/fix-timestep-smd_couple.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:58 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix smd @@ -44,33 +45,33 @@ run_pos: ! |2 28 -2.7473562684507415e+00 -4.0200819932373095e+00 1.5830052163429609e+00 29 -1.3126000191347424e+00 -3.5962518039468825e+00 2.2746342468721439e+00 run_vel: ! |2 - 1 7.7726230019725968e-03 1.6515604235752497e-02 4.7084528102094153e-03 - 2 5.0521980037732178e-03 5.1783680709551741e-03 -1.5190666845241786e-03 - 3 -8.6277806782930240e-03 -1.2927353561091700e-02 -4.1801915954398361e-03 - 4 -4.1678555976319975e-03 -6.5730910791134793e-03 -1.2002375519405187e-03 - 5 -1.1419912349849785e-02 -9.8914799705415533e-03 -2.9228473059740171e-03 + 1 7.7726230019725968e-03 1.6515604235752497e-02 4.7084528102094101e-03 + 2 5.0521980037732178e-03 5.1783680709551810e-03 -1.5190666845241721e-03 + 3 -8.6277806782930257e-03 -1.2927353561091690e-02 -4.1801915954398292e-03 + 4 -4.1678555976319932e-03 -6.5730910791134871e-03 -1.2002375519405274e-03 + 5 -1.1419912349849780e-02 -9.8914799705415585e-03 -2.9228473059740192e-03 6 -4.0074614510611659e-02 4.6816259489624000e-02 3.7066718541337952e-02 7 5.1238834094741094e-04 -1.0129326104255250e-02 -5.1650025361320608e-02 8 7.5085199000192969e-03 -3.3515273526413349e-03 3.4475324998200864e-02 9 1.1664662767161271e-03 3.7357527367169775e-03 1.4965635304900535e-02 - 10 2.8803495470410563e-02 -2.9250380570349056e-02 -1.5099850889577411e-02 + 10 2.8803495470410570e-02 -2.9250380570349056e-02 -1.5099850889577415e-02 11 -5.1815475072653321e-03 -3.7489403643505910e-03 -2.4281839126702367e-03 - 12 1.8716938827550544e-03 -3.4854325654219963e-04 -3.1458505529118491e-03 - 13 2.3552227171042581e-03 5.8163043029152732e-03 -8.7644804688818143e-04 - 14 3.1266668969159579e-03 -5.7948014134184640e-03 -4.0296166285917166e-03 - 15 -2.2527456994078450e-03 -5.8562748588176497e-03 6.2120749998211006e-03 + 12 1.8716938827550594e-03 -3.4854325654219568e-04 -3.1458505529118551e-03 + 13 2.3552227171042559e-03 5.8163043029152654e-03 -8.7644804688817601e-04 + 14 3.1266668969159514e-03 -5.7948014134184709e-03 -4.0296166285917149e-03 + 15 -2.2527456994078515e-03 -5.8562748588176505e-03 6.2120749998211024e-03 16 1.8283548626239536e-02 -1.3263268052351038e-02 -4.5720424911742705e-02 - 17 -1.3294221336147188e-02 9.7519646442611810e-03 3.7214761865470757e-02 - 18 3.9640579409797295e-05 -8.6101165098007157e-04 -1.2756344415375386e-03 - 19 2.0855377862032537e-03 -2.5044165246116217e-03 7.4725328890411528e-03 - 20 4.4333047339112051e-03 3.6955792265580007e-03 3.4049430634003901e-03 - 21 -6.2862327973669163e-04 -2.7182823424071168e-04 8.7848590735384151e-04 - 22 -6.2291212162052462e-03 -4.2560217024599683e-03 4.5346097223936393e-04 - 23 6.8849950279618686e-03 -1.3983199743792063e-03 2.7546452793490652e-03 - 24 1.1595624343847216e-03 -9.9276336691609670e-04 3.2266998867167923e-04 - 25 9.7819634209070144e-04 -4.4318962127766421e-03 -6.4541131929573821e-04 - 26 2.8888891245136025e-03 2.7830290670494374e-03 4.4972425326910192e-03 - 27 4.5604123869302072e-04 -1.0305522713327899e-03 2.1188056140041732e-04 - 28 -6.2544520848976121e-03 1.4127711189127388e-03 -1.8429821893333784e-03 - 29 6.4110631808250934e-04 3.1273432751698018e-03 3.7253671072579545e-03 + 17 -1.3294221336147188e-02 9.7519646442611758e-03 3.7214761865470757e-02 + 18 3.9640579409797308e-05 -8.6101165098007070e-04 -1.2756344415375410e-03 + 19 2.0855377862032511e-03 -2.5044165246116265e-03 7.4725328890411571e-03 + 20 4.4333047339112069e-03 3.6955792265580042e-03 3.4049430634003949e-03 + 21 -6.2862327973669120e-04 -2.7182823424071081e-04 8.7848590735383890e-04 + 22 -6.2291212162052514e-03 -4.2560217024599726e-03 4.5346097223936745e-04 + 23 6.8849950279618695e-03 -1.3983199743792063e-03 2.7546452793490721e-03 + 24 1.1595624343847212e-03 -9.9276336691609432e-04 3.2266998867167777e-04 + 25 9.7819634209069905e-04 -4.4318962127766507e-03 -6.4541131929573713e-04 + 26 2.8888891245136064e-03 2.7830290670494348e-03 4.4972425326910235e-03 + 27 4.5604123869302028e-04 -1.0305522713327873e-03 2.1188056140041651e-04 + 28 -6.2544520848976130e-03 1.4127711189127329e-03 -1.8429821893333784e-03 + 29 6.4110631808251325e-04 3.1273432751697978e-03 3.7253671072579589e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-smd_tether.yaml b/unittest/force-styles/tests/fix-timestep-smd_tether.yaml index c6627219d7..131afe97d5 100644 --- a/unittest/force-styles/tests/fix-timestep-smd_tether.yaml +++ b/unittest/force-styles/tests/fix-timestep-smd_tether.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:58 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix smd @@ -44,33 +45,33 @@ run_pos: ! |2 28 -2.7473562684513446e+00 -4.0200819932379455e+00 1.5830052163433972e+00 29 -1.3126000191360074e+00 -3.5962518039483373e+00 2.2746342468737999e+00 run_vel: ! |2 - 1 8.1896578445966942e-03 1.6497182624808478e-02 4.7854631124065305e-03 - 2 5.4692327709871457e-03 5.1599463865034051e-03 -1.4420564714032239e-03 - 3 -8.2107458456830169e-03 -1.2945775167832857e-02 -4.1031814369285801e-03 - 4 -3.7508208325995693e-03 -6.5915127643323317e-03 -1.1232273543736503e-03 - 5 -1.1002877577984444e-02 -9.9099016483700560e-03 -2.8458371012777734e-03 + 1 8.1896578445966942e-03 1.6497182624808478e-02 4.7854631124065253e-03 + 2 5.4692327709871457e-03 5.1599463865034112e-03 -1.4420564714032187e-03 + 3 -8.2107458456830186e-03 -1.2945775167832850e-02 -4.1031814369285749e-03 + 4 -3.7508208325995646e-03 -6.5915127643323378e-03 -1.1232273543736588e-03 + 5 -1.1002877577984436e-02 -9.9099016483700595e-03 -2.8458371012777747e-03 6 -3.9657579741328934e-02 4.6797837910653395e-02 3.7143728661440042e-02 7 9.2942295689604824e-04 -1.0147747964166206e-02 -5.1573015123813216e-02 - 8 7.9255546313470975e-03 -3.3699490112826008e-03 3.4552335174084084e-02 + 8 7.9255546313470957e-03 -3.3699490112826017e-03 3.4552335174084084e-02 9 1.5835010380539560e-03 3.7173310556220386e-03 1.5042645503465618e-02 - 10 2.9220530248408153e-02 -2.9268802302074300e-02 -1.5022840744168533e-02 + 10 2.9220530248408153e-02 -2.9268802302074300e-02 -1.5022840744168538e-02 11 -4.7645127242282488e-03 -3.7673620683210066e-03 -2.3511737330500233e-03 - 12 2.2887286123100944e-03 -3.6696510551173121e-04 -3.0688403503444173e-03 - 13 2.7722574718472481e-03 5.7978826056110022e-03 -7.9943785940617639e-04 - 14 3.5437016639127098e-03 -5.8132231135701908e-03 -3.9526064357339307e-03 - 15 -1.8357109375584794e-03 -5.8746965489417571e-03 6.2890851955733759e-03 - 16 1.8700583401306779e-02 -1.3281689759786268e-02 -4.5643414777918057e-02 - 17 -1.2877186554056844e-02 9.7335429720278640e-03 3.7291772041646187e-02 - 18 -8.0065794784127842e-04 -8.6270473318957931e-04 -1.4483040708792177e-03 - 19 1.2452390835953999e-03 -2.5061097117751712e-03 7.2998631009061109e-03 - 20 3.5930060229609519e-03 3.6938860309638946e-03 3.2322732687764116e-03 - 21 -1.4689220415370131e-03 -2.7352129228512843e-04 7.0581624788954435e-04 - 22 -7.0694199255550757e-03 -4.2577148922697669e-03 2.8079117649832622e-04 - 23 6.0446963114215869e-03 -1.4000131612979718e-03 2.5819754850066423e-03 - 24 3.1926368038111313e-04 -9.9445664712597510e-04 1.4999997027479131e-04 - 25 1.3789754607814955e-04 -4.4335894891963700e-03 -8.1808136738145036e-04 - 26 2.0485904035860525e-03 2.7813358633819677e-03 4.3245727149222469e-03 - 27 4.5604120245292066e-04 -1.0305523037387738e-03 2.1188058391297283e-04 - 28 -6.2544520861927766e-03 1.4127711175851688e-03 -1.8429821884760073e-03 - 29 6.4110631529538345e-04 3.1273432718600222e-03 3.7253671105959138e-03 + 12 2.2887286123100983e-03 -3.6696510551172747e-04 -3.0688403503444234e-03 + 13 2.7722574718472459e-03 5.7978826056109987e-03 -7.9943785940617107e-04 + 14 3.5437016639127041e-03 -5.8132231135701951e-03 -3.9526064357339290e-03 + 15 -1.8357109375584839e-03 -5.8746965489417579e-03 6.2890851955733811e-03 + 16 1.8700583401306776e-02 -1.3281689759786268e-02 -4.5643414777918057e-02 + 17 -1.2877186554056844e-02 9.7335429720278588e-03 3.7291772041646187e-02 + 18 -8.0065794784127842e-04 -8.6270473318957887e-04 -1.4483040708792201e-03 + 19 1.2452390835953964e-03 -2.5061097117751751e-03 7.2998631009061161e-03 + 20 3.5930060229609527e-03 3.6938860309638972e-03 3.2322732687764168e-03 + 21 -1.4689220415370120e-03 -2.7352129228512756e-04 7.0581624788954142e-04 + 22 -7.0694199255550792e-03 -4.2577148922697721e-03 2.8079117649832964e-04 + 23 6.0446963114215886e-03 -1.4000131612979718e-03 2.5819754850066492e-03 + 24 3.1926368038111242e-04 -9.9445664712597272e-04 1.4999997027478976e-04 + 25 1.3789754607814760e-04 -4.4335894891963787e-03 -8.1808136738144928e-04 + 26 2.0485904035860568e-03 2.7813358633819655e-03 4.3245727149222512e-03 + 27 4.5604120245292044e-04 -1.0305523037387708e-03 2.1188058391297202e-04 + 28 -6.2544520861927784e-03 1.4127711175851625e-03 -1.8429821884760073e-03 + 29 6.4110631529538790e-04 3.1273432718600187e-03 3.7253671105959172e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-spring_chunk.yaml b/unittest/force-styles/tests/fix-timestep-spring_chunk.yaml index 266d88dc85..fdb12449eb 100644 --- a/unittest/force-styles/tests/fix-timestep-spring_chunk.yaml +++ b/unittest/force-styles/tests/fix-timestep-spring_chunk.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:58 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 1e-11 +skip_tests: prerequisites: ! | atom full fix spring/chunk @@ -13,13 +14,13 @@ post_commands: ! | fix test solute spring/chunk 10.0 mol com input_file: in.fourmol natoms: 29 -global_scalar: 0.00150643062337391 +global_scalar: 0.0015064306233739035 run_pos: ! |2 1 -2.7039466507239462e-01 2.4911394617880092e+00 -1.6690737231056296e-01 2 3.1010122768328879e-01 2.9611589338277575e+00 -8.5461248366340781e-01 3 -7.0392460911452404e-01 1.2304744899143512e+00 -6.2772412657984222e-01 4 -1.5817550043018951e+00 1.4836642574190744e+00 -1.2538199315725116e+00 - 5 -9.0713670028527926e-01 9.2644450405390477e-01 3.9959325076039037e-01 + 5 -9.0713670028527926e-01 9.2644450405390477e-01 3.9959325076039032e-01 6 2.4836774058316266e-01 2.8306202887482079e-01 -1.2313790211702345e+00 7 3.4149618856823633e-01 -2.2723103032076725e-02 -2.5291782002728289e+00 8 1.1743069518257749e+00 -4.8858533080502903e-01 -6.3786027586713800e-01 @@ -38,40 +39,40 @@ run_pos: ! |2 21 4.9042004233221554e+00 -4.0750508982058031e+00 -3.6211861688914588e+00 22 4.3584231714404913e+00 -4.2124280236247813e+00 -4.4614391175232928e+00 23 5.7441259009277346e+00 -3.5820118748237770e+00 -3.8767908274855909e+00 - 24 2.0687885826955674e+00 3.1515550738671596e+00 3.1548778739329566e+00 + 24 2.0687885826955674e+00 3.1515550738671596e+00 3.1548778739329562e+00 25 1.3043993576001649e+00 3.2667329537232512e+00 2.5110244241852970e+00 26 2.5807879647318708e+00 4.0119806436999808e+00 3.2210449513704411e+00 27 -1.9608878136387959e+00 -4.3563688177752127e+00 2.1096520197822728e+00 28 -2.7471097690679747e+00 -4.0201096178908076e+00 1.5828279245795154e+00 - 29 -1.3123535197516709e+00 -3.5962794285999453e+00 2.2744569551087350e+00 + 29 -1.3123535197516709e+00 -3.5962794285999458e+00 2.2744569551087350e+00 run_vel: ! |2 - 1 8.2391792369945933e-03 1.6438210431911154e-02 4.8466396546764587e-03 - 2 5.5187515357448674e-03 5.1009727439991059e-03 -1.3808762794824481e-03 - 3 -8.1613173851465323e-03 -1.3004672634959349e-02 -4.0419997879360811e-03 - 4 -3.7013110268827847e-03 -6.6504700541051122e-03 -1.0620290427688062e-03 - 5 -1.0953343579757566e-02 -9.9688939579476062e-03 -2.7846596077833233e-03 + 1 8.2391792369945933e-03 1.6438210431911154e-02 4.8466396546764535e-03 + 2 5.5187515357448692e-03 5.1009727439991102e-03 -1.3808762794824425e-03 + 3 -8.1613173851465357e-03 -1.3004672634959346e-02 -4.0419997879360741e-03 + 4 -3.7013110268827817e-03 -6.6504700541051183e-03 -1.0620290427688151e-03 + 5 -1.0953343579757559e-02 -9.9688939579476148e-03 -2.7846596077833229e-03 6 -3.9627794721568313e-02 4.6754811634285347e-02 3.7192208638621563e-02 7 9.7890622933070946e-04 -1.0206782168930003e-02 -5.1512311389882055e-02 - 8 7.8618361417075872e-03 -3.3078882607816035e-03 3.4531446917267020e-02 + 8 7.8618361417075872e-03 -3.3078882607816048e-03 3.4531446917267020e-02 9 1.5032844351316340e-03 3.7927192074966782e-03 1.5010708889964666e-02 - 10 2.9140729691997370e-02 -2.9194095046793215e-02 -1.5055379032590480e-02 + 10 2.9140729691997380e-02 -2.9194095046793215e-02 -1.5055379032590480e-02 11 -4.8448308259422456e-03 -3.6920754803050761e-03 -2.3835363308950717e-03 - 12 2.2084299651528591e-03 -2.9168788114909461e-04 -3.1012020517987566e-03 - 13 2.6919570760867966e-03 5.8731594041239827e-03 -8.3179740851102243e-04 - 14 3.4634010415991300e-03 -5.7379466155056446e-03 -3.9849657546930711e-03 - 15 -1.9160117674839657e-03 -5.7994201845185164e-03 6.2567260808431089e-03 - 16 1.8620286902083137e-02 -1.3206416893569880e-02 -4.5675777789058840e-02 - 17 -1.2957486948358956e-02 9.8088191535149472e-03 3.7259412994009797e-02 - 18 -8.9827950617384479e-04 -7.2910542260446072e-04 -1.7299645349958708e-03 - 19 1.1476174779710114e-03 -2.3725104247018605e-03 7.0182026640168219e-03 - 20 3.4953844133924460e-03 3.8274853118860966e-03 2.9506128446975901e-03 - 21 -1.2679016851845891e-03 -7.6471662408770285e-05 5.4006461308053961e-04 - 22 -6.8683995853632326e-03 -4.0606652263220234e-03 1.1503957004042160e-04 - 23 6.2457166531648019e-03 -1.2029634957433776e-03 2.4162238784361063e-03 - 24 1.7379490178209351e-04 -7.5832030593805727e-04 -2.2597269496337065e-05 - 25 -7.5712376373615023e-06 -4.1974531497480216e-03 -9.9067862512451253e-04 - 26 1.9031216426784782e-03 3.0174722303355707e-03 4.1519755012089576e-03 - 27 7.2014620941966766e-04 -1.0601592030480137e-03 2.1924430684779573e-05 - 28 -5.9903471097165874e-03 1.3831641870693594e-03 -2.0329383278098810e-03 - 29 9.0521129402142120e-04 3.0977363443754624e-03 3.5354109686444916e-03 + 12 2.2084299651528635e-03 -2.9168788114909022e-04 -3.1012020517987618e-03 + 13 2.6919570760867940e-03 5.8731594041239775e-03 -8.3179740851101734e-04 + 14 3.4634010415991240e-03 -5.7379466155056524e-03 -3.9849657546930702e-03 + 15 -1.9160117674839707e-03 -5.7994201845185190e-03 6.2567260808431150e-03 + 16 1.8620286902083130e-02 -1.3206416893569875e-02 -4.5675777789058840e-02 + 17 -1.2957486948358956e-02 9.8088191535149437e-03 3.7259412994009797e-02 + 18 -8.9827950617384468e-04 -7.2910542260445986e-04 -1.7299645349958738e-03 + 19 1.1476174779710083e-03 -2.3725104247018665e-03 7.0182026640168271e-03 + 20 3.4953844133924503e-03 3.8274853118860971e-03 2.9506128446975953e-03 + 21 -1.2679016851845878e-03 -7.6471662408769499e-05 5.4006461308053711e-04 + 22 -6.8683995853632369e-03 -4.0606652263220243e-03 1.1503957004042528e-04 + 23 6.2457166531648027e-03 -1.2029634957433778e-03 2.4162238784361132e-03 + 24 1.7379490178209356e-04 -7.5832030593805120e-04 -2.2597269496325511e-05 + 25 -7.5712376373799337e-06 -4.1974531497480138e-03 -9.9067862512451340e-04 + 26 1.9031216426784775e-03 3.0174722303355750e-03 4.1519755012089715e-03 + 27 7.2014620941965822e-04 -1.0601592030480235e-03 2.1924430684776849e-05 + 28 -5.9903471097165883e-03 1.3831641870693575e-03 -2.0329383278098810e-03 + 29 9.0521129402145969e-04 3.0977363443755040e-03 3.5354109686445011e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-spring_couple.yaml b/unittest/force-styles/tests/fix-timestep-spring_couple.yaml index 496f903c1a..231dc78dfa 100644 --- a/unittest/force-styles/tests/fix-timestep-spring_couple.yaml +++ b/unittest/force-styles/tests/fix-timestep-spring_couple.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:58 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix spring @@ -11,7 +12,7 @@ post_commands: ! | fix test solute spring couple solvent 10.0 1.0 1.0 1.0 2.0 input_file: in.fourmol natoms: 29 -global_scalar: 0.0745600021880662 +global_scalar: 0.07456000218806617 global_vector: ! |- 4 -0.5427098662742316 0.008081024001708082 1.0938924727143036 -1.2211470197160226 run_pos: ! |2 @@ -19,7 +20,7 @@ run_pos: ! |2 2 3.1003734035005548e-01 2.9612355031681896e+00 -8.5465767199405718e-01 3 -7.0398846939763016e-01 1.2305510356412508e+00 -6.2776931106751632e-01 4 -1.5818188890389260e+00 1.4837408219517443e+00 -1.2538651252302153e+00 - 5 -9.0720059211686166e-01 9.2652107891551694e-01 3.9954806325973802e-01 + 5 -9.0720059211686166e-01 9.2652107891551683e-01 3.9954806325973802e-01 6 2.4831424985874301e-01 2.8313025503592970e-01 -1.2314173747941828e+00 7 3.4143232102587662e-01 -2.2646510981129606e-02 -2.5292231831151448e+00 8 1.1743522675207747e+00 -4.8863224560038016e-01 -6.3782837073133847e-01 @@ -28,7 +29,7 @@ run_pos: ! |2 11 1.7878002390550529e+00 -1.9921862872359852e+00 -1.8890542863865172e+00 12 3.0062977485450895e+00 -4.9013346491085485e-01 -1.6231838523622695e+00 13 4.0515373405302482e+00 -8.9202007600744393e-01 -1.6399945946163834e+00 - 14 2.6066933791653462e+00 -4.1789249959631031e-01 -2.6633944025034624e+00 + 14 2.6066933791653462e+00 -4.1789249959631036e-01 -2.6633944025034624e+00 15 2.9695257631822840e+00 5.5422617171113153e-01 -1.2341962438029856e+00 16 2.6747000141331685e+00 -2.4124118653971842e+00 -2.3429787773644954e-02 17 2.2153548231391307e+00 -2.0897984786319164e+00 1.1963210378241600e+00 @@ -45,33 +46,33 @@ run_pos: ! |2 28 -2.7473562684513277e+00 -4.0200819932379206e+00 1.5830052163433925e+00 29 -1.3126000191359430e+00 -3.5962518039482481e+00 2.2746342468737524e+00 run_vel: ! |2 - 1 8.1676113764653016e-03 1.6516447354733850e-02 4.7961998659539389e-03 - 2 5.4471863027360165e-03 5.1792111193687913e-03 -1.4313197231574993e-03 - 3 -8.2327923156699390e-03 -1.2926510437224927e-02 -4.0924446861479924e-03 - 4 -3.7728673009448160e-03 -6.5722480313498552e-03 -1.1124906065066043e-03 - 5 -1.1024924046231115e-02 -9.8906369153825419e-03 -2.8351003534056699e-03 - 6 -3.9679626210027671e-02 4.6817102640106599e-02 3.7154465410981712e-02 + 1 8.1676113764653051e-03 1.6516447354733850e-02 4.7961998659539345e-03 + 2 5.4471863027360165e-03 5.1792111193688008e-03 -1.4313197231574939e-03 + 3 -8.2327923156699425e-03 -1.2926510437224918e-02 -4.0924446861479837e-03 + 4 -3.7728673009448108e-03 -6.5722480313498630e-03 -1.1124906065066121e-03 + 5 -1.1024924046231113e-02 -9.8906369153825523e-03 -2.8351003534056712e-03 + 6 -3.9679626210027671e-02 4.6817102640106592e-02 3.7154465410981712e-02 7 9.0737649029424075e-04 -1.0128483230267634e-02 -5.1562278377187978e-02 8 7.9035081634799484e-03 -3.3506842779195667e-03 3.4563071923978395e-02 9 1.5614545698480605e-03 3.7365957889788368e-03 1.5053382251661831e-02 - 10 2.9198483777554480e-02 -2.9249537566295013e-02 -1.5012103993682274e-02 + 10 2.9198483777554480e-02 -2.9249537566295010e-02 -1.5012103993682276e-02 11 -4.7865591937052230e-03 -3.7480973345792369e-03 -2.3404369845686610e-03 - 12 2.2666821424230810e-03 -3.4770036539216509e-04 -3.0581036025248559e-03 - 13 2.7502110031512803e-03 5.8171473405184589e-03 -7.8870111045942410e-04 - 14 3.5216551951876380e-03 -5.7939583798635912e-03 -3.9418696877854152e-03 - 15 -1.8577574059657112e-03 -5.8554318156634260e-03 6.2998219436421867e-03 - 16 1.8678536930086594e-02 -1.3262425025023551e-02 -4.5632678025461573e-02 + 12 2.2666821424230854e-03 -3.4770036539216080e-04 -3.0581036025248620e-03 + 13 2.7502110031512772e-03 5.8171473405184545e-03 -7.8870111045941868e-04 + 14 3.5216551951876315e-03 -5.7939583798635947e-03 -3.9418696877854152e-03 + 15 -1.8577574059657144e-03 -5.8554318156634312e-03 6.2998219436421980e-03 + 16 1.8678536930086583e-02 -1.3262425025023549e-02 -4.5632678025461573e-02 17 -1.2899233023551178e-02 9.7528077053395442e-03 3.7302508790818492e-02 - 18 -7.9440130110467366e-04 -8.6279167842954693e-04 -1.4609173378236297e-03 - 19 1.2514957291990608e-03 -2.5061966621517458e-03 7.2872498362114985e-03 - 20 3.5992626684105246e-03 3.6937990802613915e-03 3.2196600049196173e-03 - 21 -1.4626653887940357e-03 -2.7360825248647872e-04 6.9320297545580442e-04 - 22 -7.0631632801783457e-03 -4.2578018436696483e-03 2.6817791238195924e-04 - 23 6.0509529571508977e-03 -1.4001001126218869e-03 2.5693622209874631e-03 - 24 3.2552032172748307e-04 -9.9454360047283646e-04 1.3738670406201591e-04 - 25 1.4415418785761430e-04 -4.4336764406934228e-03 -8.3069463343274515e-04 - 26 2.0548470485384825e-03 2.7812489122278432e-03 4.3119594512784874e-03 - 27 4.5604120356620184e-04 -1.0305523021206754e-03 2.1188058362517378e-04 - 28 -6.2544520861563657e-03 1.4127711176388342e-03 -1.8429821884847254e-03 - 29 6.4110631543493459e-04 3.1273432720553373e-03 3.7253671105021797e-03 + 18 -7.9440130110467356e-04 -8.6279167842954617e-04 -1.4609173378236325e-03 + 19 1.2514957291990575e-03 -2.5061966621517488e-03 7.2872498362115054e-03 + 20 3.5992626684105281e-03 3.6937990802613937e-03 3.2196600049196234e-03 + 21 -1.4626653887940357e-03 -2.7360825248647785e-04 6.9320297545580182e-04 + 22 -7.0631632801783483e-03 -4.2578018436696501e-03 2.6817791238196347e-04 + 23 6.0509529571508977e-03 -1.4001001126218869e-03 2.5693622209874700e-03 + 24 3.2552032172748232e-04 -9.9454360047283429e-04 1.3738670406201461e-04 + 25 1.4415418785761267e-04 -4.4336764406934332e-03 -8.3069463343274472e-04 + 26 2.0548470485384873e-03 2.7812489122278398e-03 4.3119594512784935e-03 + 27 4.5604120356620146e-04 -1.0305523021206728e-03 2.1188058362517278e-04 + 28 -6.2544520861563674e-03 1.4127711176388277e-03 -1.8429821884847254e-03 + 29 6.4110631543493892e-04 3.1273432720553317e-03 3.7253671105021823e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-spring_self.yaml b/unittest/force-styles/tests/fix-timestep-spring_self.yaml index cf303b8757..d908575cf1 100644 --- a/unittest/force-styles/tests/fix-timestep-spring_self.yaml +++ b/unittest/force-styles/tests/fix-timestep-spring_self.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:58 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full fix spring/self @@ -11,7 +12,7 @@ post_commands: ! | fix test solute spring/self 10.0 xyz input_file: in.fourmol natoms: 29 -global_scalar: 0.126237053707504 +global_scalar: 0.12623705370750438 run_pos: ! |2 1 -2.7045669792379945e-01 2.4912140072031601e+00 -1.6695897908630153e-01 2 3.1003572362014503e-01 2.9612290242130319e+00 -8.5466689099875615e-01 @@ -43,33 +44,33 @@ run_pos: ! |2 28 -2.7473562684513411e+00 -4.0200819932379330e+00 1.5830052163433952e+00 29 -1.3126000191359812e+00 -3.5962518039482934e+00 2.2746342468737817e+00 run_vel: ! |2 - 1 8.1685220941861477e-03 1.6512578512542727e-02 4.7892799147935027e-03 - 2 5.4427456394786321e-03 5.1693257879352481e-03 -1.4414043022813697e-03 - 3 -8.2272458036248344e-03 -1.2923813188884236e-02 -4.0970749471144615e-03 - 4 -3.7660861920462392e-03 -6.5659911420830304e-03 -1.1120922532834639e-03 - 5 -1.1012635909013245e-02 -9.8847866026321087e-03 -2.8391869073674529e-03 + 1 8.1685220941861477e-03 1.6512578512542727e-02 4.7892799147935001e-03 + 2 5.4427456394786321e-03 5.1693257879352533e-03 -1.4414043022813649e-03 + 3 -8.2272458036248362e-03 -1.2923813188884230e-02 -4.0970749471144546e-03 + 4 -3.7660861920462349e-03 -6.5659911420830365e-03 -1.1120922532834726e-03 + 5 -1.1012635909013241e-02 -9.8847866026321157e-03 -2.8391869073674538e-03 6 -3.9665990411620729e-02 4.6803722380071487e-02 3.7135522426802389e-02 7 9.1016763589152859e-04 -1.0126055720737583e-02 -5.1556610019025714e-02 - 8 7.9043585267658447e-03 -3.3496064544244336e-03 3.4549326598010660e-02 + 8 7.9043585267658430e-03 -3.3496064544244345e-03 3.4549326598010660e-02 9 1.5620907286754389e-03 3.7378245105921431e-03 1.5036774253075934e-02 - 10 2.9193799040059056e-02 -2.9242248165535563e-02 -1.5014281912567769e-02 + 10 2.9193799040059056e-02 -2.9242248165535563e-02 -1.5014281912567770e-02 11 -4.7797459644718264e-03 -3.7436196398511232e-03 -2.3410499103477603e-03 - 12 2.2686069875175268e-03 -3.4732729502899915e-04 -3.0627334265471585e-03 - 13 2.7456854188010046e-03 5.8081889921879921e-03 -7.9308949311655624e-04 - 14 3.5223319737918736e-03 -5.7842699330258604e-03 -3.9396805101296860e-03 - 15 -1.8475459117759320e-03 -5.8469790281561471e-03 6.2849983323582459e-03 - 16 1.8676069228413028e-02 -1.3258381729410443e-02 -4.5625616778429308e-02 - 17 -1.2893668780819389e-02 9.7505325833410275e-03 3.7288200735675299e-02 - 18 -8.0065794869105841e-04 -8.6270473288011841e-04 -1.4483040693746114e-03 - 19 1.2452390836051527e-03 -2.5061097119616145e-03 7.2998631010316572e-03 - 20 3.5930060229538122e-03 3.6938860309035453e-03 3.2322732687958939e-03 - 21 -1.4689220366910719e-03 -2.7352129796142619e-04 7.0581624168175605e-04 - 22 -7.0694199254520704e-03 -4.2577148925036995e-03 2.8079117611208874e-04 - 23 6.0446963117617479e-03 -1.4000131614895336e-03 2.5819754846773532e-03 - 24 3.1926367911308746e-04 -9.9445664741642701e-04 1.4999996978363211e-04 - 25 1.3789754526895331e-04 -4.4335894884219513e-03 -8.1808136698604508e-04 - 26 2.0485904035342827e-03 2.7813358633902779e-03 4.3245727149365549e-03 - 27 4.5604120291626980e-04 -1.0305523027244997e-03 2.1188058375789165e-04 - 28 -6.2544520861839191e-03 1.4127711176141673e-03 -1.8429821884806304e-03 - 29 6.4110631535703347e-04 3.1273432719578064e-03 3.7253671105604096e-03 + 12 2.2686069875175316e-03 -3.4732729502899497e-04 -3.0627334265471650e-03 + 13 2.7456854188010020e-03 5.8081889921879817e-03 -7.9308949311655092e-04 + 14 3.5223319737918667e-03 -5.7842699330258648e-03 -3.9396805101296825e-03 + 15 -1.8475459117759364e-03 -5.8469790281561471e-03 6.2849983323582511e-03 + 16 1.8676069228413028e-02 -1.3258381729410438e-02 -4.5625616778429308e-02 + 17 -1.2893668780819389e-02 9.7505325833410258e-03 3.7288200735675299e-02 + 18 -8.0065794869105819e-04 -8.6270473288011819e-04 -1.4483040693746142e-03 + 19 1.2452390836051499e-03 -2.5061097119616180e-03 7.2998631010316650e-03 + 20 3.5930060229538143e-03 3.6938860309035470e-03 3.2322732687958995e-03 + 21 -1.4689220366910704e-03 -2.7352129796142532e-04 7.0581624168175334e-04 + 22 -7.0694199254520765e-03 -4.2577148925037030e-03 2.8079117611209205e-04 + 23 6.0446963117617505e-03 -1.4000131614895336e-03 2.5819754846773601e-03 + 24 3.1926367911308686e-04 -9.9445664741642462e-04 1.4999996978363057e-04 + 25 1.3789754526895179e-04 -4.4335894884219599e-03 -8.1808136698604454e-04 + 26 2.0485904035342870e-03 2.7813358633902757e-03 4.3245727149365584e-03 + 27 4.5604120291626942e-04 -1.0305523027244966e-03 2.1188058375789067e-04 + 28 -6.2544520861839200e-03 1.4127711176141612e-03 -1.8429821884806304e-03 + 29 6.4110631535703737e-04 3.1273432719578029e-03 3.7253671105604122e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-spring_tether.yaml b/unittest/force-styles/tests/fix-timestep-spring_tether.yaml index d7172d3811..4786031d3d 100644 --- a/unittest/force-styles/tests/fix-timestep-spring_tether.yaml +++ b/unittest/force-styles/tests/fix-timestep-spring_tether.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix spring @@ -11,12 +12,12 @@ post_commands: ! | fix test solute spring tether 10.0 2.4 -1.0 -1.0 0.1 input_file: in.fourmol natoms: 29 -global_scalar: 9.11717430556703 +global_scalar: 9.117174305567033 global_vector: ! |- 4 11.113384922716287 -7.445466745780351 -1.84423062775835 13.503462004661646 run_pos: ! |2 1 -2.7039445160220293e-01 2.4911750347350039e+00 -1.6696866740483340e-01 - 2 3.1010144189019911e-01 2.9611945072729084e+00 -8.5467377985868331e-01 + 2 3.1010144189019911e-01 2.9611945072729084e+00 -8.5467377985868320e-01 3 -7.0392436785589674e-01 1.2305100397484134e+00 -6.2778541893442352e-01 4 -1.5817547874987234e+00 1.4836998260563596e+00 -1.2538812330947535e+00 5 -9.0713649057669887e-01 9.2648008302018825e-01 3.9953195539526082e-01 @@ -37,7 +38,7 @@ run_pos: ! |2 20 2.7727573005678532e+00 3.6923910449610058e+00 -3.9330842459132671e+00 21 4.9040128073151736e+00 -4.0752348172889405e+00 -3.6210314709819205e+00 22 4.3582355554439802e+00 -4.2126119427284330e+00 -4.4612844196310011e+00 - 23 5.7439382849303913e+00 -3.5821957939272373e+00 -3.8766361295932019e+00 + 23 5.7439382849303913e+00 -3.5821957939272373e+00 -3.8766361295932015e+00 24 2.0689243582435939e+00 3.1513346907270376e+00 3.1550389754821992e+00 25 1.3045351331497936e+00 3.2665125705830405e+00 2.5111855257416944e+00 26 2.5809237402711376e+00 4.0117602605482166e+00 3.2212060529088933e+00 @@ -45,33 +46,33 @@ run_pos: ! |2 28 -2.7473562684513855e+00 -4.0200819932379988e+00 1.5830052163434218e+00 29 -1.3126000191361185e+00 -3.5962518039484848e+00 2.2746342468739131e+00 run_vel: ! |2 - 1 8.2317166159842012e-03 1.6475450610900021e-02 4.7800782322444200e-03 - 2 5.5112915414102306e-03 5.1382143682408548e-03 -1.4474413507851044e-03 - 3 -8.1686870738110189e-03 -1.2967507183394194e-02 -4.1085663183506637e-03 - 4 -3.7087620621996252e-03 -6.6132447827252326e-03 -1.1286122339068971e-03 - 5 -1.0960818807548036e-02 -9.9316336666316757e-03 -2.8512219806973815e-03 - 6 -3.9615520972011230e-02 4.6776105895018065e-02 3.7138343780638496e-02 + 1 8.2317166159841994e-03 1.6475450610900021e-02 4.7800782322444208e-03 + 2 5.5112915414102428e-03 5.1382143682408704e-03 -1.4474413507851132e-03 + 3 -8.1686870738110207e-03 -1.2967507183394183e-02 -4.1085663183506567e-03 + 4 -3.7087620621996209e-03 -6.6132447827252404e-03 -1.1286122339069049e-03 + 5 -1.0960818807548033e-02 -9.9316336666316861e-03 -2.8512219806973828e-03 + 6 -3.9615520972011237e-02 4.6776105895018065e-02 3.7138343780638496e-02 7 9.7148172500957696e-04 -1.0169479983325357e-02 -5.1578400002915900e-02 - 8 7.9676134004255054e-03 -3.3916810304883090e-03 3.4546950293483661e-02 + 8 7.9676134004255036e-03 -3.3916810304883095e-03 3.4546950293483661e-02 9 1.6255598083025895e-03 3.6955990370543829e-03 1.5037260623673309e-02 - 10 2.9262589020948714e-02 -2.9290534323555596e-02 -1.5028225626517684e-02 + 10 2.9262589020948717e-02 -2.9290534323555589e-02 -1.5028225626517686e-02 11 -4.7224539526641964e-03 -3.7890940875562576e-03 -2.3565586134122528e-03 - 12 2.3307873840729895e-03 -3.8869713425718818e-04 -3.0742252290913040e-03 - 13 2.8143162423885058e-03 5.7761505855278934e-03 -8.0482274006447028e-04 - 14 3.5857604346995003e-03 -5.8349551328465863e-03 -3.9579913154457460e-03 - 15 -1.7936521671505239e-03 -5.8964285676622562e-03 6.2837003158612466e-03 - 16 1.8742642174161689e-02 -1.3303421779370800e-02 -4.5648799661902446e-02 - 17 -1.2835127781642990e-02 9.7118109542861809e-03 3.7286387160512018e-02 - 18 -8.0065794480950643e-04 -8.6270473366688012e-04 -1.4483040685934071e-03 - 19 1.2452390836179981e-03 -2.5061097117135929e-03 7.2998631013092086e-03 - 20 3.5930060229117915e-03 3.6938860309082195e-03 3.2322732689566043e-03 - 21 -1.4689220479142445e-03 -2.7352128349868046e-04 7.0581625710284754e-04 - 22 -7.0694199256499893e-03 -4.2577148919313475e-03 2.8079117705082096e-04 - 23 6.0446963109421431e-03 -1.4000131609649214e-03 2.5819754855140034e-03 - 24 3.1926368176694604e-04 -9.9445664760917755e-04 1.4999996820886421e-04 - 25 1.3789754635238288e-04 -4.4335894910151443e-03 -8.1808137066796812e-04 - 26 2.0485904035467272e-03 2.7813358632613932e-03 4.3245727147235690e-03 - 27 4.5604119983022373e-04 -1.0305523067564162e-03 2.1188058519480991e-04 - 28 -6.2544520862799690e-03 1.4127711174755373e-03 -1.8429821884288053e-03 - 29 6.4110631505295867e-04 3.1273432715304369e-03 3.7253671108249272e-03 + 12 2.3307873840729939e-03 -3.8869713425718406e-04 -3.0742252290913083e-03 + 13 2.8143162423885041e-03 5.7761505855278821e-03 -8.0482274006446496e-04 + 14 3.5857604346994942e-03 -5.8349551328465941e-03 -3.9579913154457426e-03 + 15 -1.7936521671505284e-03 -5.8964285676622614e-03 6.2837003158612535e-03 + 16 1.8742642174161682e-02 -1.3303421779370798e-02 -4.5648799661902446e-02 + 17 -1.2835127781642990e-02 9.7118109542861791e-03 3.7286387160512018e-02 + 18 -8.0065794480950632e-04 -8.6270473366687991e-04 -1.4483040685934101e-03 + 19 1.2452390836179953e-03 -2.5061097117135968e-03 7.2998631013092155e-03 + 20 3.5930060229117920e-03 3.6938860309082221e-03 3.2322732689566099e-03 + 21 -1.4689220479142469e-03 -2.7352128349868128e-04 7.0581625710284667e-04 + 22 -7.0694199256499911e-03 -4.2577148919313509e-03 2.8079117705082156e-04 + 23 6.0446963109421518e-03 -1.4000131609649162e-03 2.5819754855140038e-03 + 24 3.1926368176694533e-04 -9.9445664760917517e-04 1.4999996820886272e-04 + 25 1.3789754635238060e-04 -4.4335894910151512e-03 -8.1808137066796737e-04 + 26 2.0485904035467315e-03 2.7813358632613914e-03 4.3245727147235725e-03 + 27 4.5604119983022341e-04 -1.0305523067564136e-03 2.1188058519480910e-04 + 28 -6.2544520862799725e-03 1.4127711174755310e-03 -1.8429821884288053e-03 + 29 6.4110631505296300e-04 3.1273432715304326e-03 3.7253671108249294e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-temp_berendsen.yaml b/unittest/force-styles/tests/fix-timestep-temp_berendsen.yaml index 631f7c2cae..ffe3c5e2a5 100644 --- a/unittest/force-styles/tests/fix-timestep-temp_berendsen.yaml +++ b/unittest/force-styles/tests/fix-timestep-temp_berendsen.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full fix temp/berendsen @@ -11,7 +12,7 @@ post_commands: ! | fix test solute temp/berendsen 50.0 ${t_target} 1.0 input_file: in.fourmol natoms: 29 -global_scalar: 140.500399901528 +global_scalar: 140.50039990152794 run_pos: ! |2 1 -2.7309636642471763e-01 2.4861645745691683e+00 -1.6828848361402490e-01 2 3.0754156828804369e-01 2.9580811430810168e+00 -8.5566344544442696e-01 @@ -43,23 +44,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 4.4822485045367504e-03 9.2630275931323714e-03 2.7690954442220936e-03 - 2 2.5115450429997297e-03 1.9432770966180499e-03 -1.6028636434240902e-03 - 3 -4.3937474121539854e-03 -7.7137150893059059e-03 -2.2604818247973606e-03 - 4 -1.9476891076786384e-03 -3.4752865444196575e-03 2.5858331694165467e-04 - 5 -6.0140772566964372e-03 -5.8056118324908155e-03 -1.6285179811875374e-03 + 1 4.4822485045367512e-03 9.2630275931323714e-03 2.7690954442220915e-03 + 2 2.5115450429997305e-03 1.9432770966180540e-03 -1.6028636434240874e-03 + 3 -4.3937474121539862e-03 -7.7137150893059050e-03 -2.2604818247973571e-03 + 4 -1.9476891076786360e-03 -3.4752865444196606e-03 2.5858331694165017e-04 + 5 -6.0140772566964337e-03 -5.8056118324908207e-03 -1.6285179811875378e-03 6 -2.2469338308920575e-02 2.6184066673584038e-02 2.0084128049821442e-02 7 5.5310241062432727e-04 -5.4895662329791485e-03 -2.8451095082690465e-02 - 8 4.3820080553155973e-03 -1.7125373775392955e-03 1.9574889525765377e-02 + 8 4.3820080553155965e-03 -1.7125373775392961e-03 1.9574889525765377e-02 9 6.1123931362892586e-04 2.7099585868545638e-03 8.3091915039055237e-03 - 10 1.6488027562775176e-02 -1.6715055435345464e-02 -8.4916986007994542e-03 + 10 1.6488027562775179e-02 -1.6715055435345464e-02 -8.4916986007994542e-03 11 -2.6493638654309275e-03 -1.8108088716662662e-03 -7.1397665423713101e-04 - 12 1.0553014594281446e-03 -4.9095325173559483e-05 -1.4582671613828872e-03 - 13 6.8186312546743191e-04 2.5433794096564773e-03 -2.8303405188633229e-04 - 14 2.0318309992730424e-03 -2.4195214229911048e-03 -1.4031089865427190e-03 - 15 -1.0420290545722850e-04 -2.6462739410254661e-03 2.8946287413495492e-03 - 16 1.0435719112539276e-02 -7.2849035729913086e-03 -2.5728092378723793e-02 - 17 -7.3214526097835405e-03 5.3566310662169067e-03 2.0611725900352998e-02 + 12 1.0553014594281479e-03 -4.9095325173557124e-05 -1.4582671613828904e-03 + 13 6.8186312546743017e-04 2.5433794096564734e-03 -2.8303405188632926e-04 + 14 2.0318309992730394e-03 -2.4195214229911070e-03 -1.4031089865427172e-03 + 15 -1.0420290545723117e-04 -2.6462739410254665e-03 2.8946287413495531e-03 + 16 1.0435719112539269e-02 -7.2849035729913069e-03 -2.5728092378723793e-02 + 17 -7.3214526097835405e-03 5.3566310662169041e-03 2.0611725900352998e-02 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-temp_csld.yaml b/unittest/force-styles/tests/fix-timestep-temp_csld.yaml index 8266fe11c1..b09c2527cc 100644 --- a/unittest/force-styles/tests/fix-timestep-temp_csld.yaml +++ b/unittest/force-styles/tests/fix-timestep-temp_csld.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full fix temp/csld @@ -11,7 +12,7 @@ post_commands: ! | fix test solute temp/csld 50.0 ${t_target} 1.0 62823 input_file: in.fourmol natoms: 29 -global_scalar: 150.876840894722 +global_scalar: 150.87684089472174 run_pos: ! |2 1 -2.7647311866382945e-01 2.4857065646723955e+00 -1.6617735618091201e-01 2 3.0499516303476115e-01 2.9537709384435074e+00 -8.5187606183120801e-01 @@ -28,7 +29,7 @@ run_pos: ! |2 13 4.0485629820926592e+00 -8.9431038872519708e-01 -1.6345003838044976e+00 14 2.6060153448114884e+00 -4.1286533645721485e-01 -2.6584607156586810e+00 15 2.9703775066451663e+00 5.6063984758286523e-01 -1.2411803092256180e+00 - 16 2.6656970686950041e+00 -2.4008304027486727e+00 2.4324587822466010e-04 + 16 2.6656970686950041e+00 -2.4008304027486727e+00 2.4324587822466097e-04 17 2.2170696923898499e+00 -2.0966249045214056e+00 1.1748374924569560e+00 18 2.1384791188033843e+00 3.0177261773770208e+00 -3.5160827596876225e+00 19 1.5349125211132961e+00 2.6315969880333707e+00 -4.2472859440220647e+00 @@ -43,23 +44,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 -6.1518106640055098e-04 9.8413236728091859e-03 2.6821401423517848e-03 - 2 5.7584895033439311e-03 -6.4512016069715183e-03 -4.6331491821159322e-03 - 3 -4.3045744902141230e-03 -1.1357763612046034e-03 -1.5278167433944827e-03 - 4 -7.9024210036195315e-04 8.4724079430485693e-03 8.7245281838652239e-03 - 5 2.7579652970089745e-03 -5.9025323603549475e-04 -2.5454023443268127e-03 + 1 -6.1518106640055055e-04 9.8413236728091859e-03 2.6821401423517805e-03 + 2 5.7584895033439320e-03 -6.4512016069715149e-03 -4.6331491821159313e-03 + 3 -4.3045744902141230e-03 -1.1357763612045999e-03 -1.5278167433944814e-03 + 4 -7.9024210036195055e-04 8.4724079430485676e-03 8.7245281838652222e-03 + 5 2.7579652970089771e-03 -5.9025323603549649e-04 -2.5454023443268136e-03 6 -1.4815311727055615e-02 2.0221004909579707e-02 1.5396636244631938e-02 7 6.3241608228865333e-04 -1.0634159681637320e-03 -1.6769555657594071e-02 8 1.5893486075269094e-03 -6.1660323394415405e-04 1.3789272460195160e-02 9 7.4801357958314968e-03 -1.7324571377721242e-04 5.5874995558103397e-03 - 10 1.3183178250648638e-02 -7.4440255996034814e-03 -1.4024578089719738e-03 + 10 1.3183178250648639e-02 -7.4440255996034797e-03 -1.4024578089719738e-03 11 -3.6967525507180790e-03 -7.9577777641821126e-03 -2.0130547563199353e-03 - 12 1.7809421251718035e-03 -2.4228240354331847e-04 -2.9652050547483645e-03 - 13 4.3878889923020296e-04 3.8672876750012147e-03 -6.6580707926174529e-03 - 14 -5.2616323633526024e-04 -4.5860320088099964e-03 5.2733721735657773e-04 - 15 -2.1083712534527002e-03 2.9658835298400901e-03 9.1125829125389391e-04 - 16 6.3044701073886288e-03 -1.5176887611785819e-03 -1.7062686137992850e-02 - 17 -8.3474333369752789e-03 1.5146606349005583e-03 1.4823067912505096e-02 + 12 1.7809421251718048e-03 -2.4228240354331717e-04 -2.9652050547483667e-03 + 13 4.3878889923020138e-04 3.8672876750012130e-03 -6.6580707926174520e-03 + 14 -5.2616323633526251e-04 -4.5860320088099990e-03 5.2733721735657903e-04 + 15 -2.1083712534527019e-03 2.9658835298400892e-03 9.1125829125389673e-04 + 16 6.3044701073886262e-03 -1.5176887611785806e-03 -1.7062686137992850e-02 + 17 -8.3474333369752789e-03 1.5146606349005578e-03 1.4823067912505096e-02 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-temp_csvr.yaml b/unittest/force-styles/tests/fix-timestep-temp_csvr.yaml index 91de6e649c..411a35cfcc 100644 --- a/unittest/force-styles/tests/fix-timestep-temp_csvr.yaml +++ b/unittest/force-styles/tests/fix-timestep-temp_csvr.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full fix temp/csvr @@ -11,10 +12,10 @@ post_commands: ! | fix test solute temp/csvr 50.0 ${t_target} 1.0 82573 input_file: in.fourmol natoms: 29 -global_scalar: 138.691817964765 +global_scalar: 138.6918179647654 run_pos: ! |2 1 -2.7280762260987462e-01 2.4866672893615482e+00 -1.6817690082511103e-01 - 2 3.0792532339926826e-01 2.9586317848907591e+00 -8.5537067987838589e-01 + 2 3.0792532339926826e-01 2.9586317848907591e+00 -8.5537067987838578e-01 3 -7.0155509000995808e-01 1.2337201042383152e+00 -6.2645947625508680e-01 4 -1.5806259405926315e+00 1.4857183624992281e+00 -1.2524138927067634e+00 5 -9.0413749520933206e-01 9.2874389205720931e-01 4.0021691625350447e-01 @@ -27,7 +28,7 @@ run_pos: ! |2 12 3.0054411287235951e+00 -4.8987634219780540e-01 -1.6220627513203476e+00 13 4.0496794476606635e+00 -8.9447232940528654e-01 -1.6395816350351760e+00 14 2.6058661355197810e+00 -4.1525413418121015e-01 -2.6612700962724607e+00 - 15 2.9712318526989474e+00 5.5661112285831083e-01 -1.2366977651516922e+00 + 15 2.9712318526989474e+00 5.5661112285831071e-01 -1.2366977651516922e+00 16 2.6691735451973395e+00 -2.4083535475815920e+00 -9.9660994024412010e-03 17 2.2190855332677919e+00 -2.0928268444165918e+00 1.1849187762465219e+00 18 2.1384791188033843e+00 3.0177261773770208e+00 -3.5160827596876225e+00 @@ -43,23 +44,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 4.6937564710920216e-03 9.6555961564013804e-03 2.8708039254905881e-03 - 2 2.7267170444366185e-03 2.2058192686523290e-03 -1.5353913821082035e-03 - 3 -4.6306766915023894e-03 -7.9351414155915453e-03 -2.3497227140117419e-03 - 4 -2.0674867361574730e-03 -3.6722365151599765e-03 1.1155363952115448e-04 - 5 -6.3227892412089171e-03 -6.0246930339812061e-03 -1.6991048796308555e-03 + 1 4.6937564710920216e-03 9.6555961564013786e-03 2.8708039254905868e-03 + 2 2.7267170444366215e-03 2.2058192686523342e-03 -1.5353913821082024e-03 + 3 -4.6306766915023912e-03 -7.9351414155915401e-03 -2.3497227140117389e-03 + 4 -2.0674867361574699e-03 -3.6722365151599804e-03 1.1155363952114950e-04 + 5 -6.3227892412089162e-03 -6.0246930339812113e-03 -1.6991048796308561e-03 6 -2.3313325205229000e-02 2.7197550589909671e-02 2.0738710039103190e-02 7 5.6010701530313550e-04 -5.7071338016654654e-03 -2.9476037762661333e-02 8 4.5357117797050145e-03 -1.7956042409071231e-03 2.0337353845153724e-02 9 6.9780844880996972e-04 2.7260623247486841e-03 8.7428367624614034e-03 - 10 1.7158823348639104e-02 -1.7353191765645898e-02 -8.8565471428928583e-03 + 10 1.7158823348639104e-02 -1.7353191765645894e-02 -8.8565471428928583e-03 11 -2.7754554284794915e-03 -1.9484853125617634e-03 -8.5708629159661183e-04 - 12 1.1446489442763310e-03 -8.1052477490650056e-05 -1.5736644561053304e-03 - 13 8.6708264237769490e-04 2.7906792431300104e-03 -3.2527835321513224e-04 - 14 2.1170915886558860e-03 -2.6750828934791800e-03 -1.6081787775879092e-03 - 15 -2.7969721465264459e-04 -2.8792217329085164e-03 3.1381108795769806e-03 - 16 1.0810115663068724e-02 -7.5713924362591457e-03 -2.6575629458356204e-02 - 17 -7.5547245737932044e-03 5.5628964952133871e-03 2.1384064341807719e-02 + 12 1.1446489442763336e-03 -8.1052477490649677e-05 -1.5736644561053338e-03 + 13 8.6708264237769317e-04 2.7906792431300069e-03 -3.2527835321512905e-04 + 14 2.1170915886558816e-03 -2.6750828934791831e-03 -1.6081787775879079e-03 + 15 -2.7969721465264785e-04 -2.8792217329085120e-03 3.1381108795769863e-03 + 16 1.0810115663068720e-02 -7.5713924362591448e-03 -2.6575629458356204e-02 + 17 -7.5547245737932018e-03 5.5628964952133871e-03 2.1384064341807719e-02 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-temp_rescale.yaml b/unittest/force-styles/tests/fix-timestep-temp_rescale.yaml index a97c507c86..0c978dbeb2 100644 --- a/unittest/force-styles/tests/fix-timestep-temp_rescale.yaml +++ b/unittest/force-styles/tests/fix-timestep-temp_rescale.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full fix temp/rescale @@ -11,7 +12,7 @@ post_commands: ! | fix test solute temp/rescale 1 50.0 ${t_target} 20.0 1.0 input_file: in.fourmol natoms: 29 -global_scalar: 111.985962801373 +global_scalar: 111.98596280137298 run_pos: ! |2 1 -2.7729494865335724e-01 2.4779635798730588e+00 -1.7051866224911461e-01 2 3.0395344968629251e-01 2.9537772744839752e+00 -8.5662538453936599e-01 @@ -43,23 +44,23 @@ run_pos: ! |2 28 -2.7406520384725965e+00 -4.0207251278130975e+00 1.5828689861678511e+00 29 -1.3108232656499081e+00 -3.5992986322410760e+00 2.2680459788743503e+00 run_vel: ! |2 - 1 9.6432011677382917e-04 2.0918206431136525e-03 6.5734441307324849e-04 - 2 3.4233303069142282e-04 7.8824504103645128e-05 -6.0920701666988201e-04 - 3 -8.7633508078786707e-04 -1.9745201586966483e-03 -5.4496771262573537e-04 - 4 -3.5585971681901943e-04 -6.6843442679431146e-04 3.6391311544098565e-04 - 5 -1.2239421381053110e-03 -1.3309555700875293e-03 -3.5613354898249034e-04 + 1 9.6432011677382939e-04 2.0918206431136525e-03 6.5734441307324794e-04 + 2 3.4233303069142293e-04 7.8824504103646023e-05 -6.0920701666988125e-04 + 3 -8.7633508078786761e-04 -1.9745201586966478e-03 -5.4496771262573472e-04 + 4 -3.5585971681901895e-04 -6.6843442679431222e-04 3.6391311544098468e-04 + 5 -1.2239421381053104e-03 -1.3309555700875303e-03 -3.5613354898249045e-04 6 -5.3524402444485976e-03 6.2174556660276664e-03 5.3112823281305788e-03 7 1.6790334959159760e-04 -1.3277342935088365e-03 -7.0790522659180894e-03 - 8 1.0890623516114438e-03 -3.7846781397169555e-04 4.5802362529212166e-03 + 8 1.0890623516114433e-03 -3.7846781397169566e-04 4.5802362529212166e-03 9 2.0116694408903098e-06 7.7974939299565147e-04 1.6289681937292537e-03 - 10 3.7875178370291606e-03 -3.9319684550802236e-03 -1.8863429931590028e-03 + 10 3.7875178370291611e-03 -3.9319684550802236e-03 -1.8863429931590028e-03 11 -5.5681768400205642e-04 -2.7347383272171411e-04 7.1744375936039917e-05 - 12 1.4470820560752638e-04 4.7979789566033793e-05 -2.1858170352619685e-04 - 13 -1.5076467766005487e-04 2.9399698734277512e-04 -3.3191604890600937e-06 - 14 4.5111079774244590e-04 -2.4312678920895120e-04 -2.9522674835247754e-05 - 15 3.0594540906696011e-04 -3.5345074530384533e-04 4.0656059676120695e-04 - 16 2.5796771091863555e-03 -1.7489980103690638e-03 -6.5532252016967741e-03 - 17 -1.8774249077164148e-03 1.3017860987252995e-03 5.0450593820410622e-03 + 12 1.4470820560752697e-04 4.7979789566034322e-05 -2.1858170352619756e-04 + 13 -1.5076467766005522e-04 2.9399698734277425e-04 -3.3191604890594347e-06 + 14 4.5111079774244508e-04 -2.4312678920895183e-04 -2.9522674835247500e-05 + 15 3.0594540906695935e-04 -3.5345074530384560e-04 4.0656059676120776e-04 + 16 2.5796771091863555e-03 -1.7489980103690633e-03 -6.5532252016967732e-03 + 17 -1.8774249077164148e-03 1.3017860987252993e-03 5.0450593820410622e-03 18 -6.0936815808025862e-04 -9.3774557532468582e-04 -3.3558072507805731e-04 19 -6.9919768291957119e-04 -3.6060777270430031e-03 4.2833405289822791e-03 20 4.7777805013736515e-03 5.1003745845520452e-03 1.8002873923729241e-03 diff --git a/unittest/force-styles/tests/fix-timestep-wall_harmonic_const.yaml b/unittest/force-styles/tests/fix-timestep-wall_harmonic_const.yaml index ebc6fd5bea..57f38b4c37 100644 --- a/unittest/force-styles/tests/fix-timestep-wall_harmonic_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-wall_harmonic_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 4e-14 +skip_tests: prerequisites: ! | atom full fix wall/harmonic @@ -31,10 +32,10 @@ run_pos: ! |2 10 2.0510765220197009e+00 -1.4604063740411815e+00 -9.8323745080488900e-01 11 1.7878031944407509e+00 -1.9921863272886073e+00 -1.8890602447598965e+00 12 3.0063007038317027e+00 -4.9013350489718083e-01 -1.6231898106978369e+00 - 13 4.0515402959160571e+00 -8.9202011606485654e-01 -1.6400005529914481e+00 - 14 2.6066963345462244e+00 -4.1789253964874301e-01 -2.6634003608727506e+00 + 13 4.0515402959160571e+00 -8.9202011606485665e-01 -1.6400005529914481e+00 + 14 2.6066963345462244e+00 -4.1789253964874307e-01 -2.6634003608727506e+00 15 2.9695287185264685e+00 5.5422613167055734e-01 -1.2342022021669503e+00 - 16 2.6747029695037297e+00 -2.4124119054292041e+00 -2.3435746152831474e-02 + 16 2.6747029695037297e+00 -2.4124119054292041e+00 -2.3435746152831470e-02 17 2.2153577785010934e+00 -2.0897985186506944e+00 1.1963150794337314e+00 18 2.1369701704267587e+00 3.0158507413153752e+00 -3.5179348337454122e+00 19 1.5355837136075348e+00 2.6255292355297897e+00 -4.2353987779858038e+00 @@ -49,33 +50,33 @@ run_pos: ! |2 28 -2.7473562684511403e+00 -4.0200819932374339e+00 1.5830052163432258e+00 29 -1.3126000191357743e+00 -3.5962518039473323e+00 2.2746342468733483e+00 run_vel: ! |2 - 1 8.0432349631399738e-03 1.4401841389211066e-02 4.9594370365889035e-03 - 2 6.1330361195047721e-03 -2.0880295268721646e-02 -2.0467529305087974e-03 - 3 -8.3074380171099336e-03 -1.3074180712034022e-02 -4.0925567431707964e-03 - 4 -3.7694367867060308e-03 -6.5650784618522641e-03 -1.1170951231990066e-03 - 5 -1.1026343955717482e-02 -9.8958287307442903e-03 -2.8423479505575383e-03 + 1 8.0432349631399738e-03 1.4401841389211066e-02 4.9594370365888983e-03 + 2 6.1330361195047721e-03 -2.0880295268721639e-02 -2.0467529305087918e-03 + 3 -8.3074380171099371e-03 -1.3074180712034015e-02 -4.0925567431707903e-03 + 4 -3.7694367867060264e-03 -6.5650784618522711e-03 -1.1170951231990144e-03 + 5 -1.1026343955717478e-02 -9.8958287307442973e-03 -2.8423479505575396e-03 6 -3.9677127674597606e-02 4.6816039080495052e-02 3.7148638820894170e-02 7 9.1033730239907995e-04 -1.0128528243740664e-02 -5.1568250829251872e-02 - 8 7.9064772413549398e-03 -3.3507427942055237e-03 3.4557101116794005e-02 + 8 7.9064772413549398e-03 -3.3507427942055241e-03 3.4557101116794005e-02 9 1.5644169779778431e-03 3.7365552198096001e-03 1.5047408727814703e-02 - 10 2.9201446825927659e-02 -2.9249578944835358e-02 -1.5018077412006621e-02 + 10 2.9201446825927662e-02 -2.9249578944835361e-02 -1.5018077412006624e-02 11 -4.7835961594766378e-03 -3.7481385002840358e-03 -2.3464104088049835e-03 - 12 2.2696449755579802e-03 -3.4774139663753471e-04 -3.0640769495163694e-03 - 13 2.7531740375147762e-03 5.8171061651960156e-03 -7.9467453772152246e-04 - 14 3.5246182201851949e-03 -5.7939995452846345e-03 -3.9478431035191433e-03 - 15 -1.8547944555517618e-03 -5.8554729566882438e-03 6.2938485388423782e-03 - 16 1.8681499934669346e-02 -1.3262466149576241e-02 -4.5638651461858082e-02 - 17 -1.2896270037715951e-02 9.7527666092669871e-03 3.7296535331498307e-02 - 18 -8.0065791408039360e-04 -8.6270482947906340e-04 -1.4483041230016333e-03 - 19 1.2452390812060273e-03 -2.5061097279531165e-03 7.2998631045687349e-03 - 20 3.5930057934746205e-03 3.6938851526077707e-03 3.2322732077980764e-03 - 21 -1.4689219756964986e-03 -2.7352107824531023e-04 7.0581625180910238e-04 - 22 -7.0694199165145270e-03 -4.2577148692717476e-03 2.8079117911324980e-04 - 23 6.0446963236685126e-03 -1.4000131545098867e-03 2.5819754799379689e-03 - 24 3.1926371811980247e-04 -9.9445676110986795e-04 1.5000003249577247e-04 - 25 1.3789762510432095e-04 -4.4335895501596183e-03 -8.1808122106665057e-04 - 26 2.0485904106950122e-03 2.7813358601316666e-03 4.3245727251785618e-03 - 27 4.5604120562021776e-04 -1.0305522931718021e-03 2.1188058006115626e-04 - 28 -6.2544520854975879e-03 1.4127711193315995e-03 -1.8429821890767147e-03 - 29 6.4110631581209361e-04 3.1273432740202512e-03 3.7253671096581808e-03 + 12 2.2696449755579846e-03 -3.4774139663753189e-04 -3.0640769495163746e-03 + 13 2.7531740375147718e-03 5.8171061651960147e-03 -7.9467453772151639e-04 + 14 3.5246182201851889e-03 -5.7939995452846414e-03 -3.9478431035191398e-03 + 15 -1.8547944555517633e-03 -5.8554729566882438e-03 6.2938485388423842e-03 + 16 1.8681499934669346e-02 -1.3262466149576239e-02 -4.5638651461858082e-02 + 17 -1.2896270037715950e-02 9.7527666092669853e-03 3.7296535331498307e-02 + 18 -8.0065791408039360e-04 -8.6270482947906296e-04 -1.4483041230016354e-03 + 19 1.2452390812060241e-03 -2.5061097279531195e-03 7.2998631045687393e-03 + 20 3.5930057934746205e-03 3.6938851526077724e-03 3.2322732077980833e-03 + 21 -1.4689219756964980e-03 -2.7352107824530941e-04 7.0581625180909957e-04 + 22 -7.0694199165145339e-03 -4.2577148692717511e-03 2.8079117911325202e-04 + 23 6.0446963236685169e-03 -1.4000131545098867e-03 2.5819754799379759e-03 + 24 3.1926371811980193e-04 -9.9445676110986579e-04 1.5000003249577114e-04 + 25 1.3789762510431792e-04 -4.4335895501596235e-03 -8.1808122106664959e-04 + 26 2.0485904106950169e-03 2.7813358601316649e-03 4.3245727251785661e-03 + 27 4.5604120562021738e-04 -1.0305522931717997e-03 2.1188058006115548e-04 + 28 -6.2544520854975905e-03 1.4127711193315927e-03 -1.8429821890767147e-03 + 29 6.4110631581209827e-04 3.1273432740202478e-03 3.7253671096581838e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-wall_lj1043_const.yaml b/unittest/force-styles/tests/fix-timestep-wall_lj1043_const.yaml index 1bf3d793fb..346347fa52 100644 --- a/unittest/force-styles/tests/fix-timestep-wall_lj1043_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-wall_lj1043_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full fix wall/lj1043 @@ -15,7 +16,7 @@ input_file: in.fourmol natoms: 29 run_stress: ! |2- 0.0000000000000000e+00 -2.6193298572154652e+02 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -global_scalar: -21.0862098649006 +global_scalar: -21.08620986490061 global_vector: ! |- 2 0 -57.92496787419014 run_pos: ! |2 @@ -49,33 +50,33 @@ run_pos: ! |2 28 -2.7473562684518917e+00 -4.0200819932392156e+00 1.5830052163438402e+00 29 -1.3126000191361171e+00 -3.5962518039488875e+00 2.2746342468740517e+00 run_vel: ! |2 - 1 8.1841315880303335e-03 1.7803126895942198e-02 4.7331827922337359e-03 - 2 5.2872718449612950e-03 1.2374845186539878e-02 -1.2926815487313702e-03 - 3 -8.1923356344707227e-03 -1.2836076371449581e-02 -4.0802120257198661e-03 - 4 -3.7702504525868805e-03 -6.5770071693563928e-03 -1.1192307261460145e-03 - 5 -1.1019314598888658e-02 -9.8875815536224806e-03 -2.8400036285674505e-03 - 6 -3.9676375881725769e-02 4.6817794264105546e-02 3.7148459335980842e-02 + 1 8.1841315880303335e-03 1.7803126895942201e-02 4.7331827922337333e-03 + 2 5.2872718449612950e-03 1.2374845186539883e-02 -1.2926815487313641e-03 + 3 -8.1923356344707245e-03 -1.2836076371449580e-02 -4.0802120257198600e-03 + 4 -3.7702504525868744e-03 -6.5770071693564006e-03 -1.1192307261460232e-03 + 5 -1.1019314598888651e-02 -9.8875815536224911e-03 -2.8400036285674527e-03 + 6 -3.9676375881725769e-02 4.6817794264105539e-02 3.7148459335980842e-02 7 9.1033721861779292e-04 -1.0128519145692703e-02 -5.1568252024849173e-02 8 7.9064677253038868e-03 -3.3507160527491073e-03 3.4557092147681955e-02 9 1.5644180391877055e-03 3.7365541678626712e-03 1.5047408804261555e-02 - 10 2.9201446833887625e-02 -2.9249578624510289e-02 -1.5018077456724527e-02 + 10 2.9201446833887632e-02 -2.9249578624510289e-02 -1.5018077456724529e-02 11 -4.7835961445442414e-03 -3.7481385222819055e-03 -2.3464104173434820e-03 - 12 2.2696452996842312e-03 -3.4774161943199928e-04 -3.0640770808192273e-03 - 13 2.7531740494769058e-03 5.8171061592074925e-03 -7.9467454165776268e-04 - 14 3.5246182465802542e-03 -5.7939995652885696e-03 -3.9478431249656059e-03 - 15 -1.8547943156104738e-03 -5.8554730115298621e-03 6.2938484995065241e-03 - 16 1.8681499996467923e-02 -1.3262466236792605e-02 -4.5638651453944704e-02 + 12 2.2696452996842360e-03 -3.4774161943199538e-04 -3.0640770808192325e-03 + 13 2.7531740494769036e-03 5.8171061592074830e-03 -7.9467454165775748e-04 + 14 3.5246182465802482e-03 -5.7939995652885766e-03 -3.9478431249656042e-03 + 15 -1.8547943156104806e-03 -5.8554730115298647e-03 6.2938484995065285e-03 + 16 1.8681499996467919e-02 -1.3262466236792603e-02 -4.5638651453944704e-02 17 -1.2896269944808334e-02 9.7527664731510994e-03 3.7296535379994826e-02 - 18 -8.0065797973686084e-04 -8.6270468072803454e-04 -1.4483040337931771e-03 - 19 1.2452390822638691e-03 -2.5061097069508046e-03 7.2998631034517326e-03 - 20 3.5930057841485402e-03 3.6938851585669543e-03 3.2322732198995820e-03 - 21 -1.4689219756959034e-03 -2.7352107824532801e-04 7.0581625180879902e-04 - 22 -7.0694199165144897e-03 -4.2577148692717545e-03 2.8079117911321429e-04 - 23 6.0446963236685291e-03 -1.4000131545098722e-03 2.5819754799379616e-03 - 24 3.1926365397474005e-04 -9.9445658202602602e-04 1.4999993258874643e-04 - 25 1.3789749306342510e-04 -4.4335894521738721e-03 -8.1808145883526960e-04 - 26 2.0485903990643661e-03 2.7813358651652739e-03 4.3245727088377832e-03 - 27 4.5604120120843627e-04 -1.0305523087271514e-03 2.1188058621237149e-04 - 28 -6.2544520875665892e-03 1.4127711143723774e-03 -1.8429821873498409e-03 - 29 6.4110631505239705e-04 3.1273432706974765e-03 3.7253671111164882e-03 + 18 -8.0065797973686084e-04 -8.6270468072803389e-04 -1.4483040337931801e-03 + 19 1.2452390822638656e-03 -2.5061097069508089e-03 7.2998631034517352e-03 + 20 3.5930057841485423e-03 3.6938851585669569e-03 3.2322732198995889e-03 + 21 -1.4689219756959025e-03 -2.7352107824532714e-04 7.0581625180879642e-04 + 22 -7.0694199165144958e-03 -4.2577148692717571e-03 2.8079117911321755e-04 + 23 6.0446963236685317e-03 -1.4000131545098722e-03 2.5819754799379676e-03 + 24 3.1926365397473956e-04 -9.9445658202602363e-04 1.4999993258874505e-04 + 25 1.3789749306342386e-04 -4.4335894521738773e-03 -8.1808145883526906e-04 + 26 2.0485903990643704e-03 2.7813358651652721e-03 4.3245727088377884e-03 + 27 4.5604120120843600e-04 -1.0305523087271488e-03 2.1188058621237062e-04 + 28 -6.2544520875665926e-03 1.4127711143723707e-03 -1.8429821873498405e-03 + 29 6.4110631505240095e-04 3.1273432706974721e-03 3.7253671111164917e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-wall_lj126_const.yaml b/unittest/force-styles/tests/fix-timestep-wall_lj126_const.yaml index 9db35c4e80..e0b8bef40f 100644 --- a/unittest/force-styles/tests/fix-timestep-wall_lj126_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-wall_lj126_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix wall/lj126 @@ -15,7 +16,7 @@ input_file: in.fourmol natoms: 29 run_stress: ! |2- 0.0000000000000000e+00 -3.4585143439781433e+01 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -global_scalar: -2.5475438051924 +global_scalar: -2.5475438051923964 global_vector: ! |- 2 0 -7.685735804480931 run_pos: ! |2 @@ -30,7 +31,7 @@ run_pos: ! |2 9 1.3800524229683340e+00 -2.5274721032308967e-01 2.8353985887275501e-01 10 2.0510765220569853e+00 -1.4604063740290876e+00 -9.8323745081845038e-01 11 1.7878031944445345e+00 -1.9921863272953313e+00 -1.8890602447627607e+00 - 12 3.0063007039406160e+00 -4.9013350497403835e-01 -1.6231898107413574e+00 + 12 3.0063007039406160e+00 -4.9013350497403829e-01 -1.6231898107413574e+00 13 4.0515402959195130e+00 -8.9202011606664511e-01 -1.6400005529925659e+00 14 2.6066963345549077e+00 -4.1789253965552781e-01 -2.6634003608798760e+00 15 2.9695287185740900e+00 5.5422613165132262e-01 -1.2342022021798298e+00 @@ -49,33 +50,33 @@ run_pos: ! |2 28 -2.7473562684514983e+00 -4.0200819932382927e+00 1.5830052163435213e+00 29 -1.3126000191360006e+00 -3.5962518039483600e+00 2.2746342468738150e+00 run_vel: ! |2 - 1 8.1736838827147721e-03 1.6663312149638839e-02 4.7825846265060696e-03 - 2 5.4253566409412576e-03 6.2207785641861220e-03 -1.4152392467172794e-03 - 3 -8.2253027770441446e-03 -1.2916209391701676e-02 -4.0968684491418175e-03 - 4 -3.7699423337971220e-03 -6.5728207445740153e-03 -1.1185533552840906e-03 - 5 -1.1021657752717677e-02 -9.8903229665705129e-03 -2.8409586181786582e-03 + 1 8.1736838827147756e-03 1.6663312149638836e-02 4.7825846265060670e-03 + 2 5.4253566409412576e-03 6.2207785641861324e-03 -1.4152392467172742e-03 + 3 -8.2253027770441498e-03 -1.2916209391701673e-02 -4.0968684491418123e-03 + 4 -3.7699423337971198e-03 -6.5728207445740205e-03 -1.1185533552840988e-03 + 5 -1.1021657752717674e-02 -9.8903229665705215e-03 -2.8409586181786599e-03 6 -3.9676630428254457e-02 4.6817142598134763e-02 3.7148486880267687e-02 7 9.1033935555084389e-04 -1.0128523881125326e-02 -5.1568251839019315e-02 - 8 7.9064708029200504e-03 -3.3507243508992240e-03 3.4557097882930717e-02 + 8 7.9064708029200504e-03 -3.3507243508992244e-03 3.4557097882930717e-02 9 1.5644176596214809e-03 3.7365545614027047e-03 1.5047408821840599e-02 10 2.9201446821679855e-02 -2.9249578731622122e-02 -1.5018077427420468e-02 11 -4.7835961506185933e-03 -3.7481385144110253e-03 -2.3464104145897880e-03 - 12 2.2696451976812193e-03 -3.4774155295885149e-04 -3.0640770383382784e-03 - 13 2.7531740456946123e-03 5.8171061610390856e-03 -7.9467454038798337e-04 - 14 3.5246182382961751e-03 -5.7939995593613248e-03 -3.9478431181713272e-03 - 15 -1.8547943582982319e-03 -5.8554729963889171e-03 6.2938485123769285e-03 - 16 1.8681499976092579e-02 -1.3262466208300180e-02 -4.5638651456655882e-02 - 17 -1.2896269976994218e-02 9.7527665205595585e-03 3.7296535362996160e-02 - 18 -8.0065795841602957e-04 -8.6270473300520899e-04 -1.4483040625041770e-03 - 19 1.2452390821759997e-03 -2.5061097127793250e-03 7.2998631030148694e-03 - 20 3.5930057866940816e-03 3.6938851569599759e-03 3.2322732165725762e-03 - 21 -1.4689219756961328e-03 -2.7352107824530589e-04 7.0581625180891059e-04 - 22 -7.0694199165145027e-03 -4.2577148692717493e-03 2.8079117911323132e-04 - 23 6.0446963236685221e-03 -1.4000131545098765e-03 2.5819754799379646e-03 - 24 3.1926367618930162e-04 -9.9445663991403854e-04 1.4999996533169883e-04 - 25 1.3789753927534785e-04 -4.4335894842731883e-03 -8.1808137766018309e-04 - 26 2.0485904030142174e-03 2.7813358635922834e-03 4.3245727142210300e-03 - 27 4.5604120273867423e-04 -1.0305523033766722e-03 2.1188058408524177e-04 - 28 -6.2544520867835037e-03 1.4127711162392888e-03 -1.8429821879994517e-03 - 29 6.4110631531067038e-04 3.1273432718155708e-03 3.7253671106285370e-03 + 12 2.2696451976812245e-03 -3.4774155295884792e-04 -3.0640770383382832e-03 + 13 2.7531740456946106e-03 5.8171061610390786e-03 -7.9467454038797839e-04 + 14 3.5246182382961677e-03 -5.7939995593613274e-03 -3.9478431181713307e-03 + 15 -1.8547943582982380e-03 -5.8554729963889189e-03 6.2938485123769363e-03 + 16 1.8681499976092579e-02 -1.3262466208300175e-02 -4.5638651456655882e-02 + 17 -1.2896269976994217e-02 9.7527665205595568e-03 3.7296535362996160e-02 + 18 -8.0065795841602957e-04 -8.6270473300520791e-04 -1.4483040625041799e-03 + 19 1.2452390821759965e-03 -2.5061097127793276e-03 7.2998631030148720e-03 + 20 3.5930057866940860e-03 3.6938851569599772e-03 3.2322732165725818e-03 + 21 -1.4689219756961326e-03 -2.7352107824530502e-04 7.0581625180890820e-04 + 22 -7.0694199165145079e-03 -4.2577148692717545e-03 2.8079117911323462e-04 + 23 6.0446963236685247e-03 -1.4000131545098765e-03 2.5819754799379716e-03 + 24 3.1926367618930097e-04 -9.9445663991403594e-04 1.4999996533169755e-04 + 25 1.3789753927534622e-04 -4.4335894842731935e-03 -8.1808137766018244e-04 + 26 2.0485904030142217e-03 2.7813358635922804e-03 4.3245727142210335e-03 + 27 4.5604120273867374e-04 -1.0305523033766696e-03 2.1188058408524096e-04 + 28 -6.2544520867835064e-03 1.4127711162392825e-03 -1.8429821879994517e-03 + 29 6.4110631531067407e-04 3.1273432718155656e-03 3.7253671106285404e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-wall_lj93_const.yaml b/unittest/force-styles/tests/fix-timestep-wall_lj93_const.yaml index 451ce34c0b..c574eddf76 100644 --- a/unittest/force-styles/tests/fix-timestep-wall_lj93_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-wall_lj93_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:59 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 2e-14 +skip_tests: prerequisites: ! | atom full fix wall/lj93 @@ -15,7 +16,7 @@ input_file: in.fourmol natoms: 29 run_stress: ! |2- 0.0000000000000000e+00 -5.0602303343219951e+01 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -global_scalar: -4.10898799728224 +global_scalar: -4.108987997282236 global_vector: ! |- 2 0 -11.164431050504302 run_pos: ! |2 @@ -32,7 +33,7 @@ run_pos: ! |2 11 1.7878031944447623e+00 -1.9921863272956677e+00 -1.8890602447628950e+00 12 3.0063007039452563e+00 -4.9013350497696184e-01 -1.6231898107433360e+00 13 4.0515402959196631e+00 -8.9202011606671716e-01 -1.6400005529926165e+00 - 14 2.6066963345552767e+00 -4.1789253965578238e-01 -2.6634003608801833e+00 + 14 2.6066963345552767e+00 -4.1789253965578244e-01 -2.6634003608801833e+00 15 2.9695287185759982e+00 5.5422613165070589e-01 -1.2342022021804264e+00 16 2.6747029695251561e+00 -2.4124119054596429e+00 -2.3435746150366733e-02 17 2.2153577785319198e+00 -2.0897985186960004e+00 1.1963150794498112e+00 @@ -49,33 +50,33 @@ run_pos: ! |2 28 -2.7473562684515085e+00 -4.0200819932383203e+00 1.5830052163435302e+00 29 -1.3126000191360121e+00 -3.5962518039484110e+00 2.2746342468738372e+00 run_vel: ! |2 - 1 8.1727799799441534e-03 1.6773171346479501e-02 4.7791658662457654e-03 - 2 5.4195488166242462e-03 6.5417253116750443e-03 -1.4101336509904768e-03 - 3 -8.2223992085164229e-03 -1.2908451784809982e-02 -4.0945960825392244e-03 - 4 -3.7699737621353234e-03 -6.5732339099368580e-03 -1.1186165990462486e-03 - 5 -1.1021432529769996e-02 -9.8900600342307996e-03 -2.8408577395243394e-03 + 1 8.1727799799441551e-03 1.6773171346479498e-02 4.7791658662457619e-03 + 2 5.4195488166242462e-03 6.5417253116750503e-03 -1.4101336509904706e-03 + 3 -8.2223992085164246e-03 -1.2908451784809975e-02 -4.0945960825392183e-03 + 4 -3.7699737621353186e-03 -6.5732339099368641e-03 -1.1186165990462573e-03 + 5 -1.1021432529769989e-02 -9.8900600342308066e-03 -2.8408577395243402e-03 6 -3.9676605755577875e-02 4.6817208693894503e-02 3.7148485968758402e-02 7 9.1033903828574569e-04 -1.0128523335196111e-02 -5.1568251845436980e-02 - 8 7.9064705135345748e-03 -3.3507235864772373e-03 3.4557097186682206e-02 + 8 7.9064705135345748e-03 -3.3507235864772382e-03 3.4557097186682206e-02 9 1.5644176974450778e-03 3.7365545213281916e-03 1.5047408817898655e-02 - 10 2.9201446823370270e-02 -2.9249578721348601e-02 -1.5018077430999390e-02 + 10 2.9201446823370270e-02 -2.9249578721348601e-02 -1.5018077430999392e-02 11 -4.7835961499775063e-03 -3.7481385151954837e-03 -2.3464104148495902e-03 - 12 2.2696452071679567e-03 -3.4774155893559344e-04 -3.0640770423525213e-03 - 13 2.7531740460470175e-03 5.8171061608719189e-03 -7.9467454050768200e-04 - 14 3.5246182390652313e-03 -5.7939995598917469e-03 -3.9478431188056783e-03 - 15 -1.8547943544027765e-03 -5.8554729976774888e-03 6.2938485111532164e-03 - 16 1.8681499978038460e-02 -1.3262466211006751e-02 -4.5638651456391420e-02 - 17 -1.2896269973838888e-02 9.7527665158999022e-03 3.7296535364672506e-02 - 18 -8.0065796043573623e-04 -8.6270472784857302e-04 -1.4483040597982840e-03 - 19 1.2452390821689225e-03 -2.5061097122815383e-03 7.2998631031035580e-03 - 20 3.5930057864791247e-03 3.6938851570931927e-03 3.2322732168550555e-03 - 21 -1.4689219756961094e-03 -2.7352107824530887e-04 7.0581625180889899e-04 - 22 -7.0694199165145018e-03 -4.2577148692717493e-03 2.8079117911322974e-04 - 23 6.0446963236685230e-03 -1.4000131545098763e-03 2.5819754799379642e-03 - 24 3.1926367400896623e-04 -9.9445663445895337e-04 1.4999996220927379e-04 - 25 1.3789753472275229e-04 -4.4335894812289967e-03 -8.1808138555694804e-04 - 26 2.0485904026313470e-03 2.7813358637372430e-03 4.3245727137078208e-03 - 27 4.5604120258846328e-04 -1.0305523038990228e-03 2.1188058429346741e-04 - 28 -6.2544520868040663e-03 1.4127711161841230e-03 -1.8429821879802923e-03 - 29 6.4110631528576235e-04 3.1273432717073631e-03 3.7253671106756703e-03 + 12 2.2696452071679614e-03 -3.4774155893559008e-04 -3.0640770423525257e-03 + 13 2.7531740460470166e-03 5.8171061608719103e-03 -7.9467454050767680e-04 + 14 3.5246182390652257e-03 -5.7939995598917460e-03 -3.9478431188056783e-03 + 15 -1.8547943544027830e-03 -5.8554729976774897e-03 6.2938485111532208e-03 + 16 1.8681499978038456e-02 -1.3262466211006751e-02 -4.5638651456391420e-02 + 17 -1.2896269973838886e-02 9.7527665158999004e-03 3.7296535364672513e-02 + 18 -8.0065796043573602e-04 -8.6270472784857216e-04 -1.4483040597982864e-03 + 19 1.2452390821689194e-03 -2.5061097122815435e-03 7.2998631031035615e-03 + 20 3.5930057864791303e-03 3.6938851570931927e-03 3.2322732168550625e-03 + 21 -1.4689219756961087e-03 -2.7352107824530806e-04 7.0581625180889649e-04 + 22 -7.0694199165145062e-03 -4.2577148692717554e-03 2.8079117911323321e-04 + 23 6.0446963236685256e-03 -1.4000131545098763e-03 2.5819754799379711e-03 + 24 3.1926367400896563e-04 -9.9445663445895099e-04 1.4999996220927227e-04 + 25 1.3789753472275083e-04 -4.4335894812290054e-03 -8.1808138555694750e-04 + 26 2.0485904026313513e-03 2.7813358637372391e-03 4.3245727137078242e-03 + 27 4.5604120258846295e-04 -1.0305523038990200e-03 2.1188058429346654e-04 + 28 -6.2544520868040715e-03 1.4127711161841167e-03 -1.8429821879802923e-03 + 29 6.4110631528576680e-04 3.1273432717073592e-03 3.7253671106756733e-03 ... diff --git a/unittest/force-styles/tests/fix-timestep-wall_morse_const.yaml b/unittest/force-styles/tests/fix-timestep-wall_morse_const.yaml index 60261f9bfc..89290d9d7d 100644 --- a/unittest/force-styles/tests/fix-timestep-wall_morse_const.yaml +++ b/unittest/force-styles/tests/fix-timestep-wall_morse_const.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:10:00 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:01 2022 epsilon: 4e-14 +skip_tests: prerequisites: ! | atom full fix wall/morse @@ -15,13 +16,13 @@ input_file: in.fourmol natoms: 29 run_stress: ! |2- 0.0000000000000000e+00 -1.6447328969000660e+03 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -global_scalar: -715.415406257395 +global_scalar: -715.4154062573953 global_vector: ! |- 2 0 -362.76807567062644 run_pos: ! |2 - 1 -2.7045893790409276e-01 2.5008322800634093e+00 -1.6714018607090517e-01 + 1 -2.7045893790409276e-01 2.5008322800634093e+00 -1.6714018607090519e-01 2 3.0963184116147618e-01 3.0014595399936281e+00 -8.5430140686816214e-01 - 3 -7.0384894984747925e-01 1.2309015375308219e+00 -6.2768436035697617e-01 + 3 -7.0384894984747937e-01 1.2309015375308219e+00 -6.2768436035697617e-01 4 -1.5818176791640250e+00 1.4837231080448017e+00 -1.2538740983093204e+00 5 -9.0718849446796412e-01 9.2653164987898939e-01 3.9954632131545287e-01 6 2.4831839235845354e-01 2.8313265654301789e-01 -1.2314236357880461e+00 @@ -49,33 +50,33 @@ run_pos: ! |2 28 -2.7473562684536628e+00 -4.0200819932434282e+00 1.5830052163452875e+00 29 -1.3126000191369560e+00 -3.5962518039526832e+00 2.2746342468757565e+00 run_vel: ! |2 - 1 8.1789148947012790e-03 2.6011139448739451e-02 4.4419168461127534e-03 - 2 4.6260716342741070e-03 4.5085766258259767e-02 -7.0825186386967818e-04 - 3 -7.9721954985889285e-03 -1.2268783977531039e-02 -3.9361845956729456e-03 - 4 -3.7725559552080649e-03 -6.6074130975376302e-03 -1.1239964478779233e-03 - 5 -1.1002605235858460e-02 -9.8680015994752658e-03 -2.8327888280266921e-03 - 6 -3.9674547907414821e-02 4.6822592792817211e-02 3.7148318739351066e-02 + 1 8.1789148947012790e-03 2.6011139448739451e-02 4.4419168461127482e-03 + 2 4.6260716342741079e-03 4.5085766258259774e-02 -7.0825186386967308e-04 + 3 -7.9721954985889319e-03 -1.2268783977531032e-02 -3.9361845956729386e-03 + 4 -3.7725559552080636e-03 -6.6074130975376346e-03 -1.1239964478779332e-03 + 5 -1.1002605235858455e-02 -9.8680015994752728e-03 -2.8327888280266942e-03 + 6 -3.9674547907414821e-02 4.6822592792817204e-02 3.7148318739351066e-02 7 9.1031746047128470e-04 -1.0128481892033168e-02 -5.1568253048218646e-02 - 8 7.9064457287878788e-03 -3.3506582863990051e-03 3.4557045247921400e-02 + 8 7.9064457287878788e-03 -3.3506582863990068e-03 3.4557045247921400e-02 9 1.5644208034781776e-03 3.7365512668284797e-03 1.5047408581112285e-02 - 10 2.9201446942760535e-02 -2.9249577856792601e-02 -1.5018077696249433e-02 + 10 2.9201446942760539e-02 -2.9249577856792598e-02 -1.5018077696249433e-02 11 -4.7835960986765723e-03 -3.7481385797508478e-03 -2.3464104367979396e-03 - 12 2.2696460154049553e-03 -3.4774207770824208e-04 -3.0640773817331556e-03 - 13 2.7531740760828446e-03 5.8171061464595882e-03 -7.9467455065098259e-04 - 14 3.5246183046552968e-03 -5.7939996060506959e-03 -3.9478431727489110e-03 - 15 -1.8547940192371317e-03 -5.8554731130000910e-03 6.2938484079631141e-03 - 16 1.8681500141579217e-02 -1.3262466439236465e-02 -4.5638651434422119e-02 - 17 -1.2896269711984213e-02 9.7527661294105148e-03 3.7296535503389051e-02 - 18 -8.0065813058176056e-04 -8.6270429918499129e-04 -1.4483038312432203e-03 - 19 1.2452390823893700e-03 -2.5061096678311691e-03 7.2998631081901098e-03 - 20 3.5930057672106026e-03 3.6938851692874396e-03 3.2322732421069286e-03 - 21 -1.4689219756942105e-03 -2.7352107824552653e-04 7.0581625180796668e-04 - 22 -7.0694199165143717e-03 -4.2577148692717727e-03 2.8079117911313433e-04 - 23 6.0446963236686115e-03 -1.4000131545098178e-03 2.5819754799379238e-03 - 24 3.1926349353318011e-04 -9.9445617038915603e-04 1.4999970019575939e-04 - 25 1.3789715718110244e-04 -4.4335892217948203e-03 -8.1808204442384007e-04 - 26 2.0485903705729116e-03 2.7813358762743688e-03 4.3245726703719164e-03 - 27 4.5604119012943262e-04 -1.0305523473710147e-03 2.1188060159221318e-04 - 28 -6.2544520902254284e-03 1.4127711077263176e-03 -1.8429821850450522e-03 - 29 6.4110631319826985e-04 3.1273432626741679e-03 3.7253671146110535e-03 + 12 2.2696460154049596e-03 -3.4774207770823769e-04 -3.0640773817331617e-03 + 13 2.7531740760828424e-03 5.8171061464595821e-03 -7.9467455065097717e-04 + 14 3.5246183046552903e-03 -5.7939996060507011e-03 -3.9478431727489067e-03 + 15 -1.8547940192371359e-03 -5.8554731130000919e-03 6.2938484079631211e-03 + 16 1.8681500141579217e-02 -1.3262466439236464e-02 -4.5638651434422119e-02 + 17 -1.2896269711984213e-02 9.7527661294105131e-03 3.7296535503389051e-02 + 18 -8.0065813058176056e-04 -8.6270429918499042e-04 -1.4483038312432231e-03 + 19 1.2452390823893668e-03 -2.5061096678311726e-03 7.2998631081901150e-03 + 20 3.5930057672106052e-03 3.6938851692874418e-03 3.2322732421069351e-03 + 21 -1.4689219756942099e-03 -2.7352107824552571e-04 7.0581625180796419e-04 + 22 -7.0694199165143787e-03 -4.2577148692717762e-03 2.8079117911313845e-04 + 23 6.0446963236686149e-03 -1.4000131545098178e-03 2.5819754799379282e-03 + 24 3.1926349353317952e-04 -9.9445617038915342e-04 1.4999970019575790e-04 + 25 1.3789715718110098e-04 -4.4335892217948255e-03 -8.1808204442383866e-04 + 26 2.0485903705729164e-03 2.7813358762743667e-03 4.3245726703719217e-03 + 27 4.5604119012943235e-04 -1.0305523473710114e-03 2.1188060159221209e-04 + 28 -6.2544520902254328e-03 1.4127711077263102e-03 -1.8429821850450522e-03 + 29 6.4110631319827462e-04 3.1273432626741622e-03 3.7253671146110553e-03 ... diff --git a/unittest/force-styles/tests/improper-class2.yaml b/unittest/force-styles/tests/improper-class2.yaml index 2ee0feaa6b..38e8b9120b 100644 --- a/unittest/force-styles/tests/improper-class2.yaml +++ b/unittest/force-styles/tests/improper-class2.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:36 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper class2 @@ -15,7 +16,7 @@ improper_coeff: ! | * aa 75 42 31 125.4 130.01 115.06 extract: ! "" natoms: 29 -init_energy: 1375.73723669752 +init_energy: 1375.7372366975192 init_stress: ! |- -1.7468868485439822e+02 -9.2086842555214787e+01 2.6677552740961301e+02 1.4938930562506283e+02 2.2947660920769948e+01 5.9390297771307900e+01 init_forces: ! |2 @@ -48,7 +49,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 1374.65492729307 +run_energy: 1374.6549272930695 run_stress: ! |- -1.7447800608448503e+02 -9.2290397546656749e+01 2.6676840363114184e+02 1.5021277934074519e+02 2.2884061959854989e+01 5.9138100588497707e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-cossq.yaml b/unittest/force-styles/tests/improper-cossq.yaml index facb268a94..d52c50c517 100644 --- a/unittest/force-styles/tests/improper-cossq.yaml +++ b/unittest/force-styles/tests/improper-cossq.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:36 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper cossq @@ -14,7 +15,7 @@ improper_coeff: ! | 2 45.0 59.5 extract: ! "" natoms: 29 -init_energy: 47.9012064519622 +init_energy: 47.901206451962224 init_stress: ! |- -4.5136832793911459e+01 -4.0792102522859011e+01 8.5928935316770463e+01 4.5396318866546366e+01 -1.0360009267990996e+01 2.9226619105197486e+01 init_forces: ! |2 @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 47.8940525577889 +run_energy: 47.89405255778891 run_stress: ! |- -4.5134157244665538e+01 -4.0785439102386391e+01 8.5919596347051922e+01 4.5379718139339566e+01 -1.0358055502390599e+01 2.9188541576075529e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-cvff.yaml b/unittest/force-styles/tests/improper-cvff.yaml index 8047efa9f4..3a300de4d6 100644 --- a/unittest/force-styles/tests/improper-cvff.yaml +++ b/unittest/force-styles/tests/improper-cvff.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Wed Feb 24 19:35:14 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:02 2022 epsilon: 1e-11 +skip_tests: prerequisites: ! | atom full improper cvff @@ -14,7 +15,7 @@ improper_coeff: ! | 2 45.0 +1 2 extract: ! "" natoms: 29 -init_energy: 89.3326668855358 +init_energy: 89.33266688553577 init_stress: ! |2- 6.3735186906797781e-01 5.1961496386521944e-01 -1.1569668329364793e+00 6.0239243426043387e-01 -3.1000536955332481e-01 -5.5270895482870697e-01 init_forces: ! |2 @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 89.3292146995311 +run_energy: 89.32921469953112 run_stress: ! |2- 6.4099342941199167e-01 5.2185345018626172e-01 -1.1628468796005447e+00 6.0557206546498987e-01 -3.1107455425782704e-01 -5.5667330437418350e-01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-distance.yaml b/unittest/force-styles/tests/improper-distance.yaml index 7401dc3f42..91df7b7bae 100644 --- a/unittest/force-styles/tests/improper-distance.yaml +++ b/unittest/force-styles/tests/improper-distance.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:36 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper distance @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 0.0752844479361218 +run_energy: 0.07528444793612178 run_stress: ! |- -7.2139939776107845e-02 -6.7406713268567800e-02 -1.1347012542302529e-02 -6.9728309368254873e-02 2.8565942982875535e-02 2.7592710278142397e-02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-distharm.yaml b/unittest/force-styles/tests/improper-distharm.yaml index 6d2bedcb9e..e2916d3d74 100644 --- a/unittest/force-styles/tests/improper-distharm.yaml +++ b/unittest/force-styles/tests/improper-distharm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:36 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper distharm @@ -14,7 +15,7 @@ improper_coeff: ! | 2 45.0 6.2 extract: ! "" natoms: 29 -init_energy: 3973.60160543212 +init_energy: 3973.601605432119 init_stress: ! |2- 1.1840727036793918e+01 1.1289853753674723e+01 1.7432289710119591e+00 1.1555189021102050e+01 -4.4774070829341710e+00 -4.3435896298765657e+00 init_forces: ! |2 @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 3968.00170122936 +run_energy: 3968.0017012293583 run_stress: ! |2- 1.4455848528830730e+01 1.4061051246688471e+01 1.9392778677831757e+00 1.4242047809332975e+01 -5.1418231006541211e+00 -5.0085768779968713e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-fourier.yaml b/unittest/force-styles/tests/improper-fourier.yaml index 4c3fa1ff7e..278698a190 100644 --- a/unittest/force-styles/tests/improper-fourier.yaml +++ b/unittest/force-styles/tests/improper-fourier.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:36 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper fourier @@ -14,7 +15,7 @@ improper_coeff: ! | 2 45.0 0.5 0.1 0.8 0 extract: ! "" natoms: 29 -init_energy: 376.79153906023 +init_energy: 376.7915390602297 init_stress: ! |2- 1.0624187547924073e+00 1.0206113657070901e+00 -2.0830301204995032e+00 1.0486115899411781e+00 -8.1208166417311556e-01 -8.4664058797741759e-01 init_forces: ! |2 @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 376.767592296021 +run_energy: 376.76759229602084 run_stress: ! |2- 1.0819691800876623e+00 1.0419669360880310e+00 -2.1239361161756918e+00 1.0713168006483549e+00 -8.2631137022352130e-01 -8.5923448323782503e-01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-harmonic.yaml b/unittest/force-styles/tests/improper-harmonic.yaml index 10f58c12b6..7ac0dbe06e 100644 --- a/unittest/force-styles/tests/improper-harmonic.yaml +++ b/unittest/force-styles/tests/improper-harmonic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Wed Feb 24 19:35:15 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 5e-11 +skip_tests: prerequisites: ! | atom full improper harmonic @@ -14,7 +15,7 @@ improper_coeff: ! | 2 45.0 59.5 extract: ! "" natoms: 29 -init_energy: 369.340964796184 +init_energy: 369.34096479618404 init_stress: ! |2- 4.2200353970159981e+00 3.7101799973801128e+00 -7.9302153943075808e+00 4.0937388495186724e+00 -1.9761982391039652e+00 -3.2729597741471910e+00 init_forces: ! |2 @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 367.815769347681 +run_energy: 367.81576934768134 run_stress: ! |2- 4.9041475165932553e+00 4.4679825636530310e+00 -9.3721300803182039e+00 4.8178760617236946e+00 -2.2166981793365235e+00 -3.5416380080536864e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-hybrid.yaml b/unittest/force-styles/tests/improper-hybrid.yaml index e86dcc329c..a6c15faebd 100644 --- a/unittest/force-styles/tests/improper-hybrid.yaml +++ b/unittest/force-styles/tests/improper-hybrid.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Wed Feb 24 20:50:39 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 2e-12 +skip_tests: prerequisites: ! | atom full improper harmonic @@ -15,7 +16,7 @@ improper_coeff: ! | 2 harmonic 45.0 59.5 extract: ! "" natoms: 29 -init_energy: 154.104984286114 +init_energy: 154.10498428611442 init_stress: ! |2- 3.5812398303195279e+00 2.9556506659556878e+00 -6.5368904962744523e+00 3.3989946629488741e+00 -1.7306448874103899e+00 -3.0544949874314882e+00 init_forces: ! |2 @@ -48,7 +49,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 153.944034579107 +run_energy: 153.94403457910704 run_stress: ! |2- 3.6531403476456785e+00 3.0213732444931751e+00 -6.6745135921400935e+00 3.4700902950870214e+00 -1.7529962884030181e+00 -3.1023752144878927e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-inversion_harmonic.yaml b/unittest/force-styles/tests/improper-inversion_harmonic.yaml index e1fc0499a8..73eade4958 100644 --- a/unittest/force-styles/tests/improper-inversion_harmonic.yaml +++ b/unittest/force-styles/tests/improper-inversion_harmonic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:37 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper inversion/harmonic @@ -14,7 +15,7 @@ improper_coeff: ! | 2 45.0 1.0 extract: ! "" natoms: 29 -init_energy: 0.352301150271594 +init_energy: 0.35230115027159387 init_stress: ! |- -2.0258575599327061e-01 -1.7811780014253070e-01 3.8070355613579143e-01 -5.5279767824605708e-01 2.6080018124128801e-01 2.2225526588362821e-01 init_forces: ! |2 @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 0.353545934459527 +run_energy: 0.3535459344595273 run_stress: ! |- -2.0321693754031284e-01 -1.7922721758319698e-01 3.8244415512349306e-01 -5.5486273508472495e-01 2.6112525268542269e-01 2.2234067034718155e-01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-ring.yaml b/unittest/force-styles/tests/improper-ring.yaml index 355a2ff170..6a824f9699 100644 --- a/unittest/force-styles/tests/improper-ring.yaml +++ b/unittest/force-styles/tests/improper-ring.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:37 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper ring @@ -14,7 +15,7 @@ improper_coeff: ! | 2 45.0 59.5 extract: ! "" natoms: 29 -init_energy: 31535.2377170405 +init_energy: 31535.23771704055 init_stress: ! |- -1.7744033713230339e+04 1.8012468654826118e+03 1.5942786847747706e+04 9.7803086281804881e+03 -2.0937834320538430e+04 2.8406351733476626e+04 init_forces: ! |2 @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 22428.4452488262 +run_energy: 22428.445248826167 run_stress: ! |- -1.6326115243382674e+04 4.8102071032932008e+03 1.1515908140089472e+04 7.3331418747017933e+03 -2.3084241239771301e+04 2.9022908238937845e+04 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-sqdistharm.yaml b/unittest/force-styles/tests/improper-sqdistharm.yaml index e16dbde61d..8bf671efbd 100644 --- a/unittest/force-styles/tests/improper-sqdistharm.yaml +++ b/unittest/force-styles/tests/improper-sqdistharm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:37 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper sqdistharm @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 3997.61003372028 +run_energy: 3997.610033720279 run_stress: ! |2- 8.9867618231995117e-01 8.3953557023913883e-01 1.4147031268478960e-01 8.6854554531065609e-01 -3.5603505602114510e-01 -3.4388329133386453e-01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/improper-umbrella.yaml b/unittest/force-styles/tests/improper-umbrella.yaml index f049680409..ff6822e9d8 100644 --- a/unittest/force-styles/tests/improper-umbrella.yaml +++ b/unittest/force-styles/tests/improper-umbrella.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:37 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:18:03 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full improper umbrella @@ -14,7 +15,7 @@ improper_coeff: ! | 2 45.0 59.5 extract: ! "" natoms: 29 -init_energy: 120.517350302608 +init_energy: 120.51735030260785 init_stress: ! |2- 2.1450057027702318e-01 2.0615370183731152e-01 -4.2065427211433370e-01 2.1056696695589994e-01 -1.6180636745642774e-01 -1.7032228908699515e-01 init_forces: ! |2 @@ -47,7 +48,7 @@ init_forces: ! |2 27 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 28 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 29 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_energy: 120.514295597906 +run_energy: 120.51429559790625 run_stress: ! |2- 2.1714787012179959e-01 2.0917208550038957e-01 -4.2631995562218900e-01 2.1344346192068486e-01 -1.6315541446960830e-01 -1.7170717562954185e-01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/kspace-ewald_disp.yaml b/unittest/force-styles/tests/kspace-ewald_disp.yaml index 5b0faec124..ec1f4420c4 100644 --- a/unittest/force-styles/tests/kspace-ewald_disp.yaml +++ b/unittest/force-styles/tests/kspace-ewald_disp.yaml @@ -1,8 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:25 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:52 2022 epsilon: 5e-12 -skip_tests: gpu single extract +skip_tests: extract gpu single prerequisites: ! | atom full pair lj/long/coul/long @@ -62,33 +62,33 @@ run_coul: 0 run_stress: ! |2- 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 run_forces: ! |2 - 1 -1.5321369646512289e-01 3.1811336640254428e-02 -7.5291966466499868e-02 - 2 4.1718499667107597e-02 -6.0993280056077008e-02 7.1251624481841025e-02 - 3 -9.5279894353951268e-03 -1.4941462712424198e-03 -2.3308420217005594e-03 - 4 5.2578632823907102e-02 7.1842522102449641e-03 8.4623035788519083e-03 - 5 5.1098021938378528e-02 9.7285355839204779e-03 1.0253349643675840e-02 - 6 1.1944881653432862e-01 7.6133381161564415e-02 8.1359427537698162e-02 - 7 -6.3591857746436053e-02 -8.6414432169993630e-02 -7.9109433076114136e-02 - 8 -3.7433525775956017e-03 -1.0990369365284679e-01 -1.1224509664376904e-01 - 9 3.4723473525535304e-03 5.8483564454419046e-02 7.3945790434835998e-02 + 1 -1.5321369646512287e-01 3.1811336640254428e-02 -7.5291966466499854e-02 + 2 4.1718499667107591e-02 -6.0993280056077008e-02 7.1251624481841025e-02 + 3 -9.5279894353951251e-03 -1.4941462712424192e-03 -2.3308420217005594e-03 + 4 5.2578632823907109e-02 7.1842522102449641e-03 8.4623035788519083e-03 + 5 5.1098021938378535e-02 9.7285355839204727e-03 1.0253349643675837e-02 + 6 1.1944881653432865e-01 7.6133381161564387e-02 8.1359427537698162e-02 + 7 -6.3591857746436040e-02 -8.6414432169993630e-02 -7.9109433076114163e-02 + 8 -3.7433525775956008e-03 -1.0990369365284677e-01 -1.1224509664376907e-01 + 9 3.4723473525535330e-03 5.8483564454419018e-02 7.3945790434835998e-02 10 -1.9931615263391753e-02 2.3230336652331492e-02 2.2930261922462034e-02 - 11 -2.7043515997570568e-02 3.3096788353233382e-02 2.7833272909244679e-02 - 12 1.4733114619496521e-01 -7.4907012571817991e-02 -9.9310508068793130e-02 - 13 -6.0568451603864079e-02 2.6904500638990563e-02 3.7502952815534972e-02 - 14 -4.7602620526011344e-02 2.4118387991499554e-02 2.8503007637066029e-02 + 11 -2.7043515997570565e-02 3.3096788353233382e-02 2.7833272909244686e-02 + 12 1.4733114619496521e-01 -7.4907012571817977e-02 -9.9310508068793157e-02 + 13 -6.0568451603864093e-02 2.6904500638990563e-02 3.7502952815534972e-02 + 14 -4.7602620526011358e-02 2.4118387991499554e-02 2.8503007637066029e-02 15 -4.5640946475327245e-02 1.1215448404197493e-02 3.2219246480274404e-02 - 16 -2.0008038374075982e-01 1.6245819219836355e-01 1.8812371878208675e-01 - 17 1.3640979614708318e-01 -1.4877360903977557e-01 -1.3970849833566271e-01 + 16 -2.0008038374075984e-01 1.6245819219836355e-01 1.8812371878208675e-01 + 17 1.3640979614708312e-01 -1.4877360903977560e-01 -1.3970849833566271e-01 18 3.1313062271288683e-01 3.0970376465951444e-01 -2.9690888050690195e-01 - 19 -1.2278633817042250e-01 -1.5053154281354220e-01 1.1083205911757414e-01 - 20 -1.7800087923017119e-01 -1.7031941581576107e-01 1.4510467117661957e-01 + 19 -1.2278633817042253e-01 -1.5053154281354220e-01 1.1083205911757414e-01 + 20 -1.7800087923017122e-01 -1.7031941581576107e-01 1.4510467117661957e-01 21 3.5089545735563610e-01 -9.5838434134800643e-02 -2.8233685525513896e-01 - 22 -1.9415564585497344e-01 7.5645499568197813e-02 9.1631181795561525e-02 - 23 -1.4017971783984279e-01 3.7892211453094155e-02 1.1299558998235543e-01 - 24 1.7884203136981472e-01 3.1247703983741310e-01 1.4068927063619110e-01 - 25 -2.7624350380010373e-02 -1.2477864845951719e-01 -2.6147141449362272e-02 - 26 -1.3999328961714033e-01 -1.7823800630539485e-01 -8.7261723908124589e-02 - 27 -3.3286289860045476e-01 1.7647878511351969e-01 -1.8733303262234691e-01 - 28 2.1399771535404671e-01 -1.1748172155357726e-01 1.2097428314785651e-01 - 29 1.5762446207378211e-01 -5.6888082076411807e-02 8.3371966274683545e-02 + 22 -1.9415564585497339e-01 7.5645499568197841e-02 9.1631181795561512e-02 + 23 -1.4017971783984279e-01 3.7892211453094168e-02 1.1299558998235543e-01 + 24 1.7884203136981469e-01 3.1247703983741304e-01 1.4068927063619113e-01 + 25 -2.7624350380010359e-02 -1.2477864845951722e-01 -2.6147141449362275e-02 + 26 -1.3999328961714030e-01 -1.7823800630539485e-01 -8.7261723908124589e-02 + 27 -3.3286289860045476e-01 1.7647878511351975e-01 -1.8733303262234685e-01 + 28 2.1399771535404677e-01 -1.1748172155357729e-01 1.2097428314785649e-01 + 29 1.5762446207378214e-01 -5.6888082076411807e-02 8.3371966274683518e-02 ... diff --git a/unittest/force-styles/tests/manybody-pair-airebo.yaml b/unittest/force-styles/tests/manybody-pair-airebo.yaml index 8b0eda5567..655ebe65e9 100644 --- a/unittest/force-styles/tests/manybody-pair-airebo.yaml +++ b/unittest/force-styles/tests/manybody-pair-airebo.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:10 2021 +date_generated: Fri Mar 18 22:17:42 2022 epsilon: 5e-06 +skip_tests: prerequisites: ! | pair airebo pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * CH.airebo C H extract: ! "" natoms: 48 -init_vdwl: -184.951215338583 +init_vdwl: -184.9512153385827 init_coul: 0 init_stress: ! |2- 9.0890487540552234e-02 5.6086429553227568e-01 2.1197563114732207e-01 1.4104429996380902e-01 1.4152302642812123e-01 9.2650318538687204e-01 @@ -68,7 +69,7 @@ init_forces: ! |2 46 -6.4059561000704031e-04 1.5796469864722801e-02 8.7781880557686095e-03 47 1.5239882999050557e-02 -3.1268760745643753e-03 1.8994686979097005e-02 48 9.4124555469617685e-04 2.8313380234794853e-02 1.4160015571855478e-02 -run_vdwl: -184.909469169338 +run_vdwl: -184.9094691693378 run_coul: 0 run_stress: ! |- -1.7004513060135343e-01 8.3214504293749170e-01 5.8484143488625218e-01 1.5625759760276972e-01 -6.3405563108599003e-02 1.1836497162460788e+00 diff --git a/unittest/force-styles/tests/manybody-pair-airebo_00.yaml b/unittest/force-styles/tests/manybody-pair-airebo_00.yaml index 62a56f5ab1..5fdaef05aa 100644 --- a/unittest/force-styles/tests/manybody-pair-airebo_00.yaml +++ b/unittest/force-styles/tests/manybody-pair-airebo_00.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:11 2021 +date_generated: Fri Mar 18 22:17:42 2022 epsilon: 1e-07 +skip_tests: prerequisites: ! | pair airebo pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * CH.airebo C H extract: ! "" natoms: 48 -init_vdwl: -184.961290756177 +init_vdwl: -184.96129075617665 init_coul: 0 init_stress: ! |- -1.5991107880755417e-02 1.7140062289608402e+00 -1.0794915656416637e+00 4.8928377143354418e-01 1.4299757801250498e-01 9.1729270327881118e-01 @@ -68,7 +69,7 @@ init_forces: ! |2 46 7.6023397517703095e-02 -2.2544487533539470e-01 4.2072193193403246e-02 47 -7.6877574240748030e-04 5.5783708545097566e-02 -2.0995954025529923e-02 48 5.1056308529232042e-02 8.5470102504109025e-02 6.8395640494008869e-02 -run_vdwl: -184.987048108923 +run_vdwl: -184.9870481089231 run_coul: 0 run_stress: ! |- -4.3376938809685628e-01 9.4641522574347858e-01 -1.4056170063304145e+00 1.9738399077051577e-01 -1.3923958411780546e-01 6.7259467679991358e-01 diff --git a/unittest/force-styles/tests/manybody-pair-airebo_m.yaml b/unittest/force-styles/tests/manybody-pair-airebo_m.yaml index 67b14b05c9..959e099746 100644 --- a/unittest/force-styles/tests/manybody-pair-airebo_m.yaml +++ b/unittest/force-styles/tests/manybody-pair-airebo_m.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:11 2021 +date_generated: Fri Mar 18 22:17:42 2022 epsilon: 1e-07 +skip_tests: prerequisites: ! | pair airebo/morse pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * CH.airebo-m C H extract: ! "" natoms: 48 -init_vdwl: -184.906791169779 +init_vdwl: -184.90679116977853 init_coul: 0 init_stress: ! |- -1.9905840837585734e-01 9.9992116160260081e-01 -8.7107008837839661e-01 3.8867690764878343e-01 1.6780936142412156e-01 1.2045504927890958e+00 @@ -68,7 +69,7 @@ init_forces: ! |2 46 -1.2686955525069661e-02 1.5757428775066942e-02 7.5875168576671499e-03 47 1.3552850486712849e-02 -1.4399850633487542e-03 1.9372348907855261e-02 48 -3.5635040678223824e-02 1.8069673365221146e-02 4.9559034910065504e-02 -run_vdwl: -184.906187675512 +run_vdwl: -184.90618767551217 run_coul: 0 run_stress: ! |- -7.3880100944953520e-01 -6.6034554071388640e-01 -1.3687882641804252e+00 -1.9309013048921472e-01 -3.0339410967612923e-01 4.5698202536312321e-01 diff --git a/unittest/force-styles/tests/manybody-pair-airebo_m00.yaml b/unittest/force-styles/tests/manybody-pair-airebo_m00.yaml index 73c6054ec0..d57af44eed 100644 --- a/unittest/force-styles/tests/manybody-pair-airebo_m00.yaml +++ b/unittest/force-styles/tests/manybody-pair-airebo_m00.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:11 2021 +date_generated: Fri Mar 18 22:17:42 2022 epsilon: 1e-07 +skip_tests: prerequisites: ! | pair airebo/morse pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * CH.airebo-m C H extract: ! "" natoms: 48 -init_vdwl: -184.961290756177 +init_vdwl: -184.96129075617665 init_coul: 0 init_stress: ! |- -1.5991107880755417e-02 1.7140062289608402e+00 -1.0794915656416637e+00 4.8928377143354418e-01 1.4299757801250498e-01 9.1729270327881118e-01 @@ -68,7 +69,7 @@ init_forces: ! |2 46 7.6023397517703095e-02 -2.2544487533539470e-01 4.2072193193403246e-02 47 -7.6877574240748030e-04 5.5783708545097566e-02 -2.0995954025529923e-02 48 5.1056308529232042e-02 8.5470102504109025e-02 6.8395640494008869e-02 -run_vdwl: -184.987048108923 +run_vdwl: -184.9870481089231 run_coul: 0 run_stress: ! |- -4.3376938809685628e-01 9.4641522574347858e-01 -1.4056170063304145e+00 1.9738399077051577e-01 -1.3923958411780546e-01 6.7259467679991358e-01 diff --git a/unittest/force-styles/tests/manybody-pair-comb.yaml b/unittest/force-styles/tests/manybody-pair-comb.yaml index b64cc2a6e9..0307d31b0c 100644 --- a/unittest/force-styles/tests/manybody-pair-comb.yaml +++ b/unittest/force-styles/tests/manybody-pair-comb.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable -date_generated: Fri Feb 26 23:09:14 2021 +date_generated: Fri Mar 18 22:17:43 2022 epsilon: 1e-12 +skip_tests: prerequisites: ! | pair comb pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * ffield.comb Si Si Si Si Si Si Si Si extract: ! "" natoms: 64 -init_vdwl: -275.751881079493 +init_vdwl: -275.75188107949333 init_coul: 0 init_stress: ! |2- 3.8073194277509302e+01 4.1007495365110245e+01 4.4067573198243295e+01 -6.7552732749378990e+00 2.6726661722305337e+01 2.8094275792955896e+00 @@ -32,8 +33,8 @@ init_forces: ! |2 10 7.6250831093931021e-02 -1.9542588043709501e+00 -2.6688334461821070e+00 11 3.0386034695914814e+00 -3.5004996957229046e+00 2.9675425165642775e+00 12 -5.3314164643294344e+00 -3.8204324736925050e+00 -2.8063654353378009e+00 - 13 -4.4732786013323639e-01 4.7570778058875591e+00 -1.4163546943501750e+00 - 14 -1.5602916114539045e+00 3.9210941524724778e+00 2.3900632778944365e-02 + 13 -4.4732786013323683e-01 4.7570778058875591e+00 -1.4163546943501750e+00 + 14 -1.5602916114539045e+00 3.9210941524724778e+00 2.3900632778944809e-02 15 -3.7176305594445793e+00 4.6429988530036121e+00 -2.8372682457950518e+00 16 1.7066805653544286e+00 -1.1066100973446247e-01 5.9242603096373996e+00 17 2.3198336153127173e+00 2.9483597098343073e+00 -3.5039826869216242e+00 @@ -41,7 +42,7 @@ init_forces: ! |2 19 -1.2571312575531866e+00 -2.7334357936792051e+00 -3.8628454598797485e-01 20 -5.7425222661453832e+00 2.0343375133520780e-01 1.0224770474164471e+00 21 2.0536115751696906e+00 8.2665019797045047e-01 -2.0125073941326148e+00 - 22 -4.9825508533193865e+00 4.1151022895598945e+00 -4.6945991414982364e+00 + 22 -4.9825508533193856e+00 4.1151022895598945e+00 -4.6945991414982373e+00 23 1.9773508934595492e+00 3.2592055302022600e+00 1.0700298947591267e+00 24 1.8894804040829110e+00 1.0247427913411720e+00 3.0353789059074590e+00 25 7.6035693028898077e-01 -1.4868825364745319e-02 1.3589049480606676e+00 @@ -52,7 +53,7 @@ init_forces: ! |2 30 -1.4604020796936199e+00 8.7509293399206489e-01 -8.7234062201891849e-01 31 -1.3639960830898401e+00 1.5020815417757769e+00 -1.5372952064727685e-01 32 -2.7924706099917005e+00 7.7513917762024498e-01 -8.9981286693726581e-01 - 33 4.3462516719039055e+00 -2.5890297595737608e+00 2.9130917791315953e+00 + 33 4.3462516719039055e+00 -2.5890297595737608e+00 2.9130917791315971e+00 34 8.6702948604247421e-01 -6.6915597072292776e-02 4.0173126227729838e-02 35 1.2333649639812814e+00 1.7569188905194899e-01 2.6141336237260435e+00 36 -5.3825350734163113e-01 -2.5728132063936835e+00 -2.3160451967347812e-02 @@ -69,7 +70,7 @@ init_forces: ! |2 47 2.6868585640903739e+00 1.7265316767888992e+00 7.6392468506300482e-01 48 1.2747899188181782e+00 -2.7670763770165285e-01 -8.9752819527847638e-02 49 -2.6996435637937308e+00 -4.1956451968554047e+00 -2.3350041480924268e+00 - 50 -5.6197993856796291e-01 2.6648857728410960e+00 -1.1952716416604021e+00 + 50 -5.6197993856796291e-01 2.6648857728410968e+00 -1.1952716416604021e+00 51 -2.0029715841449409e+00 2.0448853225242898e+00 3.7292313284873284e+00 52 4.7052456990574951e+00 -4.9522855831556436e+00 4.5257645077258681e+00 53 3.6332609816368979e+00 3.1007467579375110e+00 2.0930796308706414e+00 @@ -84,10 +85,10 @@ init_forces: ! |2 62 -3.1661341866163668e+00 3.0572378789319057e+00 -2.1766321256993351e+00 63 2.4681627533803421e+00 -4.3463718591241030e+00 -2.6890657263468221e-01 64 2.9466851841874400e+00 3.1594069934522051e+00 5.2240357776040334e+00 -run_vdwl: -275.783459965546 +run_vdwl: -275.78345996554606 run_coul: 0 run_stress: ! |2- - 3.8014765489615172e+01 4.0945069309188604e+01 4.3999047304618138e+01 -6.7428911902544897e+00 2.6683372066660386e+01 2.8012308731515625e+00 + 3.8014765489615172e+01 4.0945069309188604e+01 4.3999047304618138e+01 -6.7428911902547171e+00 2.6683372066660358e+01 2.8012308731515625e+00 run_forces: ! |2 1 -7.7534206913915771e-01 2.8219413188105253e+00 1.3054329854322777e+00 2 -1.8130861104964291e+00 -1.1994378582483485e+00 -1.4733545605818472e+00 @@ -104,8 +105,8 @@ run_forces: ! |2 13 -4.4494824281011508e-01 4.7509967202471213e+00 -1.4136935066319520e+00 14 -1.5581267916203356e+00 3.9167644303299509e+00 2.6757555350685747e-02 15 -3.7108162817126420e+00 4.6350796729234540e+00 -2.8304249142820872e+00 - 16 1.7041447944666661e+00 -1.1393269201002276e-01 5.9145116848020773e+00 - 17 2.3162590395805367e+00 2.9441962202331622e+00 -3.5000049380321943e+00 + 16 1.7041447944666661e+00 -1.1393269201002632e-01 5.9145116848020791e+00 + 17 2.3162590395805367e+00 2.9441962202331622e+00 -3.5000049380321947e+00 18 -4.0014232990890441e-01 3.0796282485754389e-01 3.3665032517219542e+00 19 -1.2556245715589298e+00 -2.7312087083164216e+00 -3.8429646943139034e-01 20 -5.7350382502885031e+00 2.0173956623489531e-01 1.0196418942444634e+00 @@ -120,7 +121,7 @@ run_forces: ! |2 29 -3.0591700441243037e+00 1.0767212806375315e+00 -1.4424137828933918e+00 30 -1.4598855937410891e+00 8.7458207809737021e-01 -8.7190785769613122e-01 31 -1.3636082001861620e+00 1.5015317452309269e+00 -1.5350736370460383e-01 - 32 -2.7909066237776918e+00 7.7422060283896244e-01 -8.9877027420604350e-01 + 32 -2.7909066237776914e+00 7.7422060283896244e-01 -8.9877027420604350e-01 33 4.3399235010929829e+00 -2.5818570915550407e+00 2.9057580939567385e+00 34 8.6694826333752439e-01 -6.6783355869965533e-02 4.0166291067436966e-02 35 1.2326410175497016e+00 1.7672448679765296e-01 2.6119736967557130e+00 @@ -135,10 +136,10 @@ run_forces: ! |2 44 3.1898872823049222e+00 -3.5068520273855599e+00 1.8104056127730672e+00 45 -2.3458685258695731e+00 1.5729147505816061e+00 -2.8752422042742385e+00 46 -5.2392060421735298e-01 -1.4424486188077736e+00 4.9780851897838669e+00 - 47 2.6850560257735139e+00 1.7251050915466237e+00 7.6181283293787772e-01 + 47 2.6850560257735139e+00 1.7251050915466246e+00 7.6181283293787772e-01 48 1.2747125939394275e+00 -2.7703676427000978e-01 -8.9782244307514136e-02 49 -2.6955845424176390e+00 -4.1907197832362328e+00 -2.3301295947101792e+00 - 50 -5.6209787715791215e-01 2.6635817222553522e+00 -1.1946264592384601e+00 + 50 -5.6209787715791215e-01 2.6635817222553539e+00 -1.1946264592384610e+00 51 -1.9991954953954585e+00 2.0402557248500282e+00 3.7258404750762781e+00 52 4.6951644839913822e+00 -4.9418641566017545e+00 4.5138746249764852e+00 53 3.6286232825540430e+00 3.0961367575712391e+00 2.0882688547693129e+00 @@ -147,10 +148,10 @@ run_forces: ! |2 56 -5.0010880972516536e-01 -3.0949934817242841e-02 -1.8925849534718477e+00 57 -6.6566405053166355e-02 -8.4258478062523789e-01 -2.6021657717986374e-01 58 2.5371442159965878e+00 -8.7526440055363264e-01 1.4949346718757783e+00 - 59 2.9916914714794025e+00 2.5062335807851146e+00 -3.1755629216794357e+00 + 59 2.9916914714794021e+00 2.5062335807851146e+00 -3.1755629216794357e+00 60 -2.9243316010019225e+00 -5.0114677474338842e+00 -2.6969232339454456e+00 61 -1.2139394584401273e+00 1.5493721114180057e+00 -1.1508838380601498e+00 62 -3.1639283471459425e+00 3.0546678694930378e+00 -2.1747042794001317e+00 - 63 2.4654069560179650e+00 -4.3414818100056856e+00 -2.6604151896673933e-01 + 63 2.4654069560179646e+00 -4.3414818100056856e+00 -2.6604151896673933e-01 64 2.9397922209293519e+00 3.1520594954801795e+00 5.2155452896559638e+00 ... diff --git a/unittest/force-styles/tests/manybody-pair-comb3.yaml b/unittest/force-styles/tests/manybody-pair-comb3.yaml index 6c8290cb10..4892aec482 100644 --- a/unittest/force-styles/tests/manybody-pair-comb3.yaml +++ b/unittest/force-styles/tests/manybody-pair-comb3.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable -date_generated: Fri Feb 26 23:09:14 2021 +date_generated: Fri Mar 18 22:17:43 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | pair comb3 pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * ffield.comb3 C C C C N N N N extract: ! "" natoms: 64 -init_vdwl: -4.262196799538 +init_vdwl: -4.262196799538002 init_coul: 0 init_stress: ! |- -5.4044225127487408e+01 -5.6294823503326228e+01 -6.1598553071527618e+01 4.6162435900156122e+00 -2.0509689129709702e+01 -4.2576678528074137e+00 @@ -84,7 +85,7 @@ init_forces: ! |2 62 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 63 -2.5176670219302633e+00 2.0717736507107034e+00 2.9357584209133982e+00 64 -4.9843077084015803e+00 -5.4592285318606883e+00 -5.6130890399330191e+00 -run_vdwl: -4.29564844356388 +run_vdwl: -4.295648443563877 run_coul: 0 run_stress: ! |- -5.4267118842024573e+01 -5.6533164301060637e+01 -6.1852222250269804e+01 4.6439791166276025e+00 -2.0590841001386611e+01 -4.3056108355573022e+00 diff --git a/unittest/force-styles/tests/manybody-pair-edip_multi.yaml b/unittest/force-styles/tests/manybody-pair-edip_multi.yaml index 0f987836e1..b161e1db76 100644 --- a/unittest/force-styles/tests/manybody-pair-edip_multi.yaml +++ b/unittest/force-styles/tests/manybody-pair-edip_multi.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:15 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:44 2022 epsilon: 1.5e-13 +skip_tests: prerequisites: ! | pair edip/multi pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * SiC.edip Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -163.900683723295 +init_vdwl: -163.90068372329495 init_coul: 0 init_stress: ! |- -5.8957511455858798e+02 -5.9358556599643998e+02 -6.0582715425756260e+02 -7.7461856998816359e-01 -3.5449708810943299e+01 6.0358873009680941e+01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 4.2423023573252649e+00 -4.2437011984036177e+00 3.6301121042163134e+00 63 -1.9168909212115635e+00 1.8588573169033795e-01 -5.3807119221021207e+00 64 3.9655634387022887e+00 4.8051691350629415e+00 -8.3823885520783463e+00 -run_vdwl: -163.995520403999 +run_vdwl: -163.99552040399922 run_coul: 0 run_stress: ! |- -5.8954094973774431e+02 -5.9339516790815333e+02 -6.0568479850551216e+02 8.0554817494012099e-01 -3.4594782691712908e+01 5.9968329285625259e+01 diff --git a/unittest/force-styles/tests/manybody-pair-extep.yaml b/unittest/force-styles/tests/manybody-pair-extep.yaml index ec69217b4a..f9cbfb49e6 100644 --- a/unittest/force-styles/tests/manybody-pair-extep.yaml +++ b/unittest/force-styles/tests/manybody-pair-extep.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:15 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:44 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair extep pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * BN.extep B B B B N N N N extract: ! "" natoms: 64 -init_vdwl: -8.35953889724907 +init_vdwl: -8.359538897249072 init_coul: 0 init_stress: ! |- -9.8115086872000575e+01 -1.0128398153031480e+02 -1.0881402935898043e+02 7.9461199572646493e+00 -3.2762787278107325e+01 -1.5641130047291398e+01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 1.6194631652095164e+00 -1.8915906665160171e+00 1.5968589798885620e+00 63 -4.2153728649170885e+00 3.4681853182576141e+00 4.9192624131836515e+00 64 -5.8791675102747618e+00 -6.4393494182844400e+00 -6.6208407800581917e+00 -run_vdwl: -8.5008533235016 +run_vdwl: -8.500853323501596 run_coul: 0 run_stress: ! |- -9.8904571780486037e+01 -1.0224033233682025e+02 -1.0995227719752538e+02 7.6528290764675049e+00 -3.3060216107241544e+01 -1.6566570707854311e+01 diff --git a/unittest/force-styles/tests/manybody-pair-gw.yaml b/unittest/force-styles/tests/manybody-pair-gw.yaml index 94a2db51a4..980f5bd539 100644 --- a/unittest/force-styles/tests/manybody-pair-gw.yaml +++ b/unittest/force-styles/tests/manybody-pair-gw.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:15 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:44 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair gw pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * SiC.gw Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -175.936189332503 +init_vdwl: -175.93618933250326 init_coul: 0 init_stress: ! |- -5.8276420551105821e+02 -5.8346830418436662e+02 -5.9635186090956915e+02 -4.0793904942361108e+00 -2.1745769426357356e+01 6.6659517988421783e+01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 2.7519690325090496e+00 -9.9223410854458582e-01 1.1407638591976261e+00 63 -4.8143228297845866e+00 -4.0270544701096345e+00 -6.1213019115492795e+00 64 5.8092450572613377e+00 6.0819193766747937e+00 -9.3149111631847408e+00 -run_vdwl: -176.024796973854 +run_vdwl: -176.02479697385394 run_coul: 0 run_stress: ! |- -5.8366571087413683e+02 -5.8423594877692676e+02 -5.9716242780237587e+02 -3.1815762627223547e+00 -2.0790779606907606e+01 6.6758710068664939e+01 diff --git a/unittest/force-styles/tests/manybody-pair-gw_zbl.yaml b/unittest/force-styles/tests/manybody-pair-gw_zbl.yaml index bdda7df922..2857cbb29c 100644 --- a/unittest/force-styles/tests/manybody-pair-gw_zbl.yaml +++ b/unittest/force-styles/tests/manybody-pair-gw_zbl.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:15 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:44 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair gw/zbl pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * SiC.gw.zbl Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -175.936174891673 +init_vdwl: -175.93617489167295 init_coul: 0 init_stress: ! |- -5.8276406110669188e+02 -5.8346815587322897e+02 -5.9635169680266551e+02 -4.0794077115757972e+00 -2.1745700506730312e+01 6.6659517818741762e+01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 2.7519673193592538e+00 -9.9223209492059505e-01 1.1407621379187511e+00 63 -4.8143194318839724e+00 -4.0270585558397460e+00 -6.1213061124576491e+00 64 5.8092540975566473e+00 6.0819293431378529e+00 -9.3149006808172707e+00 -run_vdwl: -176.024782474281 +run_vdwl: -176.02478247428076 run_coul: 0 run_stress: ! |- -5.8366556611633632e+02 -5.8423579984632795e+02 -5.9716226264864974e+02 -3.1815930970724891e+00 -2.0790710083930556e+01 6.6758711013558496e+01 diff --git a/unittest/force-styles/tests/manybody-pair-lcbop.yaml b/unittest/force-styles/tests/manybody-pair-lcbop.yaml index 5c406b2315..50f55183a8 100644 --- a/unittest/force-styles/tests/manybody-pair-lcbop.yaml +++ b/unittest/force-styles/tests/manybody-pair-lcbop.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:15 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:47 2022 epsilon: 7.5e-12 +skip_tests: prerequisites: ! | pair lcbop pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * C.lcbop C C C C C C C C extract: ! "" natoms: 64 -init_vdwl: 8.17964021758716 +init_vdwl: 8.179640217587156 init_coul: 0 init_stress: ! |- -1.2435703568682847e+02 -1.2857102333786813e+02 -1.3890567540223492e+02 2.5932262530693418e+01 -2.6427929407841010e+01 -3.0892916656406346e+01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 1.6765145761367202e+00 -2.0782148288797191e+00 1.8091954116807478e+00 63 -9.5306462336143234e+00 7.7221239702292852e+00 1.1380605030752243e+01 64 -9.2795211740539081e+00 -1.0180658540458492e+01 -9.9052284360191454e+00 -run_vdwl: 7.86535389924738 +run_vdwl: 7.865353899247382 run_coul: 0 run_stress: ! |- -1.2481966708403526e+02 -1.2933233823626156e+02 -1.3982248076124634e+02 2.6116999993827992e+01 -2.6247661471622003e+01 -3.1660886467127749e+01 diff --git a/unittest/force-styles/tests/manybody-pair-meam.yaml b/unittest/force-styles/tests/manybody-pair-meam.yaml index fed2a060cf..2c599c0a3f 100644 --- a/unittest/force-styles/tests/manybody-pair-meam.yaml +++ b/unittest/force-styles/tests/manybody-pair-meam.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:15 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:47 2022 epsilon: 1e-10 +skip_tests: prerequisites: ! | pair meam pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | extract: ! | scale 2 natoms: 64 -init_vdwl: -294.561168519792 +init_vdwl: -294.5611685197916 init_coul: 0 init_stress: ! |- -2.2038887137312767e+02 -2.2231702131012665e+02 -2.2247104240655943e+02 7.3648974780203380e+00 -6.8098468133799006e+00 4.2641599596627948e+00 @@ -84,7 +85,7 @@ init_forces: ! |2 62 9.9419545458636727e-01 -8.2884838986402398e-01 7.4103114940356063e-01 63 7.3533009035327668e-02 -7.0509323811366853e-01 2.4535215113611608e-01 64 1.3067722952287268e+00 1.7737090528979478e+00 8.9345357265121406e-01 -run_vdwl: -294.558633724134 +run_vdwl: -294.55863372413376 run_coul: 0 run_stress: ! |- -2.2024934072613746e+02 -2.2214156836941581e+02 -2.2227662205685479e+02 7.5246892165404979e+00 -6.5974288946005712e+00 4.4471195201266918e+00 diff --git a/unittest/force-styles/tests/manybody-pair-mliap_nn.yaml b/unittest/force-styles/tests/manybody-pair-mliap_nn.yaml index 04f742536a..eee142f767 100644 --- a/unittest/force-styles/tests/manybody-pair-mliap_nn.yaml +++ b/unittest/force-styles/tests/manybody-pair-mliap_nn.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Mar 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Wed Mar 24 12:18:23 202 +date_generated: Fri Mar 18 22:17:47 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair mliap pair zbl @@ -18,10 +19,10 @@ pair_coeff: ! | * * mliap Ta Ta Ta Ta Ta Ta Ta Ta extract: ! "" natoms: 64 -init_vdwl: -473.569864629026 +init_vdwl: -473.5698646290258 init_coul: 0 init_stress: ! |2- - 3.9989504688551500e+02 4.0778136516736993e+02 4.3596322435184823e+02 -2.5242497284339720e+01 1.2811620806363655e+02 2.8644673361821793e+00 + 3.9989504688551500e+02 4.0778136516736993e+02 4.3596322435184845e+02 -2.5242497284339720e+01 1.2811620806363655e+02 2.8644673361821793e+00 init_forces: ! |2 1 -3.7538180163781538e+00 8.8612947043788708e+00 6.7712977816732263e+00 2 -7.6696525239232596e+00 -3.7674335682223203e-01 -5.7958054718422760e+00 @@ -29,7 +30,7 @@ init_forces: ! |2 4 -4.7103509354198474e+00 9.2783458784125941e+00 4.3108702582741429e+00 5 -2.0331946400488916e+00 -2.9593716047756180e+00 -1.6136351145373196e+00 6 1.8086748683348572e+00 4.6479727629048675e+00 3.0425695895915184e-01 - 7 -3.0573043543220644e+00 -4.0575899915120264e+00 1.5283788878527900e+00 + 7 -3.0573043543220644e+00 -4.0575899915120281e+00 1.5283788878527900e+00 8 2.7148403621334427e-01 1.3063473238306007e+00 -1.1268098385676173e+00 9 5.2043326273129953e-01 -2.9340446386399996e+00 -7.6461969078455834e+00 10 -6.2786875145099508e-01 5.6606570005199308e-02 -5.3746300485699576e+00 @@ -65,11 +66,11 @@ init_forces: ! |2 40 9.5193696695210637e+00 -7.0213638399035432e+00 -1.5692669012530696e+00 41 2.4000089474497699e-01 1.0045144396502914e+00 -2.3032449685213630e+00 42 -9.4741999244791426e+00 -6.3134658287662750e+00 -3.6928028439517893e+00 - 43 2.7218639962411728e-01 -1.3813634477251096e+01 5.5147832931992291e-01 + 43 2.7218639962411773e-01 -1.3813634477251096e+01 5.5147832931992202e-01 44 8.0196107396135208e+00 -8.1793730426384545e+00 3.5131695854462590e+00 45 -1.8910274064701343e-01 3.9137627573846219e+00 -7.4450993876429399e+00 46 -3.5282857552811575e+00 -5.1713579630178099e+00 1.2477491203990510e+01 - 47 5.1131478665605341e+00 2.3800985688973459e+00 5.1348001359881970e+00 + 47 5.1131478665605341e+00 2.3800985688973468e+00 5.1348001359881987e+00 48 2.1755560727357057e+00 2.9996491762493216e+00 -9.9575511910097214e-01 49 -2.3978299788760209e+00 -1.2283692236805253e+01 -8.3755937565454435e+00 50 3.6161933080447888e+00 5.6291551969069182e+00 -6.9709721613230968e-01 @@ -87,16 +88,16 @@ init_forces: ! |2 62 -6.2693637951458694e+00 5.5593866650560679e+00 -4.0417158962655781e+00 63 5.8570431431678962e+00 -6.2896068000076317e+00 -3.8788666930728688e+00 64 7.5837965251215369e+00 7.5954689486766096e+00 1.6804021764142011e+01 -run_vdwl: -473.666568306022 +run_vdwl: -473.6665683060222 run_coul: 0 run_stress: ! |2- - 3.9951053758431499e+02 4.0757094669497650e+02 4.3599209936956868e+02 -2.5012844114476398e+01 1.2751742945242590e+02 3.9821818278564844e+00 + 3.9951053758431510e+02 4.0757094669497650e+02 4.3599209936956890e+02 -2.5012844114476398e+01 1.2751742945242590e+02 3.9821818278567118e+00 run_forces: ! |2 1 -3.7832595710893155e+00 8.8212124103655292e+00 6.7792549500694745e+00 2 -7.6693903913873163e+00 -4.4331479267505980e-01 -5.8319844453604492e+00 3 -3.5652510811236748e-01 -1.2843261396638010e+00 2.3164336943032460e+00 4 -4.6688281400123417e+00 9.2569804046918627e+00 4.2532553525093961e+00 - 5 -2.0698377683688305e+00 -3.0068940885360655e+00 -1.5557558367041349e+00 + 5 -2.0698377683688309e+00 -3.0068940885360655e+00 -1.5557558367041349e+00 6 1.9121936983089021e+00 4.6485144224151016e+00 3.8302570899366983e-01 7 -3.0000564919294019e+00 -3.9598169423628935e+00 1.4730795882443171e+00 8 2.2616298546615310e-01 1.3160780554993146e+00 -1.1365737437456360e+00 @@ -127,18 +128,18 @@ run_forces: ! |2 33 1.0688722918141039e+01 -5.7920158261872583e+00 9.6923706747923646e+00 34 -1.3525464452783258e+00 -1.0575652830645854e-01 1.6380965403350563e+00 35 2.5193832475087721e+00 -2.2598987796878789e+00 5.6810280412635601e+00 - 36 1.7111787089042565e+00 -4.4473718671663391e+00 9.6398513850121076e-02 + 36 1.7111787089042565e+00 -4.4473718671663391e+00 9.6398513850120965e-02 37 -3.8563809307986823e+00 5.6131073606614059e+00 -6.6177968130852260e+00 38 1.5064516388374909e+00 -3.1694753678232956e-01 -8.3526359314898979e-01 39 4.1314418694153812e+00 -6.2751004763663678e+00 -1.1210904504268449e+01 40 9.5830290785144836e+00 -7.0395435048262769e+00 -1.6267459470122683e+00 41 3.1375436243120802e-01 1.0622164383329200e+00 -2.2467935230672076e+00 - 42 -9.4881290346220375e+00 -6.3542967900678029e+00 -3.7436081761319060e+00 + 42 -9.4881290346220410e+00 -6.3542967900678029e+00 -3.7436081761319024e+00 43 2.2855728522521823e-01 -1.3797673758210431e+01 5.1169123226999269e-01 44 8.0135824689800454e+00 -8.1618220152116709e+00 3.4767795780208774e+00 - 45 -2.2793629160624870e-01 3.8533578964252726e+00 -7.3720918772105994e+00 - 46 -3.5217473183911405e+00 -5.1375353430494126e+00 1.2535347493777751e+01 - 47 5.1244898311428937e+00 2.3801653011346930e+00 5.1114297013297003e+00 + 45 -2.2793629160624826e-01 3.8533578964252726e+00 -7.3720918772105994e+00 + 46 -3.5217473183911387e+00 -5.1375353430494126e+00 1.2535347493777753e+01 + 47 5.1244898311428937e+00 2.3801653011346930e+00 5.1114297013296994e+00 48 2.1906793040748171e+00 3.0345200169741182e+00 -1.0179863236095192e+00 49 -2.4788694934316329e+00 -1.2411071815396923e+01 -8.4971983039341392e+00 50 3.6569038614206466e+00 5.6055766933888798e+00 -7.2525721879624516e-01 diff --git a/unittest/force-styles/tests/manybody-pair-mliap_snap_chem.yaml b/unittest/force-styles/tests/manybody-pair-mliap_snap_chem.yaml index 08ebfed3b3..b1a93046db 100644 --- a/unittest/force-styles/tests/manybody-pair-mliap_snap_chem.yaml +++ b/unittest/force-styles/tests/manybody-pair-mliap_snap_chem.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:16 2021 +date_generated: Fri Mar 18 22:17:47 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair mliap pair zbl @@ -22,142 +23,142 @@ pair_coeff: ! | * * mliap In In In In P P P P extract: ! "" natoms: 64 -init_vdwl: -185.3871232982 +init_vdwl: -185.38712329820027 init_coul: 0 init_stress: ! |2- - 2.1627572764873941e+02 2.1843973818802459e+02 2.2323704161405180e+02 -5.3476822166125260e+00 2.9965125280144921e+01 1.1801773510998568e+00 + 2.1627572764873955e+02 2.1843973818802462e+02 2.2323704161405180e+02 -5.3476822166124451e+00 2.9965125280144893e+01 1.1801773510998288e+00 init_forces: ! |2 - 1 -8.9407797360085750e-01 3.1174511790027069e+00 1.7848004756991140e+00 - 2 -2.3497957616596570e+00 -7.0361817598817300e-01 -1.5634923191374663e+00 - 3 6.2372158338858297e-01 2.7149161557212836e-01 -4.8035793806964550e-01 - 4 -2.0337936615474277e+00 2.9491894607511560e+00 9.8066478014365177e-01 - 5 -1.9807302026626274e+00 -4.1921845197039964e-01 -3.9514999290884223e-01 - 6 -1.0256636650332038e-01 2.3662295416638282e+00 9.0816298775387960e-01 - 7 -6.0657120592984892e-01 -8.0634286798072863e-01 2.1759740426498744e+00 - 8 6.0627276316787593e-01 1.0677577347039506e+00 -1.2887262448970753e+00 - 9 -3.0674852805673963e-01 -2.0605633540913679e+00 -2.5500662803249239e+00 - 10 -1.9428976574806009e-01 -1.4648835736857642e+00 -2.8490531930038263e+00 + 1 -8.9407797360085706e-01 3.1174511790027060e+00 1.7848004756991140e+00 + 2 -2.3497957616596574e+00 -7.0361817598817256e-01 -1.5634923191374668e+00 + 3 6.2372158338858452e-01 2.7149161557213058e-01 -4.8035793806964533e-01 + 4 -2.0337936615474259e+00 2.9491894607511564e+00 9.8066478014365321e-01 + 5 -1.9807302026626288e+00 -4.1921845197040009e-01 -3.9514999290884223e-01 + 6 -1.0256636650332041e-01 2.3662295416638286e+00 9.0816298775387949e-01 + 7 -6.0657120592984815e-01 -8.0634286798072863e-01 2.1759740426498739e+00 + 8 6.0627276316787682e-01 1.0677577347039506e+00 -1.2887262448970751e+00 + 9 -3.0674852805674102e-01 -2.0605633540913679e+00 -2.5500662803249234e+00 + 10 -1.9428976574805981e-01 -1.4648835736857646e+00 -2.8490531930038263e+00 11 3.1532548864214469e+00 -2.9033258960601414e+00 2.2619034310429740e+00 - 12 -5.4038968585110823e+00 -3.2935652899479950e+00 -2.5707355493491839e+00 - 13 -6.1736753137043876e-01 5.1000477579656485e+00 -1.3304391624961645e+00 - 14 -1.4190543180546633e+00 3.3413841917147451e+00 4.6351390250498647e-01 - 15 -3.1131424694968639e+00 4.4700267996081635e+00 -3.2364337367424323e+00 - 16 1.7079914236492706e+00 -1.9995742761541713e-01 5.0185841295230196e+00 - 17 2.3724862536641020e+00 3.0987980523864964e+00 -3.4198379943456869e+00 - 18 -2.5111265055016418e-01 7.3348166166902651e-01 3.0622036193004067e+00 - 19 -1.2828262181283363e+00 -2.2345757410919136e+00 -3.3669351804163505e-01 - 20 -5.9491949074906927e+00 3.2510448152978932e-01 6.8450449383665313e-01 - 21 1.3962036186373195e+00 3.9865506204930412e-01 -2.5893554970082731e+00 + 12 -5.4038968585110840e+00 -3.2935652899479950e+00 -2.5707355493491839e+00 + 13 -6.1736753137043876e-01 5.1000477579656494e+00 -1.3304391624961647e+00 + 14 -1.4190543180546629e+00 3.3413841917147442e+00 4.6351390250498603e-01 + 15 -3.1131424694968644e+00 4.4700267996081635e+00 -3.2364337367424332e+00 + 16 1.7079914236492701e+00 -1.9995742761541768e-01 5.0185841295230187e+00 + 17 2.3724862536641029e+00 3.0987980523864973e+00 -3.4198379943456869e+00 + 18 -2.5111265055016468e-01 7.3348166166902651e-01 3.0622036193004081e+00 + 19 -1.2828262181283365e+00 -2.2345757410919114e+00 -3.3669351804163505e-01 + 20 -5.9491949074906927e+00 3.2510448152978899e-01 6.8450449383665324e-01 + 21 1.3962036186373190e+00 3.9865506204930412e-01 -2.5893554970082739e+00 22 -5.1263732155413688e+00 3.6744897485626438e+00 -4.8303251395784113e+00 - 23 1.7617874308698167e+00 2.9253519141342812e+00 1.4679679444255547e+00 - 24 1.5937879337284957e+00 8.9992286487733242e-01 2.8087468575298802e+00 - 25 1.0286448774492765e+00 -4.3669506584228418e-01 1.2594354985828544e+00 - 26 -3.5670456442877885e-01 -3.9811471877482152e-01 8.1854393579980123e-01 - 27 1.9066785243503745e+00 -2.9510326328254666e-01 1.2119553206259761e+00 + 23 1.7617874308698158e+00 2.9253519141342803e+00 1.4679679444255556e+00 + 24 1.5937879337284966e+00 8.9992286487733242e-01 2.8087468575298802e+00 + 25 1.0286448774492765e+00 -4.3669506584228257e-01 1.2594354985828535e+00 + 26 -3.5670456442877874e-01 -3.9811471877482207e-01 8.1854393579979901e-01 + 27 1.9066785243503748e+00 -2.9510326328254666e-01 1.2119553206259761e+00 28 2.5221087546187970e-01 1.4370172575472946e+00 4.1039332214108297e+00 - 29 -2.7893073887365909e+00 7.8106446652879402e-01 -8.2039261846997913e-01 - 30 -1.8694503114341463e+00 7.0812686858707219e-01 -9.1751940639239238e-01 - 31 -7.0985766256762606e-01 8.6963471463259845e-01 -7.5188557225015407e-01 - 32 -2.4089849337056686e+00 4.0992982351371343e-01 -1.1381600041412354e-01 + 29 -2.7893073887365909e+00 7.8106446652879447e-01 -8.2039261846997913e-01 + 30 -1.8694503114341459e+00 7.0812686858707219e-01 -9.1751940639239149e-01 + 31 -7.0985766256762695e-01 8.6963471463259756e-01 -7.5188557225015407e-01 + 32 -2.4089849337056686e+00 4.0992982351371365e-01 -1.1381600041412332e-01 33 4.3597028481189950e+00 -2.6773596435480469e+00 3.1791467867699659e+00 - 34 5.1607419486495609e-01 1.3141798772668656e-01 8.7023229642897881e-02 - 35 1.2413218618562052e+00 -4.1427608114771042e-01 2.5651243684278673e+00 - 36 -1.1152887975138914e-01 -2.3088354090108645e+00 -2.3687452176819246e-01 - 37 -2.1752322691080082e+00 1.9377327531750534e+00 -2.2419453197067281e+00 - 38 -9.9594979744325007e-01 -1.8147173502133196e-01 6.8832530755714671e-01 - 39 2.8779281856552115e+00 -1.7332955648283568e+00 -3.4260103364251702e+00 + 34 5.1607419486495698e-01 1.3141798772668656e-01 8.7023229642896549e-02 + 35 1.2413218618562050e+00 -4.1427608114771042e-01 2.5651243684278677e+00 + 36 -1.1152887975138892e-01 -2.3088354090108645e+00 -2.3687452176819246e-01 + 37 -2.1752322691080082e+00 1.9377327531750534e+00 -2.2419453197067285e+00 + 38 -9.9594979744324963e-01 -1.8147173502133196e-01 6.8832530755714627e-01 + 39 2.8779281856552119e+00 -1.7332955648283566e+00 -3.4260103364251711e+00 40 4.3351429466694658e+00 -2.2624572291840446e+00 -1.7065975882223454e+00 - 41 2.5124166305689205e-01 -4.2179260496370535e-01 -1.2503380336802188e+00 - 42 -3.5352439688397177e+00 -1.6053715846066745e+00 -6.7917775288119286e-01 - 43 8.4817996010401342e-01 -4.8899181684596487e+00 1.7369510897908608e-01 - 44 3.0506037114469597e+00 -3.3226877009576907e+00 1.7796293414951672e+00 - 45 -1.8374092699066717e+00 1.5294723708757643e+00 -2.7502022232711680e+00 - 46 -9.1023563070749636e-01 -1.7778137773508709e+00 4.9843270240840054e+00 - 47 2.6124800260927605e+00 1.6175231582888072e+00 1.5805303054926745e+00 - 48 1.4743780750991475e+00 3.6707315780789784e-02 -2.9750115931288068e-01 - 49 -2.3858202682345646e+00 -4.2223184267227856e+00 -2.7959407680025525e+00 - 50 2.4067134019906966e-01 2.8105796871762401e+00 -1.0687621004291821e+00 - 51 -1.7932456135513859e+00 2.6201558060481256e+00 3.7648454668413778e+00 - 52 4.6358669186213994e+00 -4.8660554435252061e+00 5.0894919019570990e+00 + 41 2.5124166305689205e-01 -4.2179260496370535e-01 -1.2503380336802179e+00 + 42 -3.5352439688397177e+00 -1.6053715846066747e+00 -6.7917775288119320e-01 + 43 8.4817996010401320e-01 -4.8899181684596487e+00 1.7369510897908585e-01 + 44 3.0506037114469597e+00 -3.3226877009576921e+00 1.7796293414951698e+00 + 45 -1.8374092699066711e+00 1.5294723708757640e+00 -2.7502022232711680e+00 + 46 -9.1023563070749647e-01 -1.7778137773508709e+00 4.9843270240840036e+00 + 47 2.6124800260927610e+00 1.6175231582888072e+00 1.5805303054926745e+00 + 48 1.4743780750991475e+00 3.6707315780788896e-02 -2.9750115931288024e-01 + 49 -2.3858202682345651e+00 -4.2223184267227856e+00 -2.7959407680025525e+00 + 50 2.4067134019906877e-01 2.8105796871762401e+00 -1.0687621004291821e+00 + 51 -1.7932456135513859e+00 2.6201558060481247e+00 3.7648454668413782e+00 + 52 4.6358669186214012e+00 -4.8660554435252070e+00 5.0894919019571008e+00 53 2.9898995132891759e+00 3.3216926541391691e+00 2.4227995842838990e+00 - 54 1.8732808586337490e+00 -3.0909639789911152e+00 -2.2880122319662020e+00 - 55 1.1426678804104569e+00 -2.5892472259617532e+00 -3.2449552890237379e+00 - 56 -1.1541931360327617e-01 -8.3260558816073249e-02 -1.7966753733604057e+00 - 57 -1.2751171337205552e-01 -8.8899643643851300e-01 -5.0726814112209695e-02 - 58 2.4813755367140655e+00 -1.2765007868408016e+00 1.5628981219370035e+00 - 59 2.9909449561888715e+00 2.1621928717215857e+00 -2.3820831167094330e+00 - 60 -2.2387715060953868e+00 -5.2442113310349736e+00 -2.6985516164859109e+00 - 61 -1.0184694703280122e+00 1.5256818152660523e+00 -1.0113329140640652e+00 - 62 -2.7862663394350542e+00 2.5876139756856791e+00 -1.7815179130043122e+00 + 54 1.8732808586337490e+00 -3.0909639789911147e+00 -2.2880122319662011e+00 + 55 1.1426678804104577e+00 -2.5892472259617527e+00 -3.2449552890237365e+00 + 56 -1.1541931360327529e-01 -8.3260558816073277e-02 -1.7966753733604057e+00 + 57 -1.2751171337205550e-01 -8.8899643643851300e-01 -5.0726814112209681e-02 + 58 2.4813755367140646e+00 -1.2765007868408011e+00 1.5628981219370035e+00 + 59 2.9909449561888715e+00 2.1621928717215848e+00 -2.3820831167094330e+00 + 60 -2.2387715060953877e+00 -5.2442113310349736e+00 -2.6985516164859127e+00 + 61 -1.0184694703280104e+00 1.5256818152660523e+00 -1.0113329140640650e+00 + 62 -2.7862663394350546e+00 2.5876139756856795e+00 -1.7815179130043122e+00 63 2.4339134295594302e+00 -3.1961735689987636e+00 -4.7891394265908094e-01 64 3.0382364587319710e+00 3.0430454898558588e+00 5.3416679902175384e+00 -run_vdwl: -185.37158003654 +run_vdwl: -185.3715800365395 run_coul: 0 run_stress: ! |2- - 2.1623225685916989e+02 2.1844347630762962e+02 2.2331780542890360e+02 -5.3222115188692429e+00 2.9861519391528514e+01 1.4556702426797457e+00 + 2.1623225685917001e+02 2.1844347630762960e+02 2.2331780542890351e+02 -5.3222115188692971e+00 2.9861519391528528e+01 1.4556702426798678e+00 run_forces: ! |2 - 1 -8.9945686093718891e-01 3.1102506844270676e+00 1.7924405901882392e+00 - 2 -2.3568426321865519e+00 -7.2157123823439751e-01 -1.5714999679660120e+00 - 3 5.9411461824307632e-01 2.8183072295935307e-01 -4.5584602006848729e-01 - 4 -2.0142955850044015e+00 2.9566870880684544e+00 9.5256971160575310e-01 - 5 -1.9922574807409990e+00 -4.3135288450095111e-01 -3.7982056237068562e-01 - 6 -5.1798692305348421e-02 2.3723138325448181e+00 9.3505820052018818e-01 - 7 -5.9119307570788093e-01 -7.7558353156540627e-01 2.1544553310334216e+00 - 8 5.8948882611514830e-01 1.0627350289336350e+00 -1.2852382666540922e+00 + 1 -8.9945686093718891e-01 3.1102506844270676e+00 1.7924405901882381e+00 + 2 -2.3568426321865532e+00 -7.2157123823439751e-01 -1.5714999679660120e+00 + 3 5.9411461824307610e-01 2.8183072295935313e-01 -4.5584602006848723e-01 + 4 -2.0142955850044006e+00 2.9566870880684544e+00 9.5256971160575388e-01 + 5 -1.9922574807409981e+00 -4.3135288450095111e-01 -3.7982056237068340e-01 + 6 -5.1798692305348448e-02 2.3723138325448176e+00 9.3505820052018818e-01 + 7 -5.9119307570787982e-01 -7.7558353156540449e-01 2.1544553310334202e+00 + 8 5.8948882611514741e-01 1.0627350289336348e+00 -1.2852382666540922e+00 9 -3.3097669603148050e-01 -2.0880700958311560e+00 -2.5728226298711561e+00 - 10 -1.9927857234351742e-01 -1.4707681067903973e+00 -2.8077583365509944e+00 - 11 3.1207021637041077e+00 -2.8777137799483214e+00 2.2513409071418939e+00 - 12 -5.3967388032136201e+00 -3.2755306245890572e+00 -2.5607263918480787e+00 - 13 -5.6089163267500575e-01 5.0895164624360953e+00 -1.2955340742015935e+00 - 14 -1.4424532600588069e+00 3.3397136313988538e+00 4.5056661625381278e-01 - 15 -3.1074264051087690e+00 4.4511163568785594e+00 -3.2255959617646495e+00 - 16 1.7028459742310051e+00 -1.9401543199346183e-01 4.9988885414419002e+00 - 17 2.3696411307116665e+00 3.0980579975818054e+00 -3.3992055709392099e+00 - 18 -2.7992627916472068e-01 7.5956985532908217e-01 3.0731406281977875e+00 - 19 -1.3087170031025481e+00 -2.2579241841048194e+00 -3.5423832115910026e-01 - 20 -5.9291180532530054e+00 3.0139344848989125e-01 6.6702127138861189e-01 - 21 1.4061702325656915e+00 3.6170742151671309e-01 -2.6186453774142455e+00 - 22 -5.1213538363270104e+00 3.6881133786353173e+00 -4.8334441466973619e+00 - 23 1.7799014438457179e+00 2.9383932016836729e+00 1.4889345853939060e+00 - 24 1.6265217601475135e+00 8.8638236910287549e-01 2.7958579602051579e+00 - 25 1.0261772589787777e+00 -4.3124823838990639e-01 1.2394756760658081e+00 - 26 -3.6788963153370424e-01 -3.8430715508218222e-01 8.2234939362562109e-01 - 27 1.9227116387813055e+00 -3.1924343057968851e-01 1.2219662551930728e+00 - 28 2.3558028807578302e-01 1.4603195758319958e+00 4.1124437707751715e+00 - 29 -2.7963204027225057e+00 7.9250484371162710e-01 -8.2374097886304931e-01 - 30 -1.8521850555057384e+00 6.8904513184563698e-01 -9.2377203073191461e-01 - 31 -7.0737710488564920e-01 8.7160390581421554e-01 -7.5132187044876142e-01 - 32 -2.3972194269400724e+00 4.0579824422398403e-01 -1.2192450250956055e-01 - 33 4.3391252363949713e+00 -2.6734632549855011e+00 3.1813837430923790e+00 - 34 5.0892540867377134e-01 1.3196433190574863e-01 9.1854393014863867e-02 - 35 1.2518949422589467e+00 -4.0131662341328833e-01 2.5682121097610247e+00 - 36 -1.4250724827861927e-01 -2.2940369352156500e+00 -2.7656165676472910e-01 - 37 -2.1638911011422111e+00 1.9200057202539940e+00 -2.2495537548075712e+00 - 38 -9.8448646953871100e-01 -1.7353311784227321e-01 6.9784505363718075e-01 - 39 2.8621020667478243e+00 -1.7235695529844155e+00 -3.4231784253086803e+00 - 40 4.3701211996432816e+00 -2.2721992461764238e+00 -1.7277010563698145e+00 - 41 2.7615064013020879e-01 -3.9976618325080288e-01 -1.2290534994924236e+00 + 10 -1.9927857234351726e-01 -1.4707681067903968e+00 -2.8077583365509944e+00 + 11 3.1207021637041081e+00 -2.8777137799483206e+00 2.2513409071418935e+00 + 12 -5.3967388032136201e+00 -3.2755306245890572e+00 -2.5607263918480783e+00 + 13 -5.6089163267500619e-01 5.0895164624360953e+00 -1.2955340742015937e+00 + 14 -1.4424532600588069e+00 3.3397136313988520e+00 4.5056661625381322e-01 + 15 -3.1074264051087690e+00 4.4511163568785586e+00 -3.2255959617646495e+00 + 16 1.7028459742310051e+00 -1.9401543199346216e-01 4.9988885414419002e+00 + 17 2.3696411307116665e+00 3.0980579975818046e+00 -3.3992055709392099e+00 + 18 -2.7992627916472068e-01 7.5956985532908261e-01 3.0731406281977867e+00 + 19 -1.3087170031025486e+00 -2.2579241841048194e+00 -3.5423832115910003e-01 + 20 -5.9291180532530054e+00 3.0139344848989147e-01 6.6702127138861189e-01 + 21 1.4061702325656906e+00 3.6170742151671309e-01 -2.6186453774142455e+00 + 22 -5.1213538363270104e+00 3.6881133786353173e+00 -4.8334441466973601e+00 + 23 1.7799014438457179e+00 2.9383932016836734e+00 1.4889345853939060e+00 + 24 1.6265217601475135e+00 8.8638236910287538e-01 2.7958579602051583e+00 + 25 1.0261772589787781e+00 -4.3124823838990606e-01 1.2394756760658081e+00 + 26 -3.6788963153370446e-01 -3.8430715508218188e-01 8.2234939362562132e-01 + 27 1.9227116387813059e+00 -3.1924343057968840e-01 1.2219662551930730e+00 + 28 2.3558028807578357e-01 1.4603195758319969e+00 4.1124437707751706e+00 + 29 -2.7963204027225057e+00 7.9250484371162622e-01 -8.2374097886304931e-01 + 30 -1.8521850555057389e+00 6.8904513184563609e-01 -9.2377203073191461e-01 + 31 -7.0737710488565009e-01 8.7160390581421510e-01 -7.5132187044876320e-01 + 32 -2.3972194269400706e+00 4.0579824422398203e-01 -1.2192450250956144e-01 + 33 4.3391252363949722e+00 -2.6734632549855015e+00 3.1813837430923795e+00 + 34 5.0892540867377156e-01 1.3196433190574863e-01 9.1854393014863867e-02 + 35 1.2518949422589467e+00 -4.0131662341328811e-01 2.5682121097610247e+00 + 36 -1.4250724827861927e-01 -2.2940369352156509e+00 -2.7656165676472905e-01 + 37 -2.1638911011422115e+00 1.9200057202539940e+00 -2.2495537548075712e+00 + 38 -9.8448646953871100e-01 -1.7353311784227321e-01 6.9784505363718097e-01 + 39 2.8621020667478243e+00 -1.7235695529844157e+00 -3.4231784253086803e+00 + 40 4.3701211996432816e+00 -2.2721992461764251e+00 -1.7277010563698145e+00 + 41 2.7615064013020929e-01 -3.9976618325080443e-01 -1.2290534994924227e+00 42 -3.5411751645812308e+00 -1.6301898139986259e+00 -6.9693956624465969e-01 - 43 8.3282307590551552e-01 -4.8791394930408867e+00 1.5641553921436965e-01 - 44 3.0588569737321962e+00 -3.3230712362593824e+00 1.7740893109825144e+00 + 43 8.3282307590551574e-01 -4.8791394930408858e+00 1.5641553921436943e-01 + 44 3.0588569737321967e+00 -3.3230712362593806e+00 1.7740893109825142e+00 45 -1.8543980101593716e+00 1.5090063048017774e+00 -2.7391343400007346e+00 - 46 -9.0836218859416373e-01 -1.7703257020194161e+00 5.0074804595763203e+00 - 47 2.6157347327468776e+00 1.6066618984181202e+00 1.5922002611321855e+00 - 48 1.4730694115534324e+00 6.0150682431382663e-02 -2.9959320813488199e-01 - 49 -2.4357178268972279e+00 -4.2752924255184093e+00 -2.8456954906038585e+00 - 50 2.5008857416428043e-01 2.7975929070952108e+00 -1.0870819292025393e+00 - 51 -1.8364703217563023e+00 2.6546000140944859e+00 3.7824174449012462e+00 + 46 -9.0836218859416396e-01 -1.7703257020194161e+00 5.0074804595763194e+00 + 47 2.6157347327468772e+00 1.6066618984181202e+00 1.5922002611321857e+00 + 48 1.4730694115534333e+00 6.0150682431383107e-02 -2.9959320813488199e-01 + 49 -2.4357178268972288e+00 -4.2752924255184075e+00 -2.8456954906038590e+00 + 50 2.5008857416428043e-01 2.7975929070952121e+00 -1.0870819292025393e+00 + 51 -1.8364703217563023e+00 2.6546000140944868e+00 3.7824174449012453e+00 52 4.6470415706761310e+00 -4.8541726113169865e+00 5.0978546929624020e+00 - 53 3.0332748609694704e+00 3.3674028164180130e+00 2.5018294078539540e+00 - 54 1.8687605158732028e+00 -3.0896400645801418e+00 -2.2872620802274950e+00 + 53 3.0332748609694704e+00 3.3674028164180108e+00 2.5018294078539536e+00 + 54 1.8687605158732028e+00 -3.0896400645801418e+00 -2.2872620802274941e+00 55 1.1194011524426077e+00 -2.5850952550361570e+00 -3.2174616299206584e+00 - 56 -1.2168319727714011e-01 -1.1667111392940022e-01 -1.7915767087323147e+00 - 57 -1.3228227178289417e-01 -9.1363578630224795e-01 -5.3462423971004584e-02 - 58 2.4842158694223677e+00 -1.2568730326784874e+00 1.5401682371106145e+00 - 59 3.0140102195799274e+00 2.1895971720503873e+00 -2.3881807893321017e+00 + 56 -1.2168319727713972e-01 -1.1667111392940022e-01 -1.7915767087323147e+00 + 57 -1.3228227178289331e-01 -9.1363578630224795e-01 -5.3462423971004584e-02 + 58 2.4842158694223682e+00 -1.2568730326784874e+00 1.5401682371106145e+00 + 59 3.0140102195799274e+00 2.1895971720503873e+00 -2.3881807893321030e+00 60 -2.2877466661828931e+00 -5.2803433601364151e+00 -2.7505525589065760e+00 - 61 -1.0115642352983962e+00 1.5284330358705578e+00 -1.0029499332563923e+00 - 62 -2.7811684029592287e+00 2.5821146485313546e+00 -1.7679954771137567e+00 - 63 2.4383789403708427e+00 -3.2264210802804598e+00 -5.0624191626484460e-01 - 64 3.0873388675112903e+00 3.1015018772904330e+00 5.3730513624445901e+00 + 61 -1.0115642352983965e+00 1.5284330358705580e+00 -1.0029499332563923e+00 + 62 -2.7811684029592287e+00 2.5821146485313546e+00 -1.7679954771137576e+00 + 63 2.4383789403708427e+00 -3.2264210802804594e+00 -5.0624191626484549e-01 + 64 3.0873388675112894e+00 3.1015018772904330e+00 5.3730513624445901e+00 ... diff --git a/unittest/force-styles/tests/manybody-pair-mliap_snap_linear.yaml b/unittest/force-styles/tests/manybody-pair-mliap_snap_linear.yaml index 43d7660823..c62c58295d 100644 --- a/unittest/force-styles/tests/manybody-pair-mliap_snap_linear.yaml +++ b/unittest/force-styles/tests/manybody-pair-mliap_snap_linear.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:15 2021 +date_generated: Fri Mar 18 22:17:47 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair mliap pair zbl @@ -18,10 +19,10 @@ pair_coeff: ! | * * mliap Ta Ta Ta Ta Ta Ta Ta Ta extract: ! "" natoms: 64 -init_vdwl: -473.569864629026 +init_vdwl: -473.56986462902603 init_coul: 0 init_stress: ! |2- - 3.9989504688551500e+02 4.0778136516736993e+02 4.3596322435184823e+02 -2.5242497284339720e+01 1.2811620806363655e+02 2.8644673361821793e+00 + 3.9989504688551500e+02 4.0778136516736993e+02 4.3596322435184845e+02 -2.5242497284339720e+01 1.2811620806363655e+02 2.8644673361821793e+00 init_forces: ! |2 1 -3.7538180163781538e+00 8.8612947043788708e+00 6.7712977816732263e+00 2 -7.6696525239232596e+00 -3.7674335682223203e-01 -5.7958054718422760e+00 @@ -29,7 +30,7 @@ init_forces: ! |2 4 -4.7103509354198474e+00 9.2783458784125941e+00 4.3108702582741429e+00 5 -2.0331946400488916e+00 -2.9593716047756180e+00 -1.6136351145373196e+00 6 1.8086748683348572e+00 4.6479727629048675e+00 3.0425695895915184e-01 - 7 -3.0573043543220644e+00 -4.0575899915120264e+00 1.5283788878527900e+00 + 7 -3.0573043543220644e+00 -4.0575899915120281e+00 1.5283788878527900e+00 8 2.7148403621334427e-01 1.3063473238306007e+00 -1.1268098385676173e+00 9 5.2043326273129953e-01 -2.9340446386399996e+00 -7.6461969078455834e+00 10 -6.2786875145099508e-01 5.6606570005199308e-02 -5.3746300485699576e+00 @@ -65,11 +66,11 @@ init_forces: ! |2 40 9.5193696695210637e+00 -7.0213638399035432e+00 -1.5692669012530696e+00 41 2.4000089474497699e-01 1.0045144396502914e+00 -2.3032449685213630e+00 42 -9.4741999244791426e+00 -6.3134658287662750e+00 -3.6928028439517893e+00 - 43 2.7218639962411728e-01 -1.3813634477251096e+01 5.5147832931992291e-01 + 43 2.7218639962411773e-01 -1.3813634477251096e+01 5.5147832931992202e-01 44 8.0196107396135208e+00 -8.1793730426384545e+00 3.5131695854462590e+00 45 -1.8910274064701343e-01 3.9137627573846219e+00 -7.4450993876429399e+00 46 -3.5282857552811575e+00 -5.1713579630178099e+00 1.2477491203990510e+01 - 47 5.1131478665605341e+00 2.3800985688973459e+00 5.1348001359881970e+00 + 47 5.1131478665605341e+00 2.3800985688973468e+00 5.1348001359881987e+00 48 2.1755560727357057e+00 2.9996491762493216e+00 -9.9575511910097214e-01 49 -2.3978299788760209e+00 -1.2283692236805253e+01 -8.3755937565454435e+00 50 3.6161933080447888e+00 5.6291551969069182e+00 -6.9709721613230968e-01 @@ -87,16 +88,16 @@ init_forces: ! |2 62 -6.2693637951458694e+00 5.5593866650560679e+00 -4.0417158962655781e+00 63 5.8570431431678962e+00 -6.2896068000076317e+00 -3.8788666930728688e+00 64 7.5837965251215369e+00 7.5954689486766096e+00 1.6804021764142011e+01 -run_vdwl: -473.666568306022 +run_vdwl: -473.66656830602244 run_coul: 0 run_stress: ! |2- - 3.9951053758431499e+02 4.0757094669497650e+02 4.3599209936956868e+02 -2.5012844114476398e+01 1.2751742945242590e+02 3.9821818278564844e+00 + 3.9951053758431510e+02 4.0757094669497650e+02 4.3599209936956890e+02 -2.5012844114476398e+01 1.2751742945242590e+02 3.9821818278567118e+00 run_forces: ! |2 1 -3.7832595710893155e+00 8.8212124103655292e+00 6.7792549500694745e+00 2 -7.6693903913873163e+00 -4.4331479267505980e-01 -5.8319844453604492e+00 3 -3.5652510811236748e-01 -1.2843261396638010e+00 2.3164336943032460e+00 4 -4.6688281400123417e+00 9.2569804046918627e+00 4.2532553525093961e+00 - 5 -2.0698377683688305e+00 -3.0068940885360655e+00 -1.5557558367041349e+00 + 5 -2.0698377683688309e+00 -3.0068940885360655e+00 -1.5557558367041349e+00 6 1.9121936983089021e+00 4.6485144224151016e+00 3.8302570899366983e-01 7 -3.0000564919294019e+00 -3.9598169423628935e+00 1.4730795882443171e+00 8 2.2616298546615310e-01 1.3160780554993146e+00 -1.1365737437456360e+00 @@ -127,18 +128,18 @@ run_forces: ! |2 33 1.0688722918141039e+01 -5.7920158261872583e+00 9.6923706747923646e+00 34 -1.3525464452783258e+00 -1.0575652830645854e-01 1.6380965403350563e+00 35 2.5193832475087721e+00 -2.2598987796878789e+00 5.6810280412635601e+00 - 36 1.7111787089042565e+00 -4.4473718671663391e+00 9.6398513850121076e-02 + 36 1.7111787089042565e+00 -4.4473718671663391e+00 9.6398513850120965e-02 37 -3.8563809307986823e+00 5.6131073606614059e+00 -6.6177968130852260e+00 38 1.5064516388374909e+00 -3.1694753678232956e-01 -8.3526359314898979e-01 39 4.1314418694153812e+00 -6.2751004763663678e+00 -1.1210904504268449e+01 40 9.5830290785144836e+00 -7.0395435048262769e+00 -1.6267459470122683e+00 41 3.1375436243120802e-01 1.0622164383329200e+00 -2.2467935230672076e+00 - 42 -9.4881290346220375e+00 -6.3542967900678029e+00 -3.7436081761319060e+00 + 42 -9.4881290346220410e+00 -6.3542967900678029e+00 -3.7436081761319024e+00 43 2.2855728522521823e-01 -1.3797673758210431e+01 5.1169123226999269e-01 44 8.0135824689800454e+00 -8.1618220152116709e+00 3.4767795780208774e+00 - 45 -2.2793629160624870e-01 3.8533578964252726e+00 -7.3720918772105994e+00 - 46 -3.5217473183911405e+00 -5.1375353430494126e+00 1.2535347493777751e+01 - 47 5.1244898311428937e+00 2.3801653011346930e+00 5.1114297013297003e+00 + 45 -2.2793629160624826e-01 3.8533578964252726e+00 -7.3720918772105994e+00 + 46 -3.5217473183911387e+00 -5.1375353430494126e+00 1.2535347493777753e+01 + 47 5.1244898311428937e+00 2.3801653011346930e+00 5.1114297013296994e+00 48 2.1906793040748171e+00 3.0345200169741182e+00 -1.0179863236095192e+00 49 -2.4788694934316329e+00 -1.2411071815396923e+01 -8.4971983039341392e+00 50 3.6569038614206466e+00 5.6055766933888798e+00 -7.2525721879624516e-01 diff --git a/unittest/force-styles/tests/manybody-pair-mliap_snap_quadratic.yaml b/unittest/force-styles/tests/manybody-pair-mliap_snap_quadratic.yaml index b07b4fa5b5..aeec87baeb 100644 --- a/unittest/force-styles/tests/manybody-pair-mliap_snap_quadratic.yaml +++ b/unittest/force-styles/tests/manybody-pair-mliap_snap_quadratic.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Mar 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Wed Mar 24 12:24:38 202 +date_generated: Fri Mar 18 22:17:48 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair mliap pair zbl @@ -18,10 +19,10 @@ pair_coeff: ! | * * mliap W W W W W W W W extract: ! "" natoms: 64 -init_vdwl: 310.670038860846 +init_vdwl: 310.67003886084626 init_coul: 0 init_stress: ! |2- - 5.6259528842196187e+02 5.7316629871796738e+02 5.8790591480137323e+02 -1.8189500835315549e+01 1.3614672500307736e+02 5.6212035897053383e+00 + 5.6259528842196210e+02 5.7316629871796738e+02 5.8790591480137346e+02 -1.8189500835315478e+01 1.3614672500307739e+02 5.6212035897053525e+00 init_forces: ! |2 1 -1.7332406552612252e+00 9.6965139437668633e+00 5.8109280039223741e+00 2 -8.4506855506966403e+00 1.7517630868906400e+00 -5.8585143024763751e+00 @@ -29,131 +30,131 @@ init_forces: ! |2 4 -5.4997504048583030e+00 8.6507394288895618e+00 3.5210921442144869e+00 5 -5.4578004799253836e+00 -3.8166835957403560e+00 -1.9324965001410375e+00 6 1.8068295611859355e+00 7.7167110612740411e+00 2.2464754671860354e+00 - 7 -1.4615233556948404e+00 -4.5523205969121312e+00 5.2307165009286525e+00 - 8 1.3470528830761590e+00 1.1150099302890997e+00 -2.4124956929134638e+00 + 7 -1.4615233556948404e+00 -4.5523205969121312e+00 5.2307165009286516e+00 + 8 1.3470528830761608e+00 1.1150099302890997e+00 -2.4124956929134638e+00 9 1.8536678547304528e+00 -5.9192817641183115e+00 -8.9231779770120117e+00 - 10 -1.6830129533144051e+00 -2.0004948002622096e+00 -6.7940188134883588e+00 - 11 9.3899899055663916e+00 -9.6096061996623181e+00 5.4294046031393410e+00 - 12 -1.8440182258152287e+01 -9.1578611598783599e+00 -6.9019373206621033e+00 + 10 -1.6830129533144051e+00 -2.0004948002622087e+00 -6.7940188134883588e+00 + 11 9.3899899055663916e+00 -9.6096061996623181e+00 5.4294046031393401e+00 + 12 -1.8440182258152287e+01 -9.1578611598783617e+00 -6.9019373206621033e+00 13 -1.4789077352315048e+00 1.6126223605834220e+01 -2.3399418562200816e+00 - 14 -5.1192810384232743e+00 7.8887975887856649e+00 2.7987351355628833e+00 + 14 -5.1192810384232752e+00 7.8887975887856649e+00 2.7987351355628838e+00 15 -1.1432288954023196e+01 1.2052925891647078e+01 -7.6561230955500186e+00 16 4.9875199325917112e+00 -7.9756500980837031e-01 1.5348327626794408e+01 17 3.0326448198662455e+00 1.0247763080256838e+01 -1.3162357502394531e+01 18 1.1912120343158321e+00 3.8795028741303881e+00 9.7535980505837134e+00 19 -4.1904376957856400e+00 -3.2045372808825174e+00 -1.1178952155997879e+00 - 20 -2.0524722840954009e+01 1.3584987641399842e+00 1.2643890965526294e+00 + 20 -2.0524722840954009e+01 1.3584987641399842e+00 1.2643890965526297e+00 21 7.8962692301193274e+00 3.0756220916596053e+00 -1.0060035052224105e+01 22 -1.6638865872488534e+01 7.3242501928548176e+00 -1.1470088145525292e+01 23 3.1098873977160020e+00 8.9978923066815906e+00 7.3796685128197010e+00 24 3.7623303590129575e+00 3.9470381598445985e+00 8.3456006313463575e+00 - 25 2.7135762879995773e+00 1.2688233449033359e-01 2.7652325878214103e+00 - 26 -2.5567333671028858e+00 -1.5012729784955012e+00 3.8180756571583805e+00 - 27 5.4933629833598179e+00 -3.5852699914334007e-01 5.6772577899252621e+00 - 28 2.1583223591405485e+00 2.5602854563986126e+00 1.2987493211097293e+01 - 29 -9.3928065614100227e+00 8.1231719788253520e-01 -3.4139694444606663e+00 + 25 2.7135762879995777e+00 1.2688233449033448e-01 2.7652325878214103e+00 + 26 -2.5567333671028858e+00 -1.5012729784955015e+00 3.8180756571583805e+00 + 27 5.4933629833598179e+00 -3.5852699914334007e-01 5.6772577899252639e+00 + 28 2.1583223591405489e+00 2.5602854563986126e+00 1.2987493211097291e+01 + 29 -9.3928065614100262e+00 8.1231719788253520e-01 -3.4139694444606663e+00 30 -6.5111025810175223e+00 3.9239227943865140e+00 -1.9909323666256402e+00 - 31 -4.5532920832558466e+00 2.9334735012590949e+00 -2.2603005294374805e+00 + 31 -4.5532920832558466e+00 2.9334735012590931e+00 -2.2603005294374805e+00 32 -1.1131319171235056e+01 4.0773060096293179e-01 2.3495354245782185e-01 - 33 1.1946312975015427e+01 -4.8997346173109610e+00 8.5135451343035555e+00 - 34 2.2567306848110924e-01 -9.7924723339198039e-01 1.7583322195512454e+00 + 33 1.1946312975015427e+01 -4.8997346173109610e+00 8.5135451343035573e+00 + 34 2.2567306848110835e-01 -9.7924723339198039e-01 1.7583322195512454e+00 35 2.8580692192724184e+00 -9.9224668537616911e-01 8.1615215594264985e+00 36 -9.5804648131257442e-02 -6.2355391184959963e+00 -1.1533359083409473e+00 37 -5.1866584177272408e+00 5.2276382338316552e+00 -9.4551207183301855e+00 38 -1.1543907922565189e+00 -1.2217116705851163e+00 7.8535042419588308e-01 39 7.5764294215464227e+00 -4.6563914581780939e+00 -1.4559998851452969e+01 40 1.1962426631242364e+01 -6.5095442931054395e+00 -3.2593809840204688e+00 - 41 4.2161422225881529e-01 -1.4729246940628351e+00 -4.8653082075157528e+00 + 41 4.2161422225881529e-01 -1.4729246940628351e+00 -4.8653082075157510e+00 42 -1.2872945210845128e+01 -6.7834573750437004e+00 -6.3019087398505946e-01 - 43 2.5785048972790117e+00 -1.6923099420445759e+01 -1.3360019377139212e+00 - 44 1.2291023950270986e+01 -1.2191603864766963e+01 2.7304006094143318e+00 - 45 -1.2398099447130371e+00 5.0658390044921555e+00 -9.2322482748129762e+00 - 46 -1.4311260929166141e+00 -5.6910264552445193e+00 1.3277999978308035e+01 - 47 6.2057343183031417e+00 3.7310981833648289e+00 4.8205098133270914e+00 - 48 3.3963650236743295e+00 2.0831245825926228e+00 -1.2673031459768591e+00 + 43 2.5785048972790108e+00 -1.6923099420445759e+01 -1.3360019377139194e+00 + 44 1.2291023950270988e+01 -1.2191603864766963e+01 2.7304006094143323e+00 + 45 -1.2398099447130375e+00 5.0658390044921555e+00 -9.2322482748129762e+00 + 46 -1.4311260929166147e+00 -5.6910264552445158e+00 1.3277999978308035e+01 + 47 6.2057343183031435e+00 3.7310981833648289e+00 4.8205098133270914e+00 + 48 3.3963650236743295e+00 2.0831245825926228e+00 -1.2673031459768609e+00 49 -1.8543360773247199e+00 -1.3380317233196116e+01 -8.4112300152561250e+00 - 50 -1.9920275269520710e-01 7.0107508582593869e+00 -2.6708325452002271e+00 + 50 -1.9920275269520743e-01 7.0107508582593869e+00 -2.6708325452002271e+00 51 -9.3660629689657249e-01 1.1809167034995344e+01 9.8986119959157612e+00 52 1.2220659999225337e+01 -1.2024509026677922e+01 1.4962970527017067e+01 53 7.4348387428600198e+00 7.7548706874243649e+00 4.1933368746931752e+00 54 7.0105713161150085e+00 -7.7007180274608169e+00 -6.5961935960226112e+00 - 55 3.2473798770902653e+00 -9.0385173613511878e+00 -8.5508326243716120e+00 + 55 3.2473798770902649e+00 -9.0385173613511895e+00 -8.5508326243716120e+00 56 4.2348804882267466e-01 4.3169490550492495e-01 -5.3478203134943731e+00 - 57 3.5009508489349979e+00 -3.3027079935021968e+00 -2.1184761311459956e+00 + 57 3.5009508489349974e+00 -3.3027079935021968e+00 -2.1184761311459956e+00 58 9.2468424036384231e+00 -4.5181490794556876e+00 2.4559890235342761e+00 - 59 9.9448793924013952e+00 4.5973129034833260e+00 -2.2322113512955504e+00 + 59 9.9448793924013952e+00 4.5973129034833260e+00 -2.2322113512955495e+00 60 -3.6986806985028280e+00 -1.7543528229443428e+01 -1.0133821358926038e+01 61 -2.2233420196353229e+00 6.0781304306653574e+00 -1.8495331839082056e+00 - 62 -1.2719363808848012e+01 8.6073749589883608e+00 -4.9797073704539283e+00 - 63 7.9457470990016770e+00 -9.7673000016796276e+00 -4.3317841246475552e-01 + 62 -1.2719363808848012e+01 8.6073749589883626e+00 -4.9797073704539283e+00 + 63 7.9457470990016770e+00 -9.7673000016796294e+00 -4.3317841246475552e-01 64 9.3812874011747454e+00 7.3062141638106093e+00 2.1744814847410481e+01 -run_vdwl: 310.495392494539 +run_vdwl: 310.49539249453915 run_coul: 0 run_stress: ! |2- - 5.6245390685235475e+02 5.7310155923142815e+02 5.8811705982147669e+02 -1.8382792415481248e+01 1.3530908723557451e+02 6.7996805811527254e+00 + 5.6245390685235475e+02 5.7310155923142804e+02 5.8811705982147669e+02 -1.8382792415481305e+01 1.3530908723557459e+02 6.7996805811526686e+00 run_forces: ! |2 1 -1.7474911328125362e+00 9.6453508706584969e+00 5.8264070485591564e+00 - 2 -8.4157283593600489e+00 1.6574874271599898e+00 -5.8310589262897814e+00 - 3 1.2088949261773574e+00 2.4669650164003505e+00 -4.1375090165872641e-01 + 2 -8.4157283593600489e+00 1.6574874271599893e+00 -5.8310589262897814e+00 + 3 1.2088949261773569e+00 2.4669650164003514e+00 -4.1375090165872641e-01 4 -5.4649039359012761e+00 8.6435152499830856e+00 3.4462094837625115e+00 5 -5.4958328716797862e+00 -3.8484174335646353e+00 -1.8816778997456991e+00 - 6 1.9551787223560284e+00 7.7494231202147503e+00 2.2973472684776728e+00 + 6 1.9551787223560284e+00 7.7494231202147512e+00 2.2973472684776719e+00 7 -1.4123397167898091e+00 -4.4576559389423105e+00 5.1606908467828738e+00 8 1.3003903361118314e+00 1.1090418970773539e+00 -2.4122402377787160e+00 - 9 1.7752795626830657e+00 -5.9789440759859360e+00 -8.9434548975396595e+00 + 9 1.7752795626830644e+00 -5.9789440759859351e+00 -8.9434548975396595e+00 10 -1.7012447055310522e+00 -1.9935230569531357e+00 -6.6673307006625988e+00 - 11 9.2689566064779427e+00 -9.5287746372607316e+00 5.4104731087638704e+00 + 11 9.2689566064779445e+00 -9.5287746372607316e+00 5.4104731087638704e+00 12 -1.8405278855921495e+01 -9.0991584859228194e+00 -6.8488708319775853e+00 13 -1.2996763830273808e+00 1.6069530823653931e+01 -2.2707313142490793e+00 14 -5.1882033738262070e+00 7.8832636277485548e+00 2.7916487158318102e+00 15 -1.1433449800945827e+01 1.2015094164432849e+01 -7.5825275115016781e+00 - 16 4.9454676036434462e+00 -7.8102971145205025e-01 1.5266194219606220e+01 + 16 4.9454676036434462e+00 -7.8102971145204936e-01 1.5266194219606220e+01 17 3.0052148409052588e+00 1.0222703724442866e+01 -1.3093555057589381e+01 - 18 1.0836570454713836e+00 3.9100837051064552e+00 9.7948718675854156e+00 - 19 -4.2707464401127355e+00 -3.2934173316232527e+00 -1.1211010156027728e+00 - 20 -2.0392897715847305e+01 1.3054265260795233e+00 1.1968830911637141e+00 - 21 7.9027972563135283e+00 2.9933448022464120e+00 -1.0141811195436880e+01 - 22 -1.6575655480795024e+01 7.3026015885081472e+00 -1.1453084247555879e+01 - 23 3.1438035132341287e+00 9.0208182590437627e+00 7.4001520562013852e+00 - 24 3.8345333002034385e+00 3.8688922268567087e+00 8.2635479168723016e+00 - 25 2.6893003750410522e+00 1.3495734265712933e-01 2.6770556576379549e+00 - 26 -2.5895248886874898e+00 -1.4293305889359713e+00 3.8291245405081260e+00 - 27 5.5060054332311656e+00 -4.1092061919393136e-01 5.6759895801356688e+00 - 28 2.1307408306936098e+00 2.6175526554889608e+00 1.2958660769748445e+01 - 29 -9.3633952447569087e+00 8.2665579439215930e-01 -3.4012747321257448e+00 - 30 -6.4533544693943297e+00 3.8387646522939547e+00 -2.0200114390690862e+00 - 31 -4.5312579127038672e+00 2.9434281499085380e+00 -2.2589125870011584e+00 - 32 -1.1081437585586908e+01 3.5221507626974347e-01 1.7034641632139044e-01 - 33 1.1876109082707279e+01 -4.8655564590595244e+00 8.4901635945810785e+00 - 34 1.9834861495951994e-01 -9.7867922827610787e-01 1.7689988369185765e+00 - 35 2.8755972285806117e+00 -9.4201232104253185e-01 8.1427329437299605e+00 - 36 -1.7696676342095063e-01 -6.2050030582426956e+00 -1.2610314329006926e+00 - 37 -5.1523185432926066e+00 5.1647495629610471e+00 -9.4596116018450456e+00 + 18 1.0836570454713836e+00 3.9100837051064552e+00 9.7948718675854174e+00 + 19 -4.2707464401127364e+00 -3.2934173316232531e+00 -1.1211010156027728e+00 + 20 -2.0392897715847305e+01 1.3054265260795226e+00 1.1968830911637154e+00 + 21 7.9027972563135291e+00 2.9933448022464120e+00 -1.0141811195436883e+01 + 22 -1.6575655480795024e+01 7.3026015885081481e+00 -1.1453084247555879e+01 + 23 3.1438035132341287e+00 9.0208182590437627e+00 7.4001520562013834e+00 + 24 3.8345333002034385e+00 3.8688922268567070e+00 8.2635479168722998e+00 + 25 2.6893003750410518e+00 1.3495734265712866e-01 2.6770556576379549e+00 + 26 -2.5895248886874911e+00 -1.4293305889359713e+00 3.8291245405081269e+00 + 27 5.5060054332311656e+00 -4.1092061919393247e-01 5.6759895801356670e+00 + 28 2.1307408306936089e+00 2.6175526554889608e+00 1.2958660769748445e+01 + 29 -9.3633952447569051e+00 8.2665579439215930e-01 -3.4012747321257448e+00 + 30 -6.4533544693943306e+00 3.8387646522939547e+00 -2.0200114390690862e+00 + 31 -4.5312579127038664e+00 2.9434281499085362e+00 -2.2589125870011637e+00 + 32 -1.1081437585586908e+01 3.5221507626974363e-01 1.7034641632139055e-01 + 33 1.1876109082707282e+01 -4.8655564590595253e+00 8.4901635945810803e+00 + 34 1.9834861495951994e-01 -9.7867922827610787e-01 1.7689988369185774e+00 + 35 2.8755972285806135e+00 -9.4201232104253185e-01 8.1427329437299605e+00 + 36 -1.7696676342095041e-01 -6.2050030582426956e+00 -1.2610314329006931e+00 + 37 -5.1523185432926066e+00 5.1647495629610454e+00 -9.4596116018450420e+00 38 -1.0982182558331921e+00 -1.1973914898033993e+00 8.2357032136004271e-01 - 39 7.5153819798537249e+00 -4.6353686206926801e+00 -1.4561478300809743e+01 + 39 7.5153819798537249e+00 -4.6353686206926783e+00 -1.4561478300809743e+01 40 1.2018485301986439e+01 -6.4889114819969862e+00 -3.3179507002516861e+00 41 5.3906537639254815e-01 -1.3597164515464635e+00 -4.7572664553057376e+00 42 -1.2853367469523606e+01 -6.8243263403454719e+00 -7.0954222980753212e-01 - 43 2.5285681786651231e+00 -1.6882295131334587e+01 -1.3986624925913076e+00 + 43 2.5285681786651231e+00 -1.6882295131334587e+01 -1.3986624925913085e+00 44 1.2309710907856807e+01 -1.2175400941985238e+01 2.6677164515852514e+00 45 -1.3287685848983446e+00 4.9721749381786715e+00 -9.1534484515246355e+00 46 -1.4302864380872948e+00 -5.6407929749476793e+00 1.3337675572559966e+01 47 6.2320161927247124e+00 3.7264499027617033e+00 4.8100453121557578e+00 - 48 3.4140183611989756e+00 2.1640838168269934e+00 -1.2936781336070275e+00 - 49 -1.9593115645555264e+00 -1.3493991739193522e+01 -8.5023532432195843e+00 - 50 -1.6811489988289596e-01 6.9681072464297396e+00 -2.7188888125967106e+00 + 48 3.4140183611989756e+00 2.1640838168269916e+00 -1.2936781336070275e+00 + 49 -1.9593115645555264e+00 -1.3493991739193525e+01 -8.5023532432195843e+00 + 50 -1.6811489988289596e-01 6.9681072464297387e+00 -2.7188888125967106e+00 51 -1.0469270161190001e+00 1.1884430462587432e+01 9.9090099481589125e+00 52 1.2258922313552624e+01 -1.1933013587721307e+01 1.4931067313457525e+01 53 7.4707442724281288e+00 7.8432472024360917e+00 4.3940747538426654e+00 54 6.9725677862692397e+00 -7.6678940689959383e+00 -6.5509217426800008e+00 - 55 3.1754349262716173e+00 -9.0126325358351416e+00 -8.4265432974728931e+00 - 56 4.0310136221619780e-01 3.3628916654912500e-01 -5.3158911291318605e+00 + 55 3.1754349262716164e+00 -9.0126325358351416e+00 -8.4265432974728931e+00 + 56 4.0310136221619869e-01 3.3628916654912500e-01 -5.3158911291318605e+00 57 3.5009222797756716e+00 -3.3989600099867601e+00 -2.1369392158489036e+00 - 58 9.2532114410873234e+00 -4.4437952950838877e+00 2.3641140155667579e+00 + 58 9.2532114410873216e+00 -4.4437952950838877e+00 2.3641140155667575e+00 59 1.0015845748025313e+01 4.6123938091542342e+00 -2.2569748666852796e+00 60 -3.7800808893756161e+00 -1.7584651166860183e+01 -1.0234679510276377e+01 61 -2.1980530287652753e+00 6.1071583911470810e+00 -1.7912415049492632e+00 - 62 -1.2705161798029133e+01 8.5765301471185520e+00 -4.9056271749898661e+00 + 62 -1.2705161798029131e+01 8.5765301471185484e+00 -4.9056271749898626e+00 63 7.9321561763633355e+00 -9.8033451737328594e+00 -4.9729640856821433e-01 - 64 9.4795662420049851e+00 7.4221786097433808e+00 2.1786648548971794e+01 + 64 9.4795662420049851e+00 7.4221786097433808e+00 2.1786648548971787e+01 ... diff --git a/unittest/force-styles/tests/manybody-pair-mliap_so3.yaml b/unittest/force-styles/tests/manybody-pair-mliap_so3.yaml index a4efa2c6e0..ac6ae6a190 100644 --- a/unittest/force-styles/tests/manybody-pair-mliap_so3.yaml +++ b/unittest/force-styles/tests/manybody-pair-mliap_so3.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 27 May 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable -date_generated: Sun Jun 13 17:44:07 2021 +date_generated: Fri Mar 18 22:17:48 2022 epsilon: 5e-11 skip_tests: prerequisites: ! | @@ -16,142 +16,142 @@ pair_coeff: ! | * * Si Si Si Si Si Si Si Si extract: ! "" natoms: 64 -init_vdwl: -242.08541438097282 +init_vdwl: -242.08541438097276 init_coul: 0 init_stress: ! |2- - 3.5856243389095512e+00 4.3178319509851431e+00 5.1450742391421338e+00 -2.3382445177587403e+00 6.3444541794487845e+00 9.1752299438021412e-01 + 3.5856243389096378e+00 4.3178319509852185e+00 5.1450742391422120e+00 -2.3382445177587505e+00 6.3444541794487943e+00 9.1752299438020979e-01 init_forces: ! |2 - 1 -3.1962501950595823e-01 5.6761412892541685e-01 3.5767479262345103e-01 - 2 -3.4055902237163499e-01 -3.3463048947437657e-01 -2.0463281550586621e-01 - 3 1.0965493482185078e-01 1.1852119996899939e-02 -6.8690216469585785e-02 - 4 -4.2917681710400246e-01 5.8785334295730940e-01 2.6944024734509658e-01 - 5 -2.8480011500666280e-01 -2.4246371636263281e-02 2.6371880866650411e-02 - 6 1.4478663596031660e-01 5.0373076788511817e-01 2.4754536884184455e-01 - 7 -1.6648111143006419e-01 -2.1580818190690107e-01 4.5962059999665661e-01 - 8 5.1793872208577641e-03 9.8258205721181310e-02 -2.1237239804032296e-01 - 9 -2.2695156450444193e-01 -3.0886720222241792e-01 -3.3982471524904129e-01 - 10 -5.4899280049504409e-02 -2.6361580602848766e-01 -4.6186547428794356e-01 - 11 7.0822516902798582e-01 -6.5855726964151540e-01 6.8445843697172026e-01 - 12 -9.3227603274412574e-01 -9.3228190927668686e-01 -7.6938876929731748e-01 - 13 -3.0470726616180671e-01 8.0435103580644729e-01 -2.4756252000756823e-01 - 14 -2.3479043824466983e-01 7.3220393122987470e-01 -1.4939914893452921e-01 - 15 -7.1082131811158800e-01 8.5118662256190825e-01 -9.4363341636616416e-01 - 16 3.0519311772485996e-01 2.8483674897946326e-01 1.2395992551492252e+00 - 17 6.5956915047965214e-01 4.8254693346624744e-01 -5.2567354105831976e-01 - 18 -7.9689468944905612e-02 6.8196067151325090e-02 5.9874054660106668e-01 - 19 -2.3763697545215456e-01 -4.2724396450632990e-01 -1.8684043081463819e-01 - 20 -9.7721019192374103e-01 1.9998108603209278e-01 8.6010353204828152e-02 - 21 2.2013361219973313e-01 -1.2294990669541571e-01 -2.6697320196243068e-01 - 22 -1.2285340017853370e+00 1.1690349275168264e+00 -1.4237226265347376e+00 - 23 3.8898630617701757e-01 4.6455023282884689e-01 3.3423521635638376e-01 - 24 3.8226040090622126e-01 2.9557989393434092e-01 5.5205109933714203e-01 - 25 9.3521601977790650e-02 -1.6073416835582686e-02 1.3983336197196455e-01 - 26 7.0434112329697054e-02 -2.1616954791777516e-02 1.1838121146432676e-01 - 27 4.3053526631612626e-01 -1.8120315965038483e-01 3.2118273346822135e-01 - 28 -8.5222587593901430e-02 2.5053534569095887e-01 8.4998194456908627e-01 - 29 -5.2824806036659966e-01 3.7688334350435798e-01 -2.9342945950696531e-01 - 30 -2.0630152439038446e-01 1.1742029257880499e-01 -1.5472597043542272e-01 - 31 -1.5461602575510483e-01 1.7652146539226263e-01 -3.9084496119253777e-02 - 32 -4.5837827660003577e-01 2.0385249301614106e-01 -1.2398969536978524e-01 - 33 7.9471459720084048e-01 -6.9190694940632047e-01 8.3162926736539400e-01 - 34 1.4890352006720189e-01 1.2051093068835445e-02 -1.4903892467477795e-02 - 35 2.2834220821773751e-01 -1.2404653069908662e-01 4.7043869369199348e-01 - 36 -6.0161946119659152e-02 -3.5011696674253306e-01 6.9827025926206300e-03 - 37 -3.5755783353896464e-01 3.4293192644746495e-01 -3.3035510255109329e-01 - 38 -1.5264515528290096e-01 -1.8578933375676593e-02 7.6231207427680664e-02 - 39 5.0950710874938010e-01 -4.8343099863687994e-01 -5.9731921195378934e-01 - 40 8.2087228191924311e-01 -5.8338727466140039e-01 -5.3577051746179449e-01 - 41 -2.5932061784047694e-02 -1.2942331539744090e-01 -1.1369207362951550e-01 - 42 -5.0930140389860812e-01 -2.4266141136226554e-01 -2.0947953649294865e-01 - 43 8.5673434249355668e-02 -8.4351858143712588e-01 1.2348559495353699e-01 - 44 5.2887927118716704e-01 -5.4060461346991406e-01 6.0878058062650675e-01 - 45 -4.5189088028948604e-01 3.5848279996786603e-01 -6.0248253431181398e-01 - 46 -3.3641633018653277e-01 -2.9706533294242637e-01 9.5865696396805256e-01 - 47 4.4265361896830380e-01 3.4098141839855145e-01 2.7768582076458542e-01 - 48 1.5550373308714810e-01 -8.0490292537712296e-02 -1.2140381247151916e-02 - 49 -6.4126972948425498e-01 -8.1277048989772516e-01 -6.6088623870263008e-01 - 50 6.9590856991288405e-02 3.2650008138931746e-01 -1.2981864462879661e-01 - 51 -5.9079732678911834e-01 5.4485696856005095e-01 6.8471642407028899e-01 - 52 1.2500943393870998e+00 -1.2483610604845263e+00 1.3764499435893642e+00 - 53 7.5044082180665861e-01 7.1006339405720620e-01 6.8752933088770685e-01 - 54 5.7790768581732632e-01 -6.0482253610873882e-01 -5.7995317962912973e-01 - 55 4.4776151869164765e-01 -5.9219393004341692e-01 -6.9398818388834249e-01 - 56 -7.4276087479339600e-02 3.8502591921562142e-02 -3.1482369726424059e-01 - 57 -4.9028410280524036e-02 -5.8115359646338252e-02 -2.6774949685019013e-02 - 58 3.7437462851140180e-01 -2.3858950328415252e-01 2.7176318794239890e-01 - 59 7.5049664891509604e-01 6.0003203348980849e-01 -6.0606097897888678e-01 - 60 -7.8027828178258207e-01 -1.0282777251742856e+00 -7.6957323203237027e-01 - 61 -2.0704735890388715e-01 2.1426153130500308e-01 -1.7757121507272916e-01 - 62 -4.9195674075326684e-01 5.5632927867395221e-01 -4.8501482619942371e-01 - 63 4.0392077364288381e-01 -6.5683525718558333e-01 -3.5450072515244213e-01 - 64 8.3136790206790612e-01 8.4030959270424599e-01 9.6744125066169429e-01 -run_vdwl: -242.07509367477505 + 1 -3.1962501950595745e-01 5.6761412892541896e-01 3.5767479262345070e-01 + 2 -3.4055902237163510e-01 -3.3463048947437363e-01 -2.0463281550586557e-01 + 3 1.0965493482185182e-01 1.1852119996899300e-02 -6.8690216469586271e-02 + 4 -4.2917681710400252e-01 5.8785334295731062e-01 2.6944024734509581e-01 + 5 -2.8480011500666214e-01 -2.4246371636264474e-02 2.6371880866650578e-02 + 6 1.4478663596031566e-01 5.0373076788511728e-01 2.4754536884184283e-01 + 7 -1.6648111143006686e-01 -2.1580818190690126e-01 4.5962059999665689e-01 + 8 5.1793872208572879e-03 9.8258205721180533e-02 -2.1237239804032371e-01 + 9 -2.2695156450444268e-01 -3.0886720222241770e-01 -3.3982471524904295e-01 + 10 -5.4899280049503583e-02 -2.6361580602848711e-01 -4.6186547428794306e-01 + 11 7.0822516902798649e-01 -6.5855726964151629e-01 6.8445843697172160e-01 + 12 -9.3227603274412518e-01 -9.3228190927668808e-01 -7.6938876929731692e-01 + 13 -3.0470726616180571e-01 8.0435103580644884e-01 -2.4756252000756887e-01 + 14 -2.3479043824467183e-01 7.3220393122987582e-01 -1.4939914893453093e-01 + 15 -7.1082131811158811e-01 8.5118662256190802e-01 -9.4363341636616638e-01 + 16 3.0519311772485724e-01 2.8483674897946265e-01 1.2395992551492261e+00 + 17 6.5956915047965392e-01 4.8254693346624711e-01 -5.2567354105832109e-01 + 18 -7.9689468944904862e-02 6.8196067151325229e-02 5.9874054660106679e-01 + 19 -2.3763697545215626e-01 -4.2724396450632979e-01 -1.8684043081463975e-01 + 20 -9.7721019192374270e-01 1.9998108603209538e-01 8.6010353204829068e-02 + 21 2.2013361219973379e-01 -1.2294990669541585e-01 -2.6697320196242919e-01 + 22 -1.2285340017853381e+00 1.1690349275168281e+00 -1.4237226265347394e+00 + 23 3.8898630617701818e-01 4.6455023282884916e-01 3.3423521635638420e-01 + 24 3.8226040090621888e-01 2.9557989393434225e-01 5.5205109933714380e-01 + 25 9.3521601977791330e-02 -1.6073416835582929e-02 1.3983336197196550e-01 + 26 7.0434112329697082e-02 -2.1616954791777835e-02 1.1838121146432877e-01 + 27 4.3053526631612715e-01 -1.8120315965038719e-01 3.2118273346822135e-01 + 28 -8.5222587593902291e-02 2.5053534569095814e-01 8.4998194456909026e-01 + 29 -5.2824806036659899e-01 3.7688334350435859e-01 -2.9342945950696681e-01 + 30 -2.0630152439038341e-01 1.1742029257880424e-01 -1.5472597043542391e-01 + 31 -1.5461602575510536e-01 1.7652146539226327e-01 -3.9084496119252798e-02 + 32 -4.5837827660003816e-01 2.0385249301614072e-01 -1.2398969536978427e-01 + 33 7.9471459720084336e-01 -6.9190694940632302e-01 8.3162926736539533e-01 + 34 1.4890352006720306e-01 1.2051093068836203e-02 -1.4903892467476920e-02 + 35 2.2834220821773663e-01 -1.2404653069908561e-01 4.7043869369199148e-01 + 36 -6.0161946119657847e-02 -3.5011696674253556e-01 6.9827025926195822e-03 + 37 -3.5755783353896448e-01 3.4293192644746501e-01 -3.3035510255109213e-01 + 38 -1.5264515528290129e-01 -1.8578933375677370e-02 7.6231207427680761e-02 + 39 5.0950710874938110e-01 -4.8343099863687888e-01 -5.9731921195378956e-01 + 40 8.2087228191924577e-01 -5.8338727466140305e-01 -5.3577051746179460e-01 + 41 -2.5932061784049280e-02 -1.2942331539744051e-01 -1.1369207362951533e-01 + 42 -5.0930140389860967e-01 -2.4266141136226571e-01 -2.0947953649294865e-01 + 43 8.5673434249356473e-02 -8.4351858143712910e-01 1.2348559495353806e-01 + 44 5.2887927118716749e-01 -5.4060461346991417e-01 6.0878058062650953e-01 + 45 -4.5189088028948637e-01 3.5848279996786864e-01 -6.0248253431181720e-01 + 46 -3.3641633018653183e-01 -2.9706533294242571e-01 9.5865696396805222e-01 + 47 4.4265361896830457e-01 3.4098141839855339e-01 2.7768582076458642e-01 + 48 1.5550373308714935e-01 -8.0490292537712962e-02 -1.2140381247152981e-02 + 49 -6.4126972948425676e-01 -8.1277048989772549e-01 -6.6088623870262919e-01 + 50 6.9590856991288932e-02 3.2650008138931824e-01 -1.2981864462879678e-01 + 51 -5.9079732678912000e-01 5.4485696856005439e-01 6.8471642407029165e-01 + 52 1.2500943393871011e+00 -1.2483610604845277e+00 1.3764499435893649e+00 + 53 7.5044082180665994e-01 7.1006339405720553e-01 6.8752933088770785e-01 + 54 5.7790768581732621e-01 -6.0482253610874126e-01 -5.7995317962912907e-01 + 55 4.4776151869164788e-01 -5.9219393004341947e-01 -6.9398818388834538e-01 + 56 -7.4276087479339573e-02 3.8502591921561406e-02 -3.1482369726424059e-01 + 57 -4.9028410280523176e-02 -5.8115359646340077e-02 -2.6774949685020290e-02 + 58 3.7437462851140252e-01 -2.3858950328415177e-01 2.7176318794239945e-01 + 59 7.5049664891509349e-01 6.0003203348980716e-01 -6.0606097897888567e-01 + 60 -7.8027828178258452e-01 -1.0282777251742881e+00 -7.6957323203237260e-01 + 61 -2.0704735890388526e-01 2.1426153130500483e-01 -1.7757121507272910e-01 + 62 -4.9195674075326978e-01 5.5632927867395332e-01 -4.8501482619942621e-01 + 63 4.0392077364288620e-01 -6.5683525718558311e-01 -3.5450072515244402e-01 + 64 8.3136790206790823e-01 8.4030959270424799e-01 9.6744125066169728e-01 +run_vdwl: -242.0750936747751 run_coul: 0 run_stress: ! |2- - 3.6067334447532695e+00 4.3471333638967478e+00 5.1979080340147519e+00 -2.2917015647694656e+00 6.3545457412614894e+00 1.0105656026958723e+00 + 3.6067334447533499e+00 4.3471333638968126e+00 5.1979080340148149e+00 -2.2917015647694550e+00 6.3545457412615010e+00 1.0105656026958680e+00 run_forces: ! |2 - 1 -3.2099025878012155e-01 5.6621647667818076e-01 3.5950167010603051e-01 - 2 -3.4509776918969848e-01 -3.3867254821455528e-01 -2.0920538372184505e-01 - 3 1.0531155735451671e-01 1.2386817647918189e-02 -6.5592214009213612e-02 - 4 -4.2518309605527171e-01 5.8922044317041156e-01 2.6563467306378569e-01 - 5 -2.8801072479776163e-01 -2.5766299821446889e-02 2.9057158897915637e-02 - 6 1.5542359530932462e-01 5.0618090170742924e-01 2.5705162916056401e-01 - 7 -1.6155636197369327e-01 -2.0933544079115984e-01 4.5528515616655318e-01 - 8 2.4173198798722703e-03 9.8119054544594395e-02 -2.1160344210292820e-01 - 9 -2.3309913937974988e-01 -3.1480594421707164e-01 -3.4564398106874977e-01 - 10 -5.4522048631510535e-02 -2.6706654804162977e-01 -4.5324758936337878e-01 - 11 7.0091421529942932e-01 -6.5161362710989634e-01 6.7911091706071092e-01 - 12 -9.3013382458275318e-01 -9.2865203992752920e-01 -7.6857777606975730e-01 - 13 -2.9150015714972832e-01 8.0193668506020310e-01 -2.3445660406176830e-01 - 14 -2.3931752715567098e-01 7.3165656442486871e-01 -1.5460079660908072e-01 - 15 -7.0949250316968981e-01 8.4895481344920531e-01 -9.4171558147000023e-01 - 16 3.0631254529841845e-01 2.8452527197212563e-01 1.2374792465145266e+00 - 17 6.5855968811869425e-01 4.8254937919423335e-01 -5.2248413587752107e-01 - 18 -8.7481644703575029e-02 7.6634049591861181e-02 6.0224665003051581e-01 - 19 -2.4288814928950306e-01 -4.3211093792565469e-01 -1.9384450640073986e-01 - 20 -9.7426378856830720e-01 1.9288999988815433e-01 8.0604056667934840e-02 - 21 2.2424888386015288e-01 -1.3293815632038816e-01 -2.7377822690501097e-01 - 22 -1.2323644574571764e+00 1.1752131626398818e+00 -1.4294587388733917e+00 - 23 3.9308015126728924e-01 4.6878338812272585e-01 3.4083333751850131e-01 - 24 3.8760532137362280e-01 2.9510552152958136e-01 5.5074781186708821e-01 - 25 9.3396150962252164e-02 -1.5317581194901989e-02 1.3747727146599498e-01 - 26 6.9265560054146760e-02 -2.0314915486256999e-02 1.1931386929585183e-01 - 27 4.3415121072825247e-01 -1.8687603495448388e-01 3.2487067605082509e-01 - 28 -9.1871593618403344e-02 2.5620554100946658e-01 8.5286477941973227e-01 - 29 -5.3071912525035825e-01 3.8001024033499603e-01 -2.9595616725714385e-01 - 30 -2.0363608471489461e-01 1.1467846274268546e-01 -1.5423466174347741e-01 - 31 -1.5347742017717006e-01 1.7737371992520326e-01 -3.9100161388642633e-02 - 32 -4.5523972305123062e-01 2.0385758964290804e-01 -1.2369373913464421e-01 - 33 7.9087458324830917e-01 -6.9245678150703793e-01 8.3099119891416617e-01 - 34 1.4802038008409366e-01 1.1906014937963626e-02 -1.4079337228309469e-02 - 35 2.2885578071414028e-01 -1.2375478283251561e-01 4.7035167000612227e-01 - 36 -6.6712338981015251e-02 -3.4784959749591643e-01 -8.2434566151845740e-04 - 37 -3.5559876201572144e-01 3.4127522791063586e-01 -3.3119493923999893e-01 - 38 -1.5190134438030195e-01 -1.7408563012483787e-02 7.7163920440187175e-02 - 39 5.0793157466484662e-01 -4.8015243788901102e-01 -5.9618064615637467e-01 - 40 8.3101665635822208e-01 -5.9096688016268673e-01 -5.4151897902038382e-01 - 41 -2.2638462355541608e-02 -1.2687248931889569e-01 -1.1170657237550335e-01 - 42 -5.1187405127087360e-01 -2.4900529137919386e-01 -2.1379948491741790e-01 - 43 8.1549992649728023e-02 -8.4270445844787201e-01 1.1940335582923872e-01 - 44 5.2979201238463836e-01 -5.4163495044340293e-01 6.0904604522603012e-01 - 45 -4.5349498979959058e-01 3.5543802758009235e-01 -6.0071827959729118e-01 - 46 -3.3812369451494262e-01 -2.9608077672407218e-01 9.6601486219971566e-01 - 47 4.4432776315481021e-01 3.4106617818250651e-01 2.8018780396259058e-01 - 48 1.5373759328615888e-01 -7.7559745424578372e-02 -1.1738256128522504e-02 - 49 -6.5552433924923514e-01 -8.2962215224843339e-01 -6.8041757200528219e-01 - 50 7.2009338943382531e-02 3.2345724726665581e-01 -1.3328856788416371e-01 - 51 -6.0193053801934937e-01 5.5621389434911084e-01 6.9122096987900861e-01 - 52 1.2542223217674440e+00 -1.2515674646711927e+00 1.3812983341667304e+00 - 53 7.6517171556659869e-01 7.2661791257033292e-01 7.1045870262624977e-01 - 54 5.7763188954157396e-01 -6.0585750515061210e-01 -5.7983327790970884e-01 - 55 4.4244372609738386e-01 -5.8905832551910409e-01 -6.8763885072819386e-01 - 56 -7.2489818842452189e-02 3.3901184340476273e-02 -3.1255337552350843e-01 - 57 -5.0302123192962747e-02 -6.1405545784893767e-02 -2.7597409034218284e-02 - 58 3.7360346515990828e-01 -2.3419685074330851e-01 2.6752706940536103e-01 - 59 7.5732954986333467e-01 6.0665518776115368e-01 -6.0815520107330145e-01 - 60 -7.9635276290536017e-01 -1.0415254996798184e+00 -7.8732107265558360e-01 - 61 -2.0591458098965063e-01 2.1482058504135643e-01 -1.7680341681360623e-01 - 62 -4.8938738154162575e-01 5.5387119501671334e-01 -4.8275712266641585e-01 - 63 4.0721801666660368e-01 -6.6333065414791259e-01 -3.6112779273985718e-01 - 64 8.4666802609774161e-01 8.5876008835428574e-01 9.8070536947452069e-01 + 1 -3.2099025878012277e-01 5.6621647667818142e-01 3.5950167010603240e-01 + 2 -3.4509776918969914e-01 -3.3867254821455467e-01 -2.0920538372184497e-01 + 3 1.0531155735451647e-01 1.2386817647918933e-02 -6.5592214009213751e-02 + 4 -4.2518309605527188e-01 5.8922044317041533e-01 2.6563467306378491e-01 + 5 -2.8801072479776246e-01 -2.5766299821449692e-02 2.9057158897916137e-02 + 6 1.5542359530932601e-01 5.0618090170742891e-01 2.5705162916056484e-01 + 7 -1.6155636197369519e-01 -2.0933544079116048e-01 4.5528515616655452e-01 + 8 2.4173198798739920e-03 9.8119054544594297e-02 -2.1160344210292870e-01 + 9 -2.3309913937974944e-01 -3.1480594421707114e-01 -3.4564398106874994e-01 + 10 -5.4522048631510958e-02 -2.6706654804162783e-01 -4.5324758936337933e-01 + 11 7.0091421529942954e-01 -6.5161362710989601e-01 6.7911091706071081e-01 + 12 -9.3013382458275362e-01 -9.2865203992752809e-01 -7.6857777606975919e-01 + 13 -2.9150015714972871e-01 8.0193668506020266e-01 -2.3445660406176802e-01 + 14 -2.3931752715567073e-01 7.3165656442486737e-01 -1.5460079660908072e-01 + 15 -7.0949250316969203e-01 8.4895481344920731e-01 -9.4171558147000123e-01 + 16 3.0631254529841834e-01 2.8452527197212474e-01 1.2374792465145270e+00 + 17 6.5855968811869481e-01 4.8254937919423396e-01 -5.2248413587752196e-01 + 18 -8.7481644703574890e-02 7.6634049591860653e-02 6.0224665003051814e-01 + 19 -2.4288814928950250e-01 -4.3211093792565486e-01 -1.9384450640073872e-01 + 20 -9.7426378856830931e-01 1.9288999988815450e-01 8.0604056667934160e-02 + 21 2.2424888386015274e-01 -1.3293815632038772e-01 -2.7377822690501197e-01 + 22 -1.2323644574571766e+00 1.1752131626398816e+00 -1.4294587388733897e+00 + 23 3.9308015126729029e-01 4.6878338812272569e-01 3.4083333751850153e-01 + 24 3.8760532137362380e-01 2.9510552152958086e-01 5.5074781186708921e-01 + 25 9.3396150962251498e-02 -1.5317581194904489e-02 1.3747727146599448e-01 + 26 6.9265560054145428e-02 -2.0314915486257933e-02 1.1931386929585105e-01 + 27 4.3415121072825447e-01 -1.8687603495448551e-01 3.2487067605082609e-01 + 28 -9.1871593618401193e-02 2.5620554100946658e-01 8.5286477941973338e-01 + 29 -5.3071912525035958e-01 3.8001024033499897e-01 -2.9595616725714363e-01 + 30 -2.0363608471489492e-01 1.1467846274268570e-01 -1.5423466174347783e-01 + 31 -1.5347742017717059e-01 1.7737371992520434e-01 -3.9100161388641905e-02 + 32 -4.5523972305123062e-01 2.0385758964290843e-01 -1.2369373913464619e-01 + 33 7.9087458324831295e-01 -6.9245678150703971e-01 8.3099119891416784e-01 + 34 1.4802038008409338e-01 1.1906014937961562e-02 -1.4079337228307637e-02 + 35 2.2885578071414056e-01 -1.2375478283251558e-01 4.7035167000612421e-01 + 36 -6.6712338981015695e-02 -3.4784959749591648e-01 -8.2434566151896437e-04 + 37 -3.5559876201572194e-01 3.4127522791063630e-01 -3.3119493924000043e-01 + 38 -1.5190134438030262e-01 -1.7408563012486084e-02 7.7163920440188855e-02 + 39 5.0793157466484551e-01 -4.8015243788901246e-01 -5.9618064615637500e-01 + 40 8.3101665635822353e-01 -5.9096688016268839e-01 -5.4151897902038637e-01 + 41 -2.2638462355540987e-02 -1.2687248931889492e-01 -1.1170657237550155e-01 + 42 -5.1187405127087449e-01 -2.4900529137919492e-01 -2.1379948491742093e-01 + 43 8.1549992649728342e-02 -8.4270445844787389e-01 1.1940335582924036e-01 + 44 5.2979201238463891e-01 -5.4163495044340348e-01 6.0904604522602879e-01 + 45 -4.5349498979959252e-01 3.5543802758009252e-01 -6.0071827959729251e-01 + 46 -3.3812369451494456e-01 -2.9608077672407285e-01 9.6601486219972088e-01 + 47 4.4432776315481209e-01 3.4106617818250795e-01 2.8018780396259013e-01 + 48 1.5373759328615827e-01 -7.7559745424576582e-02 -1.1738256128523430e-02 + 49 -6.5552433924923603e-01 -8.2962215224843494e-01 -6.8041757200528441e-01 + 50 7.2009338943382128e-02 3.2345724726665437e-01 -1.3328856788416377e-01 + 51 -6.0193053801934815e-01 5.5621389434911306e-01 6.9122096987901005e-01 + 52 1.2542223217674426e+00 -1.2515674646711921e+00 1.3812983341667293e+00 + 53 7.6517171556659924e-01 7.2661791257033514e-01 7.1045870262625055e-01 + 54 5.7763188954157529e-01 -6.0585750515061187e-01 -5.7983327790971062e-01 + 55 4.4244372609738447e-01 -5.8905832551910486e-01 -6.8763885072819497e-01 + 56 -7.2489818842450954e-02 3.3901184340475343e-02 -3.1255337552350881e-01 + 57 -5.0302123192966106e-02 -6.1405545784895529e-02 -2.7597409034219263e-02 + 58 3.7360346515991039e-01 -2.3419685074330873e-01 2.6752706940536053e-01 + 59 7.5732954986333800e-01 6.0665518776115301e-01 -6.0815520107330223e-01 + 60 -7.9635276290535983e-01 -1.0415254996798209e+00 -7.8732107265558349e-01 + 61 -2.0591458098964976e-01 2.1482058504136067e-01 -1.7680341681360554e-01 + 62 -4.8938738154162781e-01 5.5387119501671378e-01 -4.8275712266641829e-01 + 63 4.0721801666660451e-01 -6.6333065414791037e-01 -3.6112779273985673e-01 + 64 8.4666802609774172e-01 8.5876008835428763e-01 9.8070536947452158e-01 ... diff --git a/unittest/force-styles/tests/manybody-pair-nb3b_harmonic.yaml b/unittest/force-styles/tests/manybody-pair-nb3b_harmonic.yaml index 4701c79ad3..c39c72e7d9 100644 --- a/unittest/force-styles/tests/manybody-pair-nb3b_harmonic.yaml +++ b/unittest/force-styles/tests/manybody-pair-nb3b_harmonic.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:17 2021 +lammps_version: 17 Feb 2022 tags: unstable +date_generated: Fri Mar 18 22:17:48 2022 epsilon: 2e-12 +skip_tests: prerequisites: ! | pair nb3b/harmonic pre_commands: ! | @@ -19,7 +20,7 @@ pair_coeff: ! | * * MOH.nb3b.harmonic M M O O H H H H extract: ! "" natoms: 64 -init_vdwl: 2654.82155652424 +init_vdwl: 2654.8215565242403 init_coul: 0 init_stress: ! |- -5.1017158429026651e+01 -1.3611903256981696e+01 6.4629061686009067e+01 -8.7135857294938191e+01 -1.1070515375917164e+02 7.5452837495497633e+01 @@ -88,7 +89,7 @@ init_forces: ! |2 62 4.1476164742574909e+01 -9.7738882325904193e+00 2.2124574239200477e+01 63 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 64 0.0000000000000000e+00 0.0000000000000000e+00 0.0000000000000000e+00 -run_vdwl: 2654.82171289438 +run_vdwl: 2654.821712894376 run_coul: 0 run_stress: ! |- -5.1017319806446963e+01 -1.3611444901522319e+01 6.4628764707970163e+01 -8.7135896922470280e+01 -1.1070430113320975e+02 7.5452229912420606e+01 diff --git a/unittest/force-styles/tests/manybody-pair-pace_product.yaml b/unittest/force-styles/tests/manybody-pair-pace_product.yaml index 0911e1d81d..9aac9ddcae 100644 --- a/unittest/force-styles/tests/manybody-pair-pace_product.yaml +++ b/unittest/force-styles/tests/manybody-pair-pace_product.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Wed Apr 7 19:29:52 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:48 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair pace pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * Cu-PBE-core-rep.ace Cu Cu Cu Cu Cu Cu Cu Cu extract: ! "" natoms: 64 -init_vdwl: -161.633164433256 +init_vdwl: -161.63316443325627 init_coul: 0 init_stress: ! |2- 4.9972088100615499e+00 6.2044830913935627e+00 9.1051638867046787e+00 -3.5472278350778463e+00 1.6694265484458743e+01 1.2476127820340779e+00 @@ -83,7 +84,7 @@ init_forces: ! |2 62 -1.1637776716822190e+00 1.1834011745844724e+00 -9.3135952930487587e-01 63 9.6457625131492997e-01 -1.4202510282595555e+00 -6.5977083749846954e-01 64 1.3468893282796701e+00 1.5138254987169797e+00 2.7159451744492960e+00 -run_vdwl: -161.618480729195 +run_vdwl: -161.61848072919454 run_coul: 0 run_stress: ! |2- 4.9994648190802469e+00 6.2341889704204814e+00 9.1844870434928065e+00 -3.5139192287217877e+00 1.6660134035412678e+01 1.4298492052949148e+00 diff --git a/unittest/force-styles/tests/manybody-pair-polymorphic_sw.yaml b/unittest/force-styles/tests/manybody-pair-polymorphic_sw.yaml index 7e1e6acfd4..80d8831736 100644 --- a/unittest/force-styles/tests/manybody-pair-polymorphic_sw.yaml +++ b/unittest/force-styles/tests/manybody-pair-polymorphic_sw.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:17 2021 +lammps_version: 17 Feb 2022 tags: unstable +date_generated: Fri Mar 18 22:17:48 2022 epsilon: 2.5e-12 +skip_tests: prerequisites: ! | pair polymorphic pre_commands: ! | @@ -16,7 +17,7 @@ pair_coeff: ! | * * GaN_sw.poly Ga Ga Ga Ga N N N N extract: ! "" natoms: 64 -init_vdwl: -110.558587505304 +init_vdwl: -110.55858750530444 init_coul: 0 init_stress: ! |- -1.6871753140960841e+01 6.7120289611391286e+01 -2.6350807630371186e+01 -3.7494795095495206e+01 -3.5036126410883412e+01 3.0898629782251593e+01 @@ -85,7 +86,7 @@ init_forces: ! |2 62 8.3847363183302388e+00 -7.9441779730970898e+00 -1.9428697652986431e+00 63 -6.4026447196181824e+00 -8.9658730208109318e+00 5.5791283935903966e+00 64 -5.7668345333930739e+00 -5.3444816699294773e+00 2.4892095494490190e+00 -run_vdwl: -111.143397432489 +run_vdwl: -111.14339743248907 run_coul: 0 run_stress: ! |- -1.6884876517198332e+01 6.5112126457917583e+01 -2.6558952316833775e+01 -3.7002428812831916e+01 -3.4760986882349549e+01 3.0465464452139759e+01 diff --git a/unittest/force-styles/tests/manybody-pair-polymorphic_tersoff.yaml b/unittest/force-styles/tests/manybody-pair-polymorphic_tersoff.yaml index f5706c6dde..fa75d30266 100644 --- a/unittest/force-styles/tests/manybody-pair-polymorphic_tersoff.yaml +++ b/unittest/force-styles/tests/manybody-pair-polymorphic_tersoff.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:17 2021 +lammps_version: 17 Feb 2022 tags: unstable +date_generated: Fri Mar 18 22:17:49 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair polymorphic pre_commands: ! | @@ -16,7 +17,7 @@ pair_coeff: ! | * * GaN_tersoff.poly Ga Ga Ga Ga N N N N extract: ! "" natoms: 64 -init_vdwl: -112.241357306965 +init_vdwl: -112.24135730696504 init_coul: 0 init_stress: ! |2- 4.3249132419495197e+02 6.1806988005325991e+02 4.8708813529781338e+02 -2.2467788013860402e+02 -1.5225332287691344e+02 1.2236676585794305e+02 @@ -85,7 +86,7 @@ init_forces: ! |2 62 6.4996283247232540e+00 -7.4637247642767051e+00 -5.0174108531675454e+00 63 -5.7071873855477513e+00 -9.3348074441081295e+00 6.5081800066406998e+00 64 -4.5601626990206690e+00 -4.5257272492649570e+00 3.5749156843886922e+00 -run_vdwl: -121.544576212893 +run_vdwl: -121.54457621289319 run_coul: 0 run_stress: ! |2- 4.1813274424716730e+02 5.8447861805552952e+02 4.7956279024041038e+02 -2.1359076310114048e+02 -1.6136565007848719e+02 1.0855996460611711e+02 diff --git a/unittest/force-styles/tests/manybody-pair-rebo.yaml b/unittest/force-styles/tests/manybody-pair-rebo.yaml index bf9c43ec81..45ce7ef321 100644 --- a/unittest/force-styles/tests/manybody-pair-rebo.yaml +++ b/unittest/force-styles/tests/manybody-pair-rebo.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:18 2021 +date_generated: Fri Mar 18 22:17:49 2022 epsilon: 1e-07 skip_tests: intel prerequisites: ! | @@ -16,7 +16,7 @@ pair_coeff: ! | * * CH.rebo C H extract: ! "" natoms: 48 -init_vdwl: -184.39204996406 +init_vdwl: -184.3920499640596 init_coul: 0 init_stress: ! |2- 3.3789835306128507e-01 2.9478711461049310e+00 2.4743519134193620e-01 5.2979459234337423e-01 5.3569422394689620e-02 -6.3505274336891904e-03 @@ -69,7 +69,7 @@ init_forces: ! |2 46 1.0998928173472683e-01 -1.5086188432942196e-01 1.6829691363685131e-01 47 -7.6878894879590064e-04 5.5783704671116340e-02 -2.0995953677601979e-02 48 5.1056316250091771e-02 8.5470091106617740e-02 6.8395639456075963e-02 -run_vdwl: -184.41850184596 +run_vdwl: -184.41850184595964 run_coul: 0 run_stress: ! |- -6.3796800430503467e-02 2.0494433580340701e+00 -1.6992433003987237e-01 2.4088644686118060e-01 -2.1497443283592180e-01 -1.0587984597558675e-01 diff --git a/unittest/force-styles/tests/manybody-pair-snap.yaml b/unittest/force-styles/tests/manybody-pair-snap.yaml index 378229072e..8c0845586d 100644 --- a/unittest/force-styles/tests/manybody-pair-snap.yaml +++ b/unittest/force-styles/tests/manybody-pair-snap.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:18 2021 +date_generated: Fri Mar 18 22:17:49 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair snap pair zbl @@ -18,10 +19,10 @@ pair_coeff: ! | extract: ! | scale 2 natoms: 64 -init_vdwl: -473.569864629026 +init_vdwl: -473.56986462902603 init_coul: 0 init_stress: ! |2- - 3.9989504688551500e+02 4.0778136516736993e+02 4.3596322435184823e+02 -2.5242497284339720e+01 1.2811620806363655e+02 2.8644673361821793e+00 + 3.9989504688551500e+02 4.0778136516736993e+02 4.3596322435184845e+02 -2.5242497284339720e+01 1.2811620806363655e+02 2.8644673361821793e+00 init_forces: ! |2 1 -3.7538180163781538e+00 8.8612947043788708e+00 6.7712977816732263e+00 2 -7.6696525239232596e+00 -3.7674335682223203e-01 -5.7958054718422760e+00 @@ -29,7 +30,7 @@ init_forces: ! |2 4 -4.7103509354198474e+00 9.2783458784125941e+00 4.3108702582741429e+00 5 -2.0331946400488916e+00 -2.9593716047756180e+00 -1.6136351145373196e+00 6 1.8086748683348572e+00 4.6479727629048675e+00 3.0425695895915184e-01 - 7 -3.0573043543220644e+00 -4.0575899915120264e+00 1.5283788878527900e+00 + 7 -3.0573043543220644e+00 -4.0575899915120281e+00 1.5283788878527900e+00 8 2.7148403621334427e-01 1.3063473238306007e+00 -1.1268098385676173e+00 9 5.2043326273129953e-01 -2.9340446386399996e+00 -7.6461969078455834e+00 10 -6.2786875145099508e-01 5.6606570005199308e-02 -5.3746300485699576e+00 @@ -65,11 +66,11 @@ init_forces: ! |2 40 9.5193696695210637e+00 -7.0213638399035432e+00 -1.5692669012530696e+00 41 2.4000089474497699e-01 1.0045144396502914e+00 -2.3032449685213630e+00 42 -9.4741999244791426e+00 -6.3134658287662750e+00 -3.6928028439517893e+00 - 43 2.7218639962411728e-01 -1.3813634477251096e+01 5.5147832931992291e-01 + 43 2.7218639962411773e-01 -1.3813634477251096e+01 5.5147832931992202e-01 44 8.0196107396135208e+00 -8.1793730426384545e+00 3.5131695854462590e+00 45 -1.8910274064701343e-01 3.9137627573846219e+00 -7.4450993876429399e+00 46 -3.5282857552811575e+00 -5.1713579630178099e+00 1.2477491203990510e+01 - 47 5.1131478665605341e+00 2.3800985688973459e+00 5.1348001359881970e+00 + 47 5.1131478665605341e+00 2.3800985688973468e+00 5.1348001359881987e+00 48 2.1755560727357057e+00 2.9996491762493216e+00 -9.9575511910097214e-01 49 -2.3978299788760209e+00 -1.2283692236805253e+01 -8.3755937565454435e+00 50 3.6161933080447888e+00 5.6291551969069182e+00 -6.9709721613230968e-01 @@ -87,16 +88,16 @@ init_forces: ! |2 62 -6.2693637951458694e+00 5.5593866650560679e+00 -4.0417158962655781e+00 63 5.8570431431678962e+00 -6.2896068000076317e+00 -3.8788666930728688e+00 64 7.5837965251215369e+00 7.5954689486766096e+00 1.6804021764142011e+01 -run_vdwl: -473.666568306022 +run_vdwl: -473.66656830602244 run_coul: 0 run_stress: ! |2- - 3.9951053758431499e+02 4.0757094669497650e+02 4.3599209936956868e+02 -2.5012844114476398e+01 1.2751742945242590e+02 3.9821818278564844e+00 + 3.9951053758431510e+02 4.0757094669497650e+02 4.3599209936956890e+02 -2.5012844114476398e+01 1.2751742945242590e+02 3.9821818278567118e+00 run_forces: ! |2 1 -3.7832595710893155e+00 8.8212124103655292e+00 6.7792549500694745e+00 2 -7.6693903913873163e+00 -4.4331479267505980e-01 -5.8319844453604492e+00 3 -3.5652510811236748e-01 -1.2843261396638010e+00 2.3164336943032460e+00 4 -4.6688281400123417e+00 9.2569804046918627e+00 4.2532553525093961e+00 - 5 -2.0698377683688305e+00 -3.0068940885360655e+00 -1.5557558367041349e+00 + 5 -2.0698377683688309e+00 -3.0068940885360655e+00 -1.5557558367041349e+00 6 1.9121936983089021e+00 4.6485144224151016e+00 3.8302570899366983e-01 7 -3.0000564919294019e+00 -3.9598169423628935e+00 1.4730795882443171e+00 8 2.2616298546615310e-01 1.3160780554993146e+00 -1.1365737437456360e+00 @@ -127,18 +128,18 @@ run_forces: ! |2 33 1.0688722918141039e+01 -5.7920158261872583e+00 9.6923706747923646e+00 34 -1.3525464452783258e+00 -1.0575652830645854e-01 1.6380965403350563e+00 35 2.5193832475087721e+00 -2.2598987796878789e+00 5.6810280412635601e+00 - 36 1.7111787089042565e+00 -4.4473718671663391e+00 9.6398513850121076e-02 + 36 1.7111787089042565e+00 -4.4473718671663391e+00 9.6398513850120965e-02 37 -3.8563809307986823e+00 5.6131073606614059e+00 -6.6177968130852260e+00 38 1.5064516388374909e+00 -3.1694753678232956e-01 -8.3526359314898979e-01 39 4.1314418694153812e+00 -6.2751004763663678e+00 -1.1210904504268449e+01 40 9.5830290785144836e+00 -7.0395435048262769e+00 -1.6267459470122683e+00 41 3.1375436243120802e-01 1.0622164383329200e+00 -2.2467935230672076e+00 - 42 -9.4881290346220375e+00 -6.3542967900678029e+00 -3.7436081761319060e+00 + 42 -9.4881290346220410e+00 -6.3542967900678029e+00 -3.7436081761319024e+00 43 2.2855728522521823e-01 -1.3797673758210431e+01 5.1169123226999269e-01 44 8.0135824689800454e+00 -8.1618220152116709e+00 3.4767795780208774e+00 - 45 -2.2793629160624870e-01 3.8533578964252726e+00 -7.3720918772105994e+00 - 46 -3.5217473183911405e+00 -5.1375353430494126e+00 1.2535347493777751e+01 - 47 5.1244898311428937e+00 2.3801653011346930e+00 5.1114297013297003e+00 + 45 -2.2793629160624826e-01 3.8533578964252726e+00 -7.3720918772105994e+00 + 46 -3.5217473183911387e+00 -5.1375353430494126e+00 1.2535347493777753e+01 + 47 5.1244898311428937e+00 2.3801653011346930e+00 5.1114297013296994e+00 48 2.1906793040748171e+00 3.0345200169741182e+00 -1.0179863236095192e+00 49 -2.4788694934316329e+00 -1.2411071815396923e+01 -8.4971983039341392e+00 50 3.6569038614206466e+00 5.6055766933888798e+00 -7.2525721879624516e-01 diff --git a/unittest/force-styles/tests/manybody-pair-snap_chem.yaml b/unittest/force-styles/tests/manybody-pair-snap_chem.yaml index 80b19b09f8..861d2569a1 100644 --- a/unittest/force-styles/tests/manybody-pair-snap_chem.yaml +++ b/unittest/force-styles/tests/manybody-pair-snap_chem.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:09:18 2021 +date_generated: Fri Mar 18 22:17:49 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair snap pair zbl @@ -20,142 +21,142 @@ pair_coeff: ! | extract: ! | scale 2 natoms: 64 -init_vdwl: -185.3871232982 +init_vdwl: -185.38712329820027 init_coul: 0 init_stress: ! |2- - 2.1627572764873941e+02 2.1843973818802459e+02 2.2323704161405180e+02 -5.3476822166125260e+00 2.9965125280144921e+01 1.1801773510998568e+00 + 2.1627572764873955e+02 2.1843973818802462e+02 2.2323704161405180e+02 -5.3476822166124451e+00 2.9965125280144893e+01 1.1801773510998288e+00 init_forces: ! |2 - 1 -8.9407797360085750e-01 3.1174511790027069e+00 1.7848004756991140e+00 - 2 -2.3497957616596570e+00 -7.0361817598817300e-01 -1.5634923191374663e+00 - 3 6.2372158338858297e-01 2.7149161557212836e-01 -4.8035793806964550e-01 - 4 -2.0337936615474277e+00 2.9491894607511560e+00 9.8066478014365177e-01 - 5 -1.9807302026626274e+00 -4.1921845197039964e-01 -3.9514999290884223e-01 - 6 -1.0256636650332038e-01 2.3662295416638282e+00 9.0816298775387960e-01 - 7 -6.0657120592984892e-01 -8.0634286798072863e-01 2.1759740426498744e+00 - 8 6.0627276316787593e-01 1.0677577347039506e+00 -1.2887262448970753e+00 - 9 -3.0674852805673963e-01 -2.0605633540913679e+00 -2.5500662803249239e+00 - 10 -1.9428976574806009e-01 -1.4648835736857642e+00 -2.8490531930038263e+00 + 1 -8.9407797360085706e-01 3.1174511790027060e+00 1.7848004756991140e+00 + 2 -2.3497957616596574e+00 -7.0361817598817256e-01 -1.5634923191374668e+00 + 3 6.2372158338858452e-01 2.7149161557213058e-01 -4.8035793806964533e-01 + 4 -2.0337936615474259e+00 2.9491894607511564e+00 9.8066478014365321e-01 + 5 -1.9807302026626288e+00 -4.1921845197040009e-01 -3.9514999290884223e-01 + 6 -1.0256636650332041e-01 2.3662295416638286e+00 9.0816298775387949e-01 + 7 -6.0657120592984815e-01 -8.0634286798072863e-01 2.1759740426498739e+00 + 8 6.0627276316787682e-01 1.0677577347039506e+00 -1.2887262448970751e+00 + 9 -3.0674852805674102e-01 -2.0605633540913679e+00 -2.5500662803249234e+00 + 10 -1.9428976574805981e-01 -1.4648835736857646e+00 -2.8490531930038263e+00 11 3.1532548864214469e+00 -2.9033258960601414e+00 2.2619034310429740e+00 - 12 -5.4038968585110823e+00 -3.2935652899479950e+00 -2.5707355493491839e+00 - 13 -6.1736753137043876e-01 5.1000477579656485e+00 -1.3304391624961645e+00 - 14 -1.4190543180546633e+00 3.3413841917147451e+00 4.6351390250498647e-01 - 15 -3.1131424694968639e+00 4.4700267996081635e+00 -3.2364337367424323e+00 - 16 1.7079914236492706e+00 -1.9995742761541713e-01 5.0185841295230196e+00 - 17 2.3724862536641020e+00 3.0987980523864964e+00 -3.4198379943456869e+00 - 18 -2.5111265055016418e-01 7.3348166166902651e-01 3.0622036193004067e+00 - 19 -1.2828262181283363e+00 -2.2345757410919136e+00 -3.3669351804163505e-01 - 20 -5.9491949074906927e+00 3.2510448152978932e-01 6.8450449383665313e-01 - 21 1.3962036186373195e+00 3.9865506204930412e-01 -2.5893554970082731e+00 + 12 -5.4038968585110840e+00 -3.2935652899479950e+00 -2.5707355493491839e+00 + 13 -6.1736753137043876e-01 5.1000477579656494e+00 -1.3304391624961647e+00 + 14 -1.4190543180546629e+00 3.3413841917147442e+00 4.6351390250498603e-01 + 15 -3.1131424694968644e+00 4.4700267996081635e+00 -3.2364337367424332e+00 + 16 1.7079914236492701e+00 -1.9995742761541768e-01 5.0185841295230187e+00 + 17 2.3724862536641029e+00 3.0987980523864973e+00 -3.4198379943456869e+00 + 18 -2.5111265055016468e-01 7.3348166166902651e-01 3.0622036193004081e+00 + 19 -1.2828262181283365e+00 -2.2345757410919114e+00 -3.3669351804163505e-01 + 20 -5.9491949074906927e+00 3.2510448152978899e-01 6.8450449383665324e-01 + 21 1.3962036186373190e+00 3.9865506204930412e-01 -2.5893554970082739e+00 22 -5.1263732155413688e+00 3.6744897485626438e+00 -4.8303251395784113e+00 - 23 1.7617874308698167e+00 2.9253519141342812e+00 1.4679679444255547e+00 - 24 1.5937879337284957e+00 8.9992286487733242e-01 2.8087468575298802e+00 - 25 1.0286448774492765e+00 -4.3669506584228418e-01 1.2594354985828544e+00 - 26 -3.5670456442877885e-01 -3.9811471877482152e-01 8.1854393579980123e-01 - 27 1.9066785243503745e+00 -2.9510326328254666e-01 1.2119553206259761e+00 + 23 1.7617874308698158e+00 2.9253519141342803e+00 1.4679679444255556e+00 + 24 1.5937879337284966e+00 8.9992286487733242e-01 2.8087468575298802e+00 + 25 1.0286448774492765e+00 -4.3669506584228257e-01 1.2594354985828535e+00 + 26 -3.5670456442877874e-01 -3.9811471877482207e-01 8.1854393579979901e-01 + 27 1.9066785243503748e+00 -2.9510326328254666e-01 1.2119553206259761e+00 28 2.5221087546187970e-01 1.4370172575472946e+00 4.1039332214108297e+00 - 29 -2.7893073887365909e+00 7.8106446652879402e-01 -8.2039261846997913e-01 - 30 -1.8694503114341463e+00 7.0812686858707219e-01 -9.1751940639239238e-01 - 31 -7.0985766256762606e-01 8.6963471463259845e-01 -7.5188557225015407e-01 - 32 -2.4089849337056686e+00 4.0992982351371343e-01 -1.1381600041412354e-01 + 29 -2.7893073887365909e+00 7.8106446652879447e-01 -8.2039261846997913e-01 + 30 -1.8694503114341459e+00 7.0812686858707219e-01 -9.1751940639239149e-01 + 31 -7.0985766256762695e-01 8.6963471463259756e-01 -7.5188557225015407e-01 + 32 -2.4089849337056686e+00 4.0992982351371365e-01 -1.1381600041412332e-01 33 4.3597028481189950e+00 -2.6773596435480469e+00 3.1791467867699659e+00 - 34 5.1607419486495609e-01 1.3141798772668656e-01 8.7023229642897881e-02 - 35 1.2413218618562052e+00 -4.1427608114771042e-01 2.5651243684278673e+00 - 36 -1.1152887975138914e-01 -2.3088354090108645e+00 -2.3687452176819246e-01 - 37 -2.1752322691080082e+00 1.9377327531750534e+00 -2.2419453197067281e+00 - 38 -9.9594979744325007e-01 -1.8147173502133196e-01 6.8832530755714671e-01 - 39 2.8779281856552115e+00 -1.7332955648283568e+00 -3.4260103364251702e+00 + 34 5.1607419486495698e-01 1.3141798772668656e-01 8.7023229642896549e-02 + 35 1.2413218618562050e+00 -4.1427608114771042e-01 2.5651243684278677e+00 + 36 -1.1152887975138892e-01 -2.3088354090108645e+00 -2.3687452176819246e-01 + 37 -2.1752322691080082e+00 1.9377327531750534e+00 -2.2419453197067285e+00 + 38 -9.9594979744324963e-01 -1.8147173502133196e-01 6.8832530755714627e-01 + 39 2.8779281856552119e+00 -1.7332955648283566e+00 -3.4260103364251711e+00 40 4.3351429466694658e+00 -2.2624572291840446e+00 -1.7065975882223454e+00 - 41 2.5124166305689205e-01 -4.2179260496370535e-01 -1.2503380336802188e+00 - 42 -3.5352439688397177e+00 -1.6053715846066745e+00 -6.7917775288119286e-01 - 43 8.4817996010401342e-01 -4.8899181684596487e+00 1.7369510897908608e-01 - 44 3.0506037114469597e+00 -3.3226877009576907e+00 1.7796293414951672e+00 - 45 -1.8374092699066717e+00 1.5294723708757643e+00 -2.7502022232711680e+00 - 46 -9.1023563070749636e-01 -1.7778137773508709e+00 4.9843270240840054e+00 - 47 2.6124800260927605e+00 1.6175231582888072e+00 1.5805303054926745e+00 - 48 1.4743780750991475e+00 3.6707315780789784e-02 -2.9750115931288068e-01 - 49 -2.3858202682345646e+00 -4.2223184267227856e+00 -2.7959407680025525e+00 - 50 2.4067134019906966e-01 2.8105796871762401e+00 -1.0687621004291821e+00 - 51 -1.7932456135513859e+00 2.6201558060481256e+00 3.7648454668413778e+00 - 52 4.6358669186213994e+00 -4.8660554435252061e+00 5.0894919019570990e+00 + 41 2.5124166305689205e-01 -4.2179260496370535e-01 -1.2503380336802179e+00 + 42 -3.5352439688397177e+00 -1.6053715846066747e+00 -6.7917775288119320e-01 + 43 8.4817996010401320e-01 -4.8899181684596487e+00 1.7369510897908585e-01 + 44 3.0506037114469597e+00 -3.3226877009576921e+00 1.7796293414951698e+00 + 45 -1.8374092699066711e+00 1.5294723708757640e+00 -2.7502022232711680e+00 + 46 -9.1023563070749647e-01 -1.7778137773508709e+00 4.9843270240840036e+00 + 47 2.6124800260927610e+00 1.6175231582888072e+00 1.5805303054926745e+00 + 48 1.4743780750991475e+00 3.6707315780788896e-02 -2.9750115931288024e-01 + 49 -2.3858202682345651e+00 -4.2223184267227856e+00 -2.7959407680025525e+00 + 50 2.4067134019906877e-01 2.8105796871762401e+00 -1.0687621004291821e+00 + 51 -1.7932456135513859e+00 2.6201558060481247e+00 3.7648454668413782e+00 + 52 4.6358669186214012e+00 -4.8660554435252070e+00 5.0894919019571008e+00 53 2.9898995132891759e+00 3.3216926541391691e+00 2.4227995842838990e+00 - 54 1.8732808586337490e+00 -3.0909639789911152e+00 -2.2880122319662020e+00 - 55 1.1426678804104569e+00 -2.5892472259617532e+00 -3.2449552890237379e+00 - 56 -1.1541931360327617e-01 -8.3260558816073249e-02 -1.7966753733604057e+00 - 57 -1.2751171337205552e-01 -8.8899643643851300e-01 -5.0726814112209695e-02 - 58 2.4813755367140655e+00 -1.2765007868408016e+00 1.5628981219370035e+00 - 59 2.9909449561888715e+00 2.1621928717215857e+00 -2.3820831167094330e+00 - 60 -2.2387715060953868e+00 -5.2442113310349736e+00 -2.6985516164859109e+00 - 61 -1.0184694703280122e+00 1.5256818152660523e+00 -1.0113329140640652e+00 - 62 -2.7862663394350542e+00 2.5876139756856791e+00 -1.7815179130043122e+00 + 54 1.8732808586337490e+00 -3.0909639789911147e+00 -2.2880122319662011e+00 + 55 1.1426678804104577e+00 -2.5892472259617527e+00 -3.2449552890237365e+00 + 56 -1.1541931360327529e-01 -8.3260558816073277e-02 -1.7966753733604057e+00 + 57 -1.2751171337205550e-01 -8.8899643643851300e-01 -5.0726814112209681e-02 + 58 2.4813755367140646e+00 -1.2765007868408011e+00 1.5628981219370035e+00 + 59 2.9909449561888715e+00 2.1621928717215848e+00 -2.3820831167094330e+00 + 60 -2.2387715060953877e+00 -5.2442113310349736e+00 -2.6985516164859127e+00 + 61 -1.0184694703280104e+00 1.5256818152660523e+00 -1.0113329140640650e+00 + 62 -2.7862663394350546e+00 2.5876139756856795e+00 -1.7815179130043122e+00 63 2.4339134295594302e+00 -3.1961735689987636e+00 -4.7891394265908094e-01 64 3.0382364587319710e+00 3.0430454898558588e+00 5.3416679902175384e+00 -run_vdwl: -185.37158003654 +run_vdwl: -185.3715800365395 run_coul: 0 run_stress: ! |2- - 2.1623225685916989e+02 2.1844347630762962e+02 2.2331780542890360e+02 -5.3222115188692429e+00 2.9861519391528514e+01 1.4556702426797457e+00 + 2.1623225685917001e+02 2.1844347630762960e+02 2.2331780542890351e+02 -5.3222115188692971e+00 2.9861519391528528e+01 1.4556702426798678e+00 run_forces: ! |2 - 1 -8.9945686093718891e-01 3.1102506844270676e+00 1.7924405901882392e+00 - 2 -2.3568426321865519e+00 -7.2157123823439751e-01 -1.5714999679660120e+00 - 3 5.9411461824307632e-01 2.8183072295935307e-01 -4.5584602006848729e-01 - 4 -2.0142955850044015e+00 2.9566870880684544e+00 9.5256971160575310e-01 - 5 -1.9922574807409990e+00 -4.3135288450095111e-01 -3.7982056237068562e-01 - 6 -5.1798692305348421e-02 2.3723138325448181e+00 9.3505820052018818e-01 - 7 -5.9119307570788093e-01 -7.7558353156540627e-01 2.1544553310334216e+00 - 8 5.8948882611514830e-01 1.0627350289336350e+00 -1.2852382666540922e+00 + 1 -8.9945686093718891e-01 3.1102506844270676e+00 1.7924405901882381e+00 + 2 -2.3568426321865532e+00 -7.2157123823439751e-01 -1.5714999679660120e+00 + 3 5.9411461824307610e-01 2.8183072295935313e-01 -4.5584602006848723e-01 + 4 -2.0142955850044006e+00 2.9566870880684544e+00 9.5256971160575388e-01 + 5 -1.9922574807409981e+00 -4.3135288450095111e-01 -3.7982056237068340e-01 + 6 -5.1798692305348448e-02 2.3723138325448176e+00 9.3505820052018818e-01 + 7 -5.9119307570787982e-01 -7.7558353156540449e-01 2.1544553310334202e+00 + 8 5.8948882611514741e-01 1.0627350289336348e+00 -1.2852382666540922e+00 9 -3.3097669603148050e-01 -2.0880700958311560e+00 -2.5728226298711561e+00 - 10 -1.9927857234351742e-01 -1.4707681067903973e+00 -2.8077583365509944e+00 - 11 3.1207021637041077e+00 -2.8777137799483214e+00 2.2513409071418939e+00 - 12 -5.3967388032136201e+00 -3.2755306245890572e+00 -2.5607263918480787e+00 - 13 -5.6089163267500575e-01 5.0895164624360953e+00 -1.2955340742015935e+00 - 14 -1.4424532600588069e+00 3.3397136313988538e+00 4.5056661625381278e-01 - 15 -3.1074264051087690e+00 4.4511163568785594e+00 -3.2255959617646495e+00 - 16 1.7028459742310051e+00 -1.9401543199346183e-01 4.9988885414419002e+00 - 17 2.3696411307116665e+00 3.0980579975818054e+00 -3.3992055709392099e+00 - 18 -2.7992627916472068e-01 7.5956985532908217e-01 3.0731406281977875e+00 - 19 -1.3087170031025481e+00 -2.2579241841048194e+00 -3.5423832115910026e-01 - 20 -5.9291180532530054e+00 3.0139344848989125e-01 6.6702127138861189e-01 - 21 1.4061702325656915e+00 3.6170742151671309e-01 -2.6186453774142455e+00 - 22 -5.1213538363270104e+00 3.6881133786353173e+00 -4.8334441466973619e+00 - 23 1.7799014438457179e+00 2.9383932016836729e+00 1.4889345853939060e+00 - 24 1.6265217601475135e+00 8.8638236910287549e-01 2.7958579602051579e+00 - 25 1.0261772589787777e+00 -4.3124823838990639e-01 1.2394756760658081e+00 - 26 -3.6788963153370424e-01 -3.8430715508218222e-01 8.2234939362562109e-01 - 27 1.9227116387813055e+00 -3.1924343057968851e-01 1.2219662551930728e+00 - 28 2.3558028807578302e-01 1.4603195758319958e+00 4.1124437707751715e+00 - 29 -2.7963204027225057e+00 7.9250484371162710e-01 -8.2374097886304931e-01 - 30 -1.8521850555057384e+00 6.8904513184563698e-01 -9.2377203073191461e-01 - 31 -7.0737710488564920e-01 8.7160390581421554e-01 -7.5132187044876142e-01 - 32 -2.3972194269400724e+00 4.0579824422398403e-01 -1.2192450250956055e-01 - 33 4.3391252363949713e+00 -2.6734632549855011e+00 3.1813837430923790e+00 - 34 5.0892540867377134e-01 1.3196433190574863e-01 9.1854393014863867e-02 - 35 1.2518949422589467e+00 -4.0131662341328833e-01 2.5682121097610247e+00 - 36 -1.4250724827861927e-01 -2.2940369352156500e+00 -2.7656165676472910e-01 - 37 -2.1638911011422111e+00 1.9200057202539940e+00 -2.2495537548075712e+00 - 38 -9.8448646953871100e-01 -1.7353311784227321e-01 6.9784505363718075e-01 - 39 2.8621020667478243e+00 -1.7235695529844155e+00 -3.4231784253086803e+00 - 40 4.3701211996432816e+00 -2.2721992461764238e+00 -1.7277010563698145e+00 - 41 2.7615064013020879e-01 -3.9976618325080288e-01 -1.2290534994924236e+00 + 10 -1.9927857234351726e-01 -1.4707681067903968e+00 -2.8077583365509944e+00 + 11 3.1207021637041081e+00 -2.8777137799483206e+00 2.2513409071418935e+00 + 12 -5.3967388032136201e+00 -3.2755306245890572e+00 -2.5607263918480783e+00 + 13 -5.6089163267500619e-01 5.0895164624360953e+00 -1.2955340742015937e+00 + 14 -1.4424532600588069e+00 3.3397136313988520e+00 4.5056661625381322e-01 + 15 -3.1074264051087690e+00 4.4511163568785586e+00 -3.2255959617646495e+00 + 16 1.7028459742310051e+00 -1.9401543199346216e-01 4.9988885414419002e+00 + 17 2.3696411307116665e+00 3.0980579975818046e+00 -3.3992055709392099e+00 + 18 -2.7992627916472068e-01 7.5956985532908261e-01 3.0731406281977867e+00 + 19 -1.3087170031025486e+00 -2.2579241841048194e+00 -3.5423832115910003e-01 + 20 -5.9291180532530054e+00 3.0139344848989147e-01 6.6702127138861189e-01 + 21 1.4061702325656906e+00 3.6170742151671309e-01 -2.6186453774142455e+00 + 22 -5.1213538363270104e+00 3.6881133786353173e+00 -4.8334441466973601e+00 + 23 1.7799014438457179e+00 2.9383932016836734e+00 1.4889345853939060e+00 + 24 1.6265217601475135e+00 8.8638236910287538e-01 2.7958579602051583e+00 + 25 1.0261772589787781e+00 -4.3124823838990606e-01 1.2394756760658081e+00 + 26 -3.6788963153370446e-01 -3.8430715508218188e-01 8.2234939362562132e-01 + 27 1.9227116387813059e+00 -3.1924343057968840e-01 1.2219662551930730e+00 + 28 2.3558028807578357e-01 1.4603195758319969e+00 4.1124437707751706e+00 + 29 -2.7963204027225057e+00 7.9250484371162622e-01 -8.2374097886304931e-01 + 30 -1.8521850555057389e+00 6.8904513184563609e-01 -9.2377203073191461e-01 + 31 -7.0737710488565009e-01 8.7160390581421510e-01 -7.5132187044876320e-01 + 32 -2.3972194269400706e+00 4.0579824422398203e-01 -1.2192450250956144e-01 + 33 4.3391252363949722e+00 -2.6734632549855015e+00 3.1813837430923795e+00 + 34 5.0892540867377156e-01 1.3196433190574863e-01 9.1854393014863867e-02 + 35 1.2518949422589467e+00 -4.0131662341328811e-01 2.5682121097610247e+00 + 36 -1.4250724827861927e-01 -2.2940369352156509e+00 -2.7656165676472905e-01 + 37 -2.1638911011422115e+00 1.9200057202539940e+00 -2.2495537548075712e+00 + 38 -9.8448646953871100e-01 -1.7353311784227321e-01 6.9784505363718097e-01 + 39 2.8621020667478243e+00 -1.7235695529844157e+00 -3.4231784253086803e+00 + 40 4.3701211996432816e+00 -2.2721992461764251e+00 -1.7277010563698145e+00 + 41 2.7615064013020929e-01 -3.9976618325080443e-01 -1.2290534994924227e+00 42 -3.5411751645812308e+00 -1.6301898139986259e+00 -6.9693956624465969e-01 - 43 8.3282307590551552e-01 -4.8791394930408867e+00 1.5641553921436965e-01 - 44 3.0588569737321962e+00 -3.3230712362593824e+00 1.7740893109825144e+00 + 43 8.3282307590551574e-01 -4.8791394930408858e+00 1.5641553921436943e-01 + 44 3.0588569737321967e+00 -3.3230712362593806e+00 1.7740893109825142e+00 45 -1.8543980101593716e+00 1.5090063048017774e+00 -2.7391343400007346e+00 - 46 -9.0836218859416373e-01 -1.7703257020194161e+00 5.0074804595763203e+00 - 47 2.6157347327468776e+00 1.6066618984181202e+00 1.5922002611321855e+00 - 48 1.4730694115534324e+00 6.0150682431382663e-02 -2.9959320813488199e-01 - 49 -2.4357178268972279e+00 -4.2752924255184093e+00 -2.8456954906038585e+00 - 50 2.5008857416428043e-01 2.7975929070952108e+00 -1.0870819292025393e+00 - 51 -1.8364703217563023e+00 2.6546000140944859e+00 3.7824174449012462e+00 + 46 -9.0836218859416396e-01 -1.7703257020194161e+00 5.0074804595763194e+00 + 47 2.6157347327468772e+00 1.6066618984181202e+00 1.5922002611321857e+00 + 48 1.4730694115534333e+00 6.0150682431383107e-02 -2.9959320813488199e-01 + 49 -2.4357178268972288e+00 -4.2752924255184075e+00 -2.8456954906038590e+00 + 50 2.5008857416428043e-01 2.7975929070952121e+00 -1.0870819292025393e+00 + 51 -1.8364703217563023e+00 2.6546000140944868e+00 3.7824174449012453e+00 52 4.6470415706761310e+00 -4.8541726113169865e+00 5.0978546929624020e+00 - 53 3.0332748609694704e+00 3.3674028164180130e+00 2.5018294078539540e+00 - 54 1.8687605158732028e+00 -3.0896400645801418e+00 -2.2872620802274950e+00 + 53 3.0332748609694704e+00 3.3674028164180108e+00 2.5018294078539536e+00 + 54 1.8687605158732028e+00 -3.0896400645801418e+00 -2.2872620802274941e+00 55 1.1194011524426077e+00 -2.5850952550361570e+00 -3.2174616299206584e+00 - 56 -1.2168319727714011e-01 -1.1667111392940022e-01 -1.7915767087323147e+00 - 57 -1.3228227178289417e-01 -9.1363578630224795e-01 -5.3462423971004584e-02 - 58 2.4842158694223677e+00 -1.2568730326784874e+00 1.5401682371106145e+00 - 59 3.0140102195799274e+00 2.1895971720503873e+00 -2.3881807893321017e+00 + 56 -1.2168319727713972e-01 -1.1667111392940022e-01 -1.7915767087323147e+00 + 57 -1.3228227178289331e-01 -9.1363578630224795e-01 -5.3462423971004584e-02 + 58 2.4842158694223682e+00 -1.2568730326784874e+00 1.5401682371106145e+00 + 59 3.0140102195799274e+00 2.1895971720503873e+00 -2.3881807893321030e+00 60 -2.2877466661828931e+00 -5.2803433601364151e+00 -2.7505525589065760e+00 - 61 -1.0115642352983962e+00 1.5284330358705578e+00 -1.0029499332563923e+00 - 62 -2.7811684029592287e+00 2.5821146485313546e+00 -1.7679954771137567e+00 - 63 2.4383789403708427e+00 -3.2264210802804598e+00 -5.0624191626484460e-01 - 64 3.0873388675112903e+00 3.1015018772904330e+00 5.3730513624445901e+00 + 61 -1.0115642352983965e+00 1.5284330358705580e+00 -1.0029499332563923e+00 + 62 -2.7811684029592287e+00 2.5821146485313546e+00 -1.7679954771137576e+00 + 63 2.4383789403708427e+00 -3.2264210802804594e+00 -5.0624191626484549e-01 + 64 3.0873388675112894e+00 3.1015018772904330e+00 5.3730513624445901e+00 ... diff --git a/unittest/force-styles/tests/manybody-pair-sw-mod-maxdelcs.yaml b/unittest/force-styles/tests/manybody-pair-sw-mod-maxdelcs.yaml index 02c4afee71..890e0652a8 100644 --- a/unittest/force-styles/tests/manybody-pair-sw-mod-maxdelcs.yaml +++ b/unittest/force-styles/tests/manybody-pair-sw-mod-maxdelcs.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 27 Oct 2021 -date_generated: Fri Dec 3 17:14:23 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:49 2022 epsilon: 2e-08 skip_tests: prerequisites: ! | @@ -18,139 +18,139 @@ natoms: 64 init_vdwl: -102.90155182016774 init_coul: 0 init_stress: ! |- - -2.1947417260888678e+01 -2.2105178629076043e+01 -2.2782150007200460e+01 -9.6831443397089743e+00 2.8031085226335019e+01 2.6425790794270330e+00 + -2.1947417260888635e+01 -2.2105178629076072e+01 -2.2782150007200425e+01 -9.6831443397088854e+00 2.8031085226335051e+01 2.6425790794270130e+00 init_forces: ! |2 - 1 -8.2322511989895242e-01 2.6315476703135525e+00 1.6442126058355577e+00 - 2 -2.2311488847312719e+00 -8.2456809265006359e-01 -2.2293515519297400e+00 - 3 4.2989240623230440e-01 -4.6052129249824086e-01 -4.8909609892212980e-01 - 4 -1.5530833374407123e+00 2.5748774212987220e+00 1.5034912600724022e+00 - 5 -6.9171825412605936e-01 -1.0531847386600970e+00 9.2147776138588822e-02 - 6 1.5451416942873637e+00 3.1375544318493689e+00 2.4850508416452671e-01 - 7 -9.0063706268170907e-01 -2.7193406920151647e-01 5.1367456614538520e-01 - 8 -6.4440839188902421e-02 3.8701567174252616e-01 -2.4285825715258058e-01 - 9 -5.5617200225703267e-02 -2.1277279901291282e+00 -1.6680511813979533e+00 - 10 2.7595287122399431e-01 -1.3559527412339436e+00 -2.0239561413486844e+00 - 11 2.9100882412227174e+00 -3.1645938128174627e+00 1.7652131399585074e+00 - 12 -5.1610115075594178e+00 -3.0600096528148240e+00 -2.5793792565700739e+00 - 13 -9.9287698044288153e-01 5.1159440453263549e+00 -7.4140454237552722e-02 - 14 -1.3042563529153732e+00 3.2552405905184112e+00 -3.0303315732398806e-01 - 15 -3.0223048479632428e+00 2.8527569963119044e+00 -2.3811658931584292e+00 - 16 1.2225520471067990e+00 8.8148095840949869e-01 4.9430491876220550e+00 - 17 5.0768442926270452e-01 2.6034887477601787e+00 -3.6788718899516661e+00 - 18 8.3718278912359012e-01 1.6046320767230449e-01 3.0550065526090071e+00 - 19 -1.2883762451214118e+00 -2.3849116987845123e+00 -5.8477823649252847e-01 - 20 -5.5132529604846408e+00 4.3662399751356906e-01 8.3739708194443407e-01 - 21 1.9465564103522475e+00 3.3605256895156632e-01 -1.9812639945440429e+00 - 22 -5.3900034257758653e+00 2.7980876817713836e+00 -3.4581879904248547e+00 - 23 -6.9551235863135563e-01 1.7167183106714698e+00 1.8596769847634977e+00 - 24 1.0373451376796643e+00 2.8037482368183038e+00 1.5763756953329264e+00 - 25 8.5682777970106550e-01 -1.7513088261915449e-01 1.4385656519499774e+00 - 26 -6.0687244397992490e-01 -8.5621207324266868e-01 3.7445504803187213e-01 - 27 1.7542395648890141e+00 -9.7450364945012324e-01 1.0100795516082988e+00 - 28 1.4371612196473649e+00 7.8751799333407246e-01 4.0754691654932156e+00 - 29 -1.6851872634862173e+00 3.1860021588877185e-01 -1.9136043995523440e+00 - 30 -1.5120093558295022e-01 1.9897138579775446e+00 -7.7482882434134659e-01 - 31 -7.9238133559867108e-01 1.2389159718859988e+00 -9.7158187701085530e-01 - 32 -2.9467345906797955e+00 -2.2258546046845273e-01 -1.2952141841455944e+00 - 33 4.1055969687703975e+00 -2.1993536054909826e+00 2.3398821758640871e+00 - 34 -5.4666470780943710e-01 -5.1596374513625265e-01 4.4995707525341821e-01 - 35 6.5409470446315543e-01 -4.4929224101256049e-01 2.3033958551093261e+00 - 36 4.4102715770557099e-01 -1.9494304695990754e+00 -2.7711726811313486e-01 - 37 -1.1814185367881915e+00 1.5093409982347743e+00 -2.0145241812388726e+00 - 38 7.9979956273041686e-01 -6.2510014668964398e-01 2.2470258713803903e-01 - 39 9.1480685090248115e-01 -8.6858033858396233e-01 -3.0830126961472613e+00 - 40 2.8593879358814682e+00 -9.8501251752205943e-01 -9.5860078192014586e-01 - 41 2.1485211965273499e-01 5.2449517317149030e-02 -3.7464374392695876e-01 - 42 -3.1798376119681415e+00 -1.4672181113880249e+00 -3.2842910189007968e-01 - 43 5.4671499454984429e-01 -4.1359175442160714e+00 -1.8207740535793332e-01 - 44 2.9266008103038206e+00 -3.6068419804864180e+00 1.2113363596827269e+00 - 45 1.8852873543332602e-01 2.0862322450867481e+00 -2.2746048462286232e+00 - 46 3.1050327756207308e-01 -6.8131822103739004e-01 3.3099599857084856e+00 - 47 1.5495643784665116e+00 4.7838931757231606e-01 1.7237903621133266e+00 - 48 -1.0044710103079812e-01 1.9268843643577713e+00 -7.8383576073068006e-02 - 49 -7.5032605988628509e-01 -4.2197737225953258e+00 -2.3776532103934995e+00 - 50 1.6605480572872189e-01 2.1347903400364161e+00 -1.0644591517660023e+00 - 51 -1.0044546762645692e+00 3.4523503888228477e+00 2.5759868763834457e+00 - 52 3.3060194272186956e+00 -4.1095446389475212e+00 4.4973693213048920e+00 - 53 2.0013241503011043e+00 2.1568842444962932e+00 5.8576907510814702e-01 - 54 2.2795507897178497e+00 -1.6689794713655521e+00 -1.2265506067291636e+00 - 55 1.4414345631526004e+00 -2.3308559065173404e+00 -2.6744299494180348e+00 - 56 -1.2975056485899019e+00 1.2610549989098461e+00 -1.8919017562855065e+00 - 57 4.4635450423847911e-01 -1.8891747786298547e+00 -7.3598594916023358e-02 - 58 1.8732023203115655e+00 -1.2871222078269424e+00 1.1034998112961900e+00 - 59 2.5191023566928030e+00 1.3386335071903233e+00 -1.3910367397923291e+00 - 60 -1.3827430344664839e+00 -4.7488532834440305e+00 -2.6077765026678694e+00 - 61 5.6154005053867850e-01 1.6367914021307663e+00 2.2225403413594347e-01 - 62 -2.7117320012918236e+00 2.0222828099298611e+00 -1.0992589926255703e+00 - 63 1.1817576812178230e+00 -3.4891322995415415e+00 1.2117401144494494e-01 - 64 1.9765285883417301e+00 2.0768686745001230e+00 5.0210256117812220e+00 -run_vdwl: -102.8863066387519 + 1 -8.2322511989895286e-01 2.6315476703135534e+00 1.6442126058355560e+00 + 2 -2.2311488847312733e+00 -8.2456809265006314e-01 -2.2293515519297409e+00 + 3 4.2989240623230396e-01 -4.6052129249824009e-01 -4.8909609892212980e-01 + 4 -1.5530833374407118e+00 2.5748774212987229e+00 1.5034912600724004e+00 + 5 -6.9171825412605770e-01 -1.0531847386600979e+00 9.2147776138589044e-02 + 6 1.5451416942873628e+00 3.1375544318493702e+00 2.4850508416452707e-01 + 7 -9.0063706268170862e-01 -2.7193406920151580e-01 5.1367456614538520e-01 + 8 -6.4440839188902199e-02 3.8701567174252571e-01 -2.4285825715257958e-01 + 9 -5.5617200225704821e-02 -2.1277279901291286e+00 -1.6680511813979537e+00 + 10 2.7595287122399337e-01 -1.3559527412339423e+00 -2.0239561413486840e+00 + 11 2.9100882412227174e+00 -3.1645938128174644e+00 1.7652131399585087e+00 + 12 -5.1610115075594178e+00 -3.0600096528148244e+00 -2.5793792565700748e+00 + 13 -9.9287698044288120e-01 5.1159440453263541e+00 -7.4140454237553610e-02 + 14 -1.3042563529153728e+00 3.2552405905184107e+00 -3.0303315732398750e-01 + 15 -3.0223048479632446e+00 2.8527569963119053e+00 -2.3811658931584310e+00 + 16 1.2225520471067990e+00 8.8148095840949914e-01 4.9430491876220541e+00 + 17 5.0768442926270341e-01 2.6034887477601774e+00 -3.6788718899516679e+00 + 18 8.3718278912358901e-01 1.6046320767230560e-01 3.0550065526090062e+00 + 19 -1.2883762451214091e+00 -2.3849116987845123e+00 -5.8477823649252580e-01 + 20 -5.5132529604846399e+00 4.3662399751356784e-01 8.3739708194443241e-01 + 21 1.9465564103522484e+00 3.3605256895156721e-01 -1.9812639945440438e+00 + 22 -5.3900034257758644e+00 2.7980876817713818e+00 -3.4581879904248525e+00 + 23 -6.9551235863135630e-01 1.7167183106714672e+00 1.8596769847634960e+00 + 24 1.0373451376796661e+00 2.8037482368183042e+00 1.5763756953329238e+00 + 25 8.5682777970106683e-01 -1.7513088261915744e-01 1.4385656519499770e+00 + 26 -6.0687244397992524e-01 -8.5621207324266835e-01 3.7445504803187202e-01 + 27 1.7542395648890132e+00 -9.7450364945012380e-01 1.0100795516083001e+00 + 28 1.4371612196473667e+00 7.8751799333407491e-01 4.0754691654932129e+00 + 29 -1.6851872634862182e+00 3.1860021588877185e-01 -1.9136043995523437e+00 + 30 -1.5120093558295000e-01 1.9897138579775460e+00 -7.7482882434134670e-01 + 31 -7.9238133559867097e-01 1.2389159718859988e+00 -9.7158187701085397e-01 + 32 -2.9467345906797968e+00 -2.2258546046845362e-01 -1.2952141841455935e+00 + 33 4.1055969687703993e+00 -2.1993536054909835e+00 2.3398821758640898e+00 + 34 -5.4666470780943921e-01 -5.1596374513625398e-01 4.4995707525341944e-01 + 35 6.5409470446315654e-01 -4.4929224101256449e-01 2.3033958551093252e+00 + 36 4.4102715770557377e-01 -1.9494304695990761e+00 -2.7711726811313436e-01 + 37 -1.1814185367881915e+00 1.5093409982347745e+00 -2.0145241812388743e+00 + 38 7.9979956273041664e-01 -6.2510014668964453e-01 2.2470258713804081e-01 + 39 9.1480685090248293e-01 -8.6858033858396189e-01 -3.0830126961472590e+00 + 40 2.8593879358814660e+00 -9.8501251752205843e-01 -9.5860078192014397e-01 + 41 2.1485211965273421e-01 5.2449517317148364e-02 -3.7464374392695943e-01 + 42 -3.1798376119681420e+00 -1.4672181113880254e+00 -3.2842910189007879e-01 + 43 5.4671499454984129e-01 -4.1359175442160705e+00 -1.8207740535793673e-01 + 44 2.9266008103038210e+00 -3.6068419804864162e+00 1.2113363596827287e+00 + 45 1.8852873543332879e-01 2.0862322450867476e+00 -2.2746048462286219e+00 + 46 3.1050327756207385e-01 -6.8131822103738948e-01 3.3099599857084865e+00 + 47 1.5495643784665143e+00 4.7838931757231729e-01 1.7237903621133286e+00 + 48 -1.0044710103079835e-01 1.9268843643577696e+00 -7.8383576073070227e-02 + 49 -7.5032605988628709e-01 -4.2197737225953293e+00 -2.3776532103935031e+00 + 50 1.6605480572872100e-01 2.1347903400364157e+00 -1.0644591517660029e+00 + 51 -1.0044546762645661e+00 3.4523503888228460e+00 2.5759868763834439e+00 + 52 3.3060194272186938e+00 -4.1095446389475212e+00 4.4973693213048911e+00 + 53 2.0013241503011061e+00 2.1568842444962968e+00 5.8576907510814946e-01 + 54 2.2795507897178515e+00 -1.6689794713655517e+00 -1.2265506067291632e+00 + 55 1.4414345631525973e+00 -2.3308559065173378e+00 -2.6744299494180339e+00 + 56 -1.2975056485899017e+00 1.2610549989098470e+00 -1.8919017562855045e+00 + 57 4.4635450423847761e-01 -1.8891747786298547e+00 -7.3598594916024718e-02 + 58 1.8732023203115651e+00 -1.2871222078269409e+00 1.1034998112961891e+00 + 59 2.5191023566928026e+00 1.3386335071903244e+00 -1.3910367397923267e+00 + 60 -1.3827430344664839e+00 -4.7488532834440322e+00 -2.6077765026678685e+00 + 61 5.6154005053867961e-01 1.6367914021307668e+00 2.2225403413594336e-01 + 62 -2.7117320012918245e+00 2.0222828099298615e+00 -1.0992589926255694e+00 + 63 1.1817576812178225e+00 -3.4891322995415415e+00 1.2117401144494427e-01 + 64 1.9765285883417292e+00 2.0768686745001221e+00 5.0210256117812211e+00 +run_vdwl: -102.88630663875192 run_coul: 0 run_stress: ! |- - -2.1976112124103381e+01 -2.2120675059593967e+01 -2.2736028697191660e+01 -9.6838383640863732e+00 2.7960565626594452e+01 2.9565139447975581e+00 + -2.1976112124103434e+01 -2.2120675059593900e+01 -2.2736028697191710e+01 -9.6838383640863874e+00 2.7960565626594430e+01 2.9565139447975191e+00 run_forces: ! |2 - 1 -8.2928907389174800e-01 2.6325653168237597e+00 1.6455283675511336e+00 - 2 -2.2332848280699098e+00 -8.5105428623120738e-01 -2.2378966509481462e+00 - 3 4.0369022873323995e-01 -4.5292332026834525e-01 -4.6117125396617076e-01 - 4 -1.5392368366681055e+00 2.5836742219004307e+00 1.4866213787271727e+00 - 5 -7.0473215115198462e-01 -1.0635760940667160e+00 1.0942226301158597e-01 - 6 1.5819649596788963e+00 3.1431003510990916e+00 2.7247970443500191e-01 - 7 -8.8304300352667098e-01 -2.5512778253202795e-01 4.9061185303106492e-01 - 8 -7.5212662515965478e-02 3.8184021196914131e-01 -2.4107282446941858e-01 - 9 -8.1158381339754615e-02 -2.1476254109562842e+00 -1.6738060835548429e+00 - 10 2.6739139374368631e-01 -1.3595489108881318e+00 -1.9877911558077250e+00 - 11 2.8786464650632282e+00 -3.1444207672765661e+00 1.7595851785110754e+00 - 12 -5.1607144125813420e+00 -3.0505635395731572e+00 -2.5663556019991880e+00 - 13 -9.5218249672773658e-01 5.1068327597016960e+00 -5.8594717769482718e-02 - 14 -1.3173839151099331e+00 3.2572743003293345e+00 -3.1725961245082179e-01 - 15 -3.0209968254234791e+00 2.8556138462073033e+00 -2.3721062599278038e+00 - 16 1.2216389778733623e+00 8.8782172928552650e-01 4.9460287363958439e+00 - 17 5.0665401626634665e-01 2.6065123676788002e+00 -3.6572621755786723e+00 - 18 8.0560082005674039e-01 1.7784443143431039e-01 3.0708425303505242e+00 - 19 -1.3130648174442099e+00 -2.4049562879242599e+00 -5.9798277275158895e-01 - 20 -5.5003890970086431e+00 4.2569363932569165e-01 8.2096048756974138e-01 - 21 1.9583117745178971e+00 3.1676077641277089e-01 -2.0010367607187307e+00 - 22 -5.3782300500239106e+00 2.7954251058532851e+00 -3.4849823165113722e+00 - 23 -6.9051290513228092e-01 1.7324097820905555e+00 1.8656696660166405e+00 - 24 1.0579198267435741e+00 2.7853782129568909e+00 1.5603367091482048e+00 - 25 8.5874832624451036e-01 -1.7002486393146604e-01 1.4197740747130343e+00 - 26 -6.1775651781646257e-01 -8.4257119820718573e-01 3.7388380056589404e-01 - 27 1.7623463963448633e+00 -9.9354238242365334e-01 1.0110685126053154e+00 - 28 1.4193733470738314e+00 8.1015999185641474e-01 4.0821004813182125e+00 - 29 -1.6859151458223569e+00 3.1541062526510977e-01 -1.9250490296611780e+00 - 30 -1.3973422008752046e-01 1.9763237734759858e+00 -7.7445674509188089e-01 - 31 -7.7767063241113066e-01 1.2364953391884987e+00 -9.6957454920708874e-01 - 32 -2.9270733416295300e+00 -2.4270762795162515e-01 -1.3071450818376427e+00 - 33 4.0910389624152463e+00 -2.1992798649239882e+00 2.3441501919110235e+00 - 34 -5.5252855074094653e-01 -5.1754953667376968e-01 4.5476750785742548e-01 - 35 6.5679903128682637e-01 -4.3384313669203550e-01 2.3020978443930540e+00 - 36 4.1071528470453234e-01 -1.9426423465248290e+00 -3.0227836648613948e-01 - 37 -1.1800352185266187e+00 1.5115663414777891e+00 -2.0145348898879654e+00 - 38 8.0863765118629871e-01 -6.2601029460599156e-01 2.2604437645930608e-01 - 39 9.0595391391512536e-01 -8.6453019059818215e-01 -3.0825022954203249e+00 - 40 2.8910511690578957e+00 -9.9304764149802571e-01 -9.7028813321576568e-01 - 41 2.3576231848917817e-01 8.3058105340779065e-02 -3.5051100914776356e-01 - 42 -3.1800149002647635e+00 -1.4801218321079967e+00 -3.4939613462705732e-01 - 43 5.3438430014286320e-01 -4.1254150427656411e+00 -1.9277595501740344e-01 - 44 2.9343930193092742e+00 -3.6039709656946148e+00 1.2044564920566443e+00 - 45 1.6277597014744849e-01 2.0604496639613474e+00 -2.2638998549421463e+00 - 46 2.9983573330855845e-01 -6.7843418740863404e-01 3.3353145685585344e+00 - 47 1.5634801627108743e+00 4.8214593664222316e-01 1.7100505686438834e+00 - 48 -8.3906105082361959e-02 1.9304713818450885e+00 -8.3812015887967162e-02 - 49 -7.8979636683125953e-01 -4.2585478453255936e+00 -2.4144301914148301e+00 - 50 1.7300163937082269e-01 2.1296234182507194e+00 -1.0768825899372374e+00 - 51 -1.0406604933510912e+00 3.4818747345114609e+00 2.5791884839408641e+00 - 52 3.3194817589169796e+00 -4.1027033529151336e+00 4.5046480939694513e+00 - 53 2.0294540274748609e+00 2.1853637373905008e+00 6.4245186153892442e-01 - 54 2.2771404377390034e+00 -1.6664001034755751e+00 -1.2118966400733897e+00 - 55 1.4338268965133238e+00 -2.3320008553509282e+00 -2.6364737369251454e+00 - 56 -1.2965342194582345e+00 1.2428509252727042e+00 -1.8883258466962363e+00 - 57 4.3952750262408874e-01 -1.9156058347182991e+00 -7.8543802781213368e-02 - 58 1.8765385567796204e+00 -1.2672717375405131e+00 1.0828240486180201e+00 - 59 2.5418882730334671e+00 1.3543932883696401e+00 -1.3969143290366981e+00 - 60 -1.4187287649587188e+00 -4.7767586078518711e+00 -2.6433630359859794e+00 - 61 5.7641865518569202e-01 1.6484372040093276e+00 2.3389519515043916e-01 + 1 -8.2928907389174666e-01 2.6325653168237588e+00 1.6455283675511345e+00 + 2 -2.2332848280699098e+00 -8.5105428623120560e-01 -2.2378966509481453e+00 + 3 4.0369022873324084e-01 -4.5292332026834647e-01 -4.6117125396616998e-01 + 4 -1.5392368366681060e+00 2.5836742219004303e+00 1.4866213787271731e+00 + 5 -7.0473215115198351e-01 -1.0635760940667156e+00 1.0942226301158375e-01 + 6 1.5819649596788969e+00 3.1431003510990903e+00 2.7247970443500363e-01 + 7 -8.8304300352666831e-01 -2.5512778253202767e-01 4.9061185303106414e-01 + 8 -7.5212662515966588e-02 3.8184021196914064e-01 -2.4107282446941838e-01 + 9 -8.1158381339756724e-02 -2.1476254109562851e+00 -1.6738060835548427e+00 + 10 2.6739139374368553e-01 -1.3595489108881336e+00 -1.9877911558077259e+00 + 11 2.8786464650632277e+00 -3.1444207672765674e+00 1.7595851785110765e+00 + 12 -5.1607144125813420e+00 -3.0505635395731581e+00 -2.5663556019991889e+00 + 13 -9.5218249672773780e-01 5.1068327597016960e+00 -5.8594717769481663e-02 + 14 -1.3173839151099322e+00 3.2572743003293363e+00 -3.1725961245082268e-01 + 15 -3.0209968254234782e+00 2.8556138462073033e+00 -2.3721062599278016e+00 + 16 1.2216389778733616e+00 8.8782172928552516e-01 4.9460287363958457e+00 + 17 5.0665401626634887e-01 2.6065123676788029e+00 -3.6572621755786727e+00 + 18 8.0560082005674027e-01 1.7784443143430906e-01 3.0708425303505233e+00 + 19 -1.3130648174442086e+00 -2.4049562879242590e+00 -5.9798277275158851e-01 + 20 -5.5003890970086413e+00 4.2569363932568910e-01 8.2096048756973983e-01 + 21 1.9583117745178966e+00 3.1676077641277089e-01 -2.0010367607187303e+00 + 22 -5.3782300500239124e+00 2.7954251058532886e+00 -3.4849823165113714e+00 + 23 -6.9051290513228203e-01 1.7324097820905564e+00 1.8656696660166401e+00 + 24 1.0579198267435768e+00 2.7853782129568914e+00 1.5603367091482048e+00 + 25 8.5874832624450970e-01 -1.7002486393146504e-01 1.4197740747130334e+00 + 26 -6.1775651781646423e-01 -8.4257119820718462e-01 3.7388380056589238e-01 + 27 1.7623463963448620e+00 -9.9354238242365378e-01 1.0110685126053180e+00 + 28 1.4193733470738314e+00 8.1015999185641341e-01 4.0821004813182107e+00 + 29 -1.6859151458223580e+00 3.1541062526510955e-01 -1.9250490296611780e+00 + 30 -1.3973422008752034e-01 1.9763237734759880e+00 -7.7445674509188067e-01 + 31 -7.7767063241113155e-01 1.2364953391885003e+00 -9.6957454920708985e-01 + 32 -2.9270733416295287e+00 -2.4270762795162470e-01 -1.3071450818376427e+00 + 33 4.0910389624152446e+00 -2.1992798649239882e+00 2.3441501919110208e+00 + 34 -5.5252855074094764e-01 -5.1754953667376880e-01 4.5476750785742470e-01 + 35 6.5679903128682582e-01 -4.3384313669203151e-01 2.3020978443930513e+00 + 36 4.1071528470452945e-01 -1.9426423465248281e+00 -3.0227836648614037e-01 + 37 -1.1800352185266161e+00 1.5115663414777876e+00 -2.0145348898879649e+00 + 38 8.0863765118629882e-01 -6.2601029460599156e-01 2.2604437645930697e-01 + 39 9.0595391391512492e-01 -8.6453019059818192e-01 -3.0825022954203249e+00 + 40 2.8910511690578962e+00 -9.9304764149802682e-01 -9.7028813321576612e-01 + 41 2.3576231848917817e-01 8.3058105340779759e-02 -3.5051100914776290e-01 + 42 -3.1800149002647617e+00 -1.4801218321079943e+00 -3.4939613462705377e-01 + 43 5.3438430014286398e-01 -4.1254150427656375e+00 -1.9277595501740161e-01 + 44 2.9343930193092733e+00 -3.6039709656946148e+00 1.2044564920566434e+00 + 45 1.6277597014744849e-01 2.0604496639613448e+00 -2.2638998549421476e+00 + 46 2.9983573330855590e-01 -6.7843418740863848e-01 3.3353145685585326e+00 + 47 1.5634801627108725e+00 4.8214593664222383e-01 1.7100505686438816e+00 + 48 -8.3906105082362181e-02 1.9304713818450892e+00 -8.3812015887966052e-02 + 49 -7.8979636683125931e-01 -4.2585478453255945e+00 -2.4144301914148287e+00 + 50 1.7300163937082402e-01 2.1296234182507190e+00 -1.0768825899372381e+00 + 51 -1.0406604933510937e+00 3.4818747345114645e+00 2.5791884839408650e+00 + 52 3.3194817589169814e+00 -4.1027033529151344e+00 4.5046480939694504e+00 + 53 2.0294540274748623e+00 2.1853637373905004e+00 6.4245186153892631e-01 + 54 2.2771404377390008e+00 -1.6664001034755755e+00 -1.2118966400733884e+00 + 55 1.4338268965133218e+00 -2.3320008553509264e+00 -2.6364737369251441e+00 + 56 -1.2965342194582348e+00 1.2428509252727051e+00 -1.8883258466962369e+00 + 57 4.3952750262408985e-01 -1.9156058347182994e+00 -7.8543802781214200e-02 + 58 1.8765385567796200e+00 -1.2672717375405127e+00 1.0828240486180201e+00 + 59 2.5418882730334689e+00 1.3543932883696401e+00 -1.3969143290366983e+00 + 60 -1.4187287649587170e+00 -4.7767586078518711e+00 -2.6433630359859754e+00 + 61 5.7641865518569269e-01 1.6484372040093282e+00 2.3389519515043727e-01 62 -2.7071779218109575e+00 2.0159966095690671e+00 -1.0872338761779961e+00 - 63 1.1764921309976299e+00 -3.5078075687694996e+00 9.5738583931291754e-02 - 64 2.0160799277578452e+00 2.1172152881764932e+00 5.0470647349337190e+00 + 63 1.1764921309976299e+00 -3.5078075687695001e+00 9.5738583931291338e-02 + 64 2.0160799277578452e+00 2.1172152881764905e+00 5.0470647349337163e+00 ... diff --git a/unittest/force-styles/tests/manybody-pair-sw-mod-multi.yaml b/unittest/force-styles/tests/manybody-pair-sw-mod-multi.yaml index 206140428e..17859b7ce9 100644 --- a/unittest/force-styles/tests/manybody-pair-sw-mod-multi.yaml +++ b/unittest/force-styles/tests/manybody-pair-sw-mod-multi.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 27 Oct 2021 -date_generated: Fri Dec 3 17:00:11 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:49 2022 epsilon: 2e-08 skip_tests: prerequisites: ! | @@ -15,142 +15,142 @@ pair_coeff: ! | * * CdTe.sw Cd Cd Cd Cd Te Te Te Te extract: ! "" natoms: 64 -init_vdwl: -102.37263341910496 +init_vdwl: -102.37263341910493 init_coul: 0 init_stress: ! |- - -1.9299390308487332e+01 -1.8776425549919630e+01 -1.9374721168707158e+01 -9.9622288974183402e+00 2.8070027242773669e+01 2.3879337940188838e+00 + -1.9299390308487339e+01 -1.8776425549919587e+01 -1.9374721168707101e+01 -9.9622288974183739e+00 2.8070027242773669e+01 2.3879337940188696e+00 init_forces: ! |2 - 1 -8.3352103982839498e-01 2.6013559482542927e+00 1.6274474572425128e+00 - 2 -2.2306493745023439e+00 -8.0714318418132680e-01 -2.1923062020153332e+00 - 3 4.2806028767962845e-01 -4.3590991678773050e-01 -5.0075218062879157e-01 - 4 -1.5656435682231125e+00 2.5915183820303294e+00 1.5040666120009878e+00 - 5 -6.9060643334495364e-01 -1.0647727077215563e+00 1.0180213728505660e-01 - 6 1.5642465056067236e+00 3.1396473681405714e+00 2.3641961557945523e-01 - 7 -8.6200824722768510e-01 -3.1293943422778392e-01 5.8408431260171700e-01 - 8 -4.0266618929934772e-02 3.9766986295109796e-01 -2.5739252841289817e-01 - 9 -1.0121360928146172e-01 -2.1107078034640070e+00 -1.6464009666060164e+00 - 10 2.0923890660303709e-01 -1.3484233420079106e+00 -2.0722655526356872e+00 - 11 2.8965107909852348e+00 -3.1744989269831745e+00 1.7652663534808954e+00 - 12 -5.1795645231077438e+00 -3.1197777091864247e+00 -2.5665483054724385e+00 - 13 -9.7590684648521742e-01 5.1280259109893711e+00 -5.5091662114447909e-02 - 14 -1.3011518617770772e+00 3.2310626778618188e+00 -2.7215049371394051e-01 - 15 -3.0223115829476974e+00 2.8683423075628229e+00 -2.3758062762116352e+00 - 16 1.2188823395097397e+00 8.8545767129801856e-01 4.9357502869058907e+00 - 17 5.1082190544309336e-01 2.5961893628174249e+00 -3.6899394789612989e+00 - 18 8.0983992795309412e-01 1.9375641754963246e-01 3.0453558733140791e+00 - 19 -1.2881034138735021e+00 -2.3462670937269570e+00 -5.7655943278877531e-01 - 20 -5.5246134474571544e+00 4.3796064198379042e-01 7.8520754182924590e-01 - 21 1.9857375817468936e+00 3.5747034616111240e-01 -1.9976772359481998e+00 - 22 -5.3994091163314843e+00 2.7697124407401645e+00 -3.4667596880338745e+00 - 23 -6.7698775959152468e-01 1.7121888767603168e+00 1.8605652911619057e+00 - 24 1.0074715305644579e+00 2.7727617131893907e+00 1.6044473510176775e+00 - 25 8.2109744647411587e-01 -1.5951683209098438e-01 1.4578611299506363e+00 - 26 -6.0985382802125121e-01 -8.4244274451098200e-01 3.8129622162861987e-01 - 27 1.7520729823657701e+00 -9.7201192812768278e-01 1.0169775017077374e+00 - 28 1.4567082595385197e+00 7.8409740218617241e-01 4.0820526290440693e+00 - 29 -1.7032244062520407e+00 3.7587845180749746e-01 -1.8870964181160801e+00 - 30 -1.3206923648228786e-01 1.9916921471681335e+00 -7.8266372777153881e-01 - 31 -7.8806468309443956e-01 1.2340219176128437e+00 -9.6478187359875445e-01 - 32 -2.9476314789446243e+00 -2.3142140109749620e-01 -1.2913087888283064e+00 - 33 4.0628274986014370e+00 -2.1640961259319633e+00 2.3152290236418862e+00 - 34 -5.0178399673773300e-01 -5.0822695167360177e-01 4.4034006759355204e-01 - 35 6.4819559167223217e-01 -4.2103249402438037e-01 2.2856297398167160e+00 - 36 4.2421336892938027e-01 -1.9510682132362911e+00 -2.6576967318516032e-01 - 37 -1.1978825491980216e+00 1.4979581672416948e+00 -2.0147839781766854e+00 - 38 7.9840064761631246e-01 -6.3065633736217053e-01 2.2172788022363643e-01 - 39 9.5635170423204818e-01 -8.6585579126154955e-01 -3.1052170761751845e+00 - 40 2.8672098888058200e+00 -9.9651196656937779e-01 -9.5239701218087292e-01 - 41 2.4852080673692367e-01 6.1726598770146912e-02 -3.7738320667014214e-01 - 42 -3.2218924503111612e+00 -1.4679079242785487e+00 -3.2494955620470956e-01 - 43 5.5403553802134953e-01 -4.1887392096585874e+00 -2.0482127921175985e-01 - 44 2.9555129785833429e+00 -3.6105937273033035e+00 1.2015248443434716e+00 - 45 1.7770090288772786e-01 2.0291936769513712e+00 -2.2821357561478952e+00 - 46 3.0098477582343552e-01 -6.8109426553535413e-01 3.3143127536166697e+00 - 47 1.5621226433495043e+00 4.7692718861141892e-01 1.7210568305854430e+00 - 48 -9.4768998301996810e-02 1.9291106542258933e+00 -7.9898001163940746e-02 - 49 -7.5069898580068450e-01 -4.2258133032514049e+00 -2.3812996182822603e+00 - 50 1.4134224367113424e-01 2.1242374172137017e+00 -1.0801323306863431e+00 - 51 -1.0169916443243892e+00 3.4297591336369639e+00 2.6194829051700457e+00 - 52 3.2885617409945218e+00 -4.1236212282526887e+00 4.4781707305337832e+00 - 53 2.0148028372670694e+00 2.1448816982248586e+00 5.9971419207432852e-01 - 54 2.2814655737302960e+00 -1.7087786381643948e+00 -1.2499084070436326e+00 - 55 1.4210474600591452e+00 -2.3307737663036989e+00 -2.6810090164064904e+00 - 56 -1.2621087881539996e+00 1.2649871800389936e+00 -1.8926645655164065e+00 - 57 4.5797130534627017e-01 -1.8664838112748443e+00 -7.9083437859934921e-02 - 58 1.8947653213983979e+00 -1.2696890878445555e+00 1.1075578262554551e+00 - 59 2.5504370125908418e+00 1.3745174666515754e+00 -1.4107516734366936e+00 - 60 -1.3722628021690451e+00 -4.7890295934897642e+00 -2.6044795996416212e+00 - 61 5.5504118471845243e-01 1.6638732597224004e+00 1.9102194016740037e-01 - 62 -2.7251879924223230e+00 2.0619085257720378e+00 -1.0935823576664374e+00 - 63 1.2081746380050724e+00 -3.4948111236780761e+00 1.2168350620299762e-01 - 64 1.9860051556122582e+00 2.0927257690827177e+00 5.0697148025383179e+00 + 1 -8.3352103982839543e-01 2.6013559482542941e+00 1.6274474572425111e+00 + 2 -2.2306493745023448e+00 -8.0714318418132613e-01 -2.1923062020153337e+00 + 3 4.2806028767962823e-01 -4.3590991678773006e-01 -5.0075218062879145e-01 + 4 -1.5656435682231120e+00 2.5915183820303294e+00 1.5040666120009860e+00 + 5 -6.9060643334495198e-01 -1.0647727077215574e+00 1.0180213728505660e-01 + 6 1.5642465056067227e+00 3.1396473681405741e+00 2.3641961557945554e-01 + 7 -8.6200824722768510e-01 -3.1293943422778392e-01 5.8408431260171767e-01 + 8 -4.0266618929934772e-02 3.9766986295109752e-01 -2.5739252841289761e-01 + 9 -1.0121360928146328e-01 -2.1107078034640070e+00 -1.6464009666060169e+00 + 10 2.0923890660303610e-01 -1.3484233420079097e+00 -2.0722655526356872e+00 + 11 2.8965107909852348e+00 -3.1744989269831758e+00 1.7652663534808974e+00 + 12 -5.1795645231077430e+00 -3.1197777091864252e+00 -2.5665483054724403e+00 + 13 -9.7590684648521719e-01 5.1280259109893702e+00 -5.5091662114448797e-02 + 14 -1.3011518617770770e+00 3.2310626778618183e+00 -2.7215049371393990e-01 + 15 -3.0223115829477001e+00 2.8683423075628256e+00 -2.3758062762116374e+00 + 16 1.2188823395097392e+00 8.8545767129801844e-01 4.9357502869058898e+00 + 17 5.1082190544309225e-01 2.5961893628174231e+00 -3.6899394789613011e+00 + 18 8.0983992795309323e-01 1.9375641754963357e-01 3.0453558733140791e+00 + 19 -1.2881034138734995e+00 -2.3462670937269565e+00 -5.7655943278877242e-01 + 20 -5.5246134474571544e+00 4.3796064198378926e-01 7.8520754182924446e-01 + 21 1.9857375817468945e+00 3.5747034616111328e-01 -1.9976772359482011e+00 + 22 -5.3994091163314835e+00 2.7697124407401645e+00 -3.4667596880338722e+00 + 23 -6.7698775959152557e-01 1.7121888767603142e+00 1.8605652911619039e+00 + 24 1.0074715305644597e+00 2.7727617131893911e+00 1.6044473510176749e+00 + 25 8.2109744647411742e-01 -1.5951683209098694e-01 1.4578611299506359e+00 + 26 -6.0985382802125132e-01 -8.4244274451098200e-01 3.8129622162861965e-01 + 27 1.7520729823657692e+00 -9.7201192812768344e-01 1.0169775017077392e+00 + 28 1.4567082595385221e+00 7.8409740218617474e-01 4.0820526290440675e+00 + 29 -1.7032244062520421e+00 3.7587845180749702e-01 -1.8870964181160792e+00 + 30 -1.3206923648228763e-01 1.9916921471681348e+00 -7.8266372777153936e-01 + 31 -7.8806468309443956e-01 1.2340219176128437e+00 -9.6478187359875323e-01 + 32 -2.9476314789446256e+00 -2.3142140109749709e-01 -1.2913087888283057e+00 + 33 4.0628274986014397e+00 -2.1640961259319642e+00 2.3152290236418884e+00 + 34 -5.0178399673773511e-01 -5.0822695167360288e-01 4.4034006759355326e-01 + 35 6.4819559167223373e-01 -4.2103249402438392e-01 2.2856297398167156e+00 + 36 4.2421336892938272e-01 -1.9510682132362913e+00 -2.6576967318515970e-01 + 37 -1.1978825491980221e+00 1.4979581672416944e+00 -2.0147839781766868e+00 + 38 7.9840064761631258e-01 -6.3065633736217086e-01 2.2172788022363821e-01 + 39 9.5635170423204996e-01 -8.6585579126154888e-01 -3.1052170761751818e+00 + 40 2.8672098888058168e+00 -9.9651196656937635e-01 -9.5239701218087147e-01 + 41 2.4852080673692301e-01 6.1726598770146024e-02 -3.7738320667014291e-01 + 42 -3.2218924503111621e+00 -1.4679079242785489e+00 -3.2494955620470856e-01 + 43 5.5403553802134631e-01 -4.1887392096585865e+00 -2.0482127921176313e-01 + 44 2.9555129785833434e+00 -3.6105937273033026e+00 1.2015248443434732e+00 + 45 1.7770090288773110e-01 2.0291936769513708e+00 -2.2821357561478943e+00 + 46 3.0098477582343630e-01 -6.8109426553535390e-01 3.3143127536166697e+00 + 47 1.5621226433495066e+00 4.7692718861142158e-01 1.7210568305854446e+00 + 48 -9.4768998301996810e-02 1.9291106542258913e+00 -7.9898001163943189e-02 + 49 -7.5069898580068672e-01 -4.2258133032514085e+00 -2.3812996182822639e+00 + 50 1.4134224367113335e-01 2.1242374172137009e+00 -1.0801323306863440e+00 + 51 -1.0169916443243863e+00 3.4297591336369622e+00 2.6194829051700448e+00 + 52 3.2885617409945209e+00 -4.1236212282526887e+00 4.4781707305337823e+00 + 53 2.0148028372670703e+00 2.1448816982248622e+00 5.9971419207433097e-01 + 54 2.2814655737302978e+00 -1.7087786381643943e+00 -1.2499084070436322e+00 + 55 1.4210474600591421e+00 -2.3307737663036963e+00 -2.6810090164064895e+00 + 56 -1.2621087881539992e+00 1.2649871800389945e+00 -1.8926645655164047e+00 + 57 4.5797130534626862e-01 -1.8664838112748443e+00 -7.9083437859936739e-02 + 58 1.8947653213983977e+00 -1.2696890878445537e+00 1.1075578262554537e+00 + 59 2.5504370125908413e+00 1.3745174666515765e+00 -1.4107516734366909e+00 + 60 -1.3722628021690455e+00 -4.7890295934897660e+00 -2.6044795996416203e+00 + 61 5.5504118471845398e-01 1.6638732597224020e+00 1.9102194016740026e-01 + 62 -2.7251879924223239e+00 2.0619085257720382e+00 -1.0935823576664365e+00 + 63 1.2081746380050715e+00 -3.4948111236780757e+00 1.2168350620299700e-01 + 64 1.9860051556122571e+00 2.0927257690827168e+00 5.0697148025383170e+00 run_vdwl: -102.35973334868544 run_coul: 0 run_stress: ! |- - -1.9328658030947810e+01 -1.8780379209045268e+01 -1.9346617077044971e+01 -9.9749666938435588e+00 2.8008437891372573e+01 2.7085184376387343e+00 + -1.9328658030947796e+01 -1.8780379209045236e+01 -1.9346617077044982e+01 -9.9749666938435126e+00 2.8008437891372566e+01 2.7085184376387583e+00 run_forces: ! |2 - 1 -8.3973414156161930e-01 2.6024806716939164e+00 1.6294489541587445e+00 - 2 -2.2332320674802562e+00 -8.3325867561653455e-01 -2.2006491222340316e+00 - 3 4.0201044172486750e-01 -4.2917790666562572e-01 -4.6948321345343524e-01 - 4 -1.5508368285261567e+00 2.6001283545145055e+00 1.4866238736909396e+00 - 5 -7.0283057803506777e-01 -1.0755813727224737e+00 1.1966810285587803e-01 - 6 1.6014945801277216e+00 3.1449315086117622e+00 2.6049037731194224e-01 - 7 -8.4515391346172386e-01 -2.9643376365236135e-01 5.5592808043879749e-01 - 8 -5.2718099427328857e-02 3.9189728118504363e-01 -2.5511789246187055e-01 - 9 -1.2645445343566819e-01 -2.1304729991357707e+00 -1.6522394141178478e+00 - 10 2.0170941449333582e-01 -1.3518767924960227e+00 -2.0322937623603781e+00 - 11 2.8651919448969720e+00 -3.1544674167965900e+00 1.7604480863567769e+00 - 12 -5.1795367535891712e+00 -3.1098019791862668e+00 -2.5538057436240353e+00 - 13 -9.3449291860999784e-01 5.1182059829377859e+00 -4.0298131228021977e-02 - 14 -1.3138769883562655e+00 3.2334706395375243e+00 -2.8705931823998737e-01 - 15 -3.0202933407782986e+00 2.8717678204148385e+00 -2.3669275791353264e+00 - 16 1.2183776352258253e+00 8.9127075127665278e-01 4.9384997662616144e+00 - 17 5.1004773227753764e-01 2.5996399633357181e+00 -3.6689206261060656e+00 - 18 7.7809167896759790e-01 2.1207144945670109e-01 3.0609488662886752e+00 - 19 -1.3130275117681316e+00 -2.3667134933940694e+00 -5.8981658972312290e-01 - 20 -5.5117978458785322e+00 4.2744430925502919e-01 7.6917505422068522e-01 - 21 1.9975555296768055e+00 3.3703612298365648e-01 -2.0175086154709017e+00 - 22 -5.3878913771259942e+00 2.7669546071116780e+00 -3.4936856927711784e+00 - 23 -6.7183695072627359e-01 1.7273496394998133e+00 1.8671408697513008e+00 - 24 1.0274178552169215e+00 2.7558227820998842e+00 1.5882174839506549e+00 - 25 8.2283419787093992e-01 -1.5447852836097220e-01 1.4391797038202698e+00 - 26 -6.2156011410459711e-01 -8.2796420305524143e-01 3.8090402705185117e-01 - 27 1.7601339367218041e+00 -9.9125729448376576e-01 1.0180273847746450e+00 - 28 1.4388092815122282e+00 8.0674679694088813e-01 4.0876648999036522e+00 - 29 -1.7046413611169287e+00 3.7321569413737288e-01 -1.8989219949625276e+00 - 30 -1.2074990763593707e-01 1.9792500368063586e+00 -7.8166413542349944e-01 - 31 -7.7332943322336511e-01 1.2315391616416569e+00 -9.6239548238557426e-01 - 32 -2.9277390618142722e+00 -2.5192574067961049e-01 -1.3037200813587058e+00 - 33 4.0477554035224355e+00 -2.1635774257779952e+00 2.3187668986584278e+00 - 34 -5.0676702793740924e-01 -5.1042867431712269e-01 4.4519935389270182e-01 - 35 6.5147883642558269e-01 -4.0559353423839967e-01 2.2844315670896309e+00 - 36 3.9390278045807725e-01 -1.9447574184680256e+00 -2.9115859619763695e-01 - 37 -1.1969835780313667e+00 1.5002434334384103e+00 -2.0143490185568584e+00 - 38 8.0676971272455089e-01 -6.3075876472442627e-01 2.2352527291923852e-01 - 39 9.4831126179927472e-01 -8.6162603556527295e-01 -3.1064360157753512e+00 - 40 2.8987316294754262e+00 -1.0047866832940338e+00 -9.6394435733480410e-01 - 41 2.6960650365945771e-01 9.2011029766347563e-02 -3.5329070420464370e-01 - 42 -3.2202934703067982e+00 -1.4801433334214229e+00 -3.4640704444773640e-01 - 43 5.4054911532485972e-01 -4.1773027513600249e+00 -2.1447817794737201e-01 - 44 2.9630449457388348e+00 -3.6072732024558061e+00 1.1944777942823346e+00 - 45 1.5144749481598813e-01 2.0033822312972123e+00 -2.2719544688472020e+00 - 46 2.9049655713441491e-01 -6.7867224645607704e-01 3.3387072833091955e+00 - 47 1.5754348928781643e+00 4.8101158180913595e-01 1.7080091216663373e+00 - 48 -7.7888189794370732e-02 1.9324741091956470e+00 -8.5274908698085294e-02 - 49 -7.9019684006595448e-01 -4.2648229814895942e+00 -2.4185384574896021e+00 - 50 1.4845949202981235e-01 2.1194430145066492e+00 -1.0924025593259503e+00 - 51 -1.0531897227887335e+00 3.4601296405944799e+00 2.6236602237569762e+00 - 52 3.3021855015483581e+00 -4.1172000553476273e+00 4.4848689387827374e+00 - 53 2.0437376661991382e+00 2.1726639093433144e+00 6.5674814327221342e-01 - 54 2.2800687253756191e+00 -1.7058539676012388e+00 -1.2353352851426578e+00 - 55 1.4138080148068077e+00 -2.3311510292486584e+00 -2.6435843933533452e+00 - 56 -1.2611495893710638e+00 1.2465439472263604e+00 -1.8894879732201839e+00 - 57 4.5173711499993979e-01 -1.8928474410809497e+00 -8.2753356735880912e-02 - 58 1.8971660771741441e+00 -1.2504810390672687e+00 1.0864490717872513e+00 - 59 2.5718616964408740e+00 1.3890721660300731e+00 -1.4168830433218909e+00 - 60 -1.4083227015617696e+00 -4.8165606065577791e+00 -2.6397173641387988e+00 - 61 5.6959342807188396e-01 1.6753227696902677e+00 2.0308480954757957e-01 - 62 -2.7207823332499634e+00 2.0545577417761192e+00 -1.0816801951719224e+00 - 63 1.2029071251954688e+00 -3.5148585644551131e+00 9.6902669182167084e-02 - 64 2.0245788952513477e+00 2.1340267730573288e+00 5.0949866359832177e+00 + 1 -8.3973414156161841e-01 2.6024806716939146e+00 1.6294489541587440e+00 + 2 -2.2332320674802557e+00 -8.3325867561653433e-01 -2.2006491222340321e+00 + 3 4.0201044172486972e-01 -4.2917790666562528e-01 -4.6948321345343547e-01 + 4 -1.5508368285261569e+00 2.6001283545145020e+00 1.4866238736909383e+00 + 5 -7.0283057803506777e-01 -1.0755813727224708e+00 1.1966810285587759e-01 + 6 1.6014945801277229e+00 3.1449315086117631e+00 2.6049037731194219e-01 + 7 -8.4515391346172253e-01 -2.9643376365236040e-01 5.5592808043879682e-01 + 8 -5.2718099427327303e-02 3.9189728118504430e-01 -2.5511789246187011e-01 + 9 -1.2645445343566719e-01 -2.1304729991357716e+00 -1.6522394141178474e+00 + 10 2.0170941449333490e-01 -1.3518767924960220e+00 -2.0322937623603763e+00 + 11 2.8651919448969694e+00 -3.1544674167965878e+00 1.7604480863567766e+00 + 12 -5.1795367535891703e+00 -3.1098019791862659e+00 -2.5538057436240353e+00 + 13 -9.3449291860999517e-01 5.1182059829377833e+00 -4.0298131228020340e-02 + 14 -1.3138769883562682e+00 3.2334706395375243e+00 -2.8705931823999215e-01 + 15 -3.0202933407783004e+00 2.8717678204148402e+00 -2.3669275791353286e+00 + 16 1.2183776352258282e+00 8.9127075127665434e-01 4.9384997662616126e+00 + 17 5.1004773227753497e-01 2.5996399633357155e+00 -3.6689206261060638e+00 + 18 7.7809167896759657e-01 2.1207144945670486e-01 3.0609488662886761e+00 + 19 -1.3130275117681327e+00 -2.3667134933940690e+00 -5.8981658972312156e-01 + 20 -5.5117978458785348e+00 4.2744430925503080e-01 7.6917505422068866e-01 + 21 1.9975555296768068e+00 3.3703612298365382e-01 -2.0175086154709021e+00 + 22 -5.3878913771259942e+00 2.7669546071116766e+00 -3.4936856927711766e+00 + 23 -6.7183695072627447e-01 1.7273496394998140e+00 1.8671408697512994e+00 + 24 1.0274178552169209e+00 2.7558227820998824e+00 1.5882174839506540e+00 + 25 8.2283419787093881e-01 -1.5447852836097042e-01 1.4391797038202696e+00 + 26 -6.2156011410459877e-01 -8.2796420305524066e-01 3.8090402705185195e-01 + 27 1.7601339367218027e+00 -9.9125729448376421e-01 1.0180273847746428e+00 + 28 1.4388092815122260e+00 8.0674679694088813e-01 4.0876648999036558e+00 + 29 -1.7046413611169255e+00 3.7321569413737121e-01 -1.8989219949625280e+00 + 30 -1.2074990763593729e-01 1.9792500368063612e+00 -7.8166413542349966e-01 + 31 -7.7332943322336434e-01 1.2315391616416562e+00 -9.6239548238557371e-01 + 32 -2.9277390618142722e+00 -2.5192574067961093e-01 -1.3037200813587055e+00 + 33 4.0477554035224363e+00 -2.1635774257779992e+00 2.3187668986584313e+00 + 34 -5.0676702793740935e-01 -5.1042867431712113e-01 4.4519935389270143e-01 + 35 6.5147883642558613e-01 -4.0559353423840233e-01 2.2844315670896305e+00 + 36 3.9390278045807658e-01 -1.9447574184680232e+00 -2.9115859619763607e-01 + 37 -1.1969835780313667e+00 1.5002434334384123e+00 -2.0143490185568598e+00 + 38 8.0676971272455045e-01 -6.3075876472442660e-01 2.2352527291923829e-01 + 39 9.4831126179927205e-01 -8.6162603556527029e-01 -3.1064360157753512e+00 + 40 2.8987316294754275e+00 -1.0047866832940355e+00 -9.6394435733480544e-01 + 41 2.6960650365945893e-01 9.2011029766348285e-02 -3.5329070420464370e-01 + 42 -3.2202934703067978e+00 -1.4801433334214229e+00 -3.4640704444773684e-01 + 43 5.4054911532485961e-01 -4.1773027513600276e+00 -2.1447817794737117e-01 + 44 2.9630449457388375e+00 -3.6072732024558087e+00 1.1944777942823359e+00 + 45 1.5144749481598738e-01 2.0033822312972136e+00 -2.2719544688472029e+00 + 46 2.9049655713441624e-01 -6.7867224645607827e-01 3.3387072833091969e+00 + 47 1.5754348928781634e+00 4.8101158180913750e-01 1.7080091216663382e+00 + 48 -7.7888189794370732e-02 1.9324741091956488e+00 -8.5274908698083296e-02 + 49 -7.9019684006595403e-01 -4.2648229814895942e+00 -2.4185384574896021e+00 + 50 1.4845949202981412e-01 2.1194430145066496e+00 -1.0924025593259514e+00 + 51 -1.0531897227887344e+00 3.4601296405944812e+00 2.6236602237569766e+00 + 52 3.3021855015483559e+00 -4.1172000553476273e+00 4.4848689387827374e+00 + 53 2.0437376661991378e+00 2.1726639093433140e+00 6.5674814327221398e-01 + 54 2.2800687253756182e+00 -1.7058539676012381e+00 -1.2353352851426578e+00 + 55 1.4138080148068115e+00 -2.3311510292486624e+00 -2.6435843933533478e+00 + 56 -1.2611495893710636e+00 1.2465439472263604e+00 -1.8894879732201826e+00 + 57 4.5173711499994024e-01 -1.8928474410809502e+00 -8.2753356735879247e-02 + 58 1.8971660771741432e+00 -1.2504810390672692e+00 1.0864490717872517e+00 + 59 2.5718616964408740e+00 1.3890721660300731e+00 -1.4168830433218926e+00 + 60 -1.4083227015617670e+00 -4.8165606065577782e+00 -2.6397173641387961e+00 + 61 5.6959342807188240e-01 1.6753227696902682e+00 2.0308480954757957e-01 + 62 -2.7207823332499634e+00 2.0545577417761187e+00 -1.0816801951719228e+00 + 63 1.2029071251954688e+00 -3.5148585644551145e+00 9.6902669182165918e-02 + 64 2.0245788952513473e+00 2.1340267730573284e+00 5.0949866359832150e+00 ... diff --git a/unittest/force-styles/tests/manybody-pair-sw-multi.yaml b/unittest/force-styles/tests/manybody-pair-sw-multi.yaml index a1be280af9..15607e31d0 100644 --- a/unittest/force-styles/tests/manybody-pair-sw-multi.yaml +++ b/unittest/force-styles/tests/manybody-pair-sw-multi.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:19 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:49 2022 epsilon: 2e-08 +skip_tests: prerequisites: ! | pair sw pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * CdTe.sw Cd Cd Cd Cd Te Te Te Te extract: ! "" natoms: 64 -init_vdwl: 26.7735450040197 +init_vdwl: 26.773545004019706 init_coul: 0 init_stress: ! |2- 9.2215589743259159e+02 9.2929136989037136e+02 9.3631381668759911e+02 -5.3594035381468430e+00 4.2951811491157862e+01 3.2493816047643775e-01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 -5.8762448689533544e+00 5.8942813011991326e+00 -4.1862202974892249e+00 63 6.2441950513095250e+00 -4.6853003614172328e+00 -7.1748142164134499e-02 64 3.3607381935199805e+00 3.2378383101927035e+00 8.2922830712908908e+00 -run_vdwl: 26.7375240198584 +run_vdwl: 26.73752401985839 run_coul: 0 run_stress: ! |2- 9.2206864114246116e+02 9.2921570510249978e+02 9.3635035039956881e+02 -5.4393597598180481e+00 4.2755527181283895e+01 6.4912801883099647e-01 diff --git a/unittest/force-styles/tests/manybody-pair-sw.yaml b/unittest/force-styles/tests/manybody-pair-sw.yaml index 92ac300c40..466b6460ce 100644 --- a/unittest/force-styles/tests/manybody-pair-sw.yaml +++ b/unittest/force-styles/tests/manybody-pair-sw.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:19 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:49 2022 epsilon: 1e-10 +skip_tests: prerequisites: ! | pair sw pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * Si.sw Si Si Si Si Si Si Si Si extract: ! "" natoms: 64 -init_vdwl: -253.88807485819 +init_vdwl: -253.88807485819012 init_coul: 0 init_stress: ! |2- 1.9118540952213486e+01 2.1487344330656981e+01 2.4127534372405634e+01 -5.5872970545726481e+00 2.8576061542049843e+01 2.3167027692912461e+00 @@ -83,7 +84,7 @@ init_forces: ! |2 62 -4.0082699844093890e+00 3.5694473660939119e+00 -2.3808957458290636e+00 63 2.3993184954990650e+00 -4.9641865732173134e+00 7.9872123640002823e-01 64 2.4085468400267187e+00 2.7768510607664063e+00 5.9581090618923707e+00 -run_vdwl: -253.883637392962 +run_vdwl: -253.88363739296167 run_coul: 0 run_stress: ! |2- 1.9082434599104968e+01 2.1474531423483540e+01 2.4194121198849512e+01 -5.6218148550674991e+00 2.8428833515697679e+01 2.5800210385074096e+00 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff.yaml b/unittest/force-styles/tests/manybody-pair-tersoff.yaml index 5876ba1b5d..1df552c043 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:20 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 2e-11 +skip_tests: prerequisites: ! | pair tersoff pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * SiC.tersoff Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -163.150573313048 +init_vdwl: -163.15057331304786 init_coul: 0 init_stress: ! |- -5.4897530176832686e+02 -5.4663450719170669e+02 -5.6139257517016438e+02 -1.4199304590474304e+01 -1.3994570965097115e+01 5.4389605871425204e+01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 3.0202286274163956e+00 -5.8173499219836611e-02 3.7893096308014762e-01 63 -6.1967102136017562e+00 -4.9695212866018759e+00 -5.2998409387882637e+00 64 5.1027628612149876e+00 5.3292269345077354e+00 -8.7272297575101980e+00 -run_vdwl: -163.22666341025 +run_vdwl: -163.2266634102495 run_coul: 0 run_stress: ! |- -5.4984932084942841e+02 -5.4747825264498306e+02 -5.6218018236834973e+02 -1.3192159297195806e+01 -1.3022347931562834e+01 5.4632816484748162e+01 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff_mod.yaml b/unittest/force-styles/tests/manybody-pair-tersoff_mod.yaml index 92fc41d7e6..5f86ad443e 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff_mod.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff_mod.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:20 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 5e-11 +skip_tests: prerequisites: ! | pair tersoff/mod pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * Si.tersoff.mod Si Si Si Si Si Si Si Si extract: ! "" natoms: 64 -init_vdwl: -271.724273648021 +init_vdwl: -271.7242736480211 init_coul: 0 init_stress: ! |2- 4.5327307609410205e+01 4.8520624491107647e+01 4.9902937603449239e+01 -9.5506101395831298e+00 3.2604807162960675e+01 3.7958926469664611e+00 @@ -83,7 +84,7 @@ init_forces: ! |2 62 -3.8148306661769911e+00 3.5439712709911046e+00 -2.7497767002061524e+00 63 2.2829467996296282e+00 -4.8025431165588621e+00 -4.2319407270880682e-01 64 3.5261103084670364e+00 3.7869432645771459e+00 5.8249511151439197e+00 -run_vdwl: -271.714376157296 +run_vdwl: -271.71437615729633 run_coul: 0 run_stress: ! |2- 4.5291635990231427e+01 4.8485451299856578e+01 5.0006323329447021e+01 -9.4533068028372274e+00 3.2503068989512613e+01 4.1820539511499151e+00 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff_mod_c.yaml b/unittest/force-styles/tests/manybody-pair-tersoff_mod_c.yaml index 0243e01df7..dc7239df84 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff_mod_c.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff_mod_c.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:20 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 1e-12 +skip_tests: prerequisites: ! | pair tersoff/mod/c pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * Si.tersoff.modc Si Si Si Si Si Si Si Si extract: ! "" natoms: 64 -init_vdwl: -270.221167046491 +init_vdwl: -270.22116704649113 init_coul: 0 init_stress: ! |2- 3.7721371080158455e+01 4.0406255097835910e+01 4.5487367411373455e+01 -4.8266606949370061e+00 4.8727889805432582e+01 1.1408515692636255e+01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 -4.7911545216150291e+00 4.3378864433672462e+00 -2.6608977921209904e+00 63 3.8818660647417804e+00 -6.6892167616182157e+00 6.9165485826786188e-01 64 5.1815592623345070e+00 6.0301829566070033e+00 1.0737893845502111e+01 -run_vdwl: -270.224607668554 +run_vdwl: -270.22460766855363 run_coul: 0 run_stress: ! |2- 3.7674451362255247e+01 4.0326697108038395e+01 4.5577845337707821e+01 -4.6735158236852925e+00 4.8643168908345814e+01 1.1894000727069669e+01 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff_mod_c_shift.yaml b/unittest/force-styles/tests/manybody-pair-tersoff_mod_c_shift.yaml index 2580778581..dec7b51035 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff_mod_c_shift.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff_mod_c_shift.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:20 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 2e-11 skip_tests: intel prerequisites: ! | @@ -15,7 +15,7 @@ pair_coeff: ! | * * Si.tersoff.modc Si Si Si Si Si Si Si Si extract: ! "" natoms: 64 -init_vdwl: -270.144069879548 +init_vdwl: -270.14406987954806 init_coul: 0 init_stress: ! |2- 3.9009683820158699e+01 4.1712442670553941e+01 4.6810691626449191e+01 -4.8650488078636389e+00 4.8866660639888494e+01 1.1391803040419603e+01 @@ -84,7 +84,7 @@ init_forces: ! |2 62 -4.7979190616865797e+00 4.3434102172669791e+00 -2.6756525986102213e+00 63 3.8865402117110119e+00 -6.6984406381466162e+00 6.8155291040779375e-01 64 5.1963330181467731e+00 6.0468262093154790e+00 1.0756287747499645e+01 -run_vdwl: -270.147719451179 +run_vdwl: -270.14771945117906 run_coul: 0 run_stress: ! |2- 3.8962163987527319e+01 4.1632267398787846e+01 4.6901025481128798e+01 -4.7107503318061195e+00 4.8780605963278717e+01 1.1878434080817474e+01 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff_mod_shift.yaml b/unittest/force-styles/tests/manybody-pair-tersoff_mod_shift.yaml index 34706e4b25..974ebe772d 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff_mod_shift.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff_mod_shift.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:20 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 5e-11 skip_tests: gpu intel kokkos_omp prerequisites: ! | @@ -15,7 +15,7 @@ pair_coeff: ! | * * Si.tersoff.mod Si Si Si Si Si Si Si Si extract: ! "" natoms: 64 -init_vdwl: -271.644724447578 +init_vdwl: -271.6447244475782 init_coul: 0 init_stress: ! |2- 4.6467578511150705e+01 4.9672630447521129e+01 5.1076156386253835e+01 -9.5884521777215621e+00 3.2774050937983333e+01 3.8044769072311828e+00 @@ -84,7 +84,7 @@ init_forces: ! |2 62 -3.8279995879243911e+00 3.5559990162835984e+00 -2.7587797996461734e+00 63 2.2925741055557665e+00 -4.8170901357946256e+00 -4.2697180042074612e-01 64 3.5383040133234429e+00 3.8000319548335781e+00 5.8513232008994622e+00 -run_vdwl: -271.634962995706 +run_vdwl: -271.63496299570556 run_coul: 0 run_stress: ! |2- 4.6431311675968516e+01 4.9637001235985352e+01 5.1179498373012819e+01 -9.4909738128374883e+00 3.2671491357535999e+01 4.1923374723671643e+00 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff_shift.yaml b/unittest/force-styles/tests/manybody-pair-tersoff_shift.yaml index 3d98f221b0..ccb227b76f 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff_shift.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff_shift.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:20 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 5e-13 skip_tests: gpu intel kokkos_omp prerequisites: ! | @@ -15,7 +15,7 @@ pair_coeff: ! | * * SiC.tersoff Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -163.865146267879 +init_vdwl: -163.86514626787942 init_coul: 0 init_stress: ! |- -5.5024582031400666e+02 -5.4774409204093763e+02 -5.6246628126776079e+02 -1.4924154780208189e+01 -1.3705992344344143e+01 5.3802808177851460e+01 @@ -84,7 +84,7 @@ init_forces: ! |2 62 3.0682984262330577e+00 1.4731532775646095e-02 3.1837675172442315e-01 63 -6.1744135275042584e+00 -4.9438000546782721e+00 -5.2824439552248172e+00 64 5.0707719795244213e+00 5.2903461624479675e+00 -8.6920086960823717e+00 -run_vdwl: -163.941878707801 +run_vdwl: -163.94187870780107 run_coul: 0 run_stress: ! |- -5.5113750178835585e+02 -5.4860559540451356e+02 -5.6326696557728019e+02 -1.3916174964674051e+01 -1.2744121707845389e+01 5.4049884669345602e+01 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff_table.yaml b/unittest/force-styles/tests/manybody-pair-tersoff_table.yaml index 06b27e874f..d6770fcea0 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff_table.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff_table.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow, unstable -date_generated: Fri Feb 26 23:09:20 2021 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 9e-10 +skip_tests: prerequisites: ! | pair tersoff/table pre_commands: ! | @@ -15,7 +16,7 @@ pair_coeff: ! | * * SiC.tersoff Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -163.150900631379 +init_vdwl: -163.1509006313795 init_coul: 0 init_stress: ! |- -5.4897522008245971e+02 -5.4663587944021037e+02 -5.6139301217903756e+02 -1.4199635275715510e+01 -1.3994168950171279e+01 5.4390995854173852e+01 @@ -84,7 +85,7 @@ init_forces: ! |2 62 3.0207711149550320e+00 -5.7813674257257364e-02 3.7863400433938121e-01 63 -6.1967090156304634e+00 -4.9695164154437226e+00 -5.2998409073804016e+00 64 5.1027648459718051e+00 5.3292253828779392e+00 -8.7272294951206089e+00 -run_vdwl: -163.22697978934 +run_vdwl: -163.2269797893395 run_coul: 0 run_stress: ! |- -5.4984912642329925e+02 -5.4747889955989376e+02 -5.6218018956698495e+02 -1.3191983999982980e+01 -1.3022233748295864e+01 5.4633646266385000e+01 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff_zbl.yaml b/unittest/force-styles/tests/manybody-pair-tersoff_zbl.yaml index c1da0c1543..a6658cf1b7 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff_zbl.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff_zbl.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:20 2021 -epsilon: 5e-9 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 +epsilon: 5e-09 +skip_tests: prerequisites: ! | pair tersoff/zbl pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * SiC.tersoff.zbl Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -154.312424904672 +init_vdwl: -154.31242490467218 init_coul: 0 init_stress: ! |- -5.4522412416158102e+02 -5.4620277297655366e+02 -5.5815536323162701e+02 -1.7213270572024321e+01 -7.7594128912815021e+00 5.4428966311706304e+01 @@ -83,7 +84,7 @@ init_forces: ! |2 62 2.6584101684745818e+00 9.8218829465888779e-02 2.4244336018167600e-01 63 -5.8030976211176615e+00 -5.8640980265649096e+00 -4.9661385661230604e+00 64 5.1854732626889648e+00 5.4062029912491152e+00 -7.4682505070688574e+00 -run_vdwl: -154.378489848664 +run_vdwl: -154.37848984866412 run_coul: 0 run_stress: ! |- -5.4624007123172805e+02 -5.4721759715152484e+02 -5.5903048343882665e+02 -1.6221103215693166e+01 -6.7886936766953978e+00 5.4672709772731096e+01 diff --git a/unittest/force-styles/tests/manybody-pair-tersoff_zbl_shift.yaml b/unittest/force-styles/tests/manybody-pair-tersoff_zbl_shift.yaml index 1bf994e7b2..376abc67ca 100644 --- a/unittest/force-styles/tests/manybody-pair-tersoff_zbl_shift.yaml +++ b/unittest/force-styles/tests/manybody-pair-tersoff_zbl_shift.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 5e-11 skip_tests: gpu intel kokkos_omp prerequisites: ! | @@ -15,7 +15,7 @@ pair_coeff: ! | * * SiC.tersoff.zbl Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -155.022688586515 +init_vdwl: -155.0226885865147 init_coul: 0 init_stress: ! |- -5.4681450061751207e+02 -5.4765383545405757e+02 -5.5958816472819717e+02 -1.7937919946334258e+01 -7.4255270557571622e+00 5.3848489658845857e+01 @@ -84,7 +84,7 @@ init_forces: ! |2 62 2.7000283168511832e+00 1.6547621546223823e-01 1.8658485583726403e-01 63 -5.7748251912125133e+00 -5.8348082998315114e+00 -4.9427609042011902e+00 64 5.1516801198779412e+00 5.3652063468862412e+00 -7.4260492325704002e+00 -run_vdwl: -155.089673421163 +run_vdwl: -155.08967342116316 run_coul: 0 run_stress: ! |- -5.4785093620467512e+02 -5.4868766163134580e+02 -5.6047702088251935e+02 -1.6946060244607981e+01 -6.4660624450630184e+00 5.4095229901916355e+01 diff --git a/unittest/force-styles/tests/manybody-pair-vashishta.yaml b/unittest/force-styles/tests/manybody-pair-vashishta.yaml index 8f5e6373eb..f6085530bc 100644 --- a/unittest/force-styles/tests/manybody-pair-vashishta.yaml +++ b/unittest/force-styles/tests/manybody-pair-vashishta.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | pair vashishta pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * SiC.vashishta Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -313.692565300211 +init_vdwl: -313.69256530021073 init_coul: 0 init_stress: ! |- -1.6865844788070896e+02 -1.6802557677032220e+02 -1.7078202792877408e+02 1.2410655645813289e+00 -1.2389436818899767e+01 1.3028516323660728e+00 @@ -83,7 +84,7 @@ init_forces: ! |2 62 -2.6745936396158526e-01 2.8111058048742638e-01 1.6204295193993715e-01 63 3.3265811552668922e-01 -8.0829164437628798e-01 6.1676655388945945e-01 64 2.5167047246154373e-01 2.2796118436162449e-01 -1.2890847486936465e+00 -run_vdwl: -313.695868863151 +run_vdwl: -313.69586886315096 run_coul: 0 run_stress: ! |- -1.6862212687979553e+02 -1.6799875916220955e+02 -1.7076495599487473e+02 1.2756734851722502e+00 -1.2318626234293390e+01 1.2479663286743594e+00 diff --git a/unittest/force-styles/tests/manybody-pair-vashishta_table.yaml b/unittest/force-styles/tests/manybody-pair-vashishta_table.yaml index 466e9ff412..2598c9f88f 100644 --- a/unittest/force-styles/tests/manybody-pair-vashishta_table.yaml +++ b/unittest/force-styles/tests/manybody-pair-vashishta_table.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:09:21 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:50 2022 epsilon: 1e-12 +skip_tests: prerequisites: ! | pair vashishta/table pre_commands: ! | @@ -14,7 +15,7 @@ pair_coeff: ! | * * SiC.vashishta Si Si Si Si C C C C extract: ! "" natoms: 64 -init_vdwl: -313.692612242023 +init_vdwl: -313.69261224202336 init_coul: 0 init_stress: ! |- -1.6865842944245654e+02 -1.6802555802886161e+02 -1.7078200929565867e+02 1.2410702337908432e+00 -1.2389422965610184e+01 1.3028679521322537e+00 @@ -83,7 +84,7 @@ init_forces: ! |2 62 -2.6746099007558671e-01 2.8111186444558228e-01 1.6204174885500391e-01 63 3.3266077763541602e-01 -8.0829458064608550e-01 6.1676384476099411e-01 64 2.5167391424034580e-01 2.2796564437912092e-01 -1.2890802392853251e+00 -run_vdwl: -313.695921117013 +run_vdwl: -313.6959211170134 run_coul: 0 run_stress: ! |- -1.6862210702958757e+02 -1.6799873872591002e+02 -1.7076492974814965e+02 1.2756640884847943e+00 -1.2318605937818671e+01 1.2479616458786664e+00 diff --git a/unittest/force-styles/tests/mol-pair-beck.yaml b/unittest/force-styles/tests/mol-pair-beck.yaml index ca74372e4c..ac9b08078c 100644 --- a/unittest/force-styles/tests/mol-pair-beck.yaml +++ b/unittest/force-styles/tests/mol-pair-beck.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:38 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair beck @@ -28,7 +29,7 @@ pair_coeff: ! | 5 5 279437.56732576 78.2341704275754 3.13943017396948 5.20120131244272 1.00000000000006e-08 extract: ! "" natoms: 29 -init_vdwl: 190.036082315631 +init_vdwl: 190.03608231563146 init_coul: 0 init_stress: ! |2- 3.9653395125210380e+02 4.0062392946132519e+02 6.5568989225726875e+02 -8.0274562500806340e+01 3.9101921977574932e+01 7.1424156350717041e+01 @@ -62,7 +63,7 @@ init_forces: ! |2 27 9.4354114467686365e+00 -5.0365804752932377e+01 1.8995723437358020e+01 28 -3.8516188448751151e+01 1.6552971779437446e+01 -2.6060734296883002e+01 29 2.9089205657689586e+01 3.3820165138501068e+01 7.0599695508939604e+00 -run_vdwl: 189.570013008134 +run_vdwl: 189.57001300813437 run_coul: 0 run_stress: ! |2- 3.9673505063488938e+02 4.0042483718168398e+02 6.5281237313066970e+02 -7.9842085107845122e+01 3.9349940163427668e+01 7.1644334240795843e+01 diff --git a/unittest/force-styles/tests/mol-pair-born.yaml b/unittest/force-styles/tests/mol-pair-born.yaml index 11011100d1..95a1a79a55 100644 --- a/unittest/force-styles/tests/mol-pair-born.yaml +++ b/unittest/force-styles/tests/mol-pair-born.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:38 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair born @@ -30,7 +31,7 @@ extract: ! | c 2 d 2 natoms: 29 -init_vdwl: 225.01325775005 +init_vdwl: 225.0132577500503 init_coul: 0 init_stress: ! |2- 4.8890135912686276e+02 4.9476399950851692e+02 8.2928912031456082e+02 -1.0579437249928866e+02 4.4179413858812438e+01 9.5101960701751082e+01 @@ -64,7 +65,7 @@ init_forces: ! |2 27 1.1754339453870926e+01 -6.1391797882279533e+01 2.3297502014340736e+01 28 -4.7133554549788215e+01 2.0256243416311925e+01 -3.1891313669103603e+01 29 3.5387736817138148e+01 4.1142927584645129e+01 8.5887702016863265e+00 -run_vdwl: 224.209080812731 +run_vdwl: 224.20908081273063 run_coul: 0 run_stress: ! |2- 4.8883233519425096e+02 4.9423423364589024e+02 8.2442006134841051e+02 -1.0519543677321340e+02 4.4500721790869676e+01 9.5216321265483302e+01 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_dsf.yaml b/unittest/force-styles/tests/mol-pair-born_coul_dsf.yaml index 6280c9a9f3..467c8d59e6 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_dsf.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_dsf.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:38 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair born/coul/dsf @@ -27,8 +28,8 @@ pair_coeff: ! | 5 5 2.63841820292211 0.184008285863681 2.19742633928911 79.1465822481912 592.979935420722 extract: ! "" natoms: 29 -init_vdwl: 225.01325775005 -init_coul: -116.262182085427 +init_vdwl: 225.0132577500503 +init_coul: -116.26218208542673 init_stress: ! |2- 4.6548476353031594e+02 4.5051121181207020e+02 7.8830780607527242e+02 -1.0070292272125850e+02 3.7932502866866969e+01 1.0553864562325985e+02 init_forces: ! |2 @@ -61,8 +62,8 @@ init_forces: ! |2 27 9.4540809516248068e+00 -5.0442863407123852e+01 1.9202978230103980e+01 28 -4.2634181882990454e+01 1.5556514661238053e+01 -2.8124333709589369e+01 29 3.3595845049033741e+01 3.4856379135410293e+01 8.9087361003241199e+00 -run_vdwl: 224.239908258883 -run_coul: -116.285602012657 +run_vdwl: 224.23990825888316 +run_coul: -116.28560201265697 run_stress: ! |2- 4.6541486465261943e+02 4.5000181377675602e+02 7.8360788998458600e+02 -1.0010028697870388e+02 3.8217404146676770e+01 1.0558384978752369e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_dsf_cs.yaml b/unittest/force-styles/tests/mol-pair-born_coul_dsf_cs.yaml index fa49c094f3..f4e80551d7 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_dsf_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_dsf_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:39 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair born/coul/dsf/cs @@ -27,8 +28,8 @@ pair_coeff: ! | 5 5 2.63841820292211 0.184008285863681 2.19742633928911 79.1465822481912 592.979935420722 extract: ! "" natoms: 29 -init_vdwl: 225.01325775005 -init_coul: -116.262182085427 +init_vdwl: 225.0132577500503 +init_coul: -116.26218208542673 init_stress: ! |2- 4.6548476353031594e+02 4.5051121181207020e+02 7.8830780607527242e+02 -1.0070292272125850e+02 3.7932502866866969e+01 1.0553864562325985e+02 init_forces: ! |2 @@ -61,8 +62,8 @@ init_forces: ! |2 27 9.4540809516248068e+00 -5.0442863407123852e+01 1.9202978230103980e+01 28 -4.2634181882990454e+01 1.5556514661238053e+01 -2.8124333709589369e+01 29 3.3595845049033741e+01 3.4856379135410293e+01 8.9087361003241199e+00 -run_vdwl: 224.239908258883 -run_coul: -116.285602012657 +run_vdwl: 224.23990825888316 +run_coul: -116.28560201265697 run_stress: ! |2- 4.6541486465261943e+02 4.5000181377675602e+02 7.8360788998458600e+02 -1.0010028697870388e+02 3.8217404146676770e+01 1.0558384978752369e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_long.yaml b/unittest/force-styles/tests/mol-pair-born_coul_long.yaml index d46525ad6c..64f7f189fe 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:39 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair born/coul/long @@ -33,8 +34,8 @@ pair_coeff: ! | extract: ! | cut_coul 0 natoms: 29 -init_vdwl: 225.01325775005 -init_coul: 225.821815126925 +init_vdwl: 225.0132577500503 +init_coul: 225.82181512692495 init_stress: ! |2- 4.6612525076705970e+02 4.5192049348160413e+02 7.9054312633573579e+02 -1.0129685292097305e+02 3.7655412818406774e+01 1.0478181291601616e+02 init_forces: ! |2 @@ -67,8 +68,8 @@ init_forces: ! |2 27 9.7332846217867477e+00 -5.1358714846286986e+01 1.9618771137954440e+01 28 -4.2804238729856415e+01 1.6023907654535410e+01 -2.8346190173060055e+01 29 3.3466051778384887e+01 3.5333314670147345e+01 8.7040657727458015e+00 -run_vdwl: 224.238305263916 -run_coul: 225.801339422194 +run_vdwl: 224.23830526391563 +run_coul: 225.80133942219408 run_stress: ! |2- 4.6605249146168626e+02 4.5140738764070585e+02 7.8583111632678799e+02 -1.0069617899937634e+02 3.7937785898470828e+01 1.0482860432250801e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_long_cs.yaml b/unittest/force-styles/tests/mol-pair-born_coul_long_cs.yaml index 56de63afb8..60c1f17948 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_long_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_long_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:39 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair born/coul/long/cs @@ -33,8 +34,8 @@ pair_coeff: ! | extract: ! | cut_coul 0 natoms: 29 -init_vdwl: 225.01325774996 -init_coul: 225.8219568135 +init_vdwl: 225.0132577499601 +init_coul: 225.82195681349995 init_stress: ! |2- 4.6612532882394908e+02 4.5192052917396808e+02 7.9054319074939190e+02 -1.0129681492289940e+02 3.7655430569637737e+01 1.0478181489333996e+02 init_forces: ! |2 @@ -67,8 +68,8 @@ init_forces: ! |2 27 9.7332883747350500e+00 -5.1358738729048369e+01 1.9618779775225427e+01 28 -4.2804254672220495e+01 1.6023915870224371e+01 -2.8346201341747282e+01 29 3.3466063637323181e+01 3.5333330084781451e+01 8.7040684280919933e+00 -run_vdwl: 224.238305177817 -run_coul: 225.801481092243 +run_vdwl: 224.23830517781698 +run_coul: 225.80148109224274 run_stress: ! |2- 4.6605256944302278e+02 4.5140742319668550e+02 7.8583118030792753e+02 -1.0069614109154539e+02 3.7937803815401629e+01 1.0482860650436638e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_msm.yaml b/unittest/force-styles/tests/mol-pair-born_coul_msm.yaml index f664a72a21..37cfca5e11 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_msm.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_msm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:39 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair born/coul/msm @@ -34,8 +35,8 @@ pair_coeff: ! | extract: ! | cut_coul 0 natoms: 29 -init_vdwl: 225.009623463391 -init_coul: 114.131380823567 +init_vdwl: 225.00962346339065 +init_coul: 114.13138082356693 init_stress: ! |2- 4.6462918813446385e+02 4.4899642853749270e+02 7.8631555812755107e+02 -1.0022375678502866e+02 3.8087783960336296e+01 1.0611933533009946e+02 init_forces: ! |2 @@ -68,8 +69,8 @@ init_forces: ! |2 27 9.2127777588853803e+00 -4.9743145817451357e+01 1.8793705897680244e+01 28 -4.2446746701351501e+01 1.5146990306640154e+01 -2.7893182357714910e+01 29 3.3722087930502333e+01 3.4506742102964189e+01 9.1019508745580708e+00 -run_vdwl: 224.237652226166 -run_coul: 114.106006442906 +run_vdwl: 224.23765222616623 +run_coul: 114.10600644290636 run_stress: ! |2- 4.6456283590985373e+02 4.4849240500011121e+02 7.8162470384181984e+02 -9.9620431070851126e+01 3.8374186624871044e+01 1.0616278120291805e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_msm_table.yaml b/unittest/force-styles/tests/mol-pair-born_coul_msm_table.yaml index f25e04b008..18df82486a 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_msm_table.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_msm_table.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Fri Apr 2 15:14:43 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair born/coul/msm @@ -34,8 +35,8 @@ pair_coeff: ! | extract: ! | cut_coul 0 natoms: 29 -init_vdwl: 225.009623463391 -init_coul: 114.131380823567 +init_vdwl: 225.00962346339065 +init_coul: 114.13138082356693 init_stress: ! |2- 4.6462918813446385e+02 4.4899642853749270e+02 7.8631555812755107e+02 -1.0022375678502866e+02 3.8087783960336296e+01 1.0611933533009946e+02 init_forces: ! |2 @@ -68,8 +69,8 @@ init_forces: ! |2 27 9.2127777588853803e+00 -4.9743145817451357e+01 1.8793705897680244e+01 28 -4.2446746701351501e+01 1.5146990306640154e+01 -2.7893182357714910e+01 29 3.3722087930502333e+01 3.4506742102964189e+01 9.1019508745580708e+00 -run_vdwl: 224.237652226166 -run_coul: 114.106006442906 +run_vdwl: 224.23765222616623 +run_coul: 114.10600644290636 run_stress: ! |2- 4.6456283590985373e+02 4.4849240500011121e+02 7.8162470384181984e+02 -9.9620431070851126e+01 3.8374186624871044e+01 1.0616278120291805e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_table_cs.yaml b/unittest/force-styles/tests/mol-pair-born_coul_table_cs.yaml index d2ff07b2b8..a729bca8ad 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_table_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_table_cs.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:39 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 7.5e-14 skip_tests: gpu prerequisites: ! | @@ -34,8 +34,8 @@ pair_coeff: ! | extract: ! | cut_coul 0 natoms: 29 -init_vdwl: 225.013257749962 -init_coul: 225.821984927182 +init_vdwl: 225.0132577499623 +init_coul: 225.82198492718214 init_stress: ! |2- 4.6612535625392223e+02 4.5192055444711946e+02 7.9054321026840489e+02 -1.0129681203253186e+02 3.7655451167028815e+01 1.0478181459526597e+02 init_forces: ! |2 @@ -68,8 +68,8 @@ init_forces: ! |2 27 9.7332884809348705e+00 -5.1358738629501516e+01 1.9618779693342940e+01 28 -4.2804259382932656e+01 1.6023914430085185e+01 -2.8346203528536542e+01 29 3.3466068368781215e+01 3.5333331417895330e+01 8.7040706686759854e+00 -run_vdwl: 224.238305160725 -run_coul: 225.801509169719 +run_vdwl: 224.23830516072474 +run_coul: 225.80150916971948 run_stress: ! |2- 4.6605259652006634e+02 4.5140744303353154e+02 7.8583120168007440e+02 -1.0069613692077770e+02 3.7937821563053788e+01 1.0482860743226058e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_wolf.yaml b/unittest/force-styles/tests/mol-pair-born_coul_wolf.yaml index 797cec95a1..4c1947889c 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_wolf.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_wolf.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:39 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair born/coul/wolf @@ -27,8 +28,8 @@ pair_coeff: ! | 5 5 2.63841820292211 0.184008285863681 2.19742633928911 79.1465822481912 592.979935420722 extract: ! "" natoms: 29 -init_vdwl: 225.01325775005 -init_coul: -115.714526063965 +init_vdwl: 225.0132577500503 +init_coul: -115.71452606396501 init_stress: ! |2- 4.6548476353031594e+02 4.5051121181207009e+02 7.8830780607527231e+02 -1.0070292272125855e+02 3.7932502866866884e+01 1.0553864562325978e+02 init_forces: ! |2 @@ -61,8 +62,8 @@ init_forces: ! |2 27 9.4540809516247997e+00 -5.0442863407123895e+01 1.9202978230103980e+01 28 -4.2634181882990461e+01 1.5556514661238062e+01 -2.8124333709589376e+01 29 3.3595845049033763e+01 3.4856379135410322e+01 8.9087361003241234e+00 -run_vdwl: 224.239908258883 -run_coul: -115.738011157081 +run_vdwl: 224.23990825888316 +run_coul: -115.73801115708112 run_stress: ! |2- 4.6541486465261943e+02 4.5000181377675614e+02 7.8360788998458611e+02 -1.0010028697870386e+02 3.8217404146676735e+01 1.0558384978752372e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-born_coul_wolf_cs.yaml b/unittest/force-styles/tests/mol-pair-born_coul_wolf_cs.yaml index 33323ccdd6..8862ce4ac2 100644 --- a/unittest/force-styles/tests/mol-pair-born_coul_wolf_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-born_coul_wolf_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:40 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair born/coul/wolf/cs @@ -27,8 +28,8 @@ pair_coeff: ! | 5 5 2.63841820292211 0.184008285863681 2.19742633928911 79.1465822481912 592.979935420722 extract: ! "" natoms: 29 -init_vdwl: 225.01325775005 -init_coul: -115.714526063965 +init_vdwl: 225.0132577500503 +init_coul: -115.71452606396501 init_stress: ! |2- 4.6548476353031594e+02 4.5051121181207009e+02 7.8830780607527231e+02 -1.0070292272125855e+02 3.7932502866866884e+01 1.0553864562325978e+02 init_forces: ! |2 @@ -61,8 +62,8 @@ init_forces: ! |2 27 9.4540809516247997e+00 -5.0442863407123895e+01 1.9202978230103980e+01 28 -4.2634181882990461e+01 1.5556514661238062e+01 -2.8124333709589376e+01 29 3.3595845049033763e+01 3.4856379135410322e+01 8.9087361003241234e+00 -run_vdwl: 224.239908258883 -run_coul: -115.738011157081 +run_vdwl: 224.23990825888316 +run_coul: -115.73801115708112 run_stress: ! |2- 4.6541486465261943e+02 4.5000181377675614e+02 7.8360788998458611e+02 -1.0010028697870386e+02 3.8217404146676735e+01 1.0558384978752372e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck.yaml b/unittest/force-styles/tests/mol-pair-buck.yaml index 49445a9046..9c5669a83b 100644 --- a/unittest/force-styles/tests/mol-pair-buck.yaml +++ b/unittest/force-styles/tests/mol-pair-buck.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:40 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:27 2022 epsilon: 1.5e-13 +skip_tests: prerequisites: ! | atom full pair buck @@ -29,7 +30,7 @@ extract: ! | a 2 c 2 natoms: 29 -init_vdwl: 143.749538808172 +init_vdwl: 143.74953880817225 init_coul: 0 init_stress: ! |2- 2.8546063261749947e+02 2.8737384899658309e+02 4.6113105064788800e+02 -5.4335721921076150e+01 3.0318888748596905e+01 4.6619308801703639e+01 @@ -63,7 +64,7 @@ init_forces: ! |2 27 6.6485844671195089e+00 -3.6337865162938726e+01 1.3616306220323644e+01 28 -2.7672101461511541e+01 1.1892759906164907e+01 -1.8723455368858552e+01 29 2.1029504459272502e+01 2.4449997447911123e+01 5.1038895464304854e+00 -run_vdwl: 143.551911190157 +run_vdwl: 143.5519111901571 run_coul: 0 run_stress: ! |2- 2.8577346215348786e+02 2.8738293557155362e+02 4.5969292987124692e+02 -5.4042629413176499e+01 3.0499443960600292e+01 4.6842687890897629e+01 diff --git a/unittest/force-styles/tests/mol-pair-buck_coul_cut.yaml b/unittest/force-styles/tests/mol-pair-buck_coul_cut.yaml index 7ed68a797e..175740a525 100644 --- a/unittest/force-styles/tests/mol-pair-buck_coul_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_coul_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:40 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair buck/coul/cut @@ -25,12 +26,12 @@ pair_coeff: ! | 4 4 127198.698386798 0.207005479340455 37.2289658745028 4 5 127198.698386798 0.207005479340455 37.2289658745028 5 5 127198.698386798 0.207005479340455 37.2289658745028 -extract: | +extract: ! | a 2 c 2 natoms: 29 -init_vdwl: 143.749538808172 -init_coul: -127.494586297384 +init_vdwl: 143.74953880817225 +init_coul: -127.49458629738443 init_stress: ! |2- 2.5863608558254202e+02 2.4421107389249406e+02 4.0362378648954996e+02 -5.5156272856721458e+01 2.2411618642204040e+01 4.9674518003116084e+01 init_forces: ! |2 @@ -63,8 +64,8 @@ init_forces: ! |2 27 3.8010449618361193e+00 -2.5225906069759308e+01 9.1910688014900863e+00 28 -2.2825681053936801e+01 6.6017216011110555e+00 -1.4642565228293659e+01 29 1.9765892450982200e+01 1.8278061950393514e+01 6.0260822255895716e+00 -run_vdwl: 143.570099579859 -run_coul: -127.532904240752 +run_vdwl: 143.57009957985863 +run_coul: -127.53290424075185 run_stress: ! |2- 2.5889909416319711e+02 2.4422213961563290e+02 4.0230661883110236e+02 -5.4878661060050817e+01 2.2536041888677346e+01 4.9831039816737245e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_coul_long.yaml b/unittest/force-styles/tests/mol-pair-buck_coul_long.yaml index d17aa0f656..972a4d9b66 100644 --- a/unittest/force-styles/tests/mol-pair-buck_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:40 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 4e-13 +skip_tests: prerequisites: ! | atom full pair buck/coul/long @@ -30,12 +31,12 @@ pair_coeff: ! | 4 4 127198.698386798 0.207005479340455 37.2289658745028 4 5 127198.698386798 0.207005479340455 37.2289658745028 5 5 127198.698386798 0.207005479340455 37.2289658745028 -extract: | +extract: ! | a 2 c 2 natoms: 29 -init_vdwl: 143.749538808172 -init_coul: 225.821815126925 +init_vdwl: 143.74953880817225 +init_coul: 225.82181512692495 init_stress: ! |2- 2.6268452425769624e+02 2.4453034296967044e+02 4.2238505666906292e+02 -4.9838202342760439e+01 2.3794887708191297e+01 5.6299161015968700e+01 init_forces: ! |2 @@ -68,8 +69,8 @@ init_forces: ! |2 27 4.6275296350353301e+00 -2.6304782126946165e+01 9.9375753439373486e+00 28 -2.3342785641579749e+01 7.6604241443883918e+00 -1.5178331872815008e+01 29 1.9107819420519249e+01 1.8640384533413339e+01 5.2191851174899595e+00 -run_vdwl: 143.568625155378 -run_coul: 225.788771269962 +run_vdwl: 143.56862515537782 +run_coul: 225.78877126996179 run_stress: ! |2- 2.6294592507175832e+02 2.4453683519459824e+02 4.2104381906443354e+02 -4.9562449442644926e+01 2.3914873260658716e+01 5.6454583403156704e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_coul_long_cs.yaml b/unittest/force-styles/tests/mol-pair-buck_coul_long_cs.yaml index 1cc2cc5dec..f05adc47c0 100644 --- a/unittest/force-styles/tests/mol-pair-buck_coul_long_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_coul_long_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:40 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair buck/coul/long/cs @@ -32,8 +33,8 @@ pair_coeff: ! | 5 5 127198.698386798 0.207005479340455 37.2289658745028 extract: ! "" natoms: 29 -init_vdwl: 143.749538808184 -init_coul: 225.8219568135 +init_vdwl: 143.74953880818418 +init_coul: 225.82195681349995 init_stress: ! |2- 2.6268460231496744e+02 2.4453037866238478e+02 4.2238512108339154e+02 -4.9838164344734366e+01 2.3794905459462569e+01 5.6299162993366650e+01 init_forces: ! |2 @@ -66,8 +67,8 @@ init_forces: ! |2 27 4.6275333879969409e+00 -2.6304806009769145e+01 9.9375839812325601e+00 28 -2.3342801583992202e+01 7.6604323600981470e+00 -1.5178343041534969e+01 29 1.9107831279492629e+01 1.8640399948088248e+01 5.2191877728446663e+00 -run_vdwl: 143.568625105105 -run_coul: 225.788913139166 +run_vdwl: 143.56862510510462 +run_coul: 225.7889131391656 run_stress: ! |2- 2.6294600325205585e+02 2.4453687085649130e+02 4.2104388324691058e+02 -4.9562411450219372e+01 2.3914891250634774e+01 5.6454585594366279e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_coul_msm.yaml b/unittest/force-styles/tests/mol-pair-buck_coul_msm.yaml index db5131e253..1ab554f739 100644 --- a/unittest/force-styles/tests/mol-pair-buck_coul_msm.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_coul_msm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:40 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full pair buck/coul/msm @@ -32,12 +33,12 @@ pair_coeff: ! | 4 4 127198.698386798 0.207005479340455 37.2289658745028 4 5 127198.698386798 0.207005479340455 37.2289658745028 5 5 127198.698386798 0.207005479340455 37.2289658745028 -extract: | +extract: ! | a 2 c 2 natoms: 29 -init_vdwl: 143.749538808172 -init_coul: 226.465163473713 +init_vdwl: 143.74953880817225 +init_coul: 226.4651634737126 init_stress: ! |2- 2.6217223817480522e+02 2.4398322761761119e+02 4.2145301245028469e+02 -4.9520774663735487e+01 2.4077558427717523e+01 5.6176686601157868e+01 init_forces: ! |2 @@ -70,8 +71,8 @@ init_forces: ! |2 27 4.5726620680707963e+00 -2.6041323711122949e+01 9.8983244066517280e+00 28 -2.3279647768186493e+01 7.5396562185096743e+00 -1.5121646456861377e+01 29 1.9119389758156409e+01 1.8491995912109910e+01 5.2026425513360959e+00 -run_vdwl: 143.569113032674 -run_coul: 226.430521327767 +run_vdwl: 143.56911303267367 +run_coul: 226.43052132776702 run_stress: ! |2- 2.6243406797837577e+02 2.4399058654210910e+02 4.2011422155477402e+02 -4.9244420696743255e+01 2.4198040116799781e+01 5.6330831633160550e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_coul_msm_table.yaml b/unittest/force-styles/tests/mol-pair-buck_coul_msm_table.yaml index 340ae4c9e6..2644893751 100644 --- a/unittest/force-styles/tests/mol-pair-buck_coul_msm_table.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_coul_msm_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:40 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 2e-13 skip_tests: gpu prerequisites: ! | @@ -33,12 +33,12 @@ pair_coeff: ! | 4 4 127198.698386798 0.207005479340455 37.2289658745028 4 5 127198.698386798 0.207005479340455 37.2289658745028 5 5 127198.698386798 0.207005479340455 37.2289658745028 -extract: | +extract: ! | a 2 c 2 natoms: 29 -init_vdwl: 143.749538808172 -init_coul: 226.465163473713 +init_vdwl: 143.74953880817225 +init_coul: 226.4651634737126 init_stress: ! |2- 2.6217223817480522e+02 2.4398322761761119e+02 4.2145301245028469e+02 -4.9520774663735487e+01 2.4077558427717523e+01 5.6176686601157868e+01 init_forces: ! |2 @@ -71,8 +71,8 @@ init_forces: ! |2 27 4.5726620680707963e+00 -2.6041323711122949e+01 9.8983244066517280e+00 28 -2.3279647768186493e+01 7.5396562185096743e+00 -1.5121646456861377e+01 29 1.9119389758156409e+01 1.8491995912109910e+01 5.2026425513360959e+00 -run_vdwl: 143.569113032674 -run_coul: 226.430521327767 +run_vdwl: 143.56911303267367 +run_coul: 226.43052132776702 run_stress: ! |2- 2.6243406797837577e+02 2.4399058654210910e+02 4.2011422155477402e+02 -4.9244420696743255e+01 2.4198040116799781e+01 5.6330831633160550e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_coul_table.yaml b/unittest/force-styles/tests/mol-pair-buck_coul_table.yaml index 0c83565144..d55ac25108 100644 --- a/unittest/force-styles/tests/mol-pair-buck_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:40 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 5e-12 skip_tests: gpu prerequisites: ! | @@ -31,12 +31,12 @@ pair_coeff: ! | 4 4 127198.698386798 0.207005479340455 37.2289658745028 4 5 127198.698386798 0.207005479340455 37.2289658745028 5 5 127198.698386798 0.207005479340455 37.2289658745028 -extract: | +extract: ! | a 2 c 2 natoms: 29 -init_vdwl: 143.749538808172 -init_coul: 225.821851347828 +init_vdwl: 143.74953880817225 +init_coul: 225.8218513478281 init_stress: ! |2- 2.6268454452041823e+02 2.4453034872573909e+02 4.2238507009368755e+02 -4.9838199048167084e+01 2.3794897203338820e+01 5.6299165106627711e+01 init_forces: ! |2 @@ -69,8 +69,8 @@ init_forces: ! |2 27 4.6275295196719846e+00 -2.6304781961228922e+01 9.9375751500151814e+00 28 -2.3342788353122209e+01 7.6604232094857601e+00 -1.5178333088875645e+01 29 1.9107822043893268e+01 1.8640385042681956e+01 5.2191866233149646e+00 -run_vdwl: 143.568625150522 -run_coul: 225.788808998821 +run_vdwl: 143.56862515052202 +run_coul: 225.78880899882137 run_stress: ! |2- 2.6294594847725642e+02 2.4453683914902376e+02 4.2104383378157951e+02 -4.9562445401925707e+01 2.3914879352797943e+01 5.6454589328617381e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_coul_table_cs.yaml b/unittest/force-styles/tests/mol-pair-buck_coul_table_cs.yaml index 25c4381ba5..4235216d63 100644 --- a/unittest/force-styles/tests/mol-pair-buck_coul_table_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_coul_table_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair buck/coul/long/cs @@ -32,8 +33,8 @@ pair_coeff: ! | 5 5 127198.698386798 0.207005479340455 37.2289658745028 extract: ! "" natoms: 29 -init_vdwl: 143.749538808183 -init_coul: 225.821984927182 +init_vdwl: 143.74953880818336 +init_coul: 225.82198492718214 init_stress: ! |2- 2.6268462974492968e+02 2.4453040393552541e+02 4.2238514060239214e+02 -4.9838161454365292e+01 2.3794926056854369e+01 5.6299162695298399e+01 init_forces: ! |2 @@ -66,8 +67,8 @@ init_forces: ! |2 27 4.6275334941967543e+00 -2.6304805910222296e+01 9.9375838993500700e+00 28 -2.3342806294704374e+01 7.6604309199589586e+00 -1.5178345228324231e+01 29 1.9107836010950663e+01 1.8640401281202131e+01 5.2191900134286620e+00 -run_vdwl: 143.56862509507 -run_coul: 225.788942792757 +run_vdwl: 143.5686250950698 +run_coul: 225.7889427927568 run_stress: ! |2- 2.6294603382624263e+02 2.4453689432875228e+02 4.2104390406708438e+02 -4.9562407809564661e+01 2.3914908449773719e+01 5.6454587144561422e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_long_coul_long.yaml b/unittest/force-styles/tests/mol-pair-buck_long_coul_long.yaml index df11a0547c..36eeed675a 100644 --- a/unittest/force-styles/tests/mol-pair-buck_long_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_long_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 2e-09 +skip_tests: prerequisites: ! | atom full pair buck/long/coul/long @@ -33,7 +34,7 @@ pair_coeff: ! | 5 5 127198.698386798 0.207005479340455 37.2289658745028 extract: ! "" natoms: 29 -init_vdwl: 143.844978614334 +init_vdwl: 143.84497861433388 init_coul: 225.821815126925 init_stress: ! |2- 2.6272115366310851e+02 2.4458745276042501e+02 4.2242971713439869e+02 -4.9851077224341211e+01 2.3789370660435189e+01 5.6295145580816097e+01 @@ -67,8 +68,8 @@ init_forces: ! |2 27 4.6260665022300582e+00 -2.6306305097469373e+01 9.9386139962313145e+00 28 -2.3342848199954272e+01 7.6603913255018758e+00 -1.5178322120320068e+01 29 1.9107789199090401e+01 1.8640339900824774e+01 5.2192425307232284e+00 -run_vdwl: 143.664052390025 -run_coul: 225.78877136265 +run_vdwl: 143.66405239002466 +run_coul: 225.7887713626504 run_stress: ! |2- 2.6298255053149916e+02 2.4459393805653841e+02 4.2108847711322130e+02 -4.9575323006225169e+01 2.3909358002752519e+01 5.6450569769884474e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_long_coul_off.yaml b/unittest/force-styles/tests/mol-pair-buck_long_coul_off.yaml index 475e588687..c0fdf2c465 100644 --- a/unittest/force-styles/tests/mol-pair-buck_long_coul_off.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_long_coul_off.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 2e-09 +skip_tests: prerequisites: ! | atom full pair buck/long/coul/long @@ -33,7 +34,7 @@ pair_coeff: ! | 5 5 127198.698386798 0.207005479340455 37.2289658745028 extract: ! "" natoms: 29 -init_vdwl: 143.844978614334 +init_vdwl: 143.84497861433388 init_coul: 0 init_stress: ! |2- 2.8549726202291151e+02 2.8743095878733766e+02 4.6117571111322400e+02 -5.4348596802656758e+01 3.0313371700840868e+01 4.6615293366551008e+01 @@ -67,7 +68,7 @@ init_forces: ! |2 27 6.6471213343142246e+00 -3.6339388133461938e+01 1.3617344872617608e+01 28 -2.7672164019886065e+01 1.1892727087278390e+01 -1.8723445616363609e+01 29 2.1029474237843658e+01 2.4449952815322550e+01 5.1039469596637526e+00 -run_vdwl: 143.647338332642 +run_vdwl: 143.6473383326423 run_coul: 0 run_stress: ! |2- 2.8581008766933104e+02 2.8744003840903019e+02 4.5973758784231285e+02 -5.4055502782848421e+01 3.0493928735622941e+01 4.6838674166921798e+01 diff --git a/unittest/force-styles/tests/mol-pair-buck_long_cut_coul_long.yaml b/unittest/force-styles/tests/mol-pair-buck_long_cut_coul_long.yaml index d51ff36d84..67d9b8881d 100644 --- a/unittest/force-styles/tests/mol-pair-buck_long_cut_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_long_cut_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 2e-09 +skip_tests: prerequisites: ! | atom full pair buck/long/coul/long @@ -32,7 +33,7 @@ pair_coeff: ! | 5 5 127198.698386798 0.207005479340455 37.2289658745028 extract: ! "" natoms: 29 -init_vdwl: 143.749538808172 +init_vdwl: 143.74953880817225 init_coul: 225.821815126925 init_stress: ! |2- 2.6268452425769618e+02 2.4453034296967053e+02 4.2238505666906303e+02 -4.9838202342760418e+01 2.3794887708191212e+01 5.6299161015968693e+01 @@ -66,8 +67,8 @@ init_forces: ! |2 27 4.6275296350353177e+00 -2.6304782126946186e+01 9.9375753439373451e+00 28 -2.3342785641579749e+01 7.6604241443883918e+00 -1.5178331872815008e+01 29 1.9107819420519260e+01 1.8640384533413357e+01 5.2191851174899631e+00 -run_vdwl: 143.568625155378 -run_coul: 225.788771269962 +run_vdwl: 143.56862515537782 +run_coul: 225.7887712699618 run_stress: ! |2- 2.6294592507175838e+02 2.4453683519459824e+02 4.2104381906443348e+02 -4.9562449442644890e+01 2.3914873260658684e+01 5.6454583403156704e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_mdf.yaml b/unittest/force-styles/tests/mol-pair-buck_mdf.yaml index 7feefb9f51..4d3f107c04 100644 --- a/unittest/force-styles/tests/mol-pair-buck_mdf.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_mdf.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | atom full pair buck/mdf @@ -29,7 +30,7 @@ extract: ! | a 2 c 2 natoms: 29 -init_vdwl: 143.750172479889 +init_vdwl: 143.75017247988893 init_coul: 0 init_stress: ! |2- 2.8545976884034133e+02 2.8737056463500437e+02 4.6112835758703841e+02 -5.4336275648975430e+01 3.0319466756231911e+01 4.6620664187526550e+01 @@ -63,7 +64,7 @@ init_forces: ! |2 27 6.6487363315433221e+00 -3.6337564791281956e+01 1.3616115657254987e+01 28 -2.7672094503404313e+01 1.1892775106158119e+01 -1.8723460085236635e+01 29 2.1029505808433630e+01 2.4450001388294194e+01 5.1038879408118385e+00 -run_vdwl: 143.552545224348 +run_vdwl: 143.55254522434768 run_coul: 0 run_stress: ! |2- 2.8577259755322768e+02 2.8737964903764203e+02 4.5969023465882259e+02 -5.4043181576015463e+01 3.0500021516712550e+01 4.6844040968177744e+01 diff --git a/unittest/force-styles/tests/mol-pair-buck_table_coul_long.yaml b/unittest/force-styles/tests/mol-pair-buck_table_coul_long.yaml index ff11010ebd..65677b95ff 100644 --- a/unittest/force-styles/tests/mol-pair-buck_table_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_table_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 2e-09 +skip_tests: prerequisites: ! | atom full pair buck/long/coul/long @@ -33,7 +34,7 @@ pair_coeff: ! | 5 5 127198.698386798 0.207005479340455 37.2289658745028 extract: ! "" natoms: 29 -init_vdwl: 143.844978555225 +init_vdwl: 143.8449785552246 init_coul: 225.821815126925 init_stress: ! |2- 2.6272115353924420e+02 2.4458745265633888e+02 4.2242971700722717e+02 -4.9851077226985659e+01 2.3789370689053712e+01 5.6295145616802088e+01 @@ -67,8 +68,8 @@ init_forces: ! |2 27 4.6260665022831926e+00 -2.6306305097421209e+01 9.9386139962010169e+00 28 -2.3342848199929932e+01 7.6603913255098890e+00 -1.5178322120309636e+01 29 1.9107789199068538e+01 1.8640339900820063e+01 5.2192425307102530e+00 -run_vdwl: 143.664052317798 -run_coul: 225.788771362651 +run_vdwl: 143.66405231779763 +run_coul: 225.78877136265103 run_stress: ! |2- 2.6298255039302433e+02 2.4459393792599337e+02 4.2108847694849635e+02 -4.9575322988350926e+01 2.3909358001492738e+01 5.6450569845567607e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-buck_table_coul_off.yaml b/unittest/force-styles/tests/mol-pair-buck_table_coul_off.yaml index 009ceb6359..1dc96dd60f 100644 --- a/unittest/force-styles/tests/mol-pair-buck_table_coul_off.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_table_coul_off.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 5e-08 +skip_tests: prerequisites: ! | atom full pair buck/long/coul/long @@ -33,7 +34,7 @@ pair_coeff: ! | 5 5 127198.698386798 0.207005479340455 37.2289658745028 extract: ! "" natoms: 29 -init_vdwl: 143.844978555225 +init_vdwl: 143.8449785552246 init_coul: 0 init_stress: ! |2- 2.8549726189904709e+02 2.8743095868325156e+02 4.6117571098605237e+02 -5.4348596805301213e+01 3.0313371729459480e+01 4.6615293402536935e+01 @@ -67,7 +68,7 @@ init_forces: ! |2 27 6.6471213343673661e+00 -3.6339388133413763e+01 1.3617344872587314e+01 28 -2.7672164019861725e+01 1.1892727087286405e+01 -1.8723445616353175e+01 29 2.1029474237821791e+01 2.4449952815317836e+01 5.1039469596507772e+00 -run_vdwl: 143.647338255486 +run_vdwl: 143.64733825548632 run_coul: 0 run_stress: ! |2- 2.8581008751513525e+02 2.8744003827131843e+02 4.5973758767091698e+02 -5.4055502759640746e+01 3.0493928747153301e+01 4.6838674234102271e+01 diff --git a/unittest/force-styles/tests/mol-pair-buck_table_coul_table.yaml b/unittest/force-styles/tests/mol-pair-buck_table_coul_table.yaml index 49ddaab6d9..b5b5b55921 100644 --- a/unittest/force-styles/tests/mol-pair-buck_table_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-buck_table_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:41 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 8e-07 skip_tests: gpu prerequisites: ! | @@ -34,72 +34,72 @@ pair_coeff: ! | 5 5 127198.698386798 0.207005479340455 37.2289658745028 extract: ! "" natoms: 29 -init_vdwl: 143.844978614334 -init_coul: 225.821848735651 +init_vdwl: 143.8449785552246 +init_coul: 225.82184873565126 init_stress: ! |2- - 2.6272117306676120e+02 2.4458745621217102e+02 4.2242972894553253e+02 -4.9851073065300838e+01 2.3789378318095498e+01 5.6295149559988992e+01 + 2.6272117294289677e+02 2.4458745610808492e+02 4.2242972881836090e+02 -4.9851073067945222e+01 2.3789378346714095e+01 5.6295149595974962e+01 init_forces: ! |2 - 1 -1.4505642243640215e+00 3.8004146924345065e+01 4.9065029786406498e+01 - 2 2.3385003688559166e+01 1.6548372269719717e+01 -2.9130976131979111e+01 - 3 -1.9512020589699148e+01 -5.0838221404070403e+01 -2.0151693508779069e+01 - 4 -4.2904209500654860e+00 1.1246503672355344e+00 -3.2387272431008922e+00 - 5 -1.8674708222112977e+00 -1.5566480848536877e+00 6.0082555280887631e+00 - 6 -6.9625355419087825e+01 7.3169400262826329e+01 6.3503696373222517e+01 - 7 2.2867869937221619e-02 -2.0565222687264711e+01 -1.2607143962465263e+02 - 8 1.1996675850025813e+00 -1.8715123686519544e+00 3.7423151434986330e+01 - 9 1.2011044735413689e+01 5.3887302819054357e+00 4.7397825928121676e+01 - 10 4.8241808431442209e+01 -6.2511418839801145e+01 -1.8155088624349265e+01 - 11 -2.0864824587972244e+00 -1.9912619467801009e+00 -5.4830250628953481e+00 - 12 1.1616736503333982e+01 3.5495697662792747e+00 -2.2660045747679183e+00 - 13 4.3604502374039908e+00 -1.7673672044182291e+00 -2.5819531045379251e-01 - 14 -2.8754771873341758e+00 7.2404569709650146e-01 -4.7880074162879485e+00 - 15 2.4933073767688302e-01 4.4129065809108328e+00 6.2372655271123578e-01 - 16 4.0308376131314546e+01 -3.2807274409251065e+01 -8.8340521121472662e+01 - 17 -3.8534551208026642e+01 3.0771085663179537e+01 9.2205189419358319e+01 - 18 3.5576926187651203e-01 4.7710862380293300e+00 -7.8576991961411933e+00 - 19 1.9901880274797432e+00 -7.2120628273974552e-01 5.5217485914027300e+00 - 20 -2.9133077306028037e+00 -3.9873812666657433e+00 4.1252922615364644e+00 - 21 -8.8829724897811690e+00 -8.3744018546727830e+00 2.7526234698248395e+01 - 22 -1.5742517627293919e+01 -4.8231253819043038e+00 -2.1626156255255044e+01 - 23 2.4211679999720808e+01 1.3610506006400097e+01 -5.3979034247521342e+00 - 24 5.3565423691472525e+00 -2.4298981609236485e+01 1.3585253150887608e+01 - 25 -2.1457576768629711e+01 1.0104626755769854e+00 -1.7195902771340254e+01 - 26 1.5538244608279541e+01 2.3034634695339562e+01 2.9964020489618552e+00 - 27 4.6260663692619683e+00 -2.6306304932222957e+01 9.9386138025705169e+00 - 28 -2.3342851187576169e+01 7.6603903375650901e+00 -1.5178323537982580e+01 - 29 1.9107792107619538e+01 1.8640340506123994e+01 5.2192442277069402e+00 -run_vdwl: 143.664052385482 -run_coul: 225.788807113984 + 1 -1.4505642246493893e+00 3.8004146921245280e+01 4.9065029787128516e+01 + 2 2.3385003688526545e+01 1.6548372269618021e+01 -2.9130976131969589e+01 + 3 -1.9512020558936566e+01 -5.0838221435557891e+01 -2.0151693529215304e+01 + 4 -4.2904209499810113e+00 1.1246503672179491e+00 -3.2387272430688374e+00 + 5 -1.8674708210686974e+00 -1.5566480826272349e+00 6.0082555269682976e+00 + 6 -6.9625355446305264e+01 7.3169400291220114e+01 6.3503696392576622e+01 + 7 2.2867887782185070e-02 -2.0565222696917687e+01 -1.2607143958407579e+02 + 8 1.1996675755004982e+00 -1.8715123590268352e+00 3.7423151392434960e+01 + 9 1.2011044735352231e+01 5.3887302818208358e+00 4.7397825927713541e+01 + 10 4.8241808483620233e+01 -6.2511418790889870e+01 -1.8155088656364601e+01 + 11 -2.0864824591747761e+00 -1.9912619450444762e+00 -5.4830250613048612e+00 + 12 1.1616736442515712e+01 3.5495697163864675e+00 -2.2660045359436776e+00 + 13 4.3604502371008351e+00 -1.7673672044988684e+00 -2.5819531034309701e-01 + 14 -2.8754771876493210e+00 7.2404569679709707e-01 -4.7880074155797994e+00 + 15 2.4933073738240499e-01 4.4129065807075438e+00 6.2372655279701084e-01 + 16 4.0308376129688710e+01 -3.2807274406411338e+01 -8.8340521124317476e+01 + 17 -3.8534551208783562e+01 3.0771085664726073e+01 9.2205189416585171e+01 + 18 3.5576926167241962e-01 4.7710862376582464e+00 -7.8576991957481530e+00 + 19 1.9901880274955834e+00 -7.2120628273036580e-01 5.5217485914195938e+00 + 20 -2.9133077306229129e+00 -3.9873812666837125e+00 4.1252922615342049e+00 + 21 -8.8829724898511184e+00 -8.3744018546015084e+00 2.7526234698326579e+01 + 22 -1.5742517627262460e+01 -4.8231253818882047e+00 -2.1626156255239923e+01 + 23 2.4211679999687529e+01 1.3610506006386133e+01 -5.3979034247650652e+00 + 24 5.3565423689759015e+00 -2.4298981609324311e+01 1.3585253150613612e+01 + 25 -2.1457576768635565e+01 1.0104626755738009e+00 -1.7195902771373799e+01 + 26 1.5538244608258903e+01 2.3034634695327131e+01 2.9964020489498191e+00 + 27 4.6260663693151027e+00 -2.6306304932174790e+01 9.9386138025402140e+00 + 28 -2.3342851187551830e+01 7.6603903375731024e+00 -1.5178323537972146e+01 + 29 1.9107792107597675e+01 1.8640340506119276e+01 5.2192442276939657e+00 +run_vdwl: 143.66405231325498 +run_coul: 225.78880711398503 run_stress: ! |2- - 2.6298257278765311e+02 2.4459394060869445e+02 4.2108849022194408e+02 -4.9575317957752254e+01 2.3909363739954845e+01 5.6450575869687796e+01 + 2.6298257264917891e+02 2.4459394047814814e+02 4.2108849005722158e+02 -4.9575317939878417e+01 2.3909363738695504e+01 5.6450575945370680e+01 run_forces: ! |2 - 1 -1.3652735930906894e+00 3.7954572425088600e+01 4.8884537536228251e+01 - 2 2.3313139334678663e+01 1.6527406600491211e+01 -2.8962849276354000e+01 - 3 -1.9564718562282973e+01 -5.0756719062921292e+01 -2.0129965576839844e+01 - 4 -4.2684081469531368e+00 1.1154804222099293e+00 -3.2315049292955824e+00 - 5 -1.8626808414826610e+00 -1.5514185255808333e+00 5.9922528781941766e+00 - 6 -6.9327721229262110e+01 7.2910024635730380e+01 6.2943837085648937e+01 - 7 3.2725222830676137e-02 -2.0499842211560001e+01 -1.2523228341650837e+02 - 8 9.0645055137852115e-01 -1.5931719167310145e+00 3.7347019992128743e+01 - 9 1.1981988547677094e+01 5.2954468970124511e+00 4.7222350531971742e+01 - 10 4.8288281356087531e+01 -6.2566570067320434e+01 -1.8224022430624395e+01 - 11 -2.0738716081392377e+00 -1.9563271844965389e+00 -5.4254319181514443e+00 - 12 1.1610879631578506e+01 3.5317030183327125e+00 -2.3173858911656642e+00 - 13 4.3429258040952297e+00 -1.7528673754740225e+00 -2.5697566254992021e-01 - 14 -2.8597051688567952e+00 7.1516550852642913e-01 -4.7422662954861217e+00 - 15 2.4141796485202816e-01 4.4181495983415076e+00 6.3284909937970446e-01 - 16 4.0232211454356282e+01 -3.2797832579156953e+01 -8.8231799320354028e+01 - 17 -3.8475339764361301e+01 3.0789551940448018e+01 9.2071436318485866e+01 - 18 3.0444805304334399e-01 4.7206638753263892e+00 -7.8186575081644856e+00 - 19 2.0279150077542512e+00 -6.9154201629216772e-01 5.5370944341575088e+00 - 20 -2.8995220657682923e+00 -3.9661888647039816e+00 4.0718961563281235e+00 - 21 -8.9482098702532671e+00 -8.3621992046533951e+00 2.7577076529370782e+01 - 22 -1.5805955549117563e+01 -4.8572159950668672e+00 -2.1662218352485397e+01 - 23 2.4340521396969667e+01 1.3631552340005888e+01 -5.4129057420952673e+00 - 24 5.5331811069800025e+00 -2.4561349584081412e+01 1.3801516002278914e+01 - 25 -2.1784341752404423e+01 1.0179032153888428e+00 -1.7474990731263802e+01 - 26 1.5689570827295116e+01 2.3291561157244697e+01 3.0620923168469263e+00 - 27 4.7026946335578899e+00 -2.6383838605477855e+01 9.9362502458408990e+00 - 28 -2.3442657629509469e+01 7.6899612499018408e+00 -1.5219892620516704e+01 - 29 1.9130054888347100e+01 1.8687940309467866e+01 5.2629405449944144e+00 + 1 -1.3652735931241642e+00 3.7954572421202144e+01 4.8884537535656982e+01 + 2 2.3313139334588072e+01 1.6527406600310073e+01 -2.8962849276325887e+01 + 3 -1.9564718540556054e+01 -5.0756719084972573e+01 -2.0129965591614901e+01 + 4 -4.2684081464814945e+00 1.1154804224555763e+00 -3.2315049289640032e+00 + 5 -1.8626808406495545e+00 -1.5514185242357010e+00 5.9922528773628976e+00 + 6 -6.9327721248028368e+01 7.2910024656102067e+01 6.2943837099875118e+01 + 7 3.2725241499407427e-02 -2.0499842221118971e+01 -1.2523228337574285e+02 + 8 9.0645054823846349e-01 -1.5931719083542608e+00 3.7347019948673520e+01 + 9 1.1981988547849795e+01 5.2954468966797403e+00 4.7222350531540940e+01 + 10 4.8288281427045007e+01 -6.2566570058104183e+01 -1.8224022420813601e+01 + 11 -2.0738716083421775e+00 -1.9563271833598972e+00 -5.4254319171314114e+00 + 12 1.1610879569851726e+01 3.5317029727182354e+00 -2.3173858532477567e+00 + 13 4.3429258039736984e+00 -1.7528673754858457e+00 -2.5697566249894610e-01 + 14 -2.8597051690691000e+00 7.1516550828591940e-01 -4.7422662949710208e+00 + 15 2.4141796394313483e-01 4.4181495977299523e+00 6.3284909965172886e-01 + 16 4.0232211428273317e+01 -3.2797832539551713e+01 -8.8231799360387299e+01 + 17 -3.8475339765488044e+01 3.0789551942950329e+01 9.2071436313515775e+01 + 18 3.0444805279647119e-01 4.7206638749727059e+00 -7.8186575078624765e+00 + 19 2.0279150077691543e+00 -6.9154201628361855e-01 5.5370944341681296e+00 + 20 -2.8995220657850593e+00 -3.9661888647195291e+00 4.0718961563262175e+00 + 21 -8.9482098703242166e+00 -8.3621992045750275e+00 2.7577076529445812e+01 + 22 -1.5805955549086102e+01 -4.8572159950514777e+00 -2.1662218352471108e+01 + 23 2.4340521396936580e+01 1.3631552339992183e+01 -5.4129057421077924e+00 + 24 5.5331811068581054e+00 -2.4561349584143439e+01 1.3801516002082472e+01 + 25 -2.1784341752415159e+01 1.0179032153815144e+00 -1.7474990731290237e+01 + 26 1.5689570827288462e+01 2.3291561157240494e+01 3.0620923168426457e+00 + 27 4.7026946335974973e+00 -2.6383838605437624e+01 9.9362502458119160e+00 + 28 -2.3442657629481658e+01 7.6899612499109740e+00 -1.5219892620504993e+01 + 29 1.9130054888322256e+01 1.8687940309461990e+01 5.2629405449801574e+00 ... diff --git a/unittest/force-styles/tests/mol-pair-cosine_squared.yaml b/unittest/force-styles/tests/mol-pair-cosine_squared.yaml index f787f65e84..54c9d63f62 100644 --- a/unittest/force-styles/tests/mol-pair-cosine_squared.yaml +++ b/unittest/force-styles/tests/mol-pair-cosine_squared.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair cosine/squared @@ -27,7 +28,7 @@ pair_coeff: ! | 5 5 0.015 3.47963234975906 7.75 wca extract: ! "" natoms: 29 -init_vdwl: 743.463090276839 +init_vdwl: 743.4630902768388 init_coul: 0 init_stress: ! |2- 2.1615191386773317e+03 2.1833503580687548e+03 4.6304037820363574e+03 -7.5575560824755155e+02 1.6895783707398664e+01 6.6358284339784689e+02 @@ -61,7 +62,7 @@ init_forces: ! |2 27 5.1824366297393510e+01 -2.2703801913974428e+02 9.0836214781190961e+01 28 -1.8041288881401439e+02 7.7534058664543707e+01 -1.2206933806761211e+02 29 1.2861074587519965e+02 1.4952779475291308e+02 3.1215155717207590e+01 -run_vdwl: 713.680218065791 +run_vdwl: 713.6802180657908 run_coul: 0 run_stress: ! |2- 2.1151561780082525e+03 2.1391864702510302e+03 4.3628262575018016e+03 -7.3487635005949642e+02 3.3936602729076704e+01 6.2489239167002916e+02 diff --git a/unittest/force-styles/tests/mol-pair-coul_cut_global.yaml b/unittest/force-styles/tests/mol-pair-coul_cut_global.yaml index 817c7c76ca..55bf75328a 100644 --- a/unittest/force-styles/tests/mol-pair-coul_cut_global.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_cut_global.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | atom full pair coul/cut/global @@ -15,7 +16,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: -127.494586297384 +init_coul: -127.49458629738443 init_stress: ! |- -2.6824547034957277e+01 -4.3162775104089022e+01 -5.7507264158338124e+01 -8.2055093564543602e-01 -7.9072701063929465e+00 3.0552092014126533e+00 init_forces: ! |2 @@ -49,7 +50,7 @@ init_forces: ! |2 28 4.8464204075747359e+00 -5.2910383050538492e+00 4.0808901405648896e+00 29 -1.2636120082903082e+00 -6.1719354975176035e+00 9.2219267915908476e-01 run_vdwl: 0 -run_coul: -127.551092913469 +run_coul: -127.55109291346851 run_stress: ! |- -2.6928416018548067e+01 -4.3177725729834854e+01 -5.7444951165085541e+01 -8.5814323779813129e-01 -7.9912081348585087e+00 2.9897259857467389e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_cut_soft.yaml b/unittest/force-styles/tests/mol-pair-coul_cut_soft.yaml index 27a1343e67..4b5195ad42 100644 --- a/unittest/force-styles/tests/mol-pair-coul_cut_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_cut_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:28 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair hybrid/overlay @@ -22,8 +23,8 @@ pair_coeff: ! | * * coul/cut/soft 0.52 extract: ! "" natoms: 29 -init_vdwl: 8.07036960332133 -init_coul: -6.57579763044586 +init_vdwl: 8.070369603321334 +init_coul: -6.575797630445855 init_stress: ! |2- 3.3056188525495266e+01 3.8943881243005563e+01 2.4713892609892472e+01 -2.9521605433522784e+00 -9.1087143159719162e+00 -1.7962027131120834e+01 init_forces: ! |2 @@ -56,8 +57,8 @@ init_forces: ! |2 27 -9.9836895788385449e-02 1.4297838277829034e-01 -8.3166582485281443e-02 28 1.9219157401333040e-02 -1.2519846747100560e-01 4.0097586180285402e-02 29 1.2624368927628452e-01 -4.3232086807339080e-02 8.4752873604395568e-02 -run_vdwl: 8.04574227926329 -run_coul: -6.5763762724911 +run_vdwl: 8.045742279263285 +run_coul: -6.576376272491103 run_stress: ! |2- 3.2985189723499374e+01 3.8807044085436232e+01 2.4623156057296914e+01 -2.9100443799265778e+00 -9.1414563324874862e+00 -1.7887412154189317e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_debye.yaml b/unittest/force-styles/tests/mol-pair-coul_debye.yaml index a7902442d1..b5d4c96588 100644 --- a/unittest/force-styles/tests/mol-pair-coul_debye.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_debye.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair coul/debye @@ -16,7 +17,7 @@ extract: ! | cut_coul 2 natoms: 29 init_vdwl: 0 -init_coul: -26.0958890796496 +init_coul: -26.095889079649556 init_stress: ! |- -1.9717664878867801e+01 -1.8897629251703190e+01 -2.3301819302655669e+01 -5.9180580318294780e+00 -4.7032494573201973e+00 2.4875926300325673e+00 init_forces: ! |2 @@ -50,7 +51,7 @@ init_forces: ! |2 28 3.9278723048824835e+00 -2.8448931691021575e+00 2.9712370170163287e+00 29 -2.7543534640139833e+00 -4.6411608299539902e+00 -3.1592271326037225e-01 run_vdwl: 0 -run_coul: -26.1343293229347 +run_coul: -26.134329322934732 run_stress: ! |- -1.9796181192968501e+01 -1.8919669181296651e+01 -2.3274796553207828e+01 -5.9462383223665567e+00 -4.7655599165740519e+00 2.4302137541325664e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_diel.yaml b/unittest/force-styles/tests/mol-pair-coul_diel.yaml index dfd541d659..ed63f961c7 100644 --- a/unittest/force-styles/tests/mol-pair-coul_diel.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_diel.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair coul/diel @@ -15,7 +16,7 @@ pair_coeff: ! | extract: ! "" natoms: 29 init_vdwl: 0 -init_coul: -1584.6301811295 +init_coul: -1584.630181129497 init_stress: ! |- -1.1401563810140906e+03 -7.6376800264344706e+02 -1.7770778584720485e+03 -1.5605607206581135e+02 -2.3548453415221383e+02 -1.0526499057346052e+02 init_forces: ! |2 @@ -49,7 +50,7 @@ init_forces: ! |2 28 1.6767931231659799e+02 -7.2921408226350152e+01 1.1368791383676802e+02 29 -1.4216184138962501e+02 -1.6631243169258107e+02 -3.4224951645102870e+01 run_vdwl: 0 -run_coul: -1591.64057163164 +run_coul: -1591.640571631639 run_stress: ! |- -1.1342477067094678e+03 -7.5980312317690573e+02 -1.7706410549187392e+03 -1.5299745851214874e+02 -2.3212824809529764e+02 -1.0602549277167981e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_dsf.yaml b/unittest/force-styles/tests/mol-pair-coul_dsf.yaml index 5e47bd6c79..e7bc91ad5f 100644 --- a/unittest/force-styles/tests/mol-pair-coul_dsf.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_dsf.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 1e-12 skip_tests: kokkos_omp prerequisites: ! | @@ -17,7 +17,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: -116.262344977046 +init_coul: -116.26234497704607 init_stress: ! |- -2.3416666017056318e+01 -4.4252820375731034e+01 -4.0981374031114207e+01 5.0914225713900896e+00 -6.2469377303827818e+00 1.0436683936455253e+01 init_forces: ! |2 @@ -51,7 +51,7 @@ init_forces: ! |2 28 4.4993862952213046e+00 -4.6997333684039182e+00 3.7669887588771984e+00 29 -1.7919023403128935e+00 -6.2865597340851354e+00 3.1996268167139896e-01 run_vdwl: 0 -run_coul: -116.316659290258 +run_coul: -116.31665929025759 run_stress: ! |- -2.3519522188558341e+01 -4.4269932768479741e+01 -4.0933175350698548e+01 5.0512182532098944e+00 -6.3318312229387574e+00 1.0364966661114028e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_long.yaml b/unittest/force-styles/tests/mol-pair-coul_long.yaml index 5746877cc3..db3cf8c65b 100644 --- a/unittest/force-styles/tests/mol-pair-coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 -epsilon: 2.0e-13 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 +epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair coul/long @@ -21,7 +22,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: 225.821815126925 +init_coul: 225.82181512692495 init_stress: ! |- -2.2776108359803029e+01 -4.2843506026912706e+01 -3.8745993978825133e+01 4.4975195783156332e+00 -6.5240010404057118e+00 9.6798522142651819e+00 init_forces: ! |2 @@ -55,7 +56,7 @@ init_forces: ! |2 28 4.3293158199317929e+00 -4.2323357617765147e+00 3.5451234960435416e+00 29 -1.9216850387532598e+00 -5.8096129144977837e+00 1.1529557105947399e-01 run_vdwl: 0 -run_coul: 225.77204969693 +run_coul: 225.77204969693037 run_stress: ! |- -2.2879015704740524e+01 -4.2864538419179809e+01 -3.8706402302178340e+01 4.4580847142714477e+00 -6.6095294971406071e+00 9.6124862794454575e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_long_cs.yaml b/unittest/force-styles/tests/mol-pair-coul_long_cs.yaml index 02426dbdc3..bbe281ae0c 100644 --- a/unittest/force-styles/tests/mol-pair-coul_long_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_long_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair coul/long/cs @@ -20,7 +21,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: 225.8219568135 +init_coul: 225.82195681349995 init_stress: ! |- -2.2776030302342409e+01 -4.2843470334025362e+01 -3.8745929564195862e+01 4.4975575763288642e+00 -6.5239832891079610e+00 9.6798541916917582e+00 init_forces: ! |2 @@ -54,7 +55,7 @@ init_forces: ! |2 28 4.3292998774941402e+00 -4.2323275460559282e+00 3.5451123273065317e+00 29 -1.9216731797611686e+00 -5.8095974998011188e+00 1.1529822641872207e-01 run_vdwl: 0 -run_coul: 225.772191836741 +run_coul: 225.77219183674097 run_stress: ! |- -2.2878937289293937e+01 -4.2864502634905364e+01 -3.8706337905477625e+01 4.4581228060192499e+00 -6.6095114178790277e+00 9.6124884782943258e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_long_soft.yaml b/unittest/force-styles/tests/mol-pair-coul_long_soft.yaml index b769aabf93..91531c94bf 100644 --- a/unittest/force-styles/tests/mol-pair-coul_long_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_long_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:42 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 3e-13 +skip_tests: prerequisites: ! | atom full pair hybrid/overlay @@ -29,8 +30,8 @@ extract: ! | lambda 2 scale 2 natoms: 29 -init_vdwl: 8.07036960332133 -init_coul: 0.250616636637181 +init_vdwl: 8.070369603321334 +init_coul: 0.2506166366371815 init_stress: ! |2- 3.3318331341780379e+01 4.0258582287659699e+01 2.6723566043088852e+01 -3.2839183131153762e+00 -8.9320581791877558e+00 -1.7911132107077634e+01 init_forces: ! |2 @@ -63,8 +64,8 @@ init_forces: ! |2 27 -1.4965727761262813e-03 2.5382973054268645e-03 -1.1621717469704692e-03 28 5.3244608348053033e-04 -1.5238550051417405e-03 6.4940813491634836e-04 29 1.6207581161454922e-03 -1.1057207815271884e-03 5.2719941898918515e-04 -run_vdwl: 8.04575303732549 -run_coul: 0.250424874957335 +run_vdwl: 8.045753037325486 +run_coul: 0.25042487495733473 run_stress: ! |2- 3.3248117757660225e+01 4.0121187333028409e+01 2.6631046971692410e+01 -3.2415913680324784e+00 -8.9641268171316373e+00 -1.7836648325526387e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_msm.yaml b/unittest/force-styles/tests/mol-pair-coul_msm.yaml index fa374d7b13..d83c66827e 100644 --- a/unittest/force-styles/tests/mol-pair-coul_msm.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_msm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:43 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair coul/msm @@ -22,7 +23,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: 114.131380823567 +init_coul: 114.13138082356693 init_stress: ! |- -2.4267793355147003e+01 -4.5756717314405336e+01 -4.2967565251969454e+01 5.5703434526209152e+00 -6.0923265664647381e+00 1.1018048876055445e+01 init_forces: ! |2 @@ -56,7 +57,7 @@ init_forces: ! |2 28 4.6868038343367324e+00 -5.1092484627949588e+00 3.9981377814736256e+00 29 -1.6656557300256520e+00 -6.6361744834632246e+00 5.1318676181502421e-01 run_vdwl: 0 -run_coul: 114.073732191852 +run_coul: 114.0737321918523 run_stress: ! |- -2.4369860466323860e+01 -4.5768876443818435e+01 -4.2913169324790253e+01 5.5285317121469078e+00 -6.1771738134590590e+00 1.0942889304741621e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_msm_table.yaml b/unittest/force-styles/tests/mol-pair-coul_msm_table.yaml index 48fe4a1908..0fae7b6a43 100644 --- a/unittest/force-styles/tests/mol-pair-coul_msm_table.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_msm_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:43 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 5e-14 skip_tests: gpu prerequisites: ! | @@ -23,7 +23,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: 114.131383580102 +init_coul: 114.13138358010185 init_stress: ! |- -2.4267791676000897e+01 -4.5756714657540712e+01 -4.2967563337009388e+01 5.5703418947052219e+00 -6.0923254743244728e+00 1.1018049168817702e+01 init_forces: ! |2 @@ -57,7 +57,7 @@ init_forces: ! |2 28 4.6868036569188680e+00 -5.1092487641625155e+00 3.9981377912030145e+00 29 -1.6656553611471538e+00 -6.6361744518519572e+00 5.1318690040709902e-01 run_vdwl: 0 -run_coul: 114.073734371379 +run_coul: 114.07373437137882 run_stress: ! |- -2.4369860366231670e+01 -4.5768875963865973e+01 -4.2913165044785742e+01 5.5285342990604489e+00 -6.1771719727954659e+00 1.0942888523546028e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_shield.yaml b/unittest/force-styles/tests/mol-pair-coul_shield.yaml index 5b40743ea8..b81ea3d14c 100644 --- a/unittest/force-styles/tests/mol-pair-coul_shield.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_shield.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:43 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 2.5e-12 +skip_tests: prerequisites: ! | atom full pair coul/shield @@ -15,7 +16,7 @@ pair_coeff: ! | extract: ! "" natoms: 29 init_vdwl: 0 -init_coul: -14.0081911999883 +init_coul: -14.008191199988325 init_stress: ! |- -6.3676250986156480e-02 -1.4423973854801250e+01 -8.0441338255151145e+00 1.3473766493874642e+01 -7.0731970904225658e+00 1.3195070681009261e+01 init_forces: ! |2 @@ -49,7 +50,7 @@ init_forces: ! |2 28 5.3948559878015667e-01 -3.6126692887874567e-01 4.3474815055657107e-01 29 1.5093654276198996e+00 -2.8556829848826217e-02 8.1850682818626952e-01 run_vdwl: 0 -run_coul: -13.9882142666038 +run_coul: -13.988214266603823 run_stress: ! |- -5.0303504432780546e-02 -1.4412580708305903e+01 -8.0482064683964456e+00 1.3472795686380804e+01 -7.0700180111056925e+00 1.3195887812103887e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_slater_cut.yaml b/unittest/force-styles/tests/mol-pair-coul_slater_cut.yaml index ea587bff0b..139a0c1d36 100644 --- a/unittest/force-styles/tests/mol-pair-coul_slater_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_slater_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:43 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair coul/slater/cut @@ -15,7 +16,7 @@ pair_coeff: ! | extract: ! "" natoms: 29 init_vdwl: 0 -init_coul: -98.7571172175919 +init_coul: -98.75711721759194 init_stress: ! |- -3.9313572784781172e+00 -2.1945725976031827e+01 -3.0990906040599736e+01 6.4439048479767926e+00 -2.3281728573203475e+00 4.0566157434427641e-01 init_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_slater_long.yaml b/unittest/force-styles/tests/mol-pair-coul_slater_long.yaml index b731508901..becaaddacb 100644 --- a/unittest/force-styles/tests/mol-pair-coul_slater_long.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_slater_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:43 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair coul/slater/long @@ -20,7 +21,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: 531.695997894818 +init_coul: 531.6959978948178 init_stress: ! |2- 2.5972486027624825e+02 1.6017698793801901e+02 2.4137753464923463e+02 1.1278136362375312e+02 7.5965726957592040e+01 4.3719482306226765e-01 init_forces: ! |2 @@ -54,7 +55,7 @@ init_forces: ! |2 28 -5.1807337133621779e+01 2.4969152478376095e+01 -3.5819948334944876e+01 29 4.1532654602026298e+01 5.0825271587590592e+01 9.0234792187328665e+00 run_vdwl: 0 -run_coul: 531.631693843525 +run_coul: 531.6316938435255 run_stress: ! |2- 2.6009236274938775e+02 1.6019149935649892e+02 2.4091972549720990e+02 1.1287278205291214e+02 7.6421249875941328e+01 1.0477154416076908e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_streitz_long.yaml b/unittest/force-styles/tests/mol-pair-coul_streitz_long.yaml index 5c3c637193..fa90dc0d39 100644 --- a/unittest/force-styles/tests/mol-pair-coul_streitz_long.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_streitz_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:43 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair coul/streitz @@ -26,7 +27,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: 19.3337606135276 +init_coul: 19.333760613527634 init_stress: ! |- -5.3086784863631200e+00 -3.8663863505671787e+00 -7.5409592075109311e+00 -2.4239664884128915e+00 -6.4758709853038077e-01 -6.6613393190360437e-01 init_forces: ! |2 @@ -60,7 +61,7 @@ init_forces: ! |2 28 1.4599082339749709e+00 -1.1137079999601494e+00 1.1194166285875853e+00 29 -1.0388110297844579e+00 -1.8210443500550793e+00 -9.9526404197437260e-02 run_vdwl: 0 -run_coul: 17.8169760115007 +run_coul: 17.816976011500685 run_stress: ! |- -5.5793011954282141e+00 -3.8070193642083279e+00 -7.4794630173410894e+00 -2.4558653142135030e+00 -7.0075036097944821e-01 -1.0383497954708332e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_streitz_wolf.yaml b/unittest/force-styles/tests/mol-pair-coul_streitz_wolf.yaml index ec3b354df4..24f6f4f060 100644 --- a/unittest/force-styles/tests/mol-pair-coul_streitz_wolf.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_streitz_wolf.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:43 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair coul/streitz @@ -20,7 +21,7 @@ pair_coeff: ! | extract: ! "" natoms: 29 init_vdwl: 0 -init_coul: 4.52330695008905 +init_coul: 4.5233069500890455 init_stress: ! |- -5.3364203656609357e+00 -3.9274878201804135e+00 -7.6379055532292828e+00 -2.3981973732002277e+00 -6.3571914128820906e-01 -6.3315072609210254e-01 init_forces: ! |2 @@ -54,7 +55,7 @@ init_forces: ! |2 28 1.4672946614091067e+00 -1.1339632350120408e+00 1.1290303061925724e+00 29 -1.0331746995782534e+00 -1.8417135865371881e+00 -9.0661681750742795e-02 run_vdwl: 0 -run_coul: 2.98904393402013 +run_coul: 2.9890439340201334 run_stress: ! |- -5.6078601708855027e+00 -3.8555192197060535e+00 -7.5568621153826454e+00 -2.4336548878477799e+00 -6.9060480033072891e-01 -1.0163079058723261e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_table.yaml b/unittest/force-styles/tests/mol-pair-coul_table.yaml index 6f1077f19b..7f662ea910 100644 --- a/unittest/force-styles/tests/mol-pair-coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 7.5e-14 skip_tests: gpu prerequisites: ! | @@ -22,7 +22,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: 225.821851347828 +init_coul: 225.8218513478281 init_stress: ! |- -2.2776088097081114e+01 -4.2843500270844103e+01 -3.8745980554200742e+01 4.4975228729089247e+00 -6.5239915452582231e+00 9.6798563049241917e+00 init_forces: ! |2 @@ -56,7 +56,7 @@ init_forces: ! |2 28 4.3293131083893304e+00 -4.2323366966791456e+00 3.5451222799829045e+00 29 -1.9216824153792407e+00 -5.8096124052291662e+00 1.1529707688447896e-01 run_vdwl: 0 -run_coul: 225.772087269724 +run_coul: 225.77208726972387 run_stress: ! |- -2.2878994271888388e+01 -4.2864533290609835e+01 -3.8706386047553700e+01 4.4580897260806838e+00 -6.6095207311155475e+00 9.6124915253697747e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_table_cs.yaml b/unittest/force-styles/tests/mol-pair-coul_table_cs.yaml index 983053a88b..9e2f5f9912 100644 --- a/unittest/force-styles/tests/mol-pair-coul_table_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_table_cs.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 7.5e-14 skip_tests: gpu prerequisites: ! | @@ -21,7 +21,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 0 -init_coul: 225.821984927182 +init_coul: 225.82198492718214 init_stress: ! |- -2.2776002872387920e+01 -4.2843445060892144e+01 -3.8745910045204191e+01 4.4975604666991176e+00 -6.5239626917158073e+00 9.6798538936277261e+00 init_forces: ! |2 @@ -55,7 +55,7 @@ init_forces: ! |2 28 4.3292951667819661e+00 -4.2323289861951165e+00 3.5451101405172691e+00 29 -1.9216684483031334e+00 -5.8095961666872364e+00 1.1530046700271843e-01 run_vdwl: 0 -run_coul: 225.772221336362 +run_coul: 225.7722213363616 run_stress: ! |- -2.2878908674571353e+01 -4.2864477977439549e+01 -3.8706315539466445e+01 4.4581274178491608e+00 -6.6094915432451486e+00 9.6124893446999895e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_wolf.yaml b/unittest/force-styles/tests/mol-pair-coul_wolf.yaml index a48fa7f565..7085d28c4e 100644 --- a/unittest/force-styles/tests/mol-pair-coul_wolf.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_wolf.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair coul/wolf @@ -15,7 +16,7 @@ pair_coeff: ! | extract: ! "" natoms: 29 init_vdwl: 0 -init_coul: -115.714526063965 +init_coul: -115.71452606396501 init_stress: ! |- -2.3416595596547022e+01 -4.4252787696446617e+01 -4.0981314239288494e+01 5.0914497780301016e+00 -6.2469109919454260e+00 1.0436684921508713e+01 init_forces: ! |2 @@ -49,7 +50,7 @@ init_forces: ! |2 28 4.4993726667977505e+00 -4.6997287550738651e+00 3.7669799595142255e+00 29 -1.7918917681043876e+00 -6.2865484492348012e+00 3.1996589863779817e-01 run_vdwl: 0 -run_coul: -115.769113007043 +run_coul: -115.76911300704302 run_stress: ! |- -2.3519451591948346e+01 -4.4269900044019352e+01 -4.0933115596461185e+01 5.0512455245215024e+00 -6.3318043371823549e+00 1.0364967781882934e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-coul_wolf_cs.yaml b/unittest/force-styles/tests/mol-pair-coul_wolf_cs.yaml index 32068ba458..0d11d583f5 100644 --- a/unittest/force-styles/tests/mol-pair-coul_wolf_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-coul_wolf_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair coul/wolf/cs @@ -15,7 +16,7 @@ pair_coeff: ! | extract: ! "" natoms: 29 init_vdwl: 0 -init_coul: -115.714526063965 +init_coul: -115.71452606396501 init_stress: ! |- -2.3416595596547022e+01 -4.4252787696446617e+01 -4.0981314239288494e+01 5.0914497780301016e+00 -6.2469109919454260e+00 1.0436684921508713e+01 init_forces: ! |2 @@ -49,7 +50,7 @@ init_forces: ! |2 28 4.4993726667977505e+00 -4.6997287550738651e+00 3.7669799595142255e+00 29 -1.7918917681043876e+00 -6.2865484492348012e+00 3.1996589863779817e-01 run_vdwl: 0 -run_coul: -115.769113007043 +run_coul: -115.76911300704302 run_stress: ! |- -2.3519451591948346e+01 -4.4269900044019352e+01 -4.0933115596461185e+01 5.0512455245215024e+00 -6.3318043371823549e+00 1.0364967781882934e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-dpd.yaml b/unittest/force-styles/tests/mol-pair-dpd.yaml index c3900a3bc6..52aa755489 100644 --- a/unittest/force-styles/tests/mol-pair-dpd.yaml +++ b/unittest/force-styles/tests/mol-pair-dpd.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:29 2022 epsilon: 5e-14 skip_tests: gpu intel single prerequisites: ! | @@ -23,7 +23,7 @@ pair_coeff: ! | 5 5 0.3 3.1 extract: ! "" natoms: 29 -init_vdwl: 50.8160702483393 +init_vdwl: 50.81607024833933 init_coul: 0 init_stress: ! |2- 3.6892707387868946e+01 6.7100128759684480e+01 2.4650529885588522e+01 -1.5957061281779284e+01 -1.8149194861854802e+01 -5.8188961718178627e+00 @@ -57,7 +57,7 @@ init_forces: ! |2 27 -1.2551354817636557e+00 -2.4343811771905930e+00 2.9640832530850625e-01 28 -4.6829625062261160e-01 -1.4739473222403159e+00 1.4861524185706241e+00 29 -4.4395481506746695e+00 -2.5902691799524233e+00 3.2713554765371877e+00 -run_vdwl: 50.8096741022807 +run_vdwl: 50.80967410228065 run_coul: 0 run_stress: ! |2- 2.2678525097938930e+01 1.2784099465722879e+02 8.7854358412948542e+01 -1.0634323344871795e+01 1.4108052497366335e+01 8.9515364908436243e+00 diff --git a/unittest/force-styles/tests/mol-pair-e3b.yaml b/unittest/force-styles/tests/mol-pair-e3b.yaml index 03d74c2069..cf92c6e4a3 100644 --- a/unittest/force-styles/tests/mol-pair-e3b.yaml +++ b/unittest/force-styles/tests/mol-pair-e3b.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/cut/tip4p/cut @@ -32,8 +33,8 @@ pair_coeff: ! | * * e3b preset 2015 extract: ! "" natoms: 29 -init_vdwl: 584.671488129934 -init_coul: -128.977932168035 +init_vdwl: 584.6714881299338 +init_coul: -128.97793216803515 init_stress: ! |2- 1.4231803769197056e+03 1.6927616344571190e+03 3.8078398830142301e+03 -1.0764791807445065e+03 -2.0803020422504056e+02 7.2362454225684814e+02 init_forces: ! |2 @@ -66,8 +67,8 @@ init_forces: ! |2 27 -1.0470258927690863e+00 9.2906307144144673e+00 -3.6990588127802435e+00 28 8.5365856050054738e+00 -2.4636423220451302e+00 4.2276358718634395e+00 29 -3.8831706532739356e+00 -5.2900046950811053e+00 -1.5026494435836046e+00 -run_vdwl: 557.066176544541 -run_coul: -128.962676522943 +run_vdwl: 557.0661765445408 +run_coul: -128.9626765229425 run_stress: ! |2- 1.3827073371577881e+03 1.6513097461669279e+03 3.5578978559523357e+03 -1.0466353253226539e+03 -1.9198540562801580e+02 6.8418143769098492e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-gauss.yaml b/unittest/force-styles/tests/mol-pair-gauss.yaml index 642f2417c8..5df85e0c3f 100644 --- a/unittest/force-styles/tests/mol-pair-gauss.yaml +++ b/unittest/force-styles/tests/mol-pair-gauss.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair gauss @@ -20,7 +21,7 @@ pair_coeff: ! | extract: ! | a 2 natoms: 29 -init_vdwl: -0.386420923215596 +init_vdwl: -0.3864209232155955 init_coul: 0 init_stress: ! |- -2.2163698035273618e-01 -2.4625537112111151e-01 -2.1305188258578470e-01 6.1866130132872003e-02 6.6571531323592207e-03 2.4462489698253043e-02 @@ -54,7 +55,7 @@ init_forces: ! |2 27 1.3703266730383692e-03 6.2247400367154799e-03 -2.6349027873549895e-03 28 4.1766990025931270e-03 -1.2043760854333907e-03 2.6647558305012602e-03 29 -3.5922837617955406e-03 -3.4710661493005325e-03 -1.0719806881093012e-03 -run_vdwl: -0.386350865161716 +run_vdwl: -0.3863508651617164 run_coul: 0 run_stress: ! |- -2.2160110236171965e-01 -2.4617131296379000e-01 -2.1305840663314177e-01 6.1838681126107659e-02 6.6381976968359312e-03 2.4402003044659750e-02 diff --git a/unittest/force-styles/tests/mol-pair-gauss_cut.yaml b/unittest/force-styles/tests/mol-pair-gauss_cut.yaml index c440fc0f1c..faa73cdcf7 100644 --- a/unittest/force-styles/tests/mol-pair-gauss_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-gauss_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:44 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair gauss/cut @@ -19,7 +20,7 @@ pair_coeff: ! | 5 5 0.015 0.114464099895942 0.05 extract: ! "" natoms: 29 -init_vdwl: 0.0295944473865795 +init_vdwl: 0.02959444738657946 init_coul: 0 init_stress: ! |2- 8.9084078901764965e-02 1.4344526020208431e-01 -4.5675567211783404e-02 3.0304038957304099e-02 -3.9550748441137241e-02 -3.6653682970828876e-02 @@ -53,7 +54,7 @@ init_forces: ! |2 27 3.9020791209522708e-19 -3.1697607441541547e-19 3.0469446378497774e-19 28 -3.1076733010138523e-06 -1.1895073734336863e-06 2.1100984785083611e-07 29 1.2358705891224646e-02 5.2235910555193882e-03 -3.9039969829795730e-03 -run_vdwl: 0.0296077380266488 +run_vdwl: 0.029607738026648782 run_coul: 0 run_stress: ! |2- 8.8680865019362426e-02 1.4349057803580620e-01 -4.5973648658997335e-02 2.9363278878411954e-02 -3.9116155698441124e-02 -3.6539257116222253e-02 diff --git a/unittest/force-styles/tests/mol-pair-hybrid-overlay.yaml b/unittest/force-styles/tests/mol-pair-hybrid-overlay.yaml index 6559e2d53c..b067187cc6 100644 --- a/unittest/force-styles/tests/mol-pair-hybrid-overlay.yaml +++ b/unittest/force-styles/tests/mol-pair-hybrid-overlay.yaml @@ -1,8 +1,8 @@ --- -lammps_version: 8 Apr 2021 -date_generated: Mon Apr 19 08:49:07 2021 -skip_tests: kokkos_omp +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-13 +skip_tests: kokkos_omp prerequisites: ! | atom full pair lj/cut diff --git a/unittest/force-styles/tests/mol-pair-hybrid-scaled.yaml b/unittest/force-styles/tests/mol-pair-hybrid-scaled.yaml index 814f3780fe..41cbdb5ca0 100644 --- a/unittest/force-styles/tests/mol-pair-hybrid-scaled.yaml +++ b/unittest/force-styles/tests/mol-pair-hybrid-scaled.yaml @@ -1,8 +1,8 @@ --- -lammps_version: 8 Apr 2021 -date_generated: Mon Apr 19 08:49:07 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-14 -skip_tests: gpu intel omp kokkos_omp +skip_tests: gpu intel kokkos_omp omp prerequisites: ! | atom full pair lj/cut diff --git a/unittest/force-styles/tests/mol-pair-lennard_mdf.yaml b/unittest/force-styles/tests/mol-pair-lennard_mdf.yaml index 4ba3045057..c77280a08c 100644 --- a/unittest/force-styles/tests/mol-pair-lennard_mdf.yaml +++ b/unittest/force-styles/tests/mol-pair-lennard_mdf.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:45 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lennard/mdf @@ -28,7 +29,7 @@ pair_coeff: ! | extract: ! | a 2 natoms: 29 -init_vdwl: 749.238128769917 +init_vdwl: 749.2381287699166 init_coul: 0 init_stress: ! |2- 2.1793844857971999e+03 2.1988910807167222e+03 4.6653956464347129e+03 -7.5956623392527081e+02 2.4752218664716132e+01 6.6652254832700407e+02 @@ -62,7 +63,7 @@ init_forces: ! |2 27 5.1810629413951034e+01 -2.2705426061698427e+02 9.0848881987846823e+01 28 -1.8041314536249808e+02 7.7534100857114538e+01 -1.2206963127965679e+02 29 1.2861063445049953e+02 1.4952718810862598e+02 3.1216037810340779e+01 -run_vdwl: 719.44436226705 +run_vdwl: 719.4443622670501 run_coul: 0 run_stress: ! |2- 2.1330145141050125e+03 2.1547683543089838e+03 4.3976473968701512e+03 -7.3873403814571338e+02 4.1744535857045207e+01 6.2788233468659791e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj96_cut.yaml b/unittest/force-styles/tests/mol-pair-lj96_cut.yaml index 94e19d6663..0d72dcd120 100644 --- a/unittest/force-styles/tests/mol-pair-lj96_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-lj96_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:45 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj96/cut @@ -19,7 +20,7 @@ pair_coeff: ! | 5 5 0.0253125 3.1 extract: ! "" natoms: 29 -init_vdwl: 112.146791176334 +init_vdwl: 112.14679117633445 init_coul: 0 init_stress: ! |2- 2.7158278777258107e+02 2.7440178205574091e+02 5.0791544617614926e+02 -7.4064553668076726e+01 1.5914543736637080e+01 6.4534029091470870e+01 @@ -53,7 +54,7 @@ init_forces: ! |2 27 6.4971923893309373e+00 -3.1514490531631594e+01 1.2213590546072449e+01 28 -2.4531453852672385e+01 1.0543491079658937e+01 -1.6598700916460793e+01 29 1.8044637138654299e+01 2.0979972864085106e+01 4.3789473475744867e+00 -run_vdwl: 111.831461661122 +run_vdwl: 111.83146166112233 run_coul: 0 run_stress: ! |2- 2.7182104129385465e+02 2.7435027767758265e+02 5.0483269558351475e+02 -7.3587953393135308e+01 1.6159137974645954e+01 6.4540935527934977e+01 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_charmm.yaml b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_charmm.yaml index 452a1b58d6..a6ce470320 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_charmm.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_charmm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:45 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 7e-14 +skip_tests: prerequisites: ! | atom full pair lj/charmm/coul/charmm @@ -24,8 +25,8 @@ extract: ! | lj14_4 2 implicit 0 natoms: 29 -init_vdwl: 749.237668227108 -init_coul: -108.290049382542 +init_vdwl: 749.2376682271083 +init_coul: -108.29004938254235 init_stress: ! |2- 2.1552748494143407e+03 2.1550005644561579e+03 4.6251072425283146e+03 -7.5355306177303589e+02 1.7781989272135156e+01 6.7159660215275790e+02 init_forces: ! |2 @@ -58,8 +59,8 @@ init_forces: ! |2 27 4.8640279708056994e+01 -2.1561983683662956e+02 8.6562127166872585e+01 28 -1.7529971979703151e+02 7.2819913213128288e+01 -1.1821539358587464e+02 29 1.2695492725304132e+02 1.4275558335476956e+02 3.1862100795322899e+01 -run_vdwl: 719.58713774632 -run_coul: -108.261820989327 +run_vdwl: 719.5871377463195 +run_coul: -108.26182098932698 run_stress: ! |2- 2.1093940982116214e+03 2.1110892652935627e+03 4.3584103399795022e+03 -7.3252709893204678e+02 3.4960525980576286e+01 6.3293986693153204e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_charmm_implicit.yaml b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_charmm_implicit.yaml index f43a232db4..19651c541c 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_charmm_implicit.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_charmm_implicit.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:45 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair lj/charmm/coul/charmm/implicit @@ -24,8 +25,8 @@ extract: ! | lj14_4 2 implicit 0 natoms: 29 -init_vdwl: 749.237668227108 -init_coul: -106.563707887087 +init_vdwl: 749.2376682271083 +init_coul: -106.56370788708746 init_stress: ! |2- 2.1132972930752935e+03 2.1373125533614921e+03 4.5481605230749637e+03 -7.8484201108008779e+02 9.7286425981734648e-01 6.6737572817429782e+02 init_forces: ! |2 @@ -58,8 +59,8 @@ init_forces: ! |2 27 4.6364112435702893e+01 -2.0540113175488810e+02 8.3024621447653075e+01 28 -1.6662994528688827e+02 6.9019404330712874e+01 -1.1270127644409283e+02 29 1.2070793463535765e+02 1.3443766216040447e+02 3.1390940542732309e+01 -run_vdwl: 719.802040379616 -run_coul: -106.341473801626 +run_vdwl: 719.8020403796164 +run_coul: -106.34147380162588 run_stress: ! |2- 2.0683942556220563e+03 2.0937841185371062e+03 4.2833742375515549e+03 -7.6367164626762872e+02 1.8160880891129729e+01 6.2876371589411906e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_long.yaml index eaa7ca4fa5..464099729d 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:45 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | atom full pair lj/charmm/coul/long @@ -30,8 +31,8 @@ extract: ! | implicit 0 cut_coul 0 natoms: 29 -init_vdwl: 749.237668227108 -init_coul: 225.821815126925 +init_vdwl: 749.2376682271083 +init_coul: 225.82181512692495 init_stress: ! |2- 2.1566082274410323e+03 2.1560465648122754e+03 4.6266523051625063e+03 -7.5506869800207198e+02 1.8228301145095919e+01 6.7620190480242991e+02 init_forces: ! |2 @@ -64,8 +65,8 @@ init_forces: ! |2 27 4.9789629454245969e+01 -2.1702104505766846e+02 8.7170153066070696e+01 28 -1.7608382764129951e+02 7.3301762786387741e+01 -1.1852450858699228e+02 29 1.2668895346087699e+02 1.4371758145657193e+02 3.1331337070942034e+01 -run_vdwl: 719.571434348956 -run_coul: 225.90423714484 +run_vdwl: 719.5714343489557 +run_coul: 225.9042371448398 run_stress: ! |2- 2.1107000227891581e+03 2.1121506817933068e+03 4.3598676778975105e+03 -7.3407478186600042e+02 3.5368419084644287e+01 6.3752997609587146e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_long_soft.yaml b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_long_soft.yaml index ddc944f84b..567348ccdb 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_long_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_long_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:45 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/charmm/coul/long/soft @@ -31,8 +32,8 @@ extract: ! | implicit 0 cut_coul 0 natoms: 29 -init_vdwl: 0.0870608994865688 -init_coul: 26.4864428259304 +init_vdwl: 0.08706089948656884 +init_coul: 26.486442825930396 init_stress: ! |- -9.1272913010153811e-01 -4.3887362745626044e+00 -3.1967462851505650e+00 1.5302397885103485e+00 -2.6618292754008194e-01 1.1864876982964698e+00 init_forces: ! |2 @@ -65,8 +66,8 @@ init_forces: ! |2 27 -1.7551531704171702e-01 6.6588106276847814e-01 -2.5211663664373374e-01 28 1.5473142633686865e-01 -3.3070958116386345e-01 1.7192605646732770e-01 29 7.9295234000756817e-02 -3.3696482169090269e-01 7.7692317052364929e-02 -run_vdwl: 0.0870093421955066 -run_coul: 26.4738674237813 +run_vdwl: 0.08700934219550659 +run_coul: 26.473867423781265 run_stress: ! |- -9.1724546220915149e-01 -4.3886311602289378e+00 -3.1927905190886716e+00 1.5279209924481243e+00 -2.6997992353776179e-01 1.1833674648942241e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_msm.yaml b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_msm.yaml index c374ba6631..b93494d6f7 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_msm.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_msm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:46 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 6e-14 +skip_tests: prerequisites: ! | atom full pair lj/charmm/coul/msm @@ -32,7 +33,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 749.235242989762 -init_coul: 114.131380823567 +init_coul: 114.13138082356693 init_stress: ! |2- 2.1551140272812504e+03 2.1531297570613206e+03 4.6224268563911965e+03 -7.5399507260722862e+02 1.8659550350803705e+01 6.7753821057168352e+02 init_forces: ! |2 @@ -65,8 +66,8 @@ init_forces: ! |2 27 4.9268791156186467e+01 -2.1540598686099841e+02 8.6345383147942030e+01 28 -1.7572634950721937e+02 7.2424827220244183e+01 -1.1807149076862123e+02 29 1.2694498050495100e+02 1.4289100035784023e+02 3.1729222907581573e+01 -run_vdwl: 719.582815872373 -run_coul: 114.220463594378 +run_vdwl: 719.5828158723727 +run_coul: 114.22046359437783 run_stress: ! |2- 2.1092358422575135e+03 2.1092549801735081e+03 4.3557355823049138e+03 -7.3297396422976431e+02 3.5809159341023125e+01 6.3889365673654538e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_msm_table.yaml b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_msm_table.yaml index 5f9053fbb8..7ceab2e9df 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_msm_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_msm_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:46 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 1e-13 skip_tests: gpu prerequisites: ! | @@ -33,7 +33,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: 749.235242989762 -init_coul: 114.131383580102 +init_coul: 114.13138358010185 init_stress: ! |2- 2.1551140289603964e+03 2.1531297597181838e+03 4.6224268583061594e+03 -7.5399507416514484e+02 1.8659551442944785e+01 6.7753821086444407e+02 init_forces: ! |2 @@ -66,8 +66,8 @@ init_forces: ! |2 27 4.9268790999233929e+01 -2.1540598666832003e+02 8.6345383063447272e+01 28 -1.7572634968463726e+02 7.2424826918876605e+01 -1.1807149075889181e+02 29 1.2694498087382951e+02 1.4289100038945139e+02 3.1729223046173637e+01 -run_vdwl: 719.582815872361 -run_coul: 114.220460933603 +run_vdwl: 719.5828158723607 +run_coul: 114.22046093360304 run_stress: ! |2- 2.1092358424448466e+03 2.1092549782135725e+03 4.3557355834206801e+03 -7.3297396482794727e+02 3.5809159695238378e+01 6.3889365386521877e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_table.yaml b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_table.yaml index 17a06d99f3..faa6156fc1 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmm_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmm_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:46 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-13 skip_tests: gpu prerequisites: ! | @@ -31,8 +31,8 @@ extract: ! | implicit 0 cut_coul 0 natoms: 29 -init_vdwl: 749.237668227108 -init_coul: 225.821851347828 +init_vdwl: 749.2376682271083 +init_coul: 225.8218513478281 init_stress: ! |2- 2.1566082477037544e+03 2.1560465705683437e+03 4.6266523185871292e+03 -7.5506869470747893e+02 1.8228310640240899e+01 6.7620190889309049e+02 init_forces: ! |2 @@ -65,8 +65,8 @@ init_forces: ! |2 27 4.9789629338882591e+01 -2.1702104489195116e+02 8.7170152872148577e+01 28 -1.7608383035284197e+02 7.3301761851485111e+01 -1.1852450980305292e+02 29 1.2668895608425100e+02 1.4371758196584054e+02 3.1331338576767038e+01 -run_vdwl: 719.571434315538 -run_coul: 225.904269147748 +run_vdwl: 719.5714343155377 +run_coul: 225.9042691477477 run_stress: ! |2- 2.1107000376249293e+03 2.1121506818905805e+03 4.3598676876880390e+03 -7.3407477695911439e+02 3.5368424794838099e+01 6.3752998026727164e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_charmmfsw.yaml b/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_charmmfsw.yaml index 4ed8721c7e..05d291d4fb 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_charmmfsw.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_charmmfsw.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:46 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/charmmfsw/coul/charmmfsh @@ -24,8 +25,8 @@ extract: ! | lj14_4 2 implicit 0 natoms: 29 -init_vdwl: 749.251705989054 -init_coul: -81.8332788948413 +init_vdwl: 749.2517059890541 +init_coul: -81.83327889484134 init_stress: ! |2- 2.1548579618746862e+03 2.1552552445801803e+03 4.6226577599537195e+03 -7.5607666485336358e+02 1.9373743496376896e+01 6.7668713401334730e+02 init_forces: ! |2 @@ -59,7 +60,7 @@ init_forces: ! |2 28 -1.7560470224833779e+02 7.2224321811604753e+01 -1.1795950384540764e+02 29 1.2681366777620973e+02 1.4256971961228845e+02 3.1806925095570197e+01 run_vdwl: 719.605610058691 -run_coul: -81.7415665262046 +run_coul: -81.74156652620462 run_stress: ! |2- 2.1089926489561076e+03 2.1113852262883292e+03 4.3560155848098948e+03 -7.3504060382009311e+02 3.6514409677293408e+01 6.3806441362950068e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_long.yaml index 0b95c6c4d0..0b0bd93511 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:46 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:30 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair lj/charmmfsw/coul/long @@ -33,8 +34,8 @@ extract: ! | cut_lj 0 dihedflag 0 natoms: 29 -init_vdwl: 749.251705989054 -init_coul: 225.827180766312 +init_vdwl: 749.2517059890541 +init_coul: 225.82718076631187 init_stress: ! |2- 2.1566094937593384e+03 2.1560530990309508e+03 4.6266529212379801e+03 -7.5506782353342248e+02 1.8227021990638967e+01 6.7620037217275819e+02 init_forces: ! |2 @@ -67,8 +68,8 @@ init_forces: ! |2 27 4.9789244657638250e+01 -2.1702149805292603e+02 8.7170399036639779e+01 28 -1.7608373894634312e+02 7.3301640361340901e+01 -1.1852441542581737e+02 29 1.2668889886115156e+02 1.4371742559187234e+02 3.1331337671189914e+01 -run_vdwl: 719.585473962865 -run_coul: 225.909604651644 +run_vdwl: 719.5854739628651 +run_coul: 225.9096046516438 run_stress: ! |2- 2.1107012998513460e+03 2.1121572220770449e+03 4.3598683165615039e+03 -7.3407390560460340e+02 3.5367139753286040e+01 6.3752843926070409e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_table.yaml b/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_table.yaml index b0dbfacfd9..b2ae3af847 100644 --- a/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_charmmfsw_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:46 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-13 skip_tests: gpu prerequisites: ! | @@ -31,8 +31,8 @@ extract: ! | implicit 0 cut_coul 0 natoms: 29 -init_vdwl: 749.251705989054 -init_coul: 225.827216988076 +init_vdwl: 749.2517059890541 +init_coul: 225.82721698807558 init_stress: ! |2- 2.1566095140225407e+03 2.1560531047871550e+03 4.6266529346629231e+03 -7.5506782023875098e+02 1.8227031486011814e+01 6.7620037626351427e+02 init_forces: ! |2 @@ -66,7 +66,7 @@ init_forces: ! |2 28 -1.7608374165795001e+02 7.3301639426416060e+01 -1.1852441664190688e+02 29 1.2668890148458790e+02 1.4371742610115308e+02 3.1331339177050701e+01 run_vdwl: 719.585473929458 -run_coul: 225.909636643767 +run_coul: 225.90963664376727 run_stress: ! |2- 2.1107013146571121e+03 2.1121572221710703e+03 4.3598683263365974e+03 -7.3407390071038674e+02 3.5367145460328587e+01 6.3752844341643333e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2.yaml b/unittest/force-styles/tests/mol-pair-lj_class2.yaml index ba4989e6e2..912d73a696 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:46 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/class2 @@ -21,7 +22,7 @@ extract: ! | epsilon 2 sigma 2 natoms: 29 -init_vdwl: 33.5760671323649 +init_vdwl: 33.57606713236488 init_coul: 0 init_stress: ! |2- 8.1987691502414791e+01 8.3009725941738679e+01 1.5303015406513060e+02 -2.2810640625844286e+01 4.9269726337367228e+00 1.9929429215282934e+01 @@ -55,7 +56,7 @@ init_forces: ! |2 27 1.9470947395789979e+00 -9.4718634154663608e+00 3.6661077043913615e+00 28 -7.3682981937517198e+00 3.1669679119534848e+00 -4.9856163529580284e+00 29 5.4261127187922513e+00 6.3089559593072444e+00 1.3167924699154427e+00 -run_vdwl: 33.5535584108716 +run_vdwl: 33.55355841087158 run_coul: 0 run_stress: ! |2- 8.2178916463120643e+01 8.3101853054825369e+01 1.5253160065343116e+02 -2.2684668843204484e+01 4.9830146128102255e+00 1.9995112924898351e+01 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2_coul_cut.yaml b/unittest/force-styles/tests/mol-pair-lj_class2_coul_cut.yaml index 7855313829..722114bb6f 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2_coul_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2_coul_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:46 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/class2/coul/cut @@ -22,8 +23,8 @@ extract: ! | sigma 2 cut_coul 2 natoms: 29 -init_vdwl: 33.5760671323649 -init_coul: -127.494586297384 +init_vdwl: 33.57606713236488 +init_coul: -127.49458629738443 init_stress: ! |2- 5.5163144467457478e+01 3.9846950837649651e+01 9.5522889906792471e+01 -2.3631191561489757e+01 -2.9802974726562206e+00 2.2984638416695610e+01 init_forces: ! |2 @@ -57,7 +58,7 @@ init_forces: ! |2 28 -2.5218777861769843e+00 -2.1240703931003635e+00 -9.0472621239313922e-01 29 4.1625007105019449e+00 1.3702046178964156e-01 2.2389851490745278e+00 run_vdwl: 33.5589655379567 -run_coul: -127.545695939556 +run_coul: -127.54569593955645 run_stress: ! |2- 5.5270252973268654e+01 3.9931680555834149e+01 9.5114369967849470e+01 -2.3535631988638428e+01 -2.9991612450934029e+00 2.2985558038048861e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2_coul_cut_soft.yaml b/unittest/force-styles/tests/mol-pair-lj_class2_coul_cut_soft.yaml index 8ac23b3583..c0f844990c 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2_coul_cut_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2_coul_cut_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:47 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/class2/coul/cut/soft @@ -24,7 +25,7 @@ extract: ! | cut_coul 0 natoms: 29 init_vdwl: -0.0279568869346605 -init_coul: -16.9131718066612 +init_coul: -16.913171806661197 init_stress: ! |- -1.2568075459723569e+00 -4.0978664443210082e+00 -5.7677732235218784e+00 7.9760147162786232e-01 -4.9732737933520765e-01 9.7164487925694876e-02 init_forces: ! |2 @@ -57,8 +58,8 @@ init_forces: ! |2 27 -2.8153635630686236e-01 6.4443404010992456e-01 -3.0459961833196159e-01 28 1.6087710176599712e-01 -4.2329027587759382e-01 1.9390264301028309e-01 29 2.3361353867664425e-01 -2.7922358027060867e-01 2.0657270027457103e-01 -run_vdwl: -0.027955336404486 -run_coul: -16.9161102196865 +run_vdwl: -0.027955336404486022 +run_coul: -16.916110219686505 run_stress: ! |- -1.2609422845016363e+00 -4.0968951390172528e+00 -5.7617307980358792e+00 7.9602111013010879e-01 -5.0064987959633445e-01 9.5505298242496761e-02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_class2_coul_long.yaml index 0bae674a35..76a81bd3bc 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:47 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/class2/coul/long @@ -27,8 +28,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 33.5760671323649 -init_coul: 225.821815126925 +init_vdwl: 33.57606713236488 +init_coul: 225.82181512692495 init_stress: ! |2- 5.9211583142611758e+01 4.0166219914825973e+01 1.1428416008630550e+02 -1.8313121047528654e+01 -1.5970284066690270e+00 2.9609281429548130e+01 init_forces: ! |2 @@ -61,8 +62,8 @@ init_forces: ! |2 27 -7.3960092505173103e-02 5.6121962052620200e-01 -1.2623171994937926e-02 28 -3.0389823738199273e+00 -1.0653678498230301e+00 -1.4404928569144864e+00 29 3.5044276800389929e+00 4.9934304480946157e-01 1.4320880409749164e+00 -run_vdwl: 33.5584908485278 -run_coul: 225.776975154965 +run_vdwl: 33.55849084852781 +run_coul: 225.77697515496493 run_stress: ! |2- 5.9318588735059329e+01 4.0244979361299769e+01 1.1385148389618509e+02 -1.8219393739254063e+01 -1.6182598333884533e+00 2.9608183451995330e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2_coul_long_cs.yaml b/unittest/force-styles/tests/mol-pair-lj_class2_coul_long_cs.yaml index 7f88407d20..d156e44f98 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2_coul_long_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2_coul_long_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:47 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/class2/coul/long/cs @@ -26,8 +27,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 33.5760671322516 -init_coul: 225.8219568135 +init_vdwl: 33.57606713225163 +init_coul: 225.82195681349995 init_stress: ! |2- 5.9211661199733754e+01 4.0166255607400700e+01 1.1428422450031262e+02 -1.8313083049461831e+01 -1.5970106554027541e+00 2.9609283406901994e+01 init_forces: ! |2 @@ -61,7 +62,7 @@ init_forces: ! |2 28 -3.0389983162164067e+00 -1.0653596341201383e+00 -1.4405040256236372e+00 29 3.5044395390014174e+00 4.9935845947163410e-01 1.4320906963269642e+00 run_vdwl: 33.5584908346898 -run_coul: 225.777117217651 +run_coul: 225.77711721765144 run_stress: ! |2- 5.9318667074017746e+01 4.0245015104909228e+01 1.1385154821050502e+02 -1.8219355680157076e+01 -1.6182417814766263e+00 2.9608185646082884e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2_coul_long_soft.yaml b/unittest/force-styles/tests/mol-pair-lj_class2_coul_long_soft.yaml index 673fb46800..935bb48ef1 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2_coul_long_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2_coul_long_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:47 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/class2/coul/long/soft @@ -28,8 +29,8 @@ extract: ! | lambda 2 cut_coul 0 natoms: 29 -init_vdwl: -0.0279568869346605 -init_coul: 26.9521621832406 +init_vdwl: -0.027956886934660502 +init_coul: 26.952162183240606 init_stress: ! |- -1.0979342688867924e+00 -4.5861640845557456e+00 -3.4258685036821017e+00 1.5698533700384376e+00 -3.0977826363822086e-01 1.2339097540506174e+00 init_forces: ! |2 @@ -62,8 +63,8 @@ init_forces: ! |2 27 -1.8097814888562413e-01 6.9820913337890733e-01 -2.6340710165001457e-01 28 1.7042543108693975e-01 -3.4356300367399606e-01 1.8420405608797991e-01 29 6.8969492557682449e-02 -3.5687123235543355e-01 7.6959216046372347e-02 -run_vdwl: -0.0279553455281711 -run_coul: 26.9396548204497 +run_vdwl: -0.02795534552817105 +run_coul: 26.939654820449707 run_stress: ! |- -1.1026962923291113e+00 -4.5860313379070510e+00 -3.4217830579049293e+00 1.5673542930346522e+00 -3.1379252211484654e-01 1.2305760388108615e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2_coul_table.yaml b/unittest/force-styles/tests/mol-pair-lj_class2_coul_table.yaml index 9c442b3ac5..d27b88c403 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:47 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-12 skip_tests: gpu prerequisites: ! | @@ -28,8 +28,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 33.5760671323649 -init_coul: 225.821851347828 +init_vdwl: 33.57606713236488 +init_coul: 225.8218513478281 init_stress: ! |2- 5.9211603405333648e+01 4.0166225670894562e+01 1.1428417351092986e+02 -1.8313117752935337e+01 -1.5970189115215223e+00 2.9609285520207152e+01 init_forces: ! |2 @@ -63,7 +63,7 @@ init_forces: ! |2 28 -3.0389850853623903e+00 -1.0653687847256605e+00 -1.4404940729751226e+00 29 3.5044303034130113e+00 4.9934355407807918e-01 1.4320895467999217e+00 run_vdwl: 33.5584908471932 -run_coul: 225.777011309739 +run_coul: 225.7770113097391 run_stress: ! |2- 5.9318609074982867e+01 4.0244984094007023e+01 1.1385149722834394e+02 -1.8219387751229995e+01 -1.6182523439558310e+00 2.9608187931460801e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2_coul_table_cs.yaml b/unittest/force-styles/tests/mol-pair-lj_class2_coul_table_cs.yaml index 8d3537b6c2..631c787432 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2_coul_table_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2_coul_table_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:47 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/class2/coul/long/cs @@ -26,8 +27,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 33.5760671322537 -init_coul: 225.821984927182 +init_vdwl: 33.576067132253726 +init_coul: 225.82198492718214 init_stress: ! |2- 5.9211688629696447e+01 4.0166280880541898e+01 1.1428424401931358e+02 -1.8313080159092728e+01 -1.5969900580111622e+00 2.9609283108833711e+01 init_forces: ! |2 @@ -60,8 +61,8 @@ init_forces: ! |2 27 -7.3956233348773326e-02 5.6119583726967459e-01 -1.2614616590367472e-02 28 -3.0390030269285795e+00 -1.0653610742593265e+00 -1.4405062124128989e+00 29 3.5044442704594507e+00 4.9935979258551688e-01 1.4320929369109603e+00 -run_vdwl: 33.55849083188 -run_coul: 225.777145298871 +run_vdwl: 33.558490831880036 +run_coul: 225.7771452988714 run_stress: ! |2- 5.9318694590157293e+01 4.0245039362292594e+01 1.1385156765039514e+02 -1.8219350091906414e+01 -1.6182231844537791e+00 2.9608185748066493e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_class2_soft.yaml b/unittest/force-styles/tests/mol-pair-lj_class2_soft.yaml index c4bd4c2890..2b12aded01 100644 --- a/unittest/force-styles/tests/mol-pair-lj_class2_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_class2_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:47 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair lj/class2/soft @@ -56,7 +57,7 @@ init_forces: ! |2 27 7.7740979900039434e-04 6.3935242647477069e-04 -4.2466184497333940e-04 28 8.3048734749811267e-05 3.1248528966866243e-05 3.0822826083793829e-05 29 -5.7532973042045847e-05 -2.7672412467805212e-06 -5.4275513300832731e-05 -run_vdwl: -0.0279553425114641 +run_vdwl: -0.027955342511464143 run_coul: 0 run_stress: ! |- -2.3562497940688085e-02 -3.1203935875414219e-02 -1.9194579565053604e-02 3.4356817659739595e-03 4.7042319658996100e-03 3.7443202278747310e-03 diff --git a/unittest/force-styles/tests/mol-pair-lj_cubic.yaml b/unittest/force-styles/tests/mol-pair-lj_cubic.yaml index b0253a8fb0..432e1d5213 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cubic.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cubic.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 30 Nov 2020 -date_generated: Fri Dec 18 22:30:42 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair lj/cubic @@ -53,7 +54,7 @@ init_forces: ! |2 27 8.2825859198612442e+00 -3.6194570067428131e+01 1.4492694352248694e+01 28 -2.8773892797077618e+01 1.2366374307246014e+01 -1.9468877181493664e+01 29 2.0497044211457737e+01 2.3831279505532898e+01 4.9748677443163629e+00 -run_vdwl: 164.176727343123 +run_vdwl: 164.1767273431226 run_coul: 0 run_stress: ! |2- 4.5696669908578690e+02 4.7904134876274537e+02 1.0582153130184231e+03 -2.0794233476691440e+02 -2.0206236712071677e+00 1.5948889982266843e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut.yaml b/unittest/force-styles/tests/mol-pair-lj_cut.yaml index 4aff257f62..58bb0abf08 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/cut @@ -21,7 +22,7 @@ extract: ! | epsilon 2 sigma 2 natoms: 29 -init_vdwl: 749.23722617441 +init_vdwl: 749.2372261744105 init_coul: 0 init_stress: ! |2- 2.1793857186503233e+03 2.1988957679770601e+03 4.6653994738862330e+03 -7.5956544622684294e+02 2.4751393539192360e+01 6.6652061873806701e+02 @@ -55,7 +56,7 @@ init_forces: ! |2 27 5.1810412832327984e+01 -2.2705468907750401e+02 9.0849153441059272e+01 28 -1.8041315533250560e+02 7.7534079082878250e+01 -1.2206962452216491e+02 29 1.2861063251415729e+02 1.4952718246094855e+02 3.1216040111076961e+01 -run_vdwl: 719.443455554292 +run_vdwl: 719.4434555542921 run_coul: 0 run_stress: ! |2- 2.1330157554553721e+03 2.1547730555430498e+03 4.3976512412988704e+03 -7.3873325485023690e+02 4.1743707190786367e+01 6.2788040986774604e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_cut.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_cut.yaml index c08d9cf059..441a84f977 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair lj/cut/coul/cut @@ -22,8 +23,8 @@ extract: ! | sigma 2 cut_coul 2 natoms: 29 -init_vdwl: 749.23722617441 -init_coul: -127.494586297384 +init_vdwl: 749.2372261744105 +init_coul: -127.49458629738443 init_stress: ! |2- 2.1525611716153662e+03 2.1557329928729714e+03 4.6078922097278992e+03 -7.6038599716248871e+02 1.6844123432798593e+01 6.6957582793947995e+02 init_forces: ! |2 @@ -56,8 +57,8 @@ init_forces: ! |2 27 4.8962873327044548e+01 -2.1594272998432456e+02 8.6423916022225754e+01 28 -1.7556673492493090e+02 7.2243040777824405e+01 -1.1798873438160003e+02 29 1.2734702050586698e+02 1.4335524696343094e+02 3.2138232790236046e+01 -run_vdwl: 719.583830971028 -run_coul: -127.405445776932 +run_vdwl: 719.5838309710283 +run_coul: -127.40544577693193 run_stress: ! |2- 2.1066858851705115e+03 2.1118465406255077e+03 4.3411913895839261e+03 -7.3939091944008499e+02 3.4004195376224864e+01 6.3091830979292831e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_cut_soft.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_cut_soft.yaml index 2c37fbefe9..e242a56029 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_cut_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_cut_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair lj/cut/coul/cut/soft @@ -23,8 +24,8 @@ extract: ! | lambda 2 cut_coul 0 natoms: 29 -init_vdwl: 0.0869868307797999 -init_coul: -16.721880512059 +init_vdwl: 0.08698683077979995 +init_coul: -16.721880512058966 init_stress: ! |- -1.0613573795549203e+00 -3.8839205137835902e+00 -5.5134910841142846e+00 7.5801818987704728e-01 -4.5644823344739416e-01 4.8871441509553137e-02 init_forces: ! |2 @@ -57,8 +58,8 @@ init_forces: ! |2 27 -2.7476246020103456e-01 6.0493120625631469e-01 -2.9064786520929453e-01 28 1.4347513760734865e-01 -4.0704325460185131e-01 1.7976862032283397e-01 29 2.4405118264850023e-01 -2.5553143701616343e-01 2.0641926054763102e-01 -run_vdwl: 0.0869352789338978 -run_coul: -16.7246300810242 +run_vdwl: 0.08693527893389784 +run_coul: -16.72463008102423 run_stress: ! |- -1.0652447352865699e+00 -3.8829939850981972e+00 -5.5076420739725851e+00 7.5662871430955769e-01 -4.5956180716232609e-01 4.7459476145516044e-02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_debye.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_debye.yaml index 04e9f26025..af2f94f7ca 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_debye.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_debye.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/cut/coul/debye @@ -22,8 +23,8 @@ extract: ! | sigma 2 cut_coul 2 natoms: 29 -init_vdwl: 749.23722617441 -init_coul: -26.0958890796496 +init_vdwl: 749.2372261744105 +init_coul: -26.095889079649556 init_stress: ! |2- 2.1596680537714560e+03 2.1799981387253574e+03 4.6420976545835829e+03 -7.6548350425867341e+02 2.0048144081872266e+01 6.6900821136809998e+02 init_forces: ! |2 @@ -56,8 +57,8 @@ init_forces: ! |2 27 5.0678817618137757e+01 -2.1955868715215880e+02 8.8185424604605416e+01 28 -1.7648528302762318e+02 7.4689185913776114e+01 -1.1909838750514861e+02 29 1.2585627905014329e+02 1.4488602163099455e+02 3.0900117397816587e+01 -run_vdwl: 719.558238411404 -run_coul: -26.0154865952564 +run_vdwl: 719.5582384114039 +run_coul: -26.01548659525644 run_stress: ! |2- 2.1137295549845740e+03 2.1361119148624657e+03 4.3751903724677404e+03 -7.4447931599140713e+02 3.7119035795274364e+01 6.3036601258050814e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_dsf.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_dsf.yaml index 1e3e4249a6..620b125293 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_dsf.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_dsf.yaml @@ -1,8 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 -skip_tests: kokkos_omp +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 8e-14 +skip_tests: kokkos_omp prerequisites: ! | atom full pair lj/cut/coul/dsf @@ -21,8 +21,8 @@ pair_coeff: ! | extract: ! | cut_coul 0 natoms: 29 -init_vdwl: 749.23722617441 -init_coul: -116.262344977046 +init_vdwl: 749.2372261744105 +init_coul: -116.26234497704607 init_stress: ! |2- 2.1559690526332674e+03 2.1546429476013286e+03 4.6244180998551219e+03 -7.5447402365545327e+02 1.8504455808808729e+01 6.7695730267452313e+02 init_forces: ! |2 @@ -55,8 +55,8 @@ init_forces: ! |2 27 4.9510151487508807e+01 -2.1610573882407331e+02 8.6754624199142910e+01 28 -1.7591376903728431e+02 7.2834345714474324e+01 -1.1830263576328773e+02 29 1.2681873017384437e+02 1.4324062272686339e+02 3.1536002792748356e+01 -run_vdwl: 719.578470973931 -run_coul: -116.176575988872 +run_vdwl: 719.5784709739312 +run_coul: -116.17657598887202 run_stress: ! |2- 2.1100746518878036e+03 2.1107555585308155e+03 4.3576864807684560e+03 -7.3346402806051049e+02 3.5650252706810363e+01 6.3830265269970880e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_long.yaml index e16d0ac162..d0f55800c0 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair lj/cut/coul/long @@ -27,8 +28,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.23722617441 -init_coul: 225.821815126925 +init_vdwl: 749.2372261744105 +init_coul: 225.82181512692495 init_stress: ! |2- 2.1566096102905212e+03 2.1560522619501480e+03 4.6266534799074097e+03 -7.5506792664852810e+02 1.8227392498787179e+01 6.7620047095233247e+02 init_forces: ! |2 @@ -62,7 +63,7 @@ init_forces: ! |2 28 -1.7608383951257380e+02 7.3301743321101739e+01 -1.1852450102612136e+02 29 1.2668894747540401e+02 1.4371756954645073e+02 3.1331335682136434e+01 run_vdwl: 719.570991322032 -run_coul: 225.904237156271 +run_coul: 225.9042371562709 run_stress: ! |2- 2.1107014053468865e+03 2.1121563786867737e+03 4.3598688519011475e+03 -7.3407401306070096e+02 3.5367507798830353e+01 6.3752854031292122e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_long_cs.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_long_cs.yaml index 763470b674..2916da2fe6 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_long_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_long_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 2e-13 +skip_tests: prerequisites: ! | atom full pair lj/cut/coul/long/cs @@ -27,8 +28,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.23722617121 -init_coul: 225.8219568135 +init_vdwl: 749.2372261712098 +init_coul: 225.82195681349995 init_stress: ! |2- 2.1566096883368577e+03 2.1560522976327766e+03 4.6266535442985187e+03 -7.5506788864802854e+02 1.8227410249581407e+01 6.7620047292671313e+02 init_forces: ! |2 @@ -61,8 +62,8 @@ init_forces: ! |2 27 4.9789361752827517e+01 -2.1702162992279213e+02 8.7170431201336527e+01 28 -1.7608385545374182e+02 7.3301751536276697e+01 -1.1852451219399934e+02 29 1.2668895933351085e+02 1.4371758496011822e+02 3.1331338337280808e+01 -run_vdwl: 719.570990985203 -run_coul: 225.904377274686 +run_vdwl: 719.5709909852035 +run_coul: 225.90437727468571 run_stress: ! |2- 2.1107014816059227e+03 2.1121564133075194e+03 4.3598689136584017e+03 -7.3407397590385597e+02 3.5367525146098124e+01 6.3752854232069581e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_long_soft.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_long_soft.yaml index 70f45edc6f..8eca065092 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_long_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_long_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/cut/coul/long/soft @@ -28,8 +29,8 @@ extract: ! | lambda 2 cut_coul 0 natoms: 29 -init_vdwl: 0.0869868307797999 -init_coul: 26.4864428259304 +init_vdwl: 0.08698683077979995 +init_coul: 26.486442825930396 init_stress: ! |- -9.1249731153318292e-01 -4.3877814604377434e+00 -3.1965493449598563e+00 1.5303690111499872e+00 -2.6633522920029479e-01 1.1862474435756334e+00 init_forces: ! |2 @@ -62,8 +63,8 @@ init_forces: ! |2 27 -1.7556081111367022e-01 6.6578706971019974e-01 -2.5207147463850749e-01 28 1.5472943489635349e-01 -3.3071284636771298e-01 1.7192732481352638e-01 29 7.9294229865242635e-02 -3.3696681975738607e-01 7.7692084065202061e-02 -run_vdwl: 0.086935277212183 -run_coul: 26.4738674243055 +run_vdwl: 0.08693527721218298 +run_coul: 26.473867424305528 run_stress: ! |- -9.1701350463041709e-01 -4.3876757420292520e+00 -3.1925937335520391e+00 1.5280501208185095e+00 -2.7013227375472720e-01 1.1831272134729816e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_msm.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_msm.yaml index 7e0505220e..7ac0fdb6a0 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_msm.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_msm.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:48 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:31 2022 epsilon: 7.5e-14 skip_tests: gpu prerequisites: ! | @@ -29,8 +29,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.234609413223 -init_coul: 114.131380823567 +init_vdwl: 749.2346094132226 +init_coul: 114.13138082356693 init_stress: ! |2- 2.1551147118149142e+03 2.1531310016450821e+03 4.6224274885907998e+03 -7.5399488884461846e+02 1.8659600825010816e+01 6.7753815235266666e+02 init_forces: ! |2 @@ -63,8 +63,8 @@ init_forces: ! |2 27 4.9268806567247346e+01 -2.1540599266520917e+02 8.6345394436784431e+01 28 -1.7572634923909956e+02 7.2424827393790522e+01 -1.1807149056284722e+02 29 1.2694498092952055e+02 1.4289100071158703e+02 3.1729222911990778e+01 -run_vdwl: 719.582182590996 -run_coul: 114.220463593576 +run_vdwl: 719.5821825909958 +run_coul: 114.2204635935765 run_stress: ! |2- 2.1092365276732253e+03 2.1092562258583794e+03 4.3557362156705476e+03 -7.3297378066110355e+02 3.5809210365937368e+01 6.3889360029491104e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_msm_table.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_msm_table.yaml index 3c9bf6e724..b13e987c08 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_msm_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_msm_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:49 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 1e-13 skip_tests: gpu prerequisites: ! | @@ -29,8 +29,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.234609413223 -init_coul: 114.131383580102 +init_vdwl: 749.2346094132226 +init_coul: 114.13138358010185 init_stress: ! |2- 2.1551147134940634e+03 2.1531310043019439e+03 4.6224274905057619e+03 -7.5399489040253616e+02 1.8659601917152798e+01 6.7753815264542743e+02 init_forces: ! |2 @@ -63,8 +63,8 @@ init_forces: ! |2 27 4.9268806410294808e+01 -2.1540599247253076e+02 8.6345394352289631e+01 28 -1.7572634941651745e+02 7.2424827092422973e+01 -1.1807149055311780e+02 29 1.2694498129839906e+02 1.4289100074319830e+02 3.1729223050582846e+01 -run_vdwl: 719.582182590983 -run_coul: 114.22046093329 +run_vdwl: 719.5821825909827 +run_coul: 114.22046093328994 run_stress: ! |2- 2.1092365278604757e+03 2.1092562238992905e+03 4.3557362167859274e+03 -7.3297378125979174e+02 3.5809210720302019e+01 6.3889359742297256e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_table.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_table.yaml index fe0bd28d96..54a8dc7e7f 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:49 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-13 skip_tests: gpu prerequisites: ! | @@ -28,8 +28,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.23722617441 -init_coul: 225.821851347828 +init_vdwl: 749.2372261744105 +init_coul: 225.8218513478281 init_stress: ! |2- 2.1566096305532428e+03 2.1560522677062158e+03 4.6266534933320354e+03 -7.5506792335393379e+02 1.8227401993933608e+01 6.7620047504299214e+02 init_forces: ! |2 @@ -62,8 +62,8 @@ init_forces: ! |2 27 4.9789357884880488e+01 -2.1702160587579414e+02 8.7170422370750828e+01 28 -1.7608384222411630e+02 7.3301742386199109e+01 -1.1852450224218201e+02 29 1.2668895009877801e+02 1.4371757005571936e+02 3.1331337187961438e+01 -run_vdwl: 719.570991288614 -run_coul: 225.904269157132 +run_vdwl: 719.5709912886141 +run_coul: 225.90426915713164 run_stress: ! |2- 2.1107014201839611e+03 2.1121563787791556e+03 4.3598688616907511e+03 -7.3407400815170706e+02 3.5367513511177357e+01 6.3752854448547271e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_table_cs.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_table_cs.yaml index 179900a1f2..485aaf7b11 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_table_cs.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_table_cs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:49 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair lj/cut/coul/long/cs @@ -27,8 +28,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.237226171238 -init_coul: 225.821984927182 +init_vdwl: 749.2372261712384 +init_coul: 225.82198492718214 init_stress: ! |2- 2.1566097157669415e+03 2.1560523229060404e+03 4.6266535638176556e+03 -7.5506788575767314e+02 1.8227430846963689e+01 6.7620047262857724e+02 init_forces: ! |2 @@ -62,7 +63,7 @@ init_forces: ! |2 28 -1.7608386016445402e+02 7.3301750096137496e+01 -1.1852451438078860e+02 29 1.2668896406496889e+02 1.4371758629323210e+02 3.1331340577864808e+01 run_vdwl: 719.570990914285 -run_coul: 225.90440119896 +run_coul: 225.9044011989597 run_stress: ! |2- 2.1107015034365818e+03 2.1121564327937999e+03 4.3598689294362703e+03 -7.3407397138118756e+02 3.5367541930236200e+01 6.3752854218562106e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_coul_wolf.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_coul_wolf.yaml index 28b6525f19..0e66c9be04 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_coul_wolf.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_coul_wolf.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:49 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/cut/coul/wolf @@ -19,8 +20,8 @@ pair_coeff: ! | 5 5 0.015 3.1 extract: ! "" natoms: 29 -init_vdwl: 749.23722617441 -init_coul: -115.714526063965 +init_vdwl: 749.2372261744105 +init_coul: -115.71452606396501 init_stress: ! |2- 2.1559691230537778e+03 2.1546429802806128e+03 4.6244181596469462e+03 -7.5447399644881307e+02 1.8504482547246504e+01 6.7695730365957650e+02 init_forces: ! |2 @@ -53,8 +54,8 @@ init_forces: ! |2 27 4.9510154330081832e+01 -2.1610575460234838e+02 8.6754629656822544e+01 28 -1.7591378266570788e+02 7.2834350327804387e+01 -1.1830264456265071e+02 29 1.2681874074605287e+02 1.4324063401171372e+02 3.1536006009714757e+01 -run_vdwl: 719.578470681595 -run_coul: -115.628022767293 +run_vdwl: 719.5784706815951 +run_coul: -115.62802276729329 run_stress: ! |2- 2.1100747209994188e+03 2.1107555903838120e+03 4.3576865384721177e+03 -7.3346400125986247e+02 3.5650279092755696e+01 6.3830265374008570e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_soft.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_soft.yaml index aaa232079c..fb11a18056 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:49 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair lj/cut/soft @@ -21,7 +22,7 @@ extract: ! | epsilon 2 sigma 2 natoms: 29 -init_vdwl: -0.0428396313094945 +init_vdwl: -0.04283963130949453 init_coul: 0 init_stress: ! |- -3.7150294178485088e-02 -4.4269784260765020e-02 -3.3385877908707000e-02 3.9789543272128278e-03 1.2200860941829079e-02 5.0820551468292834e-03 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_cut.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_cut.yaml index d57e1df73a..7edf4f84a6 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:49 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | atom full pair lj/cut/tip4p/cut @@ -24,8 +25,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 584.670383161597 -init_coul: -128.977932168035 +init_vdwl: 584.6703831615966 +init_coul: -128.97793216803515 init_stress: ! |2- 1.4231788668968429e+03 1.6927574767724261e+03 3.8078398168257504e+03 -1.0764787790650696e+03 -2.0803003943962983e+02 7.2362441321593531e+02 init_forces: ! |2 @@ -58,8 +59,8 @@ init_forces: ! |2 27 -1.0468877328824875e+00 9.2905066770498319e+00 -3.6991349617673341e+00 28 8.5365856050054738e+00 -2.4636423220451302e+00 4.2276358718634395e+00 29 -3.8831706532739356e+00 -5.2900046950811053e+00 -1.5026494435836046e+00 -run_vdwl: 557.065052509673 -run_coul: -128.962676495281 +run_vdwl: 557.0650525096733 +run_coul: -128.96267649528136 run_stress: ! |2- 1.3827058216866565e+03 1.6513055817059324e+03 3.5578975730219054e+03 -1.0466349203417344e+03 -1.9198520770024712e+02 6.8418126100260508e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_long.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_long.yaml index eaf9bf1a7c..2579a3bf6c 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:49 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-12 +skip_tests: prerequisites: ! | atom full pair lj/cut/tip4p/long @@ -34,8 +35,8 @@ extract: ! | typeA 0 typeB 0 natoms: 29 -init_vdwl: 584.670383161597 -init_coul: 220.904555359383 +init_vdwl: 584.6703831615966 +init_coul: 220.90455535938298 init_stress: ! |2- 1.4179908002675882e+03 1.6981521472771326e+03 3.8247898365498659e+03 -1.0685165973996445e+03 -2.2301723469314501e+02 7.0678972133133993e+02 init_forces: ! |2 @@ -68,8 +69,8 @@ init_forces: ! |2 27 -1.5292288824966405e+00 7.3670370809055621e+00 -2.7248017347638225e+00 28 6.4035032875423159e+00 -2.1779017025677483e+00 4.1727109672631357e+00 29 -4.5201953782892055e+00 -5.1735155675050022e+00 -1.4886429234413563e+00 -run_vdwl: 557.056030476991 -run_coul: 220.91388439321 +run_vdwl: 557.0560304769907 +run_coul: 220.91388439320994 run_stress: ! |2- 1.3775223750599198e+03 1.6566888200245041e+03 3.5747572154246241e+03 -1.0386782389667430e+03 -2.0694915325068985e+02 6.6732651501863472e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_long_soft.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_long_soft.yaml index e126838215..a032e501dd 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_long_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_long_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full pair lj/cut/tip4p/long/soft @@ -35,8 +36,8 @@ extract: ! | typeA 0 typeB 0 natoms: 29 -init_vdwl: 0.0532418429363291 -init_coul: 25.1120046635773 +init_vdwl: 0.053241842936329095 +init_coul: 25.112004663577313 init_stress: ! |- -1.1823845649927935e+00 -4.2392955721273395e+00 -3.0504224276732574e+00 1.3375722516580162e+00 -4.6999744312072916e-01 1.0363313128899019e+00 init_forces: ! |2 @@ -69,8 +70,8 @@ init_forces: ! |2 27 -1.2560375316578029e-01 4.3585239984075247e-01 -1.6791098393172349e-01 28 2.1929824730708886e-01 -1.8521499231588326e-01 1.7256183204536221e-01 29 -4.1398301000284597e-02 -2.4960242874190633e-01 -1.0023685346890519e-02 -run_vdwl: 0.053197202996133 -run_coul: 25.1032924856292 +run_vdwl: 0.053197202996133036 +run_coul: 25.103292485629176 run_stress: ! |- -1.1856867406701521e+00 -4.2391316930158291e+00 -3.0468277969956912e+00 1.3354423157961397e+00 -4.7326789214355075e-01 1.0337076519425354e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_table.yaml b/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_table.yaml index f8c3e70c6f..34a48e8f5f 100644 --- a/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_cut_tip4p_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-13 skip_tests: gpu prerequisites: ! | @@ -35,8 +35,8 @@ extract: ! | typeA 0 typeB 0 natoms: 29 -init_vdwl: 584.670383161597 -init_coul: 220.904588455609 +init_vdwl: 584.6703831615966 +init_coul: 220.90458845560877 init_stress: ! |2- 1.4179908194794866e+03 1.6981521517100007e+03 3.8247898490384250e+03 -1.0685165954305710e+03 -2.2301722609703918e+02 7.0678972492750643e+02 init_forces: ! |2 @@ -69,8 +69,8 @@ init_forces: ! |2 27 -1.5292288657572302e+00 7.3670372933400197e+00 -2.7248019284366976e+00 28 6.4035005649493479e+00 -2.1779026033513014e+00 4.1727097093108574e+00 29 -4.5201927345996555e+00 -5.1735150000565087e+00 -1.4886414114327997e+00 -run_vdwl: 557.056030469831 -run_coul: 220.913919083366 +run_vdwl: 557.0560304698306 +run_coul: 220.91391908336558 run_stress: ! |2- 1.3775223934446942e+03 1.6566888251808541e+03 3.5747572317224108e+03 -1.0386782354472311e+03 -2.0694914638197031e+02 6.6732651943459655e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_expand.yaml b/unittest/force-styles/tests/mol-pair-lj_expand.yaml index fd0d04a6e2..ff7cd9dda2 100644 --- a/unittest/force-styles/tests/mol-pair-lj_expand.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_expand.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair lj/expand @@ -22,7 +23,7 @@ extract: ! | sigma 2 delta 2 natoms: 29 -init_vdwl: 869.656344368552 +init_vdwl: 869.6563443685516 init_coul: 0 init_stress: ! |2- 2.6149341679527661e+03 2.4651524709198543e+03 6.9894859705680365e+03 -7.6909378034189785e+02 -1.7265844171013239e+02 1.1086801931546745e+03 @@ -56,7 +57,7 @@ init_forces: ! |2 27 8.0791097396502110e+01 -3.4145820848332988e+02 1.3823799113869208e+02 28 -2.7341726154320116e+02 1.1750274135971229e+02 -1.8499697414648216e+02 29 1.9263223000268806e+02 2.2396045020016581e+02 4.6755745272658565e+01 -run_vdwl: 803.724793123497 +run_vdwl: 803.7247931234967 run_coul: 0 run_stress: ! |2- 2.5304401272819955e+03 2.3885464610512931e+03 6.2026324553844561e+03 -7.3991414666775518e+02 -9.2728731427343305e+01 9.6357546380783651e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_expand_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_expand_coul_long.yaml index 9f4b5fa97c..4c8f7f456b 100644 --- a/unittest/force-styles/tests/mol-pair-lj_expand_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_expand_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/expand/coul/long @@ -28,8 +29,8 @@ extract: ! | delta 2 cut_coul 0 natoms: 29 -init_vdwl: 869.656344368552 -init_coul: 225.821815126925 +init_vdwl: 869.6563443685516 +init_coul: 225.82181512692495 init_stress: ! |2- 2.5921580595929599e+03 2.4223089648929408e+03 6.9507399765892142e+03 -7.6459626076358222e+02 -1.7918244275053834e+02 1.1183600453689403e+03 init_forces: ! |2 @@ -62,8 +63,8 @@ init_forces: ! |2 27 7.8770042564417935e+01 -3.3142512544733739e+02 1.3455926026230580e+02 28 -2.6908794572326946e+02 1.1327040559793579e+02 -1.8145185065043862e+02 29 1.9071054496393484e+02 2.1815083728566805e+02 4.6871040843718049e+01 -run_vdwl: 803.912465809843 -run_coul: 225.97330421207 +run_vdwl: 803.9124658098428 +run_coul: 225.97330421207045 run_stress: ! |2- 2.5084553180562311e+03 2.3461212422412018e+03 6.1654627283929622e+03 -7.3514733668882184e+02 -9.9027297179894418e+01 9.7331742020710783e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_expand_coul_table.yaml b/unittest/force-styles/tests/mol-pair-lj_expand_coul_table.yaml index e5f31de755..bdd7081e8d 100644 --- a/unittest/force-styles/tests/mol-pair-lj_expand_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_expand_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 2e-13 skip_tests: gpu prerequisites: ! | @@ -29,8 +29,8 @@ extract: ! | delta 2 cut_coul 0 natoms: 29 -init_vdwl: 869.656344368552 -init_coul: 225.821851347828 +init_vdwl: 869.6563443685516 +init_coul: 225.82185134782813 init_stress: ! |2- 2.5921580798556824e+03 2.4223089706490100e+03 6.9507399900138435e+03 -7.6459625746898860e+02 -1.7918243325539206e+02 1.1183600494596001e+03 init_forces: ! |2 @@ -63,8 +63,8 @@ init_forces: ! |2 27 7.8770042449054543e+01 -3.3142512528162013e+02 1.3455926006838362e+02 28 -2.6908794843481189e+02 1.1327040466303316e+02 -1.8145185186649925e+02 29 1.9071054758730884e+02 2.1815083779493665e+02 4.6871042349543053e+01 -run_vdwl: 803.912465762587 -run_coul: 225.973340544803 +run_vdwl: 803.9124657625873 +run_coul: 225.97334054480308 run_stress: ! |2- 2.5084553392801040e+03 2.3461212458808004e+03 6.1654627414386759e+03 -7.3514732916023047e+02 -9.9027288618554820e+01 9.7331742333795171e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_gromacs.yaml b/unittest/force-styles/tests/mol-pair-lj_gromacs.yaml index 174c94829d..6c07bb24ce 100644 --- a/unittest/force-styles/tests/mol-pair-lj_gromacs.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_gromacs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/gromacs @@ -19,7 +20,7 @@ pair_coeff: ! | 5 5 0.015 3.1 extract: ! "" natoms: 29 -init_vdwl: 749.251137926933 +init_vdwl: 749.2511379269325 init_coul: 0 init_stress: ! |2- 2.1793860702765442e+03 2.1988973006739548e+03 4.6653997757046463e+03 -7.5956547840977657e+02 2.4751222555462579e+01 6.6652036392888783e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_gromacs_coul_gromacs.yaml b/unittest/force-styles/tests/mol-pair-lj_gromacs_coul_gromacs.yaml index c1a87514f1..42ebecdc25 100644 --- a/unittest/force-styles/tests/mol-pair-lj_gromacs_coul_gromacs.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_gromacs_coul_gromacs.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/gromacs/coul/gromacs @@ -19,8 +20,8 @@ pair_coeff: ! | 5 5 0.015 3.1 extract: ! "" natoms: 29 -init_vdwl: 749.251137926933 -init_coul: -94.9886402094888 +init_vdwl: 749.2511379269325 +init_coul: -94.98864020948878 init_stress: ! |2- 2.1552561531218485e+03 2.1550255017432773e+03 4.6249224326075973e+03 -7.5359058306584893e+02 1.7747577837935879e+01 6.7153011411602813e+02 init_forces: ! |2 @@ -53,8 +54,8 @@ init_forces: ! |2 27 4.8633559941452859e+01 -2.1563836677030434e+02 8.6569402670577887e+01 28 -1.7529561093172813e+02 7.2824409510325737e+01 -1.1821767641024830e+02 29 1.2695735068811611e+02 1.4275665966842291e+02 3.1866592810219235e+01 -run_vdwl: 719.600597109584 -run_coul: -94.8970614160366 +run_vdwl: 719.6005971095838 +run_coul: -94.89706141603662 run_stress: ! |2- 2.1093758219790202e+03 2.1111134180135791e+03 4.3582271150751021e+03 -7.3256586907634733e+02 3.4925363586198564e+01 6.3287307153174061e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_long_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_long_coul_long.yaml index 5c083caeac..7d0e1c70ef 100644 --- a/unittest/force-styles/tests/mol-pair-lj_long_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_long_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 2.5e-09 +skip_tests: prerequisites: ! | atom full pair lj/long/coul/long @@ -28,7 +29,7 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.373800441949 +init_vdwl: 749.3738004419491 init_coul: 225.821815126925 init_stress: ! |2- 2.1566620277629813e+03 2.1561339780157969e+03 4.6267173807038052e+03 -7.5508635107101691e+02 1.8219496027762062e+01 6.7619472632626719e+02 @@ -62,8 +63,8 @@ init_forces: ! |2 27 4.9787264831917881e+01 -2.1702378492861621e+02 8.7171908557180572e+01 28 -1.7608392920071728e+02 7.3301696261204825e+01 -1.1852448703331862e+02 29 1.2668890412943080e+02 1.4371750554744025e+02 3.1331418003647308e+01 -run_vdwl: 719.707466157291 -run_coul: 225.904237287566 +run_vdwl: 719.7074661572909 +run_coul: 225.90423728756593 run_stress: ! |2- 2.1107537188662236e+03 2.1122379542510184e+03 4.3599324983027345e+03 -7.3409237546545421e+02 3.5359612031240225e+01 6.3752276727918104e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_long_coul_off.yaml b/unittest/force-styles/tests/mol-pair-lj_long_coul_off.yaml index b120893757..e31ae64a50 100644 --- a/unittest/force-styles/tests/mol-pair-lj_long_coul_off.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_long_coul_off.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:50 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 2.5e-09 +skip_tests: prerequisites: ! | atom full pair lj/long/coul/long @@ -27,7 +28,7 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.373800441949 +init_vdwl: 749.3738004419491 init_coul: 0 init_stress: ! |2- 2.1794381361227847e+03 2.1989774840427094e+03 4.6654633746826312e+03 -7.5958387064933254e+02 2.4743497068166821e+01 6.6651487411200151e+02 @@ -61,7 +62,7 @@ init_forces: ! |2 27 5.1808319664002056e+01 -2.2705686796460878e+02 9.0850639433566855e+01 28 -1.8041324502064901e+02 7.7534032022981322e+01 -1.2206961052936214e+02 29 1.2861058916818402e+02 1.4952711846193802e+02 3.1216122432587827e+01 -run_vdwl: 719.579930262569 +run_vdwl: 719.5799302625688 run_coul: 0 run_stress: ! |2- 2.1330680690655749e+03 2.1548546310661609e+03 4.3977148876379333e+03 -7.3875161698392253e+02 4.1735811475391252e+01 6.2787463670975160e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_long_cut_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_long_cut_coul_long.yaml index ff512d3e09..089fdf7a3e 100644 --- a/unittest/force-styles/tests/mol-pair-lj_long_cut_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_long_cut_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:51 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:32 2022 epsilon: 2.5e-09 +skip_tests: prerequisites: ! | atom full pair lj/long/coul/long @@ -27,7 +28,7 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.23722617441 +init_vdwl: 749.2372261744105 init_coul: 225.821815126925 init_stress: ! |2- 2.1566096102905221e+03 2.1560522619501485e+03 4.6266534799074107e+03 -7.5506792664852833e+02 1.8227392498786724e+01 6.7620047095233224e+02 @@ -62,7 +63,7 @@ init_forces: ! |2 28 -1.7608383951257386e+02 7.3301743321101753e+01 -1.1852450102612138e+02 29 1.2668894747540404e+02 1.4371756954645076e+02 3.1331335682136437e+01 run_vdwl: 719.570991322032 -run_coul: 225.904237156271 +run_coul: 225.90423715627094 run_stress: ! |2- 2.1107014053468861e+03 2.1121563786867741e+03 4.3598688519011475e+03 -7.3407401306070096e+02 3.5367507798830019e+01 6.3752854031292134e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_long_cut_tip4p_long.yaml b/unittest/force-styles/tests/mol-pair-lj_long_cut_tip4p_long.yaml index 9227228855..ef1fb4f4cd 100644 --- a/unittest/force-styles/tests/mol-pair-lj_long_cut_tip4p_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_long_cut_tip4p_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:51 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 2.5e-09 +skip_tests: prerequisites: ! | atom full pair lj/long/tip4p/long @@ -33,8 +34,8 @@ extract: ! | typeA 0 typeB 0 natoms: 29 -init_vdwl: 584.670383161597 -init_coul: 220.904555359383 +init_vdwl: 584.6703831615966 +init_coul: 220.90455535938298 init_stress: ! |2- 1.4179908002675882e+03 1.6981521472771326e+03 3.8247898365498659e+03 -1.0685165973996448e+03 -2.2301723469314513e+02 7.0678972133134005e+02 init_forces: ! |2 @@ -67,8 +68,8 @@ init_forces: ! |2 27 -1.5292288824966405e+00 7.3670370809055621e+00 -2.7248017347638225e+00 28 6.4035032875423159e+00 -2.1779017025677483e+00 4.1727109672631357e+00 29 -4.5201953782892055e+00 -5.1735155675050022e+00 -1.4886429234413563e+00 -run_vdwl: 557.056030476991 -run_coul: 220.91388439321 +run_vdwl: 557.0560304769907 +run_coul: 220.91388439320994 run_stress: ! |2- 1.3775223750599198e+03 1.6566888200245044e+03 3.5747572154246241e+03 -1.0386782389667430e+03 -2.0694915325068990e+02 6.6732651501863495e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_long_tip4p_long.yaml b/unittest/force-styles/tests/mol-pair-lj_long_tip4p_long.yaml index 50a03799be..0a4639b1c9 100644 --- a/unittest/force-styles/tests/mol-pair-lj_long_tip4p_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_long_tip4p_long.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:08:51 2021 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 2.5e-09 +skip_tests: prerequisites: ! | atom full pair lj/long/tip4p/long @@ -37,8 +38,8 @@ extract: ! | typeA 0 typeB 0 natoms: 29 -init_vdwl: 584.670383161636 -init_coul: 220.904555359383 +init_vdwl: 584.6703831616355 +init_coul: 220.90455535938298 init_stress: ! |2- 1.4179908002675882e+03 1.6981521472771331e+03 3.8247898365498668e+03 -1.0685165973996445e+03 -2.2301723469314501e+02 7.0678972133134016e+02 init_forces: ! |2 @@ -71,8 +72,8 @@ init_forces: ! |2 27 -1.5292288824966420e+00 7.3670370809055621e+00 -2.7248017347638211e+00 28 6.4035032875423159e+00 -2.1779017025677483e+00 4.1727109672631357e+00 29 -4.5201953782892055e+00 -5.1735155675050022e+00 -1.4886429234413563e+00 -run_vdwl: 557.056030477029 -run_coul: 220.91388439321 +run_vdwl: 557.0560304770295 +run_coul: 220.91388439320994 run_stress: ! |2- 1.3775223750599193e+03 1.6566888200245039e+03 3.5747572154246241e+03 -1.0386782389667430e+03 -2.0694915325068987e+02 6.6732651501863484e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_mdf.yaml b/unittest/force-styles/tests/mol-pair-lj_mdf.yaml index 3dc4b08e81..31ff548db7 100644 --- a/unittest/force-styles/tests/mol-pair-lj_mdf.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_mdf.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:52 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/mdf @@ -21,7 +22,7 @@ extract: ! | epsilon 2 sigma 2 natoms: 29 -init_vdwl: 749.238128769917 +init_vdwl: 749.2381287699169 init_coul: 0 init_stress: ! |2- 2.1793844857971967e+03 2.1988910807167194e+03 4.6653956464347211e+03 -7.5956623392526990e+02 2.4752218664713212e+01 6.6652254832700567e+02 @@ -55,7 +56,7 @@ init_forces: ! |2 27 5.1810629413950949e+01 -2.2705426061698401e+02 9.0848881987846696e+01 28 -1.8041314536249783e+02 7.7534100857114439e+01 -1.2206963127965662e+02 29 1.2861063445049936e+02 1.4952718810862581e+02 3.1216037810340740e+01 -run_vdwl: 719.44436226705 +run_vdwl: 719.4443622670502 run_coul: 0 run_stress: ! |2- 2.1330145141050098e+03 2.1547683543089806e+03 4.3976473968701594e+03 -7.3873403814571213e+02 4.1744535857041868e+01 6.2788233468660019e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_sdk.yaml b/unittest/force-styles/tests/mol-pair-lj_sdk.yaml index 6a705107fe..74f8b1d80d 100644 --- a/unittest/force-styles/tests/mol-pair-lj_sdk.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_sdk.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:52 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/sdk @@ -37,7 +38,7 @@ extract: ! | rminsq 2 emin 2 natoms: 29 -init_vdwl: 96.7065789710194 +init_vdwl: 96.70657897101943 init_coul: 0 init_stress: ! |2- 2.3854236485731590e+02 2.4513069038883856e+02 4.7854108119193683e+02 -8.0187661332063271e+01 1.8589638688400608e+01 5.5399542784407586e+01 @@ -71,7 +72,7 @@ init_forces: ! |2 27 5.4452027737546072e+00 -2.3829292146895021e+01 9.5314145895722433e+00 28 -1.8937124096490784e+01 8.1392940248192893e+00 -1.2813499842672824e+01 29 1.3501717387036802e+01 1.5698317050429724e+01 3.2764339258442270e+00 -run_vdwl: 96.4078276545056 +run_vdwl: 96.40782765450555 run_coul: 0 run_stress: ! |2- 2.3882078825593069e+02 2.4514690319818953e+02 4.7570129095250257e+02 -7.9694877750512205e+01 1.8767838175742067e+01 5.5428941470529864e+01 diff --git a/unittest/force-styles/tests/mol-pair-lj_sdk_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_sdk_coul_long.yaml index 52871422b1..8decb35c5b 100644 --- a/unittest/force-styles/tests/mol-pair-lj_sdk_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_sdk_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:52 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/sdk/coul/long @@ -43,8 +44,8 @@ extract: ! | rminsq 2 emin 2 natoms: 29 -init_vdwl: 96.7065789710194 -init_coul: 225.821815126925 +init_vdwl: 96.70657897101943 +init_coul: 225.82181512692495 init_stress: ! |2- 2.1576625649751284e+02 2.0228718436192594e+02 4.3979508721311191e+02 -7.5690141753747611e+01 1.2065637647994825e+01 6.5079394998672981e+01 init_forces: ! |2 @@ -77,8 +78,8 @@ init_forces: ! |2 27 3.4241479416704426e+00 -1.3796209110902463e+01 5.8526837131859448e+00 28 -1.4607808276558991e+01 3.9069582630427737e+00 -9.2683763466292834e+00 29 1.1580032348283542e+01 9.8887041359319383e+00 3.3917294969037011e+00 -run_vdwl: 96.4212032046822 -run_coul: 225.785423219965 +run_vdwl: 96.42120320468219 +run_coul: 225.7854232199648 run_stress: ! |2- 2.1600118274105742e+02 2.0230919666468455e+02 4.3707688756974488e+02 -7.5214751729052296e+01 1.2184165306644045e+01 6.5043382029051401e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_sdk_coul_msm.yaml b/unittest/force-styles/tests/mol-pair-lj_sdk_coul_msm.yaml index 0a5043adca..e0e0629d10 100644 --- a/unittest/force-styles/tests/mol-pair-lj_sdk_coul_msm.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_sdk_coul_msm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:52 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/sdk/coul/long @@ -45,7 +46,7 @@ extract: ! | emin 2 natoms: 29 init_vdwl: 96.7010777193035 -init_coul: 114.131380823567 +init_coul: 114.13138082356693 init_stress: ! |2- 2.1426829376142507e+02 1.9935970870819688e+02 4.3556532899783042e+02 -7.4617041112731243e+01 1.2498072317675112e+01 6.6416969390148168e+01 init_forces: ! |2 @@ -78,8 +79,8 @@ init_forces: ! |2 27 2.9037104384113634e+00 -1.2180625028459321e+01 5.0275817117954995e+00 28 -1.4250304655397576e+01 3.0300324399816163e+00 -8.8153806706582216e+00 29 1.1836082667745567e+01 9.0621100202489338e+00 3.7896043026981410e+00 -run_vdwl: 96.417135798345 -run_coul: 114.088538843245 +run_vdwl: 96.41713579834504 +run_coul: 114.08853884324489 run_stress: ! |2- 2.1450745266430917e+02 1.9939196325836133e+02 4.3286812098542731e+02 -7.4141060775112749e+01 1.2618785660759315e+01 6.6376039818113469e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_sdk_coul_msm_table.yaml b/unittest/force-styles/tests/mol-pair-lj_sdk_coul_msm_table.yaml index eff2216f29..035838fc1d 100644 --- a/unittest/force-styles/tests/mol-pair-lj_sdk_coul_msm_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_sdk_coul_msm_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:52 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 5e-14 skip_tests: gpu prerequisites: ! | @@ -46,7 +46,7 @@ extract: ! | emin 2 natoms: 29 init_vdwl: 96.7010777193035 -init_coul: 114.131383580102 +init_coul: 114.13138358010185 init_stress: ! |2- 2.1426829544057128e+02 1.9935971136506137e+02 4.3556533091279061e+02 -7.4617042670646882e+01 1.2498073409815488e+01 6.6416969682910434e+01 init_forces: ! |2 @@ -79,8 +79,8 @@ init_forces: ! |2 27 2.9037102814588285e+00 -1.2180624835780948e+01 5.0275816273007337e+00 28 -1.4250304832815443e+01 3.0300321386140592e+00 -8.8153806609288345e+00 29 1.1836083036624068e+01 9.0621100518602020e+00 3.7896044412902152e+00 -run_vdwl: 96.41713579845 -run_coul: 114.088541875396 +run_vdwl: 96.41713579844998 +run_coul: 114.08854187539558 run_stress: ! |2- 2.1450745398007408e+02 1.9939196542234055e+02 4.3286812623303888e+02 -7.4141058257828249e+01 1.2618786425639284e+01 6.6376041002915073e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_sdk_coul_table.yaml b/unittest/force-styles/tests/mol-pair-lj_sdk_coul_table.yaml index 09bb65a0cf..108460d616 100644 --- a/unittest/force-styles/tests/mol-pair-lj_sdk_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_sdk_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:52 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 5e-14 skip_tests: gpu prerequisites: ! | @@ -44,8 +44,8 @@ extract: ! | rminsq 2 emin 2 natoms: 29 -init_vdwl: 96.7065789710194 -init_coul: 225.821851347828 +init_vdwl: 96.70657897101943 +init_coul: 225.8218513478281 init_stress: ! |2- 2.1576627676023486e+02 2.0228719011799453e+02 4.3979510063773620e+02 -7.5690138459154355e+01 1.2065647143142451e+01 6.5079399089331773e+01 init_forces: ! |2 @@ -78,8 +78,8 @@ init_forces: ! |2 27 3.4241478263070952e+00 -1.3796208945185219e+01 5.8526835192637785e+00 28 -1.4607810988101456e+01 3.9069573281401428e+00 -9.2683775626899187e+00 29 1.1580034971657559e+01 9.8887046452005567e+00 3.3917310027287062e+00 -run_vdwl: 96.4212032011243 -run_coul: 225.785462165742 +run_vdwl: 96.42120320112426 +run_coul: 225.7854621657423 run_stress: ! |2- 2.1600120582585106e+02 2.0230920430734940e+02 4.3707690506386808e+02 -7.5214748198931886e+01 1.2184171804318320e+01 6.5043388456772135e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_smooth.yaml b/unittest/force-styles/tests/mol-pair-lj_smooth.yaml index ea17c7d5b0..6548b75245 100644 --- a/unittest/force-styles/tests/mol-pair-lj_smooth.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_smooth.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:52 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:33 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/smooth @@ -19,7 +20,7 @@ pair_coeff: ! | 5 5 0.015 3.1 extract: ! "" natoms: 29 -init_vdwl: 749.235620806206 +init_vdwl: 749.2356208062062 init_coul: 0 init_stress: ! |2- 2.1793844379835768e+03 2.1988922741449392e+03 4.6653980846747309e+03 -7.5956502661369655e+02 2.4751855764033625e+01 6.6652015106265185e+02 @@ -53,7 +54,7 @@ init_forces: ! |2 27 5.1810556888375629e+01 -2.2705478382763954e+02 9.0849114461863849e+01 28 -1.8041315308300508e+02 7.7534078237359694e+01 -1.2206962621857849e+02 29 1.2861063646262821e+02 1.4952717884185427e+02 3.1216037219026877e+01 -run_vdwl: 719.441849866247 +run_vdwl: 719.4418498662474 run_coul: 0 run_stress: ! |2- 2.1330144733952702e+03 2.1547695598297596e+03 4.3976498516149932e+03 -7.3873283558449202e+02 4.1744169147817587e+01 6.2787994171090793e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_smooth_linear.yaml b/unittest/force-styles/tests/mol-pair-lj_smooth_linear.yaml index 1726804d29..89bc17051c 100644 --- a/unittest/force-styles/tests/mol-pair-lj_smooth_linear.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_smooth_linear.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:34 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair lj/smooth/linear @@ -19,7 +20,7 @@ pair_coeff: ! | 5 5 0.015 3.1 extract: ! "" natoms: 29 -init_vdwl: 7466.11454271316 +init_vdwl: 7466.114542713155 init_coul: 0 init_stress: ! |2- 2.1793943517585126e+03 2.1989124976263984e+03 4.6654116437861576e+03 -7.5956709427920396e+02 2.4748878452852320e+01 6.6651954873500767e+02 @@ -53,7 +54,7 @@ init_forces: ! |2 27 5.1809791369511800e+01 -2.2705548670842322e+02 9.0849693244516942e+01 28 -1.8041317714556408e+02 7.7534055022302738e+01 -1.2206961203464421e+02 29 1.2861061471308315e+02 1.4952715208640333e+02 3.1216058453122045e+01 -run_vdwl: 7168.74470801024 +run_vdwl: 7168.744708010245 run_coul: 0 run_stress: ! |2- 2.1330243778591253e+03 2.1547897736668579e+03 4.3976633892748978e+03 -7.3873489722118427e+02 4.1741192200028131e+01 6.2787933430487840e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_switch3_coulgauss_long.yaml b/unittest/force-styles/tests/mol-pair-lj_switch3_coulgauss_long.yaml index e14044f9a0..134c243b58 100644 --- a/unittest/force-styles/tests/mol-pair-lj_switch3_coulgauss_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_switch3_coulgauss_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Thu Apr 1 12:05:31 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:34 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair lj/switch3/coulgauss/long @@ -28,8 +29,8 @@ extract: ! | gamma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.239201392283 -init_coul: 262.63137433058 +init_vdwl: 749.2392013922833 +init_coul: 262.63137433057983 init_stress: ! |2- 2.1905445805730942e+03 2.1830788072793757e+03 4.6581902800701146e+03 -7.4288115309776367e+02 2.6990012828168151e+01 6.7591505796334252e+02 init_forces: ! |2 @@ -62,8 +63,8 @@ init_forces: ! |2 27 5.1263700969024825e+01 -2.2708329767472884e+02 9.0733209359745530e+01 28 -1.8280634435959598e+02 7.6676771027308675e+01 -1.2320543486529729e+02 29 1.3193901693998819e+02 1.5040612832512986e+02 3.2448964935598738e+01 -run_vdwl: 719.395943067584 -run_coul: 262.577357625246 +run_vdwl: 719.3959430675837 +run_coul: 262.57735762524624 run_stress: ! |2- 2.1439469903049130e+03 2.1388099416476502e+03 4.3901771762143671e+03 -7.2215136136852652e+02 4.3981220891989977e+01 6.3726346095247902e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_switch3_coulgauss_table.yaml b/unittest/force-styles/tests/mol-pair-lj_switch3_coulgauss_table.yaml index 973ed7051e..aa379ade27 100644 --- a/unittest/force-styles/tests/mol-pair-lj_switch3_coulgauss_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_switch3_coulgauss_table.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Thu Apr 1 12:05:32 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:34 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair lj/switch3/coulgauss/long @@ -28,8 +29,8 @@ extract: ! | gamma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.239201392283 -init_coul: 262.631410551483 +init_vdwl: 749.2392013922833 +init_coul: 262.6314105514831 init_stress: ! |2- 2.1905446008358158e+03 2.1830788130354440e+03 4.6581902934947393e+03 -7.4288114980317005e+02 2.6990022323315568e+01 6.7591506205400140e+02 init_forces: ! |2 @@ -62,8 +63,8 @@ init_forces: ! |2 27 5.1263700853661504e+01 -2.2708329750901160e+02 9.0733209165823396e+01 28 -1.8280634707113845e+02 7.6676770092406045e+01 -1.2320543608135794e+02 29 1.3193901956336219e+02 1.5040612883439849e+02 3.2448966441423750e+01 -run_vdwl: 719.3959430344 -run_coul: 262.577390407319 +run_vdwl: 719.3959430344001 +run_coul: 262.5773904073192 run_stress: ! |2- 2.1439470065972137e+03 2.1388099427650550e+03 4.3901771876285757e+03 -7.2215135528838152e+02 4.3981227731157169e+01 6.3726346514781233e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_table_coul_long.yaml b/unittest/force-styles/tests/mol-pair-lj_table_coul_long.yaml index 9b2e520fb5..cd55db249f 100644 --- a/unittest/force-styles/tests/mol-pair-lj_table_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_table_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:34 2022 epsilon: 2.5e-09 +skip_tests: prerequisites: ! | atom full pair lj/long/coul/long @@ -28,7 +29,7 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.373800357348 +init_vdwl: 749.3738003573477 init_coul: 225.821815126925 init_stress: ! |2- 2.1566620275856822e+03 2.1561339778667862e+03 4.6267173805218372e+03 -7.5508635107482382e+02 1.8219496068776014e+01 6.7619472637775823e+02 @@ -62,8 +63,8 @@ init_forces: ! |2 27 4.9787264831993880e+01 -2.1702378492854734e+02 8.7171908557137229e+01 28 -1.7608392920068218e+02 7.3301696261216364e+01 -1.1852448703330357e+02 29 1.2668890412939926e+02 1.4371750554743343e+02 3.1331418003628617e+01 -run_vdwl: 719.7074660584 -run_coul: 225.904237287567 +run_vdwl: 719.7074660584003 +run_coul: 225.90423728756718 run_stress: ! |2- 2.1107537186691984e+03 2.1122379540627758e+03 4.3599324980929077e+03 -7.3409237544465191e+02 3.5359612060552294e+01 6.3752276735532018e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_table_coul_off.yaml b/unittest/force-styles/tests/mol-pair-lj_table_coul_off.yaml index 2d6626922f..76fad79de2 100644 --- a/unittest/force-styles/tests/mol-pair-lj_table_coul_off.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_table_coul_off.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:53 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:34 2022 epsilon: 5e-08 +skip_tests: prerequisites: ! | atom full pair lj/long/coul/long @@ -27,7 +28,7 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.373800357348 +init_vdwl: 749.3738003573477 init_coul: 0 init_stress: ! |2- 2.1794381359454856e+03 2.1989774838936992e+03 4.6654633745006640e+03 -7.5958387065313900e+02 2.4743497109181568e+01 6.6651487416349380e+02 @@ -61,7 +62,7 @@ init_forces: ! |2 27 5.1808319664078056e+01 -2.2705686796453989e+02 9.0850639433523526e+01 28 -1.8041324502061397e+02 7.7534032022992875e+01 -1.2206961052934710e+02 29 1.2861058916815250e+02 1.4952711846193120e+02 3.1216122432569136e+01 -run_vdwl: 719.579930165123 +run_vdwl: 719.5799301651231 run_coul: 0 run_stress: ! |2- 2.1330680688707021e+03 2.1548546308869545e+03 4.3977148874255754e+03 -7.3875161697424380e+02 4.1735811498020226e+01 6.2787463680556255e+02 diff --git a/unittest/force-styles/tests/mol-pair-lj_table_coul_table.yaml b/unittest/force-styles/tests/mol-pair-lj_table_coul_table.yaml index 5d919a85e4..c0f4e081a9 100644 --- a/unittest/force-styles/tests/mol-pair-lj_table_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_table_coul_table.yaml @@ -1,7 +1,7 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:08:53 2021 +date_generated: Fri Mar 18 22:17:34 2022 epsilon: 2.5e-09 skip_tests: gpu prerequisites: ! | @@ -30,8 +30,8 @@ extract: ! | sigma 2 cut_coul 0 natoms: 29 -init_vdwl: 749.373800357348 -init_coul: 225.821848735651 +init_vdwl: 749.3738003573477 +init_coul: 225.82184873565126 init_stress: ! |2- 2.1566620469893351e+03 2.1561339813185318e+03 4.6267173923329747e+03 -7.5508634691578300e+02 1.8219503726437118e+01 6.7619473035693068e+02 init_forces: ! |2 @@ -65,7 +65,7 @@ init_forces: ! |2 28 -1.7608393218830406e+02 7.3301695273279591e+01 -1.1852448845096609e+02 29 1.2668890703792840e+02 1.4371750615273265e+02 3.1331419700612329e+01 run_vdwl: 719.707466025823 -run_coul: 225.904271605306 +run_coul: 225.90427160530612 run_stress: ! |2- 2.1107537361360182e+03 2.1122379552504867e+03 4.3599325102107177e+03 -7.3409236921986474e+02 3.5359618646489480e+01 6.3752277106167185e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_table_tip4p_long.yaml b/unittest/force-styles/tests/mol-pair-lj_table_tip4p_long.yaml index a1bd0e412b..817a1fcae8 100644 --- a/unittest/force-styles/tests/mol-pair-lj_table_tip4p_long.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_table_tip4p_long.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:08:54 2021 +date_generated: Fri Mar 18 22:17:34 2022 epsilon: 2.5e-09 +skip_tests: prerequisites: ! | atom full pair lj/long/tip4p/long @@ -37,8 +38,8 @@ extract: ! | typeA 0 typeB 0 natoms: 29 -init_vdwl: 584.670383080969 -init_coul: 220.904555359383 +init_vdwl: 584.6703830809686 +init_coul: 220.90455535938298 init_stress: ! |2- 1.4179908000957589e+03 1.6981521471393723e+03 3.8247898363754530e+03 -1.0685165974021609e+03 -2.2301723465511702e+02 7.0678972138306494e+02 init_forces: ! |2 @@ -71,8 +72,8 @@ init_forces: ! |2 27 -1.5292288824197682e+00 7.3670370809736765e+00 -2.7248017348072757e+00 28 6.4035032875423159e+00 -2.1779017025677483e+00 4.1727109672631357e+00 29 -4.5201953782892055e+00 -5.1735155675050022e+00 -1.4886429234413563e+00 -run_vdwl: 557.056030414379 -run_coul: 220.913884393211 +run_vdwl: 557.0560304143789 +run_coul: 220.91388439321088 run_stress: ! |2- 1.3775223749165898e+03 1.6566888199057378e+03 3.5747572153094793e+03 -1.0386782389365808e+03 -2.0694915319826390e+02 6.6732651503606473e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-lj_table_tip4p_table.yaml b/unittest/force-styles/tests/mol-pair-lj_table_tip4p_table.yaml index 1630d752df..c64b01d34a 100644 --- a/unittest/force-styles/tests/mol-pair-lj_table_tip4p_table.yaml +++ b/unittest/force-styles/tests/mol-pair-lj_table_tip4p_table.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:08:54 2021 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 2.5e-09 +skip_tests: prerequisites: ! | atom full pair lj/long/tip4p/long @@ -37,8 +38,8 @@ extract: ! | typeA 0 typeB 0 natoms: 29 -init_vdwl: 584.670383080969 -init_coul: 220.904588455609 +init_vdwl: 584.6703830809686 +init_coul: 220.90458845560877 init_stress: ! |2- 1.4179908193076576e+03 1.6981521515722404e+03 3.8247898488640121e+03 -1.0685165954330873e+03 -2.2301722605901131e+02 7.0678972497923144e+02 init_forces: ! |2 @@ -71,8 +72,8 @@ init_forces: ! |2 27 -1.5292288656803577e+00 7.3670372934081341e+00 -2.7248019284801495e+00 28 6.4035005649493479e+00 -2.1779026033513014e+00 4.1727097093108574e+00 29 -4.5201927345996555e+00 -5.1735150000565087e+00 -1.4886414114327997e+00 -run_vdwl: 557.056030407218 -run_coul: 220.913919083367 +run_vdwl: 557.0560304072184 +run_coul: 220.91391908336655 run_stress: ! |2- 1.3775223933013649e+03 1.6566888250620884e+03 3.5747572316072610e+03 -1.0386782354170655e+03 -2.0694914632954348e+02 6.6732651945202394e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-mie_cut.yaml b/unittest/force-styles/tests/mol-pair-mie_cut.yaml index ec36aa2349..00f539670e 100644 --- a/unittest/force-styles/tests/mol-pair-mie_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-mie_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair mie/cut @@ -23,7 +24,7 @@ extract: ! | gamR 2 gamA 2 natoms: 29 -init_vdwl: 572.65241169595 +init_vdwl: 572.6524116959499 init_coul: 0 init_stress: ! |2- 1.5112451012221711e+03 1.6108090633309916e+03 3.6313538023188962e+03 -6.4519502381294672e+02 -7.6958115438443343e+01 5.2466156989449894e+02 @@ -57,7 +58,7 @@ init_forces: ! |2 27 2.0888442237096100e+01 -9.4688431023944986e+01 3.7478527939720465e+01 28 -7.4711699859811475e+01 3.2108421478054176e+01 -5.0551006653560087e+01 29 5.3833799408056237e+01 6.2589370938775232e+01 1.3066022522941514e+01 -run_vdwl: 554.397373452421 +run_vdwl: 554.3973734524214 run_coul: 0 run_stress: ! |2- 1.4870680633544989e+03 1.5866563229080662e+03 3.4640437814661673e+03 -6.3299620387308835e+02 -6.5104809831557432e+01 5.0161494781835211e+02 diff --git a/unittest/force-styles/tests/mol-pair-mm3_switch3_coulgauss_long.yaml b/unittest/force-styles/tests/mol-pair-mm3_switch3_coulgauss_long.yaml index d74aba7143..215682c551 100644 --- a/unittest/force-styles/tests/mol-pair-mm3_switch3_coulgauss_long.yaml +++ b/unittest/force-styles/tests/mol-pair-mm3_switch3_coulgauss_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Thu Apr 1 12:40:49 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 7.5e-14 +skip_tests: prerequisites: ! | atom full pair mm3/switch3/coulgauss/long @@ -28,8 +29,8 @@ extract: ! | gamma 2 cut_coul 0 natoms: 29 -init_vdwl: 38.1287498820824 -init_coul: 262.63137433058 +init_vdwl: 38.12874988208239 +init_coul: 262.63137433057983 init_stress: ! |- -9.1891442318066098e+01 -1.3287972066289731e+02 -3.2601698046780012e+02 3.0074181349476991e+01 -4.6650805915669622e+00 -8.2199038214680613e+01 init_forces: ! |2 @@ -62,8 +63,8 @@ init_forces: ! |2 27 -7.1989693245110757e+00 3.0862600015720503e+01 -1.2113492397573609e+01 28 2.1728885747832702e+01 -1.1241487657358419e+01 1.5185683466068600e+01 29 -1.4356735366664552e+01 -1.9712882789785066e+01 -3.0642394558798047e+00 -run_vdwl: 37.7351028273436 -run_coul: 262.634961661768 +run_vdwl: 37.73510282734356 +run_coul: 262.6349616617681 run_stress: ! |- -9.3272108018189712e+01 -1.3382217126586661e+02 -3.2672293936615591e+02 2.9759545957029179e+01 -4.9209094100413031e+00 -8.2642487904188499e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-mm3_switch3_coulgauss_table.yaml b/unittest/force-styles/tests/mol-pair-mm3_switch3_coulgauss_table.yaml index e1b11baa5d..05113a7c79 100644 --- a/unittest/force-styles/tests/mol-pair-mm3_switch3_coulgauss_table.yaml +++ b/unittest/force-styles/tests/mol-pair-mm3_switch3_coulgauss_table.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Mar 2021 -date_generated: Thu Apr 1 12:40:49 202 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair mm3/switch3/coulgauss/long @@ -28,8 +29,8 @@ extract: ! | gamma 2 cut_coul 0 natoms: 29 -init_vdwl: 38.1287498820824 -init_coul: 262.631410551483 +init_vdwl: 38.12874988208239 +init_coul: 262.6314105514831 init_stress: ! |- -9.1891422055344222e+01 -1.3287971490682878e+02 -3.2601696704317601e+02 3.0074184644070325e+01 -4.6650710964193243e+00 -8.2199034124021594e+01 init_forces: ! |2 @@ -62,8 +63,8 @@ init_forces: ! |2 27 -7.1989694398744213e+00 3.0862600181437756e+01 -1.2113492591495778e+01 28 2.1728883036290242e+01 -1.1241488592261051e+01 1.5185682250007966e+01 29 -1.4356732743290538e+01 -1.9712882280516450e+01 -3.0642379500547996e+00 -run_vdwl: 37.735102831577 -run_coul: 262.634996567417 +run_vdwl: 37.73510283157698 +run_coul: 262.6349965674175 run_stress: ! |- -9.3272087816450096e+01 -1.3382216892660497e+02 -3.2672292496064199e+02 2.9759550012391575e+01 -4.9209020012813669e+00 -8.2642482482441096e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-morse.yaml b/unittest/force-styles/tests/mol-pair-morse.yaml index 12a2ab2132..cf39897460 100644 --- a/unittest/force-styles/tests/mol-pair-morse.yaml +++ b/unittest/force-styles/tests/mol-pair-morse.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair morse @@ -30,7 +31,7 @@ extract: ! | r0 2 alpha 2 natoms: 29 -init_vdwl: 110.576232937435 +init_vdwl: 110.57623293743501 init_coul: 0 init_stress: ! |2- 2.0965665191613445e+02 2.1015016148935857e+02 3.3202348338929278e+02 -3.7942645585905737e+01 2.3588839570240719e+01 3.0835781103486081e+01 @@ -64,7 +65,7 @@ init_forces: ! |2 27 4.7651790357913413e+00 -2.6604506061914726e+01 9.9133183430581937e+00 28 -2.0185283324331216e+01 8.6749457172768381e+00 -1.3657622292205492e+01 29 1.5422773526309053e+01 1.7931256324764902e+01 3.7433644842857023e+00 -run_vdwl: 110.4949161861 +run_vdwl: 110.49491618609969 run_coul: 0 run_stress: ! |2- 2.0994784428585552e+02 2.1021437576600792e+02 3.3123757135001267e+02 -3.7734658940331229e+01 2.3722482472838379e+01 3.1022635675675680e+01 diff --git a/unittest/force-styles/tests/mol-pair-morse_smooth_linear.yaml b/unittest/force-styles/tests/mol-pair-morse_smooth_linear.yaml index a4264cef44..1267f686d7 100644 --- a/unittest/force-styles/tests/mol-pair-morse_smooth_linear.yaml +++ b/unittest/force-styles/tests/mol-pair-morse_smooth_linear.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair morse/smooth/linear @@ -25,7 +26,7 @@ extract: ! | r0 2 alpha 2 natoms: 29 -init_vdwl: 110.576455574558 +init_vdwl: 110.5764555745584 init_coul: 0 init_stress: ! |2- 2.0965672593667708e+02 2.1015032692452459e+02 3.3202360755330801e+02 -3.7942655658588343e+01 2.3588817932865467e+01 3.0835767484464419e+01 @@ -59,7 +60,7 @@ init_forces: ! |2 27 4.7651727706625060e+00 -2.6604514922840195e+01 9.9133238206128400e+00 28 -2.0185283324769507e+01 8.6749457166585184e+00 -1.3657622291951469e+01 29 1.5422773525965512e+01 1.7931256323978314e+01 3.7433644846642018e+00 -run_vdwl: 110.495138818121 +run_vdwl: 110.4951388181207 run_coul: 0 run_stress: ! |2- 2.0994791829876567e+02 2.1021454119496974e+02 3.3123769551317008e+02 -3.7734669012057381e+01 2.3722460842313350e+01 3.1022622056857038e+01 diff --git a/unittest/force-styles/tests/mol-pair-morse_soft.yaml b/unittest/force-styles/tests/mol-pair-morse_soft.yaml index 2c385f7a80..ef3eda82d7 100644 --- a/unittest/force-styles/tests/mol-pair-morse_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-morse_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair morse/soft @@ -31,7 +32,7 @@ extract: ! | alpha 2 lambda 2 natoms: 29 -init_vdwl: 108.878402738492 +init_vdwl: 108.87840273849206 init_coul: 0 init_stress: ! |2- 2.0616314640468093e+02 2.0694552515100577e+02 3.2253755241146825e+02 -3.7303720548619488e+01 2.3916353883528416e+01 2.9242881772029893e+01 @@ -65,7 +66,7 @@ init_forces: ! |2 27 4.6456501792718932e+00 -2.6023140263358044e+01 9.6880319377243431e+00 28 -1.9732921668033161e+01 8.4805413222287829e+00 -1.3351550006152580e+01 29 1.5089940726667313e+01 1.7544294921333940e+01 3.6625786035313128e+00 -run_vdwl: 108.803617927324 +run_vdwl: 108.80361792732417 run_coul: 0 run_stress: ! |2- 2.0644682696505629e+02 2.0700759596517148e+02 3.2180109348277563e+02 -3.7100564027840441e+01 2.4043065132969296e+01 2.9430825945498110e+01 diff --git a/unittest/force-styles/tests/mol-pair-nm_cut.yaml b/unittest/force-styles/tests/mol-pair-nm_cut.yaml index 861a92dbdd..324d71b829 100644 --- a/unittest/force-styles/tests/mol-pair-nm_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-nm_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair nm/cut @@ -66,7 +67,7 @@ init_forces: ! |2 27 1.2882964877239125e+01 -5.6361972106685570e+01 2.2561805670401998e+01 28 -4.4799490702516259e+01 1.9253130813645878e+01 -3.0311947397740930e+01 29 3.1921004443145875e+01 3.7112558101945595e+01 7.7475966898074331e+00 -run_vdwl: 182.369864828409 +run_vdwl: 182.3698648284094 run_coul: 0 run_stress: ! |2- 5.3658199964385449e+02 5.4150593348929669e+02 1.1351000214934920e+03 -1.8648219712419237e+02 5.7793252452314690e+00 1.6371501081324359e+02 diff --git a/unittest/force-styles/tests/mol-pair-nm_cut_coul_cut.yaml b/unittest/force-styles/tests/mol-pair-nm_cut_coul_cut.yaml index 1e8330ec06..e10d630408 100644 --- a/unittest/force-styles/tests/mol-pair-nm_cut_coul_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-nm_cut_coul_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair nm/cut/coul/cut @@ -32,8 +33,8 @@ extract: ! | nn 2 mm 2 natoms: 29 -init_vdwl: 184.286785891603 -init_coul: -135.322201772298 +init_vdwl: 184.28678589160327 +init_coul: -135.3222017722983 init_stress: ! |2- 5.1099535412443879e+02 4.9267015856417487e+02 1.0972826650625757e+03 -1.9179119371088936e+02 -3.5985836516943652e+00 1.6890666491875683e+02 init_forces: ! |2 @@ -66,8 +67,8 @@ init_forces: ! |2 27 1.0035511306793698e+01 -4.5249946085110551e+01 1.8136503701331897e+01 28 -3.9953070294941519e+01 1.3962092508592026e+01 -2.6231057257176037e+01 29 3.0657392434855581e+01 3.0940622604427993e+01 8.6697893689665211e+00 -run_vdwl: 182.405654760453 -run_coul: -135.342822931701 +run_vdwl: 182.40565476045293 +run_coul: -135.3428229317011 run_stress: ! |2- 5.0949331883645084e+02 4.9079274612266465e+02 1.0779924919705209e+03 -1.8978874005409725e+02 -2.3414288930535676e+00 1.6680086396779814e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-nm_cut_coul_long.yaml b/unittest/force-styles/tests/mol-pair-nm_cut_coul_long.yaml index fc190d1aea..b3c77b862c 100644 --- a/unittest/force-styles/tests/mol-pair-nm_cut_coul_long.yaml +++ b/unittest/force-styles/tests/mol-pair-nm_cut_coul_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:55 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 7.5e-13 +skip_tests: prerequisites: ! | atom full pair nm/cut/coul/long @@ -38,8 +39,8 @@ extract: ! | mm 2 cut_coul 0 natoms: 29 -init_vdwl: 184.286785891603 -init_coul: 225.821815126925 +init_vdwl: 184.28678589160327 +init_coul: 225.82181512692495 init_stress: ! |2- 5.1535561642229106e+02 5.0058662653359033e+02 1.1159625282020661e+03 -1.8397466102442883e+02 -2.0220636765660638e+00 1.7544854550792292e+02 init_forces: ! |2 @@ -72,8 +73,8 @@ init_forces: ! |2 27 1.0861995979992932e+01 -4.6328822142297405e+01 1.8883010243779164e+01 28 -4.0470174882584459e+01 1.5020795051869365e+01 -2.6766823901697389e+01 29 2.9999319404392626e+01 3.1302945187447804e+01 7.8628922608669090e+00 -run_vdwl: 182.402559295073 -run_coul: 225.805231222371 +run_vdwl: 182.40255929507265 +run_coul: 225.80523122237145 run_stress: ! |2- 5.1384631551491782e+02 4.9870417055031982e+02 1.0966342093912015e+03 -1.8197324336578851e+02 -7.7105078556388151e-01 1.7333789878387816e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-nm_cut_coul_table.yaml b/unittest/force-styles/tests/mol-pair-nm_cut_coul_table.yaml index 1c796c067a..f53a664d2a 100644 --- a/unittest/force-styles/tests/mol-pair-nm_cut_coul_table.yaml +++ b/unittest/force-styles/tests/mol-pair-nm_cut_coul_table.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-12 skip_tests: gpu prerequisites: ! | @@ -39,8 +39,8 @@ extract: ! | mm 2 cut_coul 0 natoms: 29 -init_vdwl: 184.286785891603 -init_coul: 225.821851347828 +init_vdwl: 184.28678589160327 +init_coul: 225.82185134782813 init_stress: ! |2- 5.1535563668501300e+02 5.0058663228965906e+02 1.1159625416266908e+03 -1.8397465772983549e+02 -2.0220541814186075e+00 1.7544854959858193e+02 init_forces: ! |2 @@ -73,8 +73,8 @@ init_forces: ! |2 27 1.0861995864629581e+01 -4.6328821976580151e+01 1.8883010049856995e+01 28 -4.0470177594126923e+01 1.5020794116966732e+01 -2.6766825117758021e+01 29 2.9999322027766638e+01 3.1302945696716428e+01 7.8628937666919105e+00 -run_vdwl: 182.402559286578 -run_coul: 225.805266218016 +run_vdwl: 182.40255928657774 +run_coul: 225.80526621801556 run_stress: ! |2- 5.1384633450263470e+02 4.9870417152157029e+02 1.0966342229480442e+03 -1.8197323856665997e+02 -7.7104387031605370e-01 1.7333790492919763e+02 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-nm_cut_split.yaml b/unittest/force-styles/tests/mol-pair-nm_cut_split.yaml index 26fab2b1da..d71db2433c 100644 --- a/unittest/force-styles/tests/mol-pair-nm_cut_split.yaml +++ b/unittest/force-styles/tests/mol-pair-nm_cut_split.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 27 Oct 2021 -date_generated: Fri Dec 3 14:19:54 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-13 skip_tests: prerequisites: ! | @@ -36,69 +36,69 @@ natoms: 29 init_vdwl: 184.46055463786212 init_coul: 0 init_stress: ! |2- - 5.3838190519561294e+02 5.4370888866042401e+02 1.1549423729943153e+03 -1.8851357922205918e+02 4.4535538593228559e+00 1.6572955388078447e+02 + 5.3838190519561249e+02 5.4370888866042390e+02 1.1549423729943146e+03 -1.8851357922205921e+02 4.4535538593228843e+00 1.6572955388078441e+02 init_forces: ! |2 - 1 -5.8010753095576453e+00 6.7019475304167301e+01 8.2636805547527302e+01 - 2 3.9312055883575447e+01 3.2350311908851069e+01 -4.6269491919818336e+01 - 3 -3.5305111899706318e+01 -9.6504324302794672e+01 -3.5088931543566190e+01 - 4 -5.8409040695096015e-01 1.5448113553260867e-01 -4.1551985279380638e-01 - 5 -2.0046651942407759e-01 -3.4223055809276309e-01 8.7871234802730946e-01 - 6 -2.0721364706498824e+02 2.4016237943042879e+02 2.8700056551899644e+02 - 7 1.4604553825101560e+01 -8.3802360854506233e+01 -4.2794566606285696e+02 - 8 3.6138770853796672e+01 -2.7258004708576987e+01 9.9538777711653978e+01 + 1 -5.8010753095577092e+00 6.7019475304167202e+01 8.2636805547527331e+01 + 2 3.9312055883575489e+01 3.2350311908851104e+01 -4.6269491919818385e+01 + 3 -3.5305111899706297e+01 -9.6504324302794615e+01 -3.5088931543566169e+01 + 4 -5.8409040695095993e-01 1.5448113553260862e-01 -4.1551985279380615e-01 + 5 -2.0046651942407748e-01 -3.4223055809276293e-01 8.7871234802730913e-01 + 6 -2.0721364706498809e+02 2.4016237943042862e+02 2.8700056551899610e+02 + 7 1.4604553825101545e+01 -8.3802360854506134e+01 -4.2794566606285650e+02 + 8 3.6138770853796494e+01 -2.7258004708576873e+01 9.9538777711653864e+01 9 1.9677324629694770e+01 2.1192619795334007e+01 8.7076054788266745e+01 - 10 1.3187239009715952e+02 -1.5291386183130950e+02 -4.7328679849884615e+01 - 11 -1.6817605988576226e-01 -4.2337076133540452e-01 -6.9379475746613284e-01 - 12 4.9439004425924278e+00 3.5972141803133999e+00 -2.9063624045380081e+00 - 13 6.0847461884614340e-01 -2.4087582512536920e-01 -1.1429443490171888e-02 - 14 -2.5135966919090386e-01 5.0693343437559095e-02 -6.4882033213846146e-01 - 15 -1.7492135130621179e-02 6.3261129633870505e-01 2.2568696677395533e-01 - 16 1.1533643706799870e+02 -8.2319682718269064e+01 -2.9635546568323309e+02 - 17 -1.1295230473793292e+02 7.8645099709581359e+01 3.0030745767603463e+02 - 18 -2.2515034468785730e-03 -4.3333792383380811e-03 9.9435889422212678e-03 - 19 -3.8285183184657459e-03 -2.3670865665501185e-03 -5.1320932088365729e-03 - 20 5.9936054839043167e-03 6.4927254507248788e-03 -4.5957636846263574e-03 - 21 -1.7771101916350986e+01 -2.0266633257241402e+01 5.6070531525240284e+01 - 22 -2.6828196427086496e+01 -6.5013719610173153e+00 -4.2091321161763851e+01 - 23 4.4599242317851683e+01 2.6768079222089987e+01 -1.3979148411868403e+01 - 24 9.0731337276239099e+00 -5.2584048025594143e+01 2.7844998894928324e+01 - 25 -3.6857511179337180e+01 5.9339663466847563e+00 -3.0985670760400872e+01 - 26 2.7784301129627654e+01 4.6650009976909971e+01 3.1405189423721294e+00 - 27 1.2878799997680169e+01 -5.6365384292184224e+01 2.2564079535768347e+01 - 28 -4.4799160574539883e+01 1.9253173801592030e+01 -3.0311698334899067e+01 + 10 1.3187239009715952e+02 -1.5291386183130953e+02 -4.7328679849884622e+01 + 11 -1.6817605988576226e-01 -4.2337076133540447e-01 -6.9379475746613284e-01 + 12 4.9439004425924287e+00 3.5972141803134012e+00 -2.9063624045380085e+00 + 13 6.0847461884614384e-01 -2.4087582512536937e-01 -1.1429443490171897e-02 + 14 -2.5135966919090408e-01 5.0693343437559137e-02 -6.4882033213846202e-01 + 15 -1.7492135130621190e-02 6.3261129633870539e-01 2.2568696677395544e-01 + 16 1.1533643706799865e+02 -8.2319682718269021e+01 -2.9635546568323292e+02 + 17 -1.1295230473793286e+02 7.8645099709581316e+01 3.0030745767603446e+02 + 18 -2.2515034468785834e-03 -4.3333792383380915e-03 9.9435889422212747e-03 + 19 -3.8285183184657468e-03 -2.3670865665501193e-03 -5.1320932088365747e-03 + 20 5.9936054839043280e-03 6.4927254507248910e-03 -4.5957636846263644e-03 + 21 -1.7771101916350958e+01 -2.0266633257241377e+01 5.6070531525240256e+01 + 22 -2.6828196427086489e+01 -6.5013719610173135e+00 -4.2091321161763837e+01 + 23 4.4599242317851647e+01 2.6768079222089963e+01 -1.3979148411868390e+01 + 24 9.0731337276238602e+00 -5.2584048025594193e+01 2.7844998894928302e+01 + 25 -3.6857511179337159e+01 5.9339663466847528e+00 -3.0985670760400854e+01 + 26 2.7784301129627682e+01 4.6650009976910020e+01 3.1405189423721325e+00 + 27 1.2878799997680197e+01 -5.6365384292184231e+01 2.2564079535768368e+01 + 28 -4.4799160574539911e+01 1.9253173801592041e+01 -3.0311698334899088e+01 29 3.1920395724814831e+01 3.7112241385139740e+01 7.7475953310800270e+00 run_vdwl: 182.54322998463735 run_coul: 0 run_stress: ! |2- - 5.3683122198288640e+02 5.4178378802457769e+02 1.1353333493010725e+03 -1.8652393510886540e+02 5.7315943542766883e+00 1.6367637460475797e+02 + 5.3683122198288606e+02 5.4178378802457758e+02 1.1353333493010723e+03 -1.8652393510886512e+02 5.7315943542765888e+00 1.6367637460475808e+02 run_forces: ! |2 1 -5.4985800660379427e+00 6.6860137696531524e+01 8.1930199058115377e+01 2 3.8943763339079162e+01 3.2101186066798043e+01 -4.5685663412455682e+01 3 -3.5268884048814805e+01 -9.6070477131159592e+01 -3.4950962102053076e+01 4 -5.8110788445779737e-01 1.5332747558659973e-01 -4.1441556892310077e-01 - 5 -1.9983485643709664e-01 -3.4132412196311207e-01 8.7651795021384826e-01 - 6 -2.0475707877718284e+02 2.3656413731867255e+02 2.7690406065284441e+02 - 7 1.4365054876631929e+01 -8.1840771957943403e+01 -4.1598454486600491e+02 - 8 3.4383083802427983e+01 -2.5716756385026692e+01 9.8544673145606026e+01 - 9 1.9493740607077331e+01 2.0908163042484368e+01 8.6173131559856557e+01 - 10 1.3162712158663410e+02 -1.5256247809513576e+02 -4.7318022665875795e+01 - 11 -1.6663043747916428e-01 -4.1842665602207779e-01 -6.8596525639165273e-01 - 12 4.9386412500607531e+00 3.5930375471155727e+00 -2.9133311189121791e+00 - 13 6.0592613726991740e-01 -2.3863451246412490e-01 -1.1243947616635162e-02 - 14 -2.4881617601430056e-01 4.9256493847659046e-02 -6.4206555723776182e-01 + 5 -1.9983485643709656e-01 -3.4132412196311196e-01 8.7651795021384760e-01 + 6 -2.0475707877718267e+02 2.3656413731867238e+02 2.7690406065284435e+02 + 7 1.4365054876631920e+01 -8.1840771957943360e+01 -4.1598454486600480e+02 + 8 3.4383083802427862e+01 -2.5716756385026645e+01 9.8544673145605856e+01 + 9 1.9493740607077342e+01 2.0908163042484379e+01 8.6173131559856586e+01 + 10 1.3162712158663405e+02 -1.5256247809513567e+02 -4.7318022665875759e+01 + 11 -1.6663043747916439e-01 -4.1842665602207813e-01 -6.8596525639165340e-01 + 12 4.9386412500607557e+00 3.5930375471155744e+00 -2.9133311189121809e+00 + 13 6.0592613726991706e-01 -2.3863451246412476e-01 -1.1243947616635157e-02 + 14 -2.4881617601430042e-01 4.9256493847659025e-02 -6.4206555723776149e-01 15 -1.8864672034612142e-02 6.3400103620870663e-01 2.2749995602389267e-01 16 1.1368074742380061e+02 -8.1314893874686348e+01 -2.9210190496613490e+02 17 -1.1129809835055249e+02 7.7640690527244871e+01 2.9605193568469781e+02 - 18 -1.8467319685461141e-03 -3.9327680307163632e-03 9.7963964214631150e-03 - 19 -3.9239527854912802e-03 -2.4372204873194495e-03 -5.2255474424068920e-03 - 20 5.6841881117434614e-03 6.1621918750248477e-03 -4.3549955575843610e-03 - 21 -1.7911431237850785e+01 -2.0223922929187104e+01 5.6099852457401404e+01 - 22 -2.6930668338346326e+01 -6.5737840991111369e+00 -4.2110517739316450e+01 - 23 4.4842043520244751e+01 2.6797781095153024e+01 -1.3989272750175145e+01 - 24 9.5726630373688231e+00 -5.3267309313865724e+01 2.8451784044206295e+01 - 25 -3.7722233711284453e+01 5.9931042726955770e+00 -3.1723790363641090e+01 + 18 -1.8467319685461017e-03 -3.9327680307163562e-03 9.7963964214631289e-03 + 19 -3.9239527854912923e-03 -2.4372204873194564e-03 -5.2255474424069059e-03 + 20 5.6841881117434614e-03 6.1621918750248469e-03 -4.3549955575843610e-03 + 21 -1.7911431237850703e+01 -2.0223922929187065e+01 5.6099852457401440e+01 + 22 -2.6930668338346358e+01 -6.5737840991111449e+00 -4.2110517739316499e+01 + 23 4.4842043520244701e+01 2.6797781095152992e+01 -1.3989272750175129e+01 + 24 9.5726630373687875e+00 -5.3267309313865724e+01 2.8451784044206271e+01 + 25 -3.7722233711284417e+01 5.9931042726955717e+00 -3.1723790363641065e+01 26 2.8149494352154065e+01 4.7274133430564625e+01 3.2718534005530699e+00 - 27 1.3025430772458886e+01 -5.6434742994946994e+01 2.2522352857211565e+01 - 28 -4.4933173873492848e+01 1.9289121683036299e+01 -3.0342495179704237e+01 - 29 3.1907778221419438e+01 3.7145652182215706e+01 7.8201188742906407e+00 + 27 1.3025430772458829e+01 -5.6434742994947030e+01 2.2522352857211544e+01 + 28 -4.4933173873492827e+01 1.9289121683036292e+01 -3.0342495179704223e+01 + 29 3.1907778221419473e+01 3.7145652182215748e+01 7.8201188742906496e+00 ... diff --git a/unittest/force-styles/tests/mol-pair-python_lj.yaml b/unittest/force-styles/tests/mol-pair-python_lj.yaml index ac4fcd9207..31447d6826 100644 --- a/unittest/force-styles/tests/mol-pair-python_lj.yaml +++ b/unittest/force-styles/tests/mol-pair-python_lj.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:56 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:35 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair python @@ -13,7 +14,7 @@ pair_coeff: ! | * * py_pot.LJCutFourMol 1 2 3 4 5 extract: ! "" natoms: 29 -init_vdwl: 769.435514792906 +init_vdwl: 769.4355147929056 init_coul: 0 init_stress: ! |2- 2.2946767381998088e+03 2.2678657381365460e+03 4.7243519151106429e+03 -7.1780988470145303e+02 7.4887575310966838e+01 6.6120102245877695e+02 @@ -47,7 +48,7 @@ init_forces: ! |2 27 6.1705671019807909e+01 -2.7045854429300255e+02 1.0821183331233215e+02 28 -2.1489493703146951e+02 9.2352775183519000e+01 -1.4540033260735669e+02 29 1.5319756790138297e+02 1.7811269192006952e+02 3.7183833054110600e+01 -run_vdwl: 738.819757395753 +run_vdwl: 738.8197573957528 run_coul: 0 run_stress: ! |2- 2.2435980702046804e+03 2.2209196675879020e+03 4.4542444945862735e+03 -6.9874341432935455e+02 9.0014475862275745e+01 6.2292770158619999e+02 diff --git a/unittest/force-styles/tests/mol-pair-soft.yaml b/unittest/force-styles/tests/mol-pair-soft.yaml index d7cba08f72..aae01a2ff8 100644 --- a/unittest/force-styles/tests/mol-pair-soft.yaml +++ b/unittest/force-styles/tests/mol-pair-soft.yaml @@ -1,8 +1,9 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:56 2021 +lammps_version: 17 Feb 2022 tags: unstable +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 1.5e-12 +skip_tests: prerequisites: ! | atom full pair soft @@ -21,7 +22,7 @@ pair_coeff: ! | extract: ! | a 2 natoms: 29 -init_vdwl: 1.84744817921225 +init_vdwl: 1.8474481792122512 init_coul: 0 init_stress: ! |2- 2.6985212108047096e+00 1.8929069643988077e+00 1.7058942753638846e+00 -6.5932149182557853e-01 6.7921581099237488e-02 -3.2192722305869165e-01 @@ -55,7 +56,7 @@ init_forces: ! |2 27 2.6771292067361979e-03 -2.1880100266431633e-02 7.4597018341065590e-03 28 -3.4007977163362471e-02 1.3475065504780894e-03 -1.9395024081220218e-02 29 3.1330847956626273e-02 2.0532593715953545e-02 1.1935322247113659e-02 -run_vdwl: 1.84654240191966 +run_vdwl: 1.8465424019196603 run_coul: 0 run_stress: ! |2- 2.6976828829307093e+00 1.8913987677475295e+00 1.7050584522746157e+00 -6.5843276532938932e-01 6.8347915320120189e-02 -3.2141442928461578e-01 diff --git a/unittest/force-styles/tests/mol-pair-table.yaml b/unittest/force-styles/tests/mol-pair-table.yaml index 1b75119519..28b0c602fb 100644 --- a/unittest/force-styles/tests/mol-pair-table.yaml +++ b/unittest/force-styles/tests/mol-pair-table.yaml @@ -1,9 +1,9 @@ --- -lammps_version: 10 Feb 2021 +lammps_version: 17 Feb 2022 tags: slow -date_generated: Fri Feb 26 23:08:56 2021 -skip_tests: kokkos_omp +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 5e-14 +skip_tests: kokkos_omp prerequisites: ! | atom full pair table @@ -29,7 +29,7 @@ pair_coeff: ! | 5 5 ${input_dir}/pair_table_lj_cut.txt lj_5_5 extract: ! "" natoms: 29 -init_vdwl: 756.641645798358 +init_vdwl: 756.6416457983581 init_coul: 0 init_stress: ! |2- 2.2090340377185967e+03 2.2244453255747117e+03 4.7288126624664974e+03 -7.6403326905269398e+02 2.8082113929050504e+01 6.7633740837364439e+02 @@ -63,7 +63,7 @@ init_forces: ! |2 27 5.3953257632741014e+01 -2.3246330657484364e+02 9.3521822143445291e+01 28 -1.8537423924296499e+02 7.9666126830459447e+01 -1.2542634211727822e+02 29 1.3142887167232908e+02 1.5280375224826219e+02 3.1900088976429561e+01 -run_vdwl: 726.065960788881 +run_vdwl: 726.0659607888813 run_coul: 0 run_stress: ! |2- 2.1627688622718279e+03 2.1802718284070047e+03 4.4504401769393571e+03 -7.4341026090182379e+02 4.5735462684900419e+01 6.3447537883393807e+02 diff --git a/unittest/force-styles/tests/mol-pair-tip4p_cut.yaml b/unittest/force-styles/tests/mol-pair-tip4p_cut.yaml index 8174c5b905..91c42f3bbd 100644 --- a/unittest/force-styles/tests/mol-pair-tip4p_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-tip4p_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 7.5e-13 +skip_tests: prerequisites: ! | atom full pair tip4p/cut @@ -17,7 +18,7 @@ pair_coeff: ! | extract: ! "" natoms: 29 init_vdwl: 0 -init_coul: -128.977932168035 +init_coul: -128.97793216803515 init_stress: ! |- -2.6195455442550621e+01 -4.7354822618385086e+01 -5.5427654107099478e+01 -7.8408966987311342e+00 3.7890121732174942e+00 2.3361498468841489e+01 init_forces: ! |2 @@ -51,7 +52,7 @@ init_forces: ! |2 28 8.5365856050054738e+00 -2.4636423220451302e+00 4.2276358718634395e+00 29 -3.8831706532739356e+00 -5.2900046950811053e+00 -1.5026494435836046e+00 run_vdwl: 0 -run_coul: -129.022909187485 +run_coul: -129.0229091874854 run_stress: ! |- -2.6283108873476834e+01 -4.7364418931021810e+01 -5.5375381382986646e+01 -7.8830194106596636e+00 3.7088788510613115e+00 2.3292677092809960e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-tip4p_long.yaml b/unittest/force-styles/tests/mol-pair-tip4p_long.yaml index fc31ce334c..e79a216951 100644 --- a/unittest/force-styles/tests/mol-pair-tip4p_long.yaml +++ b/unittest/force-styles/tests/mol-pair-tip4p_long.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 5e-13 +skip_tests: prerequisites: ! | atom full pair tip4p/long @@ -27,7 +28,7 @@ extract: ! | typeB 0 natoms: 29 init_vdwl: 0 -init_coul: 220.904555359383 +init_coul: 220.90455535938298 init_stress: ! |- -3.1383522071804158e+01 -4.1960152113677644e+01 -3.8477634382983439e+01 1.2128496669147679e-01 -1.1198183080297536e+01 6.5268065842458656e+00 init_forces: ! |2 @@ -61,7 +62,7 @@ init_forces: ! |2 28 6.4035032875423159e+00 -2.1779017025677483e+00 4.1727109672631357e+00 29 -4.5201953782892055e+00 -5.1735155675050022e+00 -1.4886429234413563e+00 run_vdwl: 0 -run_coul: 220.863348207268 +run_coul: 220.86334820726802 run_stress: ! |- -3.1470779253640760e+01 -4.1975172229753817e+01 -3.8436275607335894e+01 8.1781431494844209e-02 -1.1280185768529634e+01 6.4589599260454849e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-tip4p_long_soft.yaml b/unittest/force-styles/tests/mol-pair-tip4p_long_soft.yaml index 88a80c7e19..cf96b906c2 100644 --- a/unittest/force-styles/tests/mol-pair-tip4p_long_soft.yaml +++ b/unittest/force-styles/tests/mol-pair-tip4p_long_soft.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 1e-13 +skip_tests: prerequisites: ! | atom full pair hybrid/overlay @@ -34,8 +35,8 @@ extract: ! | typeB 0 lambda 2 natoms: 29 -init_vdwl: 8.07036960332134 -init_coul: 100.236229731909 +init_vdwl: 8.070369603321335 +init_coul: 100.23622973190936 init_stress: ! |2- 2.0560777882594444e+01 2.1654965423904063e+01 1.0056493693519297e+01 -2.4240063285208642e+00 -1.3467251681546395e+01 -1.4781331319647904e+01 init_forces: ! |2 @@ -69,7 +70,7 @@ init_forces: ! |2 28 2.5715778047995865e+00 -9.5077350547568862e-01 1.6962019769146084e+00 29 -1.7484754906688658e+00 -2.1330220551799459e+00 -5.7043877074333837e-01 run_vdwl: 8.04558943628112 -run_coul: 100.215621837161 +run_coul: 100.21562183716118 run_stress: ! |2- 2.0456129545317090e+01 2.1511633584982544e+01 9.9821425921767180e+00 -2.3971084012987660e+00 -1.3531454922401075e+01 -1.4734205092861696e+01 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-tip4p_table.yaml b/unittest/force-styles/tests/mol-pair-tip4p_table.yaml index 1417873385..eeef0d30ad 100644 --- a/unittest/force-styles/tests/mol-pair-tip4p_table.yaml +++ b/unittest/force-styles/tests/mol-pair-tip4p_table.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 2.5e-13 +skip_tests: prerequisites: ! | atom full pair tip4p/long @@ -27,7 +28,7 @@ extract: ! | typeB 0 natoms: 29 init_vdwl: 0 -init_coul: 220.904588455609 +init_coul: 220.90458845560877 init_stress: ! |- -3.1383502859909637e+01 -4.1960147680811339e+01 -3.8477621894425063e+01 1.2128693576568650e-01 -1.1198174484192357e+01 6.5268101804125758e+00 init_forces: ! |2 @@ -61,7 +62,7 @@ init_forces: ! |2 28 6.4035005649493479e+00 -2.1779026033513014e+00 4.1727097093108574e+00 29 -4.5201927345996555e+00 -5.1735150000565087e+00 -1.4886414114327997e+00 run_vdwl: 0 -run_coul: 220.863382474572 +run_coul: 220.86338247457192 run_stress: ! |- -3.1470758245374078e+01 -4.1975168324204809e+01 -3.8436259019780465e+01 8.1785199354007770e-02 -1.1280178602908324e+01 6.4589630165689149e+00 run_forces: ! |2 diff --git a/unittest/force-styles/tests/mol-pair-ufm.yaml b/unittest/force-styles/tests/mol-pair-ufm.yaml index e94703032c..2d3c98a3a3 100644 --- a/unittest/force-styles/tests/mol-pair-ufm.yaml +++ b/unittest/force-styles/tests/mol-pair-ufm.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair ufm @@ -22,7 +23,7 @@ extract: ! | sigma 2 scale 2 natoms: 29 -init_vdwl: 15.9448178985075 +init_vdwl: 15.944817898507532 init_coul: 0 init_stress: ! |2- 1.9732282556036175e+01 1.9835191003877362e+01 2.7171236603180098e+01 -6.0276271530964340e+00 2.5967187784084929e+00 -8.1372045900773349e-01 @@ -56,7 +57,7 @@ init_forces: ! |2 27 1.6145714500530384e-01 -1.1022323446883984e+00 3.9068430664596004e-01 28 -8.1023255837556163e-01 3.4809165087801702e-01 -5.4818142230389000e-01 29 6.4875279039251865e-01 7.5412850363458084e-01 1.5750233339920508e-01 -run_vdwl: 15.9412052324003 +run_vdwl: 15.941205232400335 run_coul: 0 run_stress: ! |2- 1.9733523957315395e+01 1.9830296762262655e+01 2.7150737657801326e+01 -6.0174818337155500e+00 2.5979696973782067e+00 -8.0135796716948637e-01 diff --git a/unittest/force-styles/tests/mol-pair-wf_cut.yaml b/unittest/force-styles/tests/mol-pair-wf_cut.yaml index 0b689fd219..bb0db72a4e 100644 --- a/unittest/force-styles/tests/mol-pair-wf_cut.yaml +++ b/unittest/force-styles/tests/mol-pair-wf_cut.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair wf/cut @@ -32,7 +33,7 @@ extract: ! | mu 2 nu 2 natoms: 29 -init_vdwl: 13.331701868543 +init_vdwl: 13.331701868542952 init_coul: 0 init_stress: ! |2- 2.5178354370947517e+01 2.5642248474815997e+01 4.2120178706774510e+01 -6.3752199820262074e+00 2.4423821790103029e+00 4.0948131051558949e+00 @@ -66,7 +67,7 @@ init_forces: ! |2 27 5.1192148870411813e-01 -2.7035848557139470e+00 1.0102720504380645e+00 28 -2.0671223896069999e+00 8.9019054155521471e-01 -1.3998051355791850e+00 29 1.5714660756357337e+00 1.8277974648852422e+00 3.7915040903844482e-01 -run_vdwl: 13.3325799070269 +run_vdwl: 13.33257990702688 run_coul: 0 run_stress: ! |2- 2.5226505134166011e+01 2.5665098713276272e+01 4.2052612927488731e+01 -6.3480044192300973e+00 2.4548005748737984e+00 4.1205804855222423e+00 diff --git a/unittest/force-styles/tests/mol-pair-yukawa.yaml b/unittest/force-styles/tests/mol-pair-yukawa.yaml index 9a0882a1ce..6268ed2d6d 100644 --- a/unittest/force-styles/tests/mol-pair-yukawa.yaml +++ b/unittest/force-styles/tests/mol-pair-yukawa.yaml @@ -1,7 +1,8 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 5e-14 +skip_tests: prerequisites: ! | atom full pair yukawa @@ -18,7 +19,7 @@ pair_coeff: ! | 5 5 250.0 extract: ! "" natoms: 29 -init_vdwl: 12.1140092545333 +init_vdwl: 12.114009254533281 init_coul: 0 init_stress: ! |2- 1.5340283897676171e+01 1.5286756739439106e+01 2.0087158519042458e+01 -4.8365264950233238e+00 1.3285673835968570e+00 -4.5678403668669543e-01 @@ -52,7 +53,7 @@ init_forces: ! |2 27 9.4797146110160047e-02 -6.8646247310384589e-01 2.4639304651374588e-01 28 -5.1616210292097298e-01 2.1221625027252755e-01 -3.4651058440874610e-01 29 4.1219979792460537e-01 4.6817817771676995e-01 1.0395196284048441e-01 -run_vdwl: 12.1106731762831 +run_vdwl: 12.11067317628314 run_coul: 0 run_stress: ! |2- 1.5341399191544641e+01 1.5284077161484550e+01 2.0071770286124949e+01 -4.8293824290737088e+00 1.3289380906389465e+00 -4.4772561803272076e-01 diff --git a/unittest/force-styles/tests/mol-pair-zbl.yaml b/unittest/force-styles/tests/mol-pair-zbl.yaml index 2f29826e67..86f20f1141 100644 --- a/unittest/force-styles/tests/mol-pair-zbl.yaml +++ b/unittest/force-styles/tests/mol-pair-zbl.yaml @@ -1,6 +1,6 @@ --- -lammps_version: 10 Feb 2021 -date_generated: Fri Feb 26 23:08:57 2021 +lammps_version: 17 Feb 2022 +date_generated: Fri Mar 18 22:17:36 2022 epsilon: 1e-12 skip_tests: kokkos_omp prerequisites: ! | @@ -18,7 +18,7 @@ pair_coeff: ! | 5 5 8 8 extract: ! "" natoms: 29 -init_vdwl: 7659.78864729282 +init_vdwl: 7659.788647292821 init_coul: 0 init_stress: ! |2- 1.0415582590870607e+04 7.6650834162083220e+03 1.0439252856553290e+04 2.5596048044422173e+03 3.0124819851995339e+03 3.1820337888462433e+02 @@ -52,7 +52,7 @@ init_forces: ! |2 27 2.8071648439996488e+02 -1.7944615572570910e+03 6.4638439317319535e+02 28 -1.4822931703357754e+03 5.2788334997428888e+02 -9.7294220179957915e+02 29 1.1993303417258362e+03 1.2647795624653104e+03 3.2787996069407274e+02 -run_vdwl: 7354.46773228783 +run_vdwl: 7354.467732287832 run_coul: 0 run_stress: ! |2- 1.0013885258522969e+04 7.4142306464809189e+03 1.0129116432148794e+04 2.4013899531618986e+03 2.8619465741008166e+03 3.1548199080913969e+02