A070232 a(1) = 4; a(n) = smallest composite number greater than the sum of all previous terms.
4, 6, 12, 24, 48, 95, 190, 380, 760, 1520, 3040, 6080, 12160, 24320, 48640, 97280, 194560, 389120, 778240, 1556480, 3112960, 6225920, 12451840, 24903680, 49807360, 99614720, 199229440, 398458880, 796917760, 1593835520, 3187671040
Offset: 1
Keywords
Links
- Harvey P. Dale, Table of n, a(n) for n = 1..1000
Crossrefs
Cf. A070218.
Programs
-
Mathematica
a = {4}; Do[b = 1 + Plus @@ a; While[ PrimeQ[b], b++ ]; a = Append[a, b], {n, 2, 30}]; a nxt[{t_,a_}]:=Module[{k=t+1},While[!CompositeQ[k],k++];{t+k,k}]; NestList[nxt,{4,4},30][[;;,2]] (* Harvey P. Dale, Sep 14 2024 *)
Extensions
Edited by Robert G. Wilson v, May 06 2002
Comments