[Pw_forum] Electron-phonon interaction ...

Malgorzata Wierzbowska wierzbom at ts.infn.it
Sat Dec 16 17:52:50 CET 2006


  First: I am not a "resected Sir" but a "simple female user" ;-)

  Second: if you followed my earlier advice you would find
  what to do....
  I will tell you how:
  From words:
      !  this failure of the algorithm may indicate that the displaced grid
      !  (with k1,k2,k3.ne.0) does not have the full symmetry of the lattice
  one can guess that k1, k2, k3 are input parameters.
  Then one could look to files which read input,
  (by making: ls ./*/*inp*.f90).
  The answer is:
-----------------------------------
  ./CPV/input.f90          ./flib/linpack.f90 
./PH/bcast_ph_input.f90
./D3/bcast_d3_input.f90  ./Modules/input_parameters.f90  ./PW/input.f90
./flib/inpfile.f90       ./PH/bcast_ph_input1.f90 
./VIB/read_input_vib.f90
------------------------------
  Now we need to find these files which contain "k1" or "k2" or "k3"
  (by making:   grep -i 'k2' ./*/*inp*.f90)
  The answer is:
-------------------------
   ...............
./PW/input.f90:    k2_  = k2
   ...............
------------------------------------

We look into PW/input.f90 and we see:
------------
   IF ( k_points == 'automatic' ) THEN
     !
     ! ... automatic generation of k-points
     !
     gamma_only = .FALSE.
     lxkcry     = .FALSE.
     nks        = 0
     !
     ! ... nk1,nk2,nk3 and k1,k2,k3 are initialized even when not used
     !
     nk1_ = nk1
     nk2_ = nk2
     nk3_ = nk3
     k1_  = k1
     k2_  = k2
     k3_  = k3
-------------------------
  Which means that for automatic k-points the k-point shift (k1,k2,k3) is
  not set by default to zero like it is done for other choices of the
  k-point coordinates.

  You should therefore put your k-points as follows:
    32 32 4 0 0 0
    and
    8 8 1 0 0 0

   I have checked that above works for hegagonal magnesium.


   Third: I can guess from your "cut_and_changed" input why do you want
          to do el-ph with spin.
   If you want to implement it you need to work a bit because it will
   not be so fast and easy work  as you may think now.

   You may start from hexagonal Mg, which is nonmagnetic.
   Learn equations which are behind phonons and el-ph, for instance
   from

Baroni S, de Gironcoli S, Dal Corso A, et al.
Phonons and related crystal properties from density-functional 
perturbation theory
REVIEWS OF MODERN PHYSICS 73 (2): 515-562 APR 2001

    There is another publication closer to the implementation of elph
  with USPP:

Dal Corso A
Density-functional perturbation theory with ultrasoft pseudopotentials
PHYSICAL REVIEW B 64 (23): Art. No. 235118 DEC 15 2001

   After you think you understand above, you should write these equations
   with spin. At this point you should understand some "factors of 2" which
   might be in front of el-ph coefficients or in front of DOS in case
   of calculations without spin.

   Then go to the code and find matrixes and vectors you need.
   Then check how the simple scf is implemented with spin
   (I mean how spin is passed through the code) and
   combine above knowledge.

   Gosia






On Sat, 16 Dec 2006, Amit Kumar wrote:

> Respected Sir,
>
> I think the error is not so simple.
> Because I did all what you think a student is supposed to
> do before posting a problem.
>
> Here is my input ------>
>
> cat > hexagonal_2D_sample.scf.fit.in << EOF
> &control
>   calculation='scf'
>   restart_mode='from_scratch',
>   prefix='hexa',
>   pseudo_dir = '$PSEUDO_DIR/',
>   outdir='$TMP_DIR/'
>   tstress = .true.
>   tprnfor = .true.
> /
> &system
>   ibrav = 4,
>   celldm(1) = 4.16,
>   celldm(3) = 16.0,
>   nat = 2,
>   ntyp = 1,
>   ecutwfc =40.0,
>   ecutrho = 240.0,
>   occupations='smearing',
>   smearing='methfessel-paxton',
>   degauss=0.01,
>   la2F = .true.,
> /
> &electrons
>   conv_thr =  1.0d-8
>   mixing_beta = 0.7
>
> ATOMIC_POSITIONS (angstrom)
> A       0.000000000   0.001189495   0.000000000
> A       0.000000000   1.418810505   0.000000000
>
> K_POINTS {automatic}
> 32 32 4
>
> ****************************************************************************
> Same input file for SCF calculation only with out  la2F flag and
> with
>
> K_POINTS {automatic}
> 8 8 1
> *****************************************************************************
> cat > hexagonal_2D_sample.elph.in << EOF
> Electron-phonon coefficients for  2D hexagoanl sample
> &inputph
> tr2_ph=1.0d-10,
> prefix='hexa',
> fildvscf='hexadv',
> amass(1)=58.9332,
> outdir='$TMP_DIR/',
> fildyn='hexa.dyn',
> elph=.true.,
> trans=.true.,
> ldisp=.true.
> nq1=4, nq2=4, nq3=1
> /
> EOF
> $ECHO "  running the el-ph calculation...\c"
>
> *******************************************************************************************************
>
> I have checked for several combinations of  K_POINTS and nq1, nq2 and nq3
> also.
> But I' still getting the same error.
>
> Looking forward to your kind help.
>
>
> Regards,
> Amit
>
>
> As for the answer to the question below and similar ones
> (e.g. when the error is followed by a message from the code)
> I can advice the first debugging/input_check step:
>
> -- goto the code and find sobroutine which gives the error
>    or grep the error message in the source by making for instance
>    grep -i "cannot remap grid on k-point list" ./*/*.f90 (or PH/*.f
> 90)
> -- if you find that place, you may see "a hint"
>
>  -- You think what are "k1,k2,k3" in the code. You find that you sh
> ould
>     specify these numbers as zero in the input (otherwise there
>     are problems with the symmetry... because somebody -- read Gosi
> a
>     in this case -- was lazy to solve it).
>  -- You change your input, and if it still doesn't work.... you sen
> d us
>     your input..
>



More information about the users mailing list