Proof for Sturm Liouville eigenfunction expantion pointwise convergence theorem

In "Elementary Partial Differential Equation" by Berg and McGregor, the following theorem is given without proof:

Let $f(x)$ be piecewise smooth on the interval $[a,b]$ and let $\{\varphi_n(x)\}$ be the eigenfunctions of a self-adjoint regular Sturm-Liouville problem. Then for each value of $x$ in $[a,b]$, the Fourier series of $f(x)$ relative to $\{\varphi_n(x)\}$ converges, and $$\sum_{k=0}^\infty a_k\varphi_k(x)=\frac{f(x^+)+f(x^-)}{2}\qquad a<x<b$$

I am wondering about two things:

1. Where can I find the proof for this theorem?
2. Can the condition on $f$ can be weakened to piecewise continuity and the existence of one-sided derivatives on each point, as in Dirichlet theorem for periodical Fourier series (where the Sturm-Liouville problem is with periodical BC)?

The Sturm-Liouville eigenvalue problem is $$-(py')'+qy = \lambda wy,\;\;\; a \le x \le b,$$ subject to separated endpoint conditions at $x=a,b$.
Suppose that $p$, $w$ are positive and twice continuously differentiable on $[a,b]$, and further suppose that $q$ is continuous on $[a,b]$. Then, after a change of independent and dependent variables, the equation can be put into potential form on a new interval: $$-f''+Qf = \lambda f,\;\;\; c \le x \le d.$$ The function $Q$ will be continuous under the stated assumptions. The regular endpoint conditions for $y$ are transformed to regular endpoint conditions for $f$. If $|Q|\le M$ on $[c,d]$, then, for eigenvalues $\lambda >> M$, it follows that the solutions $f$ are asymptotically close to solutions of $-f''=\lambda f$ with the transformed endpoint conditions. In this way, the Fourier series of eigenfunctions for the regular problem is shown to be converge in the same was as the Fourier series of trigonometric functions associated with the second problem in $f$.
So convergence is reduced to the study of the Fourier expansions associated with the problem $$-f'' = \lambda f, \;\;\; c \le x \le d,$$ with regular endpoint conditions at $c$, $d$. The trigonometric expansions must be handled in order to complete the proof of a general problem, but that's the general idea. The end result is this: The Fourier series for a function $g$ on $[c,d]$ in the trigonometric series associated with the reduced problem converges to a limit $L$ iff the Sturm-Liouville eigenfunction expansion in the eigenfunctions of $-f''+Qf=\lambda f$ converges to $L$.
• @MOMO : The result for the potential form $-f''+Qf=\lambda f$ with separated endpoint conditions is handled in the book by E. C. Titchmarsh I referenced, in the first chapter. I don't know if the substitution is recorded in Titchmarsh, but that should be easy to find otherwise. – DisintegratingByParts Mar 15 '17 at 21:10