Prove that for function $f:\Bbb{R} \to \Bbb{R}$, the $\epsilon - \delta$ definition of continuity implies the open set definition.
My attempt: Claim: The notion of open set in metric space $(\Bbb{R},d=\| \cdot \|)$ setting is same as the notion of open set in standard topology, $\mathcal{T}$, on $\Bbb{R}$. Proof: let $A\subset \Bbb{R}$ is open in metric space notion. Let $B=\{B(x,r)|x\in \Bbb{R},r\gt 0\}$. Then $A$ is open iff $A=\bigcup_{i\in I} B_i$, where $B_i\in B, \forall i\in I$ and $I$ is an indexing set(Proof: $A$ is open iff it is union of open balls). In $\Bbb{R}$, $B(x,r)=(x-r,x+r)$ is precisely segment in$\Bbb{R}$. So $B(x,r)\in \mathcal{B}$, $B\subseteq \mathcal{B}$. Since $B_i\in \mathcal{B}\subseteq \mathcal{T}, \forall i\in I$, we have $A=\bigcup_{i\in I}B_i \in \mathcal{T}$. Hence, $A$ is open with respect to standard topology $\mathcal{T}$. Conversely, suppose $A\in \mathcal{T}$. Then $A=\bigcup_{i\in I}(x_i, y_i)$, where $(x_i, y_i)\in \mathcal{B}, \forall i\in I$. Note $(x_i, y_i)=B(\frac{x_i+y_i}{2}, \frac{y_i-x_i}{2})=B_i$, $r=\frac{y_i-x_i}{2}\gt 0$, for seek of completeness, I compute $r$ by solving $\frac{x_i+y_i}{2}+r=y_i$ equation. Thus $A=\bigcup_{i\in I} B_i$ $\Rightarrow$ $A$ is open in $\Bbb{R}$, metric space notion. So we can interchange the notion of open set between metric space and topological space, provided $\Bbb{R}$ is equipped with standard topology and metric on $\Bbb{R}$ is the euclidean norm or absolute value map.
By theorem 4.8 of Baby Rudin, which states “A mapping $f$ of a metric space $X$ into a metric space $Y$ is continuous on $X$ if and only if $f^{-1}(V)$ is open $X$ for every open set in $Y$”. In our case, $X=Y=(\Bbb{R},\| \cdot \|)$. So we can write, $f$ is continuous by $\epsilon -\delta$ definition $\Leftrightarrow$ $f^{-1}(V)\in \mathcal{T}$, for every $V\in \mathcal{T}$. Is this proof correct?
Application: We can use this result to prove following problems:
(1) Exercise $18.5$. Proof: Prove that $(a,b)$ is homeomorphic to $(0,1)$. $f:(a,b)\to (0,1)$, defined by $f(x)= \frac{x-a}{b-a}$ and $g:(0,1)\to (a,b)$, defined by $g(y)=(b-a)y+a$. By theorem 4.4 of Baby Rudin, $f$ & $g$ are continuous map, derived from $\epsilon -\delta$ definition of continuity, hence $f$ & $g$ are continuous maps in topological notion. By definition of map $g$, $\forall y\in (0,1)=Y, \exists !x\in (a,b)=X$ such that $g(y)=x=g(f(x))$. It is easy to check map $g$ is injective. So $g(y)=g(f(x))\Rightarrow y=f(x)$, which is exactly the definition of bijective map of $f$. Is this proof correct?
(2) Exercise $18.6$. Proof: it is easy to check $f(x)=\begin{cases} 0 &\text{ if } x\in \Bbb{Q} \\ x &\text{ if } x\in \Bbb{R}\setminus \Bbb{Q} \end{cases}$ is continuous only at $x=0$ by $\epsilon -\delta$ definition.
(3) Exercise $18.12$ (a) and (b). Proof: fix $y_0 \in \Bbb{R}$. $h$ is continuous, by theorem 4.4 of Baby Rudin. By exercise 1, $h$ is continuous in open set definition. Similarly $k$ is continuous. Hence $F$ is continuous in each variable. $g: \Bbb{R}\to \Bbb{R}$ defined by $g(x)=F(x\times x)$ is continuous at $\Bbb{R}\setminus \{0\}$. Is this proof correct?