Considering the equation: \begin{align} y&=\dfrac{6x+x^2}{x} &\text{(before simplification)}\\ y&=6+x &\text{(after simplification).} \end{align}
- If Before Simplification of the expression, $x = 0$ is substituted, $y = undefined$
- But after Simlfication, $x = 0$ is substituted, $y = 6$
Why is this so? Or am I getting something wrong?
This is because you did the simplification almost correct. The actual correct simplification would be $$y = x + 6, \quad x \neq 0$$ because that's what captures all information in the original equation. If you forget the $x \neq 0$, you lose that piece of information, and that leads to your confusion.