OFFSET
0,3
COMMENTS
The permutation satisfies A000040(a(n)) = a(A000040(n)) for all positive n, and is self-inverse. It swaps 8 & 9, maps any prime p_i with index i to p_{a(i)}, and lets the multiplicativity take care of the rest.
This can be viewed also as a "signature-permutation" for a bijection of non-oriented rooted trees, mapped through Matula-Goebel numbers (cf. A061773). This bijection will swap the subtrees encoded by numbers 8 and 9, wherever they occur as the terminal branches of the tree:
.......................
.................o...o.
.................|...|.
.o.o.o...........o...o.
..\|/.............\./..
...x.....<--->.....x...
...8...............9...
Thus, any terminal configuration in the tree that consists of three or more single edges next to each other (in "parallel") will be transformed so that maximal 3k number of those single edges will be replaced by k subtrees Matula-Goebel-encoded by 9 (see above, or equally: replaced by 2k two-edges-long branches encoded by 3), and one or two left-over single edges, if present, will stay as they are. Vice versa, any terminal configuration in the tree that consists of more than one two-edges-long branches next to each other (in "parallel") will be transformed so that maximal even number (2k) of those double-edges will be replaced by 3k single edges, and an extra odd double-edge, if present, will stay as it is.
LINKS
FORMULA
Multiplicative with a(3^(2k)) = 2^3k = 8^k, a(3^(2k+1)) = 3*2^3k, a(2^(3k)) = 3^2k = 9^k, a(2^(3k+1)) = 2*9^k, a(2^(3k+2)) = 4*9^k, a(p_i) = p_{a(i)} for primes with index i, and a(u*v) = a(u) * a(v) for composites other than 8 or 9.
PROG
CROSSREFS
List below gives similarly constructed permutations, which all force a swap of two small numbers, with (the rest of) primes permuted with the sequence itself and the new positions of composite numbers defined by the multiplicative property:
KEYWORD
nonn,mult
AUTHOR
Antti Karttunen, Jan 11 2014
STATUS
approved