I am trying to work out question 8.17 from the book 'Functional Analysis: an elementary introduction' by Haase. The question is formulated as follows. Let $(e_j)_{j\geq 1}$ be an orthonormal system in a Hilbert space $H$, and let $a_j \geq 0$ be scalars with $\sum_{j=1}^\infty a_j^2 < \infty$. Show that the set \begin{align} C := \left\{\left.\sum_{j=1}^\infty\lambda_j e_j\right|\, \lambda_j \in \mathbb{K},\,|\lambda_j| \leq a_j\right\} \end{align} is compact in $H$.
This is my attempted solution:
I would go with the definition of sequential compactness here. My plan was either to construct a pairwise orthogonal sequence. Then, showing that $
\sum_{j=1}^\infty \|f_n\|^2 < \infty$ would imply that $\sum_j f_n$ converges in H. I thought about using Bessel's inequality, which turns out here to be an equality, since for some $f\in C$ we have
\begin{align}
\langle f, e_k\rangle = \langle\sum_{j=1}^\infty \lambda_j e_j, e_k\rangle = \sum_{j=1}^\infty \lambda_j \langle e_j, e_k\rangle = \lambda_k.
\end{align}
Thus, we can write $f$ as follows
\begin{align}
f = \sum_{j=1}^\infty\lambda_j e_j = \sum_{j=1}^\infty\langle f, e_j\rangle e_j = Pf,
\end{align}
the standard abstract Fourier series.
From this, we can deduce that
\begin{align}
\|f\|^2 = \sum_{j=1}^\infty |\langle f,e_j\rangle |^2 = \sum_{j=1}^\infty |\lambda_j|^2 \left(\leq \sum_{j=1}^\infty a_j^2 < \infty\right),
\end{align}
using Pythagoras.
Now, To show that $C$ is compact we have to show that every sequence in $C$ has a converging subsequence. Let $(f_n)_{n\geq 1}$ be a sequence in $C$. Let $(f_{n_k})_{k\geq 1}$ be a subsequence, we need to show that $(f_{n_k})_{k\geq 1}$ converges to some $f$ in $C$.
Each $f_n$ is of the form
\begin{align}
f_n = \sum_{j=1}^\infty \lambda_{n,j} e_{n, j},
\end{align}
the coefficients, $\lambda_{n, \cdot}$, depend on $n$, and so does the 'positions', $e_{n, \cdot}$, where we place these coefficients. The sequence $(f_n)_{n\geq 1}$ is not pairwise orthogonal.
\begin{align}
\langle f_n, f_m\rangle = \left\langle \sum_{j=1}^\infty \lambda_{n, j}e_{n,j}, \sum_{k=1}^\infty \lambda_{m, k}e_{m,k}\right\rangle = \sum_{j=1}^\infty\sum_{k=1}^\infty \lambda_{n,j}\lambda_{m, k} \langle e_{n,j}, e_{m,k}\rangle
\end{align}
we can say nothing about the term $\langle e_{n,j}, e_{m,k}\rangle$.
We could also try to show that this set $C$ is closed in some other compact set $D$. But then we would have to construct some set $D$, and I do not really get far with this approach either.
Any help is much appreciated!