cp's OEIS Frontend

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.

A124981 Odd numbers that are not the sum of 2 squares.

This page as a plain text file.
%I A124981 #9 Mar 12 2020 07:08:04
%S A124981 3,7,11,15,19,21,23,27,31,33,35,39,43,47,51,55,57,59,63,67,69,71,75,
%T A124981 77,79,83,87,91,93,95,99,103,105,107,111,115,119,123,127,129,131,133,
%U A124981 135,139,141,143,147,151,155,159,161,163,165,167,171,175,177,179,183,187
%N A124981 Odd numbers that are not the sum of 2 squares.
%H A124981 Amiram Eldar, <a href="/A124981/b124981.txt">Table of n, a(n) for n = 1..10000</a>
%F A124981 Equals A022544 INTERSECT A005408. - _R. J. Mathar_, Nov 29 2006
%e A124981 13 is not in the list because it can be written as 3^2+2^2.
%t A124981 Select[2 * Range[0, 100] + 1, SquaresR[2, #] == 0 &] (* _Amiram Eldar_, Mar 12 2020 *)
%o A124981 (PARI) isA022544(n)={ local(cnt=0,y2) ; for(x=0,floor(sqrt(n)), y2=n-x^2 ; if( y2>=x^2 && issquare(y2), return(0) ; ) ; ) ; return(1) ; } isA124981(n)={ return( (n%2) && isA022544(n)) ; } { for(n=1,200, if( isA124981(n), print1(n,", ") ; ) ; ) ; } \\ _R. J. Mathar_, Nov 29 2006
%Y A124981 Cf. A005408, A022544.
%K A124981 nonn
%O A124981 1,1
%A A124981 _Artur Jasinski_, Nov 15 2006
%E A124981 Corrected and extended by _R. J. Mathar_, Nov 29 2006