Background: In quantum mechanics you are sometimes required to compute the overlap (inner product) of two wave functions (square integrable complex functions) $\Psi(x)$ and $\Phi_i(x)$ as $$ \lambda_i=\int dx\,\Psi^*(x)\,\Phi_i(x), $$ using Monte Carlo. This means rewriting the above equation as $$ \lambda_i=\int dx\,p(x) \frac{\Phi_i(x)}{\Psi^*(x)}, $$ where $p(x)=|\Psi(x)|^2$ is now interpreted as a probability distribution, and $x$ can e.g. be importance sampled on that distribution. For simplicity we assume that $\Psi$ and $\Phi_i$ are normalized such that $\int dx\,\left|\Psi(x)\right|^2=\int dx\,\left|\Phi_i(x)\right|^2=1$.
If the set of $\Phi_i$ form a complete set, and $\Psi$ and $\Phi_i$ are normalized, then $\sum_i\left|\lambda_i\right|^2=1$.
Problem: The above procedure will necessarily introduce errors into the computation of $\lambda_i$.
Assume that I can compute (with errors) all $\lambda_i$ except one, say $\lambda_0$. How do i estimate the value of $|\lambda_0|^2$, subject to the normalization constraint above?
The biggest problem that i don't know how to handle is that if there are many values where $\lambda_i=0$ the Monte Carlo will yield $|\lambda_i|>0$, and these will contribute to the normalization $\sum_i\left|\lambda_i\right|^2$ is such a way that the sum may be larger than 1.
Solution? I suppose the problem is that when generating the MC estimate of $\lambda_i$, the vectors $\Phi_i\left(x_n\right)$ that the MC-sampling produces will not be entirely orthogonal. The problem could the be fixed by orthogonalizing the space spanned by $\Phi_i\left(x_n\right)$ and then computing a new set of $\tilde\lambda_i$ from them. The missing vector overl shouls the be computable as $$\left|\lambda_0\right|^2=1-\sum_{i\neq0}\left|\tilde\lambda_i\right|^2$$
Is this reasonable? If so, how is the error of the desired $\left|\lambda_0\right|^2$ computed? Does this approach introduce any systematic errors?