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.

A122258 Number of Pierpont primes <= n.

Original entry on oeis.org

0, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10
Offset: 1

Views

Author

Reinhard Zumkeller, Aug 29 2006

Keywords

Crossrefs

Partial sums of A122257.

Programs

  • Mathematica
    smooth3Q[n_] := Times @@ ({2, 3}^IntegerExponent[n, {2, 3}]) == n; s[n_] := Boole[PrimeQ[n] && smooth3Q[n-1]]; Accumulate[Table[s[n], {n, 1, 100}]] (* Amiram Eldar, May 14 2025 *)
  • PARI
    is3smooth(n) = my(m = n >> valuation(n, 2)); m == 3^valuation(m, 3);
    f(n) = isprime(n) && is3smooth(n-1);
    list(lim) = {my(s = 0); for(n = 1, lim, s += f(n); print1(s, ", "));} \\ Amiram Eldar, May 14 2025

Formula

a(n) <= A000720(n).
a(n) <= A071521(n).