10
1
mirror of https://gitlab.com/scemama/QCaml.git synced 2024-11-09 07:33:40 +01:00
This commit is contained in:
Anthony Scemama 2020-07-10 01:10:26 +02:00
parent c4729da2a3
commit 152ffee402

View File

@ -1253,20 +1253,12 @@ let localize mo_basis =
Multipole.matrix_z multipoles
|> MOBasis.mo_matrix_of_ao_matrix ~mo_coef:mat
in
let phi_x2_phi =
Multipole.matrix_x2 multipoles
|> MOBasis.mo_matrix_of_ao_matrix ~mo_coef:mat
in
let phi_y2_phi =
Multipole.matrix_y2 multipoles
|> MOBasis.mo_matrix_of_ao_matrix ~mo_coef:mat
in
let phi_z2_phi =
Multipole.matrix_z2 multipoles
let phi_r2_phi =
Multipole.matrix_r2 multipoles
|> MOBasis.mo_matrix_of_ao_matrix ~mo_coef:mat
in
Vec.init n_mo (fun i ->
phi_x2_phi.{i,i} -. phi_x_phi.{i,i}**2. +. phi_y2_phi.{i,i} -. phi_y_phi.{i,i}**2. +. phi_z2_phi.{i,i} -. phi_z_phi.{i,i}**2.))
phi_r2_phi.{i,i} -. phi_x_phi.{i,i}**2. -. phi_y_phi.{i,i}**2. -. phi_z_phi.{i,i}**2.))
in
(* Sorting function *)