login
Permutation of natural numbers: rotations of the bottom branches of the rooted plane trees encoded by A014486. (to opposite direction of A057509).
18

%I #7 May 01 2014 02:48:29

%S 0,1,2,3,4,6,5,7,8,9,14,10,16,19,11,15,12,17,18,13,20,21,22,23,37,24,

%T 42,51,25,38,26,44,47,27,53,56,60,28,39,29,43,52,30,40,31,45,46,32,48,

%U 49,50,33,41,34,54,55,35,57,58,59,36,61,62,63,64,65,107,66,121,149,67

%N Permutation of natural numbers: rotations of the bottom branches of the rooted plane trees encoded by A014486. (to opposite direction of A057509).

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

%H A. Karttunen, <a href="http://www.iki.fi/~kartturi/matikka/Nekomorphisms/gatomorf.htm">Gatomorphisms</a> (Includes the complete Scheme program for computing this sequence)

%p # reverse given in A057508, for CountCycles, see A057502, for other procedures, follow A057501.

%p map(CatalanRankGlobal,map(RotateBottomBranchesR, A014486));

%p RotateBottomBranchesR := n -> pars2binexp(rotateR(binexp2pars(n)));

%p rotateR := a -> reverse(rotateL(reverse(a)));

%p RotBBPermutationCycleCounts := proc(upto_n) local u,n,a,r,b; a := []; for n from 0 to upto_n do b := []; u := (binomial(2*n,n)/(n+1)); for r from 0 to u-1 do b := [op(b),1+CatalanRank(n,RotateBottomBranchesL(CatalanUnrank(n,r)))]; od; a := [op(a),CountCycles(b)]; od; RETURN(a); end;

%p A003239 := RotBBPermutationCycleCounts(some_value); (e.g. 9. Cf. A057502, A057162)

%o (Scheme function implementing this automorphism on list-structures, see A057502 for RotateHandshakes! and swap!:) (define (Ror! s) (cond ((pair? s) (RotateHandshakesInv! s) (swap! s))) s)

%Y Inverse of A057509 and the car/cdr-flipped conjugate of A069776 and also composition of A057502 & A069770, i.e. A057510(n) = A057163(A069776(A057163(n))) = A069770(A057502(n)).

%Y Cycle counts given by A003239. Cf. also A057512, A057513.

%K nonn

%O 0,3

%A _Antti Karttunen_, Sep 03 2000