The first-order frequency dependent response of the density matrix can be expanded as

γ(x, x') = {X_{ai}(x)(x') + Y_{ai}(x)(x')}. |
(7.1) |

The (real) expansion coefficients

| X, Y〉 = |
(7.2) |

on

(

Next we define the 2×2 ``super-matrices''

Λ = , Δ = , |
(7.3) |

where the four-index quantities

If
arises from an electric dipole
perturbation
, the electronic dipole
polarizability at frequency *ω* is

α_{αβ}(ω) = - 〈X_{α}, Y_{α}| μ_{β}〉, |
(7.5) |

δ_{αβ}(ω) = - Im〈X_{α}, Y_{α}| m_{β}〉, |
(7.6) |

where

Excitation energies *Ω*_{n} are the poles of the
frequency-dependent density matrix response. They are thus the zeros
of the operator on the left-hand side of Eq. (7.4),

The corresponding eigenvectors are the transition density matrices for a given excitation (also called ``excitation vectors'' in the following). They are required to be normalized according to

〈X_{n}, Y_{n}| Δ| X_{n}, Y_{n}〉 = 1. |
(7.8) |

Transition moments are evaluated by taking the trace with one-particle operators, e.g.,

^{0n} = 〈X_{n}, Y_{n}|〉 |
(7.9) |

for the electric and

m^{0n} = 〈X_{n}, Y_{n}|m〉 |
(7.10) |

for the magnetic transition dipole moments.

The full TDHF/TDDFT formalism is gauge-invariant, i.e., the
dipole-length and dipole-velocity gauges lead to the same transition
dipole moments in the basis set limit. This can be used as a check for
basis set quality in excited state calculations. The TDA can formally
be derived as an approximation to full TDHF/TDDFT by constraining the
*Y* vectors to zero. For TDHF, the TDA is equivalent to configuration
interaction including all single excitations from the HF reference
(CIS). The TDA is not gauge invariant and does not
satisfy the usual sum rules [76], but it is somewhat less
affected by stability problems (see below).

Stability analysis of closed-shell electronic wavefunctions amounts to
computing the lowest eigenvalues of the electric
orbital rotation Hessian *A* + *B*, which decomposes into a singlet and a
triplet part, and of the magnetic orbital rotation Hessian
*A* - *B*. Note that *A* - *B* is diagonal for non-hybrid DFT, while *A* + *B*
generally is not. See refs. [80,15] for
further details.

Properties of excited states are defined as derivatives of the excited state energy with respect to an external perturbation. It is advantageous to consider a fully variational Lagrangian of the excited state energy [16],

(7.11) |

Here

First, *L* is made stationary with respect to *all* its
parameters. The additional Lagrange multipliers *Z* and *W* enforce
that the MOs satisfy the ground state HF/KS equations and are
orthonormal. *Z* is the so-called *Z*-vector, while *W* turns out to
be the excited state energy-weighted density matrix. Computation of
*Z* and *W* requires the solution of a *single* static TDHF/TDKS
response equation (7.4), also called coupled and perturbed HF/KS
equation. Once the relaxed densities have been computed, excited state
properties are obtained by simple contraction with derivative
integrals in the atomic orbital (AO) basis. Thus, computation of
excited state gradients is more expensive than that of ground state
gradients only by a constant factor which is usually in the range of
1…4.

TDHF/TDDFT expressions for components of the frequency-dependent
polarizability
*α*_{αβ}(*ω*) can also be reformulated
as variational polarizability Lagrangians [81]

(7.12) |

The stationary point of