  Density functional approximations to the exchange-correlation energy of
Kohn-Sham theory, such as the local density approximation and generalized
gradient approximations, lack the well-known integer discontinuity, a feature
that is critical to describe molecular dissociation correctly. Moreover,
standard approximations to the exchange-correlation energy also fail to yield
the correct linear dependence of the ground-state energy on the number of
electrons when this is a non-integer number obtained from the grand canonical
ensemble statistics. We present a formal framework to restore the integer
discontinuity of any density functional approximation. Our formalism derives
from a formula for the exact energy functional and a new constrained search
functional that recovers the linear dependence of the energy on the number of
electrons.
