login
A348330
Lexicographically earliest sequence of positive integers such that for any n > 0, the sum of the indices k < n such that a(k) = a(n) is strictly less than n.
2
1, 1, 2, 1, 2, 3, 3, 1, 2, 4, 4, 5, 5, 3, 6, 1, 6, 2, 7, 7, 8, 4, 8, 9, 9, 5, 10, 3, 10, 11, 11, 1, 6, 12, 12, 2, 13, 13, 14, 7, 14, 15, 15, 4, 8, 16, 16, 17, 17, 9, 18, 5, 18, 19, 19, 3, 10, 20, 20, 21, 21, 11, 22, 1, 22, 6, 23, 23, 24, 12, 24, 2, 25, 25, 26
OFFSET
1,3
COMMENTS
Every integer appears infinitely many times.
See table A348356 where the integers are arranged according to the present sequence.
FORMULA
a(n) = 1 iff n is a power of 2 (A000079).
PROG
(PARI) s=vector(25); for (n=1, 75, for (k=1, oo, if (s[k]<n, print1 (k", "); s[k]+=n; break)))
CROSSREFS
KEYWORD
nonn
AUTHOR
Rémy Sigrist, Oct 13 2021
STATUS
approved