Can we prove $ℝ^n ∖ \{\text{straight line}\}$ and $ℝ^n ∖ \text{\{an axis\}}$ homeomorphic by proving their complements homeomorphic?
Solution 1:
The statement about complements that you claim is not true. First of all, not all topological spaces embed into $\mathbb R^n$. Even for those that do, we can find counterexamples. For instance, in $\mathbb R^2$ the subsets $A = \{(x, 0) : x \in (0, 1)\}$ and $B = \{(x, 0) : x \in \mathbb R\}$ are homeomorphic. However, $\mathbb R^2 - A$ is connected but $\mathbb R^2 - B$ is disconnected. Thus, they are not homeomorphic, so the proof method you had in mind will not work.
Here's a proof for the statement at hand. Let $L = \{u + tv : t \in \mathbb R\}$ for some $u,v \in \mathbb R^n$ and $v \neq 0$ be a line in $\mathbb R^n$ and $A = \{(t, 0, \dots, 0) : t \in \mathbb R\}$ be an axis. We define a homeomorphism $f: \mathbb R^n \longrightarrow \mathbb R^n$ such that $f[A] = L$. Indeed, extend $\{v\}$ to a basis $v=v_1, v_2, \dots, v_n$. We define $f(x_1, \dots, x_n) = u + \sum x_i v_i$. This is clearly continuous with a continuous inverse (they are both affine linear isomorphisms). Furthermore, $f(t, 0,\dots, 0) = u + tv \in L$ so $f[A] = L$ and $f$ restricts to a homeomorphism $f: \mathbb R^n - A \longrightarrow \mathbb R^n - L$.
Solution 2:
In $\mathbb R$, $(0,1)$ is homeomorphic to $(1,\infty)$ (via $x \to \frac 1 x)$ but the complement of the first one is not connected whereas the complement of the second interval is connected.