merged in current master

This commit is contained in:
Steve Plimpton
2022-11-04 08:22:18 -06:00
3789 changed files with 21727 additions and 7888 deletions

View File

@ -2,7 +2,7 @@
/* ----------------------------------------------------------------------
LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
https://www.lammps.org/, Sandia National Laboratories
Steve Plimpton, sjplimp@sandia.gov
LAMMPS development team: developers@lammps.org
Copyright (2003) Sandia Corporation. Under the terms of Contract
DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains
@ -831,8 +831,8 @@ int Input::execute_command()
// try suffixed version first
std::string mycmd = command;
if (lmp->suffix_enable && lmp->suffix) {
mycmd = command + std::string("/") + lmp->suffix;
if (lmp->suffix_enable && lmp->non_pair_suffix()) {
mycmd = command + std::string("/") + lmp->non_pair_suffix();
if (command_map->find(mycmd) == command_map->end()) {
if (lmp->suffix2) {
mycmd = command + std::string("/") + lmp->suffix2;
@ -1429,19 +1429,19 @@ void Input::comm_modify()
void Input::comm_style()
{
if (narg < 1) error->all(FLERR,"Illegal comm_style command");
if (narg < 1) utils::missing_cmd_args(FLERR, "comm_style", error);
if (strcmp(arg[0],"brick") == 0) {
if (comm->style == 0) return;
if (comm->style == Comm::BRICK) return;
Comm *oldcomm = comm;
comm = new CommBrick(lmp,oldcomm);
delete oldcomm;
} else if (strcmp(arg[0],"tiled") == 0) {
if (comm->style == 1) return;
if (comm->style == Comm::TILED) return;
Comm *oldcomm = comm;
if (lmp->kokkos) comm = new CommTiledKokkos(lmp,oldcomm);
else comm = new CommTiled(lmp,oldcomm);
delete oldcomm;
} else error->all(FLERR,"Illegal comm_style command");
} else error->all(FLERR,"Unknown comm_style argument: {}", arg[0]);
}
/* ---------------------------------------------------------------------- */
@ -1497,7 +1497,7 @@ void Input::dihedral_style()
void Input::dimension()
{
if (narg != 1) error->all(FLERR,"Illegal dimension command: expected 1 argument but found {}", narg);
if (narg != 1) error->all(FLERR, "Dimension command expects exactly 1 argument");
if (domain->box_exist)
error->all(FLERR,"Dimension command after simulation box is defined");
domain->dimension = utils::inumeric(FLERR,arg[0],false,lmp);
@ -1507,8 +1507,7 @@ void Input::dimension()
// must reset default extra_dof of all computes
// since some were created before dimension command is encountered
for (int i = 0; i < modify->ncompute; i++)
modify->compute[i]->reset_extra_dof();
for (auto &c : modify->get_compute_list()) c->reset_extra_dof();
}
/* ---------------------------------------------------------------------- */
@ -1774,10 +1773,7 @@ void Input::pair_style()
int match = 0;
if (style == force->pair_style) match = 1;
if (!match && lmp->suffix_enable) {
if (lmp->suffixp)
if (style + "/" + lmp->suffixp == force->pair_style) match = 1;
if (lmp->suffix && !lmp->suffixp)
if (lmp->suffix)
if (style + "/" + lmp->suffix == force->pair_style) match = 1;
if (lmp->suffix2)