What electrons should one count? Only those mentioned in PP?NELECT
\begin{displaymath} NELECT = \mbox{number of electrons} \end{displaymath}
Usually you should not set this line -- the number of electrons is determined automatically.
If the number of electrons is not compatible with the number derived from the valence and the number of atoms a homogeneous background-charge is assumed.
If the number of ions specified in the POSCAR file is 0 and NELECT=n, then the energy of a homogeneous LDA-electron gas is calculated.
For example, lithium (POTCAR): VRHFIN =Li: s1p0
So if one needs lithium ion, NELECT = 0?
For Ca_pv: VRHFIN =Ca: p6s2d0.01
So, for calcium ion (Ca2+): NELECT = 6 + 2 + 0 - 2 (ionization) = 6.
Right?
Thanks.