code: def calc_ionic(site, structure, zval):
      
      norms = structure.lattice.lengths_and_angles[0]
      return np.multiply(norms, -site.frac_coords * zval)
docs: Calculate the ionic dipole moment using ZVAL from pseudopotential
  
      site: PeriodicSite
      structure: Structure
      zval: Charge value for ion (ZVAL for VASP pseudopotential)
  
      Returns polarization in electron Angstroms.