Add VoxelArray::index3d method, reverse to num
Split new distance code into distarray.cpp and distarray.h