Two-dimensional simulation of the effects of grain boundaries on the C–V characteristics of P+N polysilicon diodes