Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Closed Form

Using the recurrence:

We can start solving:

n12345678910111213
J(n)11313571357911

A pattern emerges in which the values repeat in windows of size the powers of 2, where each element in the window is incremented by 2. For example the window covering the values of n, 8 to 15, is of size