Suppose I have a function which is defined in different parts, for example:
$$f(x,y)=y\cos\left(\frac{x}{y}\right)\ \ \ y\neq0$$ $$f(x,0)=0$$
and I have to calculate the limit when $(x,y)\rightarrow (x_0,0)$. Is it possible to calculate it separately through the curves $y=0$ and $y\neq 0$ and say that if both are the same, then the limit is that number? I have seen this procedure a number of times, but I have the following doubt: it would be possible to find a curve $C$ with points satisfying both $y=0$ and $y\neq0$, and therefore the division made above does not consider all the curves passing through $(x_0,0)$.
Which is the correct argumentation to solve a limit of this kind?
Using: $$\large-1\le\cos x\le1\\\implies\large-y\le y\cos\frac{x_0}{y}\le +y$$ Think what will happen if $y\to0$
Spoiler:Hint: