| # | Line 1389 | Line 1389 | namespace OpenMD { | |
|---|---|---|
| 1389 | for (int j = 0; j < 3; j++) { | |
| 1390 | scaled[j] -= roundMe(scaled[j]); | |
| 1391 | scaled[j] += 0.5; | |
| 1392 | + | // Handle the special case when an object is exactly on the | 
| 1393 | + | // boundary (a scaled coordinate of 1.0 is the same as | 
| 1394 | + | // scaled coordinate of 0.0) | 
| 1395 | + | if (scaled[j] >= 1.0) scaled[j] -= 1.0; | 
| 1396 | } | |
| 1397 | ||
| 1398 | // find xyz-indices of cell that cutoffGroup is in. | |
| – | Removed lines | 
| + | Added lines | 
| < | Changed lines | 
| > | Changed lines |