.. index::
   single: Program; Rhodyn
   single: Rhodyn

.. _UG\:sec\:rhodyn:

:program:`rhodyn`
=================

.. only:: html

  .. contents::
     :local:
     :backlinks: none

.. xmldoc:: <MODULE NAME="RHODYN">
            %%Description:
            <HELP>
            The program RHODYN is used for the density matrix based
            time-dependent configuration interaction (rho-TDCI)
            calculations.
            </HELP>


The program :program:`RHODYN` is used for the density matrix based time-dependent
configuration interaction (:math:`\rho`-TDCI) calculations.
The dynamics of a system initiated by electromagnetic pulse can be obtained
by means of density matrix propagation with the :program:`RASSI` Hamiltonian :cite:`Malmqvist:89`.
Interaction with the field is included in dipole approximation
:math:`H_{\text{int}} = - \vec{d} \cdot \vec{E}`.
The theory and methodology can be found in :cite:`Kochetov:22`.
The feature of the method is the treating core states and valence states
on the same footing if the Hamiltonian is chosen properly; depending on the chosen active space
different processes can be considered.
Because of the faster timescale (atto- to femtosecond), core-states dynamics are even more adequately described in the framework
of TDCI since electron dynamics is isolated from nuclear effects.
Nonetheless, such effects as population and phase relaxation due to nuclear bath, ionization, and Auger decay
can be taken into account (see keywords).
Output of the program:

* **Populations of basis states**

  Configuration state functions, spin-free, spin--orbit coupled states can be chosen as a basis.

* **Full density matrix**

  The full matrix can be output after a given timestep. It can be used to compute various time-dependent observables.

* **Time-evolution of dipole moment**

  The value of an observable can be accessed as :math:`\langle\vec{d}\rangle = \Tr[\rho \vec{d}]`.
  If requested it is written to file :file:`DIPOLE.dat`.

These data can be used to compute

* **Linear and non-linear spectra**, e.g., TD absorption, emission spectra, high harmonic generation, etc.

.. _UG\:sec\:rhodyn_dependencies:

Dependencies
------------

The program workflow requires some input files to be present with wave function
specifications from :program:`RASSCF`, :program:`CASPT2` and their properties from
:program:`RASSI` in HDF5 format. All these dependencies, however, are totally transparent to the user.

.. _UG\:sec\:rhodyn_files:

Files
-----

.. _UG\:sec\:rhodyn_inp_files:

Input files
...........

.. class:: filelist

:file:`RASSDX`
  HDF5 file generated by :program:`RASSCF` or :program:`CASPT2` modules. ``X`` stands for
  number of file.
  Number of files should be equal to the
  number of spin manifolds stated with keyword :kword:`NRSM`.

:file:`RASSISD`
  :program:`RASSI` output file in HDF5 format, calculated on given
  :program:`RASSCF` wave functions. It should contain also additional sets (arrays) in HDF5 file
  which are not standardly included. Writing these sets to HDF5 file is activated with the keyword :kword:`RHODyn` in
  :program:`RASSI`.

:file:`HRFACT`
  File with Huang--Rhys factors. If keyword :kword:`KEXT` is active
  then this file has to contain dissipation rate :math:`k` matrix.
  This file should be generated by the user.
  In general, it provides a 3-rank tensor, see :cite:`Kochetov:20` Eq. 8,
  which is stored in molden format. Section ``[FREQ]`` should contain frequencies of normal
  modes and section ``[HR-FACT]`` gives a matrix (or line) of HR factors for each normal mode.

:file:`INDENS`
  File with initial density matrix (as an :math:`N\times N` ASCII matrix).
  When keyword :kword:`POPUlation style` set to ``FROMFILE``,
  then this file should be present.
  This file should be generated by the user.

..
  :file:`AUGEVEC`
    (To be implemented) File containing the Auger decay rates of the basis states.
    This file should be generated by the user.

.. _UG\:sec\:rhodyn_output_files:

Output files
............

.. class:: filelist

:file:`PULSE`
  Stores the applied electric field. Duplicate in file :file:`RDOUT`.

:file:`CSFDEN`
  This file contains the diagonal density matrix in CSF basis.

:file:`SFDENS`
  This file contains the diagonal density matrix in SF basis.

:file:`SODENS`
  This file contains the diagonal density matrix in SO basis

:file:`RDPREP`
  Intermediate file in HDF5 format which is automatically created
  and contains all required ingredients for propagation: transformation
  matrices from one basis to another, full and spin--orbit coupling
  Hamiltonians, transition dipole matrix, initial density matrix, and
  Dyson amplitudes. Once created this file can be used as an input file
  with keyword :kword:`RUNMode` set to ``2``.

:file:`RDOUT`
  Main output file. Here, almost all relevant information is stored in
  HDF5 format. By far, it includes the electric field data, Hamiltonian
  used for propagation, decay matrix. The time-evolution of the DM diagonal
  is also stored here; thus it is redundant. Optionally, full density matrix
  and emission spectra can be written.

:file:`DIPOLE.dat`
  This file stores the TD-dipole moment data

.. _UG\:sec\:rhodyn_inp:

Input
-----

General keywords
................

.. class:: keywordlist

:kword:`NRSManifolds`
  The number of spin manifolds :math:`n`

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="NRSM" APPEAR="Spin manifolds" KIND="INT" LEVEL="BASIC">
              %%Keyword: NRSManifolds <basic>
              <HELP>
              Number of spin manifolds.
              </HELP>
              </KEYWORD>

:kword:`NSTAte`
  The total number of states involved in the dynamics followed by a list of relevant states.
  If all states from input files are supposed to be used this list can be replaced
  by the word ``ALL``.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="NSTA" APPEAR="Number of states" KIND="INTS_COMPUTED" SIZE="1" LEVEL="BASIC">
              <ALTERNATE KIND="CUSTOM"/>
              %%Keyword: NSTate <basic>
              <HELP>
              Total number of the states involved in the dynamics.
              </HELP>
              </KEYWORD>

:kword:`NRDEt`
  This keyword should be followed by :math:`n` lines
  (math:`n` is the number of spin manifolds, see :kword:`NRSM`), each containing four numbers:
  number of determinants, number of CSFs, number of roots, and spin multiplicity
  for each spin manifold. See examples below.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="NRDE" APPEAR="Determinants, CSFs, roots, and spin" KIND="CUSTOM" LEVEL="BASIC">
              %%Keyword: NRDet <basic>
              <HELP>
              Defines number of determinants, CSFs, roots, and spin multiplicity for each manifold.
              </HELP>
              </KEYWORD>

:kword:`POPUlation style`
  Describes how the initial DM is to be constructed depending on the chosen basis.
  Available options: ``CSF``, ``SF``, ``SF_THERMAL``, ``SO``, ``SO_THERMAL``,
  ``FROMFILE``.

  .. container:: list

    ``CSF`` --- means that given CSFs (specified by keyword :kword:`NRPO`) are populated evenly.

    ``SF`` --- same as ``CSF`` but for spin-free states.

    ``SF_THERMAL`` --- SFs will be populated according to the Boltzmann distribution
    for a given temperature, see keyword :kword:`TEMP`.

    ``SO`` --- same as ``SF`` and ``CSF`` but for spin--orbit-coupled basis states.

    ``SO_THERMAL`` --- same as ``SF_THERMAL`` but for SO basis.

    ``FROMFILE`` --- read the real part of initial DM in ``CSF`` basis from file :file:`INDENS`.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="POPU" APPEAR="State basis to be populated." KIND="CHOICE" LIST="CSF,SF,SF_THERMAL,SO,SO_THERMAL,FROMFILE" LEVEL="BASIC">
              %%Keyword: POPUlation <basic>
              <HELP>
              State basis to be populated.
              </HELP>
              </KEYWORD>

:kword:`NRPO`
  Numbers of states to be populated if :kword:`POPU` is set to ``CSF``, ``SF``, or ``SO``.
  The respective basis states will be evenly populated.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="NRPO" APPEAR="Populated states" KIND="INT" LEVEL="BASIC" DEFAULT_VALUE="1" MIN_VALUE="0">
              %%Keyword: NRPO <basic>
              <HELP>
              Number of states to be populated.
              </HELP>
              </KEYWORD>

:kword:`TEMPerature`
  Temperature in K, which is used with thermal population options
  ``SF_THERMAL`` and ``SO_THERMAL`` (keyword :kword:`POPU`).
  Default is set to 300 K.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="TEMP" APPEAR="Temperature" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="300.0" MIN_VALUE="0.0">
              %%Keyword: TEMPerature <basic>
              <HELP>
              Defines the temperature for initial state population.
              </HELP>
              </KEYWORD>

:kword:`IFSO`
  Flag to include spin--orbit coupling. It is off by default.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="IFSO" APPEAR="Enable spin-orbit coupling" KIND="SINGLE" LEVEL="BASIC">
              %%Keyword: IFSO <basic>
              <HELP>
              Flag to include spin-orbit coupling.
              </HELP>
              </KEYWORD>

:kword:`RUNMode`
  Integer key governing the running mode of the program:

  .. container:: list

    ``1`` --- start propagation from the :program:`RASSCF`/:program:`RASSI` HDF5 files (default);

    ``2`` --- start propagation from reading intermediate file :file:`RDPREP`. Can be used as a checkpointing/restarting option;

    ``3`` --- only create the :file:`RDPREP` without doing the propagation;

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="RUNM" APPEAR="Run mode" KIND="CHOICE" LIST="1:Conventional,2:From prep file,3:No dynamics,4:Test" LEVEL="BASIC" DEFAULT_VALUE="1">
              %%Keyword: RUNMode <basic>
              <HELP>
              Switcher to define what part of the program runs.
              </HELP>
              </KEYWORD>

:kword:`INITialtime`
  Time when propagation starts in fs. 0 fs by default

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="INIT" APPEAR="Initial time" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="0.0" MIN_VALUE="0.0">
              %%Keyword: INITialtime <basic>
              <HELP>
              Time when propagation starts.
              </HELP>
              </KEYWORD>

:kword:`FINAltime`
  Time when propagation ends in fs. 10 fs by default.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="FINA" APPEAR="Final time in fs" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="10.0" MIN_VALUE="0.0">
              %%Keyword: FINAltime <basic>
              <HELP>
              Final time of the propagation.
              </HELP>
              </KEYWORD>

:kword:`TSTEp`
  Time step of integration in fs. Used only with fixed time step methods,
  see keyword :kword:`METH`. 0.0005 fs by default.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="TSTE" APPEAR="Time step" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="0.0005" MIN_VALUE="0.0">
              %%Keyword: TSTEp <basic>
              <HELP>
              Time step of integration in fs.
              </HELP>
              </KEYWORD>

:kword:`METHod`
  Method of integration: Runge--Kutta method of 4th order (``classic_RK4``)
  is set by default. ``RKCK`` (adaptive Runge--Kutta--Cash--Karp)
  with variable time step sometimes is better. Other available integrators are
  ``RK4``, ``RK5``, ``RK45`` (adaptive Runge--Kutta--Fehlberg), and ``RK4_SPH`` (for propagation in spherical tensors basis).

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="METH" APPEAR="Method of integration" KIND="CHOICE" LIST="classic_RK4,RKCK,RK4,RK5,RK45" LEVEL="BASIC" DEFAULT_VALUE="classic_RK4">
              %%Keyword: METHod <basic>
              <HELP>
              Method of integration.
              </HELP>
              </KEYWORD>

:kword:`RK45`
  Error threshold for the adaptive integration methods with variable step.
  :math:`10^{-6}` by default.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="RK45" APPEAR="Error threshold" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="1e-6" MIN_VALUE="0.0">
              %%Keyword: RK45 <basic>
              <HELP>
              Error threshold for the integration methods with changing step.
              </HELP>
              </KEYWORD>

:kword:`RKSAfety`
  Safety parameter to estimate error on each step for methods with
  adaptive step size. The estimated next step size is multiplied by
  the value of safety parameter. It is set to 0.9 by default.
  Increase it to get faster integration but at your own risk.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="RKSA" APPEAR="Safety parameter" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="0.9" MIN_VALUE="0.0">
              %%Keyword: RKSAfety <basic>
              <HELP>
              Safety parameter.
              </HELP>
              </KEYWORD>

:kword:`TOUT`
  Time interval for writing populations and output of the discretized field.
  0.05 fs by default.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="TOUT" APPEAR="Output time step" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="0.05" MIN_VALUE="0.0">
              %%Keyword: TOUT <basic>
              <HELP>
              Time interval of writing populations and of discretizing field.
              </HELP>
              </KEYWORD>

:kword:`PROPbasis`
  Basis used for propagation, spin-free basis by default. For some features such as
  dipole moment or emission spectrum calculations SO basis is preferrable.
  Available options: ``CSF`` basis (could be convenient, e.g., for charge migration studies),
  ``SF`` or ``SO`` bases (could be useful to study spin dynamics).
  ``SPH`` enables the propagation in the basis of spherical tensors.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="PROP" APPEAR="Propagation basis" KIND="CHOICE" LIST="CSF,SF,SO" LEVEL="BASIC" DEFAULT_VALUE="SF">
              %%Keyword: PROPbasis <basic>
              <HELP>
              Basis used for propagation.
              </HELP>
              </KEYWORD>

:kword:`DMBAsis`
  Basis used for the output of density matrix diagonal elements (populations),
  ``SF_SO`` means that density matrix is printed in two basis sets: spin-free and spin--orbit.
  Default value is set to ``SF``.
  Available options: ``CSF``, ``SF``, ``SO``, ``CSF_SF``, ``SF_SO``, ``CSF_SO``, ``ALL``.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="DMBA" APPEAR="DM basis" KIND="CHOICE" LIST="CSF,SF,SO,CSF_SF,SF_SO,CSF_SO,ALL" LEVEL="BASIC" DEFAULT_VALUE="SF">
              %%Keyword: DMBAsis <basic>
              <HELP>
              Density matrix basis.
              </HELP>
              </KEYWORD>

:kword:`KMAX`
  Maximal rank of spherical tensor included in the spherical basis.
  Employed maximal rank can be reduced only if the ``SPH`` propagation basis is activated.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="KMAX" APPEAR="Maximal rank" KIND="INT" LEVEL="BASIC" DEFAULT_VALUE="0" MIN_VALUE="0">
              %%Keyword: KMAX <basic>
              <HELP>
              Maximal rank in spherical tensors basis.
              </HELP>
              </KEYWORD>

:kword:`QMAX`
  Maximal projection of spherical tensor included in the spherical basis.
  Employed maximal projection can be reduced only if the ``SPH`` propagation basis is activated.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="QMAX" APPEAR="Maximal projection" KIND="INT" LEVEL="BASIC" DEFAULT_VALUE="0" MIN_VALUE="0">
              %%Keyword: QMAX <basic>
              <HELP>
              Maximal projection of spherical tensors basis.
              </HELP>
              </KEYWORD>

:kword:`TFDM`
  Time step (in fs) for the output of the full density matrix.
  Without this keyword the full DM will NOT be saved in file :file:`RDOUT`.


  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="TFDM" APPEAR="Time step for full density matrix" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="1.0" MIN_VALUE="0.0">
              %%Keyword: TFDM <basic>
              <HELP>
              Time step for output of full density matrix.
              </HELP>
              </KEYWORD>

:kword:`DYSO`
  Flag to switch on the ionization.
  Works only if :kword:`DYSOn` keyword was used in :program:`RASSI`.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="DYSO" APPEAR="Enable the ionization" KIND="SINGLE" LEVEL="BASIC">
              %%Keyword: DYSO <basic>
              <HELP>
              Enable the ionization.
              </HELP>
              </KEYWORD>

:kword:`ALPHa`
  Scaling parameter :math:`\alpha` for the matrix of Dyson amplitudes.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="ALPH" APPEAR="Dyson amplitude scaling parameter" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="0.001" MIN_VALUE="0.0">
              %%Keyword: ALPHa <basic>
              <HELP>
              Scaling parameter for the Dyson amplitudes.
              </HELP>
              </KEYWORD>

:kword:`IONDissipation`
  A parameter defining the phenomenological decay rates of the ionized states.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="IOND" APPEAR="Decay rate of ionized states" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="0.0" MIN_VALUE="0.0">
              %%Keyword: IONDissipation <basic>
              <HELP>
              Decay of ionized states.
              </HELP>
              </KEYWORD>

:kword:`IFDIssipation`
  Flag to switch on the dissipation due to the coupling to vibrational bath.
  See :cite:`Kochetov:20`.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="IFDI" APPEAR="Enable dissipation" KIND="SINGLE" LEVEL="BASIC">
              %%Keyword: IFDIssipation <basic>
              <HELP>
              Enable dissipation.
              </HELP>
              </KEYWORD>

:kword:`NMODe`
  Number of vibrational modes included in the calculation.
  Needed only if :kword:`IFDI` is activated.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="NMOD" APPEAR="Vibrational modes" KIND="INT" LEVEL="BASIC" DEFAULT_VALUE="0" MIN_VALUE="0">
              %%Keyword: NMODe <basic>
              <HELP>
              Number of vibrational modes included.
              </HELP>
              </KEYWORD>

:kword:`GAMMa`
  The coupling of the primary heat bath to the secondary
  one in :math:`\text{cm}^{-1}`. See :cite:`Kochetov:20`, Eq. 7.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="GAMM" APPEAR="Electronic-nuclear bath coupling" KIND="REAL" LEVEL="BASIC" DEFAULT_VALUE="300.0" MIN_VALUE="0.0">
              %%Keyword: GAMMa <basic>
              <HELP>
              Electronic-nuclear bath coupling.
              </HELP>
              </KEYWORD>

:kword:`HRSO`
  Enables reading of Huang--Rhys factors from file :file:`HR-FACT` in spin--orbit coupled basis.
  See :cite:`Kochetov:20`, Eq. 8.
  Provided that :kword:`KEXT` is not specified, both :kword:`GAMM` and :kword:`HRSO` are used to compute
  the dissipation rates according to Eq. 11 in :cite:`Kochetov:20`.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="HRSO" APPEAR="Enable reading Huang-Rhys factors" KIND="SINGLE" LEVEL="BASIC">
              %%Keyword: HRSO <basic>
              <HELP>
              Enables reading of Huang-Rhys factors.
              </HELP>
              </KEYWORD>

:kword:`KEXTernal`
  Enables reading in the dissipation rate matrix :math:`k` from the file :file:`KEXT`.
  :kword:`KEXTernal` is an alternative to keywords :kword:`HRSO` and :kword:`GAMM`.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="KEXT" APPEAR="External k matrix" KIND="SINGLE" LEVEL="BASIC">
              %%Keyword: KEXTernal <basic>
              <HELP>
              Enables reading the dissipation rate matrix.
              </HELP>
              </KEYWORD>

:kword:`NPULses`
  Number of incoming electric pulses, ``1`` by default. Set it to ``0`` if no pulse is needed.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="NPUL" APPEAR="Incoming pulses" KIND="INT" LEVEL="BASIC" DEFAULT_VALUE="1">
              %%Keyword: NPULses <basic>
              <HELP>
              Number of incoming electric pulses.
              </HELP>
              </KEYWORD>

:kword:`PTYPe`
  Defines form of the pulse envelope function for each pulse.
  The electric field is supposed to be in the form :math:`A\vec{e}s(t)\sin{(\Omega(t-t_0)+\varphi_0)}`,
  where :math:`s(t)` is the envelope function. Available options are

  .. container:: list

    ``Gauss`` --- Gaussian shape :math:`s(t)=\exp (-(t-t_0)^2/(2\sigma^2))`. Set by default.

    ``sinX``, ``cosX`` --- more localized shape :math:`s(t)=\sin^X(\pi(t-t_0)/(2\sigma))`.
    Here ``X`` is the power to which the sine or cosine function is raised. For example, ``sin16`` describes
    a :math:`\sin^{16}` shape function.
    The support of a single pulse is :math:`[t_0, t_0+2\sigma]` for ``sinX`` and :math:`[t_0-\sigma, t_0+\sigma]` for ``cosX``.

    ``Mono`` --- monochromatic pulse without shape function.

    ``TYPE_X_CIRCLE`` --- explicitly circularly polarized light, where ``X`` can be ``L`` or
    ``R`` for left and right direction, and ``TYPE`` replaces ``Mono`` or ``Gauss``. For example, ``GAUSS_R_CIRCLE``

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="PTYP" APPEAR="Pulse type" KIND="CHOICE" LIST="Gauss,Mono" LEVEL="BASIC" DEFAULT_VALUE="Gauss">
              <ALTERNATE KIND="STRING" />
              %%Keyword: PTYPe <basic>
              <HELP>
              Pulse type.
              </HELP>
              </KEYWORD>

:kword:`AMPLitude`
  On one line define as many amplitude values :math:`A` in atomic units as many pulses you ask for.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="AMPL" APPEAR="Amplitudes" KIND="REALS_LOOKUP" SIZE="NPUL" LEVEL="BASIC">
              %%Keyword: AMPLitude <basic>
              <HELP>
              Amplitudes for incoming pulses.
              </HELP>
              </KEYWORD>

:kword:`TAUShift`
  Here should be shifts :math:`t_0` in fs for each pulse with respect to
  the global initial time point.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="TAUS" APPEAR="Shifts of pulse centers" KIND="REALS_LOOKUP" SIZE="NPUL" LEVEL="BASIC">
              %%Keyword: TAUShift <basic>
              <HELP>
              Center shift of incoming pulses.
              </HELP>
              </KEYWORD>

:kword:`POLArization`
  Three complex numbers in the format ``(XR,XI) (YR,YI) (ZR,ZI)`` defining the polarization :math:`\vec{e}`. By default, the electric
  field is considered to be linear polarized along the :math:`x`-direction. If the
  number of pulses is more than one, the polarization vector should be
  given for each pulse on a separate line.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="POLA" APPEAR="Polarizations" KIND="CUSTOM" LEVEL="BASIC">
              %%Keyword: POLArization <basic>
              <HELP>
              Polarization of incoming pulses.
              </HELP>
              </KEYWORD>

:kword:`SIGMa`
  Pulse dispersion :math:`\sigma` in fs for each pulse (in one line separated by space). See keyword :kword:`PTYP` for definition.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="SIGM" APPEAR="Widths of pulses" KIND="REALS_LOOKUP" SIZE="NPUL" LEVEL="BASIC">
              %%Keyword: SIGMa <basic>
              <HELP>
              Pulse width in fs.
              </HELP>
              </KEYWORD>

:kword:`OMEGa`
  Carrier frequency :math:`\Omega` in eV for each pulse (in one line separated by space).

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="OMEG" APPEAR="Frequencies of pulses" KIND="REALS_LOOKUP" SIZE="NPUL" LEVEL="BASIC">
              %%Keyword: OMEGa <basic>
              <HELP>
              Carrier frequency of incoming pulses.
              </HELP>
              </KEYWORD>

:kword:`PHASe`
  Phase :math:`\varphi_0` in radians for each pulse.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="PHAS" APPEAR="Phases for each pulse" KIND="REALS_LOOKUP" SIZE="NPUL" LEVEL="BASIC">
              %%Keyword: PHASe <basic>
              <HELP>
              Phase in radians for each pulses.
              </HELP>
              </KEYWORD>

:kword:`CHIRp`
  Enable correction to carrier frequency simulating experimental linear frequency chirp.
  Due to time-dependent phase, the carrier frequency gets an additional linear term
  :math:`\Omega \rightarrow \Omega + a (t - t_0)`.
  The constant :math:`a` should be specified.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="CHIR" APPEAR="Linear chirp constant" KIND="REAL" LEVEL="BASIC">
              %%Keyword: CHIRp <basic>
              <HELP>
              Linear chirp constant.
              </HELP>
              </KEYWORD>

:kword:`ACORrection`
  Enable correction to electromagnetic pulse as if is given as time derivative of
  a vector potential.

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="ACOR" APPEAR="Vector potential correction" KIND="SINGLE" LEVEL="BASIC">
              %%Keyword: ACORrection <basic>
              <HELP>
              Vector potential correction.
              </HELP>
              </KEYWORD>

:kword:`DIPOle`
  Activates the calculation of mean value of dipole moment, currently it is
  written to the file :file:`DIPOLE.dat`

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="DIPO" APPEAR="Calculate dipole moment" KIND="SINGLE" LEVEL="BASIC">
              %%Keyword: DIPOle <basic>
              <HELP>
              Activates calculation of mean value of dipole moment.
              </HELP>
              </KEYWORD>

:kword:`EMISsion`
  Activates the calculation of emission spectrum

  .. xmldoc:: <KEYWORD MODULE="RHODYN" NAME="EMIS" APPEAR="Calculate emission spectra" KIND="SINGLE" LEVEL="BASIC">
              %%Keyword: EMISsion <basic>
              <HELP>
              Activates calculation of emission spectra.
              </HELP>
              </KEYWORD>

Input examples
..............

.. extractfile:: ug/RHODYN.input

  > copy /path/to/file/s3.rasscf.h5  RASSD1
  > copy /path/to/file/s1.rasscf.h5  RASSD2
  > copy /path/to/file/si.rassisd.h5 RASSISD
  > copy /path/to/file/kmatrix.dat   HRFACT

  &RHODYN

  NRSManifolds          = 2
  NRDEt,CSF,STATES,SPIN = 25   25   25   3
                          30   30   30   1
  NSTAte                = 105 all
  FINAltime             = 10
  IFSO
  AMPLitude             = 9.0
  TAUShift              = 1.
  SIGMa                 = 0.3
  OMEGa                 = 875
  IfDissipation
  KEXTernal

::

  &RHODYN

  NRSManifolds          = 2
  NRDEt,CSF,STATES,SPIN = 25   25   25   3
                          30   30   30   1
  POPUlatedstyle        = SO_THERMAL
  NSTAte                = 105 all
  FINAltime             = 6
  Tout                  = 0.0005
  METHod                = RKCK
  IFSO
  DMBAsis               = SO
  PROPbasis             = SO
  TFDM                  = 0.005

  PTYPe                 = Gaussian
  NPULses               = 1
  AMPLitude             = 9.0
  TAUShift              = 1.
  POLArization          = (1.0,0.0) (0.0,0.0) (0.0,0.0)
  SIGMa                 = 0.3
  OMEGa                 = 875
  PHASe                 = 0
  Dipole
  Emission

.. xmldoc:: </MODULE>
