Use a more numerically reasonable test for equally-spaced latitudes.  It has a chance of working for very coarse grids.