46. a) How many different rectangles, in terms of size or position, consisting of whole cells, can be drawn on a chessboard of 64 cells?

b) The same question for a chessboard of $n^{2}$ cells.
46. a) First, let's determine how many rectangles can be found on a chessboard, composed of whole numbers of

![](https://cdn.mathpix.com/cropped/2024_05_21_68334347b64402497ba5g-187.jpg?height=479&width=454&top_left_y=1086&top_left_x=144)

Fig. 61. cells and having a given width \( k \) and a given height \( l \). Each such rectangle is obtained by selecting \( k \) consecutive verticals and \( l \) consecutive horizontals (Fig. 61). A group of \( k \) consecutive verticals can be chosen in \( 8-k+1=9-k \) different ways (the first vertical of the group can be the 1st, 2nd, 3rd, ..., \((8-k+1)\)-th vertical of the board); similarly, \( l \) consecutive horizontals can be chosen in \( 8-l+1=9-l \) ways. Therefore, a rectangle of width \( k \) and height \( l \) can be chosen in 
\[
(9-k)(9-l)
\]
different ways, i.e., there are \((9-k)(9-l)\) such rectangles on the board.

Now let's count how many different rectangles of a given width \( k \) exist on the chessboard. The height \( l \) of the rectangle can vary from 1 to 8; therefore, the number of such rectangles is

\[
\begin{aligned}
& (9-k)(9-1) + (9-k)(9-2) + \ldots + (9-k)(9-8) = \\
& \quad = (9-k)(8 + 7 + 6 + 5 + 4 + 3 + 2 + 1) = 36(9-k)
\end{aligned}
\]

Considering now that the width \( k \) of the rectangle can also vary from 1 to 8, we find that the total number of different rectangles is

\[
\begin{aligned}
& 36(9-1) + 36(9-2) + \ldots + 36(9-8) = \\
& \quad = 36(8 + 7 + 6 + 5 + 4 + 3 + 2 + 1) = 36 \cdot 36 = 1296
\end{aligned}
\]

b) Analogously to the solution of part a), we conclude that the number of all possible rectangles of width \( k \) and height \( l \) on an \( n^2 \)-cell board is \((n+1-k)(n+1-l)\). The number of all possible rectangles of a given width \( k \) is

\[
(n+1-k)(1 + 2 + \ldots + n) = (n+1-k) \frac{n(n+1)}{2}
\]

and the number of all possible different rectangles is

\[
\frac{n(n+1)}{2}(1 + 2 + \ldots + n) = \left[\frac{n(n+1)}{2}\right]^2
\]