Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A054429
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A054429 Simple self-inverse permutation of natural numbers: List each block of 2^n numbers (from 2^n to 2^(n+1) - 1) in reverse order. +0
29
1, 3, 2, 7, 6, 5, 4, 15, 14, 13, 12, 11, 10, 9, 8, 31, 30, 29, 28, 27, 26, 25, 24, 23, 22, 21, 20, 19, 18, 17, 16, 63, 62, 61, 60, 59, 58, 57, 56, 55, 54, 53, 52, 51, 50, 49, 48, 47, 46, 45, 44, 43, 42, 41, 40, 39, 38, 37, 36, 35, 34, 33, 32, 127, 126, 125, 124, 123, 122, 121 (list; graph; listen)
OFFSET

1,2

LINKS

R. Zumkeller, Table of n, a(n) for n = 1..10000

R. Stephan, Some divide-and-conquer sequences ...

R. Stephan, Table of generating functions

Index entries for sequences that are permutations of the natural numbers

FORMULA

a(n) = ReflectBinTreePermutation(n)

a(n) = if n=1 then 1 else 2*a(floor(n/2)) + 1 - n mod 2. - Reinhard Zumkeller (reinhard.zumkeller(AT)gmail.com), Feb 18 2003

1/(1-x) * ((x-2x^2)/(1-x) + sum(k>=0, 3*2^k*x^2^k)). - Ralf Stephan (ralf(AT)ark.in-berlin.de), Sep 15 2003

A000120(a(n)) = A000120(A059894(n)) = A023416(n) + 1. - Ralf Stephan (ralf(AT)ark.in-berlin.de), Oct 05 2003

A115310(n, 1) = a(n). - Reinhard Zumkeller (reinhard.zumkeller(AT)gmail.com), Jan 20 2006

MAPLE

ReflectBinTreePermutation := n -> (((3*(2^floor_log_2(n)))-n)-1); # floor_log_2(x) gives [log2(x)], but floor(log[2](x)) is not healthy in Maple, so use this:

floor_log_2 := proc(n) local nn, i; nn := n; for i from -1 to n do if(0 = nn) then RETURN(i); fi: nn := floor(nn/2); od; end;

CROSSREFS

See also A054424, A054430.

{A000027, A054429, A059893, A059894} form a 4-group.

Cf. A115303, A115304, A115305, A115306, A115307, A115308, A115309, A106649.

This is Guy Steele's sequence GS(6,5) (see A135416).

Adjacent sequences: A054426 A054427 A054428 this_sequence A054430 A054431 A054432

Sequence in context: A130328 A083569 A071574 this_sequence A126316 A101224 A139285

KEYWORD

nonn,easy

AUTHOR

Antti Karttunen

page 1

Search completed in 0.003 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified October 13 02:37 EDT 2008. Contains 145008 sequences.


AT&T Labs Research