Saturday, January 27, 2018

Vijay Nambi

Displaying HonorHealth_Vijay_Nambi.JPG
     Hello there! I am Vijay and soon I will be embarking on a journey through space and time...and math; I will be going to ASU's Department of Mathematics and working with Dr. John Jones to attempt to solve the 3x3 Magic Square of Squares problem:

Construct a 3x3 magic square composed of distinct perfect squares or prove that such a magic square cannot be constructed.

     This is certainly a very difficult problem; mathematicians have worked on this problem for quite a long time and still not solved it. However, bits of progress have been made over time and hopefully I can solve the problem or add some more progress. In addition to the 3x3 Magic Square of Squares, I will spend some time on similar problems such as 5x5 bimagic squares, 3x3 semi-magic square of cubes, magic squares of cubes, and add-mult magic squares. Mathematicians have solved similar problem of this difficulty, so I am sure that I can make some progress towards these smaller problems.

     Anyways, enough about the project itself. As you probably know, I am Vijay and a senior at BASIS Scottsdale. My favorite subjects are computer science, math, and music. I plan on majoring in computer science and mathematics. In my free time, I like to listen to music, watch anime, and (please don't laugh) make computer programs. I know it seems clichéd, but I truly love designing programs. I have created a cycle decomposer, a rail-fence cipher decoder, a multiplayer video game and so much more. Maybe I will share some of my cooler projects with you. I also love jokes (By the way, What did the tooth fairy say to the lawyer? “I want the tooth, the whole tooth and nothing but the tooth!” and the lawyer responds “You can’t handle the tooth!”).

     In 8th grade, I attempted to solve the 3x3 Magic Square of Squares problem. I independently proved that this magic square of squares must have either all odd entries or all even entries. Ever since then, this problem has haunted dreams for four years and my only goal in life is to solve it...well...maybe it's more like I have been thinking about and working on this problem from time to time. I really don't know what will happen at the end of my senior project. Will I actually solve the problem? or will I only know about the progress already made? One thing is for sure: I will do my best. Wish me luck!

Friday, April 14, 2017

Week 10

Last week, I used a program to try finding this structure



To recap, my program essentially generated a pair of triangles in the same $b-a$ class



and generated a third triangle



If the full structure exists, one would expect my program to return at least two results for one of the classes. This is because for a certain class, my program would give the three red triangles once and the three green triangle once.


However, I only got one result for each class. This could mean that this overall structure is so large that the variables in my program overflowed before it reached. One thing I realized about my program is that it checks only primitive triangles meaning that I accidentally skipped some triangles in each $b-a$ class.

Last week, I also examined an excel spreadsheet of the $b-a$ classes of primitive Pythagorean triples. However, I also examined the $b+a$ classes as well



Each red value indicates a duplicate value. This is important because in our diagram, we have three triangles that belong to the same $a+b$ class.

By looking at this spreadsheet some patterns become immediately clear: duplicate values occur at regular intervals in lines. If we pick a line through the origin with slope $-\frac{r}{s}$, and pick a point it hits, we should be able to draw a line of slope $\frac{r-s}{r+s}$ through this point it hits and find duplicate values. For example, if we pick slope $3$, the points we hit are highlighted in blue. If we then draw lines of slope $\frac{3-1}{3+1}=\frac24=\frac12$, we hit duplicate values.



While this is very interesting, it is not what I am focusing on most.

If we return to the structure of Pythagorean triangles



we notice that the white lines showing the class of each triangle converge to four points at the bottom. This means that from these four numbers, we can generate this whole structure. First let's name these points


We need each triangle's hypotenuse to be an integer, so we need $\sqrt{height^2+length^2}=\sqrt{\left(\frac{y-x}{2}\right)^2+\left(\frac{x+y}{2}\right)^2}=\sqrt{\frac{x^2+y^2}{2}}$ to be an integer where $x$ and $y$ are any pair of numbers from $a,b,c$, or $d$. The six possible pairs each correspond to a triangle.

How would we start finding such numbers?

If we start out with

$a_1^2+b^2=2j^2$
$a_2^2+c^2=2k^2$
$a_3^2+d^2=2l^2$

we can then say

$\left(a_1a_2a_3\right)^2+\left(ba_2a_3\right)^2=2\left(ja_2a_3\right)^2$
$\left(a_2a_1a_3\right)^2+\left(ca_1a_3\right)^2=2\left(ka_1a_3\right)^2$
$\left(a_3a_1a_2\right)^2+\left(da_1a_2\right)^2=2\left(la_1a_2\right)^2$

So we now have a number that satisfies our equation three ways

Now we need the pairs of these other three numbers to satisfy the equations

$\left(ba_2a_3\right)^2+\left(ca_1a_3\right)^2=2p^2$

$\left(ba_2a_3\right)^2+\left(da_1a_2\right)^2=2q^2$

$\left(da_1a_2\right)^2+\left(ca_1a_3\right)^2=2r^2$

You might notice that we can simplify these equations to

$\left(ba_2\right)^2+\left(ca_1\right)^2=2p'^2$
$\left(ba_3\right)^2+\left(da_1\right)^2=2q'^2$

$\left(da_2\right)^2+\left(ca_3\right)^2=2r'^2$

If we look at the first equation and our starting equations, we see

$a_1^2+b^2=2j^2$

$a_2^2+c^2=2k^2$

$\left(ba_2\right)^2+\left(ca_1\right)^2=2p'^2$

The first two equations describe Pythagorean triples and the third equation describes a Pythagorean triple made of the previous two Pythagorean triples. So it is possible to "multiply" two Pythagorean triples together?

If we look back to



then we can see that
$23^2+289^2=2*205^2$
$527^2+289^2=2*425^2$
can be multiplied to get
$\left(289*23\right)^2+\left(289*527\right)^2=\left(373*289\right)^2$



this week's calculator will be up shortly


Friday, April 7, 2017

Week 9

Last week, we divided up all primitive Pythagorean triples into classes based on the value $b-a$ where $b$ is the long leg of triangle and $a$ is the short leg of the triangle. What we learned from this is that triangles of a certain class start at $\left(r,s\right)$ and keep extending onto $\left(2r+s,r\right)$, $\left(2\left(2r+s\right)+r,2r+s\right)$.... (This is actually related to a recurrence relation called Pell numbers)

I wondered if we could locate the first triangle from each class, so I asked myself when there is nothing before an $\left(r,s\right)$. The term before $\left(r,s\right)$ would be $\left(s,r-2s\right)$. This is not a valid value when at least one of the parts is less than $1$ or when the first half is less than the second half

If we look at this first condition, we see that either $s$ or $r-2s$ is less than $0$. If we are given that $\left(r,s\right)$ is valid then we know that $s$ is greater than $0$. This only leaves the equation $r-2s<0$ or $r<2s$

The other condition gives the equation $s<r-2s$ or $r>3s$

We see that both of these equations seem to describe lines on a graph and if we look back to our r vs. s spreadsheet, we see


This means that everything above the blue line and everything below the red line is the first of its class in that method of finding the next triple of the same class. You can also see that the triples between the two lines already had a smaller triple of the same class outside of the lines.

This actually helped cut down on calculation time for a calculator I made, but to explain that I first need to explain something else.

Let's say we draw out a Pythagorean triple as a triangle


We could subtract some $k$ from both $b$ and $a$ and not change its class since $b-a=\left(b-k\right)-\left(a-k\right)$ (although this new triangle might not represent a Pythagorean triple) 



And we could do this for any value of $k$, so we know triangles of the same class would have their hypotenuse from the origin to anywhere along this line.


Remember that this is for triangle with the same value for $b-a$. If we instead look at triangles with the same value for $b+a$, we get


This is important because if we review our arithmetic sequences


we see that there are many triangles that share their $b-a$ or $b+a$ class with another triangle. If we try drawing this out like we did earlier, we get


To clean this up, we will only show the endpoint of each hypotenuse


This includes almost all the requirements for a 3x3 magic square of squares, but we will worry about the last bit later.

Now, I will describe my program.

First, it collected the first thousand triples of a certain $b-a$ class

Next, for every pair of triples, it essentially took the two triples


and used them to calculate the third triple


And so I got solutions to some classes. For example, for the class $23$, I got the three triples $\left(119,408,425\right)$, $\left(275,252,373\right)$, and $\left(156,133,205\right)$

These give us $289^2, 425^2, 527^2$,  $23^2, 373^2, 527^2$, and $23^2, 205^2, 289^2$

We notice that we can take this


and fill in the values


So we have found out how to generate this part of a magic square of squares, but we have still not yet figured out the other parts of the magic square of squares

This week's calculator will be up shortly

Friday, March 31, 2017

Week 8

This week, instead of looking at specific families of Pythagorean triples, I looked at all Pythagorean triples. I'll explain how I got there by starting from the beginning.

So I reviewed this thing:


my visual representation of the 6 arithmetic progressions of squares I needed to find to construct a 3x3 Magic Square of Squares. Maybe I could start out by finding a smaller piece like this:


This would entail finding 3 Pythagorean triples and using our method of converting Pythagorean triples into arithmetic progressions of squares.

If we have a Pythagorean triple $\left(a,b,c\right)$, then our arithmetic progression is $\left(b-a\right)^2,a^2+b^2,\left(a+b\right)^2$. Note that the difference between the first and last term is $4ab$. If we give these triples names, then we can start writing equations.


We know that $4ab=4mn+4xy \Rightarrow ab=mn+xy$

We also know that $m+n=y-x \Rightarrow y=m+n+x$

By substituting, this gives us $ab=mn + mx + nx + x^2=\left(m+x\right)\left(n+x\right)$


We also know that $b-a=n-m \Rightarrow n=b-a+m$

By again substituting, we get $ab=\left(m+x\right)\left(b-a+m+x\right)$

If we let $k=m+x$, we get $ab=k\left(b-a+k\right)$

The only possible value for $k$ is $a$, so we see that $m+x=k=a$


If we instead rearrange $b-a=n-m$ as $m=n+a-b$, substitute, and let $l=n+x$, we get
$ab=\left(l+a-b\right)l$, giving us that $n+x=l=b$


We already knew that that $b-a=n-m$ (since the Fermat family had $b-a=1$, this is sort of a more general version), but we learned that $b-n=a-m=x$

If I look at all Pythagorean triples, I might be able to divide them up into classes based on their $b-a$ value. So how does one look at all Pythagorean triples?

Well, if we pick two positive integers $r$ and $s$ where $r>s$, then we can generate a Pythagorean triple $\left(r^2-s^2,2rs,r^2+s^2\right)$. If we put $r$ and $s$ on the axes of an Excel chart, and write out the legs of each triangle, we get

Note that the grayed-out boxes contain non-primitive triples and that the upper right corner is empty because $r>s$ and that this goes only $r<15$

Since we want to divide these up into classes based on $b-a$, let's display that instead


Now, let's highlight Fermat family triples



If we look at the $\left(r,s\right)$ values for Fermat family triples we get
$\left(2,1\right)$
$\left(5,2\right)$
$\left(12,5\right)$

By now you may have noticed some patterns


$\left(2,1\right)$
$\left(2*2+1,2\right)=\left(5,2\right)$
$\left(5*2+2,5\right)=\left(12,5\right)$

And more importantly, this pattern holds for other numbers (although there seem to be 2 $\left(r,s\right)$ starting points needed)

So we have divided up Pythagorean triples into different classes. Using this will make it much easier to find $b-n=a-m=x$

This week's calculator will be up shortly






Friday, March 24, 2017

Week 7

So last week (or the week before that) we learned how to multiply one number by another number


But in all seriousness, we learned that if we have a number of the form $2M^2-1$ where $M$ is an integer, then $2\left(M+K\right)^2-1$ describes it's multiples as long as $K \equiv 0$ or $-2M \bmod 2M^2-1$. By adding $K=Q\left(2M^2-1\right)$ or $K=Q\left(2M^2-1\right)-2M$ we are effectively multiplying the number by $\left(2MQ+1\right)^2-2Q^2$ or $\left(2MQ-1\right)^2-2Q^2$ (Sorry if I changed the name of certain variables).

Let us remind ourselves of the reason we are finding the multiples of $2M^2-1$. We were able to find arrow relations between Plato triples using

$$Plato \rightarrow Plato\\\boxed{\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{2L^2-1}\\i_{from}=L-1\\i_{to}=J}$$

We wanted to know if we could change our values of $J$ and $L$ such that $M_{from}$ and $M_{to}$ don't change. For example, when $J=L$, you can add any number to both

$$\frac{1}{1}=\frac{2\left(1\right)^2-1}{2\left(1\right)^2-1}=\frac{2\left(2\right)^2-1}{2\left(2\right)^2-1}\cdots$$

This is the reason why every Plato triple has a right arrow going to the next term in the Stifel sequence. By finding more of these, we might be able to fully describe the arrow relations between two multiples

So we need to multiply two numbers by the same $\left(2MQ+1\right)^2-2Q^2$ or $\left(2MQ-1\right)^2-2Q^2$

If we say $\left(2MQ+1\right)^2-2Q^2=7$, then we are also saying that $Q\left(2QM^2-Q+2M\right)=3$. Since $Q$ and $M$ are integers we see that the only solution is $Q=1, M=1$. (We started with $7$ because multiplying by $1$ doesn't make sense and the numbers between can never divide a number of the form $2M^2-1$)

If we say $\left(2MQ-1\right)^2-2Q^2=7$, then we are also saying that $Q\left(2QM^2-Q-2M\right)=3$. Since $Q$ and $M$ are integers we see that the only solutions are $Q=1, M=2$ and $Q=3, M=1$

If we interpret these solutions, we see that the only numbers we can multiply by $7$ and $1$ and $7$. (One of those solutions was basically a duplicate) We can see that $2\left(1\right)^2-1=1\rightarrow 7=2\left(2\right)^2-1$ and that $2\left(2\right)^2-1=7\rightarrow 49=2\left(5\right)^2-1$

I will continue exploring this with numbers higher than $7$, but here is a cool pattern I found related to $2M^2-1$. Firstly, here is a list of $2M^2-1$ up to $M=30$

1
7
17
31
49
71
97
127
161
199
241
287
337
391
449
511
577
647
721
799
881
967
1057
1151
1249
1351
1457
1567
1681
1799

We start at $1$ and move forward $\sqrt{1}$ to $7$. $7^2=49$, the next perfect square after $1$.

If we take $49$ and move forward $\sqrt{49}$ to $287$, we might notice that $287=7*41$. And it just so happens that $41^2=1681$ is the next perfect square.

I haven't looked at why this is, but I suspect it is a side effect of $2M^2-1=N^2$ being a Pellian equation.


Another interesting pattern occurs when we consider number we can multiply $2M^2-1$ by

If we consider $M=2$, the first 10 numbers we can multiply by are

7.0
23.0
41.0
73.0
103.0
151.0
193.0
257.0
311.0
391.0

If we consider $M=3$, the first 10 numbers we can multiply by are

23.0
47.0
113.0
161.0
271.0
343.0
497.0
593.0
791.0
911.0

You may have noticed that 23 is second in $M=2$ and first in $M=3$. This pattern actually continues, so hopefully I will be able to exploit it and discover more patterns

This week's calculator will be up shortly


r:

s:


Friday, March 17, 2017

Week 6

This week, there is no post because...

I'm on break!


But next week I will continue my adventure!

(for the 3x3 magic square of squares, not cookies)

Friday, March 10, 2017

Week 5

Last week, we looked at ways to find out where arrows go between
$$Plato \rightarrow Plato\\\boxed{\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{2L^2-1}\\i_{from}=L-1\\i_{to}=J}$$
$$Pythagoras \rightarrow Pythagoras\\\boxed{\frac{m_{from}}{m_{to}}=\frac{J^2-2}{L^2-2}\\i_{from}=\frac{L-3}{2}\\i_{to}=\frac{J-1}{2}\\J,L\text{ are odd}}$$
$$Plato \rightarrow Pythagoras\\\boxed{\frac{m_{from}}{m_{to}}=\frac{J^2-2}{2L^2-1}\\i_{from}=L-1\\i_{to}=\frac{J-1}{2}\\J\text{ is odd}}$$
$$Pythagoras \rightarrow Plato\\\boxed{\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{L^2-2}\\i_{from}=\frac{L-3}{2}\\i_{to}=J\\L\text{ is odd}}$$

But what does this even mean? We could plug in values for $J$ and $L$, but we can't do this infinitely, so we need to strategically hold certain values constant.

Let's hold $i_{from}$ and $i_{to}$ constant. For example, let's see what arrows go from $i_{from}=1$ and $i_{to}=3$ for $Plato \rightarrow Plato$

$1=i_{from}=L-1 \Rightarrow L=2$
$3=i_{to}=J \Rightarrow J=3$

$\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{2L^2-1}=\frac{17}{7}$
This means that for this example that
$\left(m_{from},m_{to}\right) = \left(17,7\right),\left(34,14\right)\cdots$

However, this is not always so simple. Consider the arrows from $m_{from}=8$ to $m_{to}=14$

$8=i_{from}=L-1 \Rightarrow L=9$
$14=i_{to}=J \Rightarrow J=14$

$\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{2L^2-1}=\frac{391}{161}$
So that means

$\left(m_{from},m_{to}\right) = \left(391,161\right),\left(782,322\right)\cdots$
Right?

Actually, no.
$\frac{391}{161}$ can be simplified to $\frac{17}{7}$ and gives

$\left(m_{from},m_{to}\right) = \left(17,7\right),\left(34,14\right)\cdots$

So it turns out that
$$p\text{ is a multiple of } \frac{2J^2-1}{gcf\left(2J^2-1,2L^2-1\right)}$$

$$q\text{ is a multiple of } \frac{2L^2-1}{gcf\left(2J^2-1,2L^2-1\right)}$$

Dividing by the greatest common factor is a way of showing that we simplified the numerator and denominator. To find the GCF, we could use the Euclidean algorithm (which last week's calculator uses), but we cannot calculate this for infinitely numbers. We could also use $\bmod$ to see what we can find.

Let's says that $2M^2-1$ is divisible by $n$
$2M^2-1 \equiv 0 \bmod n$
If we add $K$ to $M$ we get
$2\left(M+K\right)^2-1 \equiv 0 \bmod n$
We know that the difference between these two is $0 \bmod n$
$2\left(2MK+K^2\right) = 2\left(K\right)\left(2M+K\right) \equiv 0 \bmod n$
Since $2M^2-1$ is odd and $n$ divides $2M^2-1$, $n$ is odd
this means $2$ is never $0 \bmod n$ and either
$K \equiv 0 \bmod n$ or $K \equiv -2M \bmod n$

This means that if $2J^2-1$ and $2L^2-1$ are both divisible by a number $n$, then they differ by either $0 \bmod n$, $2J \bmod n$, or $2L \bmod n$

This is as far as I got with holding $i_{from}$ and $i_{to}$ constant


Now we will consider holding $i_{from}$ and $m_{from}$ constant

From $\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{2L^2-1}$, we get
$m_{from}\left(2L^2-1\right)=m_{to}\left(2J^2-1\right)$
This means that there are a finite number of arrows emanating from a triple
The number of arrows is the number of divisors $m_{from}\left(2L^2-1\right)$ has that are of
the form $2J^2-1$

This seemed somewhat difficult, so I set it aside for now


Next we will hold $m_{from}$ and $m_{to}$ constant

If we have $\frac{m_{from}}{m_{to}}=\frac{2J^2-1}{2L^2-1}$ and found values that work for it,
then we should be able to multiply $2J^2-1$ and $2L^2-1$ by the same number and keep
$m_{from}$ and $m_{to}$ constant.

Earlier we said that if $2M^2-1$ is divisible by $n$, then adding $K$ to $M$ would result in a number also divisible by $n$ as long as $K \equiv 0$ or $-2M \bmod n$

What if $n=2M^2-1$?

$2M^2-1$ divides $2M^2-1$ and if we let $K = Q\left(2M^2-1\right)$ or $Q\left(2M^2-1\right)-2M$ then we find multiples of $2M^2-1$. We essentially multiplied $2M^2-1$ by a number.

What number is this? If we substitute our values of $K$ into $2\left(M+K\right)^2-1$ and divide by $2M^2-1$, we get
$$\left(2QM+1\right)^2-2Q^2$$
or
$$\left(2QM-1\right)^2-2Q^2$$

So if we want to multiply $2J^2-1$ and $2L^2-1$ by the same number, we must ask when
$\left(2QM+1\right)^2-2Q^2=\left(2Q'M'+1\right)^2-2Q'^2$

This is as far as I got, but I do plan on looking at the previous equation as Pellian to find solutions (note that $\left(2QM+1\right)^2-2Q^2$ kinda looks like $X^2-2Y^2$)

Next week will be my Spring Break

I will soon be working a lot with Pellian equations, and I might use Brahmagupta's identity to compose Pellian equations together. Pellian equations are equations of the form
$$X^2-NY^2=k$$

Brahmagupta discovered that if you have
$X_1^2-NY_1^2=k_1$
$X_2^2-NY_2^2=k_2$
then the Pellian equations
$\left(X_1X_2+NY_1Y_2\right)^2-N\left(X_1Y_2+X_2Y_1\right)^2=k_1k_2$
$\left(X_1X_2-NY_1Y_2\right)^2-N\left(X_1Y_2-X_2Y_1\right)^2=k_1k_2$
are true

This calculator will allow you to compose two Pellian equations together


X1:

Y1:

X2:

Y2:

N: