A counterexample of Riesz Representation Theorem? I am working on the exercise 6.B.15 from Axler's book: Linear Algebra Done Right. This problem states that the Riesz Representation Theorem may fail on an infinite-dimensional vector space:


*Suppose $C_R([-1,1])$ is the vector space of continuous real-valued functions on the interval $[-1,1]$ with inner product given by:

$$\left<f,g \right> = \int_{-1}^{1}f(x)g(x)dx$$
for $f, g \in C_R[-1,1]$. Let $\varphi$ be the linear functional on $C_R[-1,1]$ defined by $\varphi(f)=f(0)$. Show that there does not exist $g \in C_R[-1,1]$ such that
$$
\varphi(f)= \left< f, g \right>
$$
for every $f \in C_R[-1,1]$.
My argument is that I came up with two special sequences of functions in $C_R[-1,1]$, and proved a contradiction:
Consider $f_{n}, h_{n} \subset C_{\mathbb{R}}[-1,1]$, defined by
$$
    f_{n}(x)=
\begin{cases}
    1, ~ x \in [0,1] \\
    n x + 1, ~  x \in [-\frac{1}{n},0] \\
    0, ~  x \in [-1,-\frac{1}{n}]
\end{cases}
$$
and
$$
    h_{n}(x)=
\begin{cases}
    1, ~ x \in [-1,0] \\
    -n x + 1, ~  x \in [0,\frac{1}{n}] \\
    1, ~  x \in [\frac{1}{n},1]
\end{cases}
$$
Then
$$ f_n \to f $$ and $$h_n \to h$$ where $f = 0$ on $[-1,0]$, $f = 1$ on $[0,1]$, while $h = 0$ on $[0,1]$ and $h=1$ on $[-1,0]$.
Then for any $n \in \mathbb{N}$,  we have $\varphi(f_{n}) = f_{n}(0) = 1$ and $\varphi(h_{n}) = h_{n}(x) = 1$.
For any constant function $T_{m}(x) = m \neq  0$ on $[-1,1]$, $\varphi(T_{m}) = \left< T_{m}, g \right> = T_{m}(0)= m = \int_{-1}^{1}m g(x)\,\mathrm{d}x$. As a result, then $$
    \int_{-1}^{1}g(x)\,\mathrm{d}x = 1.
$$
It implies that $g \in L^{1}[-1,1]$. So $\left\vert f_{n} g \right\vert \leqslant \left\vert g \right\vert $ and $\left\vert  h_{n} g \right\vert  \leqslant \left\vert g \right\vert $. By the LDCT,
\begin{align*}
    \lim_{n    \to \infty} \int_{-1}^{1}f_{n}(x)g(x)\,\mathrm{d}x = 1 = \int_{-1}^{1}f(x)g(x)\,\mathrm{d}x = \int_{0}^{1}g(x)\,\mathrm{d}x.
\end{align*}
The same argument applies to $h_{n}$, then we have $$
    \int_{-1}^{0}g(x)\,\mathrm{d}x = 1
$$
and then $$
    \int_{-1}^{1}g(x)\,\mathrm{d}x = \int_{-1}^{0}g(x)\,\mathrm{d}x + \int_{0}^{1}g(x)\,\mathrm{d}x = 2
$$
which contradicts with $\int_{-1}^1 g(x) dx = 1.$
My question is, if this argument is legitimate, why such contradiction could arise? Is it because the inner product space is not Hilbert?
 A: You can simplify the argument a bit by letting $f_n(x)= (1-|x|)^n.$ Then $f_n(0)=1$ for all $n.$
Let $g\in C_{\mathbb R}[-1,1].$ Set $M=\max_{[-1,1]}|g|.$ Then
$$|\int_{-1}^1 f_n(x) g(x)\,dx | \le \int_{-1}^1 |f_n(x) g(x)|\,dx$$ $$ \le M \int_{-1}^1 f_n (x)\,dx =2M\int_0^1(1-x)^n\,dx = \frac{2M}{n+1}\to 0.$$
Thus no $g\in C_{\mathbb R}[-1,1]$ can represent $\varphi$ via the inner product.
A: Suppose there did exists such a $g$. Then
$$
        |f(x)| \le \|f\|_{L^2}\|g\|_{L^2}=C\|f\|_{L^2}
$$
That would mean that every $f$ in the space would be bounded at $x$ by a fixed constant times $\|f\|_{L^2}$. Clearly $C\ne 0$; so you can contradict that by finding $f_n$ such that $\|f_n\|\rightarrow 0$ and $f_n(x)=1$, which is not a hard task.
A: Motived by  @user10354138, we can show the map $\varphi$ is not bounded, or equivalently, not continuous.
For any $\varepsilon>0$, put a sequence of functions $$f_n(x)= \begin{cases} 
\sqrt{\varepsilon}, x \in [-1, -1/n] \bigcup [1/n,1] \\ n (1-\sqrt{\varepsilon})x + 1, x \in [-1/n,0] \\ -n(1-\sqrt{\varepsilon})x +1, x \in [0,1/n]\end{cases} $$.
Then $$||f_n||_{L^2}$$ can be sufficiently small as $\varepsilon \to 0$ and $n \to \infty$.
So $$||\varphi|| = \sup\limits_{f \neq 0, f \in C_R[-1,1]} \frac{f(0)}{||f||} \geqslant \frac{f_n(0)}{||f_n||_{L^2}}=\frac{1}{||f_n||_{L^2}} \to \infty.$$
Hence, the map $\varphi$ is not continuous.
