<s>[INST] An integer $n \geq 2$ is called square-positive- proof? An integer $n \geq 2$ is called square-positive if there are $n$ consecutive positive integers whose sum is a square. Determine the first four square-positive integers.
So I have found the first four square-positive numbers, but I need to prove that why it $4$ is not a square-positive number and I also need to write a general formula for determining whether a number is square-positive or not. I have tried to write the sum of consecutive positive integers like this $a + a +1 + a + 2 + a+3 \dots a - 1$ and I wrote it like this for all numbers, and part of the proof for why $4$ isn't a square-positive number is that $4a + 6$ is not divisible with $4$. But I haven't got so far.
Here is my answer:
2 : 4 + 5 = 9  which is 3^2
3 : 2 + 3 + 4 = 9 which is 3^2
5: 18 + 19 + 20 + 21 + 22 = 100  which is 10^2
6: 35 + 36 + 37 + 38 + 39 + 40 = 225  which is 15^2
Interesting fact is that for all odd numbers and some even numbers like 6 and 10, you can find out which number is the first (the one you start with and then go forward here like 3, 2, 18 and 35) using this formula :
(I show it in an example because I still can't write it algebraically):
For example: the sum of 95 subsequent numbers is 5n + 10
(10^2 - 10) /5 = 18
So your first number is 18
And if you keep adding, 18 + 19 + 20 + 21 + 22 you get 100 which is 10^2, the same number you squared.
 [/INST] We prove the following result:
If $n=2^b \cdot d, d \text{ is odd, then } n \text{ is square-positive if and only if } b=0  \text{ or } b  \text{ is odd}$.
$\underline{\text{Case 1}}$: $b$ is even and $b>0$. Let $b=2c$. We prove by contradiction $n$ cannot be square-positive. If it were, then there exist $n$ consecutive positive integers,
$$
a, a+1, \ldots, a+n-1
$$
such that the sum of these numbers is a square, i.e.,
$$
S=a+(a+1)+\cdots + (a+n-1) = n\frac{n+2a-1}{2} =T^2
$$
for some $T\in \mathbb{N}$.
Note that $n=2^{2c}\cdot d$ is even, and
$$
T^2 = S = 2^{2c-1}\cdot d \cdot (n+2a-1),
$$
which cannot be a perfect square because 1) $d(n+2a-1)$ is odd and, 2) $2c-1$, the highest power of its factor $2$ is odd, a contradiction.
$\underline{\text{Case 2}}: b=0$. Let $n=d=2m+1$, then the sum of the following $n$ consecutive numbers is a perfect square:
$$
n-m, n-m+1, \ldots, n+m.
$$
Indeed,
$$
S = (n-m)+(n-m+1)+\cdots +(n+m) = n \cdot \frac{(n-m)+(n+m)}{2}=n^2.
$$
$\underline{\text{Case 3}}: b=2c+1 $ for some $c\geqslant 0$, then $n=2^{2c+1}d$. We show that the sum of the following $n$ consecutive numbers is a perfect square:
$$
a, a+1, \ldots, a+(n-1),
$$
where
$$
a=\frac{1+d(K^2-2^{2c+1})}{2}
$$
and $K$ is some odd positive integer such that
$$
K^2 > 2^{2c+1}.
$$
For example, if $c\geqslant 1$, we can pick $K=2^{c+1}-1$. If $c=0$, we can pick $K=3$. Also note that $a$, the first number in the sequence, is a positive integer by construction.
Finally,
$$
S=n\frac{n+2a-1}{2} = \frac{2^{2c+1}d}{2} \left[ 2^{2c+1}d + d(K^2-2^{2c+1}) \right] = 2^{2c} d [ d K^2 ] = (2^c d K)^2. \blacksquare
$$
Example: $n=8=2^3 \cdot 1, c=1, d=1, K=3 \Rightarrow a=1$, and the sum of the sequence is $1+2+\cdots+8=36=6^2$.
</s>