Why is $np$ always equal to $n_i^2$? For you guys who studied semiconductor physics must be familiar with the equation: 
$$np=n_i^2$$
I can understand why this is true for the intrinsic case (the broken bonds would always provide electron and hole in pairs )
But why is this still true for doped semiconductors? Take Si for example, $n=p=n_i=10^{10}$ in intrinsic case (that's we all know). However, if you dope $10^{15} N_d$ into the material, then $n\sim10^{15}$ and $p \sim 10^5$. The highlighted part is my confusion! Why does $p$ become smaller? Where do the holes go?
 A: Electrons and holes occupy their states according to the Fermi-Dirac distribution, which has a single parameter $E_f$, the Fermi level (assume a fixed temperature). Provided $E_f$ is in within the band gap and far from the band edges, the (energy integral of) Fermi-Dirac takes an exponential form $\propto e^{E_f}$ for electrons and $\propto e^{-E_f}$ for holes. Note that electrons and holes share the same Fermi level as we are in chemical equilibrium. You can already see that the product of electrons and holes is independent from $E_f$ in above conditions. Therefore $pn$ remains equal to $p_0n_0 = n_i^2$. In this picture, doping the semiconductor merely moves the Fermi level up (in case of donors) and down (in case of acceptors). Enforcing charge neutrality yields: $n=N_d^+ + p$. But $p$ is really small here, therefore $n\approx N_d^+$ and $p\approx n_i^2/N_d^+$.
To answer your question "where do holes go": holes are absence of electrons in the valence band, or in general the number of empty states in the valence band. When you put in donor dopants you inject electrons, which in turn fill some of these empty states and annihilate holes.
A: 
"Why is $np$ always equal to $n_i^2$ ?"

Well, first of all, the easy way to answer your question "Why is $np$ always equal to $n_i^2$ ?" would be simply to notice that $np$ is independent of the Fermi level $E_F$, and thus independent on the fact that the semiconductor is doped or not.
In the case of a non-degenerate semiconductor (i.e. when $E_F$ is inside the gap), you can approximate the carrier densities as :
$$
n=N_c\exp\left(\frac{E_F-E_c}{k_BT}\right)\quad\text{and}\quad p=N_v\exp\left(-\frac{E_F-E_v}{k_BT}\right)
$$
where $E_c$ stands for the lower energy of conduction band, and $E_v$ the upper energy of the valence band. When doping the semiconductor, only the value of $E_F$ changes.
Then it goes :
$$
np=N_c\,N_v\,\exp\left(-\frac{E_g}{k_BT}\right)
$$
where $E_g=E_c-E_v$ is the gap energy, which does not change when doping the semiconductor.

"Where do holes go?"

To the second question "Where do holes go?" when doping N for instance, I would say "Nowhere because there is none actually!". Just recall that doping a semiconductor allows you to have an assymetry in the carrier densities by construction :


*

*In an intrinsic semiconductor, if you want to put an electron in the conduction band, you need to create thermally a hole in the valence band. That is why $n=p$.

*In a N doped semicondutor for instance, if you want to put an electron in the conduction band, you can :


*

*thermally create a hole in the valence band just as in the intrinsic case. However, the probability of such event to happen scales roughly as $\propto\exp(-E_g/k_BT)$ which can be very weak at "low temperature", in particular when $E_g\gg k_BT$.

*thermally ionize a dopant impurity. The probability of such event roughly scales as $\propto\exp(-E_\ell/k_BT)$ where $E_\ell$ is ionization energy of the impurities. Typically, you will have $E_\ell\sim 10\,\text{meV}$ compared to $E_g\sim 1\,\text{eV}$, which means that impurity ionization process is far more probable than the usual intrinsic process.



When an impurity is ionized, it does not create a hole in the valence band, that is why it is possible to have $n\neq p$.
A: One way to think about it is similar to a chemical equilibrium. Electron-hole pairs are spontaneously generated every now and then from random thermal fluctuations, and when an electron collides with a hole they annihilate with each other (some fraction of the time).
The frequency with which electrons and holes collide is $np$. In steady-state, this quantity needs to be fixed, to balance out the generation rate.
So intuitively, imagine an $n$-doped semiconductor. There are a gazillion electrons everywhere. Occasionally an electron-hole pair will be spontaneously generated, but the hole will almost immediately bump into an electron, and then another and then another, and very soon, the hole will be annihilated. The consequence: Very few holes at any given moment! The only holes you see are the holes that were just generated a moment ago.
