login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A305877
Numbers in base 3 reversed.
2
0, 1, 2, 1, 11, 21, 2, 12, 22, 1, 101, 201, 11, 111, 211, 21, 121, 221, 2, 102, 202, 12, 112, 212, 22, 122, 222, 1, 1001, 2001, 101, 1101, 2101, 201, 1201, 2201, 11, 1011, 2011, 111, 1111, 2111, 211, 1211, 2211, 21, 1021, 2021, 121, 1121, 2121, 221, 1221, 2221, 2
OFFSET
0,3
LINKS
FORMULA
a(n) = A004086(A007089(n)). - Felix Fröhlich, Jun 14 2018
EXAMPLE
11 is 102 in base 3, and reversing it gives 201 = a(11).
MAPLE
a:= n-> parse(cat(convert(n, base, 3)[])):
seq(a(n), n=0..75); # Alois P. Heinz, Jun 17 2018
MATHEMATICA
Table[FromDigits@ Reverse@ IntegerDigits[n, 3], {n, 0, 54}] (* Giovanni Resta, Jun 13 2018 *)
PROG
(PARI) a(n) = fromdigits(Vecrev(digits(n, 3)), 10); \\ Michel Marcus, Jun 13 2018
CROSSREFS
Cf. A004086 (in base 10), A007089, A030102 (when converted in base 10).
Sequence in context: A101851 A300455 A270264 * A111724 A184299 A080371
KEYWORD
nonn,base,easy
AUTHOR
David F. Marrs, Jun 13 2018
STATUS
approved