mo_basis

Molecular orbitals are expressed as

\[\phi_k({\bf r}) = \sum_i C_{ik} \chi_k({\bf r})\]

where \(\chi_k\) are normalized atomic basis functions.

The current set of MOs has a label mo_label. When the orbitals are modified, the label should also be updated to keep everything consistent.

When saving the MOs, the mo_basis directory of the EZFIO database is copied in the save directory, named by the current mo_label. All this is done with the script named save_current_mos.sh in the $QP_ROOT/scripts directory.

EZFIO parameters

mo_num

Total number of MOs

mo_coef

Coefficient of the i-th AO on the j-th MO

mo_coef_aux

AUX Coefficient of the i-th AO on the j-th MO

mo_coef_imag

Imaginary part of the MO coefficient of the i-th AO on the j-th MO

mo_label

Label characterizing the MOS (Local, Canonical, Natural, etc)

mo_occ

MO occupation numbers

mo_symmetry

MOs with the same integer belong to the same irrep.

mo_class

[ Core | Inactive | Active | Virtual | Deleted ], as defined by qp_set_mo_class

ao_md5

MD5 checksum characterizing the AO basis set.

Providers

mo_class

File : mo_basis/mo_class.irp.f

character*(32), allocatable     :: mo_class     (mo_num)

[ Core | Inactive | Active | Virtual | Deleted ], as defined by qp_set_mo_class

Needs:

  • ezfio_filename

  • mo_num

  • mpi_master

Needed by:

  • list_act

  • list_all_but_del_orb

  • list_core

  • list_del

  • list_inact

  • list_virt

  • mo_two_e_integrals_erf_in_map

  • mo_two_e_integrals_in_map

  • n_act_orb

  • n_all_but_del_orb

  • n_core_orb

  • n_del_orb

  • n_inact_orb

  • n_virt_orb

mo_coef

File : mo_basis/mos.irp.f

double precision, allocatable   :: mo_coef      (ao_num,mo_num)

Molecular orbital coefficients on AO basis set

mo_coef(i,j) = coefficient of the i-th AO on the jth MO

mo_label : Label characterizing the MOs (local, canonical, natural, etc)

Needs:

  • ao_num

  • ao_ortho_canonical_coef

  • ezfio_filename

  • mo_num

  • mpi_master

Needed by:

  • attachment_orbitals

  • cholesky_mo_transp

  • d0tu_alpha_ao

  • eigenvectors_fock_matrix_mo

  • fock_matrix_mo_alpha

  • fock_matrix_mo_beta

  • fps_spf_matrix_mo

  • mcscf_fock_alpha_mo

  • mo_coef_in_ao_ortho_basis

  • mo_coef_transp

  • mo_deriv_1_x

  • mo_dipole_x

  • mo_integrals_n_e

  • mo_integrals_n_e_per_atom

  • mo_kinetic_integrals

  • mo_overlap

  • mo_pseudo_integrals

  • mo_pseudo_integrals_local

  • mo_pseudo_integrals_non_local

  • mo_spread_x

  • mo_two_e_int_erf_jj_from_ao

  • mo_two_e_integrals_erf_in_map

  • mo_two_e_integrals_in_map

  • natorbsfci

  • one_e_dm_alpha_ao_for_dft

  • one_e_dm_alpha_ao_for_dft_no_core

  • one_e_dm_ao_alpha

  • one_e_dm_ao_alpha_nstates

  • one_e_dm_mo_alpha_for_dft

  • one_e_dm_mo_beta_for_dft

  • one_e_spin_density_ao

  • psi_det

  • s_mo_coef

  • scf_density_matrix_ao_alpha

  • scf_density_matrix_ao_beta

mo_coef_aux

File : mo_basis/mos_aux.irp.f

double precision, allocatable   :: mo_coef_aux  (ao_num,mo_num)

Needs:

  • ao_num

  • ao_ortho_canonical_coef

  • ezfio_filename

  • mo_num

  • mpi_master

mo_coef_imag

File : mo_basis/mos.irp.f

double precision, allocatable   :: mo_coef_imag (ao_num,mo_num)

Molecular orbital coefficients on AO basis set

mo_coef_imag(i,j) = coefficient of the i-th AO on the jth MO

mo_label : Label characterizing the MOs (local, canonical, natural, etc)

Needs:

  • ao_num

  • ezfio_filename

  • mo_num

  • mpi_master

mo_coef_in_ao_ortho_basis

File : mo_basis/mos.irp.f

double precision, allocatable   :: mo_coef_in_ao_ortho_basis    (ao_num,mo_num)

MO coefficients in orthogonalized AO basis

\(C^{-1}.C_{mo}\)

Needs:

  • ao_num

  • ao_ortho_canonical_coef_inv

  • mo_coef

  • mo_num

mo_coef_transp

File : mo_basis/mos.irp.f

double precision, allocatable   :: mo_coef_transp       (mo_num,ao_num)

MO coefficients on AO basis set

Needs:

  • ao_num

  • mo_coef

  • mo_num

Needed by:

  • cholesky_semi_mo_transp_simple

  • mo_two_e_int_erf_jj_from_ao

  • mo_two_e_integrals_erf_in_map

  • mo_two_e_integrals_in_map

mo_label

File : mo_basis/mos.irp.f

character*(64)  :: mo_label

MO coefficients on AO basis set

mo_coef(i,j) = coefficient of the i-th AO on the j-th MO

mo_label : Label characterizing the MOs (local, canonical, natural, etc)

Needs:

  • ezfio_filename

  • mpi_master

Needed by:

  • n_det

  • psi_coef

  • psi_det

mo_num

File : mo_basis/mos.irp.f

integer :: mo_num

Number of MOs

Needs:

  • ao_ortho_canonical_coef

  • ezfio_filename

  • mpi_master

Needed by:

  • ao_one_e_integrals_from_mo

  • ao_ortho_canonical_nucl_elec_integrals

  • ao_ortho_lowdin_nucl_elec_integrals

  • attachment_numbers_sorted

  • attachment_orbitals

  • banned_excitation

  • bielec_pqxx_array

  • bielec_pqxx_no_array

  • bielec_pxxq_array

  • bielec_pxxq_no_array

  • bielecci

  • bielecci_no

  • big_array_coulomb_integrals

  • cholesky_mo

  • cholesky_mo_transp

  • cholesky_no_1_idx_transp

  • cholesky_no_total_transp

  • cholesky_semi_mo_transp_simple

  • core_fock_operator

  • core_fock_operator_erf

  • d0tu_alpha_ao

  • data_one_e_dm_alpha_mo

  • data_one_e_dm_beta_mo

  • difference_dm

  • difference_dm_eigvect

  • eigenvectors_fock_matrix_mo

  • fapq

  • fipq

  • fock_matrix_ao

  • fock_matrix_mo

  • fock_matrix_mo_alpha

  • fock_matrix_mo_beta

  • fock_operator_closed_shell_ref_bitmask

  • fock_wee_closed_shell

  • fps_spf_matrix_mo

  • full_ijkl_bitmask

  • h_core_ri

  • int_erf_3_index

  • list_act

  • list_all_but_del_orb

  • list_core

  • list_core_inact

  • list_core_inact_act

  • list_del

  • list_inact

  • list_inact_act

  • list_virt

  • lowest_super_ci_coef_mo

  • mcscf_fock_alpha_mo

  • mcscf_fock_mo

  • mo_class

  • mo_coef

  • mo_coef_aux

  • mo_coef_begin_iteration

  • mo_coef_imag

  • mo_coef_in_ao_ortho_basis

  • mo_coef_transp

  • mo_deriv_1_x

  • mo_dipole_x

  • mo_integrals_cache_min

  • mo_integrals_erf_cache_min

  • mo_integrals_erf_map

  • mo_integrals_map

  • mo_integrals_n_e

  • mo_integrals_n_e_per_atom

  • mo_kinetic_integrals

  • mo_occ

  • mo_one_e_integrals

  • mo_overlap

  • mo_pseudo_integrals

  • mo_pseudo_integrals_local

  • mo_pseudo_integrals_non_local

  • mo_spread_centered_x

  • mo_spread_x

  • mo_two_e_int_erf_jj

  • mo_two_e_int_erf_jj_from_ao

  • mo_two_e_integrals_erf_in_map

  • mo_two_e_integrals_in_map

  • mo_two_e_integrals_jj

  • multi_s_deriv_1

  • multi_s_dipole_moment

  • n_act_orb

  • n_all_but_del_orb

  • n_attachment

  • n_core_orb

  • n_del_orb

  • n_inact_orb

  • n_int

  • n_virt_orb

  • natorbsci_mos

  • natorbsfci

  • neworbs

  • occnum

  • one_body_dm_mo_alpha_one_det

  • one_e_dm_alpha_ao_for_dft

  • one_e_dm_alpha_ao_for_dft_no_core

  • one_e_dm_ao_alpha

  • one_e_dm_ao_alpha_nstates

  • one_e_dm_average_alpha_mo_for_dft

  • one_e_dm_average_beta_mo_for_dft

  • one_e_dm_average_mo_for_dft

  • one_e_dm_dagger_mo_spin_index

  • one_e_dm_mo

  • one_e_dm_mo_alpha

  • one_e_dm_mo_alpha_average

  • one_e_dm_mo_alpha_for_dft

  • one_e_dm_mo_alpha_for_dft_no_core

  • one_e_dm_mo_beta_for_dft

  • one_e_dm_mo_beta_for_dft_no_core

  • one_e_dm_mo_diff

  • one_e_dm_mo_for_dft

  • one_e_dm_mo_spin_index

  • one_e_spin_density_ao

  • one_e_spin_density_mo

  • one_e_tr_dm_mo

  • one_e_tr_dm_mo_alpha

  • one_ints_no

  • ormas_n_orb

  • psi_energy_h_core

  • s_mo_coef

  • super_ci_dm

  • superci_natorb

  • switch_mo_coef

  • two_e_dm_mo

  • umat

  • v_ne_psi_energy

  • z_dipole_moment

mo_occ

File : mo_basis/mos.irp.f

double precision, allocatable   :: mo_occ       (mo_num)

MO occupation numbers

Needs:

  • elec_alpha_num

  • elec_beta_num

  • ezfio_filename

  • mo_num

  • mpi_master

Subroutines / functions

ao_ortho_cano_to_ao:

File : mo_basis/mos.irp.f

subroutine ao_ortho_cano_to_ao(A_ao,LDA_ao,A,LDA)

Transform A from the AO basis to the orthogonal AO basis

$C^{-1}.A_{ao}.C^{dagger-1}$

Needs:

  • ao_num

  • ao_ortho_canonical_coef_inv

Calls:

  • dgemm()

ao_to_mo:

File : mo_basis/mos.irp.f

subroutine ao_to_mo(A_ao,LDA_ao,A_mo,LDA_mo)

Transform A from the AO basis to the MO basis

$C^dagger.A_{ao}.C$

Needs:

  • ao_num

  • mo_coef

  • mo_num

Called by:

  • fock_matrix_mo_alpha

  • fock_matrix_mo_beta

  • fps_spf_matrix_mo

  • mcscf_fock_alpha_mo

  • mo_deriv_1_x

  • mo_dipole_x

  • mo_integrals_n_e

  • mo_integrals_n_e_per_atom

  • mo_kinetic_integrals

  • mo_pseudo_integrals

  • mo_pseudo_integrals_local

  • mo_pseudo_integrals_non_local

  • mo_spread_x

  • one_e_dm_mo_alpha_for_dft

  • one_e_dm_mo_beta_for_dft

Calls:

  • dgemm()

  • restore_symmetry()

give_all_mos_and_grad_and_lapl_at_r:

File : mo_basis/mos_in_r.irp.f

subroutine give_all_mos_and_grad_and_lapl_at_r(r,mos_array,mos_grad_array,mos_lapl_array)

Needs:

  • ao_num

  • mo_coef

  • mo_num

Calls:

  • give_all_aos_and_grad_and_lapl_at_r()

give_all_mos_and_grad_at_r:

File : mo_basis/mos_in_r.irp.f

subroutine give_all_mos_and_grad_at_r(r,mos_array,mos_grad_array)

Needs:

  • ao_num

  • mo_coef

  • mo_num

Calls:

  • give_all_aos_and_grad_at_r()

give_all_mos_at_r:

File : mo_basis/mos_in_r.irp.f

subroutine give_all_mos_at_r(r,mos_array)

mos_array(i) = ith MO function evaluated at “r”

Needs:

  • ao_num

  • mo_coef_transp

  • mo_num

Calls:

  • dgemv()

  • give_all_aos_at_r()

mix_mo_jk:

File : mo_basis/mos.irp.f

subroutine mix_mo_jk(j,k)

Rotates the j-th MO with the k-th MO to give two new MOs that are

  • $+ = frac{1}{sqrt{2}} ( | jrangle + | krangle)$

  • $- = frac{1}{sqrt{2}} ( | jrangle - | krangle)$

by convention, the ‘+’ MO is in the lowest index (min(j,k)) by convention, the ‘-’ MO is in the highest index (max(j,k))

Needs:

  • ao_num

  • mo_coef

mo_as_eigvectors_of_mo_matrix:

File : mo_basis/utils.irp.f

subroutine mo_as_eigvectors_of_mo_matrix(matrix,n,m,label,sign,output)

Needs:

  • ao_num

  • mo_coef

  • mo_label

  • mo_num

Called by:

  • create_guess()

  • damping_scf()

  • hcore_guess()

  • roothaan_hall_scf()

Calls:

  • dgemm()

  • lapack_diag()

  • write_time()

mo_as_svd_vectors_of_mo_matrix:

File : mo_basis/utils.irp.f

subroutine mo_as_svd_vectors_of_mo_matrix(matrix,lda,m,n,label)

Needs:

  • ao_num

  • mo_coef

  • mo_label

  • mo_num

Calls:

  • dgemm()

  • svd()

  • write_time()

mo_as_svd_vectors_of_mo_matrix_eig:

File : mo_basis/utils.irp.f

subroutine mo_as_svd_vectors_of_mo_matrix_eig(matrix,lda,m,n,eig,label)

Needs:

  • ao_num

  • mo_coef

  • mo_label

  • mo_num

Called by:

  • set_natorb_no_ov_rot()

  • set_natural_mos()

  • set_natural_mos_canon_label()

Calls:

  • dgemm()

  • svd()

  • write_time()

mo_coef_new_as_svd_vectors_of_mo_matrix_eig:

File : mo_basis/utils.irp.f

subroutine mo_coef_new_as_svd_vectors_of_mo_matrix_eig(matrix,lda,m,n,mo_coef_before,eig,mo_coef_new)

You enter with matrix in the MO basis defined with the mo_coef_before.

You SVD the matrix and set the eigenvectors as mo_coef_new ordered by increasing singular values

Needs:

  • ao_num

  • mo_num

Calls:

  • dgemm()

  • svd()

  • write_time()

save_mos:

File : mo_basis/utils.irp.f

subroutine save_mos

Needs:

  • ao_md5

  • ao_num

  • mo_class

  • mo_coef

  • mo_label

  • mo_num

  • mo_occ

Called by:

  • damping_scf()

  • hcore_guess()

  • huckel_guess()

  • roothaan_hall_scf()

  • run_orb_opt_trust_v2()

  • save_natural_mos()

  • save_natural_mos_canon_label()

  • save_natural_mos_no_ov_rot()

Calls:

  • ezfio_set_mo_basis_ao_md5()

  • ezfio_set_mo_basis_mo_class()

  • ezfio_set_mo_basis_mo_coef()

  • ezfio_set_mo_basis_mo_label()

  • ezfio_set_mo_basis_mo_num()

  • ezfio_set_mo_basis_mo_occ()

save_mos_no_occ:

File : mo_basis/utils.irp.f

subroutine save_mos_no_occ

Needs:

  • ao_num

  • mo_coef

  • mo_num

Calls:

  • ezfio_set_mo_basis_mo_coef()

save_mos_truncated:

File : mo_basis/utils.irp.f

subroutine save_mos_truncated(n)

Needs:

  • ao_md5

  • ao_num

  • mo_class

  • mo_coef

  • mo_label

  • mo_occ

Calls:

  • ezfio_set_mo_basis_ao_md5()

  • ezfio_set_mo_basis_mo_class()

  • ezfio_set_mo_basis_mo_coef()

  • ezfio_set_mo_basis_mo_label()

  • ezfio_set_mo_basis_mo_num()

  • ezfio_set_mo_basis_mo_occ()