MathDB
Gardens of Rectangular Grids

Source: 2013 USAJMO Problem 2

April 30, 2013
algorithmJMOgrids

Problem Statement

Each cell of an m×nm\times n board is filled with some nonnegative integer. Two numbers in the filling are said to be adjacent if their cells share a common side. (Note that two numbers in cells that share only a corner are not adjacent). The filling is called a garden if it satisfies the following two conditions:
(i) The difference between any two adjacent numbers is either 00 or 11. (ii) If a number is less than or equal to all of its adjacent numbers, then it is equal to 00.
Determine the number of distinct gardens in terms of mm and nn.