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!)
A366389 Variant of bijective bit-reverse of n (A057889) for which it holds that a(n) == n (mod 3). 5
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 26, 12, 22, 14, 15, 16, 17, 18, 25, 20, 21, 13, 29, 24, 19, 11, 27, 28, 23, 30, 31, 32, 33, 34, 98, 36, 82, 50, 57, 40, 74, 42, 106, 104, 45, 58, 122, 48, 70, 38, 51, 88, 86, 54, 118, 56, 39, 46, 110, 60, 94, 62, 63, 64, 65, 66, 97, 68, 81, 49, 113, 72, 73, 41, 105, 100, 89, 114, 121 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
COMMENTS
Like A057889, also this is a self-inverse permutation of nonnegative integers.
LINKS
FORMULA
If A057889(n) == n mod 3, then a(n) = A057889(n), otherwise a(n) = A073675(A057889(n)) = A057889(A073675(n)).
For all n >= 0, A010872(a(n)) = A010872(n).
PROG
(PARI)
A030101(n) = if(n<1, 0, subst(Polrev(binary(n)), x, 2));
A057889(n) = if(!n, n, A030101(n/(2^valuation(n, 2))) * (2^valuation(n, 2)));
A073675(n) = if(valuation(n, 2)%2, n/2, 2*n);
A366389(n) = { my(u=A057889(n)); if(!((u-n)%3), u, A073675(u)); };
CROSSREFS
Cf. A010872, A030101, A057889, A073675, A366378, A366379, A366390 (Dirichlet inverse), A366392.
Cf. also A118967.
Sequence in context: A106604 A095205 A344325 * A161978 A132579 A004850
KEYWORD
nonn,look
AUTHOR
Antti Karttunen, Oct 22 2023
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 10 07:01 EDT 2024. Contains 372358 sequences. (Running on oeis4.)