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.

A210481 Given n-th prime p, a(n) = number of primes of the form p * q - 2 where q is any prime < p.

Original entry on oeis.org

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

Views

Author

Jayanta Basu, Apr 18 2013

Keywords

Comments

Very similar to A103960. - T. D. Noe, Apr 18 2013
a(A137291(n)) = A103960(A137291(n)) - 1. - Reinhard Zumkeller, Jul 30 2015

Crossrefs

Programs

  • Haskell
    a210481 n = sum [a010051' $ p * q - 2 |
                     let p = a000040 n, q <- takeWhile (< p) a000040_list]
    -- Reinhard Zumkeller, Jul 30 2015
  • Mathematica
    Table[p = Prime[n]; c = 0; Do[If[PrimeQ[p*Prime[i] - 2], c = c + 1], {i, n - 1}]; c, {n, 82}]
    Table[With[{pr=Prime[Range[n]]},Count[Most[pr]Last[pr]-2,?PrimeQ]],{n,90}] (* _Harvey P. Dale, Jul 19 2020 *)