The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A342102 Lexicographically latest sequence of distinct nonnegative integers such that for any n >= 0, {A000120(n), A080791(n)} = {A000120(a(n)), A080791(a(n))} 4
0, 1, 2, 3, 6, 5, 4, 7, 14, 12, 10, 13, 9, 11, 8, 15, 30, 28, 26, 25, 24, 22, 21, 29, 20, 19, 18, 27, 17, 23, 16, 31, 62, 60, 58, 56, 57, 52, 50, 54, 53, 49, 44, 51, 42, 48, 46, 61, 45, 41, 38, 43, 37, 40, 39, 59, 35, 36, 34, 55, 33, 47, 32, 63, 126, 124, 122 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
This sequence is a self-inverse permutation of the nonnegative integers.
LINKS
Rémy Sigrist, Colored scatterplot of the first 2^20 terms (where the color is function of min(A000120(n), A080791(n)))
FORMULA
a(2^k-1) = 2^k-1 for any k >= 0.
a(n) < 2^k for any n < 2^k.
EXAMPLE
The first terms, in decimal and in binary, alongside {A000120(n), A080791(n)}, are:
n a(n) bin(n) bin(a(n)) {A000120(n), A080791(n)}
-- ---- ------ --------- ------------------------
0 0 0 0 {0}
1 1 1 1 {0, 1}
2 2 10 10 {1}
3 3 11 11 {0, 2}
4 6 100 110 {1, 2}
5 5 101 101 {1, 2}
6 4 110 100 {1, 2}
7 7 111 111 {0, 3}
8 14 1000 1110 {1, 3}
9 12 1001 1100 {2}
10 10 1010 1010 {2}
11 13 1011 1101 {1, 3}
12 9 1100 1001 {2}
13 11 1101 1011 {1, 3}
14 8 1110 1000 {1, 3}
15 15 1111 1111 {0, 4}
PROG
(PARI) See Links section.
CROSSREFS
See A342115, A342116 and A342117 for similar sequences.
Sequence in context: A056539 A105726 A336962 * A284460 A336963 A175949
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, Feb 28 2021
STATUS
approved

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 May 29 03:48 EDT 2024. Contains 372921 sequences. (Running on oeis4.)