11. Optical spectra: real-time TDDFT

rt_tddft: propagates the Kohn–Sham density matrix in time after the ground-state SCF of the same run (Runge and Gross 1984; real-time approach: Yabana and Bertsch 1996, Gaussian-basis implementation: Lopata and Govind 2011). A weak delta kick excites all transitions at once; the Fourier transform of the induced dipole \(\mu(t)\) is the absorption spectrum. Unlike 10. Excitation energies: linear-response TDDFT it gives the whole spectrum, also in the nonlinear regime and with strong fields.

coulomb:
  method: density_fitting
  aux_basis_file: basis/def2-universal-JFIT.nw

rt_tddft:
  field: kick
  kick: 1.0e-3
  axis: xyz
  dt: 0.1
  steps: 5000
  corrector_iterations: 2
  wmax_ev: 15
  output: h2co

Key (rt_tddft:)

Default

Meaning

propagator

expm

expm (exact exponential, unitary), magnus, or cranknic

dt, steps

0.05, 1000

time step and number of steps (atomic units)

corrector_iterations

1

self-consistent mid-point Fock matrix; 2 to 3 conserve the energy

field

kick

kick, gaussian, pulse, cw, pulse2, static (finite-field α, β, γ) or none

kick, amplitude, omega, t0, sigma

1e-3, …

field parameters (a.u.)

axis

z

x, y, z or xyz (three kicks: full polarizability and isotropic spectrum)

spectrum

fft

damped Fourier transform (gamma, wmax_ev, dw_ev) or pade (Bruner, LaMaster, Lopata 2016)

analysis

false

line fit with oscillator strengths, transition densities, MO-pair assignment

cap

false

complex absorbing potential for ionization

populations

false

time-resolved charges and MO occupations

output

rt

prefix of <output>_dipole.dat and <output>_spectrum.dat

Requirements and tips

  • Converged collinear DFT ground state, moment_mode: fixed, no level shift; coulomb: method is eri, density_fitting, poisson or analytic. Global hybrids need density_fitting.

  • The run prints the energy drift, the change of the electron number and the idempotency error at the end; with corrector_iterations: 2 and a weak kick these should be negligible.

  • The spectral resolution is set by the total time: 100 a.u. resolves about 1.7 eV, 500 a.u. about 0.34 eV.

  • Keep the kick weak (10⁻³ a.u.) for linear response; the spectrum is then identical to the Casida one. tools/rt_spectrum.py post-processes the dipole files (windows, padding, Padé, overlay with a linear-response spectrum).

  • Nuclei are fixed here; moving nuclei are treated with job: task: md and md: method: ehrenfest.

Example: formaldehyde

In Tutorial 6 the RT-TDDFT peaks at 5.77, 6.63 and 10.22 eV agree with the linear-response roots at 5.79, 6.60 and 10.21 eV (PBE/aug-pc-1); the dark n→π* state at 3.84 eV gives no peak. The tutorial also shows a laser pulse tuned to the 10.2 eV peak with the time-dependent populations.

Related tutorials: Optical spectra from real-time TDDFT, Excitation energies (linear-response TDDFT).