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.

A120807 Cubes k in A120806: k+d+1 is prime for all divisors d of k. All cubes greater than 1 are cubes of odd primes.

This page as a plain text file.
%I A120807 #12 Aug 05 2024 04:40:00
%S A120807 1,125,357911,28049850707778719,1093838138707598549,
%T A120807 2498288375480240699,2971816820123565959,11368298790243739889,
%U A120807 14106863174732461979,17104690428464397149,21904077634699214681,64352051556875937161,82512915197756439761,115892432166552995771,231193025116112162501
%N A120807 Cubes k in A120806: k+d+1 is prime for all divisors d of k. All cubes greater than 1 are cubes of odd primes.
%H A120807 Amiram Eldar, <a href="/A120807/b120807.txt">Table of n, a(n) for n = 1..2500</a>
%e A120807 a(3) = 357911 since k = 357911 = 71^3, divisors(k) = {1, 71, 71^2, 71^3} and k+d+1 = {357913, 357983, 362953, 715823} are all primes.
%p A120807 L:=[]: for w to 1 do for k from 1 while nops(L)<=50 do p:=ithprime(k); x:=p^3; if p mod 6 = 5 and andmap(isprime,[x+2,2*x+1]) then S:={p,p^2}; Q:=map(z-> x+z+1, S); if andmap(isprime,Q) then L:=[op(L),x]; print(nops(L),p,x); fi; fi; od od;
%t A120807 Select[Range[4008000]^3,AllTrue[#+Divisors[#]+1,PrimeQ]&] (* Requires Mathematica version 10 or later *) (* _Harvey P. Dale_, May 26 2019 *)
%o A120807 (PARI) lista(kmax) = {my(f, k3, is); forstep(k = 1, kmax, 2, f = factor(k); k3 = k^3; for(i = 1, #f~, f[i, 2] *= 3); is = 1; fordiv(f, d, if(!isprime(k3 + d + 1), is = 0; break)); if(is, print1(k3, ", ")));} \\ _Amiram Eldar_, Aug 05 2024
%Y A120807 Intersection of A000578 and A120806.
%Y A120807 Cf. A120808.
%K A120807 nonn
%O A120807 1,2
%A A120807 _Walter Kehowski_, Jul 06 2006
%E A120807 a(13)-a(15) from _Amiram Eldar_, Aug 05 2024