login
A356255
a(1) = 1; for n > 1, a(n) is the smallest magnitude number not occurring earlier such that n is divisible by s = Sum_{k = 1..n} a(k), where |s| > 1.
1
1, -3, -1, 5, 3, -2, 4, -5, 7, -4, 6, -7, 9, -6, 8, -11, 13, -8, 10, -9, 11, -10, 12, -15, -13, 18, 14, -20, 22, -14, 16, -23, -19, 28, -12, -17, -25, 35, 15, -18, -36, 20, -22, 21, 17, -41, 93, -31, 33, -24, 26, -38, 40, -26, -16, -39, 25, 32, 30, -29, 31, -30, -28, 29, -27, 61, -133, 50, -52, 34
OFFSET
1,2
COMMENTS
The sequence is finite - after 2020 terms, a(2020) = -669, the sum of all terms is 4 so the next term would have to be 4 less than the divisors with magnitude > 1 of 2021, namely 2017, 43, 39, -47, -51, -2025. However these six numbers have all previously occurred so the sequence terminates.
LINKS
EXAMPLE
a(7) = 4 as Sum_{k = 1..7} a(k) = 1 - 3 - 1 + 5 + 3 - 2 + 4 = 7, and 4 is the smallest magnitude number not occurring earlier that forms a sum with magnitude > 1 that is a divisor of 7.
CROSSREFS
Cf. A019444 (sum of terms is divisible by n), A027749, A027750.
Sequence in context: A209578 A268829 A249100 * A152203 A340526 A161946
KEYWORD
sign,fini,full
AUTHOR
Scott R. Shannon, Oct 15 2022
STATUS
approved