How can $\frac{x^3-4x^2+4x}{x^2-4}$ be both $0$ and "undefined" when $x = 2$? Suppose I have a function defined as $$F(x)= \frac{x^3-4x^2+4x}{x^2-4}$$
Now I want to find the value of $F(2)$. I can do it in 2 ways:


*

*Put $x=2$ and solve the function. It will give:
$$F(2)=\frac{0}{0}$$ which is not defined.

*Solve $F(x)$ first and then put $x=2$. 
$$F(x)= \frac{x(x-2)^2}{(x-2)(x+2)}=\frac{x(x-2)}{x+2}$$
It will give $${F(2)=\frac{0}{4}}$$ which is zero.
How can zero equal not defined?

What you have found is a simplification for $F(x)$, provided $x\neq 2, x\neq -2$.  The denominator $(x^2 - 4)$ of the original function makes it undefined at $x = 2, \;x=-2:$ $(2^2-4) = (-2)^2 - 4 = 0$
So your simplification 
$$F(x)= \frac{x(x-2)^2}{(x-2)(x+2)}=\frac{x(x-2)}{x+2}$$ is valid, $\forall x \in \mathbb R \setminus\{-2, 2\}$.
