Trace:

exercises:2017_uzh_cp2k-tutorial:wfc

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

Both sides previous revision Previous revision Next revision | Previous revision | ||

exercises:2017_uzh_cp2k-tutorial:wfc [2017/07/07 12:22] vrybkin |
exercises:2017_uzh_cp2k-tutorial:wfc [2017/07/13 15:44] (current) vrybkin |
||
---|---|---|---|

Line 2: | Line 2: | ||

In order to go beyond GGA and hybrid DFT, one option is to use wave function correlation methods. Recently, second-order Møller-Plesset perturbation theory (MP2) and random phase approximation (RPA) have been added to CP2K . The implementations are aimed at condensed phase calculations, and in the case of MP2 provides energies, forces and stress, as well as electron (spin) densities at O(N^5) cost, while RPA provides energies at O(N^4) or O(N^3) cost. | In order to go beyond GGA and hybrid DFT, one option is to use wave function correlation methods. Recently, second-order Møller-Plesset perturbation theory (MP2) and random phase approximation (RPA) have been added to CP2K . The implementations are aimed at condensed phase calculations, and in the case of MP2 provides energies, forces and stress, as well as electron (spin) densities at O(N^5) cost, while RPA provides energies at O(N^4) or O(N^3) cost. | ||

- | However, significant computational resources are needed for the condensed phase calculations. Therefore, we will perform the gas phase calculations in this tutorial, even though RI-GPW is not very efficient in this case. | + | However, significant computational resources are needed for the condensed phase calculations (for the overview see the corresponding lecture). Therefore, we will perform the gas phase calculations in this tutorial, even though RI-GPW is not very efficient in this case. |

**Some references:** | **Some references:** | ||

Line 19: | Line 19: | ||

===== 1. Task: Benzene dimer MP2 binding energy ===== | ===== 1. Task: Benzene dimer MP2 binding energy ===== | ||

- | 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 necessary (or else is not). 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. | + | 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. |

- | Topics: | + | 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: |

- | * RI approach (''RI_MP2_GPW'' and ''RI_AUX_BASIS_SET'') | + | <code> |

- | * Wavelet solver (''PSOLVER WAVELET'', ''CENTER_COORDINATES'') | + | &PRINT MEDIUM |

- | * gas phase HFX calculation | + | &END |

- | * memory issues (''FREE_HFX_BUFFER'') | + | </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. | ||

+ | 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 206: | Line 233: | ||

&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 | ||

Line 215: | Line 241: | ||

</code> | </code> | ||

- | 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> | ||

- | |||

- | &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> | ||

| |

exercises/2017_uzh_cp2k-tutorial/wfc.1499430132.txt.gz · Last modified: 2017/07/07 12:22 by vrybkin

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-ShareAlike 4.0 International