modernize
This commit is contained in:
@ -549,12 +549,9 @@ void FixShardlow::initial_integrate(int /*vflag*/)
|
||||
error->all(FLERR,"Fix shardlow does not yet support triclinic geometries");
|
||||
|
||||
if (rcut >= bbx || rcut >= bby || rcut>= bbz )
|
||||
{
|
||||
char fmt[] = {"Shardlow algorithm requires sub-domain length > 2*(rcut+skin). Either reduce the number of processors requested, or change the cutoff/skin: rcut= %e bbx= %e bby= %e bbz= %e\n"};
|
||||
char *msg = (char *) malloc(sizeof(fmt) + 4*15);
|
||||
sprintf(msg, fmt, rcut, bbx, bby, bbz);
|
||||
error->one(FLERR, msg);
|
||||
}
|
||||
error->one(FLERR,"Shardlow algorithm requires sub-domain length > 2*(rcut+skin). "
|
||||
"Either reduce the number of processors requested, or change the cutoff/skin: "
|
||||
"rcut= {} bbx= {} bby= {} bbz= {}\n", rcut, bbx, bby, bbz);
|
||||
|
||||
NPairHalfBinNewtonSSA *np_ssa = dynamic_cast<NPairHalfBinNewtonSSA*>(list->np);
|
||||
if (!np_ssa) error->one(FLERR, "NPair wasn't a NPairHalfBinNewtonSSA object");
|
||||
|
||||
@ -676,16 +676,11 @@ void FixPIMD::comm_exec(double **ptr)
|
||||
int index = atom->map(tag_send[i]);
|
||||
|
||||
if (index < 0) {
|
||||
char error_line[256];
|
||||
|
||||
sprintf(error_line,
|
||||
"Atom " TAGINT_FORMAT " is missing at world [%d] "
|
||||
"rank [%d] required by rank [%d] (" TAGINT_FORMAT ", " TAGINT_FORMAT
|
||||
", " TAGINT_FORMAT ").\n",
|
||||
tag_send[i], universe->iworld, comm->me, plan_recv[iplan], atom->tag[0],
|
||||
atom->tag[1], atom->tag[2]);
|
||||
|
||||
error->universe_one(FLERR, error_line);
|
||||
auto mesg = fmt::format("Atom {} is missing at world [{}] rank [{}] "
|
||||
"required by rank [{}] ({}, {}, {}).\n",
|
||||
tag_send[i], universe->iworld, comm->me,
|
||||
plan_recv[iplan], atom->tag[0], atom->tag[1], atom->tag[2]);
|
||||
error->universe_one(FLERR, mesg);
|
||||
}
|
||||
|
||||
memcpy(wrap_ptr, ptr[index], ncpy);
|
||||
|
||||
@ -840,11 +840,9 @@ void TAD::initialize_event_list() {
|
||||
|
||||
void TAD::delete_event_list() {
|
||||
|
||||
for (int i = 0; i < n_event_list; i++) {
|
||||
char str[128];
|
||||
sprintf(str,"tad_event_%d",i);
|
||||
modify->delete_fix(str);
|
||||
}
|
||||
for (int i = 0; i < n_event_list; i++)
|
||||
modify->delete_fix(fmt::format("tad_event_{}",i));
|
||||
|
||||
memory->sfree(fix_event_list);
|
||||
fix_event_list = nullptr;
|
||||
n_event_list = 0;
|
||||
|
||||
Reference in New Issue
Block a user