OFFSET
1,2
COMMENTS
The differences between consecutive terms are <= 2^9. So the sequence contains arbitrarily long arithmetic progressions. The sequence of powers of 2 does not contain progressions, however. This is a result of the fact that 2^n satisfies the recurrence relation a(n+1)=2a(n).
FORMULA
a(n) = Sum_{k=1..n} 2^d(k) where d(k) = A034004(k).
EXAMPLE
2^d(1) + 2^d(2) + 2^d(3) = 2^0 + 2^1 + 2^3 = 11.
MATHEMATICA
Accumulate[2^Flatten@ Map[IntegerDigits, Array[# (# + 1)/2 &, 23, 0]]] (* Michael De Vlieger, Aug 03 2017 *)
PROG
(PARI) lista(nn) = {print1(cur=1, ", "); for(n=1, nn, d = digits(n*(n+1)/2); for(i=1, #d, cur += 2^d[i]; print1(cur, ", "); ); ); } \\ Michel Marcus, Jul 21 2017
(PARI) first(n) = {my(d = [0], i = 1, t = 2, res = vector(n)); res[1] = 1; while(#d < n, d = concat(d, digits(i)); i+=t; t++); for(i=2, n, res[i] = res[i-1] + 2^d[i]); res} \\ David A. Corneth, Aug 03 2017
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Joseph Wheat, Jul 17 2017
EXTENSIONS
More terms from Michel Marcus, Jul 21 2017
STATUS
approved