Skip to content

Lattice constant and bulk modulus

In order to calculate lattice constant and bulk modulus, we have to change lattice size and evaluate potential energy of the system. The lattice size that minimizes the potential energy is the lattice constant, and curvature around the lattice constant corresponds to the bulk modulus.

  1. Prepare a simulation cell of the system, which is usually the primitive unit cell or the smallest conventional unit cell.

  2. Make pmdini file (by converting the original file if needed.)

  3. Set num_iteration value in in.pmd file to zero, ecause only the 1st evaluation of the potential energy and forces are required. If you want to relax internal atomic positions, set the num_iteration and flag_damping correctly.

  4. Perform a test run of pmd as,

    /path/to/pmd/pmd
    

    and confirm that pmd is perfomed correctly without any error.

  5. Run the script as,

    python /path/to/nap/nappy/energy_vs_size.py -n 20 3.1  3.3
    

    where 3.1 and 3.3 are the min and max value of lattice size, and -n 20 specified the number of sampling points between these values. Then you get the following output.

    3.1000   804.3570    -455.5304887
    3.1100   812.1662    -457.0570473
    3.1200   820.0259    -458.4111792
    3.1300   827.9360    -459.6000610
    3.1400   835.8969    -460.6305856
    3.1500   843.9086    -461.5093734
    3.1600   851.9714    -462.2420295
    3.1700   860.0854    -462.8289708
    3.1800   868.2507    -463.2688466
    3.1900   876.4675    -463.5607352
    3.2000   884.7360    -463.7041313
    3.2100   893.0563    -463.6989250
    3.2200   901.4287    -463.5453811
    3.2300   909.8532    -463.2441193
    3.2400   918.3300    -462.7960993
    3.2500   926.8594    -462.2027522
    3.2600   935.4414    -461.4659414
    3.2700   944.0761    -460.5877459
    3.2800   952.7639    -459.5704416
    3.2900   961.5048    -458.4164932
    3.3000   970.2990    -457.1285461
    plsq= [   1.8861122     1.58686615  888.41535225 -463.71506645]
    =============================== RESULTS ================================
    Lattice constant =     3.2044 Ang.
    Cohesive energy  =     -8.587 eV
    Bulk modulus     =     302.16 GPa
    ================================ OUTPUT ================================
    * out.Ecoh-vs-size
    * log.Ecoh-vs-size.eps
    

    Then you can make a graph using some plotting program like gnuplot with the out.energy_vs_size file.

    image