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.

A124971 Numbers n which can be expressed as the ordered sum of 3 squares in 2 or more different ways and such that n+1 has the same property.

Original entry on oeis.org

17, 25, 26, 33, 49, 50, 53, 61, 65, 68, 72, 73, 74, 81, 82, 85, 89, 97, 98, 99, 100, 101, 104, 105, 106, 107, 108, 109, 113, 116, 117, 121, 122, 125, 129, 130, 131, 136, 137, 138, 144, 145, 146, 149, 152, 153, 154, 157, 161, 164, 165, 169, 170, 173, 177, 178
Offset: 1

Views

Author

Artur Jasinski, Nov 14 2006

Keywords

Examples

			a(1)=17 because 17=3^2+2^2+2^2 = 4^2+1^2+0^2 and a(1)+1= 18=3^2+3^2+0^2 = 4^2+1^2+1^2
		

Crossrefs

Programs

  • Mathematica
    Select[Range[200], Length@PowersRepresentations[#, 3, 2] > 1 && Length@PowersRepresentations[# + 1, 3, 2] > 1 &] (* Ray Chandler, Oct 31 2019 *)
  • PARI
    isCnt3sqr(n)={ local(cnt=0,z2) ; for(x=0,floor(sqrt(n)), for(y=x,floor(sqrt(n-x^2)), z2=n-x^2-y^2 ; if( z2>=y^2 && issquare(z2), cnt++ ; ) ; if(cnt >=2, return(1) ) ; ) ; ) ; return(0) ; } isA124971(n)= { return( isCnt3sqr(n) && isCnt3sqr(n+1)) ; } { for(n=1,200, if( isA124971(n), print1(n,", ") ; ) ; ) ; } \\ R. J. Mathar, Nov 29 2006

Formula

A000164(n)>=2 and A000164(n+1)>=2. - R. J. Mathar, Nov 29 2006

Extensions

Corrected and extended by Ray Chandler, Nov 30 2006
Corrected and extended by R. J. Mathar, Nov 29 2006