This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A339793 #29 Jan 16 2023 09:10:46 %S A339793 1,2,3,4,6,12,16,15,9,8,7,5,10,24,36,55,17,11,13,14,20,22,28,56,64,63, %T A339793 41,18,21,33,30,42,54,66,78,90,144,259,45,99,57,23,19,25,48,76,128, %U A339793 127,26,32,31,27,39,34,40,50,43,29,35,52,46,104,106,112,136,134,70,74,80,212,166,86,92,152 %N A339793 a(1) = 1, a(2) = 2; for n > 2, a(n) is the smallest positive number not occurring earlier that is a multiple of s(a(n-1)), the sum of the proper divisors of a(n-1). %C A339793 The sequence is possibly a permutation of the positive integers as when a(n-1) is prime a(n) will be the next smallest number that has not previously occurred. However this will depend on the likelihood of a(n) being a prime as n goes to infinity. For the first 478 terms the last prime is a(144) = 59, while a(478) = 19140499834691254267668, indicating prime values become increasingly rare, and could potentially have a finite number as n->infinity. %C A339793 The sum of the proper divisors of n is given by A001065(n). %H A339793 Scott R. Shannon, <a href="/A339793/b339793.txt">Table of n, a(n) for n = 1..478</a> %H A339793 Wikipedia, <a href="https://en.wikipedia.org/wiki/Aliquot_sum">Aliquot sum</a>. %e A339793 a(3) = 3 as s(a(2)) = s(2) = 1, and 3 is the smallest multiple of 1 that has not previously occurred. %e A339793 a(5) = 6 as s(a(4)) = s(4) = 3, and as 3 has already occurred the next lowest multiple is used, being 6. %e A339793 a(12) = 5 as s(a(11)) = s(7) = 1, and 5 is the smallest multiple of 1 that has not previously occurred. %o A339793 (Python) %o A339793 from sympy import divisors %o A339793 def s(k): return sum(d for d in divisors(k)[:-1]) %o A339793 def aupto(n): %o A339793 alst, aset = [1, 2], {1, 2} %o A339793 for k in range(2, n): %o A339793 ak = sanm1 = s(alst[-1]) %o A339793 while ak in aset: ak += sanm1 %o A339793 alst.append(ak); aset.add(ak) %o A339793 return alst # use alst[n-1] for a(n) %o A339793 print(aupto(478)) # _Michael S. Branicky_, Dec 29 2020 %Y A339793 Cf. A001065, A027751, A000203, A032741, A032742, A007956. %K A339793 nonn %O A339793 1,2 %A A339793 _Scott R. Shannon_, Dec 17 2020