A162592 Hypotenuse numbers A009003 which cannot be represented as sum of 2 distinct nonzero squares.
15, 30, 35, 39, 51, 55, 60, 70, 75, 78, 87, 91, 95, 102, 105, 110, 111, 115, 119, 120, 123, 135, 140, 143, 150, 155, 156, 159, 165, 174, 175, 182, 183, 187, 190, 195, 203, 204, 210, 215, 219, 220, 222, 230, 235, 238, 240, 246, 247, 255, 259, 267, 270, 273, 275
Offset: 1
Keywords
Examples
13 is hypotenuse number A009003(3) but can be represented as A004431(3), so 13 is not in this sequence.
Links
- Eric Weisstein's World of Mathematics, Square Number
- Proof Wiki, Fermat's Christmas Theorem
- Wikipedia, Fermat's Theorem on sums of two squares
- Wikipedia (fr), Théorème des deux carrés de Fermat (in French).
- Index entries for sequences related to sums of squares
Programs
-
Mathematica
f[n_]:=Module[{k=1},While[(n-k^2)^(1/2)!=IntegerPart[(n-k^2)^(1/2)],k++; If[2*k^2>=n,k=0;Break[]]];k]; lst1={};Do[If[f[n^2]>0,AppendTo[lst1, n]],{n,3,5!}];lst1 (*A009003 Hypotenuse numbers (squares are sums of 2 distinct nonzero squares).*) lst2={};Do[If[f[n]>0,AppendTo[lst2, n]],{n,3,5!}];lst2 (*A004431 Numbers that are the sum of 2 distinct nonzero squares.*) Complement[lst1,lst2]
Extensions
Formulas added, entries checked by R. J. Mathar, Aug 14 2009
Comments