login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A071660 Permutation of natural numbers induced by the automorphism robl_car_cdr! acting on the parenthesizations encoded by A014486. 12

%I #5 Apr 30 2014 01:53:48

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

%T 37,38,52,51,53,55,54,60,61,62,64,43,42,56,57,63,44,58,45,23,24,46,25,

%U 26,27,47,59,48,28,29,49,30,31,32,50,33,34,35,36,113,112,117,118,120

%N Permutation of natural numbers induced by the automorphism robl_car_cdr! acting on the parenthesizations encoded by A014486.

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

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

%o (Scheme function implementing this automorphism on list-structures:)

%o (define (robl_car_cdr! s) (cond ((not (pair? s))) ((not (pair? (cdr s))) (swap! s)) (else (robl! s) (robl_car_cdr! (car s)) (robl_car_cdr! (cdr s)))) s)

%o (define (robl! s) (let ((ex-car (car s))) (set-car! s (cddr s)) (set-cdr! (cdr s) ex-car) (swap! (cdr s)) (swap! s) s))

%o (define (swap! s) (let ((ex-car (car s))) (set-car! s (cdr s)) (set-cdr! s ex-car) s))

%Y Inverse permutation: A071659. The car/cdr-flipped conjugate of A071655, i.e. A071660(n) = A057163(A071655(A057163(n))). Cf. also A071657, A071658.

%K nonn

%O 0,3

%A _Antti Karttunen_, May 30 2002

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 25 10:47 EDT 2024. Contains 371967 sequences. (Running on oeis4.)