3

I have $8008$ binary grids of size $6 \times 10$ (they are all grids with the property described below), which I want to distinguish between with at most $13$ queries. A query will determine if the cell $A_{i,j}$ of a grid is $0$ or $1$.

The grids all have a nice structure. If you find a $0$ in a cell, all cells above and to the right are guaranteed to be $0$. If you find a $1$, all cells below and to the left are guaranteed to contain $1$.

An example grid is

$$\begin{matrix} 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 1 & 1 & 1 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 1 & 1 & 1 & 1 & 1 & 1 & 0 & 0 & 0 \\ 1 & 1 & 1 & 1 & 1 & 1 & 1 & 1 & 1 & 0 \\ \end{matrix}$$

For an unknown grid $A$ if a query $A_{4, 3}$ returned $0$ I could fill in all values above and to the right of it.

$$\begin{matrix} - & - & - & - & 0 & 0 & 0 & 0 & 0 & 0 \\ - & - & - & - & 0 & 0 & 0 & 0 & 0 & 0 \\ - & - & - & - & 0 & 0 & 0 & 0 & 0 & 0 \\ - & - & - & - & 0 & 0 & 0 & 0 & 0 & 0 \\ - & - & - & - & - & - & - & - & - & - \\ - & - & - & - & - & - & - & - & - & - \\ \end{matrix}$$


Since there are $8008$ grids, I believe it should be possible to distinguish the grids with at most $\log_2{8008} \approx 12.97 \lt 13$ queries. The best I've managed to do it is with 15 queries, by building a decision tree greedily (picking the query which divides the space as evenly as possible). I haven't found any algorithms that will build a minimal height decision tree in a reasonable length of time.

Is there any way to do this?

spyr03
  • 238
  • 1
  • 8

0 Answers0