# Extension by continuity in affine varieties

Is there a nice explanation of existence and uniqueness of continuous map's extension from open dense set to the whole space (in a case of map between two affine varieties)?

• I'm confused. This is not true. Think about the identity mapping $\mathbb{C}\to\mathbb{C}$ which cannot extend to the sphere $\mathbb{C}\subseteq S^2$ else the map is bounded. Uniqueness only follows when the codomain is Hausdorff--I can give you specific counterexamples if you'd like, but maybe it'd be instructive to create your own. – Alex Youcis Oct 15 '16 at 4:59
• Define $f:(\mathbb R \ \{0\})\to \mathbb R$ by $f(x)=1$ for $x>0$ and $f(x)=0$ for $x<0.$ The domain of $f$ is dense open in $\mathbb R$ but $f$ cannot be extended to a continuous real function with domain $\mathbb R.$ – DanielWainfleet Oct 15 '16 at 10:43
• @Anna Yes. It's $\mathbb{P}^1_\mathbb{C}$ removed a point. If you're claim was true for the Zariski topology then, intuitively, one would have that $\mathcal{O}_X(U)\subseteq\mathcal{O}_X(V)$ if $U\subseteq V$ when really the OPPOSITE happens (assuming that $X$ is integral). For example, with your assumption don't you get that $\mathcal{O}(\mathbb{A}^1)\subseteq\mathcal{O}(\mathbb{P}^1)$ where the former is $\mathbb{C}[t]$ and the latter $\mathbb{C}$? – Alex Youcis Oct 15 '16 at 16:07