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!)
A268712 Permutation of natural numbers: a(1) = 1, a(2n) = A268677(a(n)), a(2n+1) = A268678(1+a(n)). 4
1, 2, 3, 6, 4, 9, 5, 13, 11, 10, 7, 21, 18, 12, 8, 29, 23, 25, 20, 24, 19, 14, 15, 45, 40, 39, 34, 28, 22, 17, 16, 62, 56, 49, 42, 54, 48, 44, 37, 51, 47, 43, 36, 30, 26, 33, 27, 95, 87, 84, 75, 80, 74, 73, 65, 61, 53, 46, 41, 38, 32, 35, 31, 129, 120, 115, 108, 100, 93, 88, 82, 112, 105, 99, 92, 94, 86, 78, 70 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,2

COMMENTS

This sequence can be represented as a binary tree. Each left hand child is produced as A268677(n), and each right hand child as A268678(1+n), when the parent node contains n:

                                     |

                  ...................1...................

                 2                                       3

       6......../ \........4                   9......../ \........5

      / \                 / \                 / \                 / \

     /   \               /   \               /   \               /   \

    /     \             /     \             /     \             /     \

  13       11         10       7          21       18         12       8

29 23    25  20     24  19   14 15      45  40   39  34     28  22   17 16

etc.

LINKS

Antti Karttunen, Table of n, a(n) for n = 1..16383

Index entries for sequences that are permutations of the natural numbers

FORMULA

a(1) = 1, after which: a(2n) = A268677(a(n)), a(2n+1) = A268678(1+a(n)).

PROG

(Scheme, with memoization-macro definec)

(definec (A268712 n) (cond ((= 1 n) n) ((even? n) (A268677 (A268712 (/ n 2)))) (else (A268678 (+ 1 (A268712 (/ (- n 1) 2)))))))

CROSSREFS

Inverse: A268711.

Cf. A268677, A268678.

Sequence in context: A101369 A125147 A103864 * A152679 A232561 A348395

Adjacent sequences:  A268709 A268710 A268711 * A268713 A268714 A268715

KEYWORD

nonn,tabf

AUTHOR

Antti Karttunen, Feb 11 2016

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 August 17 12:30 EDT 2022. Contains 356189 sequences. (Running on oeis4.)