Skip to main content
4 of 6
added n=14 and its fairest sequences

The Thue-Morse sequence isn't a solution when $n=8$, but it gets close. Here are the fairest sequences with $v_0\ge v_1$ for small $n = $ $1,$ $2,$ $\dots,$ $13$, according to an exhaustive brute-force search, where $v_b$ denotes the expected score for the player choosing when the binary digit is $b$.

EDIT: added $n=14$ and its $18$ fairest sequences with $v_0\ge v_1$.

$$\begin{array}{rcccc} n&\text{fairest with }v_0\ge v_1&v_0&v_1&v_0-v_1\\ \hline 2&10&5/3&3/2&1/6\\ 3&001&5/2&7/3&1/6\\ 4&0110&10/3&16/5&2/15\\ 5&11010&62/15&33/8&1/120\\ \\ 6&000011&5&5&0\\ &001110&5&5&0\\ &110001&5&5&0\\ &111100&5&5&0\\ \\ 7&1000101&377/64&88/15&23/960\\ \\ 8&00110110&61/9&27/4&1/36\\ &10000011&61/9&27/4&1/36\\ &10001110&61/9&27/4&1/36\\ &10110001&61/9&27/4&1/36\\ &10111100&61/9&27/4&1/36\\ &11110010&61/9&27/4&1/36\\ \\ 9&011000101&245/32&574/75&7/2400\\ \\ 10&0100110110&77/9&94/11&1/99\\ &0110000011&77/9&94/11&1/99\\ &0110001110&77/9&94/11&1/99\\ &0110110001&77/9&94/11&1/99\\ &0110111100&77/9&94/11&1/99\\ &0111110010&77/9&94/11&1/99\\ \\ 11&00101101001&3309/350&8417/891&2369/311850\\ \\ 12&101000001101 &1481/143 &559/54 &37/7722\\ &101001000011 &1481/143 &559/54 &37/7722\\ &101001001110 &1481/143 &559/54 &37/7722\\ &101001110001 &1481/143 &559/54 &37/7722\\ &101001111100 &1481/143 &559/54 &37/7722\\ &101011001001 &1481/143 &559/54 &37/7722\\ \\ 13&0110100111010 &2534/225 &13873/1232 &463/277200\\ \\ 14& 00001010010011 & 1205/99 & 426/35 & 1/3465 \\ & 00001010011110 & 1205/99 & 426/35 & 1/3465 \\ & 00111000110110 & 1205/99 & 426/35 & 1/3465 \\ & 00111010000011 & 1205/99 & 426/35 & 1/3465 \\ & 00111010001110 & 1205/99 & 426/35 & 1/3465 \\ & 01111010011010 & 1205/99 & 426/35 & 1/3465 \\ & 00111010110001 & 1205/99 & 426/35 & 1/3465 \\ & 00111010111100 & 1205/99 & 426/35 & 1/3465 \\ & 00111011110010 & 1205/99 & 426/35 & 1/3465 \\ & 10001010010101 & 1205/99 & 426/35 & 1/3465 \\ & 10001011010110 & 1205/99 & 426/35 & 1/3465 \\ & 10111010000101 & 1205/99 & 426/35 & 1/3465 \\ & 11111000010110 & 1205/99 & 426/35 & 1/3465 \\ & 11111010010001 & 1205/99 & 426/35 & 1/3465 \\ & 11111010011100 & 1205/99 & 426/35 & 1/3465 \\ & 10111011000110 & 1205/99 & 426/35 & 1/3465 \\ & 11111011010010 & 1205/99 & 426/35 & 1/3465 \\ & 10111011110100 & 1205/99 & 426/35 & 1/3465 \\ \end{array}$$

Source code (in need of optimisation) in GP/PARI:

f(s,b,i0,k) = { if(#s==1, s[1],
    if(b%2, sum(i=i0,#s,f(setminus(s,[s[i]]), b\2, i, k+1))/#s*(k+1),
            f(vecextract(s,"2.."), b\2, 1, 0)
    ))
};
p(b) = { if(b>1, print1(b%2); p(b\2)) };
g(n) = { d0 = n+1; s = vector(n+1,i,i-1);
    for(b = 0, 2^(n-1)-1,
        v0 = f(s,b,1,0); v1 = f(s, 2^n-1-b, 1, 0);
        if(d0 >= abs(v0-v1), d0 = abs(v0-v1); b0 = b;
            p(b0+2^n); print(" ",v0,"  ",v1,"  ",d0)
    ))
};

g(14);