Find lambdas so that two polynomials share a root and find such root

Find $\lambda \in \mathbb{C}$ such that the following polynomials share a root, and find that root.

$$\lambda x^3-x^2 - x - (\lambda + 1) \quad and \quad \lambda x^2 - x - (\lambda +1)$$

I tried dividing them both by $(x-r)$, where r is my root. Then I want the remainder of that division to be 0. That gives two equations and two unknowns, which should be solvable, but I can't get my self to get it right. And, besides, there must be a better method: this was part of an exam, and this approach would simply take too much time.

Any ideas?

• If $f,g\in \mathbb F[x]$ have the common root $\alpha$, then for every $p,q\in \mathbb F[x]$ the polynomial $pf+qg$ has this root. – hamid kamali Feb 27 '16 at 20:25

Hint The polynomials factor respectively as $$(x^2 + x + 1) [\lambda x + (-\lambda - 1)]$$ and $$(x + 1) [\lambda x + (-\lambda - 1)] .$$ (In particular, for most values of $\lambda$ they have a common linear factor and hence a common root.)
More generally, one can detect whether two polynomials have a common root (possibly in some field extension) using the resultant, which is given by the determinant of the Sylvester Matrix for the two polynomials. (Even the size of this matrix depends on the degree of the polynomials, so if we use this method again we must treat the case $\lambda = 0$ separately.)
If $r$ is a common root, then $$0=λr^3-r^2-r-(λ+1)-(λr^2-r-(λ+1))=λr^3-(λ+1)r^2$$ So, for example for $λ=-1$ they share the root $r=0$ (actually this solution can be found directly by inspection, since the constant terms disappear). For $λ\neq 0$ and $r\neq0$ there are other solutions, since then $$0=λr-(λ+1) \implies r=\frac{λ+1}{λ}=1+\frac1λ$$ is a common root.
• You can not take $\lambda=0$ – hamid kamali Feb 27 '16 at 20:36
• @hamidkamali Firstly, why not? Secondly, $λ=0$ is only one case from the many that I treat. For $λ\neq 0$ I give a parametric solution that works, but obviously you missed it. – Jimmy R. Feb 27 '16 at 20:39
• If $\lambda=0$ we get that $x^2+x+1$ and $x+1$ have common root which is trivialy wrong. – hamid kamali Feb 27 '16 at 20:41