A334126 a(n) is the smallest positive integer not already in the sequence such that Sum_{i=k..n} a(i) is not a perfect power for 0 < k < n; start with a(1)=1.
1, 2, 3, 7, 5, 6, 17, 12, 8, 10, 4, 16, 13, 11, 15, 18, 19, 9, 14, 23, 20, 30, 22, 21, 26, 36, 29, 24, 27, 32, 25, 33, 34, 35, 28, 46, 31, 37, 47, 38, 39, 49, 41, 48, 40, 42, 50, 43, 44, 51, 45, 52, 53, 56, 54, 58, 59, 55, 62, 65, 68, 67, 57, 63, 64, 70, 61, 69
Offset: 1
Keywords
Programs
-
PARI
lista(nn) = {my(k, s, v=vector(nn)); v[1]=1; for(n=2, nn, k=s=2; while(vecsearch(vecsort(v), k) || sum(i=1, n-1, ispower(s+=v[n-i])), s=k++); v[n]=k); v; }
Comments