OFFSET
0,2
LINKS
FORMULA
EXAMPLE
n A049345 with one zero converted back
appended to the right to decimal = a(n)
---------------------------------------------------------
0 0 00 0
1 1 10 2
2 10 100 6
3 11 110 8
4 20 200 12
5 21 210 14
6 100 1000 30
7 101 1010 32
8 110 1100 36
9 111 1110 38
10 120 1200 42
11 121 1210 44
12 200 2000 60
13 201 2010 62
14 210 2100 66
15 211 2110 68
16 220 2200 72
MATHEMATICA
nn = 75; b = MixedRadix[Reverse@ Prime@ NestWhileList[# + 1 &, 1, Times @@ Prime@ Range[#] <= nn &]]; Table[FromDigits[#, b] &@ Append[IntegerDigits[n, b], 0], {n, 0, nn}] (* Version 10.2, or *)
f[n_] := Block[{a = {{0, n}}}, Do[AppendTo[a, {First@ #, Last@ #} &@ QuotientRemainder[a[[-1, -1]], Times @@ Prime@ Range[# - i]]], {i, 0, #}] &@ NestWhile[# + 1 &, 0, Times @@ Prime@ Range[# + 1] <= n &]; Rest[a][[All, 1]]]; Table[Total[Times @@@ Transpose@ {Map[Times @@ # &, Prime@ Range@ Range[0, Length@ # - 1]], Reverse@ #}] &@ Append[f@ n, 0], {n, 0, 75}] (* Michael De Vlieger, Aug 26 2016 *)
PROG
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Antti Karttunen, Aug 24 2016
STATUS
approved