In the previous post, we looked at p & n type semiconductors. These are more useful when combined together to form something called the P-N junction.
The p-doped region has holes as its majority charge carriers & the n-doped region has free electrons as its mobile charge carriers. Hence, the holes & free electrons attract & eliminate each other. This process is called recombination.
Thus, due to the diffusion of the charge carriers, a potential difference gets established in the region of recombination. This potential is called the barrier potential or the space charge potential & the region is called the depletion region.
The device resulting from the p-n junction is called a p-n junction diode or simply, a diode. P-N junctions are also used in transistors & rectifiers.