[Math] Count the number of rectangles in this figure.

combinatoricsrectangles

Find the number of rectangles whose edges lie completely on the grid lines of following figure

enter image description here

The answer says

enter image description here

But in the answer I do not understand the part that says:

"We can count these rectangles as follows: the number of rectangles with the center of the grid lying in the
interior of its south edge is $3 × 3 × 3 = 27$ (there are three choices for each of the three other edges)"

Can anyone please explain to me how they got this answer?

Best Answer

It's counting the number of rectangles for which the center of the grid is strictly within the south edge (the strictly part confused me at first too). In that case:

  • there are three ways to pick the left endpoint of the south edge (any of the first three red point on the central horizontal line);
  • independently, there are three ways to pick the right endpoint of the south edge (any green point);
  • and independently, there are three choices for the height of the rectangle (blue arrows).

enter image description here

Related Question