Calculation and analysis of electric fields