Let \(X\succeq0\), \(K(u)=K_0+uK_1\) and \(\bar K=\mathbb E[K(U)]\). For a scalar \(U\) of finite second moment,

Read the diagram in words
Averaging the quadratic action retains a covariance contribution. Applying the averaged matrix first loses that contribution even though the diagonal matrices commute. The example uses the stated uniform probability measure, so density values and mass are interpreted relative to that measure.
For the uniform probability measure \(\mu(du)=du/2\) on \([-1,1]\), take
Then \(\bar K=I/2\). The averaged congruence is \(I/2\), with trace one. Congruence by the averaged matrix is \(I/8\), with trace \(1/4\). The omitted covariance correction is \(3I/8\).
The mathematical point
The missing term is positive semidefinite and carries three quarters of the mass in this one-bin example. With \(n\) equal bins, the missing mass is \(3/(4n^2)\).
Scope
The matrices in this example are diagonal and commute. The failure concerns the order of averaging and forming a quadratic action. A density value is interpreted relative to its declared measure.
Formal route
See P57–P58 in the formal coverage map for exact integral and bin identities.