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.

A045753 Numbers n such that 4n-1 and 4n+1 are both primes.

This page as a plain text file.
%I A045753 #23 Sep 08 2022 08:44:56
%S A045753 1,3,15,18,27,45,48,57,60,78,87,105,108,150,165,207,255,258,273,288,
%T A045753 330,357,363,372,402,405,417,447,468,483,507,522,528,567,585,648,672,
%U A045753 678,750,780,792,813,825,840,843,867,882,885,918,942,963,1005,1023
%N A045753 Numbers n such that 4n-1 and 4n+1 are both primes.
%H A045753 Zak Seidov, <a href="/A045753/b045753.txt">Table of n, a(n) for n = 1..10000</a>
%e A045753 3 belongs to the sequence because 4*3+1 and 4*3-1 are both primes.
%t A045753 Select[Range[1023], And @@ PrimeQ[{-1, 1} + 4# ] &] (* _Ray Chandler_, Dec 06 2006 *)
%o A045753 (Magma) [n: n in [1..2000] | IsPrime(4*n+1) and IsPrime(4*n-1)] // _Vincenzo Librandi_, Nov 18 2010
%o A045753 (PARI) list(lim)=my(v=List(),p=2); forprime(q=3,4*lim+1, if(q-p==2 && p%4==3, listput(v,q\4)); p=q); Vec(v) \\ _Charles R Greathouse IV_, Dec 03 2016
%Y A045753 Cf. A040040, A002822, A124065, A124518-A124522, A063983.
%K A045753 nonn,easy
%O A045753 1,2
%A A045753 _Felice Russo_
%E A045753 More terms from _Erich Friedman_