# Solving the equation X^4 - DY^4 = Z^4 [closed]

Let's have the equations $$12^4 - DY^4 = 7^4$$ and $$24^4 - DY^4 = 19^4$$. For what values of D and Y do these equations have a solution?

Secondly, what little trick is required to obtain solutions of the equation $$X^4 - DY^4 = Z^4$$ where X, D, Y, Z are positive integers with a GCD of 1?

HINT: Let's have the quantity $$4f^3 + 6f^2 + 4f + 1$$. If we set $$f = (k - 1 / 2)$$ then we obtain the cubic equation $$4k^3 + k$$. Let's set $$4k^3 + k = m$$ where m a positive integer. If this equation gives a rational solution, eg. d/p, then from there on you have to figure out how to solve the equation $$X^4 - DY^4 = Z^4$$.

2nd HINT: $$24^4- 322.328 * 5^4 = 19^4$$

The equations, in order of appearance: 12^4 - D * (Y^4) = 7^4, then 24^4 - D * (Y^4) = 19^4, then X^4 - D * (Y^4) = Z^4
Equations from the hint, in order of appearance: 4f^3 + 6f^2 + 4f + 1, then f = (k - 1 / 2), then 4k^3 + k, then 4k^3 + k = m, then X^4 - D * (Y^4) = Z^4
Equation from the second hint: 24^4 - 322.328 * 5^4 = 19^4

• $12^4 - 7^4 = 18335$, which is the product of the primes 5, 19 and 193. Therefore, $D = 18335$ and $Y = 1$. $24^4 - 19^4 = 201455$, that leads to a contradiction?! Nov 19 '20 at 20:52
• Could you clarify (1) whether "... have a GCD of 1" means that there isn't a nontrivial factor of all of them, or that they're pairwise coprime, and (2) whether you're asking for ways to find all (x,y,z,d) satisfying the condition, or some (x,y,z,d), or something else, e.g. some (x,y,z) given d for which any exist? Nov 19 '20 at 20:52
• @ Glorfindel. your ansewrs are incorect you have to try harder to find the values of D,Y. Nov 19 '20 at 21:31
• I don't get how D does not have an integer value, yet X, D, Y, Z are positive integers. Nov 19 '20 at 21:54
• Plainly from the first 2 equations $DY^4 = 18335$ but $DY^4 = 201455$ so @Glorfindel 's contradiction stands. The second question uses a $D$ with different conditions from the first question. Are the $D$ and $Y$ in the first question different from each other – are there two sets of $D,Y$? So is question 1 itself in two parts? Nov 19 '20 at 22:56

I assume you found an interesting relationship between the quartic equation $$x^4-dy^4=z^4$$ and the cubic polynomial $$4f^3+6f^2+4f+1$$ by yourself, which is good for you. But such finding doesn't warrant a good puzzle, especially in the form of such a broad question (since it is very likely that there are multiple ways to approach the problem, some of which may be much simpler than you thought).

For this problem, all three parts (counting the two equations in Q1 as two separate parts) can be solved with basic number theory.

### Part 1a/1b

As Glorfindel calculated already, the equations to solve are $$dy^4 = 18335$$ and $$dy^4 = 201455$$ respectively. Both numbers are the product of three distinct primes, namely $$18335 = 5 \times 19 \times 193$$ and $$201455 = 5 \times 43 \times 937$$.

If $$d$$ and $$y$$ are limited to integers,

they have only one solution each, since neither is divisible by any prime fourth power. Therefore the only solutions are $$d=18335, y=1$$ and $$d=201455, y=1$$ respectively.

If they can be anything broader than that, there are infinitely many solutions:

Consider the first equation $$dy^4 = 18335$$. For any value of $$y \ne 0$$, $$d$$ can have the value of $$18335\over y^4$$. This holds for rationals (for any rational $$y$$, $$d$$ is also rational), and for reals (ditto). Even if we limit them to finite decimals, we can pick any $$y=2^n 5^m$$ where $$n,m$$ are integers (can be positive, 0, or negative).

### Part 2

If you mean by "GCD is 1" that $$GCD(d,x,y,z) = 1$$,

just plug in $$y=1$$ and choose any integers for $$x$$ and $$z$$. Then evaluate the value of $$d=x^4-z^4$$. Then the GCD condition is trivially satisfied (since GCD of 1 and any other integer is 1).

If you mean that the numbers are pairwise coprime, i.e. $$GCD(d,x) = GCD(d,y) = \cdots = GCD(y,z) = 1$$,

pick two coprime positive integers $$x$$ and $$z$$, so that $$x > z$$. Then we get $$dy^4 = x^4 - z^4$$. Since $$GCD(x,z) = 1$$, it follows that $$GCD(x^4, z^4) = GCD(x^4, x^4-z^4) = GCD(z^4, x^4-z^4) = 1$$. This means that, if $$d$$ and $$y$$ are coprime, all four numbers are pairwise coprime. One trivial way to pick $$d$$ and $$y$$ is $$d=x^4-z^4$$ and $$y=1$$. For a non-trivial solution, check if the prime factorization of $$x^4-z^4$$ contains a term $$p^{4k}$$ (i.e. the number should be divisible by $$p$$ exactly $$4k$$ times). If such term exists, we can find another solution: $$y=p^k, d=(x^4-z^4)\div p^{4k}$$ satisfying $$GCD(d,y) = 1$$.

It is even possible to generate infinitely many non-trivial solutions ($$y>1$$):

Pick any odd prime $$p$$. Choose $$x$$ and $$z$$ so that $$x+z=p^4$$ and $$GCD(x,p) = GCD(z,p) = 1$$. Then $$GCD(x+z,x-z) = 1$$ and $$GCD(x^2+z^2, x^2-z^2)=1$$, so we have $$p^4$$ in the prime factorization of $$x^4-z^4$$. Then let $$y=p$$ and $$d=(x^4-z^4)\div y^4$$.

Demonstration: Let $$p=3$$, and choose $$x=41, z=40$$ so that $$x+z = 81 = 3^4$$. Then $$x^4-z^4 = 41^4-40^4 = 265761 = 3^4 \times 17 \times 193$$, exactly as predicted. So we can pick $$y=3, d=17\times 193 = 3281$$, and the resulting equation is $$41^4 - 3281 \times 3^4 = 40^4$$, and you can easily see that the four numbers are pairwise coprime.

This construction also works if we choose $$x-z=p^4$$ instead or we choose any odd number $$p>1$$, as long as $$GCD(x,p) = GCD(z,p) = 1$$.

For the first hint, if $$4k^3 + k = m$$ with $$m$$ an integer has a rational solution for $$k$$, it is necessarily an integer $$n$$ or a half-integer $$\frac{n}2$$. I don't get how $$m=15, k=\frac32$$ gives rise to the equation $$5^4 - 34 \times 2^4 = 3^4$$ (which was mentioned in OP's comment), but $$m=34, k=2$$ surely does:

$$(f+1)^4 - f^4 = 34 \\ (k+\frac12)^4 - (k-\frac12)^4 = 34 \\ \left( \frac52 \right)^4 - \left( \frac32 \right)^4 = 34 \\ 5^4 - 3^4 = 34 \times 2^4 \\ 5^4 - 34 \times 2^4 = 3^4$$

For $$m=15, k=\frac32$$, I get this:

$$(k+\frac12)^4 - (k-\frac12)^4 = 15 \\ 2^4 - 1^4 = 15 \\ 2^4 - 15 \times 1^4 = 1^4$$

...which is a "trivial" solution, as $$y=1$$.

Also, my last part of Part 2 solution can be extended to include these as well (as the GCD condition seems to be $$GCD(d,x,y,z)=1$$):

Allow $$p$$ to be even numbers too, and keep the $$GCD(x,z) = 1$$ constraint. By picking $$p=2$$ and using $$x-z=p$$, all solutions intended by OP can be generated in this way.

• @VassilisParassidis Your hint 2 is just one correct answer. I can give you many others: $1145.9375 \times 2^4$, $1.8335 \times 10^4$, $0.0469376 \times 25^4$, and so on. If you're rejecting my solution for some reason, you need to include that reason as a condition in the original question. Nov 20 '20 at 7:01
• I made a mistake, Instead of $4k^3 +4k=m$ it should read $4k^3+k=m$. If $m=15$ then one root of this equation is $3/2$ from which we formulate the equation $5^4-34*2^4=3^4$. The answer to the first part of my question is $12^4 - 29.336 * 5^4 = 7^4$. I specified that $D$ is a decimal number. The other solution is contained in HINT 2.The value of $D$ is obtained with a special formula. Nov 20 '20 at 7:12
• @VassilisParassidis Can you explain why $1145.9375 \times 2^4$ is rejected? Because 1145.9375 is a decimal number just like 322.328 or 29.336. Nov 20 '20 at 7:14
• In the equations I gave, only $D$ is allowed to be a decimal. Nov 20 '20 at 7:18
• @VassilisParassidis The worst part of the "puzzle" is that guessing a special formula when there is a more general one (or guessing one when there are multiple equivalent ways to get the same results) is not fun. Nov 20 '20 at 7:54