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!)
A178754 a(n) = n XOR floor(Log_2(n)), where XOR is bitwise XOR. 0

%I #2 Mar 30 2012 17:31:29

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

%T 31,24,25,26,27,37,36,39,38,33,32,35,34,45,44,47,46,41,40,43,42,53,52,

%U 55,54,49,48,51,50,61,60,63,62,57,56,59,58,70,71,68,69,66,67,64,65,78

%N a(n) = n XOR floor(Log_2(n)), where XOR is bitwise XOR.

%C This sequence is not a permutation of the integers which is self-inverse. But is it a permutation?

%t f[n_] := BitXor[n, Floor[ Log[2, n]]]; Array[f, 75];

%K easy,nonn

%O 1,2

%A _Robert G. Wilson v_, Jun 09 2010

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 03:15 EDT 2024. Contains 371964 sequences. (Running on oeis4.)