We define a triangular number as follows:
$$\sum_{n=1}^{n} x_{i}$$
As in $T_3$ = $3+2+1$, or $6$. Generating these triangular numbers is rather simple and done by the equation:
$$T_n ={(n^2 + n)}/{2}$$
I am asking a question about how to generate Triangular Square numbers, those numbers that are both triangular and perfect squares. As in,
$$ s^2 = {(t^2 + t)}/{2}$$
Completing the square yields the following:
$$(2t + 1)^2 - 8s^2 = 1$$
Which is known as an instance of the pell equation, or
$$x^2 -2y^2 = 1$$
This is where I kind of get stuck. I thought about taking the line $y = mx - m, m \in Q$ searching for the other intersection point. Is that a way to go about this? If so,
Substituting y from the line into the pell equation yields:
$$x^2 -2m^2(x-1)^2 -1$$
Which, when divided by the other intersection point $x-1$ should yield another intersection point:
$$ \dfrac{x^2 -2m^2(x-1)^2 -1}{x-1} = -2 m^2 x+2 m^2+x+1 $$
Solving for x,
$$ x = \dfrac{2 m^2+1}{2 m^2-1} $$
Substituting back into the line equation we can get the ordered pair of the other intersection point:
$$ (x,y) = \Big(\dfrac{2 m^2+1}{2 m^2-1}, \dfrac{2 m}{2 m^2-1}\Big) $$
Though, how can I generate integer solutions? I see that some people say to take $$m = \dfrac{v}{u}, u^2 -2v^2 = 1$$
Following this advice, one gets the denominator $2 m^2-1$ to be
$$ 2\big(\dfrac{v^2}{u^2}\big) - 1 = \dfrac{-u^2 + 2v^2}{u^2} = -1/u^2 $$
Therefore, the point comes out as follows:
$$ (x,y) = \Big(-u^2 - 2v^2, -2vu\Big) $$
Which for some reason is very similar to the generating function of pythagorean triples, but I think thats besides the point? Well, we have somewhat done what we set out to with this function. Take the solution to the equation (3,2) for example, using our new point we get (17,12) which yields the triangular square 36. Keeping this up recursively will keep us going! Woohoo!
But why? What does this tell us? I tried to work it out and don't see those always being integer solutions. How can I generate all of these triangular square numbers. Does continuing with this method guarantee there are infinitely many? How do you prove every triangular square is of this form?
If $A_n$ is the $n$th triangular square, then for $n \ge 2$ the recursion $$A_n = 34A_{n-1} - A_{n-2} + 2$$ holds, with initial conditions $A_0 = 0$ and $A_1 = 1$.
And, yes, having such a recursion guarantees that there are infinitely many, and that they are all integers.
EDIT: https://oeis.org/A001110