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.

A030075 Squares which are palindromes in base 15.

Original entry on oeis.org

0, 1, 4, 9, 16, 64, 144, 256, 361, 1024, 1521, 4096, 5776, 16384, 20736, 51076, 58081, 65536, 73441, 96721, 204304, 218089, 228484, 232324, 331776, 511225, 817216, 929296, 1048576, 3055504, 3268864, 3489424, 5308416, 7033104
Offset: 1

Views

Author

Keywords

Examples

			8^2 = 64, which in base 15 is 44, and that's palindromic, so 64 is in the sequence.
9^2 = 81, which in base 15 is 56. Since that's not palindromic, 81 is not in the sequence.
		

Crossrefs

Programs

  • Maple
    N:= 10^10: # to get all entries <= N
    count:= 0:
    for x from 0 to floor(sqrt(N)) do
        y:= x^2;
        L:= convert(y,base,15);
      if ListTools[Reverse](L) = L then
         count:= count+1;
         A[count]:= y;
       fi
    od:
    seq(A[i],i=1..count); # Robert Israel, Jul 24 2014
  • Mathematica
    palQ[n_, b_:10] := Module[{idn = IntegerDigits[n, b]}, idn == Reverse[idn]]; Select[Range[0, 2700]^2, palQ[#, 15] &]  (* Harvey P. Dale, Apr 23 2011 *)
  • PARI
    isok(n) = my(d=digits(n,15)); issquare(n) && (d == Vecrev(d)); \\ Michel Marcus, Oct 21 2016