# If a set is open, its "slices" are also open. Converse?

Suppose $X$ and $Y$ are topological spaces and $U \subseteq X \times Y$.
Now, I managed to prove that whenever $U$ is open all "slices" along $Y$ are also open:

$$U \; \text{is open} \implies \forall \, x \in X : \left \{ y \in Y : \left( x, y \right) \in U \right \} \; \text{is open}$$

Obviously the same applies to slices along $X$.

Does the converse hold? That is, suppose that for a given set $U \subseteq X \times Y$ all slices along $X$ and $Y$ are open, can we conclude that $U$ is open?
My gut feeling tells me, that we need something like Hausdorffness to ensure that we have sufficiently "small" open sets, but I fail to prove it (or disprove it for that matter).

My idea so far is quite simple. If $U$ is empty then all is well, so suppose there is an element $\left( x, y \right) \in U$.
We can then look at the neighbourhood filters $\mathcal{F}_x$ and $\mathcal{F}_y$ of $x$ and $y$ respectively. Then the statement is equivalent to the existence of some $A \in \mathcal{F}_x$, $B \in \mathcal{F}_y$ such that

$$A \times B \subseteq U$$

This seems to me impossible to prove without further assumptions... What assumptions are necessary and sufficient? Uniform topology comes to mind as it assures some symmetry between openness in $X$ and $Y$ directions.

• @Eric: Whoops, right. May 26 '17 at 20:23
• Consider the complement in $\mathbb{R}^2$ of $\{(1,1), (1/2, 1/2), (1/3, 1/3), \ldots \}$ May 26 '17 at 21:26
• Can you please share how you prove $U$ is open all "slices" along $Y$ are also open? May 27 '19 at 5:48
• By the product topology, $(x, y) \in U \implies \exists \mathrm{open} A \in X, B \in Y : (x, y) \in A \times B \subseteq U$. Thus a slice along $Y$ that contains $y$ has to contain $B$. Hence to every $y$ in a slice, there is an open neighbourhood also contained in the slice.
– iolo
May 29 '19 at 7:28

This is almost always false. To put this in a perhaps more familiar context, note that the collection of all sets $U\subseteq X\times Y$ whose slices are open is a topology; call it $T$. Now note that a map $f:X\times Y\to Z$ is continuous with respect to $T$ iff it is continuous on each coordinate separately: that is, iff for each $x\in X$, $y\mapsto f(x,y)$ is continuous, and for each $y\in Y$, $x\mapsto f(x,y)$ is continuous. So your question is equivalent to asking whether every separately continuous function on a product is actually jointly continuous (i.e., continuous with respect to the product topology).
As multivariable calculus students learn, this is false even in the most familiar contexts. For instance, taking $X=Y=Z=\mathbb{R}$, the function $f(x,y)=\frac{xy}{x^2+y^2}$ for $(x,y)\neq (0,0)$ and $f(0,0)=0$ is continuous in each variable separately but is not continuous jointly at $(0,0)$. To get a direct counterexample to your question, you can take $U=f^{-1}(\mathbb{R}\setminus\{1/2\})\subset\mathbb{R}^2$. This set has open slices, but it is not open in the product topology (it contains $(0,0)$ but does not contain any ball around $(0,0)$ since $f(a,a)=1/2$ for any $a\neq 0$). Even more explicitly, this set $U$ is the complement of the set $\{(a,a):a\neq0\}$, which you can easily verify has closed slices but is not closed