login
Permutation of natural numbers: a(0) = 1; for n >= 1, a(n) = A005940(1+A122111(n)).
5

%I #11 Dec 31 2018 13:22:38

%S 1,2,3,5,4,7,9,11,6,10,25,13,15,17,49,21,8,19,16,23,35,55,121,29,27,

%T 36,169,50,77,31,81,37,12,91,289,225,30,41,361,187,125,43,625,47,143,

%U 147,529,53,45,154,90,247,221,59,28,1225,343,391,841,61,105,67,961,605,18,5929,2401,71,323,551,525,73,22,79,1369,84,437,429,14641,83

%N Permutation of natural numbers: a(0) = 1; for n >= 1, a(n) = A005940(1+A122111(n)).

%C Note the indexing: the domain starts from 0, but the range excludes zero.

%H Antti Karttunen, <a href="/A322863/b322863.txt">Table of n, a(n) for n = 0..16383</a>

%H <a href="/index/Bi#binary">Index entries for sequences related to binary expansion of n</a>

%H <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>

%H <a href="/index/Pri#prime_indices">Index entries for sequences computed from indices in prime factorization</a>

%F a(0) = 1; for n >= 1, a(n) = A005940(1+A122111(n)).

%F For all n >= 1:

%F a(prime(n)) = prime(1+n).

%F A001222(a(n)) = A322867(n).

%o (PARI)

%o A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); t };

%o A064989(n) = {my(f); f = factor(n); if((n>1 && f[1,1]==2), f[1,2] = 0); for (i=1, #f~, f[i,1] = precprime(f[i,1]-1)); factorback(f)};

%o A122111(n) = if(1==n,n,prime(bigomega(n))*A122111(A064989(n)));

%o A322863(n) = if(!n,1,A005940(1+A122111(n)));

%Y Inverse permutation: A322864.

%Y Cf. A005940, A122111, A322866, A322867.

%K nonn

%O 0,2

%A _Antti Karttunen_, Dec 30 2018