1
$\begingroup$

Ex. Given the below five sets if you select the following values [4, 5, 7, 8, 23] you can say that an even number of values are selected in all five sets.

1...{1,3,[4],[5],10}-----2

2...{3,[8],22,[23],25}---2

3...{2,[5],[7],11,12}----2

4...{1,[4],6,[8],9}------2

5...{[4],6,[7],9,10}-----2

Question: Is there a set of values in the range [1, 25], which when chosen, result in an even number of values being selected in all twenty-five sets listed below?

1.....{1,  2,  5,  7, 10,  12,  15,  17,  20,  22,  25}

2.....{1,  2,  3,  6,  8,  11,  13,  16,  18,  21,  23}

3.....{2,  3,  4,  7,  9,  12,  14,  17,  19,  22,  24}

4.....{3,  4,  5,  8, 10,  13,  15,  18,  20,  23,  25}

5.....{1,  4,  5,  6,  9,  11,  14,  16,  19,  21,  24}

6.....{2,  5,  6,  7, 10,  12,  15,  17,  20,  22,  25}

7.....{1,  3,  6,  7,  8,  11,  13,  16,  18,  21,  23}

8.....{2,  4,  7,  8,  9,  12,  14,  17,  19,  22,  24}

9.....{3,  5,  8,  9, 10,  13,  15,  18,  20,  23,  25}

10...{1,  4,  6,  9, 10,  11,  14,  16,  19,  21,  24}

11...{2,  5,  7, 10,  11,  12,  15,  17,  20,  22,  25}

12...{1,  3,  6,  8,  11,  12,  13,  16,  18,  21,  23}

13...{2,  4,  7,  9,  12,  13,  14,  17,  19,  22,  24}

14...{3,  5,  8, 10,  13,  14,  15,  18,  20,  23,  25}

15...{1,  4,  6,  9,  11,  14,  15,  16,  19,  21,  24}

16...{2,  5,  7, 10,  12,  15,  16,  17,  20,  22,  25}

17...{1,  3,  6,  8,  11,  13,  16,  17,  18,  21,  23}

18...{2,  4,  7,  9,  12,  14,  17,  18,  19,  22,  24}

19...{3,  5,  8, 10,  13,  15,  18,  19,  20,  23,  25}

20...{1,  4,  6,  9,  11,  14,  16,  19,  20,  21,  24}

21...{2,  5,  7, 10,  12,  15,  17,  20,  21,  22,  25}

22...{1,  3,  6,  8,  11,  13,  16,  18,  21,  22,  23}

23...{2,  4,  7,  9,  12,  14,  17,  19,  22,  23,  24}

24...{3,  5,  8, 10,  13,  15,  18,  20,  23,  24,  25}

25...{1,  4,  6,  9,  11,  14,  16,  19,  21,  24,  25}

1 Answers 1

0

Yes, there exists a set of values in the range [1, 25], which when chosen, result in an even number of values being selected in all twenty-five sets listed in the question. Proof: the empty set results in zero values being selected in all twenty-five sets, and thus fulfills the required condition. We don't even need to consider the particular 25 sets given!

Solving a linear system in the Booleans, as follows, gives all the solutions. It turns out there is no other.


We can represent the desired set of values in the range [1, 25] as 25 Boolean unknown $x_i$ with $x_i=1$ iff $i$ belongs to the desired set.

The constraint that the desired set result in an even number of values being selected in all twenty-five (given) sets... boils down to 25 equations, each determined by one of the 25 given sets, with an equation being that $0$ equals the exclusive-OR of the $x_i$ with $i$ in the given set.

We can turn the 25 given sets into a 25x25 boolean matrix $M$ (with the values in set $j$ determining the position where there are $1$ on line $j$ of matrix $M$ ), and we are after solving $$\begin{pmatrix}0\\\vdots\\0\end{pmatrix}=M\cdot\begin{pmatrix}x_1\\\vdots\\x_{25}\end{pmatrix}$$

That particular $M$ is (with Boolean elements) $$\begin{pmatrix} 1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1\\ 1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0\\ 0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0\\ 0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1\\ 1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0\\ 0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1\\ 1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0\\ 0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0\\ 0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1\\ 1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0\\ 0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0&1\\ 1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0&0\\ 0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1&0\\ 0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0&1\\ 1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1&0\\ 0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0&1\\ 1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0&0\\ 0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1&0\\ 0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0&1\\ 1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1&0\\ 0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0&1\\ 1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0&0\\ 0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1&0\\ 0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1&1\\ 1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&0&1&0&0&1&1\\ \end{pmatrix}$$ and is a circulant matrix, also symmetric. This eases computing its determinant, which is 1. The system thus as no other solution; there would be several for determinant 0.

  • 0
    I have insufficient funds for upvoting, but I had not considered zero being even! Would you be willing to provide code in the answer? Like a binary filter for combination set selection.2017-12-31