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.

A257772 Numbers n>=0 such that (n+1)^3 - n^3 = 3*n^2+3*n+1 is not prime.

This page as a plain text file.
%I A257772 #28 Sep 08 2022 08:46:12
%S A257772 0,5,7,8,12,15,16,18,19,20,21,22,26,29,31,33,35,36,39,40,43,44,46,47,
%T A257772 50,51,53,54,56,57,59,60,61,64,65,68,69,70,71,72,73,75,76,77,78,79,82,
%U A257772 83,84,85,87,89,92,94,96,97,98,99,100,101,102,103,104,106
%N A257772 Numbers n>=0 such that (n+1)^3 - n^3 = 3*n^2+3*n+1 is not prime.
%C A257772 Complement of A111251.
%C A257772 Includes all members of A047383 except 1. - _Robert Israel_, May 12 2015
%H A257772 Charles R Greathouse IV, <a href="/A257772/b257772.txt">Table of n, a(n) for n = 1..10000</a>
%F A257772 a(n) ~ n. - _Charles R Greathouse IV_, May 22 2015
%e A257772 5 is a term since (5+1)^3 - 5^3 = 91 = 13*7 is not prime.
%p A257772 remove(t -> isprime((t+1)^3-t^3), [$0..300]); # _Robert Israel_, May 12 2015
%t A257772 Select[Range[0, 200], ! PrimeQ[(#+1)^3 - #^3] &] (* _Giovanni Resta_, May 08 2015 *)
%o A257772 (UBASIC)
%o A257772 10 print 0
%o A257772 20 for n=1 to 200
%o A257772 30   s = (n+1)^3 - n^3
%o A257772 40   if prmdiv(s)<>s then print n
%o A257772 50 next n
%o A257772 (Magma) [n: n in [0..120] | not IsPrime(3*n^2+3*n+1)]; // _Vincenzo Librandi_, May 13 2015
%o A257772 (PARI) for(n=0,100,if(!isprime(3*n^2+3*n+1),print1(n,", "))) \\ _Derek Orr_, May 19 2015
%Y A257772 Cf. A003215, A047383, A111251.
%K A257772 nonn,easy
%O A257772 1,2
%A A257772 _Miguel Angel Velilla Mula_, May 08 2015