We study propagation of low-intensity light in a medium within a one-dimens
ional (1D) model electrodynamics. It is shown that the coupled theory for l
ight and matter fields may be solved, in principle exactly, by means of sto
chastic simulations that account for both collective linewidths and line sh
ifts, and for quantum statistical position correlations of the atoms. Such
simulations require that one synthesize atomic positions that have correlat
ion functions appropriate for the given type of atomic sample. We demonstra
te how one may simulate both a Bose-Einstein condensate (BEC) and a zero-te
mperature noninteracting Fermi-Dirac gas. Results of simulations of light p
ropagation in such quantum degenerate gases are compared with analytical de
nsity expansions obtained by adapting the approach of Morice, Castin, and D
alibard [Phys. Rev. A 51, 3896 (1995)] to the ID electrodynamics. A BEC exh
ibits an optical resonance that narrows and stays somewhat below the atomic
resonance frequency as collective effects set in with increasing atom dens
ity. The first two terms in the analytical density expansion are in excelle
nt agreement with numerical results for a condensate. While fermions displa
y a similar narrowing and shift of the resonance with increasing density,al
ready in the limit of very dilute gas the linewidth. is only half of the re
sonance linewidth of an isolated atom. We attribute this to the regular spa
cing between the atoms, which is enforced by the Pauli exclusion principle.
The analytical density expansion successfully predicts the narrowing, and
also gives the next term in the density expansion of the optical response i
n semiquantitative agreement with numerical simulations. [S1050-2947(99)058
01-1].