# How to solve the following pair of non-linear equations

$x^3+y^3=152\\x^2y+xy^2=120$

Best regards !

-

Multiply by three the second equation and add this to the first one, and you'll get (check this!)

$$(x+y)^3=152+360=512=2^9\implies x+y=2^3=8$$

Now take it from here.

-
Your method is perfectly OK, thanks. I got, $(x,y)={(3,5),(5,3)}$. I just have to ask, how did you see that relationship ? – David Sebastian Feb 23 '14 at 11:37
Experience, @DavidSebastian (years don't pass by in vain...). The first equation is ugly: cubics aren't the nicest people out there, but the second one heavily reminds Newton's binomial theorem for $\;(x+y)^3\;$, and multiplying it by three does the trick. That we get $\;512=2^9=$ a perfect cube on the other side is nice, but irrelevant for the general outcome. – DonAntonio Feb 23 '14 at 11:40
That's very cool DonAntonio. Before asking this question I tried to solve the problem like this. $x$ can be isolated in the first equation. So I get $x=\sqrt[3]{152-y^3}$. Then I substituted that in the second equation. By doing that I got $(\sqrt[3]{152-y^3})^2y+(\sqrt[3]{152-y^3})y^2=120$. But I think this expression is not solvable, right ? – David Sebastian Feb 23 '14 at 11:49

Here is another way through, which simply depends on seeing the factor $x+y$ in both parts of what is given, reducing the cubic to a quadratic as follows (though the elimination of the constant term will always give a homogeneous cubic even without noticing this factor):

$x^3+y^3=(x^2-xy+y^2)(x+y)=152=8\times 19$

$x^2y+xy^2=(x+y)xy=120=8\times 15$

Multiply the first equation by $15$ and the second by $19$ to obtain:

$$15(x+y)(x^2-xy+y^2)=19xy(x+y)$$

Then we either have $x=-y$, which is easily eliminated, or divide through by $x+y\neq 0$ to give $$15x^2-34xy+15y^2=0$$ which factorises (quadratic formula) as $$(5x-3y)(3x-5y)=0$$

Either of these factors gives a linear relation which can be plugged into either of the original equations to give a solution.

-
Just to note (might be useful), equations of the form $ax^2+bxy+cy^2=0$ can be solved by dividing both sides by $y^2$ (where $y\neq 0$) and then solving a quadratic equation in terms of $\frac{x}{y}$. – user26486 Feb 23 '14 at 19:23

Another method :

Suppose $x,y$ be the roots of $z^2+az+b=0$

$x+y=-a$ and $xy=b$

$x^3+y^3=(x+y)^3-3xy(x+y)=-a^3+3ab=152$

$xy(x+y)=-ab=120$

$a^3=-152-3*120=-512$

$a=-8$ and $b=120/8=15$

Solve of $z^2-8z+15=0$ for $x$ and $y$

-