cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A071657 Permutation of natural numbers induced by the automorphism car_robr_cdr! acting on the parenthesizations encoded by A014486.

This page as a plain text file.
%I A071657 #5 Apr 30 2014 01:53:47
%S A071657 0,1,3,2,7,8,5,6,4,17,18,20,21,22,12,13,15,16,19,10,9,14,11,45,46,48,
%T A071657 49,50,54,55,57,58,59,61,62,63,64,31,32,34,35,36,40,41,43,44,47,52,53,
%U A071657 56,60,26,27,24,28,25,38,37,42,51,29,33,30,39,23,129,130,132,133,134
%N A071657 Permutation of natural numbers induced by the automorphism car_robr_cdr! acting on the parenthesizations encoded by A014486.
%H A071657 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 A071657 <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>
%o A071657 (Scheme function implementing this automorphism on list-structures:)
%o A071657 (define (car_robr_cdr! s) (cond ((not (pair? s))) ((not (pair? (car s))) (swap! s)) (else (car_robr_cdr! (car s)) (robr! s) (car_robr_cdr! (cdr s)))) s)
%o A071657 (define (robr! s) (let ((ex-cdr (cdr s))) (set-cdr! s (caar s)) (set-car! (car s) ex-cdr) (swap! (car s)) (swap! s) s))
%o A071657 (define (swap! s) (let ((ex-car (car s))) (set-car! s (cdr s)) (set-cdr! s ex-car) s))
%Y A071657 Inverse permutation: A071658 and also its car/cdr-flipped conjugate, i.e. A071657(n) = A057163(A071658(A057163(n))). Cf. also A071655, A071656, A071659, A071660.
%K A071657 nonn
%O A071657 0,3
%A A071657 _Antti Karttunen_, May 30 2002