Commit 8494cb74 authored by Peter Eastman's avatar Peter Eastman
Browse files

DrudeLangevinIntegrator was not disabling hardwall constraint for maxDistance=0

parent 4daf8d5d
...@@ -364,9 +364,11 @@ void CudaIntegrateDrudeLangevinStepKernel::execute(ContextImpl& context, const D ...@@ -364,9 +364,11 @@ void CudaIntegrateDrudeLangevinStepKernel::execute(ContextImpl& context, const D
// Apply hard wall constraints. // Apply hard wall constraints.
void* hardwallArgs[] = {&cu.getPosq().getDevicePointer(), &posCorrection, &cu.getVelm().getDevicePointer(), if (maxDrudeDistance > 0) {
&pairParticles->getDevicePointer(), &integration.getStepSize().getDevicePointer(), maxDrudeDistancePtr, hardwallscaleDrudePtr}; void* hardwallArgs[] = {&cu.getPosq().getDevicePointer(), &posCorrection, &cu.getVelm().getDevicePointer(),
cu.executeKernel(hardwallKernel, hardwallArgs, pairParticles->getSize()); &pairParticles->getDevicePointer(), &integration.getStepSize().getDevicePointer(), maxDrudeDistancePtr, hardwallscaleDrudePtr};
cu.executeKernel(hardwallKernel, hardwallArgs, pairParticles->getSize());
}
integration.computeVirtualSites(); integration.computeVirtualSites();
// Update the time and step count. // Update the time and step count.
......
...@@ -376,7 +376,8 @@ void OpenCLIntegrateDrudeLangevinStepKernel::execute(ContextImpl& context, const ...@@ -376,7 +376,8 @@ void OpenCLIntegrateDrudeLangevinStepKernel::execute(ContextImpl& context, const
// Apply hard wall constraints. // Apply hard wall constraints.
cl.executeKernel(hardwallKernel, pairParticles->getSize()); if (maxDrudeDistance > 0)
cl.executeKernel(hardwallKernel, pairParticles->getSize());
integration.computeVirtualSites(); integration.computeVirtualSites();
// Update the time and step count. // Update the time and step count.
......
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