# How would I solve this polynomial equation system?

This topic is 1248 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hi, I wonder wheather you might know how to solve following quadratic equation system of 3 unknowns (or help me to solve it):

x- 2*x*y + y2  =2

y- 2*y*z + z2  =2

z- 2*z*x + x2  =2

I believe it is a zero dimensional system, with two solving sets of (x,y,z)

##### Share on other sites

Though there is a typo, it should read:

x-y = sqrt(2) or  x-y = -sqrt(2)

y-z = sqrt(2) or  y-z = -sqrt(2)

z-x = sqrt(2) or  z-x = -sqrt(2)

But still though, there seems to be no solution :

y= x - sqrt(2)  put to second equation

x - sqrt(2) - z = sqrt(2) so

x - z = 2*sqrt(2) and third equation says

z-x=sqrt(2) meaning z -z-2*sqrt(2)=sqrt(2)

But I find it very surprising, because it negates this assumption, that should prove this system is solvable :

(bold are vectors R3 , normal letters are scalars, vectors can index[1-3] as to scalar)

:

polite parametric equation of a line in 3d is P+D*x, x any R, P a defined point, and D a defined unit vector

Now consider a unit cube cut diagonaly so that it creates 2 three sided pyramids, the base of both of the pyramids is a triangle with all sides equal to sqrt(2).

Take one of the pyramids (omit the second) and the lines emited from the peak (the corner originaly) are three lines, that can be parametricaly

desribed with  P vector identical for all three and some three unit vectors that we only know about are orthogonal to eachother.

This yields three parametric lines as

P+D*x  ; P+G*y ; P+F*z . Now statement is that  there are three vectors X,Y,Z that are on those lines respectively and form a triangle with all sides equal to sqrt(2) .

I believe this statement is true, since there is a trinagle with all sides sqrt(2) already. The previous system of quadratic equations describes those x,y,z parameters on those lines that output those 3 points of the triangle, I believe, I will show why:

Points X,Y,Z form a triangle with all sides sqrt(2), that means that

|X-Y|=sqrt(2)  ; 2=sqr(|X-Y|)

so

sqr(|X-Y|) = (P[1]+D[1]*x - P[1]-G[1]*y)2 +(P[2]+D[2]*x - P[2]-G[2]*y)2 +(P[3]+D[3]*x - P[3]-G[3]*y)

since P is identical, the corner, we can leave it out

sqr(|X-Y|) = (D[1]*x -G[1]*y)2 +(D[2]*x - G[2]*y)2 +(D[3]*x - G[3]*y)2

lets outperform the statement by making (a-b)2=a2-2*a*b+b2 and add the three squared expressions together immediate

2=(D[1]2+D[2]2+D[3]2) * x2 - (2*D[1]*G[1] + 2*D[2]*G[2]+2*D[3]*G[3]) *x*y + (G[1]2+G[2]2+G[3]2) * y2

since we know that D and G are unit vectors, and are also orthogonal, we can write

[EDIT!! orthogonal unit vectors have dot product equal to zero, not one, !! I must have been high or something!!]

x- 2*x*y + y2  =2     as for the parameters x and y

next two equations are only equations for sqr(|Y-Z|) and sqr(|Z-X|)

Is this "proof" inconsistent, or  am I solving the equation system wrongly?

Edited by JohnnyCode

##### Share on other sites
The system of equations in the first post is asking for three points x, y and z in a line such that the distance from x to y is sqrt(2), the distance from y to z is sqrt(2) and the distance from z to x is sqrt(2). Obviously that doesn't have any solutions.

##### Share on other sites

in the first post is asking for three points x, y and z in a line such that the distance from x to y is sqrt(2), the distance from y to z is sqrt(2) and the distance from z to x is sqrt(2)

Though x,y,z are scalars, you made exact picture assuming points on a line - no three scalars can have the same distance from each other unless all are equal.

I have made correction of the problem, it is like this

x- 0*2*x*y + y2  =2

y- 0*2*y*z + z2  =2

z- 0*2*z*x + x2  =2   (I have incorectly "thought" that dot product of unit orthogonal vectors is 1, instead of zero )

then this leaves solution [(1,1,1) (-1,-1,-1)] what is exactly the size of parameters on the parametric defintion of edge lines (the 3 sided pyramid of a unit cube). I then am actualy needing to solve this for arbitrary direction vectors, where, at least one of the vectors is not equal to the rest of unit vectors.

Consider

x- i*2*x*y + y2  =2

y- n*2*y*z + z2  =2

z- m*2*z*x + x2  =2

where i,n,m are given dot products of pairs from arbitrary three unit vectors (combined), where as mentioned, at least one is not equal with the rest. I believe it then has always a solving set of two (x,y,z) vectors of unknowns. But how would I solve it, and, is it even so? (But I think it is so)

##### Share on other sites

So to be straight after all. I need to solve this system:

x- i*2*x*y + y2  =2

y- n*2*y*z + z2  =2

z- m*2*z*x + x2  =2

where i,n,m are given. It does not always has a solution, one last thing is that i,n,m are members of [0,1] real interval.

I am so lost trying to figure this out.

##### Share on other sites

well, I thought a lot about a solution for this equation, I found nothing. maybe it's better to give us some information about how you get to this equation and what you intend to do, to see if it's possible to avoid solving this equation.

##### Share on other sites

maybe it's better to give us some information about how you get to this equation and what you intend to do, to see if it's possible to avoid solving this equation.

No one is quite willing to sucumb and give up in front of a math question (no ego involved). This i a hobby question, yet, this solution would be very well professionaly utilizable. I have sort of explained it in the before post , but to sumarize - this equation tells where arbitrary 3 direction vectors form an equilaterlal triangle of size 2 - if they do .

##### Share on other sites

lets outperform the statement by making (a-b)2=a2-2*a*b+b2 and add the three squared expressions together immediate
2=(D[1]2+D[2]2+D[3]2) * x2 - (2*D[1]*G[1] + 2*D[2]*G[2]+2*D[3]*G[3]) *x*y + (G[1]2+G[2]2+G[3]2) * y2
since we know that D and G are unit vectors, and are also orthogonal, we can write
[EDIT!! orthogonal unit vectors have dot product equal to zero, not one, !! I must have been high or something!!]
x2  - 2*x*y + y2  =2     as for the parameters x and y

(2*D[1]*G[1] + 2*D[2]*G[2]+2*D[3]*G[3])*x*y is the same as 2*dot(D,G)*x*y, which would equal zero because dot(D,G) = 0 since D and G are orthogonal. Then for that equation you get x^2+y^2=2, which is the Pythagorean theorem. Doing that for all the equations and solving, you get that x=1, y=1, z=1. That's consistent with what you would expect for a trirectangular tetrahedron.

##### Share on other sites

So to be straight after all. I need to solve this system:

x- i*2*x*y + y2  =2

y- n*2*y*z + z2  =2

z- m*2*z*x + x2  =2

where i,n,m are given. It does not always has a solution, one last thing is that i,n,m are members of [0,1] real interval.

I am so lost trying to figure this out.

The problem is that in order to maintain the relationships and keep your multipliers in the unit interval, you only have 1 solution. Decreasing any of the scalars from 1, like i for example, will require at least one other scalar to be greater than 1 in order to keep the triangle sides sqrt(2).

Are you're trying to generalize this to any tetrahedron (not just trirectangular) and solve for the scalars? Or are you trying to solve what the conditions must be for the points on the trirectangular tet to still lie on the origin and XYZ axes and the "cut face" to be equilateral with edge length sqrt(2)?

• ### What is your GameDev Story?

In 2019 we are celebrating 20 years of GameDev.net! Share your GameDev Story with us.

• 13
• 9
• 15
• 14
• 46
• ### Forum Statistics

• Total Topics
634067
• Total Posts
3015323
×