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.

A002504 Numbers x such that 1 + 3*x*(x-1) is a ("cuban") prime (cf. A002407).

This page as a plain text file.
%I A002504 M0522 N0188 #63 Feb 22 2024 13:34:13
%S A002504 2,3,4,5,7,10,11,12,14,15,18,24,25,26,28,29,31,33,35,38,39,42,43,46,
%T A002504 49,50,53,56,59,63,64,67,68,75,81,82,87,89,91,92,94,96,106,109,120,
%U A002504 124,126,129,130,137,141,143,148,154,157,158,159,165,166,171,172
%N A002504 Numbers x such that 1 + 3*x*(x-1) is a ("cuban") prime (cf. A002407).
%C A002504 Equivalently, positive integers x such that x^3 - (x-1)^3 is prime. - _Rémi Guillaume_, Oct 24 2023
%D A002504 A. J. C. Cunningham, On quasi-Mersennian numbers, Mess. Math., 41 (1912), 119-146.
%D A002504 N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
%D A002504 N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
%H A002504 T. D. Noe, <a href="/A002504/b002504.txt">Table of n, a(n) for n = 1..1000</a>
%F A002504 From _Rémi Guillaume_, Dec 07 2023: (Start)
%F A002504 a(n) = ceiling(sqrt(A002407(n)/3)).
%F A002504 a(n) = A111251(n) + 1.
%F A002504 a(n) = (A121259(n) + 1)/2. (End)
%e A002504 From _Rémi Guillaume_, Dec 07 2023: (Start)
%e A002504 1 + 3*7*6 = 127 = A002407(5) is the 5th prime of this form, so a(5) = 7.
%e A002504 1 + 3*10*9 = 271 = A002407(6) is the 6th prime of this form, so a(6) = 10.
%e A002504 (End)
%t A002504 Select[Range[500], PrimeQ[1 + 3 # (# - 1)] &] (* _T. D. Noe_, Jan 30 2013 *)
%o A002504 (PARI) for(k=1,999,isprime(3*k*(k-1)+1)&print1(k",")) \\ _M. F. Hasler_, Nov 28 2007
%Y A002504 Cf. A002407 (resulting primes), A111251, A121259.
%K A002504 nonn
%O A002504 1,1
%A A002504 _N. J. A. Sloane_
%E A002504 Edited, updated (1 is no longer regarded as a prime) and extended by _M. F. Hasler_, Nov 28 2007