< prev. lesson Fourth Group >
Troubleshooting >

Content of this lesson

Material

Basics of Minima Hopping: Minima Hopping on a Mg7 cluster

Introduction:

The purpose of this lesson is to get familiar with basic variables needed to run a Minima Hopping calculation on a cluster. At the end of the lesson, one will be able to prepare the inputs required for an efficient production run and understand the important part of the output. This lesson may take 2 hours. If you have already finished the tutorial and facing some problems during the Minima Hopping run see troubleshooting section.

In this tutorial we assume that the user is already familiar with basic BigDFT inputs. We will use Mg7 cluster as an example system in this tutorial. The detailed discussion on the method can be found in the tutorial presentation.

File Structure Overview

Input files

Input/Output files

These files are updated during the run.

Output files

Other than screen output and BigDFT output files, there are two output files of Minima Hopping code.

Preparing The Inputs For A Production Run

We all know that calculations using Density Functional Theory is quite expensive method. When we couple Minima Hopping with BigDFT to search the global minimum on a DFT energy landscape, the calculation becomes even more expensive even for modern super computers. For this reason, a careful selection of input parameters are very important for the performance of the code. A detailed demonstration of the tuning process has been given in the tutorial presentation.

Exercise 1: Tuning input.dft file: Prepare an input.dft file which will give expected accuracy of 0.5E-05 . Start with input.dft, posinp.xyz and psppar.Mg files. Run BigDFT for different values of hgrid, crmult and frmult stored in first two lines of input.dft file and note the expected accuracy in energy in the output file.

sandip@phys-carbon-04:~/tutorials/Mg7-minhop/input_dft$ ls
input.dft  posinp.xyz  psppar.Mg
sandip@phys-carbon-04:~/tutorials/Mg7-minhop/input_dft$ mpirun -np 7 ~/BigDFT > OUT &
sandip@phys-carbon-04:~/tutorials/Mg7-minhop/input_dft$ grep expected OUT 
 expected accuracy in energy  4.96E-06
 expected accuracy in energy per orbital  7.09E-07
Now in the same way find a low accuracy parameter set for input.dft which will produce expected accuracy in energy of 0.5E-03 . We will rename this input.dft file to mdinput.dft to use in our Minima Hopping run.

Exercise 2: Verifying the expected accuracy: After you have found a set of parameters for the input.dft file which gives an expected accuracy of 0.5E-05 , let's check the accuracy of the energy due to rotation. Use the rotate_posinp executable in the src/tools folder of the build directory to rotate the input structure arbitrarily and note how they affect the FINAL energy of the system.

sandip@phys-carbon-04:~/tutorials/Mg7-minhop/input_dft$ grep FINAL OUT 
 FINAL iter,total energy,gnrm    18  -5.99066949724724473E+00  9.62E-06
sandip@phys-carbon-04:~/tutorials/Mg7-minhop/input_dft$ cp ~/tutorial/UTIL/rotate .
sandip@phys-carbon-04:~/tutorials/Mg7-minhop/input_dft$ ./rotate 
reading atomic positions from file posinp.xyz
 rotations in degrees (0<= Phi <=360):
 
 around z axis / in xy-plane:
30
 around y axis / in xz-plane:
20
 around x axis / in yz-plane:
10
 writing atomic positions to file rotate_posinp.xyz
sandip@phys-carbon-04:~/tutorials/Mg7-minhop/input_dft$ mpirun -np 7 ~/BigDFT > OUT1 &
sandip@phys-carbon-04:~/tutorials/Mg7-minhop/input_dft$ grep FINAL OUT1 
 FINAL iter,total energy,gnrm    16  -5.990668764306198470E+00  7.14E-06

Exercise 3: Prepare input.geopt and mdinput.geopt files: input.geopt and mdinput.geopt has following file format:

SDCG     Geometry Optimization method
200      ncount_cluster: max steps during geometry relaxation
5.d0  1.0E-4   frac_fluct:     geometry optimization stops if force norm less than frac_fluct of noise
0.d0     randdis:        random amplitude for atoms
4.0d0     betax: steepest descent step size.
The important task is to determine the step size for steepest descent stores in the last line of the file. To do this one should Use VSSD as geometry optimization method and a low initial step-size. One should not use a well relaxed structure for this purpose, so if we already have a well relaxed structure we can use a small value for randdis instead of zero. Don't forget to set the value of randdis back to zero before using the file for Minima Hopping run. use this input.geopt file along with the low accuracy set of input.dft file to start a BigDFT run. At the end of the run a stepsize will be suggested at the end of geopt.mon file.
sandip@phys-carbon-04:~tutorials/Mg7-minhop/geopt$ tail geopt.mon 
   56    55  GEOPT_VSSD  -5.99017990634830E+00  -5.34E-08  1.371E-04  2.00E-04  4.26E-05  8.52E-06  beta= 1.17E+1  last beta= 1.17E+1
   57    56  GEOPT_VSSD  -5.99018030014665E+00  -3.94E-07  4.776E-05  7.88E-05  4.32E-05  8.65E-06  beta= 9.14E+0  last beta= 9.14E+0
   58    57  GEOPT_VSSD  -5.99018035217616E+00  -5.20E-08  3.045E-05  5.79E-05  4.38E-05  8.75E-06  beta= 1.37E+1  last beta= 1.55E+1
   59    58  GEOPT_VSSD  -5.99018039144910E+00  -3.93E-08  1.978E-05  4.30E-05  4.42E-05  8.84E-06  beta= 2.06E+1  last beta= 2.11E+1
   60    59  GEOPT_VSSD  -5.99018042561645E+00  -3.42E-08  1.656E-05  3.54E-05  4.45E-05  8.90E-06  beta= 3.08E+1  last beta= 5.42E+1
 new positions rejected, reduced beta   4.00000000000000     
   61    60  GEOPT_VSSD  -5.99018038142169E+00   4.42E-08  1.287E-05  2.75E-05  4.48E-05  8.96E-06  beta= 4.00E+0  last beta= 6.87E+1
   62    61  GEOPT_VSSD  -5.99018042934774E+00  -4.79E-08  1.703E-05  3.45E-05  4.53E-05  9.06E-06  beta= 4.00E+0  last beta= 5.55E+1
variable stepsize SD FINISHED,iter, force norm,energy   61 0.34E-04 -0.5990180429E+01
suggested value for stepsize: 0.81E+01

After we find the stepsize we will use this stepsize in both input.geopt and mdinput.geopt files. Only difference between these two files is for input.geopt we will use BFGS and for mdinput.geopt ,we will use SDCG as geometry optimization method.

Exercise 4: Minima-Hopping run for Mg7: If you have followed last three exercises then you already have prepared input.dft , input.geopt , psppar.Mg ,mdinput.dft and mdinput.geopt. As discussed in the tutorial presentation ,we can choose

5.0E-03 5.0E-03 1.0 10 ediff,ekinetic dt nsoften
as parameters in ioput file. The other two files, rand.inp and earr.dat should be straight forward to understand if you follow the tutorial presentation. The atomic coordinates of the starting configuration can be used from poscur.xyz file. With these files start the minima hopping run for Mg7 cluster. Running Minima Hopping is done using the global executable in a standard Unix way, the output being by default the standard output, it must redirected to a file.

sandip@phys-carbon-04:~/tutorials/Mg7$ ls
earr.dat global  input.dft  input.geopt  ioput  mdinput.dft  mdinput.geopt  poscur.xyz  psppar.Mg  rand.inp  
sandip@phys-carbon-04:~/tutorials/Mg7$ mpirun -np 7 ./global>OUTmh &
sandip@phys-carbon-04:~/tutorials/Mg7$ tail -100f OUTmh

...