login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Lexicographically earliest sequence of positive integers such that for any distinct m and n, Sum_{k = m+1-a(m)..m} a(k) <> Sum_{k = n+1-a(n)..n} a(k).
4

%I #12 Oct 26 2020 02:02:35

%S 1,2,2,3,2,3,4,2,3,4,3,4,4,3,5,4,5,4,4,5,5,6,4,5,6,5,6,5,6,6,5,7,6,6,

%T 7,6,5,7,8,4,8,6,6,7,8,6,7,7,8,6,7,8,7,8,8,8,6,9,7,8,8,9,8,7,8,9,8,9,

%U 8,9,10,8,9,9,8,10,9,9,10,8,10,9,10,9,9

%N Lexicographically earliest sequence of positive integers such that for any distinct m and n, Sum_{k = m+1-a(m)..m} a(k) <> Sum_{k = n+1-a(n)..n} a(k).

%C In other words, for any n > 0, the sum of the a(n) terms up to and including a(n) is always unique.

%C This sequence is unbounded.

%H Rémy Sigrist, <a href="/A338283/b338283.txt">Table of n, a(n) for n = 1..10000</a>

%H Rémy Sigrist, <a href="/A338283/a338283.gp.txt">PARI program for A338283</a>

%e The first terms, alongside the corresponding sums, are:

%e n a(n) a(n+1-a(n))+...+a(n)

%e -- ---- --------------------

%e 1 1 1

%e 2 2 3

%e 3 2 4

%e 4 3 7

%e 5 2 5

%e 6 3 8

%e 7 4 12

%e 8 2 6

%e 9 3 9

%e 10 4 13

%o (PARI) See Links section.

%Y See A336346 and A338292 for similar sequences.

%Y Cf. A338285 (corresponding sums).

%K nonn

%O 1,2

%A _Rémy Sigrist_, Oct 20 2020