2

This question is based on Every natural number is covered by consecutive numbers that sum to a prime power.


Let $T(n) = \frac{n(n+1)}2$ be the $n$th triangular number, and let $p^j$ denote a prime power.

By checking $1 \leq n \leq 10\,000$, it appears empirically that after fixing $k$, $T(n)-T(k)$ is a prime power only for a finite number of values $n$:$$ \begin{align*} T(n) - T(0) = p^j &\Longrightarrow n \in \{ 2 \}\\ T(n) - T(1) = p^j &\Longrightarrow n \in \{ 2,3,4,7 \}\\ T(n) - T(2) = p^j &\Longrightarrow n \in \{ 3,4,7 \}\\ T(n) - T(3) = p^j &\Longrightarrow n \in \{ 4,5,10 \}\\ T(n) - T(4) = p^j &\Longrightarrow n \in \{ 5,6,13,22 \}\\ T(n) - T(5) = p^j &\Longrightarrow n \in \{ 7,16 \}\\ T(n) - T(6) = p^j &\Longrightarrow n \in \{ 7,19 \}\\ T(n) - T(7) = p^j &\Longrightarrow n \in \{ 8,9,10,17 \}\\ T(n) - T(8) = p^j &\Longrightarrow n \in \{ 9,10,25 \}\\ T(n) - T(9) = p^j &\Longrightarrow n \in \{ 28 \}. \end{align*} $$

Is it easy to prove that each of these sets is finite? If so, is there a way to compute an upper bound for the largest number that can appear in one of the sets, or otherwise compute the size of each set?

Peter Kagey
  • 5,438

1 Answers1

3

Yes, it's true these sets will be finite for any $k$, and the proof below shows how to compute a reasonable upper bound on the largest number which can appear. To see this, as I showed in my answer to the question you linked to as yours' being based on, you have

$$T(n) - T(k) = \frac{(n + k + 1)(n - k)}{2} = p^j \tag{1}\label{eq1A}$$

Apart from a factor of $2$ in either $n + k + 1$ or $n - k$, the only prime factor of these $2$ expressions is $p$ for some prime $p$. Assume $n - k \gt 2$, so it has at least one factor of $p$, to get

$$n - k \equiv 0 \pmod p \implies n \equiv k \pmod p \tag{2}\label{eq2A}$$

Thus, you also have

$$\begin{equation}\begin{aligned} n + k + 1 & \equiv 0 \pmod p \\ k + k + 1 & \equiv 0 \pmod p \\ 2k + 1 & \equiv 0 \pmod p \end{aligned}\end{equation}\tag{3}\label{eq3A}$$

This shows $p$ is limited to the prime factors of $2k + 1$.

Consider that $2 \mid n + k + 1$. Assuming $n - k \gt 1$, you have for some positive integers $q$ and $r$ (where $q + r = j$, so it works in \eqref{eq1A}) that

$$n + k + 1 = 2p^q \tag{4}\label{eq4A}$$

$$n - k = p^r \tag{5}\label{eq5A}$$

Next, \eqref{eq4A} minus \eqref{eq5A} gives

$$2k + 1 = 2p^q - p^r \tag{6}\label{eq6A}$$

If $s = \min(q,r)$, then $p^s \mid 2k + 1$. However, since $2k + 1$ is a fixed value, there's a maximum value allowed for $s$. This limits the maximum possible value for $n$ in \eqref{eq4A} and \eqref{eq5A}. You can also do basically the same analysis in the case where $2 \mid n - k$ instead.

In summary, this shows since for any prime factor $p$ of $2k + 1$ there's a maximum possible $n$ which works, and there are a finite number of these prime factors $p$, there are thus at most a finite number of solutions to \eqref{eq1A} for any particular $k$.

John Omielan
  • 52,653