OFFSET
1,1
COMMENTS
These numbers could be called Super-Brazilian numbers. 11_11 = 12 is not a term because every number 11_(n-1) = n is not a Brazilian representation.
The super-Brazilian primes are of the form (R_p)_(R_p) where R_p is a Repunit of p 1's, with p prime. The first one is 111_111 = 12433, but 11111_11111 = 15242341197997105 is composite.
LINKS
Gérard Villemin, Nombres super-repdigits, Dictionnaire des Nombres.
EXAMPLE
22_22 = 2 * 22^1 + 2 * 22^0 = 44 + 2 = 46;
444_444 = 4 * 444^2 + 4 * 444^1 + 4 * 444^0 = 788544 + 1776 + 4 = 790324.
MATHEMATICA
Select[Range[10^3], Function[n, AnyTrue[Range[2, n - 2], Function[b, And[Length@ Union@ IntegerDigits[n, b] == 1, n == Total@ MapIndexed[#1 b^(First[#2] - 1) &, Reverse@ IntegerDigits[b]]]]]]] (* or, faster *)
Rest@ Flatten@ Table[Function[{m, d}, Total@ MapIndexed[#1 m^(First[#2] - 1) &, Reverse@ d]] @@ {FromDigits@ #, #} &@ ConstantArray[k, n], {n, 2, 4}, {k, 9}] (* Michael De Vlieger, Jun 01 2017 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Bernard Schott, May 31 2017
STATUS
approved