login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A338243 a(0) = 0, a(n) = A338241(2*n-1) for any n > 0. 3
0, 1, 3, 2, 4, 9, 8, 7, 6, 5, 10, 12, 11, 13, 27, 26, 25, 24, 23, 19, 21, 20, 22, 18, 17, 16, 15, 14, 28, 30, 29, 31, 36, 35, 34, 33, 32, 37, 39, 38, 40, 81, 80, 79, 78, 77, 73, 75, 74, 76, 72, 71, 70, 69, 68, 55, 57, 56, 58, 63, 62, 61, 60, 59, 64, 66, 65, 67 (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, Table of n, a(n) for n = 0..6560

Index entries for sequences that are permutations of the natural numbers

EXAMPLE

a(7) = A338241(13) = 7.

PROG

(PARI) b(n) = { if (n==0, return (0), my (d=n%3, m=n\3); if (d==0, 3*b(m), d==1, 1-3*b(m), 3*b(m)-1)) }

a(n) = if (n==0, 0, b(2*n-1))

CROSSREFS

Cf. A338241, A338242.

Sequence in context: A265356 A083164 A094962 * A338246 A084793 A033820

Adjacent sequences:  A338240 A338241 A338242 * A338244 A338245 A338246

KEYWORD

nonn

AUTHOR

Rémy Sigrist, Oct 18 2020

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 27 02:00 EDT 2021. Contains 348270 sequences. (Running on oeis4.)