Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #6 Mar 15 2016 00:16:52
%S 1,2,3,4,7,6,5,8,19,14,17,12,9,10,11,16,13,38,53,28,21,34,47,24,15,18,
%T 23,20,39,22,29,32,61,26,35,76,57,106,155,56,103,42,59,68,123,94,137,
%U 48,31,30,41,36,27,46,65,40,25,78,113,44,81,58,83,64,37,122,179,52,45,70,101,152,271,114,167,212,375,310,461,112,97
%N Permutation of natural numbers: a(1) = 1, a(2n) = 2*a(n), a(2n+1) = A269369(1+a(n)).
%C This sequence can be represented as a binary tree. When the parent contains n, the left hand child contains 2n, while the value of right hand child is obtained by applying A269369(1+n):
%C 1
%C |
%C ................../ \..................
%C 2 3
%C 4......../ \........7 6......../ \........5
%C / \ / \ / \ / \
%C / \ / \ / \ / \
%C / \ / \ / \ / \
%C 8 19 14 17 12 9 10 11
%C 16 13 38 53 28 21 34 47 24 15 18 23 20 39 22 29
%C etc.
%H Antti Karttunen, <a href="/A270195/b270195.txt">Table of n, a(n) for n = 1..8191</a>
%H <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the natural numbers</a>
%F a(1) = 1, a(2n) = 2*a(n), a(2n+1) = A269369(1+a(n)).
%o (Scheme, with memoization-macro definec)
%o (definec (A270195 n) (cond ((<= n 1) n) ((even? n) (* 2 (A270195 (/ n 2)))) (else (A269369 (+ 1 (A270195 (/ (- n 1) 2)))))))
%Y Inverse: A270196.
%Y Cf. A269369.
%Y Related or similar permutations: A269865, A269374, A269375, A270197.
%K nonn,tabf
%O 1,2
%A _Antti Karttunen_, Mar 13 2016