What is the trace of the integral operator $(\mathcal{L}f)(x)=\int_0^\infty (x \wedge y)f(y) \, d \pi(y)$? Let $\pi$ denote a probability measure on $[0,+\infty)$ and let us assume that
$$m:=\int_0^\infty x \, \mathrm{d} \, \pi(x)<+\infty.$$
Let us consider the integral operator $\mathcal{L}$ on $L_2(\pi)$ defined by
$$(\mathcal{L}f)(x)=\int_0^\infty (x \wedge y)f(y) \, d \pi(y)$$
One can show that $\mathcal{L}$ is self-adjoint and positive semidefinite.
We can show that $\mathcal{L}$ is in the trace class and that the trace of $\mathcal{L}$ is less than or equal to $m$. 
Is it actually equal to $m$?
We could not find this in standard textbooks on functional analysis (Lax, Yoshida, Reed-Simon)
 A: Most probably this question has more standard explanation, but you may use that for continuous Kernels $K(x,y)$ on a standard metric measure space $(X,\mu,\rho)$ ($(X,\mu)$ is a standard probabilistic space, $\rho$ an admissible metric, where admissiblity means that $\rho(x,y)$ is measurable on $X\times X$ and separable on a set of full measure) we have $\int K(x,x)\,d\mu(x)= \operatorname{tr}\mathcal{K}$ provided that the integral operator $\mathcal{K}$ with kernel $K$ is of trace class. 
This may be proved by approximating $\mathcal{K}$ in a trace class by finite rank operators with kernels $\sum_{i=1}^N f_i(x)g_i(y)$, $f_i,g_i\in L^2(X)$ (such a possibility follows from a representation of $\mathcal K$ as an infinite convergent sum $\sum s_i \langle v_i,\cdot \rangle u_i$ for unit vectors $v_i,u_i$, where $s_i$ are singular numbers of $\mathcal K$) and the check that convergence in $S^1$-norm implies the convergence of the integral of kernels over diagonal to $\int K(x,x)\,d\mu(x)$. It may be  deduced from Theorem 15 in [A. M. Vershik, P. B. Zatitskiy, and F. V. Petrov. Virtual continuity of measurable functions and its applications. Russian Mathematical Surveys 69:6 (2014), 1031–1063]: the convergence in $S^1$ implies the convergence in $VC^1$ which implies the convergence of the integral over diagonal (defined both for finite rank kernels and for cotinuous kernels.)
