When a forward bias is applied to a p-n junction