We fill numbers in cells of $8\times 8$ table so that the sum of all neighbour cells to given cell is 1. What is the sum of all numbers in the table? 
We fill numbers in cells of $8\times 8$ table so that the sum of all neighbour cells to given cell is 1. What is the sum of all numbers in the table? Cells are neighbours if they share an edge.

I've started filling the table, but then it started to look messy: 
Filling tables $2\times 2$ and $4\times 4$ gives result 2 and 6 and it is easy to see that  $3\times 3$ is impossible to fill in this manner. It would be interesting to see why $n\times n$ table with odd $n$ is impossible
to fill in this way.
 A: Observe that the marked cells in this figure

satisfy that its neighbors covers exactly the whole grid (each cell is neighbor of exactly one of the marked cells), so the sum of all numbers is the sum of the neighbors of the marked cells and there are $20$ marked cells so the sum is $20$.
Can you generalize the problem and prove that for a $2n\times 2n$ grid the sum is $n(n+1)$?
A: The following pattern works, though I would expect there to be more
1   1   0   0   1   1   0   0
0   0   0   0   0   0   0   1
0   0   1   1   0   0   0   1
1   0   0   0   0   1   0   0
1   0   0   0   0   1   0   0
0   0   1   1   0   0   0   1
0   0   0   0   0   0   0   1
1   1   0   0   1   1   0   0

The sum is $20$, and if there is only one possible sum then this is it
More generally, you can say that the sum over the square is equal to $\frac{64}{4}=16$ plus a quarter of the sums on the four edges (so in this example $16+\frac{4+4+4+4}{4}=20$), which is $16$ plus half the sum of the four corners plus a quarter of the sum of values on edges but not corners (so in this example $16+\frac22 +\frac{12}{4}=20$)
A: Here is a proof without words that the sum of all entries is equal to $20$. Consider the below coloring. Each group of the colored groups of squares are the set of neighbors of another square, so the labels of each group must sum to one. There are ten groups, covering half of the squares of the board; a symmetric arrangement covers so the other half.  The board is partitioned into $10\times 2=20$ groups, each summing to one, so the board must sum to $20$.

Here is a proof with two pictures and several words of why no matrix exists when $n$ is odd, illustrated when $n=7$.
In the left picture, we partition the off-diagonal entries into three groups whose sum is $1$, proving the sum of the off-diagonal entries is $3$. In the right picture, we similarly prove the sum of the off-diagonal entries is $4$. Contradiction!

