login
A030075
Squares which are palindromes in base 15.
11
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,3
LINKS
EXAMPLE
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.
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 *)
PROG
(PARI) isok(n) = my(d=digits(n, 15)); issquare(n) && (d == Vecrev(d)); \\ Michel Marcus, Oct 21 2016
KEYWORD
base,nonn,changed
STATUS
approved