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.

A249147 a(n) = 0 if A249148(n) = 1, otherwise the index of the least prime dividing A249148(n): a(n) = A055396(A249148(n)).

Original entry on oeis.org

0, 1, 0, 2, 0, 1, 2, 1, 1, 1, 4, 0, 3, 0, 1, 1, 5, 0, 4, 1, 1, 1, 2, 1, 1, 1, 1, 9, 0, 1, 1, 2, 1, 1, 1, 11, 0, 2, 6, 1, 1, 12, 0, 1, 1, 2, 1, 1, 14, 0, 5, 2, 2, 1, 15, 0, 1, 4, 4, 1, 1, 1, 3, 2, 1, 1, 17, 0, 6, 3, 1, 1, 1, 2, 3, 1, 1, 1, 20, 0, 1, 1, 2, 1, 4, 2, 10, 0, 2, 1, 1, 22, 0, 1, 23, 0, 7
Offset: 1

Views

Author

Antti Karttunen, Oct 24 2014

Keywords

Crossrefs

Programs

  • PARI
    A049084(n) = if(isprime(n), primepi(n), 0); \\ This function from Charles R Greathouse IV
    A249147_write_bfile(up_to_n) = { my(pfcounts, n, a_n, x_n, f, k); pfcounts = vector(up_to_n); x_n = 1; for(n = 0, up_to_n, if((1 == x_n), pfcounts[1]++; x_n = pfcounts[1]; a_n = 0, f=factor(x_n); for(i=1,#f~,k = A049084(f[i,1])+1; pfcounts[k] += f[i,2]); a_n = A049084(f[1,1]); x_n = pfcounts[a_n+1]); if(n>0,write("b249147.txt", n, " ", a_n))); };
    A249147_write_bfile(10000);
    
  • Scheme
    (define (A249147 n) (A055396 (A249148 n)))

Formula

a(n) = A055396(A249148(n)).