[Pw_forum] Fwd: Re: Segmentation fault with Setting 2 --- follow-up of Re. ATOMIC_POSITIONS

Yong Jiang yjiang at asu.edu
Wed Jun 29 22:06:37 CEST 2005


(This is a resubmission of my last email) 

Dear All,

During phonon calc at G and K vector (by following example02), I used Setting 1 
of ATOMIC_POSITIONS and got reasonable vibrational frequencies. Setting 2 is 
equivalent as Setting 1. However, a similar phonon calc using Setting 2 failed. 
The code always stops with error "Segmentation fault". 

1:
 &system
   ibrav=2, nat=  1
 ATOMIC_POSITIONS
   Ni 0.00 0.00 0.00
 
2:
 &system
   ibrav=1, nat=  4,
 ATOMIC_POSITIONS {alat}
   Ni 0.00 0.00 0.00
   Ni 0.5 0.5 0.00 
   Ni 0.00 0.5 0.5
   Ni 0.5 0.00 0.5 

To be more clear, I am attaching the input script, running error message and 
some parts of output files (Ni.scf.out and Ni.phG.out) for your reference. 
Could somebody kindly take a few minutes to exam this case and help me out?

Thanks a lot! 

BTW, I use the serial code of PWscf. 

Best,
Yong


**********************
[hzhwc8 at linux1 example02]$  more test_RUN_atGnK
#!/bin/sh

# run from directory where this script is
cd `echo $0 | sed 's/\(.*\)\/.*/\1/'` # extract pathname

# check whether ECHO has the -e option
if test "`echo -e`" = "-e" ; then ECHO=echo ; else ECHO="echo -e" ; fi
                                                                               

# set the needed environment variables
. ../environment_variables

# required executables and pseudopotentials
BIN_LIST="pw.x ph.x"
PSEUDO_LIST="Ni.pbe-nd-rrkjus.UPF"

$ECHO
$ECHO "  executables directory: $BIN_DIR"
$ECHO "  pseudo directory:      $PSEUDO_DIR"
$ECHO "  temporary directory:   $TMP_DIR"
$ECHO
$ECHO "  checking that needed directories and files exist...\c"

# how to run executables
PW_COMMAND="$PARA_PREFIX $BIN_DIR/pw.x $PARA_POSTFIX"
PH_COMMAND="$PARA_PREFIX $BIN_DIR/ph.x $PARA_POSTFIX"
$ECHO
$ECHO "  running pw.x as: $PW_COMMAND"
$ECHO "  running ph.x as: $PH_COMMAND"
$ECHO

# clean TMP_DIR
$ECHO "  cleaning $TMP_DIR...\c"
rm -rf $TMP_DIR/*
$ECHO " done"

# self-consistent calculation for Ni with US-PP
cat > Ni.scf.in << EOF
 &control
    calculation='scf'
    restart_mode='from_scratch',
    tprnfor = .true.
    prefix='Ni',
    pseudo_dir = '$PSEUDO_DIR/',
    outdir='$TMP_DIR/'
 /
 &system    
    ibrav=1, celldm(1) =6.6518, nat=  4, ntyp= 1,
    nspin=2,
    starting_magnetization(1)=0.5,
    degauss=0.03,
    smearing='mp',
    occupations='smearing',
    ecutwfc =25.0
    ecutrho =400.0
 /
 &electrons
    conv_thr =  1.0d-8
    mixing_beta = 0.7
 /
ATOMIC_SPECIES
 Ni  58.6934  Ni.pbe-nd-rrkjus.UPF
ATOMIC_POSITIONS {alat}
 Ni 0.00 0.00 0.00 
 Ni 0.5 .5 0
 Ni 0 .5 0.5
 Ni 0.5 0 0.5
K_POINTS AUTOMATIC
2 2 2 0 0 0
EOF
$ECHO "  running the scf calculation for Ni...\c"
$PW_COMMAND < Ni.scf.in > Ni.scf.out
$ECHO " done"

# phonon calculation at Gamma
cat > Ni.phG.in << EOF
phonons of Ni at Gamma
 &inputph
  tr2_ph=1.0d-12,
  prefix='Ni',
  amass(1)=58.6934,
  outdir='$TMP_DIR/',
  fildyn='Ni.dynG',
 /
0.0 0.0 0.0
EOF
$ECHO "  running the phonon calculation at Gamma...\c"
$PH_COMMAND < Ni.phG.in > Ni.phG.out
$ECHO " done"

# non self-consistent calculation for phonon at K of Ni with US-PP
cat > Ni.nscf_K.in << EOF
 &control
    calculation='phonon'
    restart_mode='from_scratch',
    tprnfor = .true.
    prefix='Ni',
    pseudo_dir = '$PSEUDO_DIR/',
    outdir='$TMP_DIR/'
 /
 &system
    ibrav=  1, celldm(1) =6.6518, nat=  4, ntyp= 1,
    nspin=2,
    starting_magnetization(1)=0.5,
    degauss=0.03,
    smearing='mp',
    occupations='smearing',
    ecutwfc =25.0
    ecutrho =400.0
 /
 &electrons
    conv_thr =  1.0d-8
    mixing_beta = 0.7
 /
 &phonon
    xqq(1) = .75, xqq(2) = .75, xqq(3) = 0
 /
ATOMIC_SPECIES
 Ni  58.6934  Ni.pbe-nd-rrkjus.UPF
ATOMIC_POSITIONS {alat}
 Ni 0.00 0.00 0.00
 Ni 0.5 .5 0
 Ni 0 .5 0.5
 Ni 0.5 0 0.5
K_POINTS AUTOMATIC
2 2 2 0 0 0
EOF
$ECHO "  running the non-scf calculation for phonon at K of Ni...\c"
$PW_COMMAND < Ni.nscf_K.in > Ni.nscf_K.out
$ECHO " done"

# phonon calculation at K
cat > Ni.phK.in << EOF
phonons of Ni at K
 &inputph
  tr2_ph=1.0d-12,
  prefix='Ni',
  amass(1)=58.6934,
  fildyn='NiK.dyn',
  outdir='$TMP_DIR/'
 /
.75 .75 0
EOF
$ECHO "  running the phonon calculation at K...\c"
$PH_COMMAND < Ni.phK.in > Ni.phK.out
$ECHO " done"


********************** (RUNNING ERROR MESSAGE)

  running pw.x as:  /home/hzhwc8/PWscf/espresso-2.1.3/bin/pw.x 
  running ph.x as:  /home/hzhwc8/PWscf/espresso-2.1.3/bin/ph.x 

  cleaning /home/hzhwc8/PWscf/tmp... done
  running the scf calculation for Ni... done
  running the phonon calculation at Gamma..../test_RUN_atGnK: line 88:  7992 
Segmentation fault      $PH_COMMAND <Ni.phG.in >Ni.phG.out
 done
  running the non-scf calculation for phonon at K of Ni... done
  running the phonon calculation at K...forrtl: severe (24): end-of-file during

read, unit 99, file /home/hzhwc8/PWscf/tmp/recover
Image              PC        Routine            Line        Source             
ph.x               08585C80  Unknown               Unknown  Unknown
ph.x               085854E4  Unknown               Unknown  Unknown
ph.x               0854DD91  Unknown               Unknown  Unknown

**********************
[hzhwc8 at linux1 results]$ more Ni.phG.out
     ...
     Atomic displacements:
     There are   4 irreducible representations

     Representation     1      3 modes - To be done
     Representation     2      3 modes - To be done
     Representation     3      3 modes - To be done
     Representation     4      3 modes - To be done
     PHONON       :  1m47.01s CPU time

     Alpha used in Ewald sum =   2.8000
     Representation #  1 modes #   1  2  3

     Self-consistent Calculation
     Pert. #  1: Fermi energy shift (Ryd) =    0.0000    0.0000
     Pert. #  2: Fermi energy shift (Ryd) =    0.0000    0.0000
     Pert. #  3: Fermi energy shift (Ryd) =    0.0000    0.0000

      iter #   1 total cpu time :   142.4 secs   av.it.:   4.2
      thresh= 0.100E-01 alpha_mix =  0.700 |ddv_scf|^2 =  0.164E-05
      (ENDS HERE FOR WHAT REASON ?!)

[hzhwc8 at linux1 results]$ more Ni.scf.out
     ...

     the Fermi energy is    14.7679 ev
!    total energy              =  -343.53169412 ryd
     estimated scf accuracy    <        3.9E-10 ryd

     band energy sum           =    36.07464219 ryd
     one-electron contribution =    -9.08238802 ryd
     hartree contribution      =    62.01012182 ryd
     xc contribution           =  -120.75407837 ryd
     ewald contribution        =  -275.70655005 ryd
     correction for metals     =     0.00120050 ryd

     total magnetization       =     1.90 Bohr mag/cell
     absolute magnetization    =     2.20 Bohr mag/cell

     convergence has been achieved
  
     Forces acting on atoms (Ry/au):
     atom   1 type  1   force =     0.00000000    0.00000000    0.00000000
     atom   2 type  1   force =     0.00000000    0.00000000    0.00000000
     atom   3 type  1   force =     0.00000000    0.00000000    0.00000000
     atom   4 type  1   force =     0.00000000    0.00000000    0.00000000
     Total force =     0.000000     Total SCF correction =     0.000000
     Writing file        Ni.save for program phonon
     PWSCF        :  1m35.34s CPU time
     ...  



Quoting Yong Jiang <yjiang at asu.edu>:

> Dear All,
> 
> I am new to PWscf. The manual seems too simple to clerify everything.
> For 
> example, I am very confused with Atomic_Positions, expecially the
> difference 
> between {alat} and {crystal}.
> 
> To be specific, are the following two settings equivalent to generate
> the SAME 
> fcc unit cell, EXCEPT that the total energy by setting 2 would be four
> times of
> 
> that by setting 1, i.e. Etot(2)=4*Etot(1)?
>  
> 1.
> &system
>   ibrav=2, nat=  1
> ATOMIC_POSITIONS
>   Cu 0.00 0.00 0.00
> 
> 2.
> &system
>   ibrav=1, nat=  4,
> ATOMIC_POSITIONS {alat}
>   Cu 0.00 0.00 0.00
>   Cu 0.5 0.5 0.00 
>   Cu 0.00 0.5 0.5
>   Cu 0.5 0.00 0.5 
> 
> If we want express the same unit cell in ATOMIC_POSITIONS {crystal},
> what would
> 
> it be? 
> 
> Thanks in advance for help
> 
> Yong 
> _______________________________________________
> Pw_forum mailing list
> Pw_forum at pwscf.org
> http://www.democritos.it/mailman/listinfo/pw_forum
> 



More information about the users mailing list