PDA

View Full Version : 3rd Power Diophantine Generator

Enola Straight
09-07-2010, 04:48 PM
There is a generator to create perfect pythagorean triples...3:4:5, 5:12:13...
http://www.mathreference.com/num-zext,pt.html
for x^2+y^2=z^2,
x=u^2-v^2
y=2uv
z=u^2+v^2
when u and v are coprime.

For diophantine equasions of the third power
http://mathworld.wolfram.com/DiophantineEquation3rdPowers.html
is there a similar generator?

Lance Turbo
09-08-2010, 08:43 AM
Isn't equation (8) on the linked page such a beast?

Enola Straight
09-08-2010, 11:40 AM
On the Wolfram Mathpage? Ugh, i got lost in the alphabet soup.:rolleyes:

I figured, to generate A^3+B^3+C^3=D^3 involved defining A,B,C, and D as functions of u,v,and w, as is the case with pythagorean triples.

Lance Turbo
09-08-2010, 01:35 PM
Yeah equation (8) on the Wolfram page is:

(3 x^2 + 5 x y - 5 y^2)^3 + (4 x^2 - 4 x y + 6 y^2)^3 + (5 x^2 - 5 x y - 3 y^2)^3 = (6 x^2 - 4 x y + 4 y^2)^3

So let:
A = 3 x^2 + 5 x y - 5 y^2
B = 4 x^2 - 4 x y + 6 y^2
C = 5 x^2 - 5 x y - 3 y^2
D = 6 x^2 - 4 x y + 4 y^2

(with coprime x and y if you like)

Then A^3 + B^3 +C^3 = D^3.

Enola Straight
09-08-2010, 05:04 PM
The reason I was wondering is...well...I'd like to take an amateur crack at the Integer Brick problem:
http://www.durangobill.com/IntegerBrick.html
I figure, If I enter The 3rd power diophantine generator and the 2nd power diophantine (pythagorean triple) generator as variables in linear programming:
http://en.wikipedia.org/wiki/Linear_programming
http://vinci.inesc.pt/lp/
then this Great Unsolved Math Problem should become a simple, if tedious, algebra problem.

Chronos
09-08-2010, 05:11 PM
For that, you don't want a 3rd power Diophantine equation; you want a 2nd power one with three terms. That is, you want integers a, b, and c such that a^2 + b^2 = d^2, b^2 + c^2 = e^2, a^2 + c^2 = f^2, and a^2 + b^2 + c^2 = g^2, where d, e, f, and g are all also integers. There's no cubes here.

dzero
09-08-2010, 05:48 PM
Sometimes you people just fuckin' scare me.

Enola Straight
09-08-2010, 10:07 PM
OK.

According to this:
The generators for A^2+B^2+C^2=D^2 are

a=2mp
b=2np
c=p^2-(m^2+n^2)
d=p^2+(m^2+n^2).........given that m+n+p=(mod 2) and (m,n,p)=1
(whatever that means:confused::rolleyes:)

AND

a=2mp+2nq
b=2np-2mq
c=p^2+q^2-(m^2+n^2)
d=p^2+q^2+(m^2+n^2)

So...

If having the triple and quadruple generators, AND having

A^2+B^2=D^2
A^2+C^2=E^2
B^2+C^2=F^2
A^2+B^2+C^2=G^2

as the dimensions of the Brick, do we have enough information to input into a linear programming matrix?

Lance Turbo
09-09-2010, 08:42 AM
You know you don't even need the quadruple generator.

Combine:

A^2+B^2=D^2
and
A^2+B^2+C^2=G^2

To get:

D^2+C^2=G^2

Then you need to solve four pythagorean triples simultaneously:

A^2+B^2=D^2
A^2+C^2=E^2
B^2+C^2=F^2
D^2+C^2=G^2

In fact these are equivalent to equations (5) - (8) here -> (http://mathworld.wolfram.com/PerfectCuboid.html).

Can I ask you what it is that you are optimizing that suggests to you that linear programming will lead to a solution?

Lance Turbo
09-09-2010, 08:58 AM
Also, which of the equations posted thus far do you feel are linear?

CalMeacham
09-09-2010, 09:25 AM
The reason I was wondering is...well...I'd like to take an amateur crack at the Integer Brick problem:

One way to "solve" the Integer Brick (for integral sides and an integral body diagonal, but not necessarily face diagonals) is to realize that the square of (a + b) is a^2 +2ab + b^2. So if two sides are a and b and you arrange that the square of the third side is 2ab = c^2, the body diagonal will be a + b.

The most obvious solution is a = 1, b = 2, c = 2, with diagonal 3 (and multiples of these), but this is not the only solution you can generate. You can also get a = 2 b = 9, c = 6 with diagonal 11, for instance. You can use this to generate an infinite number of solutions, not all of them multiples of lower-order solutions. The only trick is choosing the value of 2 ab = c^2, and the rest falls into place.

Enola Straight
09-09-2010, 10:12 AM
Since the problem could be stated like this:

A^2+B^2=D^2
A^2+C^2=E^2
B^2+C^2=F^2
D^2+C^2=G^2
?

I thought the solution could be arrived at with matrix mathematics, instead of linear programming:
http://en.wikipedia.org/wiki/Matrix_%28mathematics%29
but obviously you must first have digits to manipulate, not algebraic variables.

Lance Turbo
09-09-2010, 10:26 AM
I halfway suspected that you were really trying to turn this into a linear algebra problem and that linear programming was a red herring. And as you've realized, linear algebra is used to solve (systems of) linear equations and is not really suited to this problem.

Enola Straight
09-09-2010, 12:34 PM
huh.

I guess the only thing left is a spreadsheet program with a TON of memory.

Brute-force exhaustive search of every pythagorean triple with digits from 1 to a quadrillion :eek:

I believe they already searched up to 1 trillion.

CalMeacham
09-09-2010, 12:40 PM
I guess the only thing left is a spreadsheet program with a TON of memory.

Brute-force exhaustive search of every pythagorean triple with digits from 1 to a quadrillion

Not true -- look at my post above. It is an infallible method of generating Pythagorean triples (quadruples?). And it doesn't require that you test all possible triples.

I suspect that it won't generate all possible integral pytrhagorean triples (quadruples?). But then again, the method you cite in your OP demonstrably doesn't generate all Pythagorean triples of the form a^2 + b^2 = c^2.

Lance Turbo
09-09-2010, 12:58 PM
huh.

I guess the only thing left is a spreadsheet program with a TON of memory.

Brute-force exhaustive search of every pythagorean triple with digits from 1 to a quadrillion :eek:

I believe they already searched up to 1 trillion.

Another option remains. You could prove that no solution exists. The advantage to this approach is that I strongly suspect that it is the only thing that has a non-zero probability of meeting success.

Indistinguishable
09-09-2010, 01:13 PM
But then again, the method you cite in your OP demonstrably doesn't generate all Pythagorean triples of the form a^2 + b^2 = c^2.
The OP's method generates all Pythagorean triples in "lowest terms"; to generate all Pythagorean triples more generally, one just takes all the multiples of these.

CalMeacham
09-09-2010, 01:23 PM
The OP's method generates all Pythagorean triples in "lowest terms"

AFAIK, that's true. And it generates many of the multiples of the "lowest terms", but not all of the multiples, as I've demonstrated myself. Although it generates all of the lowest Pythagorean triples i know of (at least in "lowest terms"), I must admit that I don't know that it will generate all of the triples in "lowest terms".

Chronos
09-09-2010, 01:26 PM
huh.

I guess the only thing left is a spreadsheet program with a TON of memory.
You don't need a ton of memory, so long as you have some systematic way of going through the possible solutions. You don't have to take up memory storing one that didn't work; you just throw it out and move on to the next candidate. And each individual candidate takes up a small amount of memory.

Now, what you do need is a different way of managing your memory, since the standard integer data types aren't large enough for numbers this big. But you can get packages to facilitate this; others have solved that problem before.

09-09-2010, 01:28 PM
The reason I was wondering is...well...I'd like to take an amateur crack at the Integer Brick problem:...
then this Great Unsolved Math Problem should become a simple, if tedious, algebra problem.Gosh darn it. Last night, after a couple of drinks, I came up with a simple proof that no Integer Brick exists, QED.

It was so simple, I didn't even bother to write it down. Needless to say, after a couple more, I wish I had. :smack:

Lance Turbo
09-09-2010, 02:53 PM
Just for fun I wrote a little program in Mathematica to implement Cal's method so I could brute force the crap out of this.

It checks all triples (l, w, h) = (i, a, ( i^2)/(2a)) where i is even and a is odd.

It's up to about i = 1,000,000 now with no luck. Of course I'm pretty I haven't checked anything that hasn't been previously checked by people who have spent more time on this problem than I have.

I'll let it run for a while, but I don't believe a solution exists so I'll probably kill it sooner rather than later.

Code below. Mathematica is effin' sweet.

CheckTrip[{a_, b_, c_}] := (Sqrt[a^2 + b^2] == Floor[Sqrt[a^2 + b^2]]) &&
(Sqrt[a^2 + c^2] == Floor[Sqrt[a^2 + c^2]]) &&
(Sqrt[c^2 + b^2] == Floor[Sqrt[c^2 + b^2]])

i = 2;

While[Not[Or @@ (CheckTrip /@ ({i, #, i^2/(2 #)} & /@ Select[Divisors[i^2/2], OddQ]))], If[Mod[i, 10000] == 0, Print[i]]; i = i + 2]

09-09-2010, 03:02 PM
...

I'll let it run for a while, but I don't believe a solution exists so I'll probably kill it sooner rather than later. ...Trust me on this and move on.

CalMeacham
09-09-2010, 03:12 PM
Just for fun I wrote a little program in Mathematica to implement Cal's method so I could brute force the crap out of this.

It checks all triples (l, w, h) = (i, a, ( i^2)/(2a)) where i is even and a is odd.

It's up to about i = 1,000,000 now with no luck.

??

What do you mean "no luck"? You haven't found any other quadruples?

There's a easier way. In order for 2ab to be a square, there are two possibilities:

1.) a = 2e^2 and b = f^2, so c = 2ef

or

2.) a = 2e and b = ef^2 so c = 2ef

Just plug in values for e and f in the above and chug. The simplest case of 1, 2, 2 has e = 1 and f = 1 in the either case.

Lance Turbo
09-09-2010, 03:25 PM
I had no luck solving the perfect cuboid problem. I had plenty of luck finding pythagorean quads.

This program takes an even i and generates every triple (l, w, h) = (i, a, ( i^2)/(2a)) where a is odd. Thus l^2 = 2 w h, so we know the long diagonal of the rectangular solid is an integer. At this point we only have to check if the face diagonals are integers. If they are the program stops, otherwise i is incremented by 2 and the program marches on.

Hari Seldon
09-09-2010, 03:58 PM
The OP's method generates all Pythagorean triples in "lowest terms"

AFAIK, that's true. And it generates many of the multiples of the "lowest terms", but not all of the multiples, as I've demonstrated myself. Although it generates all of the lowest Pythagorean triples i know of (at least in "lowest terms"), I must admit that I don't know that it will generate all of the triples in "lowest terms".

It is well-known (and has been known, although it is not clear if it was proved, for 2500 years) that you get all primitive Pythagorean triples (no common divisor) if you take numbers u > v > 0 and of opposite parity and let x = 2uv, y = u^2 - v^2, z = u^2 + v^2. As far as non-primitive ones, well in order that (x,y,z) be generable, z = u^2 + v^2 would have to be the sum of two squares. That necessary condition might be sufficient. At any rate you can generate (6,8,10), but not (9,12,15).

Here is amusing variation. You can generate all primitive integer-sided triangles with a 60 degree angle by a slightly more complicated generating formula, but no integer-sided triangle can contain a 30 degree angle.

Der Trihs
09-09-2010, 04:20 PM
Sometimes you people just fuckin' scare me.Ha, when I saw the thread title I thought "Oh, great, has someone been sucked into believing some perpetual motion machine scam again?"

"Can the 3rd Power Diophantine Generator solve our energy woes?" is what I was envisioning.