login
A295893
a(n) = 1 if in Doudna-tree (A005940) the contents of the node n and its left-hand child have binary weights with different parity, 0 otherwise.
4
0, 1, 0, 1, 1, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 1, 1, 0, 1, 0, 1, 0, 0, 1, 1, 1, 0, 1, 0, 1, 1, 1, 1, 0, 1, 1, 0, 1, 1, 0, 1, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0
OFFSET
0
COMMENTS
Like A005940 and A252743 this can be viewed as a binary tree. See illustration below.
FORMULA
a(n) = A295891(A005940(1+n)).
a(n) = A000035(A295894(n) + A295894(2n)) = A295895(n) XOR A295895(2n).
EXAMPLE
The first six levels of the binary tree (compare also to the illustrations given at A005940, A295894, A295895):
0
|
1
............../ \..............
0 1
....../ \...... ....../ \......
1 0 1 1
/ \ / \ / \ / \
/ \ / \ / \ / \
0 1 1 0 0 0 0 0
/ \ / \ / \ / \ / \ / \ / \ / \
0 1 0 0 1 0 0 0 0 1 0 0 0 1 0 1
For n=0, the corresponding node in A005940(0+1) is 1, which has just one child 2, thus we set a(0) = 0 by convention.
For n=1, the corresponding node in A005940(1+1) is 2, which has 3 as its left-hand child, and in binary 2 is "10", and 3 is "11", so the other one has an odd number of 1-bits, while the other has an even number of 1's, thus their parities differ and a(1) = 1.
For n=2, the corresponding node in A005940(1+2) is 3 (in binary "11"), which has 5 (in binary "101") as its left-hand child, and they have the same parity, thus a(2) = 0.
For n=3, the corresponding node in A005940(1+3) is 4 (in binary "100"), which has 9 (in binary "1001") as its left hand child, and here the parities differ, thus a(3) = 1.
PROG
(Scheme) (define (A295893 n) (A295891 (A005940 (+ 1 n))))
CROSSREFS
KEYWORD
nonn,tabf
AUTHOR
Antti Karttunen, Nov 30 2017
STATUS
approved