mqc_config_adapter Module

Provides conversion utilities from mqc_config_t to driver-compatible structures Minimal config for driver Convert log level string to integer Check for overlapping fragments (for testing)

Runtime configuration for driver (internal use only)


Uses

  • module~~mqc_config_adapter~~UsesGraph module~mqc_config_adapter mqc_config_adapter module~mqc_calculation_keywords mqc_calculation_keywords module~mqc_config_adapter->module~mqc_calculation_keywords module~mqc_config_parser mqc_config_parser module~mqc_config_adapter->module~mqc_config_parser module~mqc_elements mqc_elements module~mqc_config_adapter->module~mqc_elements module~mqc_error mqc_error module~mqc_config_adapter->module~mqc_error module~mqc_method_config mqc_method_config module~mqc_config_adapter->module~mqc_method_config module~mqc_physical_fragment mqc_physical_fragment module~mqc_config_adapter->module~mqc_physical_fragment pic_logger pic_logger module~mqc_config_adapter->pic_logger pic_types pic_types module~mqc_config_adapter->pic_types module~mqc_calculation_keywords->pic_types module~mqc_calculation_defaults mqc_calculation_defaults module~mqc_calculation_keywords->module~mqc_calculation_defaults module~mqc_config_parser->module~mqc_error module~mqc_config_parser->module~mqc_physical_fragment module~mqc_config_parser->pic_types module~mqc_calc_types mqc_calc_types module~mqc_config_parser->module~mqc_calc_types module~mqc_config_parser->module~mqc_calculation_defaults module~mqc_geometry mqc_geometry module~mqc_config_parser->module~mqc_geometry module~mqc_method_types mqc_method_types module~mqc_config_parser->module~mqc_method_types module~mqc_elements->pic_types pic_ascii pic_ascii module~mqc_elements->pic_ascii module~mqc_method_config->pic_types module~mqc_method_config->module~mqc_method_types module~mqc_physical_fragment->module~mqc_elements module~mqc_physical_fragment->module~mqc_error module~mqc_physical_fragment->pic_types module~mqc_cgto mqc_cgto module~mqc_physical_fragment->module~mqc_cgto module~mqc_physical_fragment->module~mqc_geometry module~mqc_physical_constants mqc_physical_constants module~mqc_physical_fragment->module~mqc_physical_constants module~mqc_xyz_reader mqc_xyz_reader module~mqc_physical_fragment->module~mqc_xyz_reader module~mqc_calc_types->pic_types module~mqc_calculation_defaults->pic_types module~mqc_cgto->pic_types module~mqc_geometry->pic_types module~mqc_method_types->pic_types module~mqc_physical_constants->pic_types module~mqc_xyz_reader->module~mqc_error module~mqc_xyz_reader->pic_types module~mqc_xyz_reader->module~mqc_geometry

Used by

  • module~~mqc_config_adapter~~UsedByGraph module~mqc_config_adapter mqc_config_adapter module~mqc_driver mqc_driver module~mqc_driver->module~mqc_config_adapter module~mqc_many_body_expansion mqc_many_body_expansion module~mqc_driver->module~mqc_many_body_expansion module~mqc_mbe_fragment_distribution_scheme mqc_mbe_fragment_distribution_scheme module~mqc_driver->module~mqc_mbe_fragment_distribution_scheme module~mqc_many_body_expansion->module~mqc_config_adapter module~mqc_mbe_fragment_distribution_scheme->module~mqc_config_adapter proc~apply_distance_screening apply_distance_screening proc~apply_distance_screening->module~mqc_config_adapter proc~compute_energy_and_forces compute_energy_and_forces proc~compute_energy_and_forces->module~mqc_config_adapter proc~compute_energy_and_forces->module~mqc_driver proc~fragment_should_be_screened fragment_should_be_screened proc~fragment_should_be_screened->module~mqc_config_adapter proc~run_multi_molecule_calculations run_multi_molecule_calculations proc~run_multi_molecule_calculations->module~mqc_config_adapter program~main main program~main->module~mqc_config_adapter program~main->module~mqc_driver module~mpi_fragment_work_smod mpi_fragment_work_smod module~mpi_fragment_work_smod->module~mqc_mbe_fragment_distribution_scheme module~mqc_gmbe_fragment_distribution_scheme mqc_gmbe_fragment_distribution_scheme module~mqc_gmbe_fragment_distribution_scheme->module~mqc_mbe_fragment_distribution_scheme module~mqc_hessian_distribution_scheme mqc_hessian_distribution_scheme module~mqc_hessian_distribution_scheme->module~mqc_mbe_fragment_distribution_scheme module~mqc_serial_fragment_processor mqc_serial_fragment_processor module~mqc_serial_fragment_processor->module~mqc_mbe_fragment_distribution_scheme module~mqc_unfragmented_workflow mqc_unfragmented_workflow module~mqc_unfragmented_workflow->module~mqc_mbe_fragment_distribution_scheme proc~gmbe_run_distributed gmbe_context_t%gmbe_run_distributed proc~gmbe_run_distributed->module~mqc_mbe_fragment_distribution_scheme proc~gmbe_run_distributed->module~mqc_gmbe_fragment_distribution_scheme proc~mbe_run_distributed mbe_context_t%mbe_run_distributed proc~mbe_run_distributed->module~mqc_mbe_fragment_distribution_scheme proc~mbe_run_serial mbe_context_t%mbe_run_serial proc~mbe_run_serial->module~mqc_mbe_fragment_distribution_scheme proc~gmbe_run_serial gmbe_context_t%gmbe_run_serial proc~gmbe_run_serial->module~mqc_gmbe_fragment_distribution_scheme

Derived Types

type, public ::  driver_config_t

Components

Type Visibility Attributes Name Initial
type(aimd_keywords_t), public :: aimd

AIMD calculation keywords

logical, public :: allow_overlapping_fragments = .false.

Enable GMBE for overlapping fragments

integer(kind=int32), public :: calc_type

Calculation type constant

real(kind=dp), public, allocatable :: fragment_cutoffs(:)

Distance cutoffs for n-mer screening (Angstrom)

type(hessian_keywords_t), public :: hessian

Hessian calculation keywords

integer, public :: max_intersection_level = 999

Maximum k-way intersection depth for GMBE (default: no limit)

type(method_config_t), public :: method_config

Complete method configuration

integer, public :: nlevel = 0

Fragmentation level (0 = unfragmented)

type(scf_keywords_t), public :: scf

SCF calculation keywords

logical, public :: skip_json_output = .false.

Skip JSON output for large calculations


Functions

public function get_logger_level(level_string) result(level_int)

Convert string log level to integer value This function uses the pic_logger constants

Arguments

Type IntentOptional Attributes Name
character(len=*), intent(in) :: level_string

Return Value integer


Subroutines

public subroutine check_fragment_overlap(fragments, nfrag, error)

Check if any atoms appear in multiple fragments This is O(nfrag * natoms_per_frag^2) which is acceptable for typical fragment sizes

Arguments

Type IntentOptional Attributes Name
type(input_fragment_t), intent(in) :: fragments(:)
integer, intent(in) :: nfrag
type(error_t), intent(out) :: error

public subroutine config_to_driver(mqc_config, driver_config, molecule_index)

Convert mqc_config_t to minimal driver_config_t Extracts only the fields needed by the driver If molecule_index is provided, uses that molecule’s fragment count

Arguments

Type IntentOptional Attributes Name
type(mqc_config_t), intent(in) :: mqc_config
type(driver_config_t), intent(out) :: driver_config
integer, intent(in), optional :: molecule_index

Which molecule to use (for multi-molecule mode)

public subroutine config_to_system_geometry(mqc_config, sys_geom, error, molecule_index)

Convert mqc_config_t geometry to system_geometry_t For unfragmented calculations (nfrag=0), treats entire system as single unit For fragmented calculations, currently assumes monomer-based fragmentation If molecule_index is provided, uses that specific molecule from multi-molecule mode

Arguments

Type IntentOptional Attributes Name
type(mqc_config_t), intent(in) :: mqc_config
type(system_geometry_t), intent(out) :: sys_geom
type(error_t), intent(out) :: error
integer, intent(in), optional :: molecule_index

Which molecule to use (for multi-molecule mode)

private subroutine geometry_to_system_fragmented(mqc_config, sys_geom, use_angstrom, error)

Convert geometry to system_geometry_t for fragmented calculation Supports both identical and variable-sized fragments

Arguments

Type IntentOptional Attributes Name
type(mqc_config_t), intent(in) :: mqc_config
type(system_geometry_t), intent(out) :: sys_geom
logical, intent(in) :: use_angstrom
type(error_t), intent(out) :: error

private subroutine geometry_to_system_unfragmented(geom, sys_geom, use_angstrom)

Convert geometry to system_geometry_t for unfragmented calculation Treats entire system as a single monomer

Arguments

Type IntentOptional Attributes Name
type(geometry_type), intent(in) :: geom
type(system_geometry_t), intent(out) :: sys_geom
logical, intent(in) :: use_angstrom

private subroutine initialize_fragmented_system(nfrag, geom, fragments, charge, multiplicity, allow_overlapping, use_angstrom, sys_geom, error)

Shared helper to initialize system_geometry_t for fragmented calculations Handles fragment allocation, size checking, and overlap validation

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: nfrag
type(geometry_type), intent(in) :: geom
type(input_fragment_t), intent(in) :: fragments(:)
integer, intent(in) :: charge
integer, intent(in) :: multiplicity
logical, intent(in) :: allow_overlapping
logical, intent(in) :: use_angstrom
type(system_geometry_t), intent(out) :: sys_geom
type(error_t), intent(out) :: error

private subroutine molecule_to_system_geometry(mol, sys_geom, use_angstrom, allow_overlapping, error)

Convert a molecule_t to system_geometry_t Handles both unfragmented (nfrag=0) and fragmented molecules

Arguments

Type IntentOptional Attributes Name
type(molecule_t), intent(in) :: mol
type(system_geometry_t), intent(out) :: sys_geom
logical, intent(in) :: use_angstrom
logical, intent(in) :: allow_overlapping
type(error_t), intent(out) :: error