%I #11 Jan 22 2023 03:01:36
%S 0,0,0,1,0,1,0,1,1,0,3,0,4,0,3,0,3,1,0,7,0,6,0,7,0,6,0,7,1,0,9,0,10,0,
%T 8,0,10,0,9,0,10,1,0,11,0,14,0,13,0,14,0,12,0,13,1,1,3,0,17,0,17,0,18,
%U 0,17,0,18,0,17,1,2,3,0,21,0,23,0,22,0,23,0
%N a(n) is the number of k > 0 such that n-1-2*k >= 0 and a(n-1-2*k) >= a(n-1-k) >= a(n-1).
%C This sequence is unbounded:
%C - by contradiction: suppose that a(n) < M for some fixed M,
%C - then, by Van der Waerden's theorem, we have an arithmetic progression of 2*M+1 indices where the sequence has the same value: say a(m) = a(m + k*r) for k = 0..2*M with m >= 0 and r > 0,
%C - this would imply that a(m + 2*M*r + 1) >= M, a contradiction.
%C This sequence has infinitely many 0's (if a(m) < a(n) for any m < n, then a(n+1) = 0).
%H Rémy Sigrist, <a href="/A359866/b359866.txt">Table of n, a(n) for n = 0..10000</a>
%H Rémy Sigrist, <a href="/A359866/a359866.png">Scatterplot of the first 250000 terms</a>
%H Rémy Sigrist, <a href="/A359866/a359866.txt">C program</a>
%H Wikipedia, <a href="https://en.wikipedia.org/wiki/Van_der_Waerden%27s_theorem">Van der Waerden's theorem</a>.
%e The first terms, alongside the corresponding k's, are:
%e n a(n) k's
%e -- ---- ------------
%e 0 0 {}
%e 1 0 {}
%e 2 0 {}
%e 3 1 {1}
%e 4 0 {}
%e 5 1 {2}
%e 6 0 {}
%e 7 1 {2}
%e 8 1 {2}
%e 9 0 {}
%e 10 3 {1, 2, 3}
%e 11 0 {}
%e 12 4 {2, 3, 4, 5}
%o (C) See Links section.
%Y Cf. A359867.
%K nonn,look
%O 0,11
%A _Rémy Sigrist_, Jan 16 2023