User Tools

Site Tools


exercises:2017_uzh_cp2k-tutorial:wfc

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
exercises:2017_uzh_cp2k-tutorial:wfc [2017/07/07 14:26]
vrybkin [Required files]
exercises:2017_uzh_cp2k-tutorial:wfc [2017/07/07 15:04]
vrybkin
Line 21: Line 21:
 Employ the provided input file to compute the benzene dimer binding energy. The provided dimer geometry is optimized already. To obtain the energy of the monomer, geometry optimization is in principle necessary, although the geometry of a benzene monomer must be close to the one in the dimer. This can be done by removing one of the benzene molecules editing the coordinates in the input. Perform a few optimization steps to see how much the energy changes and to calculate electron density (saved as .cube files) at the MP2 level. If energy does not change much, this means that the monomer structure is already close to the optimal. Compare the times needed for one geometry optimization step (energy+forces) for a monomer and energy for a dimer, as well as the relative timing for energy and forces evaluation for a monomer. ​ Employ the provided input file to compute the benzene dimer binding energy. The provided dimer geometry is optimized already. To obtain the energy of the monomer, geometry optimization is in principle necessary, although the geometry of a benzene monomer must be close to the one in the dimer. This can be done by removing one of the benzene molecules editing the coordinates in the input. Perform a few optimization steps to see how much the energy changes and to calculate electron density (saved as .cube files) at the MP2 level. If energy does not change much, this means that the monomer structure is already close to the optimal. Compare the times needed for one geometry optimization step (energy+forces) for a monomer and energy for a dimer, as well as the relative timing for energy and forces evaluation for a monomer. ​
  
 +During the optimization of benzene, one will calculate gradient which, in turn, requires density matrices. Hence, one can calculate electronic densities. Add the following to the ''&​GLOBAL''​ section:
 +<​code>​
 +&​PRINT ​       MEDIUM
 +&END
 +</​code>​
 +and the following lines to the ''&​DFT''​ section
 +<​code>​
 +&PRINT
 +  &​E_DENSITY_CUBE MEDIUM
 +  &END
 +&END
 +</​code>​
 +
 +Importantly,​ during the force calculations one will have to solve the coupled-perturbed equations invoking exact exchange calculations. If there is enough memory we can reuse the integrals from the HF calculation by setting the following keyword in the ''&​RI_MP2''​ section:
 +<​code>​
 +FREE_HFX_BUFFER .FALSE.
 +</​code>​
 +
 +Perform two optimizations setting ''​FREE_HFX_BUFFER''​ to ''​.TRUE.''​ and ''​.FALSE.''​ Compare the overall timings and especially the times for performing Hartree-Fock exchange calculations:​
 +<​code>​
 +integrate_four_center ​              71 12.3    2.261    4.012  108.805 ​ 109.179
 +</​code>​
 +The last number in the line is the real time of execution. The memory distribution between the RI-MP2 integrals and HFX integrals are tuned by the ''​MEMORY''​ keyword in the ''&​WF_CORRELATION''​ section and the ''&​MEMORY''​ section in the ''&​HF''​ section:
 +<​code>​
 +&MEMORY
 +  MAX_MEMORY ​ 1800
 +&END
 +
 +</​code>​
  
 +At the optimized (or the most optimized) geometry of benzene monomer perform a Hartree-Fock calculation to compare electron densities. Visualize them with VMD. Electron density difference between MP2 and HF looks as follows (with red and blue standing for positive and negative values):
 +{{ :​exercises:​2017_uzh_cp2k-tutorial:​benzene_diff.png?​400 |}}
 + ​Density differences can be computed with ''​cubecruncher''​ available in the executable directory.
  
 ===== 2. Task: Benzene monomer RPA energy: frequency integration ===== ===== 2. Task: Benzene monomer RPA energy: frequency integration =====
Line 202: Line 234:
 &MOTION &MOTION
  &​GEO_OPT  &​GEO_OPT
-   ​OPTIMIZER BFGS ! Good choice for '​small'​ systems ​(use LBFGS for large systems) +   ​OPTIMIZER BFGS ! Good choice for '​small'​ systems ​like benzene
-   ​MAX_ITER ​ 100+
    ​MAX_DR ​   [bohr] 0.003 ! adjust target as needed    ​MAX_DR ​   [bohr] 0.003 ! adjust target as needed
    &​BFGS    &​BFGS
exercises/2017_uzh_cp2k-tutorial/wfc.txt · Last modified: 2017/07/13 15:44 by vrybkin