login
Values of n such that there are exactly 8 solutions to x^2 - y^2 = n with x > y >= 0.
7

%I #18 Jun 18 2020 23:25:09

%S 480,576,672,840,864,945,1056,1080,1120,1155,1248,1296,1320,1365,1485,

%T 1512,1536,1560,1600,1632,1755,1760,1785,1824,1848,1995,2025,2040,

%U 2079,2080,2145,2184,2208,2280,2295,2376,2415,2457,2464,2560,2565,2625,2720,2760

%N Values of n such that there are exactly 8 solutions to x^2 - y^2 = n with x > y >= 0.

%H David A. Corneth, <a href="/A257415/b257415.txt">Table of n, a(n) for n = 1..10000</a> (first 1600 terms from Colin Barker)

%e 480 is in the sequence because there are 8 solutions to x^2 - y^2 = 480, namely (x,y) = (22,2), (23,7), (26,14), (29,19), (34,26), (43,37), (62,58), (121,119).

%t nn = 3000;

%t t = Table[0, {nn}];

%t Do[n = x^2 - y^2; If[n <= nn, t[[n]]++], {x, nn}, {y, 0, x - 1}];

%t Position[t, 8] // Flatten (* _Jean-François Alcover_, Jun 18 2020, after _T. D. Noe_ in A034178 *)

%o (PARI) is_A257415(n)={A034178(n)==8} \\ _M. F. Hasler_, Apr 22 2015

%Y Cf. A257408, A257409, A257410, A257411, A257412, A257413, A257414, A257416, A257417.

%Y Cf. A034178.

%K nonn

%O 1,1

%A _Colin Barker_, Apr 22 2015