[Pw_forum] NaN error in plotbandband.x - error in k-path?

Giovanni Cantele giovanni.cantele at spin.cnr.it
Tue Mar 1 16:49:22 CET 2016


The error comes from the calculation=‘bands’ run. Indeed, you just specified the extrema of high symmetry lines (G, R, X, M) in the Brillouin zone,
but you used as units “crystal” instead of “crystal_b”. The latter keyword tells pw.x to build a path of (in your case) 20 points along each line, whereas
the former just instructs pw.x to calculate the eigenvalues at the specified k-points. If you look at the header of bands.dat you find nks=4, that is, the bands
have been calculated only at G, R, X, M and no additional k-points have been considered.

This being said. when plotband.x reads bands.dat, at some point there is the following code:

!   A big jump in dxmod is a sign that the point k(:,n) and k(:,n-1)
!   are quite distant and belong to two different lines. We put them on
!   the same point in the graph 
!
        kx(n)=kx(n-1)

So, because no additional points were added between each pair, all the computed k-points where put on the same point of the plot, that is, kx(n)=0, for n=1,2,3,4.

At the stage were plotband.x writes the ps file:

DO i=1,nbnd
        IF (is_in_range(i)) WRITE (1,'(2(f8.3,1x)," dot")' ) &
             kx(n)*xdim/kx(nks), (e(i,n)-emin)*ydim/(emax-emin)
     ENDDO

so, you see that the division by kx(nks)=0 is undefined, which produces the NaNs.

Not related to the error, consider that ecutwfc=24 might be too low and insufficient to get converged results, for the kind of pseudo potentials you are using.

Giovanni


> On 01 Mar 2016, at 16:28, Christoph Wolf(신소재공학과) <chwolf at postech.ac.kr> wrote:
> 
> Dear All!
>  
> I am trying to calculate the band structure of a (tiny) simple cubic unit cell containing 12 atoms of 5 species. I imported to structure from a CIF file via VESTA.
>  
> 1)      First I am running an &scf and it seems to converge.
> 2)      Then I am running &bands and it finishes fine without errors
> 3)      Then I am running bands.x and generate an output file which seems fine, no NaN there
> 4)      When I use plotband.x (interactive mode) the created ps file contains NaN and I don’t understand where they come from
>  
> The output of the bands looks something like this:
>  
> &plot nbnd=  24, nks=     4 /
>             0.000000  0.000000  0.000000
> -18.411 -12.728 -12.287 -11.961 -10.967  -7.359  -7.181  -5.332  -4.940  -3.029
>   -3.013  -2.097  -2.045  -1.873  -0.112  -0.047   0.005   0.136   0.448   0.470
>    5.704   7.022   7.067   7.347
>  
> But then the ps file contains lots of:
>  
>      NaN    0.000      NaN  284.530  riga
>      NaN   11.303  dot
>      NaN   51.728  dot
>      NaN   54.865  dot
>  
>  
> My input files are as follows (maybe someone can spot the error). Version is 5.0.2 on ubuntu
>  
> Any help is greatly appreciated!
>  
> Yours,
> Chris 
>  
>  
> &control
>     calculation='scf'
>     restart_mode='from_scratch',
>     pseudo_dir = '/usr/share/espresso/pseudo/',
>     outdir='/usr/share/doc/quantum-espresso/examples/MAPbBr3/tmp/'
>     prefix='mapbbr3'
> /
> &system
>     ibrav=1, a=5.9200000763, nat=12, ntyp=5, ecutwfc = 24.0, nbnd = 24
> /
> &electrons
> /
> ATOMIC_SPECIES
>     C 12.01 C.pbe-hgh.UPF 
>     N 14.01 N.pbe-hgh.UPF
>     H 1 H.pbe-hgh.UPF
>     Pb 207.19 Pb.pbe-hgh.UPF
>     Br 79.9 Br.pbe-hgh.UPF
> ATOMIC_POSITIONS
>     C    0.896270000   0.999980000   0.988510000
>     N    0.142130000   0.999830000   0.032690000
>     H    0.866960000   0.999760000   0.805200000
>     H    0.822470000   0.152470000   0.064660000
>     H    0.822200000   0.847840000   0.065070000
>     H    0.221280000   0.142420000   0.965660000
>     H    0.221080000   0.856980000   0.965950000
>     H    0.180460000   0.999970000   0.205370000
>     Pb   0.475340000   0.500000000   0.477920000
>     Br   0.428780000   0.499880000   0.972690000
>     Br   0.433480000   0.000020000   0.512850000
>     Br   0.967550000   0.500170000   0.439210000
> K_POINTS (automatic)
> 10 10 10 0 0 0
>   
>  
> &control
>     calculation='bands'
>     pseudo_dir = '/usr/share/espresso/pseudo/',
>     outdir='/usr/share/doc/quantum-espresso/examples/MAPbBr3/tmp/'
>     prefix='mapbbr3'
> /
> &system
>     ibrav=1, a=5.9200000763, nat=12, ntyp=5, ecutwfc = 24.0, nbnd = 24
> /
> &electrons
> /
> ATOMIC_SPECIES
>     C 12.01 C.pbe-hgh.UPF 
>     N 14.01 N.pbe-hgh.UPF
>     H 1 H.pbe-hgh.UPF
>     Pb 207.19 Pb.pbe-hgh.UPF
>     Br 79.9 Br.pbe-hgh.UPF
> ATOMIC_POSITIONS
>     C    0.896270000   0.999980000   0.988510000
>     N    0.142130000   0.999830000   0.032690000
>     H    0.866960000   0.999760000   0.805200000
>     H    0.822470000   0.152470000   0.064660000
>     H    0.822200000   0.847840000   0.065070000
>     H    0.221280000   0.142420000   0.965660000
>     H    0.221080000   0.856980000   0.965950000
>     H    0.180460000   0.999970000   0.205370000
>     Pb   0.475340000   0.500000000   0.477920000
>     Br   0.428780000   0.499880000   0.972690000
>     Br   0.433480000   0.000020000   0.512850000
>     Br   0.967550000   0.500170000   0.439210000
> K_POINTS |(crystal)
> 4
> 0.0 0.0 0.0 20 !G
> 0.5 0.5 0.5 20 !R
> 0.0 0.5 0.0 20 !X
> 0.5 0.5 0.0 20 !M
>  
>  
> &bands
> outdir='/usr/share/doc/quantum-espresso/examples/MAPbBr3/tmp/'
> prefix='mapbbr3'
> filband='bands.dat'
> /
>  
>  
>  
>  
>    
>  
> _______________________________________________
> Pw_forum mailing list
> Pw_forum at pwscf.org <mailto:Pw_forum at pwscf.org>
> http://pwscf.org/mailman/listinfo/pw_forum <http://pwscf.org/mailman/listinfo/pw_forum>
-- 

Giovanni Cantele, PhD
CNR-SPIN
c/o Dipartimento di Fisica
Universita' di Napoli "Federico II"
Complesso Universitario M. S. Angelo - Ed. 6
Via Cintia, I-80126, Napoli, Italy
e-mail: giovanni.cantele at spin.cnr.it
Phone: +39 081 676910
Skype contact: giocan74

ResearcherID: http://www.researcherid.com/rid/A-1951-2009
Web page: http://people.na.infn.it/~cantele

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.quantum-espresso.org/pipermail/users/attachments/20160301/0f707c18/attachment.html>


More information about the users mailing list