login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A178734
a(n) = n XOR 8n, where XOR is bitwise XOR.
7
0, 9, 18, 27, 36, 45, 54, 63, 72, 65, 90, 83, 108, 101, 126, 119, 144, 153, 130, 139, 180, 189, 166, 175, 216, 209, 202, 195, 252, 245, 238, 231, 288, 297, 306, 315, 260, 269, 278, 287, 360, 353, 378, 371, 332, 325, 350, 343, 432, 441, 418, 427, 404, 413, 390
OFFSET
0,2
MATHEMATICA
f[n_] := BitXor[n, 8 n]; Array[f, 60, 0] (* Robert G. Wilson v, Jun 09 2010 *)
PROG
(Python)
def A178734(n): return n^ n<<3 # Chai Wah Wu, Jun 29 2022
KEYWORD
nonn
AUTHOR
Dmitry Kamenetsky, Jun 08 2010
EXTENSIONS
a(30) onwards from Robert G. Wilson v, Jun 09 2010
STATUS
approved