1

I'm trying to understand the conditions under which I can extend a function defined on a dense subset of a topological space to a continuous function defined on the full space.

Let $(X_1,\tau_1)$ and $(X_2,\tau_2)$ be separable Hausdorff spaces. Let $D$ be a countable dense set in $X_1$. Let $f\colon D\to X_2$ be continuous. Assume that

$$\lim_{y\to x, y\in D}f(y)$$

exists and is uniquely defined for all $x\in X_1$. Define the continuous extension $g$ to be

$$ g(x) = \lim_{y\to x, y\in D}f(y)\quad \forall x\in X_1 $$

Is $g$ guaranteed to be a continuous function? If so, how would I prove this? If not, is there some simple additional condition that would suffice? I specifically need to avoid a requirement of uniform continuity or compactness; I'm dealing with cases analogous to $X_1=\mathbb{R}\setminus\{0\}$, $X_2=\mathbb{R}$, $D=\mathbb{Q}\setminus\{0\}$, and $f(x)=1/x$.

Anne Bauval
  • 49,005
  • Thanks. Can you point me at a counterexample so I can see how it can fail? – Kevin S. Van Horn Jun 28 '25 at 14:59
  • The usual counterexamples rely on $\lim_{y\to x,y\in D}f(y)$ not existing or not being unique for some $x\in X_1$, but we're assuming this limit does exist and is unique for all $x\in X_1$. – Kevin S. Van Horn Jun 28 '25 at 15:51
  • 1
    I believe the appropriate property is regularity and that this is a duplicate. – Jakobian Jun 29 '25 at 08:34
  • There's also another answered by Brian Scott but I didn't find it. – Jakobian Jun 29 '25 at 08:40