next up previous contents
Next: 3 The installation of Up: 2.3 Tutorialfirst steps Previous: 2.3 Tutorialfirst steps

2.3.1 diamant

Copy all files from the tutor/diamant directory to a work directory, and proceed step by step:

  1. The following files are most important for running vasp, please check each of these files using an editor.
  2. Type (VASP.3.X only !)
    > makeparam
    and copy the lines written to the screen to the param.inc file. The param.inc is ``included'' during the compilation of the param.F and fft3d...F file of VASP.3.X and contains information about the maximum size of the system. It this particular case it will be similar to
    C
    C     automatic param.inc file
    C
    C-----General parameters always needed ...
          PARAMETER(NGX = 12,NGY = 12,NGZ = 12,
         &          NGXF= 20,NGYF= 20,NGZF= 20)
          PARAMETER(NTYPD=1,NIOND=   2,NBANDS=   7,NKDIM=  10)
          PARAMETER(NRPLWV=  203,NPLINI=   7)
          PARAMETER(NRPLWL=    1,NBLK= 32,MCPU=  1)
    C-----Parameter for non-local contribution
          PARAMETER(LDIM=4,LMDIM= 8,LDIM2=(LDIM*(LDIM+1))/2,LMYDIM=10)
          PARAMETER(IRECIP=1,IRMAX=   1,IRDMAX= 2561)
    C-----extra parameters:
          PARAMETER(IALLD=0,IRMMD=4,NEMPTY=4,ISPIND=1,IGRAD=1)
    most parameters in the param.inc file are only necessary to allocate sufficient work space, but some do influence the calculation. These parameters are NGX Y Z NG(X,Y,Z)F and to a smaller extend NBANDS. NGX,Y,Z and NG(X,Y,Z)F control the size of the FFT meshes (second mesh is for the representation of the augmentation charges) used in the calculation. They must be sufficiently large to avoid the so called wrap around errors (see section 10.4). makeparam usually allows by default a small wrap around (3/4 of the required value are used for the FFT-meshes), together with the default energy cutoff the errors are usually negligible (less than 1 meV per atom).
  3. Type (VASP.3.X only !)
    > getvasp
    The required parts (two subroutines) of vasp will be recompiled and a working copy of the vasp program will be copied to your local directory.
  4. Run vasp typing
    > vasp
    You will get an output similar to
     POSCAR found :  1 types and    2 ions
     Automatic xc-table for CA
     file io ok, starting setup
     WARNING: wrap around errors must be expected
     entering main loop
           N       E                dE            d eps      ncg     rms          rms(c)
    CG :   1    -0.27655216E+03   -0.2765E+03   -0.1962E+03   146   0.558E+02
    CG :   2    -0.30480031E+03   -0.2824E+02   -0.9664E+01   163   0.998E+01
    CG :   3    -0.31085987E+03   -0.6059E+01   -0.3783E+00   166   0.160E+01    0.790E-01
    CG :   4    -0.31052425E+03    0.3356E+00   -0.1041E+00   156   0.103E+01    0.123E-01
    CG :   5    -0.31052313E+03    0.1126E-02   -0.6119E-03   177   0.713E-01    0.185E-02
    CG :   6    -0.31052312E+03    0.4535E-05   -0.8772E-05   119   0.109E-01
       1 F= -.20028156E+02 E0= -.20028156E+02  d E =0.000000E+00
     writing wavefunctions
    Vasp is using a selfconsistency cycle with a Pulay mixer and an iterative matrix diagonalization scheme to calculate the KS-groundstate. Each electronic step consists of one step in the iterative matrix diagonalization and one mixing step. Progress is written to stout (and to the file OSZICAR).

    N counts the electronic iterations, E the current free energy, dE the change in the free energy from the last to the current step and d eps the change in the band-structure energy. ncg the number of evaluations of the Hamiltonian acting onto a wavefunction, rms the norm of the residuum ( tex2html_wrap_inline4377 ) of the trial wavefunctions (i.e. their approximate error) and rms(c) the difference between input and output charge density. In the first few steps the density and the local potentials are not updated to converge the wavefunctions to a reasonable accuracy (rms(c) is therefore not shown). Then the update of the charge density starts, in this case only three updates are required to obtain a sufficiently accurate groundstate.

    The final line gives energy information after obtaining convergence. The most important value is the total free energy F (at this point the energy of the reference atom has been subtracted).

    Much more information (like forces and stress tensor) can be found in the OUTCAR file. Please read this file to get an impression what information can be found.

    Another important file is the WAVECAR file which contains the final wavefunction. VASP usually tries to read this file on startup to speed up the calculations. At the end of the calculations the file is written (or if it exists overwritten).

  5. To calculate the equilibrium lattice constant try to type run (read this small batch file).

    There will be an error, correct the param.inc file and type getvasp again. The error is due to the fact that one array was not sufficiently large. (The arrays were set up for a specific volume, changing the volume will change the requirements for some work arrays, it is always safest to run the makeparam utility with the largest volume in mind, and to double then the value IRDMAX in the param.inc file).

  6. Determine the equilibrium volume (for instance using a quadratic fit of the energy). The equilibrium lattice constant should be 3.526.
  7. Now set the equilibrium lattice constant in the POSCAR file and move the ion located at 0.25 0.25 0.25 to 0.24 0.24 0.24, and relax back to the equilibrium position using vasp. You have to add the lines
     NSW    = 10  !   allow 10 steps
     ISIF   = 2   !   relax ions only
     IBRION = 2   !   use CG algorithm
    to the INCAR file.

    Once again you will get an error; you have to increase the number of k-points in the param.inc file (NKDIM) as the symmetry of the system has been broken. Do that and proceed with the calculation. (At this point you might find it helpful to read section 7.19).

    To find the minimum a line minimizations of the energy into the direction of the forces is done (see 7.19), for the line minimization a "small" trial step into the direction of the force is done and the energy change is evaluated, this allows to calculate the position of the minimum. For Carbon, the trial step is much to large you can reduce it by setting POTIM in the INCAR file:

     POTIM  = 0.1 !   reduce trial step to 10 %
    Do that and start once again from a more exited structure (0.20,0.20,0.20).

    After a relaxation job (or a molecular dynamics run) the final positions are written to the file CONTCAR. This file has the same format as the POSCAR file. If one wants to continue calculations with the relaxed positions simply copy CONTCAR to POSCAR.

  8. Now set the lattice constant in POSCAR to 3.40, change ISIF to
     ISIF   = 3   !   relax ions + volume
    and start once again. Positions and cell shape will be relaxed.

    Do not forget to check the OUTCAR file.

  9. The final lattice constant will be quite accurate (3.510, tex2html_wrap_inline4379 error). The small error is due to Pulay stress (see section 9.6). The stress is only correct if the calculations are fully converged with respect to the basis set. There are several possibilities to solve this problem:
  10. Increase the plane wave cutoff by tex2html_wrap_inline4381 with respect to the standard value in the INCAR file (ENMAX=600). This will give almost zero errors (but check by going to even larger cutoffs). Try this for Carbon, and increase the accuracy of the calculation by setting
     EDIFF  = 1E-7 ! very high accuracy required 10^-7 eV
    in the INCAR file. Start from the CONTCAR file of the last calculation (i.e. copy CONTCAR to POSCAR). You will get some warnings, they point out that your FFT mesh is not sufficient for this calculation. This is true in principle, but in practice the results will be only marginally affected by increasing NGX, NGY, NGZ.
  11. The Pulay error is independent of the structure, so it can be evaluated once and for ever using first a large basisset and than a small one. Start at the equilibrium structure, with a high cutoff (ENCUT=500). The stress tensor should be zero.

    Then use the default cutoff. The stress is now -43 kB. This gives you an estimation of the possible errors. (You might correct the relaxation by setting

     PSTRESS = -43  ! Pulay stress = -43 kB
    in the INCAR file. But we do not recommend this procedure, it is definitely preferable to increase ENCUT.)


next up previous contents
Next: 3 The installation of Up: 2.3 Tutorialfirst steps Previous: 2.3 Tutorialfirst steps

MASTER USER VASP
Mon Mar 29 10:38:29 MEST 1999