The calculation of the electron density starts by assuming that the semiconductor is neutral so that there is a zero charge density in the material. The hole concentration in equilibrium is written as a function of the electron density by using the mass action law. This yields the following relation between the electron density and the ionized impurity densitie