Zagreb SH

Back to Main Menu

The Zagreb Surface Hopping Code

Quantics contains an interface to the Zagreb SH code to perform surface hopping calculations. The code is written and maintained by the group of Nadia Doslic in Zagreb, Croatia. It must first be compiled by typing

from the $QUANTICS_DIR/install directory. A fortran 2003 compile (gfortran 6.0 or above) is required.

A calculation is set up as a usual wavepacket calculation with the following keywords in the RUN-SECTION .

XXX Section Description
srfhop_zagreb RUN-SECTION Run the Zagreb Surface Hopping code.
swarm = I[, I0] RUN-SECTION I trajectories are run as a swarm. If given, I0 is the first trajectory.
rdsrfhop RUN-SECTION Analysis of previous trajectories done - no new trajectories run.

General Input for an Analytical Operator

If an analytical operator is used, the standard Quantics input with a PRIMITIVE-BASIS-SECTION is used. The system must be set up with all DOFs given a classical primitive basis. To freeze coordinates, a point DVR can be used.

Note on Coordinates. The ZSH code uses Cartesian coordinates for a set of atoms. To use an operator with non-Cartesian coordinates an appropriate transformation must be set up.

XXX Section Description
shztrans = read, I OPERATOR-SECTION The surface hopping calculation will propagate I atoms while the operator and output uses the (non-Cartesian) coordinates defined in the PRIMITIVE-BASIS-SECTION as usual. The transformation between the 2 coordinate is defined in a TSHTRANS-SECTION
shztrans = LVC OPERATOR-SECTION The operator is a vibronic coupling Hamiltonian written in mass-frequency scaled coordinates. The frequencies for the modes must be included as parameters freq0_F in the operator parameter list.
An example for a general transformation is the Ferretti model, which is a 2D 3-state operator of a simple conical intersection. The operator is ferretti.op while the TSH input is ferrettin_tsh.inp and the input for an exact grid-based calculation is ferrettin_ex.inp

An example for a TSH calculation on a vibronic coupling Hamiltoninan is given for butatriene in but_tsh.inp which uses the operator C4H4.linear.op and for a 2D pyrazine calculation using a point DVR to freeze coordinates in the 4-mode model is in pyr4_tsh2d.inp

Control of the surface hopping calculation is given in the SH_ZAGREB-SECTION

XXX Description
run_cmd = S the string S is the path and name of a script to run the ZSH code. The default is $QUANTICS_DIR/bin/run_shzagreb
ovwr_tr The trajectory files will be overwritten and trajectories re-run. Otherwise, the usual Quantics overwrite option will overwrite the Quantics files but keep the raw trajectory data. If a calculation is re-run asking for more trajectories, these will be added.
ignore_frhops Ignore trajectories with frustrated hops in analysis
ignore_deltae [ =R] Ignore trajectories with large energy fluctuations. R is the threshold in eV. Default: 0.01 eV
Keywords for the ZSH code are given as they would be written in the surface hopping input file. Sections

ZSH Input

The ZSH code requires a file which requires input on separate lines. If nothing is given, Quantics will write this file, taking values were possible from the Quantics input. The $system$ input, which defines the no. of states and initial state is always given by Quantics, other options will be taken from the SH_ZAGREB-SECTION if given. For example the time-step used in the integration can be selected using
 tstep = 0.2
The default value is 0.1. Documentation for the ZSH code, with possible options is to be found Here In the $surfhop section a seed can be selected for the random number used in the hop procedure. By default this is set to -1, which is equivalent to
 seed -1
and the Zagreb codes sets a seed using the PID and time. If this is set to a non-negative integer, this value will be used for all trajectories. This is not a good idea in general as it biases the hopping, but can be useful for testing as it means runs are repeatable.

Output Files

The output files for the quantics calculation are as usual in the name directory. The files can be analysed as usual using the analysis programs. for example, showsys can be used to plot the surfaces or the evolving "wavepacket" (composed of the trajectories), or statepop can be used to plot state populations. The raw data from the I trajectories are in name/zagreb_trj/traj.n . The main output is in dynamics.out and a log file zagreb.log is written.

Extending a calculation

If I trajectories are asked for and the results for J trajectories from a previous calculation are stored in the name directory, the code will stop if I=J. If I > J then the trajectories J+1 ...I will be run and the results updated.