Extraneous solution from substituting in equations
I came across this example of how you could end up with an extraneous solution but I was wondering how it arose. We have the equation: $$x^2+x+1=0 $$ Since x=0 does not satisfy the equation, you can divide by x on both sides which yields: $$x+1+\frac{1}{x}=0$$ which is equivalent to our first equation. From our first eqution we can conclude that: $$-x^2=x+1$$ We now substitute that into the second equation to get:$$x^2=\frac{1}{x}$$ which results in $$x^3=1$$ which is equivalent to our previous equation since x cannot be 0. However, one solution from our last equation is x=1, which is not a solution to our original equation. I have a vague idea that it may have to do with the fact that you get a cubic equation and you began with a quadratic, and that steps imply the following and not vice versa, but can you provide a very detailed answer as to why it arises? Can you please provide more examples?
If we call $A(x)=x^2+x+1$ and $B(x)=x+1+\frac1x$, we can schematize your passages as such: $$A(x)=0\Leftrightarrow \begin{cases}x\ne 0\\ B(x)=0\end{cases}\Leftrightarrow \begin{cases}x\ne 0\\ A(x)=0 \\B(x)=0\end{cases}\stackrel{!!!}\Rightarrow \begin{cases}x\ne 0\\ B(x)-A(x)=0\end{cases}$$
Whereas to preserve equivalence you should have kept $A(x)=0$ in $\begin{cases}x\ne0\\ B(x)-A(x)=0\\ A(x)=0\end{cases}$
This substitution ($x+1=-x^2$) expands a set of roots of the equation
because $-x^2$ also depends on $x$.
You can substitute $x+1=y$, for example.
More example, when a similar substitution gives similar problems.
Let we need to solve $$\sqrt[3]{2x+1}+\sqrt[3]{x+1}=\sqrt[3]{x-1}.$$
We obtain: $$\left(\sqrt[3]{2x+1}+\sqrt[3]{x+1}\right)^3=x-1$$ or $$2x+1+x+1+3\sqrt[3]{2x+1}\cdot\sqrt[3]{x+1}\left(\sqrt[3]{2x+1}+\sqrt[3]{x+1}\right)=x-1.$$ Now, since $$\sqrt[3]{2x+1}+\sqrt[3]{x+1}=\sqrt[3]{x-1},$$ which can get something bad, we obtain: $$3\sqrt[3]{(2x+1)(x+1)(x-1)}=-3-2x$$ or $$x(440x^2+630x+189)=0$$ and we got as one of options $x=0$.
Easy to see that $0$ is not a root of the starting equation and it happened
because we used a not correct substitution $\sqrt[3]{2x+1}+\sqrt[3]{x+1}=\sqrt[3]{x-1}.$
Now, we need to check that all roots of the equation $440x^2+630x+189=0$ are roots of the starting equation, which is not so easy.
If we want to avoid from these problems, so we need to use the following identity. $$a^3+b^3+c^3-3abc=(a+b+c)(a^2+b^2+c^2-ab-ac-bc)$$