cp's OEIS Frontend

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.

A143293 Partial sums of A002110, the primorial numbers.

Original entry on oeis.org

1, 3, 9, 39, 249, 2559, 32589, 543099, 10242789, 233335659, 6703028889, 207263519019, 7628001653829, 311878265181039, 13394639596851069, 628284422185342479, 33217442899375387209, 1955977793053588026279, 119244359152460559009549, 7977565910232727614888639
Offset: 0

Views

Author

Gary W. Adamson, Aug 05 2008

Keywords

Comments

After 3, this is never prime because all values thereafter are multiples of 3. Starting from a(6) all are also multiples of 17. - Jonathan Vos Post, Feb 10 2010
Starting from a(162) all are also multiples of 967. - Alex Ratushnyak, May 14 2013
Repunits in primorial base, A049345. - Antti Karttunen, Aug 21 2016

Examples

			a(3) = 39 = (1 + 2 + 6 + 30), where A002110 = (1, 2, 6, 30, 210, 2310,...).
		

Crossrefs

Programs

  • Maple
    b:= proc(n) option remember; `if`(n=0, [1$2], (h->
          (p-> [p, p+h[2]])(ithprime(n)*h[1]))(b(n-1)))
        end:
    a:= n-> b(n)[2]:
    seq(a(n), n=0..19);  # Alois P. Heinz, Feb 23 2022
  • Mathematica
    Table[s = 1; Do[s = 1 + s*Prime[i], {i, n, 1, -1}]; s, {n, 0, 20}] (* T. D. Noe, May 03 2013 *)
    Accumulate[FoldList[Times,1,Prime[Range[20]]]] (* Harvey P. Dale, Feb 05 2015 *)
  • PARI
    a(n)=if(n==0,return(1)); my(P=1,s=1); forprime(p=2,prime(n), s+=P*=p); s \\ Charles R Greathouse IV, Feb 05 2014
    
  • Python
    from itertools import chain, accumulate, count, islice
    from operator import mul
    from sympy import prime
    def A143293_gen(): # generator of terms
        return accumulate(accumulate(chain((1,),(prime(n) for n in count(1))), mul))
    A143293_list = list(islice(A143293_gen(),20)) # Chai Wah Wu, Feb 23 2022

Formula

a(n) = Sum_{k=0..n} prime(k)#, where prime(n)# = A002110(n).
a(n) = A276085(A002110(1+n)). - Antti Karttunen, Aug 21 2016

Extensions

a(11)-a(19) from Jonathan Vos Post, Feb 10 2010