Maths Olympiad Prep

Library / /807 of 860

Geometry Difficulty 5.6 AIME, harder Find the answer

Let n>1n>1 be a positive integer. Each unit square in an n×nn \times n grid of squares is colored either black or white, such that the following conditions hold: - Any two black squares can be connected by a sequence of black squares where every two consecutive squares in the sequence share an edge; - Any two white squares can be connected by a sequence of white squares where every two consecutive squares in the sequence share an edge; - Any 2×22 \times 2 subgrid contains at least one square of each color. Determine, with proof, the maximum possible difference between the number of black squares and white squares in this grid (in terms of nn).

A number or a short expression. Fractions can be typed as 3/2, and spacing doesn't matter.

Solution

Answer: 2n+12n+1 if nn is odd, 2n22n-2 if nn is even. Solution: The first two conditions also imply that there can be no 2×22 \times 2 checkerboards, so the boundary between black squares and white squares is either a lattice path or cycle (if one color encloses the other). Therefore, the set of squares of each color is the interior of a lattice polygon of genus 0 or 1. (In the latter case, the genus-1 color uses all squares on the outer boundary, and the opposite color must be genus-0.) The third condition requires that the perimeter of each color passes through all (n1)2(n-1)^{2} interior lattice points, or else there will be a monochromatic 2×22 \times 2 subgrid. Hence, by Pick's Theorem, the area of one color is at least (n1)2/21=(n22n1)/2(n-1)^{2} / 2-1=\left(n^{2}-2n-1\right) / 2, and the difference is at most n2(n22n1)=2n+1n^{2}-\left(n^{2}-2n-1\right)=2n+1. For even nn, the number of interior lattice points is odd so there is no cycle that only uses them. (In particular, this means that both colors are genus-0.) It is impossible for the perimeter to only go through one boundary point either, so we need to add at least three more boundary points, which means that we lose 2(3/2)=32(3 / 2)=3 from the bound for odd nn. Here is one possible set of constructions. Throughout, we'll label the squares as (x,y)(x, y), for 1x,yn1 \leq x, y \leq n: - For n=2n=2, we color (2,2)(2,2) black and the others white. - For odd values of nn, we create a comb shape using black squares. Specifically, the base of the comb will consist of the squares (i,2)(i, 2), for i=2,3,,n1i=2,3, \ldots, n-1. The teeth of the comb will be (2k,j)(2k, j), for k=1,2,,n12k=1,2, \ldots, \frac{n-1}{2}, and j=3,4,,n1j=3,4, \ldots, n-1. - For even values of n>2n>2, we make a modified comb shape. The base of the comb will be (i,2)(i, 2) for i=2,3,,ni=2,3, \ldots, n, and the teeth will be (2k,j)(2k, j) for k=1,2,,n21k=1,2, \ldots, \frac{n}{2}-1 and j=3,4,,n1j=3,4, \ldots, n-1. Furthermore, we add the square (n,3)(n, 3), and the squares (n1,2k+3)(n-1,2k+3) for k=1,2,,n22k=1,2, \ldots, \frac{n}{2}-2.

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: Omni-MATH, licensed Apache-2.0. Statement and solution reproduced as published; topic and difficulty added by this site.