# Statement(s)
> [!NOTE] Statement 1 (....)
> Contents
# Proof(s)
We prove by constructing examples.
###### Example 1:
We will construct an example based on the sawtooth function. Consider
$
\phi(x)= \begin{cases}x-|x| & x \leqslant|x|+\frac{1}{2} \\ 1-x+|x| & x>|x|+\frac{1}{2} .\end{cases}
$
```run-pyhton
```
The function $\phi$ is equal to the distance function from $x$ to $\mathbb{Z}$.
We define, for $n=0,1, \ldots$
$
f_n(x)=\frac{1}{4^n} \phi\left(4^n x\right)
$
We will show that $f(x)=\sum_{n-0}^{\infty} f_n$ is continuous but nowhere differentiable. Notice that
$
0 \leqslant f_n \leqslant \frac{1}{4^n} \phi \leqslant \frac{1}{2} \frac{1}{4^n},
$
and that by the Weierstrass M -test we have the uniform convergence of the series. Since each $f_{\mathrm{n}}$ is continuous, and the convergence is uniform we have that $f$ is $C^0$.
Given $x \in \mathbb{R}$ we will choose the sign of $h_n= \pm \frac{1}{4^{n+1}}$ in such a way that the points $4^n x$ and $4^n\left(x+h_n\right)$ both belong to the same interval of length $1 / 2,\left[\frac{k}{2}, \frac{k+1}{2}\right]$ for some $k \in \mathbb{Z}$. We make this choice of sign for $h_n$ because on each of these intervals $\left[\frac{k}{2}, \frac{k+1}{2}\right]$, the function $\phi$ has constant slope +1 or -1 .
Consider the incremental quotient
$
\frac{f_n\left(x+h_n\right)-f_n(x)}{h_n}=\frac{\phi\left(4^n x+4^n h_n\right)-\phi\left(4^n x\right)}{4^n h_n}= \pm 1 .
$
Moreover, if $m<n$ the graph of $f_m$ also has slope $\pm 1$ on the interval in which $x$ and $x+h_n$ belong to.
Therefore
$
\epsilon_m:=\frac{f_m\left(x+h_n\right)-f_m(x)}{h_n}=\frac{\phi\left(4^m x+4^m h_n\right)-\phi\left(4^m x\right)}{4^m h_n}= \pm 1 .
$
However for $m \geqslant n+1$ we have (since $4^m x+4^m h_n-4^m x=+4^m h_n= \pm 4^{m-n-1} \in \mathbb{Z}$ )
$
f_m\left(x+h_n\right)-f_n(x)=\frac{1}{4^m}\left(\phi\left(4^m x+4^m h_n\right)-\phi\left(4^m x\right)\right)=0 .
$
Therefore
$
A_n:=\frac{f\left(x+h_n\right)-f(x)}{h_n}=\sum_{m=0}^n \frac{f_m\left(x+h_n\right)-f_m(x)}{h_n}=\sum_{m=0}^n \epsilon_m .
$
Therefore $A_n$ is an even integer if $n$ is odd and an odd integer if $n$ is even. Hence there is no limit as $n$ goes to infinity. Since $h_n$ goes to zero that proves that $f$ is not differentiable.
$\blacksquare$