Adding a routine to convert arrays to morton codes.