$C[0,1]$ is not Hilbert space

Solution 1:

Let $f_n:[-1,1]\to\mathbb R$ be such that $$f_n(t)=\begin{cases}1, & \text{if $t\in[-1,0];$} \\1-nt, & \text{if $t\in[0,\tfrac1n]$;} \\ 0, & \text{otherwise.}\end{cases}$$

According to Mathematica, we have $\lVert f_n-f_m\rVert=\frac{(m-n)^2}{3 m^2 n}$ if $1<n<m$ so this is indeed a Cauchy sequence.

In[1]:= f[n_] := Piecewise[{{1, t < 0}, {1 - n t, 0 <= t <= 1/n}}];

In[2]:= Integrate[(f[n]-f[m])^2, {t, -1, 1},  Assumptions-> 1<n<m] 

               2
        (m - n)
Out[2]= --------
            2
         3 m  n

Can you show it does not converge?

Solution 2:

An alternative way (sledgehammer): if $C[0,1]$ where an Hilbert space then the linear continuous map $L\colon f\mapsto \int_0^{\frac 12}f(t)dt-\int_{\frac 12}^1f(t)dt$ would be represented by $g_0$.

Let $x\in (0,1/2)$ be fixed. Then consider a function $f_n$ such that $f_n(t)=1$ if $t\lt x$, $0\leqslant f_n\leqslant 1$ and $f_n(t)=0$ if $t\gt x+1/n$. We have $$\lim_{n\to +\infty}L(f_n)=x=\lim_{n\to +\infty} \int_0^{x+1/n}g_0(t)f(t)\mathrm dt,$$ and the last limit is $\int_0^xg_0(t)\mathrm dt$. This proves that $g_0(t)=1$ for each $t\in (0,1/2)$. Similarly, we can prove that $g_0(t)=-1$ for each $t\in(1/2,1)$, hence $g_0$ cannot be continuous.