  We calculate the electronic structure for a modulation doped and gated
T-shaped quantum wire using density functional theory. We calculate the bandgap
renormalization as a function of the density of conduction band electrons,
induced by the donor layer and/or the gate, for the translationally invariant
wire, incorporating all growth and geometric properties of the structure
completely. We show that most of the bandgap renormalization arises from
exchange-correlation effects, but that a small shift also results from the
difference of wave function evolution between electrons and holes. We calculate
the binding energy of excitons in the wire, which breaks translational
invariance, using a simpler, cylindrical model of the wire. For a single hole
and a one dimensional electron gas of density n_e, screening of the exciton
binding energy is shown to approximately compensate for bandgap
renormalization, suggesting that the recombination energy remains approximately
constant with n_e, in agreement with experiment. We find that the nature of
screening, as treated within our non-linear model, is significantly different
from that of the various linear screening treatments, and the orthogonality of
free carrier states with the bound electron states has a profound effect on the
screening charge. We find that the electron and hole remain bound for all
densities up to about 3 x 10^6 cm^{-1} and that, as n_e increases from zero,
trion and even ``quadron'' formation becomes allowed.
