Tweak the formulas for unsafeSquares