diff --git a/src/ctrl_io/mod.rs b/src/ctrl_io/mod.rs index fcd15c008f76fd15911963c02a4243217fe7bac6..67935f33cc7ea17526bf20a97e4c5d1327162dd2 100644 --- a/src/ctrl_io/mod.rs +++ b/src/ctrl_io/mod.rs @@ -11,13 +11,13 @@ use crate::analdrv::config::{AnalDrvConfig, AnalDrvTask}; use crate::ctrl_io::tddft_parameters::parse_tddft_keywords; use crate::ctrl_io::hessian_parameters::parse_hessian_keywords; use crate::ctrl_io::thermo_parameters::parse_thermo_keywords; -use crate::{check_norm::force_state_occupation::ForceStateOccupation}; +use crate::{scf_io::force_state_occupation::ForceStateOccupation}; use crate::scf_io::smear::SmearingType; use crate::dft::{DFAFamily, DFTType}; use crate::geom_io::{GeomCell, MOrC, parse_geom_keywords}; use crate::utilities; // use rayon::ThreadPoolBuilder; -use crate::check_norm::OCCType; +use crate::scf_io::occupation::OCCType; use tensors::matrix_blas_lapack::{omp_set_num_threads_wrapper}; use crate::solvent::{PcmMethod, RadiusScheme}; use crate::x2c::RelativisticMethod; diff --git a/src/initial_guess/sad.rs b/src/initial_guess/sad.rs index afe9b9ab466d4b898febc41369989c9f04c26d1f..f9a83ca8e9037fc052b7a4f6f8429b461ffbb530 100644 --- a/src/initial_guess/sad.rs +++ b/src/initial_guess/sad.rs @@ -1,5 +1,5 @@ use tensors::{MatrixFull, BasicMatrix}; -use crate::check_norm::OCCType; +use crate::scf_io::occupation::OCCType; use crate::molecule_io::Molecule; use crate::ctrl_io::InputKeywords; use crate::geom_io::{GeomCell, formated_element_name}; diff --git a/src/lib.rs b/src/lib.rs index 7c57f09dd041d58ba81172a81aba0f9d85982b8a..984ddd19385f0d2c5973a675092aa042250f5688 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -57,7 +57,6 @@ extern crate anyhow; extern crate lazy_static; pub mod basis_io; pub mod constants; -pub mod check_norm; pub mod ctrl_io; pub mod dft; pub mod geom_io; diff --git a/src/check_norm/force_state_occupation.rs b/src/scf_io/force_state_occupation.rs similarity index 100% rename from src/check_norm/force_state_occupation.rs rename to src/scf_io/force_state_occupation.rs diff --git a/src/scf_io/mod.rs b/src/scf_io/mod.rs index 7cd507a0aace3bd62cbe1b8c1881cff0baac94f8..f49a3fe40820cbd9a5c53817b445351839d8d533 100644 --- a/src/scf_io/mod.rs +++ b/src/scf_io/mod.rs @@ -1,7 +1,7 @@ #![warn(unused_imports)] use crate::basis_io::ecp::ghost_effective_potential_matrix; -use crate::check_norm::force_state_occupation::adapt_occupation_with_force_projection; -use crate::check_norm::{self, generate_occupation_frac_occ, generate_occupation_integer, generate_occupation_sad, OCCType}; +use self::force_state_occupation::adapt_occupation_with_force_projection; +use self::occupation::{generate_occupation_frac_occ, generate_occupation_integer, generate_occupation_sad, OCCType}; use crate::dft::gen_grids::prune::prune_by_rho; use crate::dft::{DFTType, Grids}; use crate::geom_io::{calc_nuc_energy, calc_nuc_energy_with_ext_field, calc_nuc_energy_with_point_charges}; @@ -19,6 +19,8 @@ mod pyrest_scf_io; pub mod scfrecord; pub mod smear; pub mod util; +pub mod occupation; +pub mod force_state_occupation; #[cfg(feature = "mpi")] use mpi::collective::SystemOperation; @@ -5269,7 +5271,7 @@ pub fn scf_without_build(scf_data: &mut SCF, mpi_operator: &Option) } match scf_data.mol.ctrl.occupation_type { OCCType::FRAC => { - let (occupation, homo, lumo) = check_norm::generate_occupation_integer(&scf_data.mol, &scf_data.scftype); + let (occupation, homo, lumo) = occupation::generate_occupation_integer(&scf_data.mol, &scf_data.scftype); scf_data.occupation = occupation; scf_data.homo = homo; scf_data.lumo = lumo; diff --git a/src/check_norm/mod.rs b/src/scf_io/occupation.rs similarity index 99% rename from src/check_norm/mod.rs rename to src/scf_io/occupation.rs index dc1370d55ecad6b3686c38f65f0f25e7cac28c2b..ae1b1a59e182eda05198705a906725d1238d9699 100644 --- a/src/check_norm/mod.rs +++ b/src/scf_io/occupation.rs @@ -11,8 +11,6 @@ pub enum OCCType { ATMSAD, } -pub mod force_state_occupation; - pub fn generate_occupation_frac_occ(mol: &Molecule, scftype: &SCFType, eigenvalues: &[Vec;2], tolerant: f64) -> ([Vec;2],[usize;2],[usize;2]) { let num_state = mol.num_state; let spin_channel = mol.ctrl.spin_channel;