## Documentation for module qs_linres_op

Calculate the operators p rxp and D needed in the optimization of the different contribution of the firs order response orbitals in a epr calculation

source: qs_linres_op.F

#### public Subroutines/Functions:

Calculate the first order hamiltonian applied to the ao and then apply them to the ground state orbitals, the h1_psi1 full matrices are then ready to solve the non-homogeneous linear equations that give the psi1 linear response orbitals.
fac_vecp (a, b, c)
...
scale a matrix as a_ij = a_ij * pbc(rc(:,j),ra(:,i))(ixyz)
ind_m2 (ii, iii)
...
...
Calculate the Berry phase operator in the AO basis and then the derivative of the Berry phase operator with respect to the ground state wave function (see paper Putrino et al., JCP, 13, 7102) for the AOs; afterwards multiply with the ground state MO coefficients
SUBROUTINE
set_vecp (i1, i2, i3)
...
SUBROUTINE
set_vecp_rev (i1, i2, i3)
...

#### SUBROUTINEcurrent_operators(current_env, qs_env)^

Calculate the first order hamiltonian applied to the ao and then apply them to the ground state orbitals, the h1_psi1 full matrices are then ready to solve the non-homogeneous linear equations that give the psi1 linear response orbitals.

##### Arguments:
 TYPE(current_env_type) :: current_env ... TYPE(qs_environment_type), POINTER :: qs_env ...

#### FUNCTIONfac_vecp(a, b, c)^

...

 Return Value :: REAL(dp)
##### Arguments:
 INTEGER :: a ... INTEGER :: b ... INTEGER :: c ...

#### SUBROUTINEfm_scale_by_pbc_ac(matrix, ra, rc, cell, ixyz)^

scale a matrix as a_ij = a_ij * pbc(rc(:,j),ra(:,i))(ixyz)

##### Arguments:
 TYPE(cp_fm_type), POINTER :: matrix ... REAL(dp), INTENT(in) :: ra(:,:) ... REAL(dp), INTENT(in) :: rc(:,:) ... TYPE(cell_type), POINTER :: cell ... INTEGER, INTENT(in) :: ixyz ...

#### FUNCTIONind_m2(ii, iii)^

...

 Return Value :: INTEGER
##### Arguments:
 INTEGER :: ii ... INTEGER :: iii ...

#### SUBROUTINEissc_operators(issc_env, qs_env, iatom)^

...

##### Arguments:
 TYPE(issc_env_type) :: issc_env ... TYPE(qs_environment_type), POINTER :: qs_env ... INTEGER, INTENT(in) :: iatom ...

#### SUBROUTINEpolar_operators(polar_env, qs_env)^

Calculate the Berry phase operator in the AO basis and then the derivative of the Berry phase operator with respect to the ground state wave function (see paper Putrino et al., JCP, 13, 7102) for the AOs; afterwards multiply with the ground state MO coefficients

##### Arguments:
 TYPE(polar_env_type) :: polar_env ... TYPE(qs_environment_type), POINTER :: qs_env ...

#### SUBROUTINEset_vecp(i1, i2, i3)^

...

##### Arguments:
 INTEGER, INTENT(in) :: i1 ... INTEGER, INTENT(out) :: i2 ... INTEGER, INTENT(out) :: i3 ...

#### SUBROUTINEset_vecp_rev(i1, i2, i3)^

...

##### Arguments:
 INTEGER, INTENT(in) :: i1 ... INTEGER, INTENT(in) :: i2 ... INTEGER, INTENT(out) :: i3 ...