the points, where the function is discontinuous

How can I find the points where is this function is discontinuous?

$$f:[0,\infty[^2\to\mathbb R,\quad f(x,y):=\begin{cases}x/y&\text{for }y>x,\\y/x&\text{for }x>y,\\1&\text{for }y=x\end{cases}$$

If I try to define the points with 2 sequences so that $x_n\to1$ and $y_n\to1$, I get that this function is continuous. But it's not true, because I plotted this function in WolframMatematica.


Let us $f\,:\,[0,+\infty)^2\to\mathbb{R}$ be the function you defined above. We will look at the function behavior, first when $x\neq0$ and $y\neq 0$, then when either $x=0$ or $y=0$, and last when $x=0=y$.

Case $x,y>0$

On the domain $(0,+\infty)^2$, $f$ is continuous. As said by @theo-bendit we can, on this domain rewrite $f$ as an exponential. Let suppose $x\geq y>0$, then $$ f(x,y)= \frac{y}{x} = \frac{e^{\log y}}{e^{\log x}} = e^{\log y - \log x} $$ Same reasoning if $y\geq x>0$ gets us that on the restricted domain $$ f(x,y) = e^{-|\log(x)- \log(y)|} $$ This is a composition of continuous function meaning that $f$ is continuous on this restriction.

Case $x=0$ or $y=0$

What happen now when we allow either $x$ of $y$ to be 0?
Since the function is symmetric I will suppose w.l.o.g. that $x>y = 0$. Take any sequence $x_n\to x > 0$, and $y_n \to 0$. We since $x_n\to c>0$ and $y_n\to 0$, we can choose $N\in\mathbb{N}$ sufficently large such that $\forall n\geq N$, we have $x_n > y_n$. I will only look at this part of the sequence now. $$ \lim_{n\to\infty} f(x_n, y_n) = \lim_{n\to\infty}\frac{y_n}{x_n} \overset{(\star)}{=}\frac{\lim_{n\to\infty} y_n}{\lim_{n\to\infty} x_n} = \frac{0}{c} = f(c, 0) = f\Big(\lim_{n\to\infty} (x_n, y_n)\Big) $$ Which mean that $f$ is continuous at every point in $[0,+\infty)^2 \setminus (0,0)$.
We get $(\star)$ only because the limit of $x_n$ is not 0, and that both limits are defined (by hypothesis).

Quick note: You can also use this method to show that there is no discontinuity on the line $x=y$ (expected when $x=y=0$). Take some point $c$ and two sequences $x_n\to c$, $y_n\to c$, then the limit of the ratio will always be 1.

Case $x=y=0$

Now we can show that $f$ is not continuous at $(0,0)$.
To show this it suffice to take a sequence $(x_n,y_n)$ such that $\lim f(x_n,y_n) \neq f\big(\lim\; (x_n,y_n)\big)$.

Take $x_n := n^{-1}$ and $y_n:= 2\cdot x_n$, then $y_n \to 0$ and $x_n\to 0$. Moreover $y_n > x_n$, meaning $$ f(x_n,y_n) = \frac{1}{2} $$ Clearly $$ \lim_{n\to\infty} f(x_n,y_n) = \frac{1}{2}\neq 1 = f(0,0) = f\Big(\lim_{n\to\infty} (x_n, y_n) \Big) $$

Below are some plot and the Mathematica code to generate them.

Extras

Plot of the function and some sequences

In blue you have the trajectory of the sequence I defined above, and I added the trajectory of another sequence: $$ x_n = \frac{1}{(n+1)^2}\quad y_n = \frac{1}{n^2} $$ This sequence also converges to $(0,0)$ but the ratio is equal to $1=f(0,0)$ in the limit. It shows that not every sequence will prove that $f$ has a discontinuity at $(0,0)$, and that you have to find the right ones.

Note that the dip you see on the line $x=y$ when going close to $(0,0)$ is purely graphical, you can play with the code and zoom on this domain and you will see that the graph basically looks the same. Same thing for the hole you see on the line $x=y$, it is just graphical.

Mathematica code

f[x_, y_] := Piecewise[{{1, x == y}, {x/y, y > x}, {y/x, x > y}}]
p1 := Plot3D[{f[x, y]}, {x, 0, 10}, {y, 0, 10}];
p2 := ParametricPlot3D[{1/n, 2/n, 1/2}, {n, 0.2, 100}, PlotStyle -> Blue];
p3 := ParametricPlot3D[{1/(n + 1)^2, 1/n^2, n^2/(n + 1)^2}, {n, 0.3, 10}, PlotStyle -> Red];
Show[p1, p2, p3]