Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
| properties_and_expectation_values [2025/07/18 13:32] – [Derivatives with respect to fields (dipole, quadrupole, second and third moments)] doll | properties_and_expectation_values [2025/09/10 06:37] (current) – add example for pop , spin doll | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | |||
| - | |||
| ====== Properties and expectation values ====== | ====== Properties and expectation values ====== | ||
| Line 271: | Line 269: | ||
| ci; | ci; | ||
| pop; | pop; | ||
| + | </ | ||
| + | |||
| + | In the following example, the population for charge and spin is computed: | ||
| + | |||
| + | <code - examples/ | ||
| + | geometry={li} | ||
| + | basis=vdz | ||
| + | hf | ||
| + | pop; | ||
| + | pop; | ||
| </ | </ | ||
| Line 412: | Line 420: | ||
| Second derivatives include a minus sign, e.g. $$-\frac{\partial^2 E}{\partial d_i \partial d_j}$$ where $d_i$ are the components of the dipole field. | Second derivatives include a minus sign, e.g. $$-\frac{\partial^2 E}{\partial d_i \partial d_j}$$ where $d_i$ are the components of the dipole field. | ||
| - | By default a two-point formula is used for first derivatives (keyword '' | ||
| - | The quadrupole tensor is traceless which is exploited by default. It may be switched off with '' | + | The syntax for the first or second derivative with respect to a dipole field is like this: |
| + | |||
| + | '' | ||
| + | or | ||
| + | '' | ||
| + | |||
| + | where '' | ||
| + | |||
| + | By default a two-point formula is used for first derivatives (keyword '' | ||
| + | |||
| + | For second derivatives, | ||
| + | |||
| + | The default step size is 0.001 a.u. and may be changed with the option '' | ||
| + | |||
| + | The quadrupole tensor is traceless which is exploited by default | ||
| The energy calculation has to be done with a '' | The energy calculation has to be done with a '' | ||
| + | ==== Examples ==== | ||
| + | |||
| + | This example shows how dipole, quadrupole and third moments can be obtained by computing derivatives with respect to the corresponding fields, and the dipole polarizability. | ||
| + | |||
| + | <code - examples/ | ||
| + | geometry={4 | ||
| + | H2O2 | ||
| + | O1 0.0000 | ||
| + | O2 0.0000 | ||
| + | H3 0.8190 | ||
| + | H4 | ||
| + | } | ||
| + | |||
| + | basis=def2-svp | ||
| + | {hf} | ||
| + | {mp2; | ||
| + | |||
| + | fgrad, | ||
| + | fgrad, | ||
| + | fgrad, | ||
| + | fpol, | ||
| + | |||
| + | proc myproc | ||
| + | {hf} | ||
| + | {mp2} | ||
| + | endproc | ||
| + | |||
| + | |||
| + | |||
| + | </ | ||
| + | |||
| + | This example shows how '' | ||
| + | |||
| + | |||
| + | <code - examples/ | ||
| + | geometry={ | ||
| + | H2O | ||
| + | O 0.0000000000 | ||
| + | H 0.7581330543 | ||
| + | H | ||
| + | } | ||
| + | |||
| + | basis=def2-svp | ||
| + | {hf} | ||
| + | |||
| + | !use first analytial derivative | ||
| + | fpol, | ||
| + | |||
| + | proc myproc | ||
| + | {hf} | ||
| + | {ccsd | ||
| + | expec,dm} | ||
| + | endproc | ||
| + | |||
| + | |||
| + | !compare with twofold numerical derivative | ||
| + | fpol, | ||
| + | </ | ||