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.

A031368 Odd-indexed primes: a(n) = prime(2n-1).

Original entry on oeis.org

2, 5, 11, 17, 23, 31, 41, 47, 59, 67, 73, 83, 97, 103, 109, 127, 137, 149, 157, 167, 179, 191, 197, 211, 227, 233, 241, 257, 269, 277, 283, 307, 313, 331, 347, 353, 367, 379, 389, 401, 419, 431, 439, 449, 461, 467, 487, 499, 509, 523, 547, 563
Offset: 1

Views

Author

Keywords

Comments

Appeared as a puzzle in "Stickelers", a nationally distributed feature, by Terry Stickels, Sep 28 2006. - Franklin T. Adams-Watters, Sep 28 2006
Also every second prime starting with 2. - Cino Hilliard, Dec 02 2007
Central terms of the triangle in A005145. - Reinhard Zumkeller, Aug 05 2009

Crossrefs

Cf. A000040, A031215 (even-indexed primes), A005408.
First differences are A155067.

Programs

  • Haskell
    a031368 = a000040 . ((subtract 1) . (* 2))
    a031368_list = map a000040 [1, 3 ..]  -- Reinhard Zumkeller, Nov 25 2012
    
  • Magma
    [ NthPrime(2*n-1): n in [1..1000] ]; // Vincenzo Librandi, Apr 11 2011
    
  • Maple
    A031368 := n->ithprime(2*n-1): seq(A031368(n), n=1..100);
  • Mathematica
    Table[ Prime[ 2n -1], {n, 52}] (* Robert G. Wilson v, Dec 01 2013 *)
  • PARI
    a(n) = prime(2*n-1) \\ Jianing Song, Jun 03 2021

Formula

a(n) = A219603(n) / A000040(n). - Reinhard Zumkeller, Nov 25 2012