An exchange energy functional based on the Dirac and the Fermi–Amaldi approximations