login
A283438
The largest possible size of a set in F_3^n, free of three-term arithmetic progressions with the difference in {0,1}^n.
1
1, 2, 6, 14, 36
OFFSET
0,2
COMMENTS
102 <= a(5) <= 108. - Robert Israel, Mar 10 2017
EXAMPLE
a(0) = 1: {()}.
a(1) = 2: {(0), (1)}.
a(2) = 6: {(0,0), (0,2), (1,1), (1,2), (2,0), (2,1)}.
a(3) = 14: {(0,0,0), (0,0,2), (0,2,0), (0,2,2), (1,0,1), (1,0,2), (1,1,0), (1,1,1), (1,2,0), (1,2,2), (2,0,0), (2,0,1), (2,1,0), (2,1,1)}.
PROG
(PARI) \\ This code is for demonstration only, it is far too slow for computation!
ok(v)=vecmax(lift(v))<2
has(v)=my(t); for(i=1, #v, for(j=1, #v, if(i==j, next); for(k=1, #v, if(i==k||j==k, next); t=v[i]-v[j]; if(v[j]-v[k]==t && ok(t), return(0))))); 1
a(n)=my(N=3^n, v=vector(N, i, digits(N+i-1, 3)[2..n+1]), u, r, t); for(i=0, 2^N-1, u=Mod(vecextract(v, i), 3); if(has(u), t=hammingweight(i); if(t>r, r=t))); r \\ Charles R Greathouse IV, Mar 07 2017
CROSSREFS
Sequence in context: A231509 A318018 A025257 * A362780 A323027 A110152
KEYWORD
nonn,more,hard
AUTHOR
Vsevolod F. Lev, Mar 07 2017
EXTENSIONS
a(4) from Robert Israel, Mar 07 2017
STATUS
approved