# Prove the support of a real function is countable

This is a problem from my real analysis homework. We are learning the countable sets, and have yet to reach uncountable sets.

Let $$f$$ be a real function defined on $$[0, 1]$$. There exists a constant $$M$$, such that for each finite $$n$$, and $$0 \le x_1 < x_2 < \cdots < x_n \le 1$$, we have

$$|f(x_1) + f(x_2) + \cdots + f(x_n)| \le M.$$

Prove $$E \stackrel{\text{def}}{=} \{x \in [0, 1] : f(x) \ne 0\}$$ is countable.

My attempt

I split $$E$$ into two parts,

\begin{align} E^{+} &\stackrel{\text{def}}{=} \{x \in [0, 1] : f(x) > 0\} \\ E^{-} &\stackrel{\text{def}}{=} \{x \in [0, 1] : f(x) < 0\} \end{align}

A classmate suggested considering $$f(x) > \frac{1}{n}$$ and $$f(x) \le \frac{1}{n}$$ from $$E^{+}$$ separately, and proving for each $$n$$ both part have finite amount of elements, but I didn't gain much from her hint.

Another path I have taken is letting

\begin{align} E' &\stackrel{\text{def}}{=} \{x \in E : \exists \delta_x > 0, (x, x+\delta_x) \cap E = \varnothing \} \\ E'' &\stackrel{\text{def}}{=} E \setminus E' \end{align}

I can prove $$E'$$ is countable, but $$E''$$ is still tricky even though it contains less or equal elements than $$E$$.

Proof by contradiction didn't yield any significant result, either.

• Terminological remark: usually, the set $E$ you define is not called the support, but rather its closure is. For instance, if you consider a function which is nonzero precisely at the rational numbers, then its support would be all of $[0,1]$. This doesn't impact the question because of how it's phrased, but it's something to be aware of. – Wojowu Mar 2 at 9:20
• The trick is always the same; the nonzero reals can be partitioned into countably many sets each of which is strictly bounded away from zero. Remember this trick for real analysis and measure theory. – user21820 Mar 2 at 10:06
• @Wojowu Thanks for pointing that out! Initially I wasn't sure if it's the correct term, so I consulted Wikipedia, and that appears to be the definition of a support? To quote, "In mathematics, the support of a real-valued function f is the subset of the domain containing those elements which are not mapped to zero." – nalzok Mar 2 at 10:52
• Your classmate's suggestion might be slightly better as considering $f(x) > \frac{1}{n}$ and $f(x) \lt -\frac{1}{n}$ from $E$ separately, and proving for each $n$ both parts have a finite number of elements – Henry Mar 2 at 13:50
• @Henry I could have misunderstood her point... – nalzok Mar 2 at 13:56

A classmate suggested considering $$f(x) > \frac{1}{n}$$ and $$f(x) \le \frac{1}{n}$$ from $$E^{+}$$ separately, and proving for each $$n$$ both part have finite amount of elements, ...
Your classmate is on the right track, but it suffices to show that there are (at most) finitely many points with $$f(x) > \frac{1}{n}$$ in $$E^{+}$$.
For each $$n \in \Bbb N = \{ 1, 2, 3, \ldots \}$$ define $$E^{+}_n = \left\{x \in [0, 1] : f(x) > \frac 1n \right\}$$ Then $$E^{+}_n$$ has at most $$nM$$ elements. It follows that $$E^{+} = \bigcup_{n \in \Bbb N} E^{+}_n = \{x \in [0, 1] : f(x) > 0\}$$ is countable (as the countable union of finite sets).
In the same way (or by applying the above argument to $$-f$$) it can be shown that $$E^{-}$$ is countable as well.
Remark: The domain of $$f$$ (in your case: the interval $$[0, 1]$$) is irrelevant for this conclusion. The same statement holds for a real-valued function $$f$$ defined on an arbitrary set $$X$$.