OFFSET
1,2
COMMENTS
Leading zeros are ignored.
This sequence is a self-inverse permutation of the natural numbers.
LINKS
EXAMPLE
The first terms, in decimal and in ternary, are:
n a(n) ter(n) ter(a(n))
-- ---- ------ ---------
1 1 1 1
2 2 2 2
3 3 10 10
4 4 11 11
5 7 12 21
6 6 20 20
7 5 21 12
8 8 22 22
9 9 100 100
10 12 101 110
11 21 102 210
12 10 110 101
13 13 111 111
14 22 112 211
15 19 120 201
PROG
(PARI) See Links section.
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, Jan 13 2020
STATUS
approved