silence compiler warnings
This commit is contained in:
@ -154,7 +154,7 @@ void FixUpdateSpecialBonds::pre_exchange()
|
||||
|
||||
void FixUpdateSpecialBonds::pre_force(int /*vflag*/)
|
||||
{
|
||||
int ilist, nlist, i1, i2, j, jj, jnum;
|
||||
int i1, i2, j, jj, jnum;
|
||||
int *jlist, *numneigh, **firstneigh;
|
||||
tagint tag1, tag2;
|
||||
NeighList *list;
|
||||
|
||||
@ -38,8 +38,7 @@ class ComputeRattlersAtom : public Compute {
|
||||
void unpack_reverse_comm(int, int *, double *) override;
|
||||
|
||||
private:
|
||||
int pstyle, cutstyle;
|
||||
int ncontacts_rattler, max_tries, nmax, invoked_peratom;
|
||||
int cutstyle, ncontacts_rattler, max_tries, nmax, invoked_peratom;
|
||||
int *ncontacts;
|
||||
double *rattler;
|
||||
class NeighList *list;
|
||||
|
||||
@ -33,12 +33,11 @@
|
||||
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
#include <iostream>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
static const char cite_compute_slcsa_atom_c[] =
|
||||
"compute slcsa/atom command: doi:10.1088/0965-0393/21/5/055020\n\n"
|
||||
"compute slcsa/atom command: doi:10.1016/j.commatsci.2023.112534\n\n"
|
||||
"@Article{Lafourcade2023,\n"
|
||||
" author = {P. Lafourcade and J.-B. Maillet and C. Denoual and E. Duval and A. Allera and A. "
|
||||
"M. Goryaeva and M.-C. Marinica},\n"
|
||||
@ -46,8 +45,8 @@ static const char cite_compute_slcsa_atom_c[] =
|
||||
"density-independent spectral descriptor and supervised learning},\n"
|
||||
" journal = {Computational Materials Science},\n"
|
||||
" year = 2023,\n"
|
||||
" volume = XX,\n"
|
||||
" pages = {XXXXXX}\n"
|
||||
" volume = 230,\n"
|
||||
" pages = 112534\n"
|
||||
"}\n\n";
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
@ -79,6 +78,8 @@ ComputeSLCSAAtom::ComputeSLCSAAtom(LAMMPS *lmp, int narg, char **arg) :
|
||||
// # LR bias vector
|
||||
// vector with 1 row x nclasses cols
|
||||
|
||||
if (lmp->citeme) lmp->citeme->add(cite_compute_slcsa_atom_c);
|
||||
|
||||
if (narg != 11) utils::missing_cmd_args(FLERR, "compute slcsa/atom", error);
|
||||
|
||||
int twojmax = utils::inumeric(FLERR, arg[3], false, lmp);
|
||||
|
||||
@ -53,14 +53,12 @@ class ComputeSLCSAAtom : public Compute {
|
||||
value_t descriptorval;
|
||||
int nmax;
|
||||
int ncols;
|
||||
int nevery;
|
||||
int ncomps;
|
||||
int nclasses;
|
||||
const char *database_mean_descriptor_file;
|
||||
const char *lda_scalings_file;
|
||||
const char *lr_decision_file;
|
||||
const char *lr_bias_file;
|
||||
const char *covmat_file;
|
||||
const char *maha_file;
|
||||
class NeighList *list;
|
||||
|
||||
|
||||
@ -202,7 +202,7 @@ void FixNonaffineDisplacement::init()
|
||||
// need an occasional half neighbor list
|
||||
|
||||
if (cut_style == RADIUS) {
|
||||
auto req = neighbor->add_request(this, NeighConst::REQ_SIZE | NeighConst::REQ_OCCASIONAL);
|
||||
neighbor->add_request(this, NeighConst::REQ_SIZE | NeighConst::REQ_OCCASIONAL);
|
||||
} else {
|
||||
auto req = neighbor->add_request(this, NeighConst::REQ_OCCASIONAL);
|
||||
if (cut_style == CUSTOM) {
|
||||
@ -233,7 +233,7 @@ void FixNonaffineDisplacement::init_list(int /*id*/, NeighList *ptr)
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
void FixNonaffineDisplacement::setup(int vflag)
|
||||
void FixNonaffineDisplacement::setup(int /*vflag*/)
|
||||
{
|
||||
post_force(0); // Save state if needed before starting the 1st timestep
|
||||
}
|
||||
@ -285,7 +285,6 @@ void FixNonaffineDisplacement::restart(char *buf)
|
||||
|
||||
void FixNonaffineDisplacement::integrate_velocity()
|
||||
{
|
||||
int i,n;
|
||||
dtv = update->dt;
|
||||
|
||||
double **v = atom->v;
|
||||
@ -306,7 +305,6 @@ void FixNonaffineDisplacement::integrate_velocity()
|
||||
|
||||
void FixNonaffineDisplacement::save_reference_state()
|
||||
{
|
||||
int i, n;
|
||||
double **x = atom->x;
|
||||
|
||||
int *mask = atom->mask;
|
||||
@ -354,15 +352,14 @@ void FixNonaffineDisplacement::calculate_D2Min()
|
||||
|
||||
int i, j, k, l, ii, jj, inum, jnum, itype, jtype;
|
||||
double evol, j2, edev;
|
||||
double r[3], r0[3], rsq, rsq0, radsum, temp[3];
|
||||
double r[3], r0[3], rsq, radsum, temp[3];
|
||||
double X_tmp[3][3], Y_tmp[3][3], F_tmp[3][3], E[3][3];
|
||||
double Y_inv[3][3] = {0.0}; // Zero for 2d since not all entries used
|
||||
double Y_inv[3][3] = {{0.0,0.0,0.0},{0.0,0.0,0.0},{0.0,0.0,0.0}}; // Zero for 2d since not all entries used
|
||||
int *ilist, *jlist, *numneigh, **firstneigh;
|
||||
|
||||
double **x = atom->x;
|
||||
double **x0 = array_atom;
|
||||
double *radius = atom->radius;
|
||||
tagint *tag = atom->tag;
|
||||
int *type = atom->type;
|
||||
int *mask = atom->mask;
|
||||
int nlocal = atom->nlocal;
|
||||
|
||||
@ -338,7 +338,7 @@ void DihedralQuadratic::born_matrix(int nd, int i1, int i2, int i3, int i4,
|
||||
double sb1,sb3,rb1,rb3,c0,b1mag2,b1mag,b2mag2;
|
||||
double b2mag,b3mag2,b3mag,ctmp,r12c1,c1mag,r12c2;
|
||||
double c2mag,sc1,sc2,s12,c;
|
||||
double s1,s2,cx,cy,cz,cmag,dx,phi,si,siinv,sin2;
|
||||
double cx,cy,cz,cmag,dx,phi,si,siinv,sin2;
|
||||
|
||||
int **dihedrallist = neighbor->dihedrallist;
|
||||
double **x = atom->x;
|
||||
@ -405,8 +405,6 @@ void DihedralQuadratic::born_matrix(int nd, int i1, int i2, int i3, int i4,
|
||||
if (sc2 < SMALL) sc2 = SMALL;
|
||||
sc2 = 1.0/sc2;
|
||||
|
||||
s1 = sc1 * sc1;
|
||||
s2 = sc2 * sc2;
|
||||
s12 = sc1 * sc2;
|
||||
c = (c0 + c1mag*c2mag) * s12;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user