Why isn't there a vertical asymptote at $x = 2$ for $y = \frac{x - 2}{x^2 - 3x +2}$?
If you factorize the denominator, you get: $(x-1)(x-2)$. So, when $x = 1$ or $2$, the denominator will be $0$. But I noticed that when I put this function into a graphing program, there is only a vertical asymptote at $x = 1$ and the function seems to be continuous at $x = 2$.
I can also see that the $(x - 2)$ will cancel with the numerator, but I was just wondering on a deeper level why this means that only $x = 1$ is undefined.
We have
$$y = \frac{x-2}{x^2-3x+2}$$
You can check that at $x=1$, we face the following problem
$$y(1) = -\frac{1}{0}$$
So the function is not defined at $x=1$. Similarily
$$y(2) = \frac{0}{0}$$
So the function is not defined at $x=2$ either.
How do we differentiate an asymptote from a removable discontinuity$^{1}$? We need to find the limits. In this case, we have
\begin{align*} \lim_{x\to 2} y &=\lim_{x\to 2}\frac{x-2}{x^2-3x+2}\\ &=\lim_{x\to 2}\frac{x-2}{(x-2)(x-1)}\\ &=\lim_{x\to 2}\frac{1}{x-1}\\ &=1 \end{align*} so there is no asymptote at $x=2$, but rather a "hole". We can fill it in, and in fact make $y$ continuous there by simply defining $y(2)=1$.
However, at $x=1$, as you note, there is an asymptote.
$1:$ [the function] is discontinuous there, but the function can be redefined so that it can be continuous at that point. J.M.