I'm working on it now by carefully listing all the possibilities.
Is there a fast way to do this? And what's the answer anyways?
I'm working on it now by carefully listing all the possibilities.
Is there a fast way to do this? And what's the answer anyways?
select two horizontal lines from the available $8$ horizonal lines
$\dbinom{8}{2}$ ways
select two vertical lines from the available 7 vertical lines
$\dbinom{7}{2}$ ways
Required count of rectangles
$\dbinom{8}{2} \times \dbinom{7}{2}$
This is the way I solved this problem before I read Kiran's answer that exposed a faster method: The grid that encloses the $7 \times 6$ rectangles consists of $8 \times 7$ lines and $8 \cdot 7 = 56$ points. Two of such points define the diagonal of a rectangle and therefore exactely one rectangle. There are $56 \choose 2$ pairs of points. But if two points lie on the same horizontal line or on the same vertical line this is a degenerated rectangle that we won't count. On a horizontal line we can choose $8 \choose 2$ pairs of points and there are $7$ horizontal lines. On a vertical line we can choose $7 \choose 2$ pairs of points and there are $8$ vertical lines. We have to subtract them from our number. The remaining number counts each rectangle twice because a rectangle has two diagonale. So there are
$$\left ({56 \choose 2} - 7 \cdot {8 \choose 2} - 8 \cdot {7 \choose 2}\right)/2$$ rectangles.