In this section, we first build the finite-range momentum-dependent two-body pseudopotential, based on general symmetry conditions, and next we derive a nonlocal nuclear EDF by the Hartree-Fock (HF) averaging of the pseudopotential over an uncorrelated many-body wavefunction. In this sense, the pseudopotential can be regarded as an EDF generator, and not as a true in-medium interaction. The derivation from the pseudopotential guarantees the functional to be free from the self-interaction problem. Indeed, after the EDF is built, all results are obtained by minimizing the EDF with respect to Kohn-Sham orbitals, whereupon the underlying pseudopotential is never more explicitly invoked. Moreover, the proposed nonlocal EDF is meant to be an approximation of the exact functional whose existence is guaranteed by the variational principle. As such, the corresponding results must be regarded as full solutions and not as pertaining to the HF approximation, which is the first order of the many-body perturbation theory.