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.

A182091 Numbers n such that (n-1)*n^2/2-1 is prime.

Original entry on oeis.org

4, 6, 8, 10, 13, 17, 18, 21, 22, 25, 30, 34, 36, 38, 41, 42, 45, 46, 56, 57, 58, 62, 64, 69, 70, 72, 74, 86, 88, 101, 105, 113, 114, 116, 120, 122, 126, 132, 133, 141, 157, 158, 174, 176, 181, 182, 186, 192, 198, 200, 205, 216, 217, 221, 224, 240, 253, 254
Offset: 1

Views

Author

Gerasimov Sergey, Apr 11 2012

Keywords

Examples

			a(1)=4 because (4-1)*4^2/2-1=23 is prime, a(2)=6 because (6-1)*6^2/2-1=89 is prime.
		

Crossrefs

Cf. A006002.

Programs

  • Magma
    [n: n in [1..300] |IsPrime((n-1)*n^2 div 2-1)]; // Vincenzo Librandi, Aug 21 2017
  • Mathematica
    Select[Range[300], PrimeQ[(# - 1)*#^2/2 - 1] &] (* T. D. Noe, Apr 11 2012 *)
  • PARI
    is(n)=isprime((n-1)*n^2/2-1) \\ Charles R Greathouse IV, Jun 13 2017