[QE-developers] Fix upf2plotcore.sh QE6.4.1

Paolo Giannozzi p.giannozzi at gmail.com
Mon Nov 25 17:46:09 CET 2019


Thank you. I also had noticed that upf2plotcore wasn't working any longer,
but I lacked the courage to try to find out why. There is by the way
another code that does the same (upftools/extract_core.x) but it seems to
me that  it does strange things (that is: what it extracts is not what one
expects)

Paolo


On Mon, Nov 25, 2019 at 1:33 PM Aldo Ugolotti <a.ugolotti at campus.unimib.it>
wrote:

> Dear QE developers,
>
> I recently had to generate a core hole pseudopotential, from which I
> needed to extract the core state wavefunction. As usual, after running
> the atomic code, I tried to run upf2plotcore.sh - both as included in
> the 6.4.1 version of QE - but the output of the latter was empty with
> the exception of a single line "# number of core states 1 =  1 0;".
> After some checks, I noticed that the awk commands within the script
> itself were looking for a slightly different pattern than that included
> in the UPF file, and the string manipulation to extract some parameters
> was not working as intended.
>
> Hoping it could be of help, I am attaching a copy of the script I edited
> to fix it; the changes are summarized here as well:
>
> 1) in reading the size of the radial grid (mesh_size, nris) the regex
> patterns in gsub functions have been substituted as:
>
>      gsub ( /.*mesh_size="/, "", nris )
>
>      gsub ( /[^0-9]*".*/, "", nris )
>
> 2) in reading the radial grid, the awk patterns to be searched have been
> changed as "/PP_R /" -> "<PP_R>" and "<PP_R"  -> "<PP_R>"
>
> As for 2), I have not tested it with previous versions, but I noticed
> that v6.0 was reporting the "old" format of the tags; about point 1) I
> cannot guess why it wouldn't work for me.
>
> Bests,
>
> --
> Aldo Ugolotti
>
> PhD student
> Materials Science Dept. U5,
> Università degli Studi di Milano-Bicocca
> via Cozzi 55,
> 20125 Milano (MI)
> Italy
> e-mail: a.ugolotti at campus.unimib.it
>
>
> _______________________________________________
> developers mailing list
> developers at lists.quantum-espresso.org
> https://lists.quantum-espresso.org/mailman/listinfo/developers
>


-- 
Paolo Giannozzi, Dip. Scienze Matematiche Informatiche e Fisiche,
Univ. Udine, via delle Scienze 208, 33100 Udine, Italy
Phone +39-0432-558216, fax +39-0432-558222
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.quantum-espresso.org/pipermail/developers/attachments/20191125/c06c244a/attachment.html>


More information about the developers mailing list