# Continuity on paths implies continuity on space?

Suppose we have some map $f:X\rightarrow Y$. Given any path in $X$, $\gamma:I\rightarrow X$ we know the composite map $f\circ\gamma:I\rightarrow Y$ is continuous. Can we say that $f$ is continuous?

Note: $I=[0,1]$ is the closed unit interval in the real line

Also, I'm specifically interested in the case for which $X=I\times I$.

In general, the answer is negative. For instance, let $X=\Bbb Q$ endowed with the standard topology (or, more general, a non-discrete space which is hereditarily disconnected (that is, it has only one-point connected subsets)), $Y=X$ endowed with the discrete topology, and $f$ be the identity map (which is discontinuous). Nevertheless, any map $\gamma: I\to X$ is constant, so the composition $f\circ \gamma$ is continuous.

On the other hand, the claim holds when $X$ is a first countable (that is, it has a countable base at each its point) locally pathwise connected space (that is, for every $x\in X$ and each neighborhood $U$ of the point $x$ there exists a neighborhood $V$ of $x$ such that for any $y\in V$ there exists a continuous map $\gamma: I\to U$ satisfying $\gamma(0)=x$ and $\gamma(1)=y$). Indeed, let $x\in X$ be an arbitrary point. By induction we can construct a sequence $\{U_n:n\in\Bbb N\}$ of open neighborhoods of the point $x$ such that $\{U_n\}$ is a base at $x$ and for each $n$ and each $y\in U_{n+1}$ there exists a continuous map $\delta: I\to U_n$ satisfying $\delta(0)=x$ and $\delta(1)=y$. Assume that the map $f:X\to Y$ is discontinuous at the point $x$. This means that there exists a neighborhood $W$ of the point $f(x)$ such that for any neighborhood $U_n$, $n\ge 2$ there exists a point $x_n\in U_n$ such that $f(x_n)\not\in W$. We can easily construct a continuous map $\gamma_n:\left[1-\frac 1{n-1}, 1-\frac 1{n}\right]\to U_{n-1}$ such that $\gamma_n\left(1-\frac 1{n-1}\right)=x_n$ and $\gamma_n\left(1-\frac 1{n}\right)=x_{n+1}$. Now define a map $\gamma: [0,1]\to X$ by putting $\gamma(t)=\gamma_n(t)$ if $t\in \left[1-\frac 1{n-1}, 1-\frac 1{n}\right]$ for some $n$ and $\gamma(1)=x$. Since for each $n$ the set $U_n$ contains a set $\gamma_m\left(\left[1-\frac 1{m-1}, 1-\frac 1{m}\right]\right)$ for each $m>n$, we see that the map $\gamma$ is continuous. But $f\gamma(1)=f(x)$ $f\gamma\left(1-\frac 1{n}\right)=x_{n+1}\not\in W$ for each $n$, so the map $f\gamma$ is discontinuous at the point $x$.

• +1..... A counter-example to the general Q when $X=Y$ and $X$ is a compact connected subspace of $\Bbb R^2$ : Let $X=A\cup B$ where $A=\{0\}\times [-1,1]$ and $B= \{(x,\sin (1/x)):0<x\leq 3\}.$ ..... Let $f(A)=\{(2,\sin (1/2)\}$ and let $f((x,\sin (1/x))=(x/3,\sin (3/x))$ for $0<x\leq 3.$...... If $\gamma: I\to X$ is a path then $\gamma (I)\subset A$ or $\gamma (I)\subset B$ so $f\cdot \gamma$ is continuous...... But $\phi \ne A\subset \overline B$ and $f(A)\cap \overline {f(B)}=\phi$ so $f$ is not continuous. Sep 27, 2017 at 18:31
• In my previous comment I could have let $Y$ be any space with $p,q\in Y$ such that $p\not \in Cl_Y(\{q\})$ and let $f(A)=\{p\}$ and $f(B)=\{q\}.$ Sep 27, 2017 at 18:42
• It seems to me that your construction of $\{U_n\}$ requires the Axiom of Choice, no? Can one prove this without invoking AC? In particular, can one prove the result for an open set in $\mathbf{R}^n$ without invoking AC? Mar 23, 2019 at 17:14

Suppose that $f$ is not continuous at point $c$. Then, by Heine´s characterization of continuity, there must exist some sequence $x_n$ that tends to $c$ which is such that $f(x_n)$ does not tend to $f(c)$. Build a path that connects all members of the set $(\bigcup \{{x_n\}_{n\in \mathbb N}}) \bigcup \{c\}$. Since, by assumption, $f$ is not continuous at $c$ we then have that $f(x_n)$ does not tend to $f(c)$ on this path but that is not true since $f$ is continuous on every path.

So, basically, your claim is true for every nice enough set in $\mathbb R^n$.

• Well, but how do you define "tend to" in a non-metric space? Is it possible? Sep 26, 2017 at 17:03
• @GabrielGolfetti Yes, this is possible for each topological space $X$. Namely, a sequence $\{x_n\}$ of points of $X$ converges to a point $x\in X$ provided for each neighborhood $U$ of the point $x$ there exists a number $N$ such that $x_n\in U$ provided $n>N$. Sep 26, 2017 at 18:30
• For a space with uncountable tightness the closure operator cannot be defined in terms of countable sequences. Example: In the box-product topology on $X=\Bbb R^{\Bbb N}$ let $A=\{f\in X:\forall n\in \Bbb N\;(f(n)>0) \}$ and let $0^*\in X$ where $\forall n\in \Bbb N\;(0^*(n)=0)\}.$..... Then $0^*\in \overline A$ but $0^*\not \in \overline B$ for any countable $B\subset A.$ Sep 27, 2017 at 19:04