more robust testing if field is a boundary field
Previous test would give false positives for cases where the number of points in the z direction would match the x direction.