diff --git a/src/ML-UF3/pair_uf3.cpp b/src/ML-UF3/pair_uf3.cpp index 0f828833a4..2ce4a3e8c4 100644 --- a/src/ML-UF3/pair_uf3.cpp +++ b/src/ML-UF3/pair_uf3.cpp @@ -119,7 +119,7 @@ void PairUF3::settings(int narg, char **arg) error->all(FLERR, "Invalid number of arguments for pair_style uf3" " Are you using a 2-body or 2 & 3-body UF potential?"); - nbody_flag = utils::numeric(FLERR, arg[0], true, lmp); + nbody_flag = utils::inumeric(FLERR, arg[0], true, lmp); if (nbody_flag == 2) { pot_3b = false; manybody_flag = 0; diff --git a/src/MOFFF/angle_cosine_buck6d.cpp b/src/MOFFF/angle_cosine_buck6d.cpp index bc6b8eb51a..601b7429f0 100644 --- a/src/MOFFF/angle_cosine_buck6d.cpp +++ b/src/MOFFF/angle_cosine_buck6d.cpp @@ -256,7 +256,7 @@ void AngleCosineBuck6d::coeff(int narg, char **arg) double c_one = utils::numeric(FLERR,arg[1],false,lmp); int n_one = utils::inumeric(FLERR,arg[2],false,lmp); - int th0_one = utils::numeric(FLERR,arg[3],false,lmp); + double th0_one = utils::numeric(FLERR,arg[3],false,lmp); if (n_one <= 0) error->all(FLERR,"Incorrect args for angle coefficients" + utils::errorurl(21)); diff --git a/src/pair_table.cpp b/src/pair_table.cpp index 08f1d12d4d..2ff428c427 100644 --- a/src/pair_table.cpp +++ b/src/pair_table.cpp @@ -424,7 +424,7 @@ void PairTable::read_table(Table *tb, char *file, char *keyword) } else if (tb->rflag == BMP) { rsq_lookup.i = i << nshiftbits; rsq_lookup.i |= masklo; - if (rsq_lookup.f < tb->rlo * tb->rlo) { + if ((double)rsq_lookup.f < tb->rlo * tb->rlo) { rsq_lookup.i = i << nshiftbits; rsq_lookup.i |= maskhi; } @@ -759,7 +759,7 @@ void PairTable::compute_table(Table *tb) for (int i = 0; i < ntable; i++) { rsq_lookup.i = i << tb->nshiftbits; rsq_lookup.i |= masklo; - if (rsq_lookup.f < tb->innersq) { + if ((double)rsq_lookup.f < tb->innersq) { rsq_lookup.i = i << tb->nshiftbits; rsq_lookup.i |= maskhi; } @@ -809,7 +809,7 @@ void PairTable::compute_table(Table *tb) if (itablemax == 0) itablemaxm1 = ntablem1; rsq_lookup.i = itablemax << tb->nshiftbits; rsq_lookup.i |= maskhi; - if (rsq_lookup.f < tb->cut * tb->cut) { + if ((double)rsq_lookup.f < tb->cut * tb->cut) { if (tb->match) { tb->de[itablemax] = tb->de[itablemaxm1]; tb->df[itablemax] = tb->df[itablemaxm1]; @@ -821,7 +821,7 @@ void PairTable::compute_table(Table *tb) f_tmp = splint(tb->rfile, tb->ffile, tb->f2file, tb->ninput, r) / r; tb->de[itablemax] = e_tmp - tb->e[itablemax]; tb->df[itablemax] = f_tmp - tb->f[itablemax]; - tb->drsq[itablemax] = 1.0 / (rsq_lookup.f - tb->rsq[itablemax]); + tb->drsq[itablemax] = 1.0 / ((double)rsq_lookup.f - tb->rsq[itablemax]); } } }