login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A233418 a(n) is the smallest number k > 0 such that k^2+1, (k+1)^2+1,...,(k+n)^2+1 are composite numbers. 2

%I #9 Dec 10 2013 14:55:54

%S 1,3,8,7,32,31,30,29,28,27,44,43,42,41,96,95,188,187,186,185,364,363,

%T 362,361,360,359,358,357,356,355,354,353,352,351,502,501,500,499,498,

%U 497,3396,3395,3394,3393,3392,3391,3578,3577,3576,3575,3574,3573,3572

%N a(n) is the smallest number k > 0 such that k^2+1, (k+1)^2+1,...,(k+n)^2+1 are composite numbers.

%H Michel Lagneau, <a href="/A233418/b233418.txt">Table of n, a(n) for n = 0..325</a>

%e a(0) = 1 because 1^2+1 is prime.

%e a(1) = 3 because 3^2+1 is composite, but 4^2+1 is prime.

%e a(2) = 8 because 8^2+1, 9^2+1 are composites, but 10^2+1 is prime.

%e a(3) = 7 because 7^2+1, 8^2+1 and 9^2+1 are composites, but 10^2+1 is prime.

%p for n from 0 to 60 do: ii:=0:for k from 1 to 10^8 while(ii=0) do:i:=0:for m from 0 to n while(type((k+m)^2+1,prime)=false ) do :i:=i+1:od:if i=n then ii:=1: printf(`%d, `,k):else fi:od:od:

%t nn = 50; t = Table[0, {nn}]; cnt = 0; k = 0; While[cnt < nn, k++; i = 0; While[! PrimeQ[(k + i)^2 + 1], i++]; If[i < nn && t[[i + 1]] == 0, t[[i + 1]] = k; cnt++]]; t (* _T. D. Noe_, Dec 10 2013 *)

%Y Cf. A002496, A002522, A134406.

%K nonn

%O 0,2

%A _Michel Lagneau_, Dec 09 2013

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 23:40 EDT 2024. Contains 371798 sequences. (Running on oeis4.)