limit simplification in case of 0 denominator I know the following implication holds:
$\lim_{x \to p} f(x) = A \land \lim_{x\to p} g(x) = B \land B \ne 0 \implies \lim_{x\to p} \frac{f(x)}{g(x)} = \frac{A}{B}$.
My question is how much "freedom" we have when computing $\lim_{x\to p} \frac{f(x)}{g(x)} $in case $B = 0$.
Do I understand correctly that limits are defined for the neighbourhood of $p$, and exclude point $p$? If so, can we then multiply both numerator and denominator by a function which is $0$ only at $p$, but not $0$ when approaching $p$?
For example, does the equality below hold (e.g. in case multiplying by $x-p$ simplifies the expression, such that the limit converges:
$$
\lim_{x\to p} \frac{f(x)}{g(x)} = \lim_{x\to p} \frac{f(x) \cdot (x-p)}{g(x) \cdot(x-p)}
$$
 A: If $B = g(p) = 0$ and $A = f(p) \neq 0$, then $\lim_{x \to p} \frac{f(x)}{g(x)}$ blows up to $\pm \infty$.
The only circumstance maybe when $\lim_{x \to p} \frac{f(x)}{g(x)}$ exists and is finite is if $f(p) = 0$. A famous example of this is $\lim_{x \to 0} \frac{\sin(x)}{x} = 1$, a calculation which is used to compute the derivative of $\sin(x)$. But even if $f(p) = 0$, that's not a guarantee that the limit exists and is finite. For example, one can show $\lim_{x \to 0} \frac{\sin (x)}{x^2} = \infty$.
General intuition: If $f(p) = 0$ and $g(p) = 0$, then the limit of $\frac{f(x)}{g(x)}$ as $x \to p$ exists if and only if $f(x)$ goes to $0$ "faster or just as fast" as $g(x)$. In the above examples, near $0$, the function $f(x) = \sin(x)$ "looks" and "behaves" very similarly to the function $g(x) = x$. So they each approach $0$ as $x \to 0$ at about the same rate. On the other hand, $x^2$ approaches $0$ much faster than $\sin(x)$, so the limit blows up. (You can see this yourself: plug in different values of $x$ for $x^2$ and for $\sin(x)$, and you'll see that small values of $x$ give you much smaller values of $x^2$ than $\sin(x)$.)
EDIT: In response to your example, yes, you can absolutely do that! Though to be clear, the limits in this example are exactly the same—in particular they either both converge or both do not. Multiplying the numerator and denominator in this way doesn't make the limit converge; it just might make it easier to find what the limit is. (More frequently, however, you'll find yourself doing the opposite: factoring out a term from the numerator and denominator that's nonzero near $p$, and cancelling it.)
Aside: As you said, a limit depends on the behavior around the point $p$, but not necessarily the actual value $f(p)$. You can imagine a function formally defined by
$$
f(x) = \begin{cases} x^2 & \textrm{if } x \neq 3, \\
0 & \textrm{if } x = 3
\end{cases}
$$
and observe that $\lim_{x \to 3} f(x) = 9$ even though $f(3) \neq 9$. This, by the way, is one way to define continuity: a function $f$ is continuous at $x = p$ if $\lim_{x \to p} f(x) = f(p)$.
A: Ponder $\lim_{x\to0}\dfrac{x^p}{x^q}$. Clearly, this limit exists iff $p\ge q$. And is nonzero iff $p=q$.
Now assume you can factor your functions as
$$f(x)=x^p\frac{f(x)}{x^p}$$ where $p$ is such that
$$\lim_{x\to0}\frac{f(x)}{x^p}$$ is finite, and similarly with $g(x)$ and some $q$.
E.g.,
$$\sin x=x\frac{\sin x}x$$ where the right factor has a finite limit at $0$, so to that
$$\lim_{x\to0}\frac{\sin x}{\sqrt x}=\lim_{x\to0}x^{1-1/2}=0.$$
