Hartree-Fock by varying the coefficients of a wave function expansion

It is normal to choose a single-particle basis defined as the eigenfunctions of parts of the full Hamiltonian. The typical situation consists of the solutions of the one-body part of the Hamiltonian, that is we have $$ \hat{h}_0\phi_{\lambda}=\epsilon_{\lambda}\phi_{\lambda}. $$ The single-particle wave functions \( \phi_{\lambda}({\bf r}) \), defined by the quantum numbers \( \lambda \) and \( {\bf r} \) are defined as the overlap $$ \phi_{\lambda}({\bf r}) = \langle {\bf r} | \lambda \rangle . $$