OFFSET
1,1
COMMENTS
The sequence is well defined: sketch of proof, by contradiction:
- if the sequence were not well defined, then we would have some m > 0 such that L(1) = m for any k >= m,
- to prevent L(1) from being merged to L(2) forever, L(2) must always be merged to L(3) for some L(3) < m
- this can happen only finitely many times as the number of terms < m in L strictly decreases at each such merge,
- so at some time, L(1) < L(3) and L(1) merges with L(2) at k = L(1) + L(2), and then L(1) > m, a contradiction, QED.
The given procedure leads to a kind of infinite binary tree T:
- each node has a positive integer value,
- the node with value n has as parent the node with value abs(a(n)) and as sibling the node with value abs(a(n)) - n (see A328654 for the sibling of a node),
- each node has finitely many descendant nodes,
- each node has infinitely many ancestor nodes, so the tree is not rooted (see A328653 for the ancestors of 1),
- two nodes have always a common ancestor,
- see illustration in Links section.
LINKS
Rémy Sigrist, Table of n, a(n) for n = 1..10000
Rémy Sigrist, Illustration of the first terms
Rémy Sigrist, C++ program for A326936
FORMULA
If a(m) + a(n) = 0, then abs(a(m)) = abs(a(n)) = m + n.
EXAMPLE
For k = 1:
- we set L = (1).
For k = 2:
- we set L = (1, 2).
For k = 3:
- the first two terms, (1, 2), sum to 3,
- so a(1) = -3 and a(2) = +3,
- we set L = (3).
For k = 4:
- we set L = (3, 4).
For k = 5:
- we set L = (3, 4, 5).
For k = 6:
- we set L = (3, 4, 5, 6).
For k = 7:
- the first two terms, (3, 4), sum to 7,
- so a(3) = -1 and a(4) = +7,
- we set L = (7, 5, 6).
PROG
(C++) See Links section.
CROSSREFS
KEYWORD
sign
AUTHOR
Rémy Sigrist, Oct 22 2019
STATUS
approved