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.

A163419 Primes of the form ((p+1)/2)^2+((p-1)/2), where p is prime.

Original entry on oeis.org

5, 11, 19, 41, 89, 109, 239, 271, 379, 461, 599, 929, 991, 2069, 2969, 3079, 4159, 4421, 4969, 5851, 9311, 10099, 13109, 13339, 14519, 16001, 20021, 23869, 25439, 28729, 30449, 32579, 34039, 38219, 39799, 48619, 50849, 53591, 57839, 59779, 60761
Offset: 1

Views

Author

Keywords

Comments

Subsequence of A002327. - Charles R Greathouse IV, Aug 11 2009

Examples

			((3+1)/2)^2+((3-1)/2) = 4+1 = 5;
((5+1)/2)^2+((5-1)/2) = 9+2 = 11;
((7+1)/2)^2+((7-1)/2) = 16+3 = 19.
		

Crossrefs

Programs

  • Magma
    [a: p in PrimesInInterval(3, 600) | IsPrime(a) where a is (p^2 + 4*p - 1) div 4]; // Vincenzo Librandi, Sep 17 2016
    
  • Mathematica
    f[n_]:=((p+1)/2)^2+((p-1)/2); lst={};Do[p=Prime[n];If[PrimeQ[f[p]],AppendTo[lst,f[p]]],{n,6!}];lst
    Select[((#+1)/2)^2+(#-1)/2&/@Prime[Range[500]],PrimeQ] (* Harvey P. Dale, Nov 25 2012 *)
  • PARI
    lista(nn) = forprime(p=3, nn, if(isprime(P=(p^2+4*p-1)/4), print1(P, ", "))); \\ Altug Alkan, Sep 17 2016