A262065
Numbers that are palindromes in base-60 representation.
Original entry on oeis.org
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 61, 122, 183, 244, 305, 366
Offset: 1
. n | a(n) | base 60 n | a(n) | base 60
. -----+------+----------- ------+-------+--------------
. 100 | 2440 | [40, 40] 1000 | 56415 | [15, 40, 15]
. 101 | 2501 | [41, 41] 1001 | 56475 | [15, 41, 15]
. 102 | 2562 | [42, 42] 1002 | 56535 | [15, 42, 15]
. 103 | 2623 | [43, 43] 1003 | 56595 | [15, 43, 15]
. 104 | 2684 | [44, 44] 1004 | 56655 | [15, 44, 15]
. 105 | 2745 | [45, 45] 1005 | 56715 | [15, 45, 15]
. 106 | 2806 | [46, 46] 1006 | 56775 | [15, 46, 15]
. 107 | 2867 | [47, 47] 1007 | 56835 | [15, 47, 15]
. 108 | 2928 | [48, 48] 1008 | 56895 | [15, 48, 15]
. 109 | 2989 | [49, 49] 1009 | 56955 | [15, 49, 15]
. 110 | 3050 | [50, 50] 1010 | 57015 | [15, 50, 15]
. 111 | 3111 | [51, 51] 1011 | 57075 | [15, 51, 15]
. 112 | 3172 | [52, 52] 1012 | 57135 | [15, 52, 15]
. 113 | 3233 | [53, 53] 1013 | 57195 | [15, 53, 15]
. 114 | 3294 | [54, 54] 1014 | 57255 | [15, 54, 15]
. 115 | 3355 | [55, 55] 1015 | 57315 | [15, 55, 15]
. 116 | 3416 | [56, 56] 1016 | 57375 | [15, 56, 15]
. 117 | 3477 | [57, 57] 1017 | 57435 | [15, 57, 15]
. 118 | 3538 | [58, 58] 1018 | 57495 | [15, 58, 15]
. 119 | 3599 | [59, 59] 1019 | 57555 | [15, 59, 15]
. 120 | 3601 | [1, 0, 1] 1020 | 57616 | [16, 0, 16]
. 121 | 3661 | [1, 1, 1] 1021 | 57676 | [16, 1, 16]
. 122 | 3721 | [1, 2, 1] 1022 | 57736 | [16, 2, 16]
. 123 | 3781 | [1, 3, 1] 1023 | 57796 | [16, 3, 16]
. 124 | 3841 | [1, 4, 1] 1024 | 57856 | [16, 4, 16]
. 125 | 3901 | [1, 5, 1] 1025 | 57916 | [16, 5, 16] .
Corresponding sequences for bases 2 through 12:
A006995,
A014190,
A014192,
A029952,
A029953,
A029954,
A029803,
A029955,
A002113,
A029956,
A029957.
-
import Data.List.Ordered (union)
a262065 n = a262065_list !! (n-1)
a262065_list = union us vs where
us = [val60 $ bs ++ reverse bs | bs <- bss]
vs = [0..59] ++ [val60 $ bs ++ cs ++ reverse bs |
bs <- tail bss, cs <- take 60 bss]
bss = iterate s [0] where
s [] = [1]; s (59:ds) = 0 : s ds; s (d:ds) = (d + 1) : ds
val60 = foldr (\b v -> 60 * v + b) 0
-
[n: n in [0..600] | Intseq(n, 60) eq Reverse(Intseq(n, 60))]; // Vincenzo Librandi, Aug 24 2016
-
f[n_, b_]:=Module[{i=IntegerDigits[n, b]}, i==Reverse[i]]; lst={}; Do[If[f[n, 60], AppendTo[lst, n]], {n, 400}]; lst (* Vincenzo Librandi, Aug 24 2016 *)
pal60Q[n_]:=Module[{idn60=IntegerDigits[n,60]},idn60==Reverse[idn60]]; Select[Range[0,400],pal60Q] (* Harvey P. Dale, Nov 04 2017 *)
-
isok(m) = my(d=digits(m, 60)); d == Vecrev(d); \\ Michel Marcus, Jan 22 2022
-
from sympy import integer_log
from gmpy2 import digits, mpz
def A262065(n):
if n == 1: return 0
y = 60*(x:=60**integer_log(n>>1,60)[0])
return int((c:=n-x)*x+mpz(digits(c,60)[-2::-1]or'0',60) if nChai Wah Wu, Jun 13-14 2024
A342725
Numbers that are palindromic in base i-1.
Original entry on oeis.org
0, 1, 13, 17, 189, 205, 257, 273, 3005, 3069, 3277, 3341, 4033, 4097, 4305, 4369, 48061, 48317, 49149, 49405, 52173, 52429, 53261, 53517, 64449, 64705, 65537, 65793, 68561, 68817, 69649, 69905, 768957, 769981, 773309, 774333, 785405, 786429, 789757, 790781, 834509
Offset: 1
Similar sequences:
A002113 (decimal),
A006995 (binary),
A014190 (base 3),
A014192 (base 4),
A029952 (base 5),
A029953 (base 6),
A029954 (base 7),
A029803 (base 8),
A029955 (base 9),
A046807 (factorial base),
A094202 (Zeckendorf),
A331191 (dual Zeckendorf),
A331891 (negabinary),
A333423 (primorial base).
-
v = {{0, 0, 0, 0}, {0, 0, 0, 1}, {1, 1, 0, 0}, {1, 1, 0, 1}}; q[n_] := PalindromeQ @ FromDigits[Flatten @ v[[1 + Reverse @ Most[Mod[NestWhileList[(# - Mod[#, 4])/-4 &, n, # != 0 &], 4]]]]]; Select[Range[0, 10^4], q]
A350993
Triangular numbers that are palindromes in base 9.
Original entry on oeis.org
0, 1, 3, 6, 10, 91, 136, 300, 528, 820, 4560, 7381, 11476, 20910, 42486, 66430, 552826, 581581, 597871, 1664400, 2001000, 3420420, 3444000, 5070520, 5380840, 48427561, 75995956, 132494781, 134553810, 137158203, 159213090, 290585778, 434520460, 435848050, 669615310
Offset: 1
10 is a term since 10 = A000217(4) is a triangular number and also a palindromic number in base 9: 10 = 11_9.
91 is a term since 91 = A000217(13) is a triangular number and also a palindromic number in base 9: 91 = 111_9.
- Charles W. Trigg, Mathematical Quickies, McGraw Hill Book Co., 1967, Q112, p. 127.
- Amiram Eldar, Table of n, a(n) for n = 1..123
- Charles W. Trigg, Infinite sequences of palindromic triangular numbers, The Fibonacci Quarterly, Vol. 12, No. 2 (1974), pp. 209-212.
- Charles W. Trigg, Problem 281, The College Mathematics Journal, Vol. 15, No. 4 (1984), p. 346; Palindromic Triangular Numbers in Base Nine, Solution to Problem 281, by Michael Vowe, ibid., Vol. 17, No. 2 (1986), pp. 188-189.
- Maciej Ulas, On certain diophantine equations related to triangular and tetrahedral numbers, arXiv:0811.2477 [math.NT], 2008.
- G. W. Wishard, Problem 3480, The American Mathematical Monthly, Vol. 38, No. 3 (1931), p. 170; Solution to Problem 3480, by Helen A. Merrill, ibid., Vol. 39, No. 3 (1932), p. 179.
A297268
Numbers whose base-9 digits have equal down-variation and up-variation; see Comments.
Original entry on oeis.org
1, 2, 3, 4, 5, 6, 7, 8, 10, 20, 30, 40, 50, 60, 70, 80, 82, 91, 100, 109, 118, 127, 136, 145, 154, 164, 173, 182, 191, 200, 209, 218, 227, 236, 246, 255, 264, 273, 282, 291, 300, 309, 318, 328, 337, 346, 355, 364, 373, 382, 391, 400, 410, 419, 428, 437, 446
Offset: 1
446 in base-9: 5,4,5, having DV = 1, UV = 1, so that 446 is in the sequence.
-
g[n_, b_] := Map[Total, GatherBy[Differences[IntegerDigits[n, b]], Sign]];
x[n_, b_] := Select[g[n, b], # < 0 &]; y[n_, b_] := Select[g[n, b], # > 0 &];
b = 9; z = 2000; p = Table[x[n, b], {n, 1, z}]; q = Table[y[n, b], {n, 1, z}];
w = Sign[Flatten[p /. {} -> {0}] + Flatten[q /. {} -> {0}]];
Take[Flatten[Position[w, -1]], 120] (* A297267 *)
Take[Flatten[Position[w, 0]], 120] (* A297268 *)
Take[Flatten[Position[w, 1]], 120] (* A297269 *)
A333423
Numbers that are palindromes in primorial base.
Original entry on oeis.org
0, 1, 3, 7, 9, 11, 31, 39, 47, 211, 217, 223, 229, 235, 243, 249, 255, 261, 267, 275, 281, 287, 293, 299, 2311, 2347, 2383, 2419, 2455, 2523, 2559, 2595, 2631, 2667, 2735, 2771, 2807, 2843, 2879, 30031, 30061, 30091, 30121, 30151, 30181, 30211, 30247, 30277, 30307
Offset: 1
3 is a term since its representation in primorial base is 11 (1 * 2# + 1) which is a palindrome.
7 is a term since its representation in primorial base is 101 (1 * 3# + 0 * 2# + 1 = 6 + 1) which is a palindrome.
-
max = 6; bases = Prime @ Range[max, 1, -1]; nmax = Times @@ bases - 1; Select[Range[0, nmax], PalindromeQ @ IntegerDigits[#, MixedRadix[bases]] &]
A043035
Base-9 palindromes that start with 8.
Original entry on oeis.org
8, 80, 656, 665, 674, 683, 692, 701, 710, 719, 728, 5840, 5930, 6020, 6110, 6200, 6290, 6380, 6470, 6560, 52496, 52577, 52658, 52739, 52820, 52901, 52982, 53063, 53144, 53234, 53315, 53396, 53477, 53558, 53639, 53720
Offset: 1
Base-b palindromes that start with 8, for b=9,10: this sequence,
A043043.
-
b9dQ[n_]:=Module[{idn=IntegerDigits[n,9]},idn==Reverse[idn]&&idn[[1]] == 8]; Select[Range[60000],b9dQ] (* Harvey P. Dale, Sep 03 2016 *)
A043030
Base-9 palindromes that start with 3.
Original entry on oeis.org
3, 30, 246, 255, 264, 273, 282, 291, 300, 309, 318, 2190, 2280, 2370, 2460, 2550, 2640, 2730, 2820, 2910, 19686, 19767, 19848, 19929, 20010, 20091, 20172, 20253, 20334, 20424, 20505, 20586, 20667, 20748, 20829, 20910
Offset: 1
-
okQ[n_] := Module[{idn = IntegerDigits[n, 9]}, First[idn] == 3 && FromDigits[IntegerDigits[n, 9]] == FromDigits[Reverse[idn]]]; Select[Range[20910], okQ] (* Robert P. P. McKone, Aug 22 2021, after Harvey P. Dale in A043038 *)
A046242
Cubes which are palindromes in base 9.
Original entry on oeis.org
0, 1, 8, 1000, 54872, 551368, 753571, 389017000, 282558696328, 293151929707, 205901592625000, 150095482587202888, 150714005985636211, 109419057761904073000, 79766448635933205559048, 79802927193348078816187
Offset: 1
-
Select[Range[0,44*10^6]^3,IntegerDigits[#,9]==Reverse[ IntegerDigits[ #,9]]&] (* Harvey P. Dale, Oct 09 2016 *)
A260184
Numbers n written in base 10 that are palindromic in exactly three bases b, 2 <= b <= 10 and not simultaneously bases 2, 4 and 8.
Original entry on oeis.org
9, 10, 21, 40, 55, 80, 85, 100, 130, 154, 164, 178, 191, 203, 235, 242, 255, 257, 273, 282, 292, 300, 328, 400, 455, 585, 656, 819, 910, 2709, 6643, 8200, 14762, 32152, 53235, 74647, 428585, 532900, 1181729, 1405397, 4210945, 5259525, 27711772, 719848917, 43253138565
Offset: 1
273 is in the sequence because 100010001_2 = 101010_3 = 10101_4 = 2043_5 = 1133_6 = 540_7 = 421_8 = 333_9 = 273_10 and three of the bases, namely 2, 4 & 9, yield palindromes.
-
(* see A214425 and set all terms as lst, then *)
gQ[n_] := Count[ palQ[n,#] & /@ {2, 4, 8}, True];
Select[ lst, gQ[#] != 3 &]
A043034
Base-9 palindromes that start with 7.
Original entry on oeis.org
7, 70, 574, 583, 592, 601, 610, 619, 628, 637, 646, 5110, 5200, 5290, 5380, 5470, 5560, 5650, 5740, 5830, 45934, 46015, 46096, 46177, 46258, 46339, 46420, 46501, 46582, 46672, 46753, 46834, 46915, 46996, 47077, 47158
Offset: 1
Base-b palindromes that start with 7, for b=8..10:
A043027, this sequence,
A043042.
Comments