So does a limit approaches infinity and the term limit does not exist are the same.
Limits do not approach anything. Functions do. When a function approaches something, we say that its limit is equal to that thing.
Anyway, the terms are not equivalent. The limit $\lim_{x\to 0} \sin (1/x)$ does not exist, but it would not be correct to say that this function approaches infinity; it clearly does not.
However, it is true that when a function approaches infinity, the limit (understood in the strict sense of a limit in $\mathbb R$) does not exist. The failure of limit to exist in this particular way is recorded as "$\lim_{x\to a}f(x)=\infty$", a shorthand for "limit does not exist due to $f$ approaching infinity".
Yet, there are ways in which one can extend the definition of limit to make $\lim_{x\to a}f(x)=\infty$ an actual limit rather than a shorthand form of the statement quoted above. This is a matter of how a particular book / professor define things.
Concerning the second part: you are right that $$f(x) =
\begin{cases}
x^2 & \text{if } x \ne 2 \\
4 & \text{if } x=2 \\
\end{cases}$$
is a continuous function. It is the same function as "$f(x)=x^2$ for all $x$", only written differently.
Perhaps what the lecturer had in mind was that
$$f(x) =
\begin{cases}
x^2 & \text{if } x \ne 2 \\
\text{undefined} & \text{if } x=2 \\
\end{cases}$$
has a removable discontinuity, which is demonstrated by the fact that defining $f(2)=4$ makes a continuous function.
This is an answer on the question from the khanacademy.org
Full credit for this answer goes to the user "Tronax" from khanacademy.org:
I will try to show the difference between the two types of what we previously called "undefined".
Let's start with the "removable discontinuity", which actually says, that the graph at the point of x could be absolutely any y! And there is no way to find it. It could be 0, -7, 65, 23/7, 3982.3 etc. Math guys agreed between themselves, that if they can't understand it better and find its value - it does not exist. So now we just draw an empty circle on the curve of our graphs in spots that are known to have a removable discontinuity.
This happens if the function is of a form that includes the same non constant factor in both numerator and denominator. For example y = (x+1)(x+2) / (x+1). Notice (x+1) factor is both on the numerator and on the denominator.
For x=-1, (x+1) equals zero, so we say that at x=-1 function has a removable discontinuity.
But... why?
Because when you input x=-1 and try to solve for y:
y = (-1+1)(-1+2) / (-1+1)
y = 0*(-1)/0
y = 0/0
or (this is one of interpretations):
0y = 0
You could substitute any number into y, this expression will fit them all, since anything multiplied by 0 equals 0.
This is removable discontinuity. The graph around the point of it, looks just like it would, if there was no removable discontinuity.
The second type is the "vertical asymptote". It occurs when for some x, the denominator (and only denominator) equals zero. It's somewhat easier to understand. Let's think about what happens when we see 8/4. This says: how many times, can we fit the denominator 4 into 8? It takes 2 times. For 8/2 it takes 4 times; for 8/1 - 8 times; 8/0.5 - 16 times; 8/0.25 - 32 times. The lower and closer to zero our denominator gets, the more times we can fit it into the same 8. When it becomes really really small, it can take millions of times! When it gets such a small number that we can barely distinguish it from zero, it seems like it would take almost infinite times of that number to fit our 8! That's why when denominator approaches 0, we say that the result approaches infinity.
When x approaches 0, y=8/x approaches infinity and y=-8/x approaches negative infinity.
Don't be confused, when x actually equals zero, y=8/x is undefined! In this case, you could say that even infinity is not enough :)
When saying "approaches zero", we only mean that it gets very very very close to zero, but not zero.
"Vertical asymptote at x = k" only refers to what happens before and after k on the graph. x = k itself is undefined.
The graph before and after vertical asymptote quickly gets almost parallel to the y-axis.
Hope this is helpful.
Source: https://www.khanacademy.org/math/algebra2/rational-expressions-equations-and-functions/discontinuities-of-rational-functions/v/discontinuities-of-rational-functions
Best Answer
Two functions are typically defined to be equal if and only if they...
Thus, functions $f,g : S \to T$ for sets $S,T$ have $f=g$ if and only if $f(x) = g(x)$ for all $x$ in $S$.
For functions with holes, we typically restrict the domain by ensuring the values where the function is not defined at not included. For example, in the functions you have, you have
$$f(x) = \frac{(x-3)(x+2)}{(x-3)} \;\;\;\;\; g(x) = x+2$$
Are these equal? Yes, and no.
A function must be defined at all values of the domain. Thus, we can say $3$ is not in the domain of $f$ for sure. But we never specified otherwise the domains and codomains of these functions! Typically, unless stated otherwise, we often assume their domain to be $\Bbb R$ or $\Bbb C$, minus whatever points are causing problems - and of course, in such cases, $f \neq g$ since $f(3)$ is not defined, and thus $f$ normally has domain $\Bbb R \setminus \{3\}$ and $g$ generally has domain $\Bbb R$.
But that restriction is not necessary. For example, we could define the functions to be $f,g : \Bbb R \setminus \Bbb Q \to \Bbb R$. Notice that the domain of both functions are now all real numbers except rational numbers, i.e. the irrational numbers. This means $3$ is not in the domain of either function - and since that's the only "trouble spot," and the codomains are equal, and the values are equal at each point in the domain, $f=g$ here.
Or even more simply: we could have $\Bbb R \setminus \{3\}$ be the domain of $f$ and $g$ and again have equality! The key point in all this is that, just because $f$ or $g$ do attain defined values for certain inputs, doesn't mean they have to be in the domain.
In short, whether $f=g$ depends on your definitions of each. Under typical assumptions, $f \neq g$ in this case, but if we deviate from those assumptions even a little we don't necessarily have inequality.