[gpaw-users] orbital_ldos

Ask Hjorth Larsen asklarsen at gmail.com
Mon May 14 16:04:57 CEST 2012


Hi

2012/5/14 Rico Friedrich <friedrir at mailserver.tu-freiberg.de>:
> Dear GPAW users,
>
> we do calculations of molecules on surfaces and want to use the
> following piece of code to obtain the part of the DOS belonging to the
> molecule:
>
> atoms = calc.get_atoms()
>
> tidx = np.where(atoms.get_tags() == 0)[0]
> #print tidx
> dos = np.zeros((nspins + 1, npts), dtype='d')
> for s in range(nspins):
>     doss = np.zeros(npts, dtype='d')
>     #print doss.shape
>     for i in tidx.tolist():
>         parprint('  Spin {0}, Atom {1}'.format(s,i))
>         if not dryrun:
>             _e, _d = calc.get_orbital_ldos(i,
>                 spin=s,
>                 angular='spdf',
>                 npts=npts,
>                 width=width
>             )
>             #print _d.shape
>             doss += _d
>     dos[s+1] = doss
>     dos[0] = _e
>
>
> However when we plot the obtained DOS for spin up and spin down and
> integrate from the lowest energy to the fermi level then we get far
> bigger values than the number of electrons to be expected on the
> molecule. Then we tried "get_all_electron_ldos" instead of
> "get_orbital_ldos" but even got worse results. Is there some kind of
> weighting we neglected so far? Thanks in advance.
>
> Best,
>
> Rico

Yes, the PDOS it is unfortunately quite useless for counting electrons
because the basis of projector functions is neither complete nor
orthonormal.  If you use LCAO mode, there's a direct way to get the
correctly normalized PDOS on the atomic orbitals which is *sort of*
implemented, except not checked into the code yet.  This we should
probably do at some point.  Do you (or anyone) need this desperately?

Regards
Ask



More information about the gpaw-users mailing list