for(dim = 0; dim < ImageDimension; dim++) {
// The following block is equivalent to the following line without
// having to call floor. (Only for positive inputs, we already now that is in the image)
for(dim = 0; dim < ImageDimension; dim++) {
// The following block is equivalent to the following line without
// having to call floor. (Only for positive inputs, we already now that is in the image)