Commit 991ca25d authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

consistent formatting: adjust cases of "dangling else", add curly braces

parent c588b44c
Loading
Loading
Loading
Loading
+32 −64
Original line number Diff line number Diff line
@@ -195,8 +195,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,1,1,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else{
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,1,1,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -204,8 +203,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,1,1,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,1,1,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -214,8 +212,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,1,0,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,1,0,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -223,8 +220,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,1,0,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else{
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,1,0,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -234,8 +230,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,0,1,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,0,1,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -243,8 +238,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,0,1,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,0,1,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -253,8 +247,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,0,0,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,0,0,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -262,8 +255,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,0,0,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,1,0,0,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -274,8 +266,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,1,1,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,1,1,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -283,8 +274,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,1,1,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,1,1,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -293,8 +283,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,1,0,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,1,0,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -302,8 +291,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,1,0,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,1,0,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -313,8 +301,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,0,1,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,0,1,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -322,8 +309,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,0,1,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,0,1,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -332,8 +318,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,0,0,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,0,0,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -341,8 +326,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,0,0,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,1,0,0,0,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -354,8 +338,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,1,1,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,1,1,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -363,8 +346,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,1,1,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,1,1,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -373,8 +355,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,1,0,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,1,0,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -382,8 +363,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,1,0,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,1,0,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -393,8 +373,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,0,1,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,0,1,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -402,8 +381,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,0,1,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,0,1,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -412,8 +390,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,0,0,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,0,0,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -421,8 +398,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,0,0,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,1,0,0,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -433,8 +409,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,1,1,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,1,1,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -442,8 +417,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,1,1,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,1,1,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -452,8 +426,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,1,0,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,1,0,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -461,8 +434,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,1,0,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,1,0,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -472,8 +444,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,0,1,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,0,1,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -481,8 +452,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,0,1,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,0,1,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -491,8 +461,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,0,0,1,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,0,0,1,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
@@ -500,8 +469,7 @@ void FixLangevinKokkos<DeviceType>::post_force(int vflag)
            if (zeroflag) {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,0,0,0,1> post_functor(this);
              Kokkos::parallel_reduce(nlocal,post_functor,s_fsum);
            }
            else {
            } else {
              FixLangevinKokkosPostForceFunctor<DeviceType,0,0,0,0,0,0> post_functor(this);
              Kokkos::parallel_for(nlocal,post_functor);
            }
+2 −4
Original line number Diff line number Diff line
@@ -530,9 +530,7 @@ int PairReaxCKokkos<DeviceType>::Init_Lookup_Tables()
      Natural_Cubic_Spline( &h[1], &fCEclmb[1],
                            &(LR[i][j].CEclmb[1]), control->tabulate+1,
                            world );
    }// else{
     // LR[i][j].n = 0;
    //}//
    }
  }
  free(h);
  free(fh);
+7 −9
Original line number Diff line number Diff line
@@ -279,8 +279,7 @@ void PairAWPMDCut::compute(int eflag, int vflag)
      f[i][0]=fi[ion][0];
      f[i][0]=fi[ion][1];
      f[i][0]=fi[ion][2];
    }
    else { // electron
    } else { // electron
      int iel=gmap[i];
      int s=spin[i] >0 ? 0 : 1;
      wpmd->get_wp_force(s,iel,(Vector_3 *)f[i],(Vector_3 *)(atom->vforce+3*i),atom->erforce+i,atom->ervelforce+i,(Vector_2 *)(atom->csforce+2*i));
@@ -308,8 +307,7 @@ void PairAWPMDCut::compute(int eflag, int vflag)
          continue;
        if (spin[i]==0) {
          eatom[i]=wpmd->Eiep[gmap[i]]+wpmd->Eiip[gmap[i]];
        }
        else {
        } else {
          int s=spin[i] >0 ? 0 : 1;
          eatom[i]=wpmd->Eep[s][gmap[i]]+wpmd->Eeip[s][gmap[i]]+wpmd->Eeep[s][gmap[i]]+wpmd->Ewp[s][gmap[i]];
        }
@@ -474,9 +472,9 @@ void PairAWPMDCut::coeff(int narg, char **arg)
  if(cut_global<0)
    cut_global=half_box_length;

  if (!allocated)
  if (!allocated) {
    allocate();
  else{
  } else {
    int i,j;
    for (i = 1; i <= atom->ntypes; i++)
      for (j = i; j <= atom->ntypes; j++)
+15 −22
Original line number Diff line number Diff line
@@ -1017,9 +1017,9 @@ void FixLbFluid::peskin_interpolation(int i)
  for(ii=-1; ii<3; ii++){
    rsq=(-dx1+ii)*(-dx1+ii);

    if(rsq>=4)
    if(rsq>=4) {
      weightx=0.0;
    else{
    } else {
      r=sqrt(rsq);
      if(rsq>1){
        weightx=(5.0-2.0*r-sqrt(-7.0+12.0*r-4.0*rsq))/8.;
@@ -1029,9 +1029,9 @@ void FixLbFluid::peskin_interpolation(int i)
    }
    for(jj=-1; jj<3; jj++){
      rsq=(-dy1+jj)*(-dy1+jj);
      if(rsq>=4)
      if(rsq>=4) {
        weighty=0.0;
      else{
      } else {
        r=sqrt(rsq);
        if(rsq>1){
          weighty=(5.0-2.0*r-sqrt(-7.0+12.0*r-4.0*rsq))/8.;
@@ -1041,9 +1041,9 @@ void FixLbFluid::peskin_interpolation(int i)
      }
      for(kk=-1; kk<3; kk++){
        rsq=(-dz1+kk)*(-dz1+kk);
        if(rsq>=4)
        if(rsq>=4) {
          weightz=0.0;
        else{
        } else {
          r=sqrt(rsq);
          if(rsq>1){
            weightz=(5.0-2.0*r-sqrt(-7.0+12.0*r-4.0*rsq))/8.;
@@ -1090,8 +1090,7 @@ require more frequent neighborlist rebuilds");
    massone = massone/dm_lb;

    gammavalue = 2.0*(mnode*massone)*dtoverdtcollision/(mnode+massone);
  }
  else{
  } else {
    gammavalue = Gamma[type[i]];
  }

@@ -2836,8 +2835,7 @@ void FixLbFluid::update_full15(void)
             }
           }
         }
       }
       else{
       } else {
         update_periodic(1,subNbx-1,1,subNby-1,subNbz-2,subNbz-1);
       }
     }
@@ -2866,8 +2864,7 @@ void FixLbFluid::update_full15(void)
           if(typeLB == 1){
             fnew[i][j][k][5]=fnew[i][j][k-1][6];
             tmp1=fnew[i][j][k-1][11]+fnew[i][j][k-1][12]+fnew[i][j][k-1][13]+fnew[i][j][k-1][14];
           }
           else{
           } else {
             fnew[i][j][k][5]=fnew[i][j][k-1][6] + (0.5-Dcoeff*(tau+0.5))*feqn[i][j][k+1][5];
             tmp1=fnew[i][j][k-1][11]+fnew[i][j][k-1][12]+fnew[i][j][k-1][13]+fnew[i][j][k-1][14] +
               (0.5-Dcoeff*(tau+0.5))*(feqn[i-1][j-1][k+1][7] + feqn[i+1][j-1][k+1][8] +
@@ -2908,8 +2905,7 @@ void FixLbFluid::update_full15(void)
           if(typeLB == 1){
             fnew[i][j][k][6]=fnew[i][j][k+1][5];
             tmp1=fnew[i][j][k+1][7]+fnew[i][j][k+1][8]+fnew[i][j][k+1][9]+fnew[i][j][k+1][10];
           }
           else{
           } else {
             fnew[i][j][k][6]=fnew[i][j][k+1][5] + (0.5-Dcoeff*(tau+0.5))*feqn[i][j][k-1][6];
             tmp1=fnew[i][j][k+1][7]+fnew[i][j][k+1][8]+fnew[i][j][k+1][9]+fnew[i][j][k+1][10] +
               (0.5-Dcoeff*(tau+0.5))*(feqn[i-1][j-1][k-1][11] + feqn[i+1][j-1][k-1][12] +
@@ -3193,8 +3189,7 @@ void FixLbFluid::update_full19(void)
            }
          }
        }
      }
      else{
      } else {
        update_periodic(1,subNbx-1,1,subNby-1,subNbz-2,subNbz-1);
      }
    }
@@ -3224,8 +3219,7 @@ void FixLbFluid::update_full19(void)
          if(typeLB == 1){
            fnew[i][j][k][5]=fnew[i][j][k-1][6];
            tmp1=fnew[i][j][k-1][12]+fnew[i][j][k-1][14]+fnew[i][j][k-1][16]+fnew[i][j][k-1][18];
          }
          else{
          } else {
            fnew[i][j][k][5]=fnew[i][j][k-1][6] + (0.5-Dcoeff*(tau+0.5))*feqn[i][j][k+1][5];
            tmp1=fnew[i][j][k-1][12]+fnew[i][j][k-1][14]+fnew[i][j][k-1][16]+fnew[i][j][k-1][18] +
              (0.5-Dcoeff*(tau+0.5))*(feqn[i-1][j][k+1][11] + feqn[i+1][j][k+1][13] +
@@ -3261,8 +3255,7 @@ void FixLbFluid::update_full19(void)
          if(typeLB == 1){
            fnew[i][j][k][6]=fnew[i][j][k+1][5];
            tmp1=fnew[i][j][k+1][11]+fnew[i][j][k+1][13]+fnew[i][j][k+1][15]+fnew[i][j][k+1][17];
          }
          else{
          } else {
            fnew[i][j][k][6]=fnew[i][j][k+1][5] + (0.5-Dcoeff*(tau+0.5))*feqn[i][j][k-1][6];
            tmp1=fnew[i][j][k+1][11]+fnew[i][j][k+1][13]+fnew[i][j][k+1][15]+fnew[i][j][k+1][17] +
              (0.5-Dcoeff*(tau+0.5))*(feqn[i-1][j][k-1][12] + feqn[i+1][j][k-1][14] +
+6 −6
Original line number Diff line number Diff line
@@ -387,9 +387,9 @@ int FixLbPC::unpack_exchange(int nlocal, double *buf)
        for(ii=-1; ii<3; ii++){
          rsq=(-dx1+ii)*(-dx1+ii);

          if(rsq>=4)
          if(rsq>=4) {
            weightx=0.0;
          else{
          } else {
            r=sqrt(rsq);
            if(rsq>1){
              weightx=(5.0-2.0*r-sqrt(-7.0+12.0*r-4.0*rsq))/8.;
@@ -399,9 +399,9 @@ int FixLbPC::unpack_exchange(int nlocal, double *buf)
          }
          for(jj=-1; jj<3; jj++){
            rsq=(-dy1+jj)*(-dy1+jj);
            if(rsq>=4)
            if(rsq>=4) {
              weighty=0.0;
            else{
            } else {
              r=sqrt(rsq);
              if(rsq>1){
                weighty=(5.0-2.0*r-sqrt(-7.0+12.0*r-4.0*rsq))/8.;
@@ -411,9 +411,9 @@ int FixLbPC::unpack_exchange(int nlocal, double *buf)
            }
            for(kk=-1; kk<3; kk++){
              rsq=(-dz1+kk)*(-dz1+kk);
              if(rsq>=4)
              if(rsq>=4) {
                weightz=0.0;
              else{
              } else {
                r=sqrt(rsq);
                if(rsq>1){
                  weightz=(5.0-2.0*r-sqrt(-7.0+12.0*r-4.0*rsq))/8.;
Loading