# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/ Search: id:a053000 Showing 1-1 of 1 %I A053000 #55 Sep 21 2024 08:43:24 %S A053000 2,1,1,2,1,4,1,4,3,2,1,6,5,4,1,2,1,4,7,6,1,2,3,12,1,6,1,4,3,12,7,6,7, %T A053000 2,7,4,1,4,3,2,1,12,13,12,13,2,13,4,5,10,3,8,3,10,1,12,1,2,7,10,7,6,3, %U A053000 20,3,4,1,4,13,22,3,10,5,4,1,14,3,10,5,6,21,2,9,10,1,4,15,4,9,6,1,6,3,14 %N A053000 a(n) = (smallest prime > n^2) - n^2. %C A053000 Suggested by Legendre's conjecture (still open) that there is always a prime between n^2 and (n+1)^2. %C A053000 Record values are listed in A070317, their indices in A070316. - _M. F. Hasler_, Mar 23 2013 %C A053000 Conjecture: a(n) <= 1+phi(n) = 1+A000010(n), for n>0. This improves on Oppermann's conjecture, which says a(n) < n. - _Jianglin Luo_, Sep 22 2023 %D A053000 J. R. Goldman, The Queen of Mathematics, 1998, p. 82. %D A053000 R. K. Guy, Unsolved Problems in Number Theory, Section A1. %H A053000 T. D. Noe, Table of n, a(n) for n = 0..10000 %F A053000 a(n) = A013632(n^2). - _Robert Israel_, Jul 06 2015 %p A053000 A053000 := n->nextprime(n^2)-n^2; %t A053000 nxt[n_]:=Module[{n2=n^2},NextPrime[n2]-n2] %t A053000 nxt/@Range[0,100] (* _Harvey P. Dale_, Dec 20 2010 *) %o A053000 (PARI) A053000(n)=nextprime(n^2)-n^2 \\ _M. F. Hasler_, Mar 23 2013 %o A053000 (Magma) [NextPrime(n^2) - n^2: n in [0..100]]; // _Vincenzo Librandi_, Jul 06 2015 %o A053000 (Python) %o A053000 from sympy import nextprime %o A053000 def a(n): nn = n*n; return nextprime(nn) - nn %o A053000 print([a(n) for n in range(94)]) # _Michael S. Branicky_, Feb 17 2022 %Y A053000 Cf. A007491, A013632, A053001, A014085, A070316, A085099, A058055, A069003. %K A053000 nonn,easy,nice %O A053000 0,1 %A A053000 _N. J. A. Sloane_, Feb 21 2000 %E A053000 More terms from _James A. Sellers_, Feb 22 2000 # Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE