# Continuity of the sum of continuous functions

Let $X$ be a topological space and $f:X\to \mathbb{R}$ and $g:X\to \mathbb{R}$ be continuous functions. How do I show that $h:X\to \mathbb{R}$ where $h:=f+g$ is continuous, would prefer to use the general definition so for and open $U$ in $\mathbb{R}$, $h^-(U)$ is open. Also if $Y$ is another top space and $k:Y\to \mathbb{R}$ is also a continuous function, how do I show $l:X\times Y\to \mathbb{R}$, defined by $l:=f+k$ is also continuous. Any help please. Thanks in advance.

## 2 Answers

You should consider the maps

• $(f,g)\colon X → ℝ × ℝ,\; x ↦ (f(x),g(x))$,
• $f × k \colon X × Y → ℝ × ℝ,\; (x,y) ↦ (f(x),k(y))$, and
• $(+)\colon ℝ × ℝ → ℝ,\; (a,b) ↦ a+b$.

If you can show continuity for all of these maps, you have also shown continuity for $f + g = (+) ∘ (f,g)$ and $f + k = (+) ∘ (f × k)$ (not sure if “$f+k$” isn’t a bit of a misleading notation here).

For the continuity of $(+)$: For any $c ∈ ℝ$, every $ε/2$-maximum-ball around any preimage $(a,b) ∈ (+)^{-1}(c)$ stays within an $ε$-ball of $c$ by the triangle inequality. This implies that preimages of open sets are open. (Essentially: $|(a' + b') - (a + b)| ≤ |a-a'| + |b-b'|$.)

• Can you explain in more detail, also preferred strategy is to use the definition that the preimage of open set is open, for the + function you defined know there is a quick way using sequences but not definition I need to use. Thanks again – Jens Apr 8 '14 at 9:15
• @Jens Is that okay? – k.stm Apr 8 '14 at 9:41
• One could replace the first bullit point with continuity of the diagonal map $\Delta\colon X\to X\times X$, $x\mapsto (x,x)$. Then $f+g = (+)\circ(f\times g)\circ \Delta$. For the continuity of $\Delta$, the preimage of a basic open set $U\times V$ is $U\cap V$, hence open. – Hagen von Eitzen Apr 8 '14 at 9:55
• Not quite sure, how do I know $(+)^-[B(c,\epsilon/2)]$ is the Cartesian product of 2 open balls in $\mathbb{R}$ with radius $\epsilon$, is that what you are saying or am I confusing things. Can you clear things up for me? Thanks again, really appreciate it. Also how do I show that the map $X\to \mathbb{R}$ defined as $x\mapsto |f(x)|$ is continuous using just the open preimage definition of continuity? – Jens Apr 8 '14 at 14:45
• @Jens I didn’t characterize the preimage of an open ball around $c$, but I instead said that any point in this preimage has an open neighbourhood within the preimage. The cartesian products of open sets in $ℝ$ is open in $ℝ × ℝ$. I firmly believe you can show the continuity of the absolute value yourself using the same trick. Ask again if you couldn’t manage to do so. – k.stm Apr 8 '14 at 16:41

Let us define the shift in x operator: \begin{eqnarray} S_x : \mathbb{R}^2 &\to& \mathbb{R}^2 \\ (x,y) &\mapsto& (x + x, y+x) \end{eqnarray}

It is easy to prove that this is continuous using open balls.

Pick $(x,y) \in \mathbb{R}$ then $S_x(x)=(2x, x+y)$. An arbitrary open ball around $S_x[(x,y)]$ is $B[ (2x, x+y), r]$, Now $S^{-1}[B(2x, x+y),r]] = B[(x,y),r]$, so $S_x$ is continuous.

Define \begin{eqnarray} h : X &\to& \mathbb{R}^2 \\ x &\mapsto& (f(x), g(x)). \end{eqnarray}

Let us now assume that $f : X \to \mathbb{R}$, and $g : X \to \mathbb{R}$ are continuous. We show that \begin{eqnarray} f+g : X &\to& \mathbb{R} \\ x &\mapsto& f(x) + g(x) \end{eqnarray} is continuous.

Since $$S_x[h(x)]= [2 f(x), f(x)+g(x)]$$ and:

(i) Since $f(x)$ and $g(x)$ are continuous then $h(x)$ is continuous, from the product topology continuity of a function is equivalent of continuity of all its projections.

(ii) The function composition is continuous, that is $S_x \circ h: A \to \mathbb{R}^2$ is continuous.

(iii) Since $S_x \circ h$ is continuous its components $2 f(x)$ and $f(x)+g(x)$ are continuous.

So $f+g$ is continuous.