num::spectral::debug::verify_parseval¶
Defined in header <spectral/debug.hpp>
template <class Plan>
requires transform_plan<Plan>
void verify_parseval(const Plan &plan, real tol = 1e-10,
std::source_location loc = std::source_location::current());
Verify Parseval's identity for a forward transform.
\[
\sum_n |x_n|^2 = \frac{1}{N} \sum_k |X_k|^2
\]
A transform that violates it is not unitary after normalization, and a spectral method built on it will gain or lose energy every step.