A random network model containing defects has been developed and applied to
the deposition of amorphous SiOx films on a flat substrate. A new Monte Ca
rlo procedure enables dangling bonds to migrate and annihilate. The degree
of porosity in the films is found to increase with oxygen content. As the o
xygen content increases a larger fraction of pore surfaces is covered with
oxygen, and the density of dangling bonds on pore surfaces decreases. Oxyge
n plays the role of a surfactant, lowering the energies of pore surfaces an
d enhancing the porosity of amorphous SiO2 compared to amorphous Si.