determines region of square based on row and column