Friday, March 3, 2017

Week 4

Last week on "Don't be a Square: The Magic Square of Squares"...

Our brave adventurer made strange discoveries,




new friends.

and a lot of progress.

This time, Vijay continues on and explores non-primitive pythagorean triples.


Non-primitive pythagorean triples $X^2+Y^2=Z^2$ are pythagorean triples where $X$ and $Y$ and not relatively prime. In other words, they can be "reduced."

For example, the pythagorean triple $6^2+8^2=10^2$ is non-primitve because it can be reduced to $3^2+4^2=5^2$


If we include non-primitive triples, then we must also consider Fermat family triples. We eliminated them last time because $Y-X=1$ for Fermat triples, but this is not the case for non-primitive triples.


Last time, we learned about the white arrow and that it meant the that $X+Y$ of one triple equals $Y-X$ of another triple.


Here are all the possible cases for the arrow relation:


$p \times Fermat \rightarrow q \times Fermat$

$p \times Fermat \rightarrow q \times Plato$
$p \times Fermat \rightarrow q \times Pythagoras$
$p \times Plato \rightarrow q \times Fermat$
$p \times Plato \rightarrow q \times Plato$
$p \times Plato \rightarrow q \times Pythagoras$
$p \times Pythagoras \rightarrow q \times Fermat$
$p \times Pythagora \rightarrow q \times Plato$
$p \times Pythagoras \rightarrow q \times Pythagoras$

We need to find out when each of these are possible. Here are the mathematical expressions for the sums and difference of the primitive type of each triangle


$X+Y$ for Fermat:

$\frac{1}{2}\left(\left(1+\sqrt{2}\right)^{2k+1}+\left(1-\sqrt{2}\right)^{2k+1}\right)$

$Y-X$ for Fermat:

$1$

$X+Y$ for Plato:

$2n^2+4n+1$

$Y-X$ for Plato:

$2n^2-1$

$X+Y$ for Pythagoras:

$4m^2+12m+7$

$Y-X$ for Pythagoras:

$4m^2+4m-1$

This means that our list of cases for the arrow relation becomes


$p \times \frac{1}{2}\left(\left(1+\sqrt{2}\right)^{2k+1}+\left(1-\sqrt{2}\right)^{2k+1}\right) = q \times 1$

$p \times \frac{1}{2}\left(\left(1+\sqrt{2}\right)^{2k+1}+\left(1-\sqrt{2}\right)^{2k+1}\right) = q \times 2n^2-1$
$p \times \frac{1}{2}\left(\left(1+\sqrt{2}\right)^{2k+1}+\left(1-\sqrt{2}\right)^{2k+1}\right) = q \times 4m^2+4m-1$
$p \times 2n^2+4n+1 = q \times 1$
$p \times 2n^2+4n+1 = q \times 2n^2-1$
$p \times 2n^2+4n+1 = q \times 4m^2+4m-1$
$p \times 4m^2+12m+7 = q \times 1$
$p \times 4m^2+12m+7 = q \times 2n^2-1$
$p \times 4m^2+12m+7 = q \times 4m^2+4m-1$

Because $X+Y$ and $Y-X$ are $1 \bmod 2$ for a pythagorean triple, modding all these equations by $2$ gives


$p \times 1 \bmod 2 = q \times 1 \bmod 2$

$p \bmod 2 = q \bmod 2$

This means arrows can only be drawn between two odd multiple triples or between two even multiple triples. This also happens to be true for the red, blue and green lines, so we can actually ignore even multiples since a reduced version can be found.


This is something I noticed very recently, but really it's ... something I should have noticed sooner


Anyways, let's look at some of these cases.


$$p \times 2n_1^2+4n_1+1 = q \times 2n_2^2-1$$

$$\frac{p}{q} \times 2n_1^2+4n_1+1 =  2n_2^2-1$$
$$\frac{p}{q} \times n_1^2+2n_1+\frac{1}{2} =  n_2^2-\frac{1}{2}$$
Let $n_2=n_1+k$
$$\frac{p}{q} \times n_1^2+2n_1+\frac{1}{2} =  n_1^2+2n_1k+k^2-\frac{1}{2}$$
$$0=n_1^2+2n_1k+k^2-\frac{1}{2}-\frac{p}{q}n_1^2-\frac{p}{q}2n_1-\frac{p}{q}\frac{1}{2}$$
By the quadratic formula, we get 
$$k=\frac{-2n_1 \pm \sqrt{\left(2n_1\right)^2-4\left(n_1^2-\frac{1}{2}-\frac{p}{q}n_1^2-\frac{p}{q}2n_1-\frac{p}{q}\frac{1}{2}\right)}}{2}$$
$$k=-n_1 \pm \sqrt{\frac{1}{2}+\frac{p}{q}n_1^2+\frac{p}{q}2n_1+\frac{p}{q}\frac{1}{2}}$$
We need
$$\frac{1}{2}+\frac{p}{q}n_1^2+\frac{p}{q}2n_1+\frac{p}{q}\frac{1}{2}=J^2$$
$$\frac{p}{q}n_1^2+\frac{p}{q}2n_1+\frac{p}{q}\frac{1}{2}+\frac{1}{2}-J^2=0$$
By the quadratic equation
$$n_1=\frac{-\frac{p}{q}2 \pm \sqrt{\left(\frac{p}{q}2\right)^2-4\left(\frac{p}{q}\right)\left(\frac{p}{q}\frac{1}{2}+\frac{1}{2}-J^2\right)}}{2\frac{p}{q}}$$
$$n_1=-1 \pm \sqrt{\frac{1}{2}-\frac{1}{2}\frac{q}{p}+\frac{q}{p}J^2}$$
We need
$$\frac{1}{2}-\frac{1}{2}\frac{q}{p}+\frac{q}{p}J^2=L^2$$
$$\frac{q}{p}\left(-\frac{1}{2}+J^2\right)=L^2-\frac{1}{2}$$
$$\frac{p}{q}=\frac{J^2-\frac{1}{2}}{L^2-\frac{1}{2}}$$

To summarize this means

$$\frac{p}{q}=\frac{J^2-\frac{1}{2}}{L^2-\frac{1}{2}}=\frac{2J^2-1}{2L^2-1}$$

$$n_1=L-1$$

$$n_2=J$$



By a similar proofs, we can get equations for three more cases. Here I will rewrite all four of them with clearer variables. $m$ will indicate the multiple of the primitive series while $i$ will indicate the index of the triple in the series



$Plato \rightarrow Plato$

$J$ and $L$ are integers

$$\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{2L^2-1}$$

$$i_{from}=L-1$$

$$i_{to}=J$$



$Pythagoras \rightarrow Pythagoras$

$J$ and $L$ are odd integers

$$\frac{m_{from}}{m_{to}}=\frac{J^2-2}{L^2-2}$$

$$i_{from}=\frac{L-3}{2}$$

$$i_{to}=\frac{J-1}{2}$$


$Pythagoras \rightarrow Plato$

$J$ and $L$ are integers and $L$ is odd

$$\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{L^2-2}$$

$$i_{from}=\frac{L-3}{2}$$

$$i_{to}=J$$


$Plato \rightarrow Pythagoras$

$J$ and $L$ are integers and $J$ is odd

$$\frac{m_{from}}{m_{to}}=\frac{J^2-2}{2L^2-1}$$

$$i_{from}=L-1$$

$$i_{to}=\frac{J-1}{2}$$


If we look a bit closer at
$$\frac{m_{from}}{m_{to}}=\frac{J^2-2}{2L^2-1}$$
$$m_{from}\left(2L^2-1\right)=\left(J^2-2\right)m_{to}$$
Since $J^2$ is an odd square, we can say
$$m_{from}\left(2L^2-1\right)=\left(8\left(\frac{n^2+n}{2}\right)+1-2\right)m_{to}$$
When we mod out by $8$ we get
$$m_{from}\left(2L^2-1\right)=\left(7 \bmod 8\right)m_{to}$$
This chart shows that if $L$ is odd, then $2L^2-1=1 \bmod 8$ and
if $L$ is even, then $2L^2-1=7 \bmod 8$


so if $L$ is odd, we get
$$m_{from}\left(1\bmod8\right)=\left(7 \bmod 8\right)m_{to}$$

$$m_{from} \bmod 8 = -m_{to} \bmod 8$$



if $L$ is even, we get

$$m_{from}\left(7\bmod8\right)=\left(7 \bmod 8\right)m_{to}$$

$$m_{from} \bmod 8 = m_{to} \bmod 8$$



I have not yet tried this out on the other cases.


I have noticed that the arrows between the two families occur in pairs. I will explain more in this week's calculator.


If we again look at
$$m_{from}\left(2L^2-1\right)=\left(J^2-2\right)m_{to}$$
and let $m_{from}=1$ and $m_{to}=1$ then we get the Pellian equation
$$J^2-2L^2=1$$
which can be used to find value of $J$ and $L$ for $m_{from}=1$ and $m_{to}=1$


When an arrow goes to a Fermat family triple, it actually goes to all Fermat family triples of that multiple since they all share the $Y-X$ term.


That leaves only

$p \times \frac{1}{2}\left(\left(1+\sqrt{2}\right)^{2k+1}+\left(1-\sqrt{2}\right)^{2k+1}\right) = q \times 2n^2-1$

$p \times \frac{1}{2}\left(\left(1+\sqrt{2}\right)^{2k+1}+\left(1-\sqrt{2}\right)^{2k+1}\right) = q \times 4m^2+4m-1$

which I have not gotten to yet.


After I examine these two, I will start examining the red, green, and blue line relations.




And that is where I am at.

Here is a calculator that finds where arrows go between according to the equations in this post. The first line tells you the triples in terms of family(index,multiple) while the second line tells you the explicit values of the triples.

To see the arrow pairs, find values of $J$ and $L$ that work for Pythagoras => Plato. Then switch the values of $J$ and $L$ and hit Plato => Pythagoras. You should find a pattern like the picture below. This can also be observed with arrows within the same family. find values for $J$ and $L$ where $J \neq L$ that work for Plato => Plato. and then switch the two values and again try Plato => Plato. The same again works for Pythagoras => Pythagoras.


J:


L:


Friday, February 24, 2017

Week 3

     Last week, I worked on finding ways to express the 3x3 magic square of squares and this week, I found many more ways. Let's pick up where we left off.

We were looking for
$$\left(n_Y+1\ \ \ \ +\ \ \ \ n_Y+2\ \ \ \ ...\ \ \ \ n_Z \right)=\left(n_X+1\ \ \ \ +\ \ \ \ n_X+2\ \ \ \ ...\ \ \ \ n_Y \right)$$
so I thought of this as 
$$\left(m\ \ \ \ +\ \ \ \ m+1\ \ \ \ ...\ \ \ \ n \right)=\left(n+1\ \ \ \ +\ \ \ \ n+2\ \ \ \ ...\ \ \ \ n+k \right)$$
We need to find $m,n,k$ such that
$$\frac{\left( n+m \right) \left( n-m+1 \right) }{2}=\frac{\left( 2n+k+1 \right) \left( k \right) }{2}$$
$$n^2-m^2+n+m=\left(2n+k+1\right)\left(k\right)$$
$$n^2-m^2-n+m=\left(2n+k+1\right)\left(k\right)-2n$$
$$\left(n-m\right)\left(n+m-1\right)=\left(2n+k+1\right)\left(k\right)-2n$$
Let $w=n-m$ and $x=n+m+1$. Also note that $2n=w+x+1$
$$wx=\left(w+x+k+2\right)\left(k\right)-\left(w+x+1\right)$$
$$0=k^2+wk+xk+2k-wx-w-x-1$$
$$0=k^2+k\left(w+x+1\right)-\left(w+1\right)\left(x+1\right)$$
Through the quadratic formula, we get
$$k=\frac{-w-x-2 \pm \sqrt{\left(x+x+2\right)^2 -4\left(-\left(w+1\right)\left(x+1\right)\right)}}{2}$$
Essentially we need the $b^2-4ac$ term to be a perfect square, but first we'll consider $b^2$ and $b^2+4ac$
$$b^2+4ac=\left(w+x+2\right)^2 +4\left(-\left(w+1\right)\left(x+1\right)\right)=w^2-2wx+x^2=\left(x-w\right)^2$$
So $b^2+4ac$ is a perfect square.
$b^2$ is also a perfect square.
This means that if $b^2 -4ac$ is a perfect square, it is the last term in an arithmetic progression of squares which is what we were looking for in the first place.

This seems like all the ways of expressing a magic square I would find, so I decided to take a step back and try a different approach. Besides, I was getting really frustrated anyways
Image result for nichijou gifs popcorn

We need the 8 sums of the magic square to be equal.
$A+B+C=S$
$D+E+F=S$
$G+H+I=S$
$A+D+G=S$
$B+E+H=S$
$C+F+I=S$
$A+E+I=S$
$C+E+G=S$

If the following are true:
$B+H=D+F=2E$
$B+D=2I$
$B+F=2G$
$H+D=2C$
$H+F=2A$

then
$A+B+C=\frac{H+F}{2}+\left(D+F-H\right)+\frac{H+D}{2}=\frac{3F+3D}{2}$
$A+D+G=\frac{H+F}{2}+D+\frac{B+F}{2}=\frac{2D+B+H+2F}{2}=\frac{3F+3D}{2}$
$D+E+F=\frac{2D+2E+2F}{2}=\frac{3D+3F}{2}$
$A+E+I=\frac{H+F}{2}+\frac{D+F}{2}+\frac{B+D}{2}=\frac{2D+B+H+2F}{2}=\frac{3F+3D}{2}$
This continues for all 8 sums we need.

In squares where $B+H=D+F=2E$, we can say $B<D<F<H$ without loss of generality

(By "without loss of generality," I mean a square with $B+H=D+F=2E$ but not $B<D<F<H$ can just be rotated or reflected so that $B<D<F<H$)

We can express the magic square of squares as 6 arithmetic sequences of squares:
$b^2,e^2,h^2$
$d^2,e^2,f^2$
$b^2,i^2,d^2$
$b^2,g^2,f^2$
$d^2,c^2,h^2$
$f^2,a^2,h^2$

Here's my best attempt to visually represent this

Each rectangle is an arithmetic progression of size 3 and each letter is an entry. Let's also give each progression a name.

Each rectangle can be related to another rectangle in a couple of ways

  1. First terms match
  2. Middle terms match
  3. Last terms match
  4. Last term of one matches first term of other
If we draw out these relationships, we get
Where the red line mean the first terms match, green lines mean the middle terms match, blue lines mean the last terms match. and white arrows go from an arithmetic progression whose last term matches the first term of the arithmetic progression it goes to.

An arithmetic progression $r^2,s^2,t^2$ can also be expressed as a Pythagorean triple $X^2+Y^2=Z^2$ through
$r=Y-X$
$s=Z$
$t=X+Y$

For the white arrow this means that $X_1+Y_1=Y_2-X_2$
which we can find in Stifel and Ozanam sequence.

A Stifel sequence generates all primitive triples in the Plato family
$$1\frac13 , 2\frac25 , 3\frac37 ...$$
to get the triples, express them as an improper fraction
$$\frac43 , \frac{12}{5} , \frac{24}{7}...$$
and we get
$3^2+4^2=5^2$, $5^2+12^2=13^2$, $7^2 + 24^2 = 25^2$...

Also notice that $3+4=12-5$, $5+12=24-7$...

This means we would draw white arrows between arithmetic progressions of squares generated by consecutive terms in this progression.

A Ozanam sequence generates all primitve triples in the Pythagoras family
$$1\frac78 , 2\frac{11}{12} , 3\frac{15}{16}...$$
to get the triples, express them as an improper fraction
$$\frac{15}{8} , \frac{35}{12} , \frac{63}{16}...$$
and we get $8^2+15^2=17^2$, $12^2+35^2=37^2$, and $16^2+63^2=65^2$

Again notice that $8+15=35-12$, $12+35=63-16$...


This means we would draw white arrows between arithmetic progressions of squares generated by consecutive terms in this progression.

The primitive triples in the Fermat family have $Y-X=1$ which would yield $1$ as an entry in the magic square of squares. Morgenstern proved that 1 cannot be an entry in a magic square of squares, so we don't need to consider the Fermat family.

So we know to draw arrows between consecutive terms of the Stifel and Ozanam sequences, but should we draw any arrows between them?

We would need
the $X+Y$ of the nth term of Stifel = $Y-X$ of the mth term of Ozanam
$2n^2+4n+1=4m^2+4m-1$
let $n=m+k$
$2m^2+4mk+2k^2+4m+4k+1=4m^2+4m-1$
$0=-2k^2-4mk-4k+2m^2-2$
$0=k^2+k\left(2m+2\right)+\left(1-m^2\right)$
By the quadratic formula, we get
$$\frac{-2m-2 \pm \sqrt{4\left(m+1\right)^2+4\left(m^2-1\right)}}{2}$$
$$-m-1 \pm \sqrt{2\left(m\right)\left(m+1\right)}$$
So we need to prove that $2\left(m\right)\left(m+1\right)$ is a perfect square

By reversing Dickson's method, we can find values for $m$
If there are $u,v,w$ such that $w^2=2uv$, then there is a Pythagorean triple can be made by
$x=w+u$
$y=w+v$
$z=w+u+v$

If we reverse this so that $u=m$ and $v=m+1$, we are looking for a Pythagorean triple where $y-x=1$, or in other words, one from the Fermat family.

So Pythagorean triples from the Fermat family dictate where we can draw arrows from the Stifel sequence to the Ozanam sequence, but what about from the Ozanam sequence from the Stifel sequence?

We would need
$Y-X$ of the nth term of Stifel = $X+Y$ of the mth term of Ozanam
$2n^2-1=4m^2+12m+7$
let $n=m+k$
$2m^2+4mk+2k^2-1=4m^2+12m+7$
$0=-2k^2-4mk+2m^2+12m+8$
$0=k^2+k\left(2m\right)+\left(-6m-m^2-4\right)$
By the quadratic formula,
$$k=\frac{-2m \pm \sqrt{4m^2+4\left(6m+m^2+4\right)}}{2}$$
$$k=-m \pm \sqrt{2\left( m+1\right)\left(m+2\right)}$$

We again use reverse Dickson's method to find that we must find a Pythagorean triple from the Fermat family.

If we visualize Stifel and Ozanam sequences then we get

Our work with arrows between the two sequence would mean that later on we would see multiple of something similar to

So far, I've only considered primitive triples, only considered the white arrow, and only considered Plato and Pythagoras families. So there's a lot to learn.

And that's where I'm currently at.

Here we have a calculator that will let you see the nth triple of the Plato, Pythagoras, or Fermat family. Just enter $n>0$ and select which family you want. For large values of $n$, the Fermat family triples get very large. So large in fact that the programming variables overflow. For $n>20$ it doesn't work properly and for $n>402$ it says "infinity^2 + infinity^2 = infinity^2." Just something I found funny.

Friday, February 17, 2017

Week 2

     Even though the magic squares only requires that the rows, columns, and diagonals sum to the same number and that each entry is the distinct square of an integer, there are many ways to think about the magic square of squares. If we can turn the magic square of squares problem into a different problem, then perhaps we may solve it.


A magic square can be expressed as 3 arithmetic progressions.

     An arithmetic progression is a sequence of numbers where the difference between consecutive terms is constant. For example
$1,2,3$ where consecutive terms differ by $1$
$3,5,7,9,11$ where consecutive terms differ by $2$

If we have 3 arithmetic progressions

$a,a+u,a+2u$
$a+v,a+u+v,a+2u+v$
$a+2v,a+2v+,a+2u+2v$

We can reorganize them into this magic square





$$a+u+2v,\ \ \ \ \ a,\ \ \ \ \ a+2u+v\\a+2u,\ \ \ \ \ a+u+v,\ \ \ \ \ a+2v\\a+v,\ \ \ \ \ a+2u+2v,\ \ \ \ \ a+u$$

Now we just need to ensure that each of these numbers are perfect squares

An arithmetic progression of squares can be expressed as a Pythagorean triple

We can find arithmetic progressions of perfect squares by taking a Pythagorean triple $X^2+Y^2=Z^2$ and letting
$r=X-Y$
$s=Z$
$t=X+Y$

Our arithmetic progression is $r^2,s^2,t^2$

For example $4^2+3^2=5^2$
$r=4-3=1$
$s=5$
$t=4+3=7$

and our arithmetic progression is $1,25,49$ with common difference 24
However, nothing has yet been discovered with this method of generating arithmetic progressions of squares.

     This previous way of expressing a magic square was part of research previously done. Now, I will show my version of this, but first I must prove a few things.

The entries of a magic square are all odd
Let us try organizing all integers into four classes. The first class is $0 \bmod 4$ and numbers that give remainder $0$ when divided by $4$ are in this class. The second class is $1 \bmod 4$ and numbers that give remainder $1$ when divided by $4$ are in this class. This continues up to $3 \bmod 4$. (You can't have a remainder $4$ or higher if you are diving by $4$).

even numbers are in either the $0 \bmod 4$ or $2 \bmod 4$ class while odd numbers are in either the $1 \bmod 4$ or $3 \bmod 4$ class.

What class is the square of even numbers in?
$0 \bmod 4 * 0 \bmod 4 = 0 \bmod 4$
$2 \bmod 4 * 2 \bmod 4 = 4 \bmod 4 = 0 \bmod 4$

Whether the even number is $0 \bmod 4$ or $2 \bmod 4$, it's square is $0 \bmod 4$

What class is the square of odd numbers in?
$1 \bmod 4 * 1 \bmod 4 = 1 \bmod 4$
$3 \bmod 4 * 3 \bmod 4 = 9 \bmod 4 = 1 \bmod 4$

Whether the odd number is $1 \bmod 4$ or $3 \bmod 4$, it's square is $1 \bmod 4$

From one of our previous proofs, for some magic square of squares
$$A\ B\ C\\D\ E\ F\\G\ H\ I$$
we know that $B+H=2E$

Because $B$ and $H$ are squares, they must be either $0 \bmod 4$ or $1 \bmod 4$

If $B$ is $0 \bmod 4$ and $H$ is $1 \bmod 4$, what is $E$?

In other words, for what $n$ does $2 * n \bmod 4 = 1 \bmod 4$?

The answer is there is no $n$. This means that $B$ and $H$ cannot have those values. They must both be $0 \bmod 4$ or both be $1 \bmod 4$


What if $B \equiv 0 \bmod 4$, $H \equiv 0 \bmod 4, D \equiv 1 \bmod 4, F \equiv 1 \bmod 4$?

According to $B$ and $H$, $2 * n \bmod 4 = 0 \bmod 4$ so $n=0$ or $2$ and $E \equiv 0 \bmod 4$ (since $2 \bmod 4$ is not a square)

According to $D$ and $F$, $2 * n \bmod 4 = 2 \bmod 4$ so $n=1$ or $3$ and $E \equiv 1 \bmod 4$ (since $3 \bmod 4$ is not a square)

We have reached a contradiction, so these values for $B,H,D,F$ do not work. Instead they must all have the same value.


What if $B,H,D,F$ are all $ 1 \bmod 4$?
$$A\ 1\ C\\1\ E\ 1\\G\ 1\ I$$
Then $E \equiv 1 \bmod 4$
$$A\ 1\ C\\1\ 1\ 1\\G\ 1\ I$$
Then the sum of each row, column and diagonal is $3 \bmod 4$. This forces the rest of the values to be $ 1 \bmod 4$
$$1\ 1\ 1\\1\ 1\ 1\\1\ 1\ 1$$

What if $B,H,D,F$ are all $ 0 \bmod 4$?
$$A\ 0\ C\\0\ E\ 0\\G\ 0\ I$$
Then $E \equiv 0 \bmod 4$
$$A\ 0\ C\\0\ 0\ 0\\G\ 0\ I$$
Then the sum of each row, column and diagonal is $0 \bmod 4$. This forces the rest of the values to be $ 0 \bmod 4$
$$0\ 0\ 0\\0\ 0\ 0\\0\ 0\ 0$$

However, each of these entries is even and the square is not simplified. It's kind of like writing $\frac{2}{4}$; we would instead write $\frac{1}{2}$. Since all entries are even, we could keep dividing by $2$ until at least one entry is odd. Since we proved the entries are either all even or all odd, repeatedly dividing by $2$ would yield a square with all odd entries.

In short, a magic square of squares with all even entries is just a magic square of squares with all odd entries times an even square

Now, we see that a magic square of squares must have only odd entries.


An arithmetic progression of odd squares can be expressed as an arithmetic progression of triangular numbers
Since each entry is an odd perfect square, each entry can be expressed as 8m+1 where m is a triangular number. A triangular number is the number of points in a triangle like this:
Image result for triangular numbers
For example $8*3+1=25$ and $8*6+1=49$. This means that we can express an arithmetic progression of squares as an arithmetic progression of triangular numbers

An arithmetic progression of triangular numbers can be expressed as halves of an arithmetic series with difference 1

Triangular numbers can be expressed as an arithmetic series with difference 1. For example, $1+2+3+4=10$
$1+2+3+4+5=15$
$1+2+3+4+5+6=21$
For some triangular number, we'll say that it can be expressed as $1+2+...n$

Let's say we have an arithmetic progression of triangular numbers $X,Y, Z$
We know that $Z-Y=Y-X$
This means that
$\left(1+2\ ...\ n_Z \right) - \left(1+2\ ...\ n_Y\right) = \left(1+2\ ...\ n_Y \right) - \left(1+2\ ...\ n_X \right)$
$\left(n_Y+1\ \ \ \ +\ \ \ \ n_Y+2\ \ \ \ ...\ \ \ \ n_Z \right)=\left(n_X+1\ \ \ \ +\ \ \ \ n_X+2\ \ \ \ ...\ \ \ \ n_Y \right)$
By inspecting this equation, we see that we are looking for
an arithmetic series such that it can be split into 2 parts with equal sums.
We could express an arithmetic progression of triangular numbers as such an arithmetic series

With so many different ways to express a magic square of squares, hopefully we will be able to generate one of these and by extension generate a magic square of squares.

I will leave you with a little program that Intro to Categories students might find useful. This is a permutation calculator. In Intro to Categories, we have "permutations" that send one number to another. For example, the permutation $\left(ACBD\right)$ sends A to C, C to B, B to D, and D to A. When we link multiple of these permutations together we can "multiply" them together to get a single permutation. This process of multiplying permutations together can become tedious for larger permutations, so I created a program that multiplies permutations.