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.
%I A283183 #23 May 03 2024 19:47:27 %S A283183 0,1,3,2,1,4,3,2,2,0,5,4,1,4,2,2,3,4,3,4,4,2,5,2,0,2,6,4,3,4,1,6,4,0, %T A283183 4,2,1,8,4,2,5,4,3,4,4,2,7,4,2,2,4,4,5,6,2,6,4,0,5,4,1,8,4,0,4,6,5,8, %U A283183 4,2,5,6,3,2,6,2,8,4,3,6,2,2,11,6,0,6,6 %N A283183 Number of partitions of n into a prime and a square of an arbitrary integer. %C A283183 a(n) is also the number of solutions to the equation n = p + m^2, where p is prime and m is an arbitrary integer. In comparison, the sequence A002471 counts representations with m being nonnegative. %C A283183 a(n) is odd if and only if n is prime. %H A283183 Anton Mosunov, <a href="/A283183/b283183.txt">Table of n, a(n) for n = 1..10000</a> %H A283183 H. Li, <a href="https://doi.org/10.1023/A:1024513613734">The exceptional set for the sum of a prime and a square</a>, Acta Math. Hung., 99:123 (2003), 123-141. %H A283183 R. J. Miech, <a href="https://doi.org/10.2307/1994761">On the equation n=p+x^2</a>, Trans. of the AMS, 130:3 (1968), 494-512. %H A283183 A. Nayebi, <a href="https://arxiv.org/abs/1004.0536">Upper bounds on the solutions to n=p+m^2</a>, Bull of the Iran. Math. Soc., 37:4 (2011), 95-108. %H A283183 W. Tianze, <a href="https://doi.org/10.1007/BF02274058">On the exceptional set for the equation n=p+k^2</a>, Acta Math. Sinica, 11:2 (1995), 156-167. %e A283183 a(11) = 5 because 11 = 11 + 0^2 = 7 + (-2)^2 = 7 + 2^2 = 2 + (-3)^2 = 2 + 3^2. %t A283183 a[n_] := Boole@ PrimeQ[n] + 2 Length@ Select[n - Range[Sqrt@ n]^2, PrimeQ]; Array[a, 87] (* _Giovanni Resta_, Apr 09 2017 *) %o A283183 (PARI) local(i,j,k,total); for (i=1, 1000, j=1; k=1; total=isprime(i); while (j <= i, total += 2*isprime(i-j); j += (2*k+1); k++); print1(total, ", ")) \\ _Anton Mosunov_, Apr 09 2017 %Y A283183 Cf. A002471, A020495. %K A283183 nonn,easy %O A283183 1,3 %A A283183 _Anton Mosunov_, Mar 02 2017