(N.B. I am not a mathematician and often make stupid mistakes in my recreational maths. Caveat lector.)
101 isn’t a number, it’s a label for a number. In fact, it’s a label for infinitely many numbers. In base 2, 1012 = 5; in base 3, 1013 = 10; 1014 = 17; 1015 = 26; and so on, for ever. In some bases, like 2 and 4, the number labelled 101 is prime. In other bases, it isn’t. But it is always a palindrome: that is, it’s the same read forward and back. But 101, the number itself, is a palindrome in only two bases: base 10 and base 100.1 Note that 100 = 101-1: with the exception of 2, all integers, or whole numbers, are palindromic in at least one base, the base that is one less than the integer itself. So 3 = 112; 4 = 113; 5 = 114; 101 = 11100; and so on.
Less trivial is the question of which integers set progressive records for palindromicity, or for the number of palindromes they create in bases less than the integers themselves. You might guess that the bigger the integer, the more palindromes it will create, but it isn’t as simple as that. Here is 10 represented in bases 2 through 9:
10102 | 1013* | 224* | 205 | 146 | 137 | 128 | 119*
10 is a palindrome in bases 3, 4, and 9. Now here is 30 represented in bases 2 through 29 (note that a number between square brackets represents a single digit in that base):2
111102 | 10103 | 1324 | 1105 | 506 | 427 | 368 | 339* | 30 | 2811 | 2612 | 2413 | 2214* | 2015 | 1[14]16 | 1[13]17 | 1[12]18 | 1[11]19 | 1[10]20 | 1921 | 1822 | 1723 | 1624 | 1525 | 1426 | 1327 | 1228
| 1129*
30, despite being three times bigger than 10, creates only three palindromes too: in bases 9, 14, and 29. Here is a graph showing the number of palindromes for each number from 3 to 100 (prime numbers are in red):
The number of palindromes a number has is related to the number of factors, or divisors, it has. A prime number has only one factor, itself (and 1), so primes tend to be less palindromic than composite numbers. Even large primes can have only one palindrome, in the base b=n-1 (55,440 has 119 factors and 61 palindromes; 65,381 has one factor and one palindrome, 1165380). Here is a graph showing the number of factors for each number from 3 to 100:
And here is an animated gif combining the two previous images:
Here is a graph indicating where palindromes appear when n, along the x-axis, is represented in the bases b=2 to n-1, along the y-axis:
The red line are the palindromes in base b=n-1, which is “11” for every n>2. The lines below it arise because every sufficiently large n with divisor d can be represented in the form d·n1 + d. For example, 8 = 2·3 + 2, so 8 in base 3 = 223; 18 = 3·5 + 3, so 18 = 335; 32 = 4.7 + 4, so 32 = 447; 391 = 17·22 + 17, so 391 = [17][17]22.
And here, finally, is a table showing integers that set progressive records for palindromicity (p = number of palindromes, f = total number of factors, prime and non-prime):
n | Prime Factors | p | f | n | Prime Factors | p | f | |
3 | 3 | 1 | 1 | 2,520 | 23·32·5·7 | 25 | 47 | |
5 | 5 | 2 | 1 | 3,600 | 24·32·52 | 26 | 44 | |
10 | 2·5 | 3 | 3 | 5,040 | 24·32·5·7 | 30 | 59 | |
21 | 3·7 | 4 | 3 | 7,560 | 23·33·5·7 | 32 | 63 | |
36 | 22·32 | 5 | 8 | 9,240 | 23·3·5·7·11 | 35 | 63 | |
60 | 22·3·5 | 6 | 11 | 10,080 | 25·32·5·7 | 36 | 71 | |
80 | 24·5 | 7 | 9 | 12,600 | 23·32·52·7 | 38 | 71 | |
120 | 23·3·5 | 8 | 15 | 15,120 | 24·33·5·7 | 40 | 79 | |
180 | 22·32·5 | 9 | 17 | 18,480 | 24·3·5·7·11 | 43 | 79 | |
252 | 22·32·7 | 11 | 17 | 25,200 | 24·32·52·7 | 47 | 89 | |
300 | 22·3·52 | 13 | 17 | 27,720 | 23·32·5·7·11 | 49 | 95 | |
720 | 24·32·5 | 16 | 29 | 36,960 | 25·3·5·7·11 | 50 | 95 | |
1,080 | 23·33·5 | 17 | 31 | 41,580 | 22·33·5·7·11 | 51 | 95 | |
1,440 | 25·32·5 | 18 | 35 | 45,360 | 24·34·5·7 | 52 | 99 | |
1,680 | 24·3·5·7 | 20 | 39 | 50,400 | 25·32·52·7 | 54 | 107 | |
2,160 | 24·33·5 | 21 | 39 | 55,440 | 24·32·5·7·11 | 61 | 119 |
Notes
1. That is, it’s only a palindrome in two bases less than 101. In higher bases, “101” is a single digit, so is trivially a palindrome (as the numbers 1 through 9 are in base 10).
2. In base b, there are b digits, including 0. So base 2 has two digits, 0 and 1; base 10 has ten digits, 0-9; base 16 has sixteen digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F.