A097931 Numbers in base 10 that are palindromic in bases 6 and 7.
0, 1, 2, 3, 4, 5, 92, 135, 178, 185, 5854, 6148, 7703, 186621, 204856, 206620, 213970, 269957, 271721, 279071, 4252232, 160258808, 9689802280, 203509031168, 204191148800, 231773764784, 321015775216, 4102350269485, 12262956787888
Offset: 1
Examples
269957 base 10 is 5441445 base 6 and 269957 base 10 is 2203022 base 7.
Links
- Giovanni Resta, Table of n, a(n) for n = 1..50 (first 30 terms from Robert G. Wilson v)
- Cino Hilliard, util.gp PARI Functions not in the PARI Library. [broken link]
- Cino Hilliard, Pari Utilities (cached)
Programs
-
Mathematica
Do[ p6 = IntegerDigits[n, 6]; If[ FromDigits[ Reverse[ p6]] == FromDigits[p6], p7 = IntegerDigits[n, 7]; If[ FromDigits[ Reverse[p7]] == FromDigits[p7], Print[n]]], {n, 10^9}] (* Robert G. Wilson v, Sep 07 2004 *)
-
PARI
/* Requires reading the util.gp file in the link into the gp session. */ palbase(n,b1,b2) = { for(x=1,n, if(ispal(base(10,b1,x))& ispal(base(10,b2,x)),print1(x",")) ) }
Extensions
More terms from Robert G. Wilson v, Sep 07 2004
a(23)-a(29) from Donovan Johnson, Apr 23 2010
a(30) from Robert G. Wilson v, Jul 17 2015
Comments