Commit cfa7ab82 authored by Peter Eastman's avatar Peter Eastman
Browse files

Fixed bug in building neighbor list

parent 06c82bc0
...@@ -29,7 +29,7 @@ extern "C" __global__ void findBlockBounds(int numAtoms, real4 periodicBoxSize, ...@@ -29,7 +29,7 @@ extern "C" __global__ void findBlockBounds(int numAtoms, real4 periodicBoxSize,
real4 blockSize = 0.5f*(maxPos-minPos); real4 blockSize = 0.5f*(maxPos-minPos);
real4 center = 0.5f*(maxPos+minPos); real4 center = 0.5f*(maxPos+minPos);
center.w = 0; center.w = 0;
for (int i = base+1; i < last; i++) { for (int i = base; i < last; i++) {
pos = posq[i]; pos = posq[i];
real4 delta = posq[i]-center; real4 delta = posq[i]-center;
#ifdef USE_PERIODIC #ifdef USE_PERIODIC
......
...@@ -29,7 +29,7 @@ __kernel void findBlockBounds(int numAtoms, real4 periodicBoxSize, real4 invPeri ...@@ -29,7 +29,7 @@ __kernel void findBlockBounds(int numAtoms, real4 periodicBoxSize, real4 invPeri
real4 blockSize = 0.5f*(maxPos-minPos); real4 blockSize = 0.5f*(maxPos-minPos);
real4 center = 0.5f*(maxPos+minPos); real4 center = 0.5f*(maxPos+minPos);
center.w = 0; center.w = 0;
for (int i = base+1; i < last; i++) { for (int i = base; i < last; i++) {
pos = posq[i]; pos = posq[i];
real4 delta = posq[i]-center; real4 delta = posq[i]-center;
#ifdef USE_PERIODIC #ifdef USE_PERIODIC
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment