Skip to main content
3 of 3
Make a few more minor fixes, clarifications and other changes.
John Omielan
  • 1k
  • 3
  • 10
  • 14

Using almost exclusively just the first and second power terms, all positive integers (apart from the 8 exceptions you found) can be expressed in your specified form. First, with $s_k = 1$ for all $0 \le k \le c$, have

$$a_1 = \sum_{k=0}^{c}(k + 2) = \frac{(c + 2)(c + 3)}{2} - 1$$

For all $0 \le k \le c$, define

$$d_k = (k + 2)^2 - (k + 2) = k^2 + 3k + 2$$

i.e., the increase $a_1$ will get when $s_k$ increases to $2$. The initial set of $d_k$ values are

$$2, 6, 12, 20, 30, 42, 56, 72, \ldots$$

Using a sum of $1$ or more (at most once each) of these, there's no way to get an overall increase of $4$, $10$ or $16$, even with also using larger $s_k$ values. Otherwise, we have the following initial set of results:

$$2 = d_0, 6 = d_1, 8 = d_1 + d_0, 12 = d_2, 14 = d_2 + d_0, 18 = d_2 + d_1$$

Note $20 = d_2 + d_1 + d_0 = d_3$, so it can be obtained in more than one way. Next, using $20 = d_3$, we can get the values up to just before $30 = d_4$ by adding the results above, apart from $24$. However, that can be obtained instead by using that $3^3 - 3 = 24$. Next, using $30 = d_4$ and the cumulative results, we can obtain all of the even values up to just before $42 = d_5$ except for several exceptions, but they can be achieved by other combinations starting from $d_3$ and using the previous results. In particular, $34 = 20 + 14 = d_3 + (d_2 + d_0)$ and $40 = 20 + 20 = d_3 + (d_2 + d_1 + d_0)$. Also, these larger values can be obtained in multiple ways, e.g., $42 = 30 + 12 = d_4 + d_2$, $44 = 30 + 12 + 2 = d_4 + d_2 + d_0$, etc.

In general, using each next $d_k$ value, all of the even values up to just before $d_{k+1}$ can be obtained by adding the previous smaller results to either $d_k$ or $d_{k-1}$. Thus, apart from the exceptions of $4$, $10$ and $16$ mentioned earlier, all of the values with the same parity and larger than $a_1$ until well past $a_1 + d_c$ can be obtained.

Thus, here's an outline of how to use induction to prove my original statement, in particular by starting at $n = 1$, then going from $c = 4n$ to $c = 4(n + 1)$ for even $a$, and from $c = 4n + 1$ to $c = 4(n + 1) + 1$ for odd $a$. First, however, confirm that all $a$ values, apart from the $8$ exceptions you noted, can be obtained up to $45$. This is from $a_1 = 27$ (with $n = 1$ for odd values), so $c = 5$ and $a_1 = \frac{7\times 8}{2} - 1 = 27$, plus the first even integer addend always obtainable, i.e., $18$. Next, for even $a$ values, use the method I outlined above to show the even values from $a = a_1 + 18$ up to the next increase of $a_1$ value for $n + 1$ (i.e., $(4n + 1) + (4n + 2) + (4n + 3) + (4n + 4) = 16n + 10$, so the total is then $a = a_1 + 16n + 28$) can be obtained. Then do a similar thing for the odd $a$ values. Altogether, this proves that all larger $a$ values can be obtained.

John Omielan
  • 1k
  • 3
  • 10
  • 14