Four. (50 points) In a $2011 \times 2011$ grid, some cells are colored black such that no three black cells form an $\mathrm{L}$ shape (in any of the four possible orientations). What is the maximum number of cells that can be colored black?
First, color the first row, the third row, ..., and the last row. It is clearly satisfied, and the number of colored cells is $(n+1)(2 n+1)$.

Next, prove: If there are $(n+1)(2 n+1)+1$ cells colored, then there exists an L-shape.

When $n=1$, in a $3 \times 3$ grid, if 7 cells are colored, it is obvious that there exists an L-shape.

Assume that when $n=k$, the conclusion holds. Then when $n=k+1$, take out a $(2 k+1) \times(2 k+1)$ grid from the top-left corner of the $(2 k+3) \times(2 k+3)$ grid.

If there are $(2 k+1)(k+1)+1$ cells colored in it, by the induction hypothesis, there is an L-shape. If there are at most $(2 k+1)(k+1)$ cells colored, then in the remaining large L-shape's two rows and two columns, there are at least $4 k+6$ cells colored.

Taking out $2(2 k+2)$ rows in the vertical direction of the large L-shape, there are at most $2 k+2$ cells colored to avoid an L-shape.

Similarly, in the horizontal direction, $2(2 k+2)$ rows have at most $2 k+2$ cells colored. But only one cell in the bottom-right corner is unprocessed, and even if it is colored, there is still one more colored cell. No matter where it is, there must be an L-shape.
Therefore, when $n=k+1$, the conclusion holds.
In summary, the maximum number of cells that can be colored is $(n+1)(2 n+1)$.