Commit 8e808f6c authored by Stan Moore's avatar Stan Moore
Browse files

Zeroing variables in pair_exp6_rx_kokkos to match pull request

parent 5897955e
Loading
Loading
Loading
Loading
+34 −30
Original line number Diff line number Diff line
@@ -311,9 +311,6 @@ void PairExp6rxKokkos<DeviceType>::operator()(TagPairExp6rxCompute<NEIGHFLAG,NEW
  double mixWtSite1_i, mixWtSite1_j;
  double mixWtSite2_i, mixWtSite2_j;

  fpairOldEXP6_12 = 0.0;
  fpairOldEXP6_21 = 0.0;

  const int nRep = 12;
  const double shift = 1.05;
  double rin1, aRep, uin1, win1, uin1rep, rin1exp, rin6, rin6inv;
@@ -415,6 +412,13 @@ void PairExp6rxKokkos<DeviceType>::operator()(TagPairExp6rxCompute<NEIGHFLAG,NEW
      rm21_ij = 0.5*(rm2_i + rm1_j);
      epsilon21_ij = sqrt(epsilon2_i*epsilon1_j);

      evdwlOldEXP6_12 = 0.0;
      evdwlOldEXP6_21 = 0.0;
      evdwlEXP6_12 = 0.0;
      evdwlEXP6_21 = 0.0;
      fpairOldEXP6_12 = 0.0;
      fpairOldEXP6_21 = 0.0;

      if(rmOld12_ij!=0.0 && rmOld21_ij!=0.0){
        if(alphaOld21_ij == 6.0 || alphaOld12_ij == 6.0)
          k_error_flag.d_view() = 1;
@@ -577,6 +581,7 @@ void PairExp6rxKokkos<DeviceType>::operator()(TagPairExp6rxCompute<NEIGHFLAG,NEW
        } else {
          evdwlEXP6_21 = buck1*(6.0*rexp - alpha21_ij*rm6ij*r6inv) - urc - durc*(r-rCut);
        }
      }

      //
      // Apply Mixing Rule to get the overall force for the CG pair
@@ -607,7 +612,6 @@ void PairExp6rxKokkos<DeviceType>::operator()(TagPairExp6rxCompute<NEIGHFLAG,NEW
      if (EVFLAG) this->template ev_tally<NEIGHFLAG,NEWTON_PAIR>(ev,i,j,evdwl,fpair,delx,dely,delz);
    }
  }
  }

  a_f(i,0) += fx_i;
  a_f(i,1) += fy_i;