How to calculate the grounding of the battery