27
27
#include < MRCPP/Printer>
28
28
#include < MRCPP/Timer>
29
29
30
- #include < filesystem>
31
30
#include " driver.h"
31
+ #include < filesystem>
32
32
33
33
#include " chemistry/Molecule.h"
34
34
#include " chemistry/Nucleus.h"
51
51
#include " qmfunctions/density_utils.h"
52
52
#include " qmfunctions/orbital_utils.h"
53
53
54
+ #include " qmoperators/one_electron/AZoraPotential.h"
54
55
#include " qmoperators/one_electron/ElectricFieldOperator.h"
55
56
#include " qmoperators/one_electron/KineticOperator.h"
56
57
#include " qmoperators/one_electron/NuclearGradientOperator.h"
57
58
#include " qmoperators/one_electron/NuclearOperator.h"
58
59
#include " qmoperators/one_electron/ZoraOperator.h"
59
- #include " qmoperators/one_electron/AZoraPotential.h"
60
60
61
61
#include " qmoperators/one_electron/H_BB_dia.h"
62
62
#include " qmoperators/one_electron/H_BM_dia.h"
83
83
#include " environment/LPBESolver.h"
84
84
#include " environment/PBESolver.h"
85
85
#include " environment/Permittivity.h"
86
- #include " surface_forces/SurfaceForce.h"
87
86
#include " properties/hirshfeld/HirshfeldPartition.h"
87
+ #include " surface_forces/SurfaceForce.h"
88
88
89
89
#include " mrdft/Factory.h"
90
90
@@ -563,7 +563,7 @@ void driver::scf::calc_properties(const json &json_prop, Molecule &mol, const js
563
563
el.row (k) = h.trace (Phi).real ();
564
564
h.clear ();
565
565
}
566
- // calculate electronic gradient using the surface integrals method
566
+ // calculate electronic gradient using the surface integrals method
567
567
} else if (json_prop[" geometric_derivative" ][" geom-1" ][" method" ] == " surface_integrals" ) {
568
568
double prec = json_prop[" geometric_derivative" ][" geom-1" ][" precision" ];
569
569
std::string leb_prec = json_prop[" geometric_derivative" ][" geom-1" ][" surface_integral_precision" ];
@@ -573,9 +573,7 @@ void driver::scf::calc_properties(const json &json_prop, Molecule &mol, const js
573
573
auto &nuc = G.getNuclear ();
574
574
auto &el = G.getElectronic ();
575
575
// set electronic gradient
576
- for (int k = 0 ; k < mol.getNNuclei (); k++) {
577
- el.row (k) = surfaceForces.row (k) - nuc.row (k);
578
- }
576
+ for (int k = 0 ; k < mol.getNNuclei (); k++) { el.row (k) = surfaceForces.row (k) - nuc.row (k); }
579
577
} else {
580
578
MSG_ABORT (" Invalid method for geometric derivative" );
581
579
}
@@ -639,9 +637,9 @@ void driver::scf::calc_properties(const json &json_prop, Molecule &mol, const js
639
637
mrchem::density::compute (prec, rho, Phi, DensityType::Total);
640
638
Eigen::VectorXd charges = Eigen::VectorXd::Zero (mol.getNNuclei ());
641
639
for (int i = 0 ; i < mol.getNNuclei (); i++) {
642
- if ( ! mrcpp::mpi::my_func (i) ) continue ; // my_orb also works for atoms.
640
+ if (! mrcpp::mpi::my_func (i)) continue ; // my_orb also works for atoms.
643
641
double charge = partitioner.getHirshfeldPartitionIntegral (i, rho, prec);
644
- charge = - charge + mol.getNuclei ()[i].getCharge ();
642
+ charge = -charge + mol.getNuclei ()[i].getCharge ();
645
643
charges (i) = charge;
646
644
}
647
645
mrcpp::mpi::allreduce_vector (charges, mrcpp::mpi::comm_wrk);
@@ -1105,9 +1103,7 @@ void driver::build_fock_operator(const json &json_fock, Molecule &mol, FockBuild
1105
1103
std::string azora_dir_src = AZORA_POTENTIALS_SOURCE_DIR;
1106
1104
std::string azora_dir_install = AZORA_POTENTIALS_INSTALL_DIR;
1107
1105
std::string azora_dir = " " ;
1108
- if (json_fock[" zora_operator" ].contains (" azora_potential_path" )) {
1109
- azora_dir = json_fock[" zora_operator" ][" azora_potential_path" ];
1110
- }
1106
+ if (json_fock[" zora_operator" ].contains (" azora_potential_path" )) { azora_dir = json_fock[" zora_operator" ][" azora_potential_path" ]; }
1111
1107
1112
1108
std::string azora_dir_final;
1113
1109
if (azora_dir != " " ) {
0 commit comments