Relationship between Na, K, Mg, and Ca ionization potentials