%I #7 Mar 31 2012 13:21:12
%S 0,1,2,3,4,5,7,8,6,9,10,11,12,13,17,18,20,21,22,16,19,14,15,23,24,25,
%T 26,27,28,29,30,31,32,33,34,35,36,45,46,48,49,50,54,55,57,58,59,61,62,
%U 63,64,44,47,53,56,60,42,51,37,38,43,52,39,40,41,65,66,67,68,69,70,71
%N Signature permutation of a nonrecursive Catalan automorphism: row 1783367 of table A089840.
%H A. Karttunen, <a href="/A123713/b123713.txt">Table of n, a(n) for n = 0..6917</a>
%H A. Karttunen, <a href="/A089840/a089840p.txt">Prolog-program which illustrates the construction of this and other similar nonrecursive Catalan automorphisms.</a>
%H <a href="/index/Per#IntegerPermutationCatAuto">Index entries for signature-permutations of Catalan automorphisms</a>
%o (Scheme function, destructive implementation of this automorphism acting on S-expressions:) (define (*A123713! s) (cond ((not (pair? s)) s) ((pair? (car s)) (let ((org_cdar (cdar s))) (set-cdr! (car s) (cdr s)) (set-cdr! s (caar s)) (set-car! (car s) org_cdar) s)) ((and (pair? (cdr s)) (pair? (cadr s)) (pair? (caadr s)) (pair? (caaadr s))) (let ((org_b (car (caaadr s)))) (set-car! (caaadr s) (cdr (caaadr s))) (set-cdr! (caaadr s) (cdaadr s)) (set-cdr! (caadr s) (cdadr s)) (set-cdr! (cadr s) (cddr s)) (set-cdr! (cdr s) org_b) s)) (else s)))
%Y Inverse: A123714. Row 1783367 of A089840. Differs from A089855 for the first time at n=102, where a(n)=103, while A089855(n)=102.
%K nonn
%O 0,3
%A _Antti Karttunen_, Oct 11 2006