|
|
A266645
|
|
Permutation of natural numbers: a(n) = A064989(A250469(n)).
|
|
10
|
|
|
1, 2, 3, 4, 5, 6, 7, 10, 9, 8, 11, 14, 13, 22, 15, 12, 17, 26, 19, 34, 21, 20, 23, 38, 25, 18, 33, 16, 29, 46, 31, 58, 39, 28, 35, 30, 37, 62, 51, 44, 41, 74, 43, 82, 57, 24, 47, 86, 49, 50, 27, 52, 53, 94, 55, 42, 69, 68, 59, 106, 61, 118, 87, 40, 65, 66, 67, 122, 45, 76, 71, 134, 73, 142, 93, 36, 77, 70, 79, 146, 111, 32, 83, 158, 85, 78, 123
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
LINKS
|
|
|
FORMULA
|
As a composition of related permutations:
Other identities. For all n >= 0:
A000035(a(n)) = A000035(n). [This permutation preserves the parity of n.]
A020639(a(n)) = A020639(n). [More generally, it preserves the smallest prime dividing n.]
|
|
MATHEMATICA
|
f[n_] := Times @@ Power[Which[# == 1, 1, # == 2, 1, True, NextPrime[#, -1]] & /@ First@ #, Last@ #] &@ Transpose@ FactorInteger@ n; g[n_] := If[n == 1, 0, PrimePi@ FactorInteger[n][[1, 1]]]; Function[s, MapIndexed[ Function[{m, n}, f[Lookup[s, g[n] + 1][[m]] - Boole[n == 1]]][#1, First@ #2] &, #] &@ Map[Position[Lookup[s, g@ #], #][[1, 1]] &, Range@ 120]]@ PositionIndex@ Array[g, 10^4] (* Michael De Vlieger, Mar 09 2017, Version 10 *)
|
|
PROG
|
(Scheme, two alternatives)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|