Added failing test to demonstrate bug
Fixed crashing bug with getNeighborsND (wrapAround=true case)
Fixed bug with getNeighborsND
Small refactor
Refactor range function
Comments and formatting
Merge pull request #127 from chetan51/issue-125

Fixed crashing bug with getNeighborsND (wrapAround=true case)