# Solve issue with a solution at zero [closed]

I'm trying to understand why Solve overcounts a solution at zero, or undercounts it altogether in different cases:

For example, the input

Solve[x^2 == 0, x]
Solve[x^2 (1 - x) == 0, x]
Solve[x^2 (1 - x) (1 - r x) == 0, x]
Solve[x^2 (1 - x) (1 - r/x) == 0, x]
Solve[x^2 (1 - x) (1 - r/x)^2 == 0, x]


returns

{{x->0},{x->0}}

{{x->0},{x->0},{x->1}}

{{x->0},{x->0},{x->1},{x->1/r}}

{{x->0},{x->1},{x->r}}

{{x->1},{x->r},{x->r}}


The solution of x->0 behaves in a way I don't understand. Thanks.

• consider what happens when solving eg $(x-2)^2=0$; how many solutions do you get? (perhaps check Multiplicity too) Commented Mar 18, 2018 at 18:55
• As noted by others in slightly different terms, x is not an actual factor of the left hand side. 'In[115]:= Factor[x^2 (1 - x) (1 - r/x)^2] Out[115]= -(r - x)^2 (-1 + x)' Commented Mar 18, 2018 at 19:30
• I'm voting to close this question as off-topic because the issue it raises is not really a Mathematica issue but a matter of the OP not having grasped the mathematics involved. Commented Mar 18, 2018 at 20:54
• Thanks very much, my bad Commented Mar 18, 2018 at 21:51

{x->0} is not a solution for the last equaiton since it contains $1/x^{2}$ which is later multiplied by $x^2$. Previous has {x->0} because it has $1/x$ which is multiplied by $x^2$. The output you get is perfectly fine, try Expand[] function on each of your input.
• Simplify will also eliminate the removable singularities Commented Mar 18, 2018 at 18:56