pyiron_atomistics
pyiron_atomistics copied to clipboard
get_nelect() gives wrong number of electrons
Summary job.get_nelect() gives wrong number of electrons when not using default POTCAR files
Dear all,
I recently found out that the get_nelect() method for vasp jobs does not read from the input POTCAR files but use the values of the default pseudopotentials, which leads to wrong number of electrons. Here is a simple example demonstrating this error.
struct = pr.create_atoms('Cr', pbc = True, cell = 10* np.eye(3))
job = pr.create_job(pr.job_type.Vasp, 'Cr')
job.structure = struct
job.potential.Cr = '/u/system/soft/pyiron/dev/pyiron-resources-cmmc/vasp/potentials/potpaw_PBE/Cr_sv/POTCAR'
print(job.get_nelect())
pyiron gives the default 12 electrons instead of 14 electrons as in the potcar file set. It would be nice to get this fixed as a number of us are doing charged cell calculations.
Best, Jing
I don't have a solution but just want to point out that Sphinx
doesn't offer this functionality at all, but I think it should. If we're touching this code we should also think about moving the function to GenericDftJob
.