%I #20 Sep 08 2022 08:45:06
%S -1,1,4,9,14,23,32,45,58,71,90,107,128,153,178,203,230,263,294,329,
%T 368,405,446,487,528,575,626,677,732,787,834,893,952,1017,1076,1145,
%U 1212,1281,1354,1427,1502,1583,1658,1743,1828,1917,1998,2081,2174,2271,2368
%N a(n) = n^2 - prime(n).
%C a(n) is never a perfect square for n>=5. [Proof: assume on the contrary n^2 - prime(n) = k^2, equivalent to (n+k)*(n-k) = prime(n). Since prime(n) cannot be the product of two nontrivial factors, this equation can only hold for k=n-1, i.e., prime(n)=2n-1. This contradicts the assumption and completes the proof.] - _Alexander R. Povolotsky_, Oct 01 2008
%H G. C. Greubel, <a href="/A073497/b073497.txt">Table of n, a(n) for n = 1..1000</a>
%t Table[n^2 - Prime[n], {n, 1, 55}]
%o (PARI) for(n=1,51,print1(n*n-prime(n),","))
%o (Magma) [n^2 - NthPrime(n): n in [1..100] ]; // _Vincenzo Librandi_, Apr 12 2011
%K sign,easy
%O 1,3
%A _Werner D. Sand_, Aug 27 2002
%E More terms from _Klaus Brockhaus_ and _Robert G. Wilson v_, Aug 28 2002
|