An electron density distribution n(r) which can be represented by that of a
single-determinant ground state of noninteracting electrons in an external
potential v(r) is called pure-state v-representablc (P-VR). Most physical
electronic systems are P-VR. Systems which require a weighted sum of severa
l such determinants to represent their density are called ensemble v-repres
entable (E-VR). This paper develops formal Kohn-Sham equations for E-VR phy
sical systems, using the appropriate coupling constant integration. It also
derives local density- and generalized gradient approximations, and condit
ions and corrections specific to ensembles.