Open GuoYongFa opened 5 months ago
I think that the problem is here:
this->_cells->at(cellIndex - neighbourOffset)
This can lead to "negative" (-> overflowed) results. Unfortunately, I am not really into this part of the code and I am not sure if this traversal is still in use at all.
When running with the configuration file "examples/force-exchange/testcube-dense-fs.xml", I encountered an index out-of-bounds issue. Below, I've added comments hypothesizing the potential cause of this error, though I admit my usage is limited and I'm not entirely sure if my speculation is correct. My operating system is Ubuntu 22.04, with gcc version 11.4.0.