diff --git a/src/MANYBODY/pair_polymorphic.cpp b/src/MANYBODY/pair_polymorphic.cpp index b807cb2a07..d01e126371 100755 --- a/src/MANYBODY/pair_polymorphic.cpp +++ b/src/MANYBODY/pair_polymorphic.cpp @@ -108,7 +108,7 @@ void PairPolymorphic::compute(int eflag, int vflag) int itype,jtype,ktype; int iparam_ii,iparam_jj,iparam_kk,iparam_ij,iparam_ik,iparam_ijk; double xtmp,ytmp,ztmp,delx,dely,delz,evdwl,fpair; - double rsq,rsq1,rsq2,r0,r1,r2; + double rsq,r0,r1,r2; double delr1[3],delr2[3],fi[3],fj[3],fk[3]; double zeta_ij,prefactor,wfac,pfac,gfac,fa,fa_d,bij,bij_d; double costheta; @@ -872,7 +872,8 @@ void PairPolymorphic::grab(FILE *fp, int n, double *list) fgets(line,MAXLINE,fp); ptr = strtok(line," \t\n\r\f"); list[i++] = atof(ptr); - while (ptr = strtok(NULL," \t\n\r\f")) list[i++] = atof(ptr); + while ((ptr = strtok(NULL," \t\n\r\f"))) + list[i++] = atof(ptr); } } diff --git a/src/USER-MGPT/mgpt_readpot.cpp b/src/USER-MGPT/mgpt_readpot.cpp index 144c661b05..62d5311c4e 100644 --- a/src/USER-MGPT/mgpt_readpot.cpp +++ b/src/USER-MGPT/mgpt_readpot.cpp @@ -155,7 +155,7 @@ static void getparmindata(const char *potin_file,int nvol[1],double vol0[1],doub void potdata::readpot(const char *parmin_file,const char *potin_file,const double vol) { FILE *in; - double x0,x1,dx,dr; + double x0,x1,dx; int nx; double r0x,r1x,drx; @@ -347,7 +347,7 @@ void potdata::readpot(const char *parmin_file,const char *potin_file,const doubl nrx = (int) ((r1x-r0x)/drx + 1.1); /* Really: 1+round((r1-r0)/dr) */ if(ii == 0) { - r0 = r0x; r1 = r1x; dr = drx; nr = nrx; + r0 = r0x; r1 = r1x; nr = nrx; vpairtab = new double[nx*nr]; } else { /* Check that {r0,r1,dr,nr}x == {r0,r1,dr,nr} */ @@ -372,9 +372,6 @@ void potdata::readpot(const char *parmin_file,const char *potin_file,const doubl double r0rws = r0rwstab[i]; double r00 = r0rws*rws,rp = 1.8*rws; if(bscreen == 0) r0rws = 10.0; - double alp = al,alm = al; - if(mode == 2 || mode == 4 || mode == 6) alm = 125.0; - al = alp; double r = r0 + j*(r1-r0)/(nr-1); @@ -389,17 +386,12 @@ void potdata::readpot(const char *parmin_file,const char *potin_file,const doubl if(bscreen == 1 && rrws >= r0rws) { double arg = rrws/r0rwstab[i]; - double arg1 = arg - 1.0; - double arg12 = arg1*arg1; - double f,dp; + double f; if(mode <= 2) { f = fgauss(arg,al); - dp=2.*al*arg*arg1; } else { f = hgauss(arg,al); - double arg13 = arg1*arg12; - dp=2.0*al*al*arg*arg13/(1.+al*arg12); } fscr = f*f; } diff --git a/src/USER-MISC/improper_distance.cpp b/src/USER-MISC/improper_distance.cpp index a98f404d52..a98005a247 100644 --- a/src/USER-MISC/improper_distance.cpp +++ b/src/USER-MISC/improper_distance.cpp @@ -65,7 +65,6 @@ void ImproperDistance::compute(int eflag, int vflag) // double ss1,ss2,ss3,r1,r2,r3,c0,c1,c2,s1,s2; // double s12,c,s,domega,a,a11,a22,a33,a12,a13,a23; double domega,a; - double sx2,sy2,sz2; eimproper = 0.0; if (eflag || vflag) ev_setup(eflag,vflag);