From b7b4e7f64f62a24937f28e9931f3f1abca1e38ae Mon Sep 17 00:00:00 2001 From: Frederick Stein <43850145+fstein93@users.noreply.github.com> Date: Mon, 17 Jun 2024 10:31:33 +0200 Subject: [PATCH] Conventions: Fix uninitialised variables and missing default initializers (#3480) This PR: - fixes uninitialised variables - adds default initializers for most types - adds an implicit interface to one module - removes ~300 suppressions of the convention checker Default initializers are still missing due if the respective type member variables of the libraries - DBCSR - SIRIUS - PEXSI For the record: - Types derived from the abstract type eri_type_eri_element_func may be false positives as all their member variables have a default (the base type does not have any member variables) - semi_empirical_int_debug could be reimplemented using submodules (requiring adjustments on the build system) due to dependencies between this file and semi_empirical_int_utils --- src/cp_eri_mme_interface.F | 2 +- src/ewald_environment_types.F | 30 +- src/ewalds_multipole_sr.fypp | 16 +- src/exclusion_types.F | 6 +- src/exstates_types.F | 24 +- src/farming_types.F | 44 +-- src/fist_efield_types.F | 6 +- src/fist_energy_types.F | 5 +- src/fist_environment_types.F | 26 +- src/fist_force.F | 20 +- src/fist_neighbor_list_types.F | 24 +- src/fist_neighbor_lists.F | 4 +- src/force_field_types.F | 302 +++++++++--------- src/fp_types.F | 24 +- src/free_energy_types.F | 46 +-- src/gle_system_types.F | 24 +- src/graphcon.F | 24 +- src/hartree_local_types.F | 4 +- src/hirshfeld_types.F | 22 +- src/integration_grid_types.F | 20 +- src/kg_environment_types.F | 82 ++--- src/kg_vertex_coloring_methods.F | 10 +- src/kpoint_types.F | 58 ++-- src/lri_environment_types.F | 270 ++++++++-------- src/lri_optimize_ri_basis_types.F | 36 +-- src/mao_methods.F | 6 +- src/mao_types.F | 2 +- src/mdctrl_types.F | 12 +- src/metadynamics_types.F | 97 +++--- src/mixed_cdft_types.F | 146 ++++----- src/mixed_energy_types.F | 6 +- src/mm_mapping_library.F | 4 +- src/mode_selective.F | 38 +-- src/molsym.F | 37 ++- src/motion/integrator_utils.F | 36 +-- src/mscfg_types.F | 6 +- src/negf_atom_map.F | 10 +- src/negf_control_types.F | 50 +-- src/negf_env_types.F | 12 +- src/negf_green_methods.F | 16 +- src/negf_integr_cc.F | 17 +- src/negf_integr_simpson.F | 27 +- src/negf_methods.F | 6 +- src/nnp_environment_types.F | 64 ++-- src/optimize_basis_types.F | 54 ++-- src/optimize_input.F | 44 +-- src/outer_scf_control_types.F | 32 +- src/pexsi_types.F | 16 +- src/preconditioner_types.F | 26 +- src/pw/fft/fftw3_lib.F | 3 + src/pwdft_environment_types.F | 2 +- src/qmmm_gaussian_types.F | 10 +- src/qmmm_types_low.F | 204 ++++++------ src/qs_active_space_methods.F | 2 +- src/qs_atomic_block.F | 2 +- src/qs_block_davidson_types.F | 10 +- src/qs_cdft_opt_types.F | 26 +- src/qs_cdft_types.F | 128 ++++---- src/qs_charges_types.F | 12 +- src/qs_density_mixing_types.F | 68 ++-- src/qs_dftb_types.F | 66 ++-- src/qs_dispersion_pairpot.F | 8 +- src/qs_dispersion_types.F | 106 +++--- src/qs_energy_types.F | 4 +- src/qs_environment_types.F | 154 ++++----- src/qs_fb_atomic_halo_types.F | 24 +- src/qs_fb_buffer_types.F | 16 +- src/qs_fb_com_tasks_types.F | 18 +- src/qs_fb_distribution_methods.F | 10 +- src/qs_fb_env_types.F | 22 +- src/qs_fb_hash_table_types.F | 10 +- src/qs_fb_matrix_data_types.F | 10 +- src/qs_fb_trial_fns_types.F | 8 +- src/qs_force_types.F | 48 +-- src/qs_gcp_types.F | 22 +- src/qs_grid_atom.F | 28 +- src/qs_harmonics_atom.F | 22 +- src/qs_initial_guess.F | 2 +- src/qs_kernel_types.F | 16 +- src/qs_kind_types.F | 6 +- src/qs_ks_qmmm_types.F | 14 +- src/qs_linres_current.F | 4 +- src/qs_loc_types.F | 64 ++-- src/qs_local_rho_types.F | 18 +- src/qs_localization_methods.F | 5 +- src/qs_matrix_pools.F | 10 +- src/qs_mo_types.F | 2 +- src/qs_neighbor_list_types.F | 74 ++--- src/qs_neighbor_lists.F | 12 +- src/qs_nl_hash_table_types.F | 10 +- src/qs_o3c_types.F | 54 ++-- src/qs_ot_types.F | 210 ++++++------ src/qs_p_env_types.F | 8 +- src/qs_pdos.F | 24 +- src/qs_period_efield_types.F | 10 +- src/qs_resp.F | 42 +-- src/qs_rho0_types.F | 42 +-- src/qs_rho_types.F | 6 +- src/qs_scf_types.F | 76 ++--- src/qs_tddfpt2_stda_types.F | 28 +- src/qs_tddfpt2_types.F | 64 ++-- src/qs_tddfpt_types.F | 8 +- src/qs_tddfpt_utils.F | 8 +- src/qs_wannier90.F | 2 +- src/qs_wf_history_types.F | 31 +- src/rel_control_types.F | 12 +- src/replica_types.F | 32 +- src/scf_control_types.F | 77 ++--- src/semi_empirical_expns3_types.F | 8 +- src/semi_empirical_int_debug.F | 81 ++++- src/semi_empirical_mpole_types.F | 26 +- src/semi_empirical_store_int_types.F | 12 +- src/semi_empirical_types.F | 129 ++++---- src/simpar_types.F | 108 +++---- src/splines_types.F | 34 +- src/subcell_types.F | 8 +- src/submatrix_dissection.F | 9 +- src/submatrix_types.F | 6 +- src/taper_types.F | 4 +- src/tip_scan_types.F | 10 +- src/topology_types.F | 239 +++++++------- src/transport_env_types.F | 130 ++++---- src/xtb_matrices.F | 6 +- src/xtb_types.F | 52 +-- tools/conventions/conventions.supp | 295 ----------------- .../toolchain/scripts/generate_arch_files.sh | 2 +- 126 files changed, 2426 insertions(+), 2640 deletions(-) diff --git a/src/cp_eri_mme_interface.F b/src/cp_eri_mme_interface.F index 147be760f3..75d3eef956 100644 --- a/src/cp_eri_mme_interface.F +++ b/src/cp_eri_mme_interface.F @@ -80,7 +80,7 @@ MODULE cp_eri_mme_interface TYPE(cp_logger_type), POINTER :: logger => NULL() ! There is a bug with some older compilers preventing a default initialization of derived types with allocatable components #if __GNUC__ < 9 || (__GNUC__ == 9 && __GNUC_MINOR__ < 5) - TYPE(eri_mme_param) :: par + TYPE(eri_mme_param) :: par = eri_mme_param(minimax_grid=NULL()) #else TYPE(eri_mme_param) :: par = eri_mme_param() #endif diff --git a/src/ewald_environment_types.F b/src/ewald_environment_types.F index ddc9887d8f..92b88eac30 100644 --- a/src/ewald_environment_types.F +++ b/src/ewald_environment_types.F @@ -54,24 +54,24 @@ MODULE ewald_environment_types ! ************************************************************************************************** TYPE ewald_environment_type PRIVATE - LOGICAL :: do_multipoles ! Flag for using the multipole code - INTEGER :: do_ipol ! Solver for induced dipoles - INTEGER :: max_multipole ! max expansion in the multipoles - INTEGER :: max_ipol_iter ! max number of interaction for induced dipoles - INTEGER :: ewald_type ! type of ewald - INTEGER :: gmax(3) ! max Miller index - INTEGER :: ns_max ! # grid points for small grid (PME) - INTEGER :: o_spline ! order of spline (SPME) - REAL(KIND=dp) :: precs ! precision achieved when evaluating the real-space part - REAL(KIND=dp) :: alpha, rcut ! ewald alpha and real-space cutoff - REAL(KIND=dp) :: epsilon ! tolerance for small grid (PME) - REAL(KIND=dp) :: eps_pol ! tolerance for convergence of induced dipoles - TYPE(mp_para_env_type), POINTER :: para_env - TYPE(section_vals_type), POINTER :: poisson_section + LOGICAL :: do_multipoles = .FALSE. ! Flag for using the multipole code + INTEGER :: do_ipol = -1 ! Solver for induced dipoles + INTEGER :: max_multipole = -1 ! max expansion in the multipoles + INTEGER :: max_ipol_iter = -1 ! max number of interaction for induced dipoles + INTEGER :: ewald_type = -1 ! type of ewald + INTEGER :: gmax(3) = -1 ! max Miller index + INTEGER :: ns_max = -1 ! # grid points for small grid (PME) + INTEGER :: o_spline = -1 ! order of spline (SPME) + REAL(KIND=dp) :: precs = 0.0_dp ! precision achieved when evaluating the real-space part + REAL(KIND=dp) :: alpha = 0.0_dp, rcut = 0.0_dp ! ewald alpha and real-space cutoff + REAL(KIND=dp) :: epsilon = 0.0_dp ! tolerance for small grid (PME) + REAL(KIND=dp) :: eps_pol = 0.0_dp ! tolerance for convergence of induced dipoles + TYPE(mp_para_env_type), POINTER :: para_env => NULL() + TYPE(section_vals_type), POINTER :: poisson_section => NULL() ! interaction cutoff is required to make the electrostatic interaction ! continuous at a pair distance equal to rcut. this is ignored by the ! multipole code and is otherwise only active when SHIFT_CUTOFF is used. - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: interaction_cutoffs + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: interaction_cutoffs => NULL() ! store current cell, used to rebuild lazily. REAL(KIND=dp), DIMENSION(3, 3) :: cell_hmat = -1.0_dp END TYPE ewald_environment_type diff --git a/src/ewalds_multipole_sr.fypp b/src/ewalds_multipole_sr.fypp index a544ea1c28..6d2af2df9a 100644 --- a/src/ewalds_multipole_sr.fypp +++ b/src/ewalds_multipole_sr.fypp @@ -8,15 +8,13 @@ #:def ewalds_multipole_sr_macro(mode, damping=False, store_energy=False, store_forces=False) ! Compute the Short Range constribution according the task - IF (debug_this_module) THEN - f = HUGE(0.0_dp) - tij = HUGE(0.0_dp) - tij_a = HUGE(0.0_dp) - tij_ab = HUGE(0.0_dp) - tij_abc = HUGE(0.0_dp) - tij_abcd = HUGE(0.0_dp) - tij_abcde = HUGE(0.0_dp) - END IF + f = HUGE(0.0_dp) + tij = HUGE(0.0_dp) + tij_a = HUGE(0.0_dp) + tij_ab = HUGE(0.0_dp) + tij_abc = HUGE(0.0_dp) + tij_abcd = HUGE(0.0_dp) + tij_abcde = HUGE(0.0_dp) r = SQRT(rab2) irab2 = 1.0_dp/rab2 ir = 1.0_dp/r diff --git a/src/exclusion_types.F b/src/exclusion_types.F index 5446f4ba07..ef6cf19c28 100644 --- a/src/exclusion_types.F +++ b/src/exclusion_types.F @@ -19,9 +19,9 @@ MODULE exclusion_types !> 12.2010 created [Joost VandeVondele] ! ************************************************************************************************** TYPE exclusion_type - INTEGER, POINTER, DIMENSION(:) :: list_exclude_vdw - INTEGER, POINTER, DIMENSION(:) :: list_exclude_ei - INTEGER, POINTER, DIMENSION(:) :: list_onfo + INTEGER, POINTER, DIMENSION(:) :: list_exclude_vdw => NULL() + INTEGER, POINTER, DIMENSION(:) :: list_exclude_ei => NULL() + INTEGER, POINTER, DIMENSION(:) :: list_onfo => NULL() END TYPE PUBLIC :: exclusion_type, & diff --git a/src/exstates_types.F b/src/exstates_types.F index ceb0bbe075..1a5a570d1e 100644 --- a/src/exstates_types.F +++ b/src/exstates_types.F @@ -38,11 +38,11 @@ MODULE exstates_types ! ***************************************************************************** TYPE wfn_history_type - INTEGER :: state - REAL(KIND=dp) :: evalue + INTEGER :: state = -1 + REAL(KIND=dp) :: evalue = 0.0_dp TYPE(cp_fm_type), POINTER, DIMENSION(:) :: evect => NULL() TYPE(cp_fm_type), POINTER, DIMENSION(:) :: cpmos => NULL() - REAL(KIND=dp) :: xsval, gsval, gsmin + REAL(KIND=dp) :: xsval = 0.0_dp, gsval = 0.0_dp, gsmin = 0.0_dp END TYPE wfn_history_type ! ***************************************************************************** @@ -52,11 +52,11 @@ MODULE exstates_types !> \author JGH ! ***************************************************************************** TYPE excited_energy_type - INTEGER :: state - REAL(KIND=dp) :: evalue - INTEGER :: xc_kernel_method + INTEGER :: state = -1 + REAL(KIND=dp) :: evalue = 0.0_dp + INTEGER :: xc_kernel_method = -1 REAL(KIND=dp) :: eps_delta_rho = 1.E-02_dp - INTEGER :: diff_order + INTEGER :: diff_order = -1 LOGICAL :: debug_forces = .FALSE. TYPE(cp_fm_type), POINTER, DIMENSION(:) :: evect => NULL() TYPE(cp_fm_type), POINTER, DIMENSION(:) :: cpmos => NULL() @@ -68,13 +68,13 @@ MODULE exstates_types TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: matrix_px1_asymm => NULL() TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: matrix_px1_admm_asymm => NULL() TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: matrix_wx1 => NULL() - TYPE(pw_r3d_rs_type) :: vh_rspace - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: vxc_rspace => NULL() - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: vtau_rspace => NULL() - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: vadmm_rspace => NULL() + TYPE(pw_r3d_rs_type) :: vh_rspace = pw_r3d_rs_type() + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: vxc_rspace => NULL() + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: vtau_rspace => NULL() + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: vadmm_rspace => NULL() TYPE(local_rho_type), POINTER :: local_rho_set => NULL() TYPE(local_rho_type), POINTER :: local_rho_set_admm => NULL() - TYPE(wfn_history_type) :: wfn_history + TYPE(wfn_history_type) :: wfn_history = wfn_history_type() END TYPE excited_energy_type CONTAINS diff --git a/src/farming_types.F b/src/farming_types.F index 1b6ac06dc0..4c97ba2872 100644 --- a/src/farming_types.F +++ b/src/farming_types.F @@ -21,33 +21,33 @@ MODULE farming_types ! ************************************************************************************************** TYPE job_type - CHARACTER(LEN=default_path_length) :: cwd ! the directory to go to - CHARACTER(LEN=default_path_length) :: input ! the input file to use - CHARACTER(LEN=default_path_length) :: output ! the output file to use - INTEGER :: ID ! the ID of this job - INTEGER, POINTER, DIMENSION(:) :: dependencies ! the dependencies of this job - INTEGER :: status ! pending,running,finished + CHARACTER(LEN=default_path_length) :: cwd = "" ! the directory to go to + CHARACTER(LEN=default_path_length) :: input = "" ! the input file to use + CHARACTER(LEN=default_path_length) :: output = "" ! the output file to use + INTEGER :: ID = -1 ! the ID of this job + INTEGER, POINTER, DIMENSION(:) :: dependencies => NULL() ! the dependencies of this job + INTEGER :: status = -1 ! pending,running,finished END TYPE job_type ! ************************************************************************************************** TYPE farming_env_type - INTEGER :: group_size_wish - LOGICAL :: group_size_wish_set - INTEGER :: ngroup_wish - LOGICAL :: ngroup_wish_set - LOGICAL :: restart - LOGICAL :: CYCLE - LOGICAL :: captain_minion - INTEGER, DIMENSION(:), POINTER :: group_partition ! user preference for partitioning the cpus - CHARACTER(LEN=default_path_length) :: restart_file_name ! restart file for farming - CHARACTER(LEN=default_path_length) :: cwd ! directory we started from - INTEGER :: Njobs ! how many jobs to run - INTEGER :: restart_n ! where to start - INTEGER :: max_steps ! max number of steps, + INTEGER :: group_size_wish = -1 + LOGICAL :: group_size_wish_set = .FALSE. + INTEGER :: ngroup_wish = -1 + LOGICAL :: ngroup_wish_set = .FALSE. + LOGICAL :: restart = .FALSE. + LOGICAL :: CYCLE = .FALSE. + LOGICAL :: captain_minion = .FALSE. + INTEGER, DIMENSION(:), POINTER :: group_partition => NULL() ! user preference for partitioning the cpus + CHARACTER(LEN=default_path_length) :: restart_file_name = "" ! restart file for farming + CHARACTER(LEN=default_path_length) :: cwd = "" ! directory we started from + INTEGER :: Njobs = -1 ! how many jobs to run + INTEGER :: restart_n = -1 ! where to start + INTEGER :: max_steps = -1 ! max number of steps, ! results in max_steps*Ngroup jobs being run - INTEGER :: stride ! for creating minion groups. - TYPE(job_type), DIMENSION(:), POINTER :: job ! a list of jobs - REAL(KIND=dp) :: wait_time + INTEGER :: stride = -1 ! for creating minion groups. + TYPE(job_type), DIMENSION(:), POINTER :: job => NULL() ! a list of jobs + REAL(KIND=dp) :: wait_time = 0.0_dp END TYPE farming_env_type CONTAINS diff --git a/src/fist_efield_types.F b/src/fist_efield_types.F index c3986228a1..5f05e9d682 100644 --- a/src/fist_efield_types.F +++ b/src/fist_efield_types.F @@ -25,9 +25,9 @@ MODULE fist_efield_types TYPE fist_efield_type LOGICAL :: apply_field = .FALSE. LOGICAL :: displacement = .FALSE. - REAL(KIND=dp) :: strength - REAL(KIND=dp), DIMENSION(3) :: polarisation - REAL(KIND=dp), DIMENSION(3) :: dfilter + REAL(KIND=dp) :: strength = 0.0_dp + REAL(KIND=dp), DIMENSION(3) :: polarisation = 0.0_dp + REAL(KIND=dp), DIMENSION(3) :: dfilter = 0.0_dp END TYPE fist_efield_type ! ************************************************************************************************** diff --git a/src/fist_energy_types.F b/src/fist_energy_types.F index 58d06b4d55..d34172a44c 100644 --- a/src/fist_energy_types.F +++ b/src/fist_energy_types.F @@ -22,8 +22,9 @@ MODULE fist_energy_types ! ************************************************************************************************** TYPE fist_energy_type - REAL(kind=dp) :: kin, pot, e_gspace, e_self, e_neut, e_bonded, e_induction - REAL(kind=dp) :: kin_shell, harm_shell + REAL(kind=dp) :: kin = 0.0_dp, pot = 0.0_dp, e_gspace = 0.0_dp, e_self = 0.0_dp, & + e_neut = 0.0_dp, e_bonded = 0.0_dp, e_induction = 0.0_dp + REAL(kind=dp) :: kin_shell = 0.0_dp, harm_shell = 0.0_dp END TYPE fist_energy_type ! *** Public data types *** diff --git a/src/fist_environment_types.F b/src/fist_environment_types.F index 64204ced3b..1bf2775bf6 100644 --- a/src/fist_environment_types.F +++ b/src/fist_environment_types.F @@ -70,19 +70,19 @@ MODULE fist_environment_types ! ************************************************************************************************** TYPE fist_environment_type PRIVATE - LOGICAL :: qmmm - LOGICAL :: shell_model, shell_model_ad - TYPE(qmmm_env_mm_type), POINTER :: qmmm_env - TYPE(cell_type), POINTER :: cell_ref - TYPE(ewald_environment_type), POINTER :: ewald_env - TYPE(ewald_pw_type), POINTER :: ewald_pw - TYPE(fist_energy_type), POINTER :: thermo - TYPE(mp_para_env_type), POINTER :: para_env - TYPE(cp_subsys_type), POINTER :: subsys - TYPE(fist_nonbond_env_type), POINTER :: fist_nonbond_env - TYPE(section_vals_type), POINTER :: input - TYPE(exclusion_type), DIMENSION(:), POINTER :: exclusions - TYPE(fist_efield_type), POINTER :: efield + LOGICAL :: qmmm = .FALSE. + LOGICAL :: shell_model = .FALSE., shell_model_ad = .FALSE. + TYPE(qmmm_env_mm_type), POINTER :: qmmm_env => NULL() + TYPE(cell_type), POINTER :: cell_ref => NULL() + TYPE(ewald_environment_type), POINTER :: ewald_env => NULL() + TYPE(ewald_pw_type), POINTER :: ewald_pw => NULL() + TYPE(fist_energy_type), POINTER :: thermo => NULL() + TYPE(mp_para_env_type), POINTER :: para_env => NULL() + TYPE(cp_subsys_type), POINTER :: subsys => NULL() + TYPE(fist_nonbond_env_type), POINTER :: fist_nonbond_env => NULL() + TYPE(section_vals_type), POINTER :: input => NULL() + TYPE(exclusion_type), DIMENSION(:), POINTER :: exclusions => NULL() + TYPE(fist_efield_type), POINTER :: efield => NULL() END TYPE fist_environment_type ! *** Public data types *** diff --git a/src/fist_force.F b/src/fist_force.F index fa3def826c..2b07c24a28 100644 --- a/src/fist_force.F +++ b/src/fist_force.F @@ -79,16 +79,16 @@ MODULE fist_force CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'fist_force' TYPE debug_variables_type - REAL(KIND=dp) :: pot_manybody, pot_bend, pot_torsion - REAL(KIND=dp) :: pot_nonbond, pot_g, pot_bond - REAL(KIND=dp) :: pot_imptors, pot_urey_bradley - REAL(KIND=dp) :: pot_opbend - REAL(KIND=dp), DIMENSION(:, :), POINTER :: f_nonbond, f_g, f_bond, f_bend, & - f_torsion, f_imptors, f_ub, & - f_opbend - REAL(KIND=dp), DIMENSION(3, 3) :: pv_nonbond, pv_g, pv_bond, pv_ub, & - pv_bend, pv_torsion, pv_imptors, & - pv_opbend + REAL(KIND=dp) :: pot_manybody = 0.0_dp, pot_bend = 0.0_dp, pot_torsion = 0.0_dp + REAL(KIND=dp) :: pot_nonbond = 0.0_dp, pot_g = 0.0_dp, pot_bond = 0.0_dp + REAL(KIND=dp) :: pot_imptors = 0.0_dp, pot_urey_bradley = 0.0_dp + REAL(KIND=dp) :: pot_opbend = 0.0_dp + REAL(KIND=dp), DIMENSION(:, :), POINTER :: f_nonbond => NULL(), f_g => NULL(), f_bond => NULL(), f_bend => NULL(), & + f_torsion => NULL(), f_imptors => NULL(), f_ub => NULL(), & + f_opbend => NULL() + REAL(KIND=dp), DIMENSION(3, 3) :: pv_nonbond = 0.0_dp, pv_g = 0.0_dp, pv_bond = 0.0_dp, pv_ub = 0.0_dp, & + pv_bend = 0.0_dp, pv_torsion = 0.0_dp, pv_imptors = 0.0_dp, & + pv_opbend = 0.0_dp END TYPE debug_variables_type CONTAINS diff --git a/src/fist_neighbor_list_types.F b/src/fist_neighbor_list_types.F index ffabcfc3e6..ca69869dfb 100644 --- a/src/fist_neighbor_list_types.F +++ b/src/fist_neighbor_list_types.F @@ -24,12 +24,12 @@ MODULE fist_neighbor_list_types ! ************************************************************************************************** TYPE neighbor_kind_pairs_type - INTEGER, POINTER, DIMENSION(:, :) :: list, ij_kind - INTEGER, POINTER, DIMENSION(:) :: id_kind - INTEGER, POINTER, DIMENSION(:) :: grp_kind_start, grp_kind_end - INTEGER :: cell_vector(3), npairs - INTEGER :: ngrp_kind - REAL(KIND=dp) :: rmax + INTEGER, POINTER, DIMENSION(:, :) :: list => NULL(), ij_kind => NULL() + INTEGER, POINTER, DIMENSION(:) :: id_kind => NULL() + INTEGER, POINTER, DIMENSION(:) :: grp_kind_start => NULL(), grp_kind_end => NULL() + INTEGER :: cell_vector(3) = -1, npairs = -1 + INTEGER :: ngrp_kind = -1 + REAL(KIND=dp) :: rmax = 0.0_dp ! The *_scale arrays are scaling factors for the corresponding nonbonding ! interaction energies and forces for the pairs in 'list'. To keep the size ! of these arrays small, pairs whose interaction must be scaled are moved @@ -38,16 +38,16 @@ MODULE fist_neighbor_list_types ! reallocate the *_scale arrays for every new scaled pair interaction. ! The field is_info is only used to switch between the regular nonbonded ! and the nonbonded14 splines for the van der waals interactions. - REAL(KIND=dp), POINTER, DIMENSION(:) :: ei_scale - REAL(KIND=dp), POINTER, DIMENSION(:) :: vdw_scale - LOGICAL, POINTER, DIMENSION(:) :: is_onfo - INTEGER :: nscale + REAL(KIND=dp), POINTER, DIMENSION(:) :: ei_scale => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:) :: vdw_scale => NULL() + LOGICAL, POINTER, DIMENSION(:) :: is_onfo => NULL() + INTEGER :: nscale = -1 END TYPE neighbor_kind_pairs_type ! ************************************************************************************************** TYPE fist_neighbor_type - TYPE(neighbor_kind_pairs_type), DIMENSION(:), POINTER :: neighbor_kind_pairs - INTEGER :: nlists + TYPE(neighbor_kind_pairs_type), DIMENSION(:), POINTER :: neighbor_kind_pairs => NULL() + INTEGER :: nlists = -1 END TYPE fist_neighbor_type PUBLIC :: neighbor_kind_pairs_type, & diff --git a/src/fist_neighbor_lists.F b/src/fist_neighbor_lists.F index f6315a37d4..f3c23ea1be 100644 --- a/src/fist_neighbor_lists.F +++ b/src/fist_neighbor_lists.F @@ -66,8 +66,8 @@ MODULE fist_neighbor_lists CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'fist_neighbor_lists' TYPE local_atoms_type - INTEGER, DIMENSION(:), POINTER :: list, & - list_local_a_index + INTEGER, DIMENSION(:), POINTER :: list => NULL(), & + list_local_a_index => NULL() END TYPE local_atoms_type ! Public subroutines diff --git a/src/force_field_types.F b/src/force_field_types.F index 938bd7500d..12e3732d47 100644 --- a/src/force_field_types.F +++ b/src/force_field_types.F @@ -36,173 +36,173 @@ MODULE force_field_types ! ************************************************************************************************** TYPE input_info_type - CHARACTER(LEN=default_string_length), POINTER :: charge_atm(:) - REAL(KIND=dp), POINTER :: charge(:) - CHARACTER(LEN=default_string_length), POINTER :: apol_atm(:) - REAL(KIND=dp), POINTER :: apol(:) - CHARACTER(LEN=default_string_length), POINTER :: cpol_atm(:) - REAL(KIND=dp), POINTER :: cpol(:) - INTEGER, POINTER :: bond_kind(:) - CHARACTER(LEN=default_string_length), POINTER :: bond_a(:) - CHARACTER(LEN=default_string_length), POINTER :: bond_b(:) - REAL(KIND=dp), POINTER :: bond_k(:, :) - REAL(KIND=dp), POINTER :: bond_r0(:) - REAL(KIND=dp), POINTER :: bond_cs(:) - INTEGER, POINTER :: bend_kind(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_a(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_b(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_c(:) - REAL(KIND=dp), POINTER :: bend_k(:) - REAL(KIND=dp), POINTER :: bend_theta0(:) - REAL(KIND=dp), POINTER :: bend_cb(:) - REAL(KIND=dp), POINTER, DIMENSION(:) :: bend_r012, & - bend_r032, & - bend_kbs12, & - bend_kbs32, & - bend_kss - TYPE(legendre_data_type), POINTER, DIMENSION(:):: bend_legendre - INTEGER, POINTER :: ub_kind(:) - CHARACTER(LEN=default_string_length), POINTER :: ub_a(:) - CHARACTER(LEN=default_string_length), POINTER :: ub_b(:) - CHARACTER(LEN=default_string_length), POINTER :: ub_c(:) - REAL(KIND=dp), POINTER :: ub_k(:, :) - REAL(KIND=dp), POINTER :: ub_r0(:) - INTEGER, POINTER :: torsion_kind(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_a(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_b(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_c(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_d(:) - REAL(KIND=dp), POINTER :: torsion_k(:) - INTEGER, POINTER :: torsion_m(:) - REAL(KIND=dp), POINTER :: torsion_phi0(:) - INTEGER, POINTER :: impr_kind(:) - CHARACTER(LEN=default_string_length), POINTER :: impr_a(:) - CHARACTER(LEN=default_string_length), POINTER :: impr_b(:) - CHARACTER(LEN=default_string_length), POINTER :: impr_c(:) - CHARACTER(LEN=default_string_length), POINTER :: impr_d(:) - REAL(KIND=dp), POINTER :: impr_k(:) - REAL(KIND=dp), POINTER :: impr_phi0(:) - INTEGER, POINTER :: opbend_kind(:) - CHARACTER(LEN=default_string_length), POINTER :: opbend_a(:) - CHARACTER(LEN=default_string_length), POINTER :: opbend_b(:) - CHARACTER(LEN=default_string_length), POINTER :: opbend_c(:) - CHARACTER(LEN=default_string_length), POINTER :: opbend_d(:) - REAL(KIND=dp), POINTER :: opbend_k(:) - REAL(KIND=dp), POINTER :: opbend_phi0(:) - TYPE(pair_potential_p_type), POINTER :: nonbonded - TYPE(pair_potential_p_type), POINTER :: nonbonded14 - TYPE(shell_p_type), DIMENSION(:), POINTER :: shell_list - TYPE(damping_info_type), DIMENSION(:), POINTER :: damping_list + CHARACTER(LEN=default_string_length), POINTER :: charge_atm(:) => NULL() + REAL(KIND=dp), POINTER :: charge(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: apol_atm(:) => NULL() + REAL(KIND=dp), POINTER :: apol(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: cpol_atm(:) => NULL() + REAL(KIND=dp), POINTER :: cpol(:) => NULL() + INTEGER, POINTER :: bond_kind(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bond_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bond_b(:) => NULL() + REAL(KIND=dp), POINTER :: bond_k(:, :) => NULL() + REAL(KIND=dp), POINTER :: bond_r0(:) => NULL() + REAL(KIND=dp), POINTER :: bond_cs(:) => NULL() + INTEGER, POINTER :: bend_kind(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_c(:) => NULL() + REAL(KIND=dp), POINTER :: bend_k(:) => NULL() + REAL(KIND=dp), POINTER :: bend_theta0(:) => NULL() + REAL(KIND=dp), POINTER :: bend_cb(:) => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:) :: bend_r012 => NULL(), & + bend_r032 => NULL(), & + bend_kbs12 => NULL(), & + bend_kbs32 => NULL(), & + bend_kss => NULL() + TYPE(legendre_data_type), POINTER, DIMENSION(:):: bend_legendre => NULL() + INTEGER, POINTER :: ub_kind(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: ub_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: ub_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: ub_c(:) => NULL() + REAL(KIND=dp), POINTER :: ub_k(:, :) => NULL() + REAL(KIND=dp), POINTER :: ub_r0(:) => NULL() + INTEGER, POINTER :: torsion_kind(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_c(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_d(:) => NULL() + REAL(KIND=dp), POINTER :: torsion_k(:) => NULL() + INTEGER, POINTER :: torsion_m(:) => NULL() + REAL(KIND=dp), POINTER :: torsion_phi0(:) => NULL() + INTEGER, POINTER :: impr_kind(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: impr_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: impr_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: impr_c(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: impr_d(:) => NULL() + REAL(KIND=dp), POINTER :: impr_k(:) => NULL() + REAL(KIND=dp), POINTER :: impr_phi0(:) => NULL() + INTEGER, POINTER :: opbend_kind(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: opbend_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: opbend_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: opbend_c(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: opbend_d(:) => NULL() + REAL(KIND=dp), POINTER :: opbend_k(:) => NULL() + REAL(KIND=dp), POINTER :: opbend_phi0(:) => NULL() + TYPE(pair_potential_p_type), POINTER :: nonbonded => NULL() + TYPE(pair_potential_p_type), POINTER :: nonbonded14 => NULL() + TYPE(shell_p_type), DIMENSION(:), POINTER :: shell_list => NULL() + TYPE(damping_info_type), DIMENSION(:), POINTER :: damping_list => NULL() END TYPE input_info_type ! ************************************************************************************************** TYPE charmm_info_type - CHARACTER(LEN=default_string_length), POINTER :: bond_a(:) - CHARACTER(LEN=default_string_length), POINTER :: bond_b(:) - REAL(KIND=dp), POINTER :: bond_k(:) - REAL(KIND=dp), POINTER :: bond_r0(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_a(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_b(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_c(:) - REAL(KIND=dp), POINTER :: bend_k(:) - REAL(KIND=dp), POINTER :: bend_theta0(:) - CHARACTER(LEN=default_string_length), POINTER :: ub_a(:) - CHARACTER(LEN=default_string_length), POINTER :: ub_b(:) - CHARACTER(LEN=default_string_length), POINTER :: ub_c(:) - REAL(KIND=dp), POINTER :: ub_k(:) - REAL(KIND=dp), POINTER :: ub_r0(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_a(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_b(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_c(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_d(:) - REAL(KIND=dp), POINTER :: torsion_k(:) - INTEGER, POINTER :: torsion_m(:) - REAL(KIND=dp), POINTER :: torsion_phi0(:) - CHARACTER(LEN=default_string_length), POINTER :: impr_a(:) - CHARACTER(LEN=default_string_length), POINTER :: impr_b(:) - CHARACTER(LEN=default_string_length), POINTER :: impr_c(:) - CHARACTER(LEN=default_string_length), POINTER :: impr_d(:) - REAL(KIND=dp), POINTER :: impr_k(:) - REAL(KIND=dp), POINTER :: impr_phi0(:) - CHARACTER(LEN=default_string_length), POINTER :: nonbond_a(:) - REAL(KIND=dp), POINTER :: nonbond_eps(:) - REAL(KIND=dp), POINTER :: nonbond_rmin2(:) - CHARACTER(LEN=default_string_length), POINTER :: nonbond_a_14(:) - REAL(KIND=dp), POINTER :: nonbond_eps_14(:) - REAL(KIND=dp), POINTER :: nonbond_rmin2_14(:) + CHARACTER(LEN=default_string_length), POINTER :: bond_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bond_b(:) => NULL() + REAL(KIND=dp), POINTER :: bond_k(:) => NULL() + REAL(KIND=dp), POINTER :: bond_r0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_c(:) => NULL() + REAL(KIND=dp), POINTER :: bend_k(:) => NULL() + REAL(KIND=dp), POINTER :: bend_theta0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: ub_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: ub_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: ub_c(:) => NULL() + REAL(KIND=dp), POINTER :: ub_k(:) => NULL() + REAL(KIND=dp), POINTER :: ub_r0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_c(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_d(:) => NULL() + REAL(KIND=dp), POINTER :: torsion_k(:) => NULL() + INTEGER, POINTER :: torsion_m(:) => NULL() + REAL(KIND=dp), POINTER :: torsion_phi0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: impr_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: impr_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: impr_c(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: impr_d(:) => NULL() + REAL(KIND=dp), POINTER :: impr_k(:) => NULL() + REAL(KIND=dp), POINTER :: impr_phi0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: nonbond_a(:) => NULL() + REAL(KIND=dp), POINTER :: nonbond_eps(:) => NULL() + REAL(KIND=dp), POINTER :: nonbond_rmin2(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: nonbond_a_14(:) => NULL() + REAL(KIND=dp), POINTER :: nonbond_eps_14(:) => NULL() + REAL(KIND=dp), POINTER :: nonbond_rmin2_14(:) => NULL() END TYPE charmm_info_type ! ************************************************************************************************** TYPE amber_info_type - CHARACTER(LEN=default_string_length), POINTER :: bond_a(:) - CHARACTER(LEN=default_string_length), POINTER :: bond_b(:) - REAL(KIND=dp), POINTER :: bond_k(:) - REAL(KIND=dp), POINTER :: bond_r0(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_a(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_b(:) - CHARACTER(LEN=default_string_length), POINTER :: bend_c(:) - REAL(KIND=dp), POINTER :: bend_k(:) - REAL(KIND=dp), POINTER :: bend_theta0(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_a(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_b(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_c(:) - CHARACTER(LEN=default_string_length), POINTER :: torsion_d(:) - REAL(KIND=dp), POINTER :: torsion_k(:) - INTEGER, POINTER :: torsion_m(:) - REAL(KIND=dp), POINTER :: torsion_phi0(:) - CHARACTER(LEN=default_string_length), POINTER :: nonbond_a(:) - REAL(KIND=dp), POINTER :: nonbond_eps(:) - REAL(KIND=dp), POINTER :: nonbond_rmin2(:) - INTEGER, POINTER :: raw_torsion_id(:, :) - REAL(KIND=dp), POINTER :: raw_torsion_k(:) - REAL(KIND=dp), POINTER :: raw_torsion_m(:) - REAL(KIND=dp), POINTER :: raw_torsion_phi0(:) + CHARACTER(LEN=default_string_length), POINTER :: bond_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bond_b(:) => NULL() + REAL(KIND=dp), POINTER :: bond_k(:) => NULL() + REAL(KIND=dp), POINTER :: bond_r0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: bend_c(:) => NULL() + REAL(KIND=dp), POINTER :: bend_k(:) => NULL() + REAL(KIND=dp), POINTER :: bend_theta0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_a(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_b(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_c(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: torsion_d(:) => NULL() + REAL(KIND=dp), POINTER :: torsion_k(:) => NULL() + INTEGER, POINTER :: torsion_m(:) => NULL() + REAL(KIND=dp), POINTER :: torsion_phi0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: nonbond_a(:) => NULL() + REAL(KIND=dp), POINTER :: nonbond_eps(:) => NULL() + REAL(KIND=dp), POINTER :: nonbond_rmin2(:) => NULL() + INTEGER, POINTER :: raw_torsion_id(:, :) => NULL() + REAL(KIND=dp), POINTER :: raw_torsion_k(:) => NULL() + REAL(KIND=dp), POINTER :: raw_torsion_m(:) => NULL() + REAL(KIND=dp), POINTER :: raw_torsion_phi0(:) => NULL() END TYPE amber_info_type ! ************************************************************************************************** TYPE gromos_info_type - INTEGER :: ff_gromos_type - REAL(KIND=dp), POINTER :: solvent_k(:) - REAL(KIND=dp), POINTER :: solvent_r0(:) - REAL(KIND=dp), POINTER :: bond_k(:) - REAL(KIND=dp), POINTER :: bond_r0(:) - REAL(KIND=dp), POINTER :: bend_k(:) - REAL(KIND=dp), POINTER :: bend_theta0(:) - REAL(KIND=dp), POINTER :: torsion_k(:) - INTEGER, POINTER :: torsion_m(:) - REAL(KIND=dp), POINTER :: torsion_phi0(:) - REAL(KIND=dp), POINTER :: impr_k(:) - REAL(KIND=dp), POINTER :: impr_phi0(:) - CHARACTER(LEN=default_string_length), POINTER :: nonbond_a(:) - REAL(KIND=dp), POINTER :: nonbond_c6(:, :) - REAL(KIND=dp), POINTER :: nonbond_c12(:, :) - CHARACTER(LEN=default_string_length), POINTER :: nonbond_a_14(:) - REAL(KIND=dp), POINTER :: nonbond_c6_14(:, :) - REAL(KIND=dp), POINTER :: nonbond_c12_14(:, :) + INTEGER :: ff_gromos_type = -1 + REAL(KIND=dp), POINTER :: solvent_k(:) => NULL() + REAL(KIND=dp), POINTER :: solvent_r0(:) => NULL() + REAL(KIND=dp), POINTER :: bond_k(:) => NULL() + REAL(KIND=dp), POINTER :: bond_r0(:) => NULL() + REAL(KIND=dp), POINTER :: bend_k(:) => NULL() + REAL(KIND=dp), POINTER :: bend_theta0(:) => NULL() + REAL(KIND=dp), POINTER :: torsion_k(:) => NULL() + INTEGER, POINTER :: torsion_m(:) => NULL() + REAL(KIND=dp), POINTER :: torsion_phi0(:) => NULL() + REAL(KIND=dp), POINTER :: impr_k(:) => NULL() + REAL(KIND=dp), POINTER :: impr_phi0(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: nonbond_a(:) => NULL() + REAL(KIND=dp), POINTER :: nonbond_c6(:, :) => NULL() + REAL(KIND=dp), POINTER :: nonbond_c12(:, :) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: nonbond_a_14(:) => NULL() + REAL(KIND=dp), POINTER :: nonbond_c6_14(:, :) => NULL() + REAL(KIND=dp), POINTER :: nonbond_c12_14(:, :) => NULL() END TYPE gromos_info_type ! ************************************************************************************************** TYPE force_field_type - LOGICAL :: shift_cutoff, & - do_nonbonded, & - do_electrostatics, & - electrostatics, & - multiple_potential, & - ignore_missing_critical - INTEGER :: ff_type - REAL(KIND=dp) :: rcut_nb - REAL(KIND=dp) :: ei_scale14 - REAL(KIND=dp) :: vdw_scale14 - REAL(KIND=dp) :: eps_spline, & - max_energy, & - emax_spline, & - rlow_nb - INTEGER :: npoints - CHARACTER(LEN=default_path_length) :: ff_file_name - TYPE(input_info_type), POINTER :: inp_info - TYPE(charmm_info_type), POINTER :: chm_info - TYPE(gromos_info_type), POINTER :: gro_info - TYPE(amber_info_type), POINTER :: amb_info + LOGICAL :: shift_cutoff = .FALSE., & + do_nonbonded = .FALSE., & + do_electrostatics = .FALSE., & + electrostatics = .FALSE., & + multiple_potential = .FALSE., & + ignore_missing_critical = .FALSE. + INTEGER :: ff_type = -1 + REAL(KIND=dp) :: rcut_nb = 0.0_dp + REAL(KIND=dp) :: ei_scale14 = 0.0_dp + REAL(KIND=dp) :: vdw_scale14 = 0.0_dp + REAL(KIND=dp) :: eps_spline = 0.0_dp, & + max_energy = 0.0_dp, & + emax_spline = 0.0_dp, & + rlow_nb = 0.0_dp + INTEGER :: npoints = -1 + CHARACTER(LEN=default_path_length) :: ff_file_name = "" + TYPE(input_info_type), POINTER :: inp_info => NULL() + TYPE(charmm_info_type), POINTER :: chm_info => NULL() + TYPE(gromos_info_type), POINTER :: gro_info => NULL() + TYPE(amber_info_type), POINTER :: amb_info => NULL() END TYPE force_field_type ! *** Public subroutines *** diff --git a/src/fp_types.F b/src/fp_types.F index dc3bf75a0e..1bc40edf47 100644 --- a/src/fp_types.F +++ b/src/fp_types.F @@ -37,21 +37,21 @@ MODULE fp_types TYPE fp_type ! input related objects - LOGICAL :: use_fp + LOGICAL :: use_fp = .FALSE. - INTEGER :: central_atom - INTEGER, DIMENSION(:), POINTER :: inner_atoms, outer_atoms - REAL(KIND=dp) :: inner_radius, outer_radius - REAL(KIND=dp) :: strength, smooth_width - LOGICAL :: bias - REAL(KIND=dp) :: temperature - TYPE(section_vals_type), POINTER :: print_section + INTEGER :: central_atom = -1 + INTEGER, DIMENSION(:), POINTER :: inner_atoms => NULL(), outer_atoms => NULL() + REAL(KIND=dp) :: inner_radius = 0.0_dp, outer_radius = 0.0_dp + REAL(KIND=dp) :: strength = 0.0_dp, smooth_width = 0.0_dp + LOGICAL :: bias = .FALSE. + REAL(KIND=dp) :: temperature = 0.0_dp + TYPE(section_vals_type), POINTER :: print_section => NULL() ! computed during runs - INTEGER :: i1, i2, o1, o2 - REAL(KIND=dp) :: ri1, ri2, ro1, ro2 - REAL(KIND=dp) :: weight, comb_weight, bias_weight - REAL(KIND=dp) :: energy, bias_energy, restraint_energy + INTEGER :: i1 = -1, i2 = -1, o1 = -1, o2 = -1 + REAL(KIND=dp) :: ri1 = 0.0_dp, ri2 = 0.0_dp, ro1 = 0.0_dp, ro2 = 0.0_dp + REAL(KIND=dp) :: weight = 0.0_dp, comb_weight = 0.0_dp, bias_weight = 0.0_dp + REAL(KIND=dp) :: energy = 0.0_dp, bias_energy = 0.0_dp, restraint_energy = 0.0_dp END TYPE fp_type CONTAINS diff --git a/src/free_energy_types.F b/src/free_energy_types.F index 99579d0c78..a153426248 100644 --- a/src/free_energy_types.F +++ b/src/free_energy_types.F @@ -35,45 +35,45 @@ MODULE free_energy_types ! ************************************************************************************************** TYPE ui_var_type - REAL(KIND=dp), DIMENSION(:), POINTER :: ss - INTEGER :: icolvar + REAL(KIND=dp), DIMENSION(:), POINTER :: ss => NULL() + INTEGER :: icolvar = -1 END TYPE ui_var_type ! ************************************************************************************************** TYPE ui_conv_type ! Specifying convergence parameters - INTEGER :: cg_width, max_cg_width - INTEGER :: cg_points - REAL(KIND=dp) :: eps_conv - REAL(KIND=dp) :: k_conf_lm - REAL(KIND=dp) :: sw_conf_lm - REAL(KIND=dp) :: vn_conf_lm - LOGICAL :: test_k, & - test_sw, & - test_vn + INTEGER :: cg_width = -1, max_cg_width = -1 + INTEGER :: cg_points = -1 + REAL(KIND=dp) :: eps_conv = 0.0_dp + REAL(KIND=dp) :: k_conf_lm = 0.0_dp + REAL(KIND=dp) :: sw_conf_lm = 0.0_dp + REAL(KIND=dp) :: vn_conf_lm = 0.0_dp + LOGICAL :: test_k = .FALSE., & + test_sw = .FALSE., & + test_vn = .FALSE. END TYPE ui_conv_type ! ************************************************************************************************** TYPE statistical_type ! Collecting coarse grained data - REAL(KIND=dp), DIMENSION(:), POINTER :: avg - REAL(KIND=dp), DIMENSION(:, :), POINTER :: var + REAL(KIND=dp), DIMENSION(:), POINTER :: avg => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: var => NULL() END TYPE statistical_type ! ************************************************************************************************** TYPE free_energy_type - INTEGER :: ncolvar - INTEGER :: TYPE - INTEGER :: nr_points, & - nr_rejected - TYPE(ui_conv_type), POINTER :: conv_par - TYPE(ui_var_type), POINTER, DIMENSION(:) :: uivar - TYPE(statistical_type), DIMENSION(:), POINTER :: cg_data + INTEGER :: ncolvar = -1 + INTEGER :: TYPE = -1 + INTEGER :: nr_points = -1, & + nr_rejected = -1 + TYPE(ui_conv_type), POINTER :: conv_par => NULL() + TYPE(ui_var_type), POINTER, DIMENSION(:) :: uivar => NULL() + TYPE(statistical_type), DIMENSION(:), POINTER :: cg_data => NULL() ! Old data - REAL(KIND=dp) :: eps_conv - REAL(KIND=dp), DIMENSION(:, :), POINTER :: covmx + REAL(KIND=dp) :: eps_conv = 0.0_dp + REAL(KIND=dp), DIMENSION(:, :), POINTER :: covmx => NULL() - CHARACTER(len=default_string_length) :: plumed_input_file + CHARACTER(len=default_string_length) :: plumed_input_file = "" END TYPE free_energy_type CONTAINS diff --git a/src/gle_system_types.F b/src/gle_system_types.F index 524a4b8f36..3c04b1579f 100644 --- a/src/gle_system_types.F +++ b/src/gle_system_types.F @@ -35,22 +35,22 @@ MODULE gle_system_types ! TYPE gle_thermo_type - INTEGER :: degrees_of_freedom - REAL(KIND=dp) :: nkt, kin_energy, thermostat_energy - REAL(KIND=dp), DIMENSION(:), POINTER :: s - TYPE(rng_stream_type) :: gaussian_rng_stream + INTEGER :: degrees_of_freedom = -1 + REAL(KIND=dp) :: nkt = 0.0_dp, kin_energy = 0.0_dp, thermostat_energy = 0.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: s => NULL() + TYPE(rng_stream_type) :: gaussian_rng_stream = rng_stream_type() END TYPE gle_thermo_type ! ************************************************************************************************** TYPE gle_type - INTEGER :: ndim - INTEGER :: glob_num_gle, loc_num_gle, region - INTEGER, DIMENSION(:), POINTER :: mal - REAL(dp) :: temp, dt, dt_fact - REAL(dp), POINTER :: gle_s(:, :), gle_t(:, :) - REAL(dp), POINTER :: a_mat(:, :), c_mat(:, :) - TYPE(gle_thermo_type), POINTER :: nvt(:) - TYPE(map_info_type), POINTER :: map_info + INTEGER :: ndim = -1 + INTEGER :: glob_num_gle = -1, loc_num_gle = -1, region = -1 + INTEGER, DIMENSION(:), POINTER :: mal => NULL() + REAL(dp) :: temp = 0.0_dp, dt = 0.0_dp, dt_fact = 0.0_dp + REAL(dp), POINTER :: gle_s(:, :) => NULL(), gle_t(:, :) => NULL() + REAL(dp), POINTER :: a_mat(:, :) => NULL(), c_mat(:, :) => NULL() + TYPE(gle_thermo_type), POINTER :: nvt(:) => NULL() + TYPE(map_info_type), POINTER :: map_info => NULL() END TYPE gle_type CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'gle_system_types' diff --git a/src/graphcon.F b/src/graphcon.F index 47ea31a901..2689a6acd2 100644 --- a/src/graphcon.F +++ b/src/graphcon.F @@ -35,30 +35,30 @@ MODULE graphcon ! (the number is the index of the other vertex in the array that builds the molecule) ! ************************************************************************************************** TYPE graph_type - TYPE(vertex), POINTER, DIMENSION(:) :: graph + TYPE(vertex), POINTER, DIMENSION(:) :: graph => NULL() END TYPE graph_type ! ************************************************************************************************** TYPE vertex - INTEGER :: kind - INTEGER, POINTER, DIMENSION(:) :: bonds + INTEGER :: kind = -1 + INTEGER, POINTER, DIMENSION(:) :: bonds => NULL() END TYPE vertex ! ************************************************************************************************** TYPE class - INTEGER, DIMENSION(:), POINTER :: reference - INTEGER, DIMENSION(:), POINTER :: unordered - INTEGER :: kind - INTEGER :: Nele - LOGICAL :: first - INTEGER, DIMENSION(:), POINTER :: order - INTEGER, DIMENSION(:), POINTER :: q + INTEGER, DIMENSION(:), POINTER :: reference => NULL() + INTEGER, DIMENSION(:), POINTER :: unordered => NULL() + INTEGER :: kind = -1 + INTEGER :: Nele = -1 + LOGICAL :: first = .FALSE. + INTEGER, DIMENSION(:), POINTER :: order => NULL() + INTEGER, DIMENSION(:), POINTER :: q => NULL() END TYPE class ! ************************************************************************************************** TYPE superclass - INTEGER :: Nele - INTEGER, DIMENSION(:), POINTER :: classes + INTEGER :: Nele = -1 + INTEGER, DIMENSION(:), POINTER :: classes => NULL() END TYPE CONTAINS diff --git a/src/hartree_local_types.F b/src/hartree_local_types.F index b9d605af8d..bb2ea580df 100644 --- a/src/hartree_local_types.F +++ b/src/hartree_local_types.F @@ -23,7 +23,7 @@ MODULE hartree_local_types ! ************************************************************************************************** TYPE ecoul_1center_type - TYPE(rho_atom_coeff), POINTER :: Vh1_h, Vh1_s + TYPE(rho_atom_coeff), POINTER :: Vh1_h => NULL(), Vh1_s => NULL() REAL(dp) :: ecoul_1_h = 0.0_dp, & ecoul_1_s = 0.0_dp, & ecoul_1_z = 0.0_dp, & @@ -33,7 +33,7 @@ MODULE hartree_local_types ! ************************************************************************************************** TYPE hartree_local_type TYPE(ecoul_1center_type), & - DIMENSION(:), POINTER :: ecoul_1c + DIMENSION(:), POINTER :: ecoul_1c => NULL() END TYPE hartree_local_type ! *** Public subroutines *** diff --git a/src/hirshfeld_types.F b/src/hirshfeld_types.F index ba244ee6be..954a7ba8e7 100644 --- a/src/hirshfeld_types.F +++ b/src/hirshfeld_types.F @@ -34,24 +34,24 @@ MODULE hirshfeld_types !> \author JGH ! ************************************************************************************************** TYPE hirshfeld_type - LOGICAL :: iterative, & - use_bohr - INTEGER :: shape_function_type - INTEGER :: ref_charge, & - radius_type + LOGICAL :: iterative = .FALSE., & + use_bohr = .FALSE. + INTEGER :: shape_function_type = -1 + INTEGER :: ref_charge = -1, & + radius_type = -1 TYPE(shape_fn), DIMENSION(:), & - POINTER :: kind_shape_fn + POINTER :: kind_shape_fn => NULL() REAL(KIND=dp), DIMENSION(:), & - POINTER :: charges - TYPE(pw_r3d_rs_type), POINTER :: fnorm + POINTER :: charges => NULL() + TYPE(pw_r3d_rs_type), POINTER :: fnorm => NULL() END TYPE hirshfeld_type TYPE shape_fn - INTEGER :: numexp + INTEGER :: numexp = -1 REAL(KIND=dp), DIMENSION(:), & - POINTER :: zet + POINTER :: zet => NULL() REAL(KIND=dp), DIMENSION(:), & - POINTER :: coef + POINTER :: coef => NULL() END TYPE shape_fn ! ************************************************************************************************** diff --git a/src/integration_grid_types.F b/src/integration_grid_types.F index b846569191..23053f27dd 100644 --- a/src/integration_grid_types.F +++ b/src/integration_grid_types.F @@ -17,12 +17,12 @@ MODULE integration_grid_types CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'integration_grid_types' TYPE grid_batch_val_1d_type - INTEGER :: np1 + INTEGER :: np1 = -1 REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: val1d END TYPE grid_batch_val_1d_type TYPE grid_batch_val_2d_type - INTEGER :: np1, np2 + INTEGER :: np1 = -1, np2 = -1 REAL(KIND=dp), DIMENSION(:, :), ALLOCATABLE :: val2d END TYPE grid_batch_val_2d_type @@ -32,12 +32,12 @@ MODULE integration_grid_types END TYPE gnlist_type TYPE grid_batch_info_type - INTEGER :: np - INTEGER :: ref_atom - INTEGER :: ibatch - TYPE(gnlist_type) :: gnlist - REAL(KIND=dp), DIMENSION(3) :: rcenter - REAL(KIND=dp) :: radius + INTEGER :: np = -1 + INTEGER :: ref_atom = -1 + INTEGER :: ibatch = -1 + TYPE(gnlist_type) :: gnlist = gnlist_type() + REAL(KIND=dp), DIMENSION(3) :: rcenter = 0.0_dp + REAL(KIND=dp) :: radius = 0.0_dp REAL(dp), DIMENSION(:, :), ALLOCATABLE :: rco REAL(dp), DIMENSION(:), ALLOCATABLE :: weight REAL(dp), DIMENSION(:), ALLOCATABLE :: wref @@ -45,12 +45,12 @@ MODULE integration_grid_types END TYPE grid_batch_info_type TYPE integration_grid_type - INTEGER :: nbatch + INTEGER :: nbatch = -1 TYPE(grid_batch_info_type), DIMENSION(:), ALLOCATABLE :: grid_batch END TYPE integration_grid_type TYPE integration_grid_value_type - INTEGER :: nbatch + INTEGER :: nbatch = -1 TYPE(grid_batch_val_1d_type), DIMENSION(:), ALLOCATABLE :: grid_val_1d TYPE(grid_batch_val_2d_type), DIMENSION(:), ALLOCATABLE :: grid_val_2d END TYPE integration_grid_value_type diff --git a/src/kg_environment_types.F b/src/kg_environment_types.F index 45b5fc9b4b..4abea4d27d 100644 --- a/src/kg_environment_types.F +++ b/src/kg_environment_types.F @@ -42,8 +42,8 @@ MODULE kg_environment_types PUBLIC :: kg_environment_type, kg_env_release, energy_correction_type TYPE subset_type - TYPE(neighbor_list_set_p_type), DIMENSION(:), POINTER :: sab_orb - TYPE(task_list_type), POINTER :: task_list + TYPE(neighbor_list_set_p_type), DIMENSION(:), POINTER :: sab_orb => NULL() + TYPE(task_list_type), POINTER :: task_list => NULL() END TYPE subset_type ! ***************************************************************************** @@ -53,36 +53,36 @@ MODULE kg_environment_types !> \author JGH ! ***************************************************************************** TYPE energy_correction_type - CHARACTER(len=20) :: ec_name - INTEGER :: energy_functional - INTEGER :: ks_solver - INTEGER :: factorization - REAL(KIND=dp) :: eps_default + CHARACTER(len=20) :: ec_name = "" + INTEGER :: energy_functional = -1 + INTEGER :: ks_solver = -1 + INTEGER :: factorization = -1 + REAL(KIND=dp) :: eps_default = 0.0_dp ! basis set - CHARACTER(len=20) :: basis - LOGICAL :: mao - INTEGER :: mao_max_iter - REAL(KIND=dp) :: mao_eps_grad + CHARACTER(len=20) :: basis = "" + LOGICAL :: mao = .FALSE. + INTEGER :: mao_max_iter = -1 + REAL(KIND=dp) :: mao_eps_grad = 0.0_dp ! energy components - REAL(KIND=dp) :: etotal - REAL(KIND=dp) :: eband, exc, ehartree, vhxc - REAL(KIND=dp) :: edispersion + REAL(KIND=dp) :: etotal = 0.0_dp + REAL(KIND=dp) :: eband = 0.0_dp, exc = 0.0_dp, ehartree = 0.0_dp, vhxc = 0.0_dp + REAL(KIND=dp) :: edispersion = 0.0_dp ! full neighbor lists and corresponding task list TYPE(neighbor_list_set_p_type), & - DIMENSION(:), POINTER :: sab_orb, sac_ppl, sap_ppnl - TYPE(task_list_type), POINTER :: task_list + DIMENSION(:), POINTER :: sab_orb => NULL(), sac_ppl => NULL(), sap_ppnl => NULL() + TYPE(task_list_type), POINTER :: task_list => NULL() ! the XC function to be used for the correction, dispersion info - TYPE(section_vals_type), POINTER :: xc_section - TYPE(qs_dispersion_type), POINTER :: dispersion_env + TYPE(section_vals_type), POINTER :: xc_section => NULL() + TYPE(qs_dispersion_type), POINTER :: dispersion_env => NULL() ! matrices in complete basis ! KS: Kohn-Sham; H: Core; S: overlap; T: kinetic energy; - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_ks - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_h - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_s - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_t - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_p + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_ks => NULL() + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_h => NULL() + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_s => NULL() + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_t => NULL() + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: matrix_p => NULL() ! reduce basis - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: mao_coef + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: mao_coef => NULL() END TYPE energy_correction_type ! ************************************************************************************************** @@ -100,29 +100,29 @@ MODULE kg_environment_types !> \author Martin Haeufel ! ************************************************************************************************** TYPE kg_environment_type - INTEGER :: nspins - INTEGER :: natom - TYPE(section_vals_type), POINTER :: xc_section_kg + INTEGER :: nspins = -1 + INTEGER :: natom = -1 + TYPE(section_vals_type), POINTER :: xc_section_kg => NULL() INTEGER, ALLOCATABLE, DIMENSION(:) :: atom_to_molecule - TYPE(molecule_type), DIMENSION(:), POINTER :: molecule_set - INTEGER :: tnadd_method + TYPE(molecule_type), DIMENSION(:), POINTER :: molecule_set => NULL() + INTEGER :: tnadd_method = -1 TYPE(neighbor_list_set_p_type), & - DIMENSION(:), POINTER :: sab_orb_full, sac_kin + DIMENSION(:), POINTER :: sab_orb_full => NULL(), sac_kin => NULL() ! - INTEGER, DIMENSION(:), POINTER :: subset_of_mol - TYPE(subset_type), DIMENSION(:), POINTER :: subset - INTEGER :: nsubsets - INTEGER :: maxdegree - INTEGER :: coloring_method + INTEGER, DIMENSION(:), POINTER :: subset_of_mol => NULL() + TYPE(subset_type), DIMENSION(:), POINTER :: subset => NULL() + INTEGER :: nsubsets = -1 + INTEGER :: maxdegree = -1 + INTEGER :: coloring_method = -1 ! - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: tnadd_mat + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: tnadd_mat => NULL() ! LRI - TYPE(lri_environment_type), POINTER :: lri_env, lri_env1 - TYPE(lri_density_type), POINTER :: lri_density, lri_rho1 + TYPE(lri_environment_type), POINTER :: lri_env => NULL(), lri_env1 => NULL() + TYPE(lri_density_type), POINTER :: lri_density => NULL(), lri_rho1 => NULL() ! atomic grid - TYPE(atom_integration_grid_type), POINTER :: int_grid_atom - TYPE(integration_grid_type), POINTER :: int_grid_molecules - TYPE(integration_grid_type), POINTER :: int_grid_full + TYPE(atom_integration_grid_type), POINTER :: int_grid_atom => NULL() + TYPE(integration_grid_type), POINTER :: int_grid_molecules => NULL() + TYPE(integration_grid_type), POINTER :: int_grid_full => NULL() END TYPE kg_environment_type CONTAINS diff --git a/src/kg_vertex_coloring_methods.F b/src/kg_vertex_coloring_methods.F index ed8e72900e..1adde8c5a1 100644 --- a/src/kg_vertex_coloring_methods.F +++ b/src/kg_vertex_coloring_methods.F @@ -42,16 +42,16 @@ MODULE kg_vertex_coloring_methods PRIVATE TYPE vertex - INTEGER :: id - INTEGER :: color - INTEGER :: degree ! degree (number of neighbors) - INTEGER :: dsat ! degree of saturation + INTEGER :: id = -1 + INTEGER :: color = -1 + INTEGER :: degree = -1 ! degree (number of neighbors) + INTEGER :: dsat = -1 ! degree of saturation LOGICAL, ALLOCATABLE, DIMENSION(:) :: color_present ! the colors present on neighbors TYPE(vertex_p_type), DIMENSION(:), POINTER :: neighbors => NULL() END TYPE vertex TYPE vertex_p_type - TYPE(vertex), POINTER :: vertex + TYPE(vertex), POINTER :: vertex => NULL() END TYPE vertex_p_type CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'kg_vertex_coloring_methods' diff --git a/src/kpoint_types.F b/src/kpoint_types.F index fd68fbd135..87e17d6de2 100644 --- a/src/kpoint_types.F +++ b/src/kpoint_types.F @@ -70,19 +70,19 @@ MODULE kpoint_types !> \author JGH ! ************************************************************************************************** TYPE kpoint_env_type - INTEGER :: nkpoint - REAL(KIND=dp) :: wkp - REAL(KIND=dp), DIMENSION(3) :: xkp - LOGICAL :: is_local - TYPE(mo_set_type), DIMENSION(:, :), POINTER :: mos - TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: pmat - TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: wmat - TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: smat - TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: amat + INTEGER :: nkpoint = -1 + REAL(KIND=dp) :: wkp = 0.0_dp + REAL(KIND=dp), DIMENSION(3) :: xkp = 0.0_dp + LOGICAL :: is_local = .FALSE. + TYPE(mo_set_type), DIMENSION(:, :), POINTER :: mos => NULL() + TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: pmat => NULL() + TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: wmat => NULL() + TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: smat => NULL() + TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: amat => NULL() END TYPE kpoint_env_type TYPE kpoint_env_p_type - TYPE(kpoint_env_type), POINTER :: kpoint_env + TYPE(kpoint_env_type), POINTER :: kpoint_env => NULL() END TYPE kpoint_env_p_type ! ************************************************************************************************** @@ -95,15 +95,15 @@ MODULE kpoint_types !> \author JGH ! ************************************************************************************************** TYPE kpoint_sym_type - LOGICAL :: apply_symmetry - INTEGER :: nwght - REAL(KIND=dp), DIMENSION(:, :), POINTER :: xkp - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: rot - INTEGER, DIMENSION(:, :), POINTER :: f0 + LOGICAL :: apply_symmetry = .FALSE. + INTEGER :: nwght = -1 + REAL(KIND=dp), DIMENSION(:, :), POINTER :: xkp => NULL() + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: rot => NULL() + INTEGER, DIMENSION(:, :), POINTER :: f0 => NULL() END TYPE kpoint_sym_type TYPE kpoint_sym_p_type - TYPE(kpoint_sym_type), POINTER :: kpoint_sym + TYPE(kpoint_sym_type), POINTER :: kpoint_sym => NULL() END TYPE kpoint_sym_p_type ! ************************************************************************************************** @@ -136,16 +136,16 @@ MODULE kpoint_types !> \author JGH ! ************************************************************************************************** TYPE kpoint_type - CHARACTER(LEN=default_string_length) :: kp_scheme - INTEGER, DIMENSION(3) :: nkp_grid - REAL(KIND=dp), DIMENSION(3) :: kp_shift - LOGICAL :: use_real_wfn - LOGICAL :: symmetry - LOGICAL :: full_grid - LOGICAL :: verbose - REAL(KIND=dp) :: eps_geo - INTEGER :: parallel_group_size - INTEGER :: nkp + CHARACTER(LEN=default_string_length) :: kp_scheme = "" + INTEGER, DIMENSION(3) :: nkp_grid = -1 + REAL(KIND=dp), DIMENSION(3) :: kp_shift = 0.0_dp + LOGICAL :: use_real_wfn = .FALSE. + LOGICAL :: symmetry = .FALSE. + LOGICAL :: full_grid = .FALSE. + LOGICAL :: verbose = .FALSE. + REAL(KIND=dp) :: eps_geo = 0.0_dp + INTEGER :: parallel_group_size = -1 + INTEGER :: nkp = -1 REAL(KIND=dp), DIMENSION(:, :), POINTER :: xkp => Null() REAL(KIND=dp), DIMENSION(:), POINTER :: wkp => Null() ! parallel environment @@ -153,10 +153,10 @@ MODULE kpoint_types TYPE(cp_blacs_env_type), POINTER :: blacs_env_all => Null() TYPE(mp_para_env_type), POINTER :: para_env_kp => Null(), & para_env_inter_kp => Null() - LOGICAL :: iogrp - INTEGER :: nkp_groups + LOGICAL :: iogrp = .FALSE. + INTEGER :: nkp_groups = -1 INTEGER, DIMENSION(:, :), POINTER :: kp_dist => Null() - INTEGER, DIMENSION(2) :: kp_range + INTEGER, DIMENSION(2) :: kp_range = -1 TYPE(cp_blacs_env_type), POINTER :: blacs_env => Null() INTEGER, DIMENSION(:, :, :), POINTER :: cell_to_index => Null() INTEGER, DIMENSION(:, :), POINTER :: index_to_cell => Null() diff --git a/src/lri_environment_types.F b/src/lri_environment_types.F index 462244f363..7f89d41590 100644 --- a/src/lri_environment_types.F +++ b/src/lri_environment_types.F @@ -45,62 +45,63 @@ MODULE lri_environment_types ! ************************************************************************************************** ! Integral container TYPE carray - INTEGER :: compression - REAL(KIND=dp), DIMENSION(:), POINTER :: cdp - REAL(KIND=sp), DIMENSION(:), POINTER :: csp - INTEGER(INT_8), DIMENSION(:), POINTER :: cip + INTEGER :: compression = -1 + REAL(KIND=dp), DIMENSION(:), POINTER :: cdp => NULL() + REAL(KIND=sp), DIMENSION(:), POINTER :: csp => NULL() + INTEGER(INT_8), DIMENSION(:), POINTER :: cip => NULL() END TYPE carray + TYPE int_container - INTEGER :: na, nb, nc - TYPE(carray), DIMENSION(:), POINTER :: ca + INTEGER :: na = -1, nb = -1, nc = -1 + TYPE(carray), DIMENSION(:), POINTER :: ca => NULL() END TYPE int_container ! ************************************************************************************************** TYPE lri_rhoab_type ! number of spherical basis functions (a) - INTEGER :: nba + INTEGER :: nba = -1 ! number of spherical basis functions (b) - INTEGER :: nbb + INTEGER :: nbb = -1 ! number of spherical fit basis functions (ai) - INTEGER :: nfa + INTEGER :: nfa = -1 ! number of spherical fit basis functions (bi) - INTEGER :: nfb + INTEGER :: nfb = -1 ! expansion coeffs for RI density - REAL(KIND=dp), DIMENSION(:), POINTER :: avec - REAL(KIND=dp), DIMENSION(:), POINTER :: aveca - REAL(KIND=dp), DIMENSION(:), POINTER :: avecb + REAL(KIND=dp), DIMENSION(:), POINTER :: avec => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: aveca => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: avecb => NULL() ! projection coeffs for RI density: SUM_ab (ab,i)*Pab - REAL(KIND=dp), DIMENSION(:), POINTER :: tvec - REAL(KIND=dp), DIMENSION(:), POINTER :: tveca - REAL(KIND=dp), DIMENSION(:), POINTER :: tvecb + REAL(KIND=dp), DIMENSION(:), POINTER :: tvec => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: tveca => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: tvecb => NULL() ! integral (ai) * sinv * tvec - REAL(KIND=dp) :: nst - REAL(KIND=dp) :: nsta - REAL(KIND=dp) :: nstb + REAL(KIND=dp) :: nst = 0.0_dp + REAL(KIND=dp) :: nsta = 0.0_dp + REAL(KIND=dp) :: nstb = 0.0_dp ! Lagrange parameter - REAL(KIND=dp) :: lambda - REAL(KIND=dp) :: lambdaa - REAL(KIND=dp) :: lambdab + REAL(KIND=dp) :: lambda = 0.0_dp + REAL(KIND=dp) :: lambdaa = 0.0_dp + REAL(KIND=dp) :: lambdab = 0.0_dp ! Charge of pair density - REAL(KIND=dp) :: charge - REAL(KIND=dp) :: chargea - REAL(KIND=dp) :: chargeb + REAL(KIND=dp) :: charge = 0.0_dp + REAL(KIND=dp) :: chargea = 0.0_dp + REAL(KIND=dp) :: chargeb = 0.0_dp END TYPE lri_rhoab_type ! ************************************************************************************************** TYPE lri_int_type ! whether to calculate force for pair - LOGICAL :: calc_force_pair + LOGICAL :: calc_force_pair = .FALSE. ! number of spherical basis functions (a) - INTEGER :: nba + INTEGER :: nba = -1 ! number of spherical basis functions (b) - INTEGER :: nbb + INTEGER :: nbb = -1 ! number of spherical fit basis functions (ai) - INTEGER :: nfa + INTEGER :: nfa = -1 ! number of spherical fit basis functions (bi) - INTEGER :: nfb + INTEGER :: nfb = -1 ! condition number of overlap matrix - REAL(KIND=dp) :: cond_num + REAL(KIND=dp) :: cond_num = 0.0_dp ! integrals (a,b,ai) REAL(KIND=dp), DIMENSION(:, :, :), ALLOCATABLE :: abaint REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: abascr @@ -108,9 +109,9 @@ MODULE lri_environment_types REAL(KIND=dp), DIMENSION(:, :, :), ALLOCATABLE :: abbint REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: abbscr ! compressed aba integrals - TYPE(int_container) :: cabai + TYPE(int_container) :: cabai = int_container() ! compressed abb integrals - TYPE(int_container) :: cabbi + TYPE(int_container) :: cabbi = int_container() ! integrals (da/dA,b,dai/dA) REAL(KIND=dp), DIMENSION(:, :, :, :), ALLOCATABLE :: dabdaint ! integrals (da/dA,b,bi) @@ -124,38 +125,38 @@ MODULE lri_environment_types ! derivative d(ai,bi)/dA REAL(KIND=dp), DIMENSION(:, :, :), ALLOCATABLE :: dsab ! inverse of integrals (ai,bi) - REAL(KIND=dp), DIMENSION(:, :), POINTER :: sinv + REAL(KIND=dp), DIMENSION(:, :), POINTER :: sinv => NULL() ! integral (ai) / (bi), dim(1..nfa,nfa+1..nfa+nfb) - REAL(KIND=dp), DIMENSION(:), POINTER :: n + REAL(KIND=dp), DIMENSION(:), POINTER :: n => NULL() ! sinv * (ai) - REAL(KIND=dp), DIMENSION(:), POINTER :: sn + REAL(KIND=dp), DIMENSION(:), POINTER :: sn => NULL() ! (ai) * sinv * (ai) - REAL(KIND=dp) :: nsn + REAL(KIND=dp) :: nsn = 0.0_dp ! distant pair approximation - LOGICAL :: lrisr - LOGICAL :: lriff - REAL(KIND=dp) :: wsr, wff, dwsr, dwff - REAL(KIND=dp), DIMENSION(:, :), POINTER :: asinv, bsinv - REAL(KIND=dp), DIMENSION(:), POINTER :: na, nb - REAL(KIND=dp), DIMENSION(:), POINTER :: sna, snb - REAL(KIND=dp) :: nsna, nsnb + LOGICAL :: lrisr = .FALSE. + LOGICAL :: lriff = .FALSE. + REAL(KIND=dp) :: wsr = 0.0_dp, wff = 0.0_dp, dwsr = 0.0_dp, dwff = 0.0_dp + REAL(KIND=dp), DIMENSION(:, :), POINTER :: asinv => NULL(), bsinv => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: na => NULL(), nb => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: sna => NULL(), snb => NULL() + REAL(KIND=dp) :: nsna = 0.0_dp, nsnb = 0.0_dp ! ! dmax: max deviation for integrals of primitive gtos; for debugging ! dmax for overlap integrals (ai,bi); fit bas - REAL(KIND=dp) :: dmax_ab + REAL(KIND=dp) :: dmax_ab = 0.0_dp ! dmax for overlap integrals (a,b); orb bas - REAL(KIND=dp) :: dmax_oo + REAL(KIND=dp) :: dmax_oo = 0.0_dp ! dmax for integrals (a,b,ai) - REAL(KIND=dp) :: dmax_aba + REAL(KIND=dp) :: dmax_aba = 0.0_dp ! dmax for integrals (a,b,bi) - REAL(KIND=dp) :: dmax_abb + REAL(KIND=dp) :: dmax_abb = 0.0_dp END TYPE lri_int_type TYPE lri_int_rho_type ! integrals (aa,bb), orb basis - REAL(KIND=dp), DIMENSION(:, :, :, :), POINTER :: soaabb + REAL(KIND=dp), DIMENSION(:, :, :, :), POINTER :: soaabb => NULL() ! dmax for (aa,bb) integrals; for debugging - REAL(KIND=dp) :: dmax_aabb + REAL(KIND=dp) :: dmax_aabb = 0.0_dp END TYPE lri_int_rho_type TYPE lri_node_type @@ -182,174 +183,175 @@ MODULE lri_environment_types ! ************************************************************************************************** TYPE lri_bas_type - INTEGER, DIMENSION(:, :, :), POINTER :: orb_index - INTEGER, DIMENSION(:, :, :), POINTER :: ri_index + INTEGER, DIMENSION(:, :, :), POINTER :: orb_index => NULL() + INTEGER, DIMENSION(:, :, :), POINTER :: ri_index => NULL() ! integral of ri basis fbas - REAL(KIND=dp), DIMENSION(:), POINTER :: int_fbas + REAL(KIND=dp), DIMENSION(:), POINTER :: int_fbas => NULL() ! self overlap ri basis - REAL(KIND=dp), DIMENSION(:, :), POINTER :: ri_ovlp + REAL(KIND=dp), DIMENSION(:, :), POINTER :: ri_ovlp => NULL() ! inverse of self overlap ri basis - REAL(KIND=dp), DIMENSION(:, :), POINTER :: ri_ovlp_inv + REAL(KIND=dp), DIMENSION(:, :), POINTER :: ri_ovlp_inv => NULL() ! self overlap orb basis - REAL(KIND=dp), DIMENSION(:, :), POINTER :: orb_ovlp + REAL(KIND=dp), DIMENSION(:, :), POINTER :: orb_ovlp => NULL() ! self overlap (a,a,fa) REAL(KIND=dp), DIMENSION(:, :, :), ALLOCATABLE :: ovlp3 ! contraction matrix for SHG integrals ri basis - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: scon_ri + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: scon_ri => NULL() ! contraction matrix for SHG integrals orb basis - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: scon_orb + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: scon_orb => NULL() ! contraction matrix for SHG integrals aba/abb - REAL(KIND=dp), DIMENSION(:, :, :, :), POINTER :: scon_mix + REAL(KIND=dp), DIMENSION(:, :, :, :), POINTER :: scon_mix => NULL() END TYPE lri_bas_type ! ************************************************************************************************** TYPE lri_clebsch_gordon_type ! Clebsch-Gordon (CG) coefficients - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: cg_coeff + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: cg_coeff => NULL() ! list of non-zero CG coefficients - INTEGER, DIMENSION(:, :, :), POINTER :: cg_none0_list + INTEGER, DIMENSION(:, :, :), POINTER :: cg_none0_list => NULL() ! number of non-zero CG coefficients - INTEGER, DIMENSION(:, :), POINTER :: ncg_none0 + INTEGER, DIMENSION(:, :), POINTER :: ncg_none0 => NULL() END TYPE lri_clebsch_gordon_type ! ************************************************************************************************** TYPE lri_ppl_type ! integrals Vppl*fbas (potential*fit basis) dim(natom,nsgf) - REAL(KIND=dp), DIMENSION(:, :), POINTER :: v_int + REAL(KIND=dp), DIMENSION(:, :), POINTER :: v_int => NULL() END TYPE lri_ppl_type TYPE lri_ppl_int_type - TYPE(lri_ppl_type), DIMENSION(:), POINTER :: lri_ppl - REAL(KIND=dp) :: ecore_pp_ri + TYPE(lri_ppl_type), DIMENSION(:), POINTER :: lri_ppl => NULL() + REAL(KIND=dp) :: ecore_pp_ri = 0.0_dp END TYPE lri_ppl_int_type ! ************************************************************************************************** TYPE ri_fit_type - INTEGER, DIMENSION(:, :), POINTER :: bas_ptr - REAL(KIND=dp), DIMENSION(:), POINTER :: nvec - REAL(KIND=dp), DIMENSION(:), POINTER :: rm1n - REAL(KIND=dp), DIMENSION(:, :), POINTER :: tvec - REAL(KIND=dp), DIMENSION(:, :), POINTER :: rm1t - REAL(KIND=dp), DIMENSION(:, :), POINTER :: avec - REAL(KIND=dp), DIMENSION(:, :), POINTER :: fout - REAL(KIND=dp) :: ntrm1n - REAL(KIND=dp), DIMENSION(2) :: ftrm1n - REAL(KIND=dp), DIMENSION(2) :: echarge - REAL(KIND=dp), DIMENSION(2) :: lambda + INTEGER, DIMENSION(:, :), POINTER :: bas_ptr => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: nvec => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: rm1n => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: tvec => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: rm1t => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: avec => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: fout => NULL() + REAL(KIND=dp) :: ntrm1n = 0.0_dp + REAL(KIND=dp), DIMENSION(2) :: ftrm1n = 0.0_dp + REAL(KIND=dp), DIMENSION(2) :: echarge = 0.0_dp + REAL(KIND=dp), DIMENSION(2) :: lambda = 0.0_dp END TYPE ri_fit_type ! ************************************************************************************************** TYPE wmat_type - REAL(KIND=dp), DIMENSION(:, :), POINTER :: mat + REAL(KIND=dp), DIMENSION(:, :), POINTER :: mat => NULL() END TYPE wmat_type + TYPE wbas_type - REAL(KIND=dp), DIMENSION(:), POINTER :: vec + REAL(KIND=dp), DIMENSION(:), POINTER :: vec => NULL() END TYPE wbas_type ! ************************************************************************************************** TYPE stat_type - REAL(KIND=dp) :: pairs_tt - REAL(KIND=dp) :: pairs_sr - REAL(KIND=dp) :: pairs_ff - REAL(KIND=dp) :: overlap_error - REAL(KIND=dp) :: rho_tt - REAL(KIND=dp) :: rho_sr - REAL(KIND=dp) :: rho_ff - REAL(KIND=dp) :: rho_1c - REAL(KIND=dp) :: coef_mem - REAL(KIND=dp) :: oint_mem - REAL(KIND=dp) :: rhos_mem - REAL(KIND=dp) :: abai_mem - REAL(KIND=dp) :: ppli_mem + REAL(KIND=dp) :: pairs_tt = 0.0_dp + REAL(KIND=dp) :: pairs_sr = 0.0_dp + REAL(KIND=dp) :: pairs_ff = 0.0_dp + REAL(KIND=dp) :: overlap_error = 0.0_dp + REAL(KIND=dp) :: rho_tt = 0.0_dp + REAL(KIND=dp) :: rho_sr = 0.0_dp + REAL(KIND=dp) :: rho_ff = 0.0_dp + REAL(KIND=dp) :: rho_1c = 0.0_dp + REAL(KIND=dp) :: coef_mem = 0.0_dp + REAL(KIND=dp) :: oint_mem = 0.0_dp + REAL(KIND=dp) :: rhos_mem = 0.0_dp + REAL(KIND=dp) :: abai_mem = 0.0_dp + REAL(KIND=dp) :: ppli_mem = 0.0_dp END TYPE stat_type ! ************************************************************************************************** TYPE lri_environment_type ! parameter for (pseudo)inverse of overlap - INTEGER :: lri_overlap_inv + INTEGER :: lri_overlap_inv = -1 ! flag for debugging lri integrals - LOGICAL :: debug + LOGICAL :: debug = .FALSE. ! flag for shg (solid haromonic Gaussian) integrals - LOGICAL :: use_shg_integrals + LOGICAL :: use_shg_integrals = .FALSE. ! parameter for inversion (autoselect); maximal condition ! number up to where inversion is legal - REAL(KIND=dp) :: cond_max + REAL(KIND=dp) :: cond_max = 0.0_dp ! parameter for checking distance between atom pairs - REAL(KIND=dp) :: delta + REAL(KIND=dp) :: delta = 0.0_dp ! threshold for aba and abb integrals - REAL(KIND=dp) :: eps_o3_int + REAL(KIND=dp) :: eps_o3_int = 0.0_dp ! orbital basis set - TYPE(gto_basis_set_p_type), DIMENSION(:), POINTER :: orb_basis + TYPE(gto_basis_set_p_type), DIMENSION(:), POINTER :: orb_basis => NULL() ! lri (fit) basis set - TYPE(gto_basis_set_p_type), DIMENSION(:), POINTER :: ri_basis + TYPE(gto_basis_set_p_type), DIMENSION(:), POINTER :: ri_basis => NULL() ! orb_basis neighborlist - TYPE(neighbor_list_set_p_type), DIMENSION(:), POINTER :: soo_list - TYPE(neighbor_list_set_p_type), DIMENSION(:), POINTER :: saa_list - TYPE(neighbor_list_set_p_type), DIMENSION(:), POINTER :: soa_list + TYPE(neighbor_list_set_p_type), DIMENSION(:), POINTER :: soo_list => NULL() + TYPE(neighbor_list_set_p_type), DIMENSION(:), POINTER :: saa_list => NULL() + TYPE(neighbor_list_set_p_type), DIMENSION(:), POINTER :: soa_list => NULL() ! local RI integrals - TYPE(lri_list_type), POINTER :: lri_ints + TYPE(lri_list_type), POINTER :: lri_ints => NULL() ! local Vppl integrals - TYPE(lri_ppl_int_type), POINTER :: lri_ppl_ints + TYPE(lri_ppl_int_type), POINTER :: lri_ppl_ints => NULL() ! local integral of rho**2; for optimization - TYPE(lri_list_type), POINTER :: lri_ints_rho + TYPE(lri_list_type), POINTER :: lri_ints_rho => NULL() ! properties of orb and aux basis - TYPE(lri_bas_type), DIMENSION(:), POINTER :: bas_prop + TYPE(lri_bas_type), DIMENSION(:), POINTER :: bas_prop => NULL() ! Clebsch-Gordon for solid harmonics - TYPE(lri_clebsch_gordon_type), POINTER :: cg_shg + TYPE(lri_clebsch_gordon_type), POINTER :: cg_shg => NULL() ! orbital basis overlap - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: ob_smat + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: ob_smat => NULL() ! statistics - LOGICAL :: statistics - TYPE(stat_type) :: stat + LOGICAL :: statistics = .FALSE. + TYPE(stat_type) :: stat = stat_type() ! exact one-center terms - LOGICAL :: exact_1c_terms + LOGICAL :: exact_1c_terms = .FALSE. ! use RI for local pp - LOGICAL :: ppl_ri + LOGICAL :: ppl_ri = .FALSE. ! store integrals (needed for basis optimization) - LOGICAL :: store_integrals + LOGICAL :: store_integrals = .FALSE. ! distant pair approximation - LOGICAL :: distant_pair_approximation - CHARACTER(len=10) :: distant_pair_method - REAL(KIND=dp) :: r_in - REAL(KIND=dp) :: r_out - REAL(KIND=dp), DIMENSION(:), POINTER :: aradius - TYPE(wbas_type), DIMENSION(:), POINTER :: wbas - TYPE(wmat_type), DIMENSION(:, :), POINTER :: wmat + LOGICAL :: distant_pair_approximation = .FALSE. + CHARACTER(len=10) :: distant_pair_method = "" + REAL(KIND=dp) :: r_in = 0.0_dp + REAL(KIND=dp) :: r_out = 0.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: aradius => NULL() + TYPE(wbas_type), DIMENSION(:), POINTER :: wbas => NULL() + TYPE(wmat_type), DIMENSION(:, :), POINTER :: wmat => NULL() ! RI overlap and inverse - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: ri_smat, & - ri_sinv - TYPE(ri_fit_type), POINTER :: ri_fit - CHARACTER(len=10) :: ri_sinv_app - TYPE(o3c_container_type), POINTER :: o3c + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: ri_smat => NULL(), & + ri_sinv => NULL() + TYPE(ri_fit_type), POINTER :: ri_fit => NULL() + CHARACTER(len=10) :: ri_sinv_app = "" + TYPE(o3c_container_type), POINTER :: o3c => NULL() END TYPE lri_environment_type ! ************************************************************************************************** TYPE lri_kind_type ! expansion coeff for lri density dim(natom,nsgf) - REAL(KIND=dp), DIMENSION(:, :), POINTER :: acoef + REAL(KIND=dp), DIMENSION(:, :), POINTER :: acoef => NULL() ! integrals V*fbas (potential*fit basis) dim(natom,nsgf) - REAL(KIND=dp), DIMENSION(:, :), POINTER :: v_int + REAL(KIND=dp), DIMENSION(:, :), POINTER :: v_int => NULL() ! SUM_i integral(V*fbas_i)*davec/dR dim(natom,3) - REAL(KIND=dp), DIMENSION(:, :), POINTER :: v_dadr + REAL(KIND=dp), DIMENSION(:, :), POINTER :: v_dadr => NULL() ! integrals V*dfbas/dR - REAL(KIND=dp), DIMENSION(:, :), POINTER :: v_dfdr + REAL(KIND=dp), DIMENSION(:, :), POINTER :: v_dfdr => NULL() END TYPE lri_kind_type TYPE lri_spin_type - TYPE(lri_kind_type), DIMENSION(:), POINTER :: lri_kinds + TYPE(lri_kind_type), DIMENSION(:), POINTER :: lri_kinds => NULL() END TYPE lri_spin_type ! ************************************************************************************************** TYPE lri_force_type - REAL(KIND=dp), DIMENSION(:), POINTER :: st - REAL(KIND=dp), DIMENSION(:, :), POINTER :: dssn, & - dsst + REAL(KIND=dp), DIMENSION(:), POINTER :: st => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: dssn => NULL(), & + dsst => NULL() ! derivative dtvec/dR - REAL(KIND=dp), DIMENSION(:, :), POINTER :: dtvec + REAL(KIND=dp), DIMENSION(:, :), POINTER :: dtvec => NULL() END TYPE lri_force_type ! ************************************************************************************************** diff --git a/src/lri_optimize_ri_basis_types.F b/src/lri_optimize_ri_basis_types.F index 49fad2a78b..1079ce21fe 100644 --- a/src/lri_optimize_ri_basis_types.F +++ b/src/lri_optimize_ri_basis_types.F @@ -34,35 +34,35 @@ MODULE lri_optimize_ri_basis_types TYPE lri_gcc_p_type ! gcc without normalization factor - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: gcc_orig + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: gcc_orig => NULL() END TYPE lri_gcc_p_type TYPE lri_subset_type ! amount of l quantum numbers per set - INTEGER :: nl + INTEGER :: nl = -1 ! number of contraction per l quantum number for a given set - INTEGER, DIMENSION(:), POINTER :: ncont_l + INTEGER, DIMENSION(:), POINTER :: ncont_l => NULL() END TYPE lri_subset_type TYPE lri_opt_type - LOGICAL :: opt_exps - LOGICAL :: opt_coeffs - LOGICAL :: use_condition_number - LOGICAL :: use_geometric_seq - LOGICAL :: use_constraints - INTEGER :: nexp - INTEGER :: ncoeff - REAL(KIND=dp) :: cond_weight - REAL(KIND=dp) :: scale_exp - REAL(KIND=dp) :: fermi_exp - REAL(KIND=dp) :: rho_diff + LOGICAL :: opt_exps = .FALSE. + LOGICAL :: opt_coeffs = .FALSE. + LOGICAL :: use_condition_number = .FALSE. + LOGICAL :: use_geometric_seq = .FALSE. + LOGICAL :: use_constraints = .FALSE. + INTEGER :: nexp = -1 + INTEGER :: ncoeff = -1 + REAL(KIND=dp) :: cond_weight = 0.0_dp + REAL(KIND=dp) :: scale_exp = 0.0_dp + REAL(KIND=dp) :: fermi_exp = 0.0_dp + REAL(KIND=dp) :: rho_diff = 0.0_dp ! array holding the variables that are optimized - REAL(KIND=dp), DIMENSION(:), POINTER :: x + REAL(KIND=dp), DIMENSION(:), POINTER :: x => NULL() ! initial exponents - REAL(KIND=dp), DIMENSION(:), POINTER :: zet_init + REAL(KIND=dp), DIMENSION(:), POINTER :: zet_init => NULL() ! holds the original contraction coeff of the lri basis - TYPE(lri_gcc_p_type), DIMENSION(:), POINTER :: ri_gcc_orig - TYPE(lri_subset_type), DIMENSION(:), POINTER :: subset + TYPE(lri_gcc_p_type), DIMENSION(:), POINTER :: ri_gcc_orig => NULL() + TYPE(lri_subset_type), DIMENSION(:), POINTER :: subset => NULL() END TYPE lri_opt_type ! ************************************************************************************************** diff --git a/src/mao_methods.F b/src/mao_methods.F index 0522c590a9..ca05ff2a2b 100644 --- a/src/mao_methods.F +++ b/src/mao_methods.F @@ -65,9 +65,9 @@ MODULE mao_methods CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'mao_methods' TYPE mblocks - INTEGER :: n, ma - REAL(KIND=dp), DIMENSION(:, :), POINTER :: mat - REAL(KIND=dp), DIMENSION(:), POINTER :: eig + INTEGER :: n = -1, ma = -1 + REAL(KIND=dp), DIMENSION(:, :), POINTER :: mat => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: eig => NULL() END TYPE mblocks PUBLIC :: mao_initialization, mao_function, mao_function_gradient, mao_orthogonalization, & diff --git a/src/mao_types.F b/src/mao_types.F index 7fbc3382a1..39e1b1653e 100644 --- a/src/mao_types.F +++ b/src/mao_types.F @@ -24,7 +24,7 @@ MODULE mao_types !> \author JGH ! ************************************************************************************************** TYPE mao_type - INTEGER :: ref_basis + INTEGER :: ref_basis = -1 END TYPE mao_type ! ************************************************************************************************** diff --git a/src/mdctrl_types.F b/src/mdctrl_types.F index b938c1b58d..84b79299ed 100644 --- a/src/mdctrl_types.F +++ b/src/mdctrl_types.F @@ -19,13 +19,13 @@ MODULE mdctrl_types PRIVATE TYPE glbopt_mdctrl_data_type - INTEGER :: md_bump_counter + INTEGER :: md_bump_counter = -1 REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: epot_history - INTEGER :: output_unit - INTEGER :: itimes - INTEGER :: bump_steps_upwards - INTEGER :: bump_steps_downwards - INTEGER :: md_bumps_max + INTEGER :: output_unit = -1 + INTEGER :: itimes = -1 + INTEGER :: bump_steps_upwards = -1 + INTEGER :: bump_steps_downwards = -1 + INTEGER :: md_bumps_max = -1 END TYPE glbopt_mdctrl_data_type TYPE mdctrl_type diff --git a/src/metadynamics_types.F b/src/metadynamics_types.F index 07851a499f..f6d399ba6b 100644 --- a/src/metadynamics_types.F +++ b/src/metadynamics_types.F @@ -38,87 +38,88 @@ MODULE metadynamics_types !> \brief defines types for HILLS ! ************************************************************************************************** TYPE hills_env_type - LOGICAL :: restart, slow_growth, wtcontrol + LOGICAL :: restart = .FALSE., slow_growth = .FALSE., wtcontrol = .FALSE. !RG Adaptive hills - REAL(KIND=dp) :: ww, min_disp, energy - INTEGER :: n_hills, nt_hills, min_nt_hills - INTEGER :: old_hill_number, old_hill_step + REAL(KIND=dp) :: ww = 0.0_dp, min_disp = 0.0_dp, energy = 0.0_dp + INTEGER :: n_hills = -1, nt_hills = -1, min_nt_hills = -1 + INTEGER :: old_hill_number = -1, old_hill_step = -1 !RG Adaptive hills - REAL(KIND=dp), DIMENSION(:, :), POINTER :: ss_history - REAL(KIND=dp), DIMENSION(:, :), POINTER :: delta_s_history - REAL(KIND=dp), DIMENSION(:), POINTER :: ww_history - REAL(KIND=dp), DIMENSION(:), POINTER :: invdt_history + REAL(KIND=dp), DIMENSION(:, :), POINTER :: ss_history => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: delta_s_history => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: ww_history => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: invdt_history => NULL() !Hills tail damping - REAL(KIND=dp) :: tail_cutoff - INTEGER :: p_exp, q_exp + REAL(KIND=dp) :: tail_cutoff = 0.0_dp + INTEGER :: p_exp = -1, q_exp = -1 END TYPE hills_env_type ! ************************************************************************************************** !> \brief defines types for WALLS ! ************************************************************************************************** TYPE wall_type - INTEGER :: id_type, id_direction - REAL(KIND=dp) :: pos, pos0 - REAL(KIND=dp) :: k_quadratic, k_quartic, ww_gauss, sigma_gauss + INTEGER :: id_type = -1, id_direction = -1 + REAL(KIND=dp) :: pos = 0.0_dp, pos0 = 0.0_dp + REAL(KIND=dp) :: k_quadratic = 0.0_dp, k_quartic = 0.0_dp, & + ww_gauss = 0.0_dp, sigma_gauss = 0.0_dp END TYPE wall_type ! ************************************************************************************************** !> \brief defines types for COLVAR used in the metadynamics ! ************************************************************************************************** TYPE metavar_type - INTEGER :: icolvar - LOGICAL :: do_wall, periodic - REAL(KIND=dp) :: mass, lambda, vvp - REAL(KIND=dp) :: gamma - REAL(KIND=dp) :: epot_s, delta_s, epot_walls - REAL(KIND=dp) :: ss, ss0, ff_s, ff_hills, ff_walls - TYPE(wall_type), DIMENSION(:), POINTER :: walls + INTEGER :: icolvar = -1 + LOGICAL :: do_wall = .FALSE., periodic = .FALSE. + REAL(KIND=dp) :: mass = 0.0_dp, lambda = 0.0_dp, vvp = 0.0_dp + REAL(KIND=dp) :: gamma = 0.0_dp + REAL(KIND=dp) :: epot_s = 0.0_dp, delta_s = 0.0_dp, epot_walls = 0.0_dp + REAL(KIND=dp) :: ss = 0.0_dp, ss0 = 0.0_dp, ff_s = 0.0_dp, ff_hills = 0.0_dp, ff_walls = 0.0_dp + TYPE(wall_type), DIMENSION(:), POINTER :: walls => NULL() END TYPE metavar_type ! ************************************************************************************************** !> \brief defines types for multiple walkers run ! ************************************************************************************************** TYPE multiple_walkers_type - INTEGER :: n_hills_local - INTEGER :: walker_id - INTEGER :: walkers_tot_nr - INTEGER :: walkers_freq_comm - INTEGER, DIMENSION(:), POINTER :: walkers_status + INTEGER :: n_hills_local = -1 + INTEGER :: walker_id = -1 + INTEGER :: walkers_tot_nr = -1 + INTEGER :: walkers_freq_comm = -1 + INTEGER, DIMENSION(:), POINTER :: walkers_status => NULL() CHARACTER(LEN=default_path_length), & - DIMENSION(:), POINTER :: walkers_file_name + DIMENSION(:), POINTER :: walkers_file_name => NULL() END TYPE multiple_walkers_type ! ************************************************************************************************** !> \brief defines meta_env type ! ************************************************************************************************** TYPE meta_env_type - LOGICAL :: do_hills, do_multiple_walkers - LOGICAL :: extended_lagrange - LOGICAL :: well_tempered - LOGICAL :: langevin - LOGICAL :: use_plumed - CHARACTER(LEN=default_path_length) :: plumed_input_file - INTEGER :: n_colvar - REAL(KIND=dp) :: ekin_s, epot_s, dt, & - avg_temp, epot_walls - LOGICAL :: tempcontrol, restart - REAL(KIND=dp) :: temp_wanted, toll_temp - REAL(KIND=dp) :: delta_t, invdt, & - wtgamma, wttemperature - INTEGER :: n_steps + LOGICAL :: do_hills = .FALSE., do_multiple_walkers = .FALSE. + LOGICAL :: extended_lagrange = .FALSE. + LOGICAL :: well_tempered = .FALSE. + LOGICAL :: langevin = .FALSE. + LOGICAL :: use_plumed = .FALSE. + CHARACTER(LEN=default_path_length) :: plumed_input_file = "" + INTEGER :: n_colvar = -1 + REAL(KIND=dp) :: ekin_s = 0.0_dp, epot_s = 0.0_dp, dt = 0.0_dp, & + avg_temp = 0.0_dp, epot_walls = 0.0_dp + LOGICAL :: tempcontrol = .FALSE., restart = .FALSE. + REAL(KIND=dp) :: temp_wanted = 0.0_dp, toll_temp = 0.0_dp + REAL(KIND=dp) :: delta_t = 0.0_dp, invdt = 0.0_dp, & + wtgamma = 0.0_dp, wttemperature = 0.0_dp + INTEGER :: n_steps = -1 ! time pointer should never be allocated itself.. that's a quite bad ! choice derived from the md_env.. So whenever the meta_env type is ! used the pointer time should be pointer to the high level time counter - REAL(KIND=dp), POINTER :: time - TYPE(hills_env_type), POINTER :: hills_env - TYPE(metavar_type), POINTER, DIMENSION(:) :: metavar - TYPE(multiple_walkers_type), POINTER :: multiple_walkers - TYPE(mp_para_env_type), POINTER :: para_env - TYPE(section_vals_type), POINTER :: metadyn_section + REAL(KIND=dp), POINTER :: time => NULL() + TYPE(hills_env_type), POINTER :: hills_env => NULL() + TYPE(metavar_type), POINTER, DIMENSION(:) :: metavar => NULL() + TYPE(multiple_walkers_type), POINTER :: multiple_walkers => NULL() + TYPE(mp_para_env_type), POINTER :: para_env => NULL() + TYPE(section_vals_type), POINTER :: metadyn_section => NULL() TYPE(rng_stream_type), DIMENSION(:), & ALLOCATABLE :: rng - INTEGER :: TAMCSteps - REAL(kind=dp) :: zdt + INTEGER :: TAMCSteps = -1 + REAL(kind=dp) :: zdt = 0.0_dp END TYPE meta_env_type CONTAINS diff --git a/src/mixed_cdft_types.F b/src/mixed_cdft_types.F index 3b7b687b9d..dcd33dee66 100644 --- a/src/mixed_cdft_types.F +++ b/src/mixed_cdft_types.F @@ -64,13 +64,13 @@ MODULE mixed_cdft_types ! ************************************************************************************************** TYPE mixed_cdft_work_type ! Matrix representations of the CDFT weight functions - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: w_matrix + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: w_matrix => NULL() ! AO overlap matrix - TYPE(dbcsr_type), POINTER :: mixed_matrix_s + TYPE(dbcsr_type), POINTER :: mixed_matrix_s => NULL() ! MO coefficients of each CDFT state - TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: mixed_mo_coeff + TYPE(cp_fm_type), DIMENSION(:, :), POINTER :: mixed_mo_coeff => NULL() ! Density matrices of the CDFT states - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: density_matrix + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: density_matrix => NULL() END TYPE mixed_cdft_work_type ! ************************************************************************************************** @@ -82,18 +82,18 @@ MODULE mixed_cdft_types !> \param gradients the gradients to send ! ************************************************************************************************** TYPE buffers - INTEGER :: rank(2), tag(2) + INTEGER :: rank(2) = -1, tag(2) = -1 REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :) :: cavity, weight + DIMENSION(:, :, :) :: cavity => NULL(), weight => NULL() REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :, :) :: gradients + DIMENSION(:, :, :, :) :: gradients => NULL() END TYPE buffers ! ************************************************************************************************** !> \brief To build array of buffers !> \param buffs the pointer to the buffers type ! ************************************************************************************************** TYPE p_buffers - TYPE(buffers), DIMENSION(:), POINTER :: buffs + TYPE(buffers), DIMENSION(:), POINTER :: buffs => NULL() END TYPE p_buffers ! ************************************************************************************************** !> \brief Information about load balancing @@ -101,8 +101,8 @@ MODULE mixed_cdft_types !> \param target_list the target_list array of the processor that sends me data ! ************************************************************************************************** TYPE repl_info - INTEGER, DIMENSION(:), POINTER :: matrix_info - INTEGER, DIMENSION(:, :), POINTER :: target_list + INTEGER, DIMENSION(:), POINTER :: matrix_info => NULL() + INTEGER, DIMENSION(:, :), POINTER :: target_list => NULL() END TYPE repl_info ! ************************************************************************************************** !> \brief Load balancing control for mixed CDFT calculation @@ -134,23 +134,23 @@ MODULE mixed_cdft_types !> \param recv_info additional information on the data this processor will receive ! ************************************************************************************************** TYPE mixed_cdft_dlb_type - INTEGER :: my_source, distributed(2), & - my_dest_repl(2), dest_tags_repl(2), & - more_work - INTEGER, DIMENSION(:), POINTER :: bo, expected_work, & - prediction_error - INTEGER, DIMENSION(:, :), POINTER :: target_list - LOGICAL :: recv_work, send_work - LOGICAL, DIMENSION(:), POINTER :: recv_work_repl - REAL(KIND=dp) :: load_scale, very_overloaded + INTEGER :: my_source = -1, distributed(2) = -1, & + my_dest_repl(2) = -1, dest_tags_repl(2) = -1, & + more_work = -1 + INTEGER, DIMENSION(:), POINTER :: bo => NULL(), expected_work => NULL(), & + prediction_error => NULL() + INTEGER, DIMENSION(:, :), POINTER :: target_list => NULL() + LOGICAL :: recv_work = .FALSE., send_work = .FALSE. + LOGICAL, DIMENSION(:), POINTER :: recv_work_repl => NULL() + REAL(KIND=dp) :: load_scale = 0.0_dp, very_overloaded = 0.0_dp REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :) :: cavity, weight + DIMENSION(:, :, :) :: cavity => NULL(), weight => NULL() REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :, :) :: gradients + DIMENSION(:, :, :, :) :: gradients => NULL() ! Should convert to TYPE(p_buffers), POINTER - TYPE(buffers), DIMENSION(:), POINTER :: sendbuff - TYPE(p_buffers), DIMENSION(:), POINTER :: recvbuff - TYPE(repl_info), DIMENSION(:), POINTER :: recv_info + TYPE(buffers), DIMENSION(:), POINTER :: sendbuff => NULL() + TYPE(p_buffers), DIMENSION(:), POINTER :: recvbuff => NULL() + TYPE(repl_info), DIMENSION(:), POINTER :: recv_info => NULL() END TYPE mixed_cdft_dlb_type ! ************************************************************************************************** !> \brief Main mixed CDFT control type @@ -202,65 +202,65 @@ MODULE mixed_cdft_types !> \param occupations occupation numbers in case non-uniform occupation ! ************************************************************************************************** TYPE mixed_cdft_type - INTEGER :: sim_step, multiplicity, & - nconstraint, & - run_type + INTEGER :: sim_step = -1, multiplicity = -1, & + nconstraint = -1, & + run_type = -1 INTEGER, DIMENSION(:, :), ALLOCATABLE :: constraint_type - INTEGER, POINTER, DIMENSION(:) :: source_list, dest_list, & - recv_bo, source_list_save, & - dest_list_save - INTEGER, POINTER, DIMENSION(:, :) :: source_list_bo, dest_list_bo, & - source_bo_save, dest_bo_save - LOGICAL :: is_pencil, dlb, & - is_special, first_iteration, & - calculate_metric, & - wfn_overlap_method, & - has_unit_metric, & - use_lowdin, & - do_ci, nonortho_coupling, & - identical_constraints, & - block_diagonalize - REAL(KIND=dp) :: eps_rho_rspace, sim_dt, & - eps_svd - REAL(KIND=dp), POINTER, DIMENSION(:, :, :) :: weight, cavity - TYPE(cdft_control_type), POINTER :: cdft_control - TYPE(buffers), DIMENSION(:), POINTER :: sendbuff + INTEGER, POINTER, DIMENSION(:) :: source_list => NULL(), dest_list => NULL(), & + recv_bo => NULL(), source_list_save => NULL(), & + dest_list_save => NULL() + INTEGER, POINTER, DIMENSION(:, :) :: source_list_bo => NULL(), dest_list_bo => NULL(), & + source_bo_save => NULL(), dest_bo_save => NULL() + LOGICAL :: is_pencil = .FALSE., dlb = .FALSE., & + is_special = .FALSE., first_iteration = .FALSE., & + calculate_metric = .FALSE., & + wfn_overlap_method = .FALSE., & + has_unit_metric = .FALSE., & + use_lowdin = .FALSE., & + do_ci = .FALSE., nonortho_coupling = .FALSE., & + identical_constraints = .FALSE., & + block_diagonalize = .FALSE. + REAL(KIND=dp) :: eps_rho_rspace = 0.0_dp, sim_dt = 0.0_dp, & + eps_svd = 0.0_dp + REAL(KIND=dp), POINTER, DIMENSION(:, :, :) :: weight => NULL(), cavity => NULL() + TYPE(cdft_control_type), POINTER :: cdft_control => NULL() + TYPE(buffers), DIMENSION(:), POINTER :: sendbuff => NULL() TYPE(cp_1d_r_p_type), ALLOCATABLE, & DIMENSION(:, :) :: occupations - TYPE(cp_blacs_env_type), POINTER :: blacs_env - TYPE(cp_logger_p_type), DIMENSION(:), POINTER :: sub_logger - TYPE(mixed_cdft_result_type) :: results - TYPE(mixed_cdft_work_type) :: matrix - TYPE(mixed_cdft_dlb_type), POINTER :: dlb_control - TYPE(pw_env_type), POINTER :: pw_env + TYPE(cp_blacs_env_type), POINTER :: blacs_env => NULL() + TYPE(cp_logger_p_type), DIMENSION(:), POINTER :: sub_logger => NULL() + TYPE(mixed_cdft_result_type) :: results = mixed_cdft_result_type() + TYPE(mixed_cdft_work_type) :: matrix = mixed_cdft_work_type() + TYPE(mixed_cdft_dlb_type), POINTER :: dlb_control => NULL() + TYPE(pw_env_type), POINTER :: pw_env => NULL() TYPE(qs_kind_type), DIMENSION(:), & - POINTER :: qs_kind_set + POINTER :: qs_kind_set => NULL() END TYPE mixed_cdft_type ! ************************************************************************************************** !> \brief Container for constraint settings to check consistency of force_evals ! ************************************************************************************************** TYPE mixed_cdft_settings_type - LOGICAL :: is_spherical, & - is_odd - LOGICAL, DIMENSION(:, :), POINTER :: sb - INTEGER :: ncdft, & - max_nkinds - INTEGER, DIMENSION(2, 3) :: bo - INTEGER, DIMENSION(:), POINTER :: grid_span, & - spherical, & - odd - INTEGER, DIMENSION(:, :), POINTER :: si, & - rs_dims, & - atoms, & - npts - REAL(KIND=dp) :: radius - REAL(KIND=dp), DIMENSION(:), POINTER :: cutoff, & - rel_cutoff - REAL(KIND=dp), DIMENSION(:, :), POINTER :: sr, & - coeffs, & - cutoffs, & - radii + LOGICAL :: is_spherical = .FALSE., & + is_odd = .FALSE. + LOGICAL, DIMENSION(:, :), POINTER :: sb => NULL() + INTEGER :: ncdft = -1, & + max_nkinds = -1 + INTEGER, DIMENSION(2, 3) :: bo = -1 + INTEGER, DIMENSION(:), POINTER :: grid_span => NULL(), & + spherical => NULL(), & + odd => NULL() + INTEGER, DIMENSION(:, :), POINTER :: si => NULL(), & + rs_dims => NULL(), & + atoms => NULL(), & + npts => NULL() + REAL(KIND=dp) :: radius = 0.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: cutoff => NULL(), & + rel_cutoff => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: sr => NULL(), & + coeffs => NULL(), & + cutoffs => NULL(), & + radii => NULL() END TYPE mixed_cdft_settings_type ! *** Public data types *** diff --git a/src/mixed_energy_types.F b/src/mixed_energy_types.F index 812edbac34..0dbee1c27b 100644 --- a/src/mixed_energy_types.F +++ b/src/mixed_energy_types.F @@ -20,13 +20,13 @@ MODULE mixed_energy_types ! ************************************************************************************************** TYPE mixed_energy_type - REAL(kind=dp) :: pot - REAL(kind=dp) :: kin + REAL(kind=dp) :: pot = 0.0_dp + REAL(kind=dp) :: kin = 0.0_dp END TYPE mixed_energy_type ! ************************************************************************************************** TYPE mixed_force_type - REAL(KIND=dp), DIMENSION(:, :), POINTER :: forces + REAL(KIND=dp), DIMENSION(:, :), POINTER :: forces => NULL() END TYPE mixed_force_type ! Public data types diff --git a/src/mm_mapping_library.F b/src/mm_mapping_library.F index 0ff41d5a65..5507f71eda 100644 --- a/src/mm_mapping_library.F +++ b/src/mm_mapping_library.F @@ -27,8 +27,8 @@ MODULE mm_mapping_library ! ************************************************************************************************** TYPE ff_map_type - CHARACTER(LEN=default_string_length), DIMENSION(:), POINTER :: kind - CHARACTER(LEN=default_string_length), DIMENSION(:), POINTER :: element + CHARACTER(LEN=default_string_length), DIMENSION(:), POINTER :: kind => NULL() + CHARACTER(LEN=default_string_length), DIMENSION(:), POINTER :: element => NULL() END TYPE ff_map_type TYPE(ff_map_type), POINTER, PUBLIC :: amber_map, & diff --git a/src/mode_selective.F b/src/mode_selective.F index 5f975030f9..c84dc26c6e 100644 --- a/src/mode_selective.F +++ b/src/mode_selective.F @@ -60,25 +60,25 @@ MODULE mode_selective LOGICAL, PARAMETER :: debug_this_module = .FALSE. TYPE ms_vib_type - INTEGER :: mat_size - INTEGER :: select_id - INTEGER, DIMENSION(:), POINTER :: inv_atoms - REAL(KIND=dp) :: eps(2) - REAL(KIND=dp) :: sel_freq - REAL(KIND=dp) :: low_freq - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: b_vec - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: delta_vec - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: ms_force - REAL(KIND=dp), DIMENSION(:), POINTER :: eig_bfgs - REAL(KIND=dp), DIMENSION(:), POINTER :: f_range - REAL(KIND=dp), DIMENSION(:), POINTER :: inv_range - REAL(KIND=dp), POINTER, DIMENSION(:) :: step_b - REAL(KIND=dp), POINTER, DIMENSION(:) :: step_r - REAL(KIND=dp), DIMENSION(:, :), POINTER :: b_mat - REAL(KIND=dp), DIMENSION(:, :), POINTER :: dip_deriv - REAL(KIND=dp), DIMENSION(:, :), POINTER :: hes_bfgs - REAL(KIND=dp), DIMENSION(:, :), POINTER :: s_mat - INTEGER :: initial_guess + INTEGER :: mat_size = -1 + INTEGER :: select_id = -1 + INTEGER, DIMENSION(:), POINTER :: inv_atoms => NULL() + REAL(KIND=dp) :: eps(2) = 0.0_dp + REAL(KIND=dp) :: sel_freq = 0.0_dp + REAL(KIND=dp) :: low_freq = 0.0_dp + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: b_vec => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: delta_vec => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: ms_force => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: eig_bfgs => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: f_range => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: inv_range => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:) :: step_b => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:) :: step_r => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: b_mat => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: dip_deriv => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: hes_bfgs => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: s_mat => NULL() + INTEGER :: initial_guess = -1 END TYPE ms_vib_type PUBLIC :: ms_vb_anal diff --git a/src/molsym.F b/src/molsym.F index 655c5b539f..6d4e4cef49 100644 --- a/src/molsym.F +++ b/src/molsym.F @@ -92,23 +92,26 @@ MODULE molsym !> \author jgh ! ************************************************************************************************** TYPE molsym_type - CHARACTER(LEN=4) :: point_group_symbol - INTEGER :: point_group_order - INTEGER :: ncn, ndod, ngroup, nico, nlin, nsig, nsn, ntet - LOGICAL :: cubic, dgroup, igroup, invers, linear, maxis, & - ogroup, sgroup, sigmad, sigmah, sigmav, tgroup - REAL(KIND=dp) :: eps_geo - REAL(KIND=dp), DIMENSION(3) :: center_of_mass, tenval - REAL(KIND=dp), DIMENSION(3) :: x_axis, y_axis, z_axis - REAL(KIND=dp), DIMENSION(:), POINTER :: ain, aw - REAL(KIND=dp), DIMENSION(3, 3) :: inptostd, rotmat, tenmat, tenvec - REAL(KIND=dp), DIMENSION(3, maxsig) :: sig - REAL(KIND=dp), DIMENSION(3, maxsec, 2:maxcn) :: sec - REAL(KIND=dp), DIMENSION(3, maxses, 2:maxsn) :: ses - INTEGER, DIMENSION(maxcn) :: nsec - INTEGER, DIMENSION(maxsn) :: nses - INTEGER, DIMENSION(:), POINTER :: group_of, llequatom, nequatom, & - symequ_list, ulequatom + CHARACTER(LEN=4) :: point_group_symbol = "" + INTEGER :: point_group_order = -1 + INTEGER :: ncn = -1, ndod = -1, ngroup = -1, nico = -1, & + nlin = -1, nsig = -1, nsn = -1, ntet = -1 + LOGICAL :: cubic = .FALSE., dgroup = .FALSE., igroup = .FALSE., & + invers = .FALSE., linear = .FALSE., maxis = .FALSE., & + ogroup = .FALSE., sgroup = .FALSE., sigmad = .FALSE., & + sigmah = .FALSE., sigmav = .FALSE., tgroup = .FALSE. + REAL(KIND=dp) :: eps_geo = 0.0_dp + REAL(KIND=dp), DIMENSION(3) :: center_of_mass = 0.0_dp, tenval = 0.0_dp + REAL(KIND=dp), DIMENSION(3) :: x_axis = 0.0_dp, y_axis = 0.0_dp, z_axis = 0.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: ain => NULL(), aw => NULL() + REAL(KIND=dp), DIMENSION(3, 3) :: inptostd = 0.0_dp, rotmat = 0.0_dp, tenmat = 0.0_dp, tenvec = 0.0_dp + REAL(KIND=dp), DIMENSION(3, maxsig) :: sig = 0.0_dp + REAL(KIND=dp), DIMENSION(3, maxsec, 2:maxcn) :: sec = 0.0_dp + REAL(KIND=dp), DIMENSION(3, maxses, 2:maxsn) :: ses = 0.0_dp + INTEGER, DIMENSION(maxcn) :: nsec = -1 + INTEGER, DIMENSION(maxsn) :: nses = -1 + INTEGER, DIMENSION(:), POINTER :: group_of => NULL(), llequatom => NULL(), nequatom => NULL(), & + symequ_list => NULL(), ulequatom => NULL() END TYPE molsym_type ! ************************************************************************************************** diff --git a/src/motion/integrator_utils.F b/src/motion/integrator_utils.F index f1fa9dceeb..5806028ebd 100644 --- a/src/motion/integrator_utils.F +++ b/src/motion/integrator_utils.F @@ -60,28 +60,28 @@ MODULE integrator_utils ! ************************************************************************************************** TYPE old_variables_type - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: v - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: r - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: eps - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: veps - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: h + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: v => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: r => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: eps => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: veps => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: h => NULL() END TYPE old_variables_type ! ************************************************************************************************** TYPE tmp_variables_type - INTEGER, POINTER :: itimes - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: pos - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: vel - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: shell_pos - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: shell_vel - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: core_pos - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: core_vel - REAL(KIND=dp) :: max_vel, max_vel_sc - REAL(KIND=dp) :: max_dvel, max_dvel_sc - REAL(KIND=dp) :: max_dr, max_dsc - REAL(KIND=dp) :: arg_r(3), arg_v(3), u(3, 3), e_val(3), s, ds - REAL(KIND=dp), DIMENSION(3) :: poly_r, & - poly_v, scale_r, scale_v + INTEGER, POINTER :: itimes => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: pos => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: vel => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: shell_pos => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: shell_vel => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: core_pos => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: core_vel => NULL() + REAL(KIND=dp) :: max_vel = 0.0_dp, max_vel_sc = 0.0_dp + REAL(KIND=dp) :: max_dvel = 0.0_dp, max_dvel_sc = 0.0_dp + REAL(KIND=dp) :: max_dr = 0.0_dp, max_dsc = 0.0_dp + REAL(KIND=dp) :: arg_r(3) = 0.0_dp, arg_v(3) = 0.0_dp, u(3, 3) = 0.0_dp, e_val(3) = 0.0_dp, s = 0.0_dp, ds = 0.0_dp + REAL(KIND=dp), DIMENSION(3) :: poly_r = 0.0_dp, & + poly_v = 0.0_dp, scale_r = 0.0_dp, scale_v = 0.0_dp END TYPE tmp_variables_type INTERFACE set diff --git a/src/mscfg_types.F b/src/mscfg_types.F index aa1f5610c3..729881b269 100644 --- a/src/mscfg_types.F +++ b/src/mscfg_types.F @@ -42,11 +42,11 @@ MODULE mscfg_types TYPE molecular_scf_guess_env_type ! Useful flags to pass around - LOGICAL :: is_fast_dirty, & - is_crystal + LOGICAL :: is_fast_dirty = .FALSE., & + is_crystal = .FALSE. ! Real data - INTEGER :: nfrags + INTEGER :: nfrags = -1 REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: energy_of_frag INTEGER, DIMENSION(:), ALLOCATABLE :: nmosets_of_frag TYPE(dbcsr_type), DIMENSION(:, :), ALLOCATABLE :: mos_of_frag diff --git a/src/negf_atom_map.F b/src/negf_atom_map.F index 1774886556..e7cca13ada 100644 --- a/src/negf_atom_map.F +++ b/src/negf_atom_map.F @@ -37,9 +37,9 @@ MODULE negf_atom_map ! ************************************************************************************************** TYPE negf_atom_map_type !> atomic index within the target FORCE_EVAL - INTEGER :: iatom + INTEGER :: iatom = -1 !> cell replica - INTEGER, DIMENSION(3) :: cell + INTEGER, DIMENSION(3) :: cell = -1 END TYPE negf_atom_map_type PRIVATE :: qs_kind_group_type, qs_kind_groups_create, qs_kind_groups_release @@ -49,11 +49,11 @@ MODULE negf_atom_map ! ************************************************************************************************** TYPE qs_kind_group_type !> atomic symbol - CHARACTER(len=2) :: element_symbol + CHARACTER(len=2) :: element_symbol = "" !> number of atoms of this kind in 'atom_list' - INTEGER :: natoms + INTEGER :: natoms = -1 !> number of spherical Gaussian functions per atom - INTEGER :: nsgf + INTEGER :: nsgf = -1 !> list of atomic indices INTEGER, ALLOCATABLE, DIMENSION(:) :: atom_list !> atomic coordinates [3 x natoms] diff --git a/src/negf_control_types.F b/src/negf_control_types.F index bd205c57a8..26d5fa8d09 100644 --- a/src/negf_control_types.F +++ b/src/negf_control_types.F @@ -51,18 +51,18 @@ MODULE negf_control_types TYPE(negf_allocatable_ivector), ALLOCATABLE, & DIMENSION(:) :: atomlist_cell !> index of the sub_force_env which should be used for bulk calculation - INTEGER :: force_env_index + INTEGER :: force_env_index = -1 !> contact Fermi level needs to be computed prior NEGF run - LOGICAL :: compute_fermi_level + LOGICAL :: compute_fermi_level = .FALSE. !> when computing contact Fermi level, use the energy given in 'fermi_level' (instead of HOMO) !> (instead of the HOMO energy) as a starting point - LOGICAL :: refine_fermi_level + LOGICAL :: refine_fermi_level = .FALSE. !> Fermi level - REAL(kind=dp) :: fermi_level + REAL(kind=dp) :: fermi_level = -1.0_dp !> temperature [in a.u.] - REAL(kind=dp) :: temperature + REAL(kind=dp) :: temperature = -1.0_dp !> applied electric potential - REAL(kind=dp) :: v_external + REAL(kind=dp) :: v_external = 0.0_dp END TYPE negf_control_contact_type ! ************************************************************************************************** @@ -79,43 +79,43 @@ MODULE negf_control_types !> screening regions of all the contacts INTEGER, ALLOCATABLE, DIMENSION(:) :: atomlist_S_screening !> do not keep contact self-energy matrices - LOGICAL :: disable_cache + LOGICAL :: disable_cache = .FALSE. !> convergence criteria for adaptive integration methods - REAL(kind=dp) :: conv_density + REAL(kind=dp) :: conv_density = -1.0_dp !> convergence criteria for iterative Lopez-Sancho algorithm - REAL(kind=dp) :: conv_green + REAL(kind=dp) :: conv_green = -1.0_dp !> convergence criteria for self-consistent iterations - REAL(kind=dp) :: conv_scf + REAL(kind=dp) :: conv_scf = -1.0_dp !> accuracy in mapping atoms between different force environments - REAL(kind=dp) :: eps_geometry + REAL(kind=dp) :: eps_geometry = -1.0_dp !> applied bias [in a.u.] - REAL(kind=dp) :: v_bias + REAL(kind=dp) :: v_bias = -1.0_dp !> integration lower bound [in a.u.] - REAL(kind=dp) :: energy_lbound + REAL(kind=dp) :: energy_lbound = -1.0_dp !> infinitesimal offset along the imaginary axis [in a.u.] - REAL(kind=dp) :: eta + REAL(kind=dp) :: eta = -1.0_dp !> initial guess to determine the actual Fermi level of bulk contacts [in a.u.] - REAL(kind=dp) :: homo_lumo_gap + REAL(kind=dp) :: homo_lumo_gap = -1.0_dp !> number of residuals (poles of the Fermi function) - INTEGER :: delta_npoles + INTEGER :: delta_npoles = -1 !> offset along the x-axis away from the poles of the Fermi function [in units of kT] - INTEGER :: gamma_kT + INTEGER :: gamma_kT = -1 !> integration method - INTEGER :: integr_method + INTEGER :: integr_method = -1 !> minimal number of grid points along the closed contour - INTEGER :: integr_min_points + INTEGER :: integr_min_points = -1 !> maximal number of grid points along the closed contour - INTEGER :: integr_max_points + INTEGER :: integr_max_points = -1 !> maximal number of SCF iterations - INTEGER :: max_scf + INTEGER :: max_scf = -1 !> minimal number of MPI processes to be used to compute Green's function per energy point - INTEGER :: nprocs + INTEGER :: nprocs = -1 !> shift in Hartree potential [in a.u.] - REAL(kind=dp) :: v_shift + REAL(kind=dp) :: v_shift = -1.0_dp !> initial offset to determine the correct shift in Hartree potential [in a.u.] - REAL(kind=dp) :: v_shift_offset + REAL(kind=dp) :: v_shift_offset = -1.0_dp !> maximal number of iteration to determine the shift in Hartree potential - INTEGER :: v_shift_maxiters + INTEGER :: v_shift_maxiters = -1 END TYPE negf_control_type PRIVATE :: read_negf_atomlist diff --git a/src/negf_env_types.F b/src/negf_env_types.F index 4e0c391271..599c5bc52b 100644 --- a/src/negf_env_types.F +++ b/src/negf_env_types.F @@ -85,11 +85,11 @@ MODULE negf_env_types !> \author Sergey Chulkov ! ************************************************************************************************** TYPE negf_env_contact_type - REAL(kind=dp), DIMENSION(3) :: direction_vector, origin - REAL(kind=dp), DIMENSION(3) :: direction_vector_bias, origin_bias + REAL(kind=dp), DIMENSION(3) :: direction_vector = -1.0_dp, origin = -1.0_dp + REAL(kind=dp), DIMENSION(3) :: direction_vector_bias = -1.0_dp, origin_bias = -1.0_dp !> an axis towards the secondary contact unit cell which coincides with the transport direction !> 0 (undefined), 1 (+x), 2 (+y), 3 (+z), -1 (-x), -2 (-y), -3 (-z) - INTEGER :: direction_axis + INTEGER :: direction_axis = -1 !> atoms belonging to a primary contact unit cell INTEGER, ALLOCATABLE, DIMENSION(:) :: atomlist_cell0 !> atoms belonging to a secondary contact unit cell (will be removed one day ...) @@ -98,7 +98,7 @@ MODULE negf_env_types TYPE(negf_atom_map_type), ALLOCATABLE, & DIMENSION(:) :: atom_map_cell0, atom_map_cell1 !> energy of the HOMO - REAL(kind=dp) :: homo_energy + REAL(kind=dp) :: homo_energy = -1.0_dp !> diagonal (h_00) and off-diagonal (h_01) blocks of the contact Kohn-Sham matrix ([number_of_spins]). !> The matrix h_01 is of the shape [nao_cell0 x nao_cell1] TYPE(cp_fm_type), ALLOCATABLE, DIMENSION(:) :: h_00, h_01 @@ -127,9 +127,9 @@ MODULE negf_env_types !> overlap matrix of the scattering region -- contact interface for every contact ([ncontacts]) TYPE(cp_fm_type), ALLOCATABLE, DIMENSION(:) :: s_sc !> structure needed for density mixing - TYPE(mixing_storage_type), POINTER :: mixing_storage + TYPE(mixing_storage_type), POINTER :: mixing_storage => NULL() !> density mixing method - INTEGER :: mixing_method + INTEGER :: mixing_method = -1 END TYPE negf_env_type ! ************************************************************************************************** diff --git a/src/negf_green_methods.F b/src/negf_green_methods.F index 18aa0da257..666fbdb544 100644 --- a/src/negf_green_methods.F +++ b/src/negf_green_methods.F @@ -45,21 +45,21 @@ MODULE negf_green_methods TYPE sancho_work_matrices_type ! A_{n+1} = A_n + D_n + E_n - TYPE(cp_cfm_type), POINTER :: a + TYPE(cp_cfm_type), POINTER :: a => NULL() ! A0_{n+1} = A0_n + D_n - TYPE(cp_cfm_type), POINTER :: a0 + TYPE(cp_cfm_type), POINTER :: a0 => NULL() ! A_inv = A^-1 - TYPE(cp_cfm_type), POINTER :: a_inv + TYPE(cp_cfm_type), POINTER :: a_inv => NULL() ! B_{n+1} = - B_n A_n^-1 B_n \equiv B_n A_n^-1 B_n - TYPE(cp_cfm_type), POINTER :: b + TYPE(cp_cfm_type), POINTER :: b => NULL() ! C_{n+1} = - C_n A_n^-1 C_n \equiv C_n A_n^-1 C_n - TYPE(cp_cfm_type), POINTER :: c + TYPE(cp_cfm_type), POINTER :: c => NULL() ! D_n = - B_n A_n^-1 C_n - TYPE(cp_cfm_type), POINTER :: d + TYPE(cp_cfm_type), POINTER :: d => NULL() ! E_n = - C_n A_n^-1 B_n - TYPE(cp_cfm_type), POINTER :: e + TYPE(cp_cfm_type), POINTER :: e => NULL() ! a scratch area for matrix multiplication - TYPE(cp_cfm_type), POINTER :: scratch + TYPE(cp_cfm_type), POINTER :: scratch => NULL() END TYPE sancho_work_matrices_type CONTAINS diff --git a/src/negf_integr_cc.F b/src/negf_integr_cc.F index 0f613fdede..810ecc9224 100644 --- a/src/negf_integr_cc.F +++ b/src/negf_integr_cc.F @@ -31,7 +31,8 @@ MODULE negf_integr_cc USE kahan_sum, ONLY: accurate_sum USE kinds, ONLY: dp,& int_8 - USE mathconstants, ONLY: z_one + USE mathconstants, ONLY: z_one,& + z_zero USE negf_integr_utils, ONLY: contour_shape_arc,& contour_shape_linear,& equidistant_nodes_a_b,& @@ -64,23 +65,23 @@ MODULE negf_integr_cc ! ************************************************************************************************** TYPE ccquad_type !> integration lower and upper bounds - COMPLEX(kind=dp) :: a, b + COMPLEX(kind=dp) :: a = z_zero, b = z_zero !> integration interval: !> cc_interval_full -- [a .. b], !> grid density: 'a' .. . . . . . .. 'b'; !> cc_interval_half -- [a .. 2b-a], assuming int_{b}^{2b-a} f(x) dx = 0, !> grid density: 'a' .. . . . 'b' - INTEGER :: interval_id + INTEGER :: interval_id = -1 !> integration shape - INTEGER :: shape_id + INTEGER :: shape_id = -1 !> estimated error - REAL(kind=dp) :: error + REAL(kind=dp) :: error = -1.0_dp !> approximate integral value - TYPE(cp_cfm_type), POINTER :: integral + TYPE(cp_cfm_type), POINTER :: integral => NULL() !> error estimate for every element of the 'integral' matrix - TYPE(cp_fm_type), POINTER :: error_fm + TYPE(cp_fm_type), POINTER :: error_fm => NULL() !> weights associated with matrix elements; the 'error' variable contains the value Trace(error_fm * weights) - TYPE(cp_fm_type), POINTER :: weights + TYPE(cp_fm_type), POINTER :: weights => NULL() !> integrand value at grid points. Due to symmetry of Clenshaw-Curtis quadratures, !> we only need to keep the left half-interval TYPE(cp_cfm_type), ALLOCATABLE, DIMENSION(:) :: zdata_cache diff --git a/src/negf_integr_simpson.F b/src/negf_integr_simpson.F index 7112bb47d3..401408d4a9 100644 --- a/src/negf_integr_simpson.F +++ b/src/negf_integr_simpson.F @@ -54,13 +54,14 @@ MODULE negf_integr_simpson ! ************************************************************************************************** TYPE simpsonrule_subinterval_type !> unscaled lower and upper boundaries within the interval [-1 .. 1] - REAL(kind=dp) :: lb, ub + REAL(kind=dp) :: lb = -1.0_dp, ub = -1.0_dp !> target accuracy for this sub-interval - REAL(kind=dp) :: conv + REAL(kind=dp) :: conv = -1.0_dp !> estimated error value on this sub-interval - REAL(kind=dp) :: error + REAL(kind=dp) :: error = -1.0_dp !> integrand values at equally spaced points [a, b, c, d, e] located on the curve shape([lb .. ub]) - TYPE(cp_cfm_type) :: fa, fb, fc, fd, fe + TYPE(cp_cfm_type) :: fa = cp_cfm_type(), fb = cp_cfm_type(), fc = cp_cfm_type(), & + fd = cp_cfm_type(), fe = cp_cfm_type() END TYPE simpsonrule_subinterval_type ! ************************************************************************************************** @@ -68,24 +69,24 @@ MODULE negf_integr_simpson ! ************************************************************************************************** TYPE simpsonrule_type !> lower and upper boundaries of the curve on the complex plane - COMPLEX(kind=dp) :: a, b + COMPLEX(kind=dp) :: a = z_zero, b = z_zero !> ID number which determines the shape of a curve along which the integral will be evaluated - INTEGER :: shape_id + INTEGER :: shape_id = -1 !> target accuracy - REAL(kind=dp) :: conv + REAL(kind=dp) :: conv = -1.0_dp !> estimated error value on the entire integration interval, !> as well as on converged sub-intervals only - REAL(kind=dp) :: error, error_conv + REAL(kind=dp) :: error = -1.0_dp, error_conv = -1.0_dp !> the estimated value of the integral on the entire interval - TYPE(cp_cfm_type), POINTER :: integral + TYPE(cp_cfm_type), POINTER :: integral => NULL() !> work matrix to store the contribution to the integral on converged sub-intervals - TYPE(cp_cfm_type), POINTER :: integral_conv + TYPE(cp_cfm_type), POINTER :: integral_conv => NULL() !> work matrices which stores approximated integral computed by using a/b/c, c/d/e, and a/c/e points respectively - TYPE(cp_cfm_type), POINTER :: integral_abc, integral_cde, integral_ace + TYPE(cp_cfm_type), POINTER :: integral_abc => NULL(), integral_cde => NULL(), integral_ace => NULL() !> work matrix to temporarily store error estimate of the integral on a sub-interval for every matrix element - TYPE(cp_fm_type), POINTER :: error_fm + TYPE(cp_fm_type), POINTER :: error_fm => NULL() !> weights associated with matrix elements; the final error is computed as Trace(error_fm * weights) - TYPE(cp_fm_type), POINTER :: weights + TYPE(cp_fm_type), POINTER :: weights => NULL() ! non-converged sub-intervals TYPE(simpsonrule_subinterval_type), ALLOCATABLE, & DIMENSION(:) :: subintervals diff --git a/src/negf_methods.F b/src/negf_methods.F index 207b878b00..e309f4fa5c 100644 --- a/src/negf_methods.F +++ b/src/negf_methods.F @@ -140,8 +140,8 @@ MODULE negf_methods !> \author Sergey Chulkov ! ************************************************************************************************** TYPE integration_status_type - INTEGER :: npoints - REAL(kind=dp) :: error + INTEGER :: npoints = -1 + REAL(kind=dp) :: error = -1.0_dp END TYPE integration_status_type CONTAINS @@ -265,7 +265,6 @@ SUBROUTINE do_negf(force_env) END DO IF (ncontacts > 1) THEN - NULLIFY (qs_env) CALL force_env_get(force_env, qs_env=qs_env) CALL shift_potential(negf_env, negf_control, sub_env, qs_env, base_contact=1, log_unit=log_unit) @@ -1309,7 +1308,6 @@ SUBROUTINE negf_surface_green_function_batch(g_surf, omega, h0, s0, h1, s1, sub_ CALL timeset(routineN, handle) npoints = SIZE(omega) - NULLIFY (fm_struct) CALL cp_fm_get_info(s0, matrix_struct=fm_struct) CALL sancho_work_matrices_create(work, fm_struct) diff --git a/src/nnp_environment_types.F b/src/nnp_environment_types.F index f06623d552..679edc0d4a 100644 --- a/src/nnp_environment_types.F +++ b/src/nnp_environment_types.F @@ -85,32 +85,32 @@ MODULE nnp_environment_types TYPE(nnp_acsf_ang_type), DIMENSION(:), POINTER :: ang => NULL() ! DIM(n_ele) INTEGER, DIMENSION(:), ALLOCATABLE :: n_rad ! # radial symfnct for this element INTEGER, DIMENSION(:), ALLOCATABLE :: n_ang ! # angular symfnct for this element - INTEGER :: n_ele ! # elements + INTEGER :: n_ele = -1 ! # elements CHARACTER(len=2), ALLOCATABLE, DIMENSION(:) :: ele ! elements(n_ele) INTEGER, ALLOCATABLE, DIMENSION(:) :: nuc_ele ! elements(n_ele) - LOGICAL :: scale_acsf - LOGICAL :: scale_sigma_acsf - LOGICAL :: center_acsf - LOGICAL :: normnodes - INTEGER :: n_radgrp - INTEGER :: n_anggrp - INTEGER :: cut_type ! cutofftype - REAL(KIND=dp) :: eshortmin - REAL(KIND=dp) :: eshortmax - REAL(KIND=dp) :: scmax !scale - REAL(KIND=dp) :: scmin !scale - REAL(KIND=dp) :: max_cut !largest cutoff + LOGICAL :: scale_acsf = .FALSE. + LOGICAL :: scale_sigma_acsf = .FALSE. + LOGICAL :: center_acsf = .FALSE. + LOGICAL :: normnodes = .FALSE. + INTEGER :: n_radgrp = -1 + INTEGER :: n_anggrp = -1 + INTEGER :: cut_type = -1 ! cutofftype + REAL(KIND=dp) :: eshortmin = -1.0_dp + REAL(KIND=dp) :: eshortmax = -1.0_dp + REAL(KIND=dp) :: scmax = -1.0_dp !scale + REAL(KIND=dp) :: scmin = -1.0_dp !scale + REAL(KIND=dp) :: max_cut = -1.0_dp !largest cutoff REAL(KIND=dp), ALLOCATABLE, DIMENSION(:) :: atom_energies !DIM(n_ele) TYPE(nnp_arc_type), POINTER, DIMENSION(:) :: arc => NULL() ! DIM(n_ele) - INTEGER :: n_committee - INTEGER :: n_hlayer - INTEGER :: n_layer + INTEGER :: n_committee = -1 + INTEGER :: n_hlayer = -1 + INTEGER :: n_layer = -1 INTEGER, ALLOCATABLE, DIMENSION(:) :: n_hnodes INTEGER, ALLOCATABLE, DIMENSION(:) :: actfnct - INTEGER :: expol ! extrapolation coutner - LOGICAL :: output_expol ! output extrapolation + INTEGER :: expol = -1 ! extrapolation coutner + LOGICAL :: output_expol = .FALSE. ! output extrapolation ! structures for calculation - INTEGER :: num_atoms + INTEGER :: num_atoms = -1 REAL(KIND=dp), ALLOCATABLE, DIMENSION(:, :) :: atomic_energy REAL(KIND=dp), ALLOCATABLE, DIMENSION(:) :: committee_energy INTEGER, ALLOCATABLE, DIMENSION(:) :: ele_ind, nuc_atoms, sort, sort_inv @@ -120,7 +120,7 @@ MODULE nnp_environment_types CHARACTER(len=default_string_length), & ALLOCATABLE, DIMENSION(:) :: atoms REAL(KIND=dp), DIMENSION(:, :), ALLOCATABLE :: nnp_forces - REAL(KIND=dp) :: nnp_potential_energy + REAL(KIND=dp) :: nnp_potential_energy = -1.0_dp TYPE(cp_subsys_type), POINTER :: subsys => NULL() TYPE(section_vals_type), POINTER :: nnp_input => NULL() TYPE(section_vals_type), POINTER :: force_env_input => NULL() @@ -128,12 +128,12 @@ MODULE nnp_environment_types TYPE(cell_type), POINTER :: cell_ref => NULL() LOGICAL :: use_ref_cell = .FALSE. ! bias - LOGICAL :: bias - LOGICAL :: bias_align - REAL(KIND=dp) :: bias_energy - REAL(KIND=dp) :: bias_kb - REAL(KIND=dp) :: bias_sigma0 - REAL(KIND=dp) :: bias_sigma + LOGICAL :: bias = .FALSE. + LOGICAL :: bias_align = .FALSE. + REAL(KIND=dp) :: bias_energy = -1.0_dp + REAL(KIND=dp) :: bias_kb = -1.0_dp + REAL(KIND=dp) :: bias_sigma0 = -1.0_dp + REAL(KIND=dp) :: bias_sigma = -1.0_dp REAL(KIND=dp), DIMENSION(:, :), ALLOCATABLE :: bias_forces REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: bias_e_avrg END TYPE nnp_type @@ -148,11 +148,11 @@ MODULE nnp_environment_types !> \date 2020-10-10 ! ************************************************************************************************** TYPE nnp_symfgrp_type - INTEGER :: n_symf + INTEGER :: n_symf = -1 INTEGER, DIMENSION(:), ALLOCATABLE :: symf INTEGER, DIMENSION(:), ALLOCATABLE :: ele_ind CHARACTER(LEN=2), DIMENSION(:), ALLOCATABLE :: ele - REAL(KIND=dp) :: cutoff + REAL(KIND=dp) :: cutoff = -1.0_dp END TYPE ! ************************************************************************************************** @@ -181,7 +181,7 @@ MODULE nnp_environment_types REAL(KIND=dp), ALLOCATABLE, DIMENSION(:) :: sigma CHARACTER(len=2), ALLOCATABLE, DIMENSION(:) :: ele INTEGER, ALLOCATABLE, DIMENSION(:) :: nuc_ele - INTEGER :: n_symfgrp + INTEGER :: n_symfgrp = -1 TYPE(nnp_symfgrp_type), DIMENSION(:), ALLOCATABLE :: symfgrp END TYPE @@ -216,7 +216,7 @@ MODULE nnp_environment_types CHARACTER(len=2), ALLOCATABLE, DIMENSION(:) :: ele2 INTEGER, ALLOCATABLE, DIMENSION(:) :: nuc_ele1 INTEGER, ALLOCATABLE, DIMENSION(:) :: nuc_ele2 - INTEGER :: n_symfgrp + INTEGER :: n_symfgrp = -1 TYPE(nnp_symfgrp_type), DIMENSION(:), ALLOCATABLE :: symfgrp END TYPE @@ -228,7 +228,7 @@ MODULE nnp_environment_types !> \date 2020-10-10 ! ************************************************************************************************** TYPE nnp_neighbor_type - INTEGER, DIMENSION(3) :: pbc_copies + INTEGER, DIMENSION(3) :: pbc_copies = -1 INTEGER, DIMENSION(:), ALLOCATABLE :: n_rad INTEGER, DIMENSION(:), ALLOCATABLE :: n_ang1 INTEGER, DIMENSION(:), ALLOCATABLE :: n_ang2 @@ -246,7 +246,7 @@ MODULE nnp_environment_types !> \date 2020-10-10 ! ************************************************************************************************** TYPE nnp_arc_type - TYPE(nnp_arc_layer_type), POINTER, DIMENSION(:) :: layer ! DIM(n_layer) + TYPE(nnp_arc_layer_type), POINTER, DIMENSION(:) :: layer => NULL() ! DIM(n_layer) INTEGER, ALLOCATABLE, DIMENSION(:) :: n_nodes END TYPE diff --git a/src/optimize_basis_types.F b/src/optimize_basis_types.F index b9650ea35f..d49025957e 100644 --- a/src/optimize_basis_types.F +++ b/src/optimize_basis_types.F @@ -23,9 +23,9 @@ MODULE optimize_basis_types ! constraint information for a single constraing. boundary is translateed into a fermi function ! like setting as for variational limited case TYPE exp_constraint_type - INTEGER :: const_type - REAL(KIND=dp) :: llim, ulim - REAL(KIND=dp) :: init, var_fac + INTEGER :: const_type = -1 + REAL(KIND=dp) :: llim = -1.0_dp, ulim = -1.0_dp + REAL(KIND=dp) :: init = -1.0_dp, var_fac = -1.0_dp END TYPE ! Subset of a basis+ additional information on what to optimize. @@ -33,8 +33,8 @@ MODULE optimize_basis_types ! opt_* logical whether quantity ahould be optimized ! *_const information for exponents used to constrain them TYPE subset_type - INTEGER :: lmin, lmax, nexp - INTEGER :: n, ncon_tot, nl + INTEGER :: lmin = -1, lmax = -1, nexp = -1 + INTEGER :: n = -1, ncon_tot = -1, nl = -1 INTEGER, DIMENSION(:), ALLOCATABLE :: l REAL(KIND=dp), DIMENSION(:, :), ALLOCATABLE :: coeff LOGICAL, DIMENSION(:, :), ALLOCATABLE :: opt_coeff @@ -49,9 +49,9 @@ MODULE optimize_basis_types ! Top level information for basis sets+ vector subset with the real information TYPE flex_basis_type - CHARACTER(LEN=default_string_length) :: basis_name - INTEGER :: nopt - INTEGER :: nsets + CHARACTER(LEN=default_string_length) :: basis_name = "" + INTEGER :: nopt = -1 + INTEGER :: nsets = -1 TYPE(subset_type), DIMENSION(:), ALLOCATABLE :: subset END TYPE @@ -62,10 +62,10 @@ MODULE optimize_basis_types ! information about how to generate the derived basis sets TYPE derived_basis_info - CHARACTER(LEN=default_string_length) :: basis_name - INTEGER :: reference_set + CHARACTER(LEN=default_string_length) :: basis_name = "" + INTEGER :: reference_set = -1 INTEGER, DIMENSION(:, :), ALLOCATABLE :: remove_contr - INTEGER :: nsets, ncontr + INTEGER :: nsets = -1, ncontr = -1 INTEGER, DIMENSION(:), ALLOCATABLE :: remove_set LOGICAL, DIMENSION(:), ALLOCATABLE :: in_use_set TYPE(use_contr_type), DIMENSION(:), ALLOCATABLE :: use_contr @@ -77,9 +77,9 @@ MODULE optimize_basis_types ! ATTENTION: both vectors go from 0:nbasis_deriv. entry 0 is the one specified ! in the template basis file TYPE kind_basis_type - CHARACTER(LEN=default_string_length) :: basis_name - CHARACTER(LEN=default_string_length) :: element - INTEGER :: nbasis_deriv + CHARACTER(LEN=default_string_length) :: basis_name = "" + CHARACTER(LEN=default_string_length) :: element = "" + INTEGER :: nbasis_deriv = -1 TYPE(derived_basis_info), DIMENSION(:), & ALLOCATABLE :: deriv_info TYPE(flex_basis_type), DIMENSION(:), ALLOCATABLE :: flex_basis @@ -96,27 +96,27 @@ MODULE optimize_basis_types ! ************************************************************************************************** TYPE basis_optimization_type TYPE(comp_group_type), DIMENSION(:), ALLOCATABLE :: comp_group - INTEGER :: ntraining_sets - INTEGER :: ncombinations - LOGICAL :: use_condition_number - INTEGER, DIMENSION(:), POINTER :: group_partition - INTEGER :: n_groups_created + INTEGER :: ntraining_sets = -1 + INTEGER :: ncombinations = -1 + LOGICAL :: use_condition_number = .FALSE. + INTEGER, DIMENSION(:), POINTER :: group_partition => NULL() + INTEGER :: n_groups_created = -1 INTEGER, DIMENSION(:), ALLOCATABLE :: sub_sources INTEGER, DIMENSION(:, :), ALLOCATABLE :: combination REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: fval_weight REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: condition_weight - INTEGER :: nkind - INTEGER :: write_frequency - INTEGER :: nbasis_deriv_types + INTEGER :: nkind = -1 + INTEGER :: write_frequency = -1 + INTEGER :: nbasis_deriv_types = -1 REAL(KIND=dp), DIMENSION(:), ALLOCATABLE :: x_opt - TYPE(opt_state_type) :: powell_param + TYPE(opt_state_type) :: powell_param = opt_state_type() CHARACTER(LEN=default_path_length), DIMENSION(:), ALLOCATABLE :: training_input CHARACTER(LEN=default_path_length), DIMENSION(:), ALLOCATABLE :: training_dir - CHARACTER(LEN=default_path_length) :: work_basis_file - CHARACTER(LEN=default_path_length) :: output_basis_file - CHARACTER(LEN=default_path_length) :: template_basis_file + CHARACTER(LEN=default_path_length) :: work_basis_file = "" + CHARACTER(LEN=default_path_length) :: output_basis_file = "" + CHARACTER(LEN=default_path_length) :: template_basis_file = "" TYPE(kind_basis_type), DIMENSION(:), ALLOCATABLE :: kind_basis - INTEGER :: opt_id + INTEGER :: opt_id = -1 END TYPE CONTAINS diff --git a/src/optimize_input.F b/src/optimize_input.F index 57fd788b8d..21a0b182b3 100644 --- a/src/optimize_input.F +++ b/src/optimize_input.F @@ -54,38 +54,38 @@ MODULE optimize_input PUBLIC :: run_optimize_input TYPE fm_env_type - CHARACTER(LEN=default_path_length) :: optimize_file_name + CHARACTER(LEN=default_path_length) :: optimize_file_name = "" - CHARACTER(LEN=default_path_length) :: ref_traj_file_name - CHARACTER(LEN=default_path_length) :: ref_force_file_name - CHARACTER(LEN=default_path_length) :: ref_cell_file_name + CHARACTER(LEN=default_path_length) :: ref_traj_file_name = "" + CHARACTER(LEN=default_path_length) :: ref_force_file_name = "" + CHARACTER(LEN=default_path_length) :: ref_cell_file_name = "" - INTEGER :: group_size + INTEGER :: group_size = -1 - REAL(KIND=dp) :: energy_weight - REAL(KIND=dp) :: shift_mm - REAL(KIND=dp) :: shift_qm - LOGICAL :: shift_average - INTEGER :: frame_start, frame_stop, frame_stride, frame_count + REAL(KIND=dp) :: energy_weight = -1.0_dp + REAL(KIND=dp) :: shift_mm = -1.0_dp + REAL(KIND=dp) :: shift_qm = -1.0_dp + LOGICAL :: shift_average = .FALSE. + INTEGER :: frame_start = -1, frame_stop = -1, frame_stride = -1, frame_count = -1 END TYPE TYPE variable_type - CHARACTER(LEN=default_string_length) :: label - REAL(KIND=dp) :: value - LOGICAL :: fixed + CHARACTER(LEN=default_string_length) :: label = "" + REAL(KIND=dp) :: value = -1.0_dp + LOGICAL :: fixed = .FALSE. END TYPE TYPE oi_env_type - INTEGER :: method - INTEGER :: seed - CHARACTER(LEN=default_path_length) :: project_name - TYPE(fm_env_type) :: fm_env + INTEGER :: method = -1 + INTEGER :: seed = -1 + CHARACTER(LEN=default_path_length) :: project_name = "" + TYPE(fm_env_type) :: fm_env = fm_env_type() TYPE(variable_type), DIMENSION(:), ALLOCATABLE :: variables - REAL(KIND=dp) :: rhobeg, rhoend - INTEGER :: maxfun - INTEGER :: iter_start_val - REAL(KIND=dp) :: randomize_variables - REAL(KIND=dp) :: start_time, target_time + REAL(KIND=dp) :: rhobeg = -1.0_dp, rhoend = -1.0_dp + INTEGER :: maxfun = -1 + INTEGER :: iter_start_val = -1 + REAL(KIND=dp) :: randomize_variables = -1.0_dp + REAL(KIND=dp) :: start_time = -1.0_dp, target_time = -1.0_dp END TYPE CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'optimize_input' diff --git a/src/outer_scf_control_types.F b/src/outer_scf_control_types.F index eb497c1c9a..2d22f34926 100644 --- a/src/outer_scf_control_types.F +++ b/src/outer_scf_control_types.F @@ -61,30 +61,30 @@ MODULE outer_scf_control_types ! ************************************************************************************************** TYPE outer_scf_control_type - LOGICAL :: have_scf - INTEGER :: max_scf - REAL(KIND=dp) :: eps_scf, step_size - INTEGER :: TYPE - INTEGER :: optimizer - INTEGER :: diis_buffer_length - INTEGER :: extrapolation_order - INTEGER :: bisect_trust_count - TYPE(cdft_opt_type), POINTER :: cdft_opt_control + LOGICAL :: have_scf = .FALSE. + INTEGER :: max_scf = -1 + REAL(KIND=dp) :: eps_scf = -1.0_dp, step_size = -1.0_dp + INTEGER :: TYPE = -1 + INTEGER :: optimizer = -1 + INTEGER :: diis_buffer_length = -1 + INTEGER :: extrapolation_order = -1 + INTEGER :: bisect_trust_count = -1 + TYPE(cdft_opt_type), POINTER :: cdft_opt_control => NULL() END TYPE outer_scf_control_type TYPE qs_outer_scf_type - INTEGER :: iter_count - LOGICAL :: deallocate_jacobian + INTEGER :: iter_count = -1 + LOGICAL :: deallocate_jacobian = .FALSE. ! these are the variable of outer loop. ! right now, we assume that they can be easily written as ! small arrays, but we might want to go the cp_fm_types ! at a later stage ! also, we just store the full iteration history - REAL(KIND=dp), DIMENSION(:), POINTER :: energy - REAL(KIND=dp), DIMENSION(:, :), POINTER :: variables - REAL(KIND=dp), DIMENSION(:, :), POINTER :: gradient - REAL(KIND=dp), DIMENSION(:, :), POINTER :: inv_jacobian - INTEGER, DIMENSION(:), POINTER :: count + REAL(KIND=dp), DIMENSION(:), POINTER :: energy => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: variables => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: gradient => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: inv_jacobian => NULL() + INTEGER, DIMENSION(:), POINTER :: count => NULL() END TYPE qs_outer_scf_type CONTAINS diff --git a/src/pexsi_types.F b/src/pexsi_types.F index 3cea7780fd..af711000ab 100644 --- a/src/pexsi_types.F +++ b/src/pexsi_types.F @@ -93,17 +93,17 @@ MODULE pexsi_types REAL(KIND=dp), DIMENSION(:), POINTER :: kTS => NULL() TYPE(dbcsr_p_type), DIMENSION(:), & POINTER :: matrix_w => NULL() - INTEGER(KIND=C_INTPTR_T) :: plan - INTEGER :: nspin, num_ranks_per_pole - TYPE(mp_comm_type) :: mp_group + INTEGER(KIND=C_INTPTR_T) :: plan = 0_C_INTPTR_T + INTEGER :: nspin = -1, num_ranks_per_pole = -1 + TYPE(mp_comm_type) :: mp_group = mp_comm_type() TYPE(dbcsr_type), DIMENSION(:), & - POINTER :: max_ev_vector + POINTER :: max_ev_vector => NULL() TYPE(dbcsr_type) :: csr_sparsity - INTEGER, DIMENSION(2) :: mp_dims + INTEGER, DIMENSION(2) :: mp_dims = -1 - LOGICAL :: csr_screening, do_adaptive_tol_nel - REAL(KIND=dp) :: adaptive_nel_alpha, adaptive_nel_beta, & - tol_nel_initial, tol_nel_target + LOGICAL :: csr_screening = .FALSE., do_adaptive_tol_nel = .FALSE. + REAL(KIND=dp) :: adaptive_nel_alpha = -1.0_dp, adaptive_nel_beta = -1.0_dp, & + tol_nel_initial = -1.0_dp, tol_nel_target = -1.0_dp END TYPE lib_pexsi_env CONTAINS diff --git a/src/preconditioner_types.F b/src/preconditioner_types.F index 8687fa2060..490cbf460d 100644 --- a/src/preconditioner_types.F +++ b/src/preconditioner_types.F @@ -41,23 +41,23 @@ MODULE preconditioner_types ! ************************************************************************************************** TYPE preconditioner_type ! PRIVATE - TYPE(dbcsr_type), POINTER :: sparse_matrix - TYPE(cp_fm_type), POINTER :: fm - TYPE(dbcsr_type), POINTER :: dbcsr_matrix - TYPE(dbcsr_type), POINTER :: max_ev_vector - TYPE(dbcsr_type), POINTER :: min_ev_vector - TYPE(dbcsr_p_type), POINTER, DIMENSION(:) :: inverse_history - TYPE(mp_para_env_type), POINTER :: para_env - TYPE(cp_blacs_env_type), POINTER :: ctxt - INTEGER :: in_use, solver, ihistory, cholesky_use - REAL(KIND=dp), DIMENSION(:), POINTER :: occ_evals, full_evals - REAL(KIND=dp) :: energy_gap - REAL(KIND=dp) :: condition_num + TYPE(dbcsr_type), POINTER :: sparse_matrix => NULL() + TYPE(cp_fm_type), POINTER :: fm => NULL() + TYPE(dbcsr_type), POINTER :: dbcsr_matrix => NULL() + TYPE(dbcsr_type), POINTER :: max_ev_vector => NULL() + TYPE(dbcsr_type), POINTER :: min_ev_vector => NULL() + TYPE(dbcsr_p_type), POINTER, DIMENSION(:) :: inverse_history => NULL() + TYPE(mp_para_env_type), POINTER :: para_env => NULL() + TYPE(cp_blacs_env_type), POINTER :: ctxt => NULL() + INTEGER :: in_use = -1, solver = -1, ihistory = -1, cholesky_use = -1 + REAL(KIND=dp), DIMENSION(:), POINTER :: occ_evals => NULL(), full_evals => NULL() + REAL(KIND=dp) :: energy_gap = -1.0_dp + REAL(KIND=dp) :: condition_num = -1.0_dp END TYPE preconditioner_type ! ************************************************************************************************** TYPE preconditioner_p_type - TYPE(preconditioner_type), POINTER :: preconditioner + TYPE(preconditioner_type), POINTER :: preconditioner => NULL() END TYPE preconditioner_p_type CONTAINS diff --git a/src/pw/fft/fftw3_lib.F b/src/pw/fft/fftw3_lib.F index f989aa7995..4efcfb9a9a 100644 --- a/src/pw/fft/fftw3_lib.F +++ b/src/pw/fft/fftw3_lib.F @@ -563,8 +563,11 @@ FUNCTION fftw3_is_mkl_wrapper() RESULT(is_mkl) ! If this fails (e.g. for MKL's FFTW3 interface), fall back to the ! FFTW3 threaded 3D transform instead of the hand-optimised version dim_n(1) = 1 + dim_n(2) = 1 dim_istride(1) = 1 + dim_istride(2) = 1 dim_ostride(1) = 1 + dim_ostride(2) = 1 howmany_n(1) = 1 howmany_n(2) = 1 howmany_istride(1) = 1 diff --git a/src/pwdft_environment_types.F b/src/pwdft_environment_types.F index 853b6bd34a..1380e445b3 100644 --- a/src/pwdft_environment_types.F +++ b/src/pwdft_environment_types.F @@ -90,7 +90,7 @@ MODULE pwdft_environment_types CONTAINS ! ************************************************************************************************** -!> \brief Releases the given pwdft environment (see doc/ReferenceCounting.html) +!> \brief Releases the given pwdft environment !> \param pwdft_env The pwdft environment to release !> \par History !> 07.2018 initial create diff --git a/src/qmmm_gaussian_types.F b/src/qmmm_gaussian_types.F index 962768ba9e..6191bd692f 100644 --- a/src/qmmm_gaussian_types.F +++ b/src/qmmm_gaussian_types.F @@ -25,10 +25,10 @@ MODULE qmmm_gaussian_types !> \author Laino Teodoro ! ************************************************************************************************** TYPE qmmm_gaussian_type - INTEGER :: number_of_gaussians - REAL(KIND=dp) :: Elp_Radius, Elp_Radius_Corr - INTEGER, DIMENSION(:), POINTER :: grid_level - REAL(KIND=dp), DIMENSION(:), POINTER :: Ak, Gk + INTEGER :: number_of_gaussians = -1 + REAL(KIND=dp) :: Elp_Radius = -1.0_dp, Elp_Radius_Corr = -1.0_dp + INTEGER, DIMENSION(:), POINTER :: grid_level => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: Ak => NULL(), Gk => NULL() END TYPE qmmm_gaussian_type ! ************************************************************************************************** @@ -40,7 +40,7 @@ MODULE qmmm_gaussian_types !> \author Teodoro Laino ! ************************************************************************************************** TYPE qmmm_gaussian_p_type - TYPE(qmmm_gaussian_type), POINTER :: pgf + TYPE(qmmm_gaussian_type), POINTER :: pgf => NULL() END TYPE qmmm_gaussian_p_type PUBLIC :: qmmm_gaussian_type, & diff --git a/src/qmmm_types_low.F b/src/qmmm_types_low.F index bb2324b55d..983cbc07f7 100644 --- a/src/qmmm_types_low.F +++ b/src/qmmm_types_low.F @@ -66,186 +66,186 @@ MODULE qmmm_types_low !> Teodoro Laino ! ************************************************************************************************** TYPE gridlevel_info_type - INTEGER :: auxbas_grid - INTEGER :: coarser_grid + INTEGER :: auxbas_grid = -1 + INTEGER :: coarser_grid = -1 END TYPE gridlevel_info_type ! ************************************************************************************************** !> \brief Real Space Potential ! ************************************************************************************************** TYPE qmmm_pot_type - REAL(KIND=dp), DIMENSION(:, :), POINTER :: Pot0_2 - REAL(KIND=dp) :: Rmax, Rmin, dx, Rc - INTEGER :: npts - INTEGER, DIMENSION(:), POINTER :: mm_atom_index + REAL(KIND=dp), DIMENSION(:, :), POINTER :: Pot0_2 => NULL() + REAL(KIND=dp) :: Rmax = -1.0_dp, Rmin = -1.0_dp, dx = -1.0_dp, Rc = -1.0_dp + INTEGER :: npts = -1 + INTEGER, DIMENSION(:), POINTER :: mm_atom_index => NULL() END TYPE qmmm_pot_type TYPE qmmm_pot_p_type - TYPE(qmmm_pot_type), POINTER :: pot + TYPE(qmmm_pot_type), POINTER :: pot => NULL() END TYPE qmmm_pot_p_type ! ************************************************************************************************** !> \brief Periodic Potential ! ************************************************************************************************** TYPE qmmm_per_pot_type - REAL(KIND=dp), DIMENSION(:), POINTER :: lg, gx, gy, gz - REAL(KIND=dp) :: Gmax, Fac(3) - INTEGER :: Kmax(3), n_rep_real(3) - INTEGER, DIMENSION(:), POINTER :: mm_atom_index - TYPE(pw_pool_type), POINTER :: pw_pool - TYPE(pw_grid_type), POINTER :: pw_grid - TYPE(pw_r3d_rs_type), POINTER :: TabLR + REAL(KIND=dp), DIMENSION(:), POINTER :: lg => NULL(), gx => NULL(), gy => NULL(), gz => NULL() + REAL(KIND=dp) :: Gmax = -1.0_dp, Fac(3) = -1.0_dp + INTEGER :: Kmax(3) = -1, n_rep_real(3) = -1 + INTEGER, DIMENSION(:), POINTER :: mm_atom_index => NULL() + TYPE(pw_pool_type), POINTER :: pw_pool => NULL() + TYPE(pw_grid_type), POINTER :: pw_grid => NULL() + TYPE(pw_r3d_rs_type), POINTER :: TabLR => NULL() END TYPE qmmm_per_pot_type TYPE qmmm_per_pot_p_type - TYPE(qmmm_per_pot_type), POINTER :: pot + TYPE(qmmm_per_pot_type), POINTER :: pot => NULL() END TYPE qmmm_per_pot_p_type ! ************************************************************************************************** !> \brief LINKs IMOMM ! ************************************************************************************************** TYPE qmmm_imomm_link_type - INTEGER :: qm_index, mm_index - REAL(KIND=dp) :: alpha + INTEGER :: qm_index = -1, mm_index = -1 + REAL(KIND=dp) :: alpha = -1.0_dp END TYPE qmmm_imomm_link_type TYPE qmmm_imomm_link_p_type - TYPE(qmmm_imomm_link_type), POINTER :: link + TYPE(qmmm_imomm_link_type), POINTER :: link => NULL() END TYPE qmmm_imomm_link_p_type ! ************************************************************************************************** !> \brief LINKs PSEUDO ! ************************************************************************************************** TYPE qmmm_pseudo_link_type - INTEGER :: qm_index, mm_index + INTEGER :: qm_index = -1, mm_index = -1 END TYPE qmmm_pseudo_link_type TYPE qmmm_pseudo_link_p_type - TYPE(qmmm_pseudo_link_type), POINTER :: link + TYPE(qmmm_pseudo_link_type), POINTER :: link => NULL() END TYPE qmmm_pseudo_link_p_type ! ************************************************************************************************** !> \brief LINKs summary ! ************************************************************************************************** TYPE qmmm_links_type - TYPE(qmmm_imomm_link_p_type), DIMENSION(:), POINTER :: imomm - TYPE(qmmm_pseudo_link_p_type), DIMENSION(:), POINTER :: pseudo + TYPE(qmmm_imomm_link_p_type), DIMENSION(:), POINTER :: imomm => NULL() + TYPE(qmmm_pseudo_link_p_type), DIMENSION(:), POINTER :: pseudo => NULL() END TYPE qmmm_links_type ! ************************************************************************************************** !> \brief ... ! ************************************************************************************************** TYPE add_env_type - INTEGER :: Index1, Index2 - REAL(KIND=dp) :: alpha + INTEGER :: Index1 = -1, Index2 = -1 + REAL(KIND=dp) :: alpha = -1.0_dp END TYPE add_env_type ! ************************************************************************************************** !> \brief ... ! ************************************************************************************************** TYPE add_set_type - INTEGER :: num_mm_atoms - TYPE(add_env_type), DIMENSION(:), POINTER :: add_env - TYPE(particle_type), DIMENSION(:), POINTER :: added_particles - INTEGER, DIMENSION(:), POINTER :: mm_atom_index - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_atom_chrg - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius_corr - TYPE(qmmm_pot_p_type), DIMENSION(:), POINTER :: Potentials - TYPE(qmmm_per_pot_p_type), DIMENSION(:), POINTER :: Per_Potentials - TYPE(qmmm_gaussian_p_type), DIMENSION(:), POINTER :: pgfs + INTEGER :: num_mm_atoms = -1 + TYPE(add_env_type), DIMENSION(:), POINTER :: add_env => NULL() + TYPE(particle_type), DIMENSION(:), POINTER :: added_particles => NULL() + INTEGER, DIMENSION(:), POINTER :: mm_atom_index => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_atom_chrg => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius_corr => NULL() + TYPE(qmmm_pot_p_type), DIMENSION(:), POINTER :: Potentials => NULL() + TYPE(qmmm_per_pot_p_type), DIMENSION(:), POINTER :: Per_Potentials => NULL() + TYPE(qmmm_gaussian_p_type), DIMENSION(:), POINTER :: pgfs => NULL() END TYPE add_set_type ! ************************************************************************************************** !> \brief parameters for core-shell model potentials ! ************************************************************************************************** TYPE add_shell_type - INTEGER :: num_mm_atoms - TYPE(particle_type), DIMENSION(:), POINTER :: added_particles - TYPE(particle_type), DIMENSION(:), POINTER :: added_cores - INTEGER, DIMENSION(:), POINTER :: mm_core_index - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_core_chrg - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius_corr - TYPE(qmmm_pot_p_type), DIMENSION(:), POINTER :: Potentials - TYPE(qmmm_per_pot_p_type), DIMENSION(:), POINTER :: Per_Potentials - TYPE(qmmm_gaussian_p_type), DIMENSION(:), POINTER :: pgfs + INTEGER :: num_mm_atoms = -1 + TYPE(particle_type), DIMENSION(:), POINTER :: added_particles => NULL() + TYPE(particle_type), DIMENSION(:), POINTER :: added_cores => NULL() + INTEGER, DIMENSION(:), POINTER :: mm_core_index => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_core_chrg => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius_corr => NULL() + TYPE(qmmm_pot_p_type), DIMENSION(:), POINTER :: Potentials => NULL() + TYPE(qmmm_per_pot_p_type), DIMENSION(:), POINTER :: Per_Potentials => NULL() + TYPE(qmmm_gaussian_p_type), DIMENSION(:), POINTER :: pgfs => NULL() END TYPE add_shell_type ! ************************************************************************************************** !> \brief ... ! ************************************************************************************************** TYPE image_charge_type - LOGICAL :: all_mm - LOGICAL :: coeff_iterative - LOGICAL :: image_restart - INTEGER :: state_image_matrix - INTEGER, DIMENSION(:), POINTER :: image_mm_list - TYPE(particle_type), DIMENSION(:), POINTER :: particles_all - REAL(KIND=dp), DIMENSION(:, :), POINTER :: image_forcesMM - REAL(KIND=dp) :: V0 - REAL(KIND=dp) :: eta - INTEGER :: image_matrix_method - TYPE(cp_eri_mme_param) :: eri_mme_param + LOGICAL :: all_mm = .FALSE. + LOGICAL :: coeff_iterative = .FALSE. + LOGICAL :: image_restart = .FALSE. + INTEGER :: state_image_matrix = -1 + INTEGER, DIMENSION(:), POINTER :: image_mm_list => NULL() + TYPE(particle_type), DIMENSION(:), POINTER :: particles_all => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: image_forcesMM => NULL() + REAL(KIND=dp) :: V0 = -1.0_dp + REAL(KIND=dp) :: eta = -1.0_dp + INTEGER :: image_matrix_method = -1 + TYPE(cp_eri_mme_param) :: eri_mme_param = cp_eri_mme_param() END TYPE image_charge_type ! ************************************************************************************************** !> \brief ... ! ************************************************************************************************** TYPE qmmm_env_qm_type - LOGICAL :: center_qm_subsys - LOGICAL :: center_qm_subsys0, do_translate - LOGICAL :: center_qm_subsys_pbc_aware - LOGICAL :: do_force_mixing - LOGICAL :: compatibility - LOGICAL :: qmmm_link - LOGICAL :: move_mm_charges - LOGICAL :: add_mm_charges - LOGICAL :: periodic - LOGICAL :: multipole - LOGICAL :: image_charge - INTEGER :: par_scheme - INTEGER :: qmmm_coupl_type - INTEGER :: num_qm_atoms - INTEGER :: num_mm_atoms - INTEGER :: num_image_mm_atoms - REAL(KIND=dp) :: eps_mm_rspace - REAL(KIND=dp), DIMENSION(3) :: dOmmOqm, utrasl, transl_v - REAL(KIND=dp), DIMENSION(2) :: spherical_cutoff - REAL(KIND=dp), DIMENSION(:), POINTER :: maxradius - INTEGER, DIMENSION(:), POINTER :: qm_atom_index - INTEGER, DIMENSION(:), POINTER :: mm_atom_index - INTEGER, DIMENSION(:), POINTER :: mm_link_atoms - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_atom_chrg - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius_corr - TYPE(qmmm_pot_p_type), DIMENSION(:), POINTER :: Potentials - TYPE(qmmm_per_pot_p_type), DIMENSION(:), POINTER :: Per_Potentials - TYPE(gridlevel_info_type) :: gridlevel_info - TYPE(qmmm_gaussian_p_type), DIMENSION(:), POINTER :: pgfs - TYPE(pw_pool_p_type), DIMENSION(:), POINTER :: aug_pools - TYPE(qmmm_links_type), POINTER :: qmmm_links - TYPE(add_set_type), POINTER :: added_charges - TYPE(add_shell_type), POINTER :: added_shells - TYPE(image_charge_type), POINTER :: image_charge_pot - TYPE(ewald_environment_type), POINTER :: ewald_env - TYPE(ewald_pw_type), POINTER :: ewald_pw + LOGICAL :: center_qm_subsys = .FALSE. + LOGICAL :: center_qm_subsys0 = .FALSE., do_translate = .FALSE. + LOGICAL :: center_qm_subsys_pbc_aware = .FALSE. + LOGICAL :: do_force_mixing = .FALSE. + LOGICAL :: compatibility = .FALSE. + LOGICAL :: qmmm_link = .FALSE. + LOGICAL :: move_mm_charges = .FALSE. + LOGICAL :: add_mm_charges = .FALSE. + LOGICAL :: periodic = .FALSE. + LOGICAL :: multipole = .FALSE. + LOGICAL :: image_charge = .FALSE. + INTEGER :: par_scheme = -1 + INTEGER :: qmmm_coupl_type = -1 + INTEGER :: num_qm_atoms = -1 + INTEGER :: num_mm_atoms = -1 + INTEGER :: num_image_mm_atoms = -1 + REAL(KIND=dp) :: eps_mm_rspace = -1.0_dp + REAL(KIND=dp), DIMENSION(3) :: dOmmOqm = -1.0_dp, utrasl = -1.0_dp, transl_v = -1.0_dp + REAL(KIND=dp), DIMENSION(2) :: spherical_cutoff = -1.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: maxradius => NULL() + INTEGER, DIMENSION(:), POINTER :: qm_atom_index => NULL() + INTEGER, DIMENSION(:), POINTER :: mm_atom_index => NULL() + INTEGER, DIMENSION(:), POINTER :: mm_link_atoms => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_atom_chrg => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_el_pot_radius_corr => NULL() + TYPE(qmmm_pot_p_type), DIMENSION(:), POINTER :: Potentials => NULL() + TYPE(qmmm_per_pot_p_type), DIMENSION(:), POINTER :: Per_Potentials => NULL() + TYPE(gridlevel_info_type) :: gridlevel_info = gridlevel_info_type() + TYPE(qmmm_gaussian_p_type), DIMENSION(:), POINTER :: pgfs => NULL() + TYPE(pw_pool_p_type), DIMENSION(:), POINTER :: aug_pools => NULL() + TYPE(qmmm_links_type), POINTER :: qmmm_links => NULL() + TYPE(add_set_type), POINTER :: added_charges => NULL() + TYPE(add_shell_type), POINTER :: added_shells => NULL() + TYPE(image_charge_type), POINTER :: image_charge_pot => NULL() + TYPE(ewald_environment_type), POINTER :: ewald_env => NULL() + TYPE(ewald_pw_type), POINTER :: ewald_pw => NULL() END TYPE qmmm_env_qm_type ! ************************************************************************************************** !> \brief ... ! ************************************************************************************************** TYPE qmmm_env_mm_type - LOGICAL :: qmmm_link - LOGICAL :: use_qmmm_ff - LOGICAL :: multiple_potential - INTEGER :: qmmm_coupl_type - INTEGER, DIMENSION(:), POINTER :: qm_atom_index - INTEGER, DIMENSION(:), POINTER :: mm_link_atoms - REAL(KIND=dp), DIMENSION(:), POINTER :: mm_link_scale_factor - REAL(KIND=dp), DIMENSION(:), POINTER :: fist_scale_charge_link - INTEGER, DIMENSION(:), POINTER :: qm_molecule_index - TYPE(input_info_type), POINTER :: inp_info + LOGICAL :: qmmm_link = .FALSE. + LOGICAL :: use_qmmm_ff = .FALSE. + LOGICAL :: multiple_potential = .FALSE. + INTEGER :: qmmm_coupl_type = -1 + INTEGER, DIMENSION(:), POINTER :: qm_atom_index => NULL() + INTEGER, DIMENSION(:), POINTER :: mm_link_atoms => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: mm_link_scale_factor => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: fist_scale_charge_link => NULL() + INTEGER, DIMENSION(:), POINTER :: qm_molecule_index => NULL() + TYPE(input_info_type), POINTER :: inp_info => NULL() END TYPE qmmm_env_mm_type CONTAINS diff --git a/src/qs_active_space_methods.F b/src/qs_active_space_methods.F index ab2505b292..625d463d44 100644 --- a/src/qs_active_space_methods.F +++ b/src/qs_active_space_methods.F @@ -161,7 +161,7 @@ MODULE qs_active_space_methods PUBLIC :: active_space_main TYPE, EXTENDS(eri_type_eri_element_func) :: eri_fcidump_print - INTEGER :: unit_nr, bra_start, ket_start + INTEGER :: unit_nr = -1, bra_start = -1, ket_start = -1 CONTAINS PROCEDURE :: func => eri_fcidump_print_func END TYPE diff --git a/src/qs_atomic_block.F b/src/qs_atomic_block.F index 4eff7a4cfa..318f429874 100644 --- a/src/qs_atomic_block.F +++ b/src/qs_atomic_block.F @@ -33,7 +33,7 @@ MODULE qs_atomic_block PUBLIC :: calculate_atomic_block_dm TYPE atom_matrix_type - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: mat + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: mat => NULL() END TYPE atom_matrix_type CONTAINS diff --git a/src/qs_block_davidson_types.F b/src/qs_block_davidson_types.F index 4c090a5416..e914b94194 100644 --- a/src/qs_block_davidson_types.F +++ b/src/qs_block_davidson_types.F @@ -36,11 +36,11 @@ MODULE qs_block_davidson_types block_davidson_env_create, davidson_type TYPE davidson_type - INTEGER :: max_iter, prec_type, solver_type, niter_new_prec, first_prec - LOGICAL :: use_sparse_mos - REAL(KIND=dp) :: conv_percent, energy_gap, eps_iter - TYPE(cp_fm_type), POINTER :: H_block_mat, H_block_vec, & - matrix_z, matrix_pz, S_block_mat, W_block_mat + INTEGER :: max_iter = -1, prec_type = -1, solver_type = -1, niter_new_prec = -1, first_prec = -1 + LOGICAL :: use_sparse_mos = .FALSE. + REAL(KIND=dp) :: conv_percent = -1.0_dp, energy_gap = -1.0_dp, eps_iter = -1.0_dp + TYPE(cp_fm_type), POINTER :: H_block_mat => NULL(), H_block_vec => NULL(), & + matrix_z => NULL(), matrix_pz => NULL(), S_block_mat => NULL(), W_block_mat => NULL() END TYPE davidson_type CONTAINS diff --git a/src/qs_cdft_opt_types.F b/src/qs_cdft_opt_types.F index 9b69b5642b..c26a0a581a 100644 --- a/src/qs_cdft_opt_types.F +++ b/src/qs_cdft_opt_types.F @@ -63,22 +63,22 @@ MODULE qs_cdft_opt_types ! ************************************************************************************************** TYPE cdft_opt_type - LOGICAL :: build_jacobian - LOGICAL :: broyden_update - LOGICAL :: continue_ls - LOGICAL :: jacobian_restart - REAL(KIND=dp) :: newton_step - REAL(KIND=dp) :: newton_step_save - REAL(KIND=dp) :: factor_ls + LOGICAL :: build_jacobian = .FALSE. + LOGICAL :: broyden_update = .FALSE. + LOGICAL :: continue_ls = .FALSE. + LOGICAL :: jacobian_restart = .FALSE. + REAL(KIND=dp) :: newton_step = 0.0_dp + REAL(KIND=dp) :: newton_step_save = 0.0_dp + REAL(KIND=dp) :: factor_ls = 0.0_dp REAL(KIND=dp), DIMENSION(:), & ALLOCATABLE :: jacobian_step REAL(KIND=dp), DIMENSION(:), & - POINTER :: jacobian_vector - INTEGER :: jacobian_type - INTEGER :: broyden_type - INTEGER :: jacobian_freq(2) - INTEGER :: ijacobian(2) - INTEGER :: max_ls + POINTER :: jacobian_vector => NULL() + INTEGER :: jacobian_type = -1 + INTEGER :: broyden_type = -1 + INTEGER :: jacobian_freq(2) = -1 + INTEGER :: ijacobian(2) = -1 + INTEGER :: max_ls = -1 END TYPE cdft_opt_type CONTAINS diff --git a/src/qs_cdft_types.F b/src/qs_cdft_types.F index 156670cd8c..a7d01b19f5 100644 --- a/src/qs_cdft_types.F +++ b/src/qs_cdft_types.F @@ -62,7 +62,7 @@ MODULE qs_cdft_types ! ************************************************************************************************** ! Utility vector container for building becke constraint TYPE becke_vector_buffer - LOGICAL :: store_vectors + LOGICAL :: store_vectors = .FALSE. REAL(kind=dp), ALLOCATABLE, & DIMENSION(:) :: distances REAL(kind=dp), ALLOCATABLE, & @@ -74,23 +74,23 @@ MODULE qs_cdft_types END TYPE becke_vector_buffer TYPE becke_constraint_type - INTEGER :: cavity_shape, cutoff_type, & - confine_bounds(2) - LOGICAL :: in_memory, & - adjust, cavity_confine, & - should_skip, print_cavity, & - use_bohr - REAL(KIND=dp) :: rglobal, & - rcavity, eps_cavity - REAL(KIND=dp), DIMENSION(:), POINTER :: cutoffs, cutoffs_tmp, & - radii_tmp, radii + INTEGER :: cavity_shape = -1, cutoff_type = -1, & + confine_bounds(2) = -1 + LOGICAL :: in_memory = .FALSE., & + adjust = .FALSE., cavity_confine = .FALSE., & + should_skip = .FALSE., print_cavity = .FALSE., & + use_bohr = .FALSE. + REAL(KIND=dp) :: rglobal = -1.0_dp, & + rcavity = -1.0_dp, eps_cavity = -1.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: cutoffs => NULL(), cutoffs_tmp => NULL(), & + radii_tmp => NULL(), radii => NULL() REAL(KIND=dp), POINTER, & - DIMENSION(:, :) :: aij + DIMENSION(:, :) :: aij => NULL() REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :) :: cavity_mat - TYPE(becke_vector_buffer) :: vector_buffer - TYPE(hirshfeld_type), POINTER :: cavity_env - TYPE(pw_r3d_rs_type) :: cavity + DIMENSION(:, :, :) :: cavity_mat => NULL() + TYPE(becke_vector_buffer) :: vector_buffer = becke_vector_buffer() + TYPE(hirshfeld_type), POINTER :: cavity_env => NULL() + TYPE(pw_r3d_rs_type) :: cavity = pw_r3d_rs_type() END TYPE becke_constraint_type ! ************************************************************************************************** @@ -108,11 +108,11 @@ MODULE qs_cdft_types !> \param hirshfeld_env auxiliary type storing information about the Gaussians ! ************************************************************************************************** TYPE hirshfeld_constraint_type - INTEGER :: gaussian_shape, shape_function, atoms_memory - LOGICAL :: use_bohr, print_density, use_atomic_cutoff - REAL(KIND=dp) :: radius, eps_cutoff, atomic_cutoff - REAL(KIND=dp), DIMENSION(:), POINTER :: radii - TYPE(hirshfeld_type), POINTER :: hirshfeld_env + INTEGER :: gaussian_shape = -1, shape_function = -1, atoms_memory = -1 + LOGICAL :: use_bohr = .FALSE., print_density = .FALSE., use_atomic_cutoff = .FALSE. + REAL(KIND=dp) :: radius = -1.0_dp, eps_cutoff = -1.0_dp, atomic_cutoff = -1.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: radii => NULL() + TYPE(hirshfeld_type), POINTER :: hirshfeld_env => NULL() END TYPE hirshfeld_constraint_type ! ************************************************************************************************** @@ -185,77 +185,77 @@ MODULE qs_cdft_types ! To build multiple constraints TYPE cdft_group_type ! Atoms of this constraint group - INTEGER, POINTER, DIMENSION(:) :: atoms + INTEGER, POINTER, DIMENSION(:) :: atoms => NULL() ! Constraint type: charge constraint, magnetization density constraint, or spin channel specific constraint - INTEGER :: constraint_type + INTEGER :: constraint_type = -1 ! Is the constraint fragment based - LOGICAL :: is_fragment_constraint + LOGICAL :: is_fragment_constraint = .FALSE. ! Temporary array holding a component of the weight function gradient that only includes ! terms defined on constraint atoms REAL(kind=dp), ALLOCATABLE, & DIMENSION(:, :) :: d_sum_const_dR ! Coefficients that determine how to sum up the atoms to form the constraint - REAL(KIND=dp), POINTER, DIMENSION(:) :: coeff + REAL(KIND=dp), POINTER, DIMENSION(:) :: coeff => NULL() ! Result of integration dw/dR * rho_r dr where dw/dR is the weight function gradient REAL(KIND=dp), POINTER, & - DIMENSION(:, :) :: integrated + DIMENSION(:, :) :: integrated => NULL() ! Atomic gradients of the weight function at every grid point REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :, :) :: gradients + DIMENSION(:, :, :, :) :: gradients => NULL() REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :, :) :: gradients_x + DIMENSION(:, :, :, :) :: gradients_x => NULL() REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :, :) :: gradients_y + DIMENSION(:, :, :, :) :: gradients_y => NULL() REAL(KIND=dp), POINTER, & - DIMENSION(:, :, :, :) :: gradients_z + DIMENSION(:, :, :, :) :: gradients_z => NULL() ! The weight function of this constraint group - TYPE(pw_r3d_rs_type), POINTER :: weight - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: hw_rho_atomic - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: hw_rho_atomic_dr - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: hw_rho_atomic_charge - TYPE(pw_r3d_rs_type) :: hw_rho_total_constraint - TYPE(pw_r3d_rs_type) :: hw_rho_total + TYPE(pw_r3d_rs_type), POINTER :: weight => NULL() + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: hw_rho_atomic => NULL() + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: hw_rho_atomic_dr => NULL() + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: hw_rho_atomic_charge => NULL() + TYPE(pw_r3d_rs_type) :: hw_rho_total_constraint = pw_r3d_rs_type() + TYPE(pw_r3d_rs_type) :: hw_rho_total = pw_r3d_rs_type() END TYPE cdft_group_type TYPE cdft_control_type - CHARACTER(LEN=default_path_length) :: fragment_a_fname, & - fragment_b_fname, & - fragment_a_spin_fname, & - fragment_b_spin_fname - INTEGER :: ref_count, total_steps, TYPE, & - precond_freq, nreused, max_reuse, & - purge_freq, nbad_conv, purge_offset, & - istep, ienergy, natoms - INTEGER, POINTER, DIMENSION(:) :: atoms - LOGICAL :: need_pot, save_pot, do_et, & - reuse_precond, purge_history, & - should_purge, calculate_metric, & - atomic_charges, fragment_density, & - fragments_integrated, flip_fragment(2), & - transfer_pot, external_control, & - first_iteration, print_weight, in_memory - LOGICAL, POINTER, DIMENSION(:) :: is_constraint - REAL(KIND=dp), DIMENSION(:), POINTER :: strength, TARGET, value + CHARACTER(LEN=default_path_length) :: fragment_a_fname = "", & + fragment_b_fname = "", & + fragment_a_spin_fname = "", & + fragment_b_spin_fname = "" + INTEGER :: ref_count = -1, total_steps = -1, TYPE = -1, & + precond_freq = -1, nreused = -1, max_reuse = -1, & + purge_freq = -1, nbad_conv = -1, purge_offset = -1, & + istep = -1, ienergy = -1, natoms = -1 + INTEGER, POINTER, DIMENSION(:) :: atoms => NULL() + LOGICAL :: need_pot = .FALSE., save_pot = .FALSE., do_et = .FALSE., & + reuse_precond = .FALSE., purge_history = .FALSE., & + should_purge = .FALSE., calculate_metric = .FALSE., & + atomic_charges = .FALSE., fragment_density = .FALSE., & + fragments_integrated = .FALSE., flip_fragment(2) = .FALSE., & + transfer_pot = .FALSE., external_control = .FALSE., & + first_iteration = .FALSE., print_weight = .FALSE., in_memory = .FALSE. + LOGICAL, POINTER, DIMENSION(:) :: is_constraint => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: strength => NULL(), TARGET => NULL(), value => NULL() REAL(KIND=dp), POINTER, & - DIMENSION(:, :) :: charges_fragment - TYPE(becke_constraint_type), POINTER :: becke_control + DIMENSION(:, :) :: charges_fragment => NULL() + TYPE(becke_constraint_type), POINTER :: becke_control => NULL() TYPE(cdft_group_type), POINTER, & - DIMENSION(:) :: group + DIMENSION(:) :: group => NULL() TYPE(cp_1d_r_p_type), ALLOCATABLE, & DIMENSION(:) :: occupations TYPE(cp_fm_type), DIMENSION(:), & - POINTER :: mo_coeff + POINTER :: mo_coeff => NULL() TYPE(dbcsr_p_type) :: matrix_s TYPE(dbcsr_p_type), DIMENSION(:), & - POINTER :: wmat, matrix_p + POINTER :: wmat => NULL(), matrix_p => NULL() TYPE(hirshfeld_constraint_type), & - POINTER :: hirshfeld_control - TYPE(outer_scf_control_type) :: constraint_control, ot_control + POINTER :: hirshfeld_control => NULL() + TYPE(outer_scf_control_type) :: constraint_control = outer_scf_control_type(), ot_control = outer_scf_control_type() TYPE(pw_r3d_rs_type), POINTER, & - DIMENSION(:) :: charge + DIMENSION(:) :: charge => NULL() TYPE(pw_r3d_rs_type), POINTER, & - DIMENSION(:, :) :: fragments - TYPE(qs_outer_scf_type) :: constraint + DIMENSION(:, :) :: fragments => NULL() + TYPE(qs_outer_scf_type) :: constraint = qs_outer_scf_type() END TYPE cdft_control_type CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'qs_cdft_types' diff --git a/src/qs_charges_types.F b/src/qs_charges_types.F index 800f5b8acb..1fb9d654c8 100644 --- a/src/qs_charges_types.F +++ b/src/qs_charges_types.F @@ -39,12 +39,12 @@ MODULE qs_charges_types !> \author Fawzi Mohamed ! ************************************************************************************************** TYPE qs_charges_type - REAL(KIND=dp) :: total_rho_core_rspace, total_rho_gspace - REAL(KIND=dp) :: total_rho0_soft_rspace, total_rho0_hard_lebedev - REAL(KIND=dp) :: total_rho_soft_gspace - REAL(KIND=dp), DIMENSION(:), POINTER :: total_rho1_hard, & - total_rho1_soft - REAL(KIND=dp) :: background + REAL(KIND=dp) :: total_rho_core_rspace = -1.0_dp, total_rho_gspace = -1.0_dp + REAL(KIND=dp) :: total_rho0_soft_rspace = -1.0_dp, total_rho0_hard_lebedev = -1.0_dp + REAL(KIND=dp) :: total_rho_soft_gspace = -1.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: total_rho1_hard => NULL(), & + total_rho1_soft => NULL() + REAL(KIND=dp) :: background = -1.0_dp END TYPE qs_charges_type CONTAINS diff --git a/src/qs_density_mixing_types.F b/src/qs_density_mixing_types.F index 4ddc874488..47cc3d2698 100644 --- a/src/qs_density_mixing_types.F +++ b/src/qs_density_mixing_types.F @@ -49,46 +49,46 @@ MODULE qs_density_mixing_types PUBLIC :: cp_1d_z_p_type, mixing_storage_create, mixing_storage_type, mixing_storage_release, create_mixing_section TYPE cp_1d_z_p_type - COMPLEX(dp), DIMENSION(:), POINTER :: cc + COMPLEX(dp), DIMENSION(:), POINTER :: cc => NULL() END TYPE cp_1d_z_p_type TYPE mixing_storage_type - INTEGER :: ig_max, ncall, ncall_p(2), nbuffer, n_simple_mix, & - nskip_mixing, p_metric_method - INTEGER, POINTER, DIMENSION(:) :: ig_global_index - LOGICAL :: gmix_p - LOGICAL, POINTER, DIMENSION(:) :: paw - CHARACTER(len=15) :: iter_method - REAL(KIND=dp) :: alpha, bconst, beta, broy_w0, & - max_g2, max_gvec_exp, pulay_alpha, & - pulay_beta, r_step, reg_par, & - sigma_max, wc, wmax - REAL(KIND=dp), DIMENSION(:), POINTER :: p_metric - REAL(KIND=dp), DIMENSION(:), POINTER :: kerker_factor - REAL(KIND=dp), DIMENSION(:), POINTER :: special_metric - REAL(KIND=dp), DIMENSION(:, :), POINTER :: weight - REAL(KIND=dp), DIMENSION(:, :), POINTER :: norm_res_buffer - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: fmat, gmat, pulay_matrix, smat + INTEGER :: ig_max = -1, ncall = -1, ncall_p(2) = -1, nbuffer = -1, n_simple_mix = -1, & + nskip_mixing = -1, p_metric_method = -1 + INTEGER, POINTER, DIMENSION(:) :: ig_global_index => NULL() + LOGICAL :: gmix_p = .FALSE. + LOGICAL, POINTER, DIMENSION(:) :: paw => NULL() + CHARACTER(len=15) :: iter_method = "" + REAL(KIND=dp) :: alpha = -1.0_dp, bconst = -1.0_dp, beta = -1.0_dp, broy_w0 = -1.0_dp, & + max_g2 = -1.0_dp, max_gvec_exp = -1.0_dp, pulay_alpha = -1.0_dp, & + pulay_beta = -1.0_dp, r_step = -1.0_dp, reg_par = -1.0_dp, & + sigma_max = -1.0_dp, wc = -1.0_dp, wmax = -1.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: p_metric => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: kerker_factor => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: special_metric => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: weight => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: norm_res_buffer => NULL() + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: fmat => NULL(), gmat => NULL(), pulay_matrix => NULL(), smat => NULL() ! - INTEGER :: nat_local, max_shell - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: acharge - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: dacharge - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: dfbroy - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: ubroy - REAL(KIND=dp), DIMENSION(:, :), POINTER :: abroy - REAL(KIND=dp), DIMENSION(:), POINTER :: wbroy - INTEGER, DIMENSION(:), POINTER :: atlist + INTEGER :: nat_local = -1, max_shell = -1 + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: acharge => NULL() + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: dacharge => NULL() + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: dfbroy => NULL() + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: ubroy => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: abroy => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: wbroy => NULL() + INTEGER, DIMENSION(:), POINTER :: atlist => NULL() ! - TYPE(cp_1d_z_p_type), DIMENSION(:), POINTER :: last_res, rhoin, rhoin_old - TYPE(cp_1d_z_p_type), DIMENSION(:, :), POINTER :: delta_res, u_vec, z_vec - TYPE(cp_1d_z_p_type), DIMENSION(:, :), POINTER :: drho_buffer, rhoin_buffer, res_buffer + TYPE(cp_1d_z_p_type), DIMENSION(:), POINTER :: last_res => NULL(), rhoin => NULL(), rhoin_old => NULL() + TYPE(cp_1d_z_p_type), DIMENSION(:, :), POINTER :: delta_res => NULL(), u_vec => NULL(), z_vec => NULL() + TYPE(cp_1d_z_p_type), DIMENSION(:, :), POINTER :: drho_buffer => NULL(), rhoin_buffer => NULL(), res_buffer => NULL() ! - TYPE(rho_atom_coeff), DIMENSION(:, :), POINTER :: cpc_h_lastres, cpc_s_lastres - TYPE(rho_atom_coeff), DIMENSION(:, :), POINTER :: cpc_h_in, cpc_s_in - TYPE(rho_atom_coeff), DIMENSION(:, :), POINTER :: cpc_h_old, cpc_s_old - TYPE(rho_atom_coeff), DIMENSION(:, :, :), POINTER :: cpc_h_in_buffer, cpc_s_in_buffer - TYPE(rho_atom_coeff), DIMENSION(:, :, :), POINTER :: cpc_h_res_buffer, cpc_s_res_buffer - TYPE(rho_atom_coeff), DIMENSION(:, :, :), POINTER :: dcpc_h_in, dcpc_s_in + TYPE(rho_atom_coeff), DIMENSION(:, :), POINTER :: cpc_h_lastres => NULL(), cpc_s_lastres => NULL() + TYPE(rho_atom_coeff), DIMENSION(:, :), POINTER :: cpc_h_in => NULL(), cpc_s_in => NULL() + TYPE(rho_atom_coeff), DIMENSION(:, :), POINTER :: cpc_h_old => NULL(), cpc_s_old => NULL() + TYPE(rho_atom_coeff), DIMENSION(:, :, :), POINTER :: cpc_h_in_buffer => NULL(), cpc_s_in_buffer => NULL() + TYPE(rho_atom_coeff), DIMENSION(:, :, :), POINTER :: cpc_h_res_buffer => NULL(), cpc_s_res_buffer => NULL() + TYPE(rho_atom_coeff), DIMENSION(:, :, :), POINTER :: dcpc_h_in => NULL(), dcpc_s_in => NULL() END TYPE mixing_storage_type CONTAINS diff --git a/src/qs_dftb_types.F b/src/qs_dftb_types.F index 3197f4fe56..ef84eb5385 100644 --- a/src/qs_dftb_types.F +++ b/src/qs_dftb_types.F @@ -26,46 +26,46 @@ MODULE qs_dftb_types ! ************************************************************************************************** TYPE qs_dftb_atom_type ! PRIVATE - CHARACTER(LEN=default_string_length) :: typ - CHARACTER(LEN=default_string_length) :: name - LOGICAL :: defined - INTEGER :: z !atomic number - REAL(KIND=dp) :: zeff !effective core charge - INTEGER :: natorb !number of orbitals - INTEGER :: lmax !max angular momentum - REAL(KIND=dp), DIMENSION(0:3) :: skself !orbital energy - REAL(KIND=dp), DIMENSION(0:3) :: occupation !free atom occupation - REAL(KIND=dp), DIMENSION(0:3) :: eta !orbital hardness - REAL(KIND=dp) :: energy !free atom energy - REAL(KIND=dp) :: cutoff !cutoff radius for f matrix - REAL(KIND=dp) :: xi, di !London parameter - REAL(KIND=dp) :: rcdisp !cutoff radius for vdW - REAL(KIND=dp) :: dudq !DFTB3 hardness derivative + CHARACTER(LEN=default_string_length) :: typ = "" + CHARACTER(LEN=default_string_length) :: name = "" + LOGICAL :: defined = .FALSE. + INTEGER :: z = -1 !atomic number + REAL(KIND=dp) :: zeff = -1.0_dp !effective core charge + INTEGER :: natorb = -1 !number of orbitals + INTEGER :: lmax = -1 !max angular momentum + REAL(KIND=dp), DIMENSION(0:3) :: skself = -1.0_dp !orbital energy + REAL(KIND=dp), DIMENSION(0:3) :: occupation = -1.0_dp !free atom occupation + REAL(KIND=dp), DIMENSION(0:3) :: eta = -1.0_dp !orbital hardness + REAL(KIND=dp) :: energy = -1.0_dp !free atom energy + REAL(KIND=dp) :: cutoff = -1.0_dp !cutoff radius for f matrix + REAL(KIND=dp) :: xi = -1.0_dp, di = -1.0_dp !London parameter + REAL(KIND=dp) :: rcdisp = -1.0_dp !cutoff radius for vdW + REAL(KIND=dp) :: dudq = -1.0_dp !DFTB3 hardness derivative END TYPE qs_dftb_atom_type ! ************************************************************************************************** TYPE qs_dftb_pairpot_type - REAL(KIND=dp) :: dgrd ! grid spacing - INTEGER :: ngrd ! number of grid points - INTEGER :: ngrdcut ! grid cutoff - INTEGER :: llm ! number of interactions (l,l,m) - INTEGER :: n_urpoly ! order of polynomial - REAL(KIND=dp) :: urep_cut ! cutoff for repulsive pot. - REAL(KIND=dp), DIMENSION(10) :: urep ! coefficients for repulsive + REAL(KIND=dp) :: dgrd = -1.0_dp ! grid spacing + INTEGER :: ngrd = -1 ! number of grid points + INTEGER :: ngrdcut = -1 ! grid cutoff + INTEGER :: llm = -1 ! number of interactions (l,l,m) + INTEGER :: n_urpoly = -1 ! order of polynomial + REAL(KIND=dp) :: urep_cut = -1.0_dp ! cutoff for repulsive pot. + REAL(KIND=dp), DIMENSION(10) :: urep = -1.0_dp ! coefficients for repulsive ! potential in polynomial form - INTEGER :: spdim ! number of points for + INTEGER :: spdim = -1 ! number of points for ! spline representation - REAL(KIND=dp) :: s_cut ! left-hand cutoff - REAL(KIND=dp), DIMENSION(3) :: srep ! coefficients for extrapolation - REAL(KIND=dp), DIMENSION(:, :), POINTER :: spxr ! spline points - REAL(KIND=dp), DIMENSION(:, :), POINTER :: scoeff ! spline coefficients - REAL(KIND=dp), DIMENSION(2) :: surr ! coefficients for last point - REAL(KIND=dp), DIMENSION(:, :), POINTER :: fmat ! Slater-Koster table (Hamiltonian) - REAL(KIND=dp), DIMENSION(:, :), POINTER :: smat ! Slater-Koster table (overlap) + REAL(KIND=dp) :: s_cut = -1.0_dp ! left-hand cutoff + REAL(KIND=dp), DIMENSION(3) :: srep = -1.0_dp ! coefficients for extrapolation + REAL(KIND=dp), DIMENSION(:, :), POINTER :: spxr => NULL() ! spline points + REAL(KIND=dp), DIMENSION(:, :), POINTER :: scoeff => NULL() ! spline coefficients + REAL(KIND=dp), DIMENSION(2) :: surr = -1.0_dp ! coefficients for last point + REAL(KIND=dp), DIMENSION(:, :), POINTER :: fmat => NULL() ! Slater-Koster table (Hamiltonian) + REAL(KIND=dp), DIMENSION(:, :), POINTER :: smat => NULL() ! Slater-Koster table (overlap) ! van der Waals parameter - REAL(KIND=dp) :: xij, dij ! standard LJ parameters - REAL(KIND=dp) :: x0ij ! Evdw(x0) = 0 - REAL(KIND=dp) :: a, b, c ! Short range polynomial coeffs + REAL(KIND=dp) :: xij = -1.0_dp, dij = -1.0_dp ! standard LJ parameters + REAL(KIND=dp) :: x0ij = -1.0_dp ! Evdw(x0) = 0 + REAL(KIND=dp) :: a = -1.0_dp, b = -1.0_dp, c = -1.0_dp ! Short range polynomial coeffs END TYPE qs_dftb_pairpot_type ! *** Public data types *** diff --git a/src/qs_dispersion_pairpot.F b/src/qs_dispersion_pairpot.F index f67f239e11..d7bf98525b 100644 --- a/src/qs_dispersion_pairpot.F +++ b/src/qs_dispersion_pairpot.F @@ -92,10 +92,10 @@ MODULE qs_dispersion_pairpot qs_dispersion_setcn TYPE dcnum_type - INTEGER :: neighbors - INTEGER, DIMENSION(:), POINTER :: nlist - REAL(KIND=dp), DIMENSION(:), POINTER :: dvals - REAL(KIND=dp), DIMENSION(:, :), POINTER :: rik + INTEGER :: neighbors = -1 + INTEGER, DIMENSION(:), POINTER :: nlist => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: dvals => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: rik => NULL() END TYPE dcnum_type PUBLIC :: d3_cnumber, dcnum_type, dcnum_distribute diff --git a/src/qs_dispersion_types.F b/src/qs_dispersion_types.F index 6780db4453..27a3fd0dce 100644 --- a/src/qs_dispersion_types.F +++ b/src/qs_dispersion_types.F @@ -29,88 +29,88 @@ MODULE qs_dispersion_types INTEGER, PARAMETER :: dftd3_pp = 2 TYPE qs_dispersion_type - INTEGER :: TYPE - INTEGER :: pp_type - INTEGER :: nl_type - CHARACTER(LEN=default_string_length) :: ref_functional - REAL(KIND=dp) :: scaling - REAL(KIND=dp) :: rc_disp - REAL(KIND=dp) :: exp_pre - TYPE(section_vals_type), POINTER :: dftd_section - LOGICAL :: verbose !extended output - CHARACTER(LEN=default_string_length) :: parameter_file_name - CHARACTER(LEN=default_string_length) :: kernel_file_name + INTEGER :: TYPE = -1 + INTEGER :: pp_type = -1 + INTEGER :: nl_type = -1 + CHARACTER(LEN=default_string_length) :: ref_functional = "" + REAL(KIND=dp) :: scaling = -1.0_dp + REAL(KIND=dp) :: rc_disp = -1.0_dp + REAL(KIND=dp) :: exp_pre = -1.0_dp + TYPE(section_vals_type), POINTER :: dftd_section => NULL() + LOGICAL :: verbose = .FALSE. !extended output + CHARACTER(LEN=default_string_length) :: parameter_file_name = "" + CHARACTER(LEN=default_string_length) :: kernel_file_name = "" !DFT-D3 global parameters - INTEGER :: max_elem !elements parametrized - INTEGER :: maxc !max coordination number references per element - REAL(KIND=dp) :: k1, k2, k3 !ad hoc parameters - REAL(KIND=dp) :: alp !ad hoc parameters - REAL(KIND=dp) :: s6, s8, sr6 !scaling parameters - REAL(KIND=dp) :: a1, a2 !BJ scaling parameters - REAL(KIND=dp) :: eps_cn - LOGICAL :: doabc !neglect C9 terms - LOGICAL :: c9cnst !use constant c9 terms - LOGICAL :: lrc !calculate a long range correction - LOGICAL :: srb !calculate a short range bond correction - REAL(KIND=dp), DIMENSION(4) :: srb_params ! parameters for SRB (s,g,t1,t2) + INTEGER :: max_elem = -1 !elements parametrized + INTEGER :: maxc = -1 !max coordination number references per element + REAL(KIND=dp) :: k1 = -1.0_dp, k2 = -1.0_dp, k3 = -1.0_dp !ad hoc parameters + REAL(KIND=dp) :: alp = -1.0_dp !ad hoc parameters + REAL(KIND=dp) :: s6 = -1.0_dp, s8 = -1.0_dp, sr6 = -1.0_dp !scaling parameters + REAL(KIND=dp) :: a1 = -1.0_dp, a2 = -1.0_dp !BJ scaling parameters + REAL(KIND=dp) :: eps_cn = -1.0_dp + LOGICAL :: doabc = .FALSE. !neglect C9 terms + LOGICAL :: c9cnst = .FALSE. !use constant c9 terms + LOGICAL :: lrc = .FALSE. !calculate a long range correction + LOGICAL :: srb = .FALSE. !calculate a short range bond correction + REAL(KIND=dp), DIMENSION(4) :: srb_params = -1.0_dp ! parameters for SRB (s,g,t1,t2) TYPE(neighbor_list_set_p_type), & - DIMENSION(:), POINTER :: sab_vdw, sab_cn ! neighborlists for pair interactions + DIMENSION(:), POINTER :: sab_vdw => NULL(), sab_cn => NULL() ! neighborlists for pair interactions REAL(KIND=dp), DIMENSION(:, :, :, :, :), POINTER & - :: c6ab - INTEGER, DIMENSION(:), POINTER :: maxci - REAL(KIND=dp), DIMENSION(:, :), POINTER :: r0ab - REAL(KIND=dp), DIMENSION(:), POINTER :: rcov !covalent radii - REAL(KIND=dp), DIMENSION(:), POINTER :: r2r4 !atomic / values - REAL(KIND=dp), DIMENSION(:), POINTER :: cn !coordination numbers (defaults) + :: c6ab => NULL() + INTEGER, DIMENSION(:), POINTER :: maxci => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: r0ab => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: rcov => NULL() !covalent radii + REAL(KIND=dp), DIMENSION(:), POINTER :: r2r4 => NULL() !atomic / values + REAL(KIND=dp), DIMENSION(:), POINTER :: cn => NULL() !coordination numbers (defaults) TYPE(cn_kind_list), DIMENSION(:), POINTER & - :: cnkind + :: cnkind => NULL() TYPE(cn_atom_list), DIMENSION(:), POINTER & - :: cnlist + :: cnlist => NULL() ! KG molecular corrections - LOGICAL :: domol - REAL(KIND=dp) :: kgc8 !s8 scaling parameter + LOGICAL :: domol = .FALSE. + REAL(KIND=dp) :: kgc8 = -1.0_dp !s8 scaling parameter !vdW-DF variables - REAL(KIND=dp) :: pw_cutoff - REAL(KIND=dp) :: b_value, c_value, scale_rvv10 !parameters for the rVV10 functional - INTEGER :: nqs, nr_points + REAL(KIND=dp) :: pw_cutoff = -1.0_dp + REAL(KIND=dp) :: b_value = -1.0_dp, c_value = -1.0_dp, scale_rvv10 = -1.0_dp !parameters for the rVV10 functional + INTEGER :: nqs = -1, nr_points = -1 !! The number of q points and radial points !! used in generating the kernel phi(q1*r, q2*r) !! (see DION 14-16 and SOLER 3) - REAL(KIND=dp) :: r_max, q_cut, q_min, dk + REAL(KIND=dp) :: r_max = -1.0_dp, q_cut = -1.0_dp, q_min = -1.0_dp, dk = -1.0_dp !! The maximum value of r, the maximum and minimum !! values of q and the k-space spacing of grid points. !! Note that, during a vdW run, values of q0 found !! larger than q_cut will be saturated (SOLER 6-7) to !! q_cut - REAL(KIND=dp), DIMENSION(:), POINTER :: q_mesh !! The values of all the q points used + REAL(KIND=dp), DIMENSION(:), POINTER :: q_mesh => NULL() !! The values of all the q points used REAL(KIND=dp), DIMENSION(:, :, :), POINTER & - :: kernel !! A matrix holding the Fourier transformed kernel function + :: kernel => NULL() !! A matrix holding the Fourier transformed kernel function !! for each pair of q values. The ordering is !! kernel(k_point, q1_value, q2_value) REAL(KIND=dp), DIMENSION(:, :, :), POINTER & - :: d2phi_dk2 !! A matrix holding the second derivatives of the above + :: d2phi_dk2 => NULL() !! A matrix holding the second derivatives of the above !! kernel matrix at each of the q points. Stored as !! d2phi_dk2(k_point, q1_value, q2_value) - REAL(KIND=dp), DIMENSION(:, :), POINTER :: d2y_dx2 !! 2nd derivatives of q_mesh for interpolation - INTEGER, DIMENSION(:, :), POINTER :: d3_exclude_pair - INTEGER :: nd3_exclude_pair + REAL(KIND=dp), DIMENSION(:, :), POINTER :: d2y_dx2 => NULL() !! 2nd derivatives of q_mesh for interpolation + INTEGER, DIMENSION(:, :), POINTER :: d3_exclude_pair => NULL() + INTEGER :: nd3_exclude_pair = -1 END TYPE qs_dispersion_type TYPE qs_atom_dispersion_type - INTEGER :: TYPE - LOGICAL :: defined - REAL(KIND=dp) :: vdw_radii !van der Waals radii - REAL(KIND=dp) :: c6 !c6 coefficients + INTEGER :: TYPE = -1 + LOGICAL :: defined = .FALSE. + REAL(KIND=dp) :: vdw_radii = -1.0_dp !van der Waals radii + REAL(KIND=dp) :: c6 = -1.0_dp !c6 coefficients END TYPE qs_atom_dispersion_type TYPE cn_kind_list - REAL(KIND=dp) :: cnum - INTEGER :: kind + REAL(KIND=dp) :: cnum = -1.0_dp + INTEGER :: kind = -1 END TYPE cn_kind_list TYPE cn_atom_list - REAL(KIND=dp) :: cnum - INTEGER :: natom - INTEGER, DIMENSION(:), POINTER :: atom + REAL(KIND=dp) :: cnum = -1.0_dp + INTEGER :: natom = -1 + INTEGER, DIMENSION(:), POINTER :: atom => NULL() END TYPE cn_atom_list ! ************************************************************************************************** diff --git a/src/qs_energy_types.F b/src/qs_energy_types.F index 3d2a46616e..aae52bb139 100644 --- a/src/qs_energy_types.F +++ b/src/qs_energy_types.F @@ -74,8 +74,8 @@ MODULE qs_energy_types surf_dipole = 0.0_dp, & embed_corr = 0.0_dp, & ! correction for embedding potential xtb_xb_inter = 0.0_dp, & ! correction for halogen bonding within GFN1-xTB - xtb_nonbonded ! correction for nonbonded interactions within GFN1-xTB - REAL(KIND=dp), DIMENSION(:), POINTER :: ddapc_restraint + xtb_nonbonded = 0.0_dp ! correction for nonbonded interactions within GFN1-xTB + REAL(KIND=dp), DIMENSION(:), POINTER :: ddapc_restraint => NULL() END TYPE qs_energy_type ! Public data types diff --git a/src/qs_environment_types.F b/src/qs_environment_types.F index 4c35a643a7..98d8f3d674 100644 --- a/src/qs_environment_types.F +++ b/src/qs_environment_types.F @@ -213,101 +213,101 @@ MODULE qs_environment_types ! ************************************************************************************************** TYPE qs_environment_type - LOGICAL :: qmmm, qmmm_periodic - LOGICAL :: requires_mo_derivs - LOGICAL :: requires_matrix_vxc - LOGICAL :: has_unit_metric - LOGICAL :: run_rtp - LOGICAL :: linres_run - LOGICAL :: calc_image_preconditioner - LOGICAL :: do_transport - LOGICAL :: single_point_run - LOGICAL :: given_embed_pot - LOGICAL :: energy_correction - REAL(KIND=dp) :: sim_time - REAL(KIND=dp) :: start_time, target_time - REAL(KIND=dp), DIMENSION(:, :), POINTER :: image_matrix - REAL(KIND=dp), DIMENSION(:), POINTER :: image_coeff - INTEGER, DIMENSION(:), POINTER :: ipiv - INTEGER :: sim_step - TYPE(ls_scf_env_type), POINTER :: ls_scf_env - TYPE(almo_scf_env_type), POINTER :: almo_scf_env - TYPE(transport_env_type), POINTER :: transport_env - TYPE(cell_type), POINTER :: super_cell - TYPE(mo_set_type), DIMENSION(:), POINTER :: mos - TYPE(cp_fm_type), DIMENSION(:), POINTER :: mo_loc_history - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: mo_derivs - TYPE(scf_control_type), POINTER :: scf_control - TYPE(rel_control_type), POINTER :: rel_control + LOGICAL :: qmmm = .FALSE., qmmm_periodic = .FALSE. + LOGICAL :: requires_mo_derivs = .FALSE. + LOGICAL :: requires_matrix_vxc = .FALSE. + LOGICAL :: has_unit_metric = .FALSE. + LOGICAL :: run_rtp = .FALSE. + LOGICAL :: linres_run = .FALSE. + LOGICAL :: calc_image_preconditioner = .FALSE. + LOGICAL :: do_transport = .FALSE. + LOGICAL :: single_point_run = .FALSE. + LOGICAL :: given_embed_pot = .FALSE. + LOGICAL :: energy_correction = .FALSE. + REAL(KIND=dp) :: sim_time = -1.0_dp + REAL(KIND=dp) :: start_time = -1.0_dp, target_time = -1.0_dp + REAL(KIND=dp), DIMENSION(:, :), POINTER :: image_matrix => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: image_coeff => NULL() + INTEGER, DIMENSION(:), POINTER :: ipiv => NULL() + INTEGER :: sim_step = -1 + TYPE(ls_scf_env_type), POINTER :: ls_scf_env => NULL() + TYPE(almo_scf_env_type), POINTER :: almo_scf_env => NULL() + TYPE(transport_env_type), POINTER :: transport_env => NULL() + TYPE(cell_type), POINTER :: super_cell => NULL() + TYPE(mo_set_type), DIMENSION(:), POINTER :: mos => NULL() + TYPE(cp_fm_type), DIMENSION(:), POINTER :: mo_loc_history => NULL() + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: mo_derivs => NULL() + TYPE(scf_control_type), POINTER :: scf_control => NULL() + TYPE(rel_control_type), POINTER :: rel_control => NULL() ! ZMP adding variables - TYPE(qs_rho_type), POINTER :: rho_external - TYPE(pw_r3d_rs_type), POINTER :: external_vxc - TYPE(pw_r3d_rs_type), POINTER :: mask - TYPE(qs_charges_type), POINTER :: qs_charges - TYPE(qs_ks_env_type), POINTER :: ks_env - TYPE(qs_ks_qmmm_env_type), POINTER :: ks_qmmm_env - TYPE(qmmm_env_qm_type), POINTER :: qmmm_env_qm - TYPE(qs_wf_history_type), POINTER :: wf_history - TYPE(qs_scf_env_type), POINTER :: scf_env - TYPE(qs_matrix_pools_type), POINTER :: mpools - TYPE(oce_matrix_type), POINTER :: oce - TYPE(local_rho_type), POINTER :: local_rho_set - TYPE(hartree_local_type), POINTER :: hartree_local - TYPE(section_vals_type), POINTER :: input - TYPE(linres_control_type), POINTER :: linres_control - TYPE(xas_environment_type), POINTER :: xas_env - TYPE(cp_ddapc_type), POINTER :: cp_ddapc_env - TYPE(cp_ddapc_ewald_type), POINTER :: cp_ddapc_ewald - REAL(KIND=dp), DIMENSION(:, :), POINTER :: outer_scf_history - INTEGER :: outer_scf_ihistory - REAL(KIND=dp), DIMENSION(:, :), POINTER :: gradient_history, & - variable_history - TYPE(hfx_type), DIMENSION(:, :), POINTER :: x_data - TYPE(et_coupling_type), POINTER :: et_coupling - TYPE(qs_dftb_pairpot_type), DIMENSION(:, :), POINTER :: dftb_potential - TYPE(admm_type), POINTER :: admm_env - TYPE(active_space_type), POINTER :: active_space + TYPE(qs_rho_type), POINTER :: rho_external => NULL() + TYPE(pw_r3d_rs_type), POINTER :: external_vxc => NULL() + TYPE(pw_r3d_rs_type), POINTER :: mask => NULL() + TYPE(qs_charges_type), POINTER :: qs_charges => NULL() + TYPE(qs_ks_env_type), POINTER :: ks_env => NULL() + TYPE(qs_ks_qmmm_env_type), POINTER :: ks_qmmm_env => NULL() + TYPE(qmmm_env_qm_type), POINTER :: qmmm_env_qm => NULL() + TYPE(qs_wf_history_type), POINTER :: wf_history => NULL() + TYPE(qs_scf_env_type), POINTER :: scf_env => NULL() + TYPE(qs_matrix_pools_type), POINTER :: mpools => NULL() + TYPE(oce_matrix_type), POINTER :: oce => NULL() + TYPE(local_rho_type), POINTER :: local_rho_set => NULL() + TYPE(hartree_local_type), POINTER :: hartree_local => NULL() + TYPE(section_vals_type), POINTER :: input => NULL() + TYPE(linres_control_type), POINTER :: linres_control => NULL() + TYPE(xas_environment_type), POINTER :: xas_env => NULL() + TYPE(cp_ddapc_type), POINTER :: cp_ddapc_env => NULL() + TYPE(cp_ddapc_ewald_type), POINTER :: cp_ddapc_ewald => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: outer_scf_history => NULL() + INTEGER :: outer_scf_ihistory = -1 + REAL(KIND=dp), DIMENSION(:, :), POINTER :: gradient_history => NULL(), & + variable_history => NULL() + TYPE(hfx_type), DIMENSION(:, :), POINTER :: x_data => NULL() + TYPE(et_coupling_type), POINTER :: et_coupling => NULL() + TYPE(qs_dftb_pairpot_type), DIMENSION(:, :), POINTER :: dftb_potential => NULL() + TYPE(admm_type), POINTER :: admm_env => NULL() + TYPE(active_space_type), POINTER :: active_space => NULL() ! LRI - TYPE(lri_environment_type), POINTER :: lri_env - TYPE(lri_density_type), POINTER :: lri_density + TYPE(lri_environment_type), POINTER :: lri_env => NULL() + TYPE(lri_density_type), POINTER :: lri_density => NULL() ! Energy correction - TYPE(energy_correction_type), POINTER :: ec_env + TYPE(energy_correction_type), POINTER :: ec_env => NULL() ! Excited States - LOGICAL :: excited_state - TYPE(excited_energy_type), POINTER :: exstate_env + LOGICAL :: excited_state = .FALSE. + TYPE(excited_energy_type), POINTER :: exstate_env => NULL() ! Empirical dispersion - TYPE(qs_dispersion_type), POINTER :: dispersion_env + TYPE(qs_dispersion_type), POINTER :: dispersion_env => NULL() ! Empirical geometrical BSSE correction - TYPE(qs_gcp_type), POINTER :: gcp_env + TYPE(qs_gcp_type), POINTER :: gcp_env => NULL() ! Semi-empirical and DFTB types - TYPE(ewald_environment_type), POINTER :: ewald_env - TYPE(ewald_pw_type), POINTER :: ewald_pw + TYPE(ewald_environment_type), POINTER :: ewald_env => NULL() + TYPE(ewald_pw_type), POINTER :: ewald_pw => NULL() ! Semi-empirical types - TYPE(se_taper_type), POINTER :: se_taper - TYPE(semi_empirical_si_type), POINTER :: se_store_int_env - TYPE(nddo_mpole_type), POINTER :: se_nddo_mpole - TYPE(fist_nonbond_env_type), POINTER :: se_nonbond_env - TYPE(rt_prop_type), POINTER :: rtp - TYPE(efield_berry_type), POINTER :: efield + TYPE(se_taper_type), POINTER :: se_taper => NULL() + TYPE(semi_empirical_si_type), POINTER :: se_store_int_env => NULL() + TYPE(nddo_mpole_type), POINTER :: se_nddo_mpole => NULL() + TYPE(fist_nonbond_env_type), POINTER :: se_nonbond_env => NULL() + TYPE(rt_prop_type), POINTER :: rtp => NULL() + TYPE(efield_berry_type), POINTER :: efield => NULL() ! a history for the broyden ot - REAL(KIND=dp) :: broyden_adaptive_sigma + REAL(KIND=dp) :: broyden_adaptive_sigma = -1.0_dp TYPE(mp2_type), POINTER :: mp2_env => NULL() TYPE(post_scf_bandstructure_type), POINTER :: bs_env => NULL() - TYPE(kg_environment_type), POINTER :: kg_env + TYPE(kg_environment_type), POINTER :: kg_env => NULL() TYPE(wannier_centres_type), POINTER, DIMENSION(:) :: WannierCentres => NULL() TYPE(molecular_scf_guess_env_type), POINTER :: molecular_scf_guess_env => NULL() ! Subsystem densities - TYPE(qs_rho_p_type), DIMENSION(:), POINTER :: subsys_dens + TYPE(qs_rho_p_type), DIMENSION(:), POINTER :: subsys_dens => NULL() ! Embedding potential - TYPE(pw_r3d_rs_type), POINTER :: embed_pot - TYPE(pw_r3d_rs_type), POINTER :: spin_embed_pot + TYPE(pw_r3d_rs_type), POINTER :: embed_pot => NULL() + TYPE(pw_r3d_rs_type), POINTER :: spin_embed_pot => NULL() ! Polarizability tensor - TYPE(polar_env_type), POINTER :: polar_env + TYPE(polar_env_type), POINTER :: polar_env => NULL() ! Resp charges REAL(KIND=dp), DIMENSION(:), POINTER :: rhs => NULL() - REAL(KIND=dp) :: total_zeff_corr, surface_dipole_moment - LOGICAL :: surface_dipole_switch_off - TYPE(mo_set_type), DIMENSION(:), POINTER :: mos_last_converged + REAL(KIND=dp) :: total_zeff_corr = -1.0_dp, surface_dipole_moment = -1.0_dp + LOGICAL :: surface_dipole_switch_off = .FALSE. + TYPE(mo_set_type), DIMENSION(:), POINTER :: mos_last_converged => NULL() END TYPE qs_environment_type CONTAINS diff --git a/src/qs_fb_atomic_halo_types.F b/src/qs_fb_atomic_halo_types.F index b9b41f11ae..feaa40aa5c 100644 --- a/src/qs_fb_atomic_halo_types.F +++ b/src/qs_fb_atomic_halo_types.F @@ -78,13 +78,13 @@ MODULE qs_fb_atomic_halo_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_atomic_halo_data - INTEGER :: owner_atom - INTEGER :: owner_id_in_halo - INTEGER :: natoms - INTEGER :: nelectrons - INTEGER, DIMENSION(:), POINTER :: halo_atoms - LOGICAL :: sorted - REAL(KIND=dp) :: cost + INTEGER :: owner_atom = -1 + INTEGER :: owner_id_in_halo = -1 + INTEGER :: natoms = -1 + INTEGER :: nelectrons = -1 + INTEGER, DIMENSION(:), POINTER :: halo_atoms => NULL() + LOGICAL :: sorted = .FALSE. + REAL(KIND=dp) :: cost = -1.0_dp END TYPE fb_atomic_halo_data ! ************************************************************************************************** @@ -92,7 +92,7 @@ MODULE qs_fb_atomic_halo_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_atomic_halo_obj - TYPE(fb_atomic_halo_data), POINTER, PRIVATE :: obj + TYPE(fb_atomic_halo_data), POINTER, PRIVATE :: obj => NULL() END TYPE fb_atomic_halo_obj ! ************************************************************************************************** @@ -104,9 +104,9 @@ MODULE qs_fb_atomic_halo_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_atomic_halo_list_data - INTEGER :: nhalos - INTEGER :: max_nhalos - TYPE(fb_atomic_halo_obj), DIMENSION(:), POINTER :: halos + INTEGER :: nhalos = -1 + INTEGER :: max_nhalos = -1 + TYPE(fb_atomic_halo_obj), DIMENSION(:), POINTER :: halos => NULL() END TYPE fb_atomic_halo_list_data ! ************************************************************************************************** @@ -114,7 +114,7 @@ MODULE qs_fb_atomic_halo_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_atomic_halo_list_obj - TYPE(fb_atomic_halo_list_data), POINTER, PRIVATE :: obj + TYPE(fb_atomic_halo_list_data), POINTER, PRIVATE :: obj => NULL() END TYPE fb_atomic_halo_list_obj CONTAINS diff --git a/src/qs_fb_buffer_types.F b/src/qs_fb_buffer_types.F index a3bf2271ef..8f5e971385 100644 --- a/src/qs_fb_buffer_types.F +++ b/src/qs_fb_buffer_types.F @@ -41,10 +41,10 @@ MODULE qs_fb_buffer_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ********************************************************************** TYPE fb_buffer_i_data - INTEGER :: ref_count - INTEGER :: n - INTEGER, DIMENSION(:), POINTER :: disps - INTEGER, DIMENSION(:), POINTER :: data_1d + INTEGER :: ref_count = -1 + INTEGER :: n = -1 + INTEGER, DIMENSION(:), POINTER :: disps => NULL() + INTEGER, DIMENSION(:), POINTER :: data_1d => NULL() END TYPE fb_buffer_i_data ! ********************************************************************** @@ -68,10 +68,10 @@ MODULE qs_fb_buffer_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ********************************************************************** TYPE fb_buffer_d_data - INTEGER :: ref_count - INTEGER :: n - INTEGER, DIMENSION(:), POINTER :: disps - REAL(KIND=dp), DIMENSION(:), POINTER :: data_1d + INTEGER :: ref_count = -1 + INTEGER :: n = -1 + INTEGER, DIMENSION(:), POINTER :: disps => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: data_1d => NULL() END TYPE fb_buffer_d_data ! ********************************************************************** diff --git a/src/qs_fb_com_tasks_types.F b/src/qs_fb_com_tasks_types.F index f6cf764b0e..fc2aba9ad9 100644 --- a/src/qs_fb_com_tasks_types.F +++ b/src/qs_fb_com_tasks_types.F @@ -96,10 +96,10 @@ MODULE qs_fb_com_tasks_types ! ********************************************************************** TYPE fb_com_tasks_data ! use pure integer arrays to facilitate easier MPI coms - INTEGER(KIND=int_8), DIMENSION(:, :), POINTER :: tasks - INTEGER :: task_dim - INTEGER :: ntasks - INTEGER :: nencode + INTEGER(KIND=int_8), DIMENSION(:, :), POINTER :: tasks => NULL() + INTEGER :: task_dim = -1 + INTEGER :: ntasks = -1 + INTEGER :: nencode = -1 END TYPE fb_com_tasks_data !********************************************************************** @@ -107,7 +107,7 @@ MODULE qs_fb_com_tasks_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk !********************************************************************** TYPE fb_com_tasks_obj - TYPE(fb_com_tasks_data), POINTER, PRIVATE :: obj + TYPE(fb_com_tasks_data), POINTER, PRIVATE :: obj => NULL() END TYPE fb_com_tasks_obj ! ********************************************************************** @@ -126,9 +126,9 @@ MODULE qs_fb_com_tasks_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ********************************************************************** TYPE fb_com_atom_pairs_data - INTEGER(KIND=int_8), DIMENSION(:), POINTER :: pairs - INTEGER :: npairs - INTEGER :: natoms_encode + INTEGER(KIND=int_8), DIMENSION(:), POINTER :: pairs => NULL() + INTEGER :: npairs = -1 + INTEGER :: natoms_encode = -1 END TYPE fb_com_atom_pairs_data ! ********************************************************************** @@ -136,7 +136,7 @@ MODULE qs_fb_com_tasks_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ********************************************************************** TYPE fb_com_atom_pairs_obj - TYPE(fb_com_atom_pairs_data), POINTER, PRIVATE :: obj + TYPE(fb_com_atom_pairs_data), POINTER, PRIVATE :: obj => NULL() END TYPE fb_com_atom_pairs_obj CONTAINS diff --git a/src/qs_fb_distribution_methods.F b/src/qs_fb_distribution_methods.F index eb3776e21c..3828eec6b4 100644 --- a/src/qs_fb_distribution_methods.F +++ b/src/qs_fb_distribution_methods.F @@ -51,8 +51,8 @@ MODULE qs_fb_distribution_methods !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_distribution_element - INTEGER :: id - REAL(KIND=dp) :: cost + INTEGER :: id = -1 + REAL(KIND=dp) :: cost = -1.0_dp END TYPE fb_distribution_element ! ************************************************************************************************** @@ -64,8 +64,8 @@ MODULE qs_fb_distribution_methods ! ************************************************************************************************** TYPE fb_distribution_list TYPE(fb_distribution_element), DIMENSION(:), POINTER :: list => NULL() - INTEGER :: nelements - REAL(KIND=dp) :: cost + INTEGER :: nelements = -1 + REAL(KIND=dp) :: cost = -1.0_dp END TYPE fb_distribution_list ! ************************************************************************************************** @@ -86,7 +86,7 @@ MODULE qs_fb_distribution_methods ! ************************************************************************************************** TYPE fb_preferred_procs_list INTEGER, DIMENSION(:), POINTER :: list => NULL() - INTEGER :: nprocs + INTEGER :: nprocs = -1 END TYPE fb_preferred_procs_list ! Parameters related to automatic resizing of the hash_table: diff --git a/src/qs_fb_env_types.F b/src/qs_fb_env_types.F index 53ba91d838..cc02ba9824 100644 --- a/src/qs_fb_env_types.F +++ b/src/qs_fb_env_types.F @@ -65,16 +65,16 @@ MODULE qs_fb_env_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ********************************************************************** TYPE fb_env_data - INTEGER :: ref_count - REAL(KIND=dp), DIMENSION(:), POINTER :: rcut - TYPE(fb_atomic_halo_list_obj) :: atomic_halos - TYPE(fb_trial_fns_obj) :: trial_fns - REAL(KIND=dp) :: filter_temperature - REAL(KIND=dp) :: auto_cutoff_scale - REAL(KIND=dp) :: eps_default - LOGICAL :: collective_com - INTEGER, DIMENSION(:), POINTER :: local_atoms - INTEGER :: nlocal_atoms + INTEGER :: ref_count = -1 + REAL(KIND=dp), DIMENSION(:), POINTER :: rcut => NULL() + TYPE(fb_atomic_halo_list_obj) :: atomic_halos = fb_atomic_halo_list_obj() + TYPE(fb_trial_fns_obj) :: trial_fns = fb_trial_fns_obj() + REAL(KIND=dp) :: filter_temperature = -1.0_dp + REAL(KIND=dp) :: auto_cutoff_scale = -1.0_dp + REAL(KIND=dp) :: eps_default = -1.0_dp + LOGICAL :: collective_com = .FALSE. + INTEGER, DIMENSION(:), POINTER :: local_atoms => NULL() + INTEGER :: nlocal_atoms = -1 END TYPE fb_env_data ! ************************************************************************************************** @@ -84,7 +84,7 @@ MODULE qs_fb_env_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_env_obj - TYPE(fb_env_data), POINTER, PRIVATE :: obj + TYPE(fb_env_data), POINTER, PRIVATE :: obj => NULL() END TYPE fb_env_obj CONTAINS diff --git a/src/qs_fb_hash_table_types.F b/src/qs_fb_hash_table_types.F index 5913c4dfa4..f6a8cfb61c 100644 --- a/src/qs_fb_hash_table_types.F +++ b/src/qs_fb_hash_table_types.F @@ -62,8 +62,8 @@ MODULE qs_fb_hash_table_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_hash_table_element - INTEGER(KIND=int_8) :: key - INTEGER :: val + INTEGER(KIND=int_8) :: key = -1_int_8 + INTEGER :: val = -1 END TYPE fb_hash_table_element ! ************************************************************************************************** @@ -78,9 +78,9 @@ MODULE qs_fb_hash_table_types ! ************************************************************************************************** TYPE fb_hash_table_data TYPE(fb_hash_table_element), DIMENSION(:), POINTER :: table => NULL() - INTEGER :: nelements - INTEGER :: nmax - INTEGER :: prime + INTEGER :: nelements = -1 + INTEGER :: nmax = -1 + INTEGER :: prime = -1 END TYPE fb_hash_table_data ! ************************************************************************************************** diff --git a/src/qs_fb_matrix_data_types.F b/src/qs_fb_matrix_data_types.F index 933813763f..4b400166fd 100644 --- a/src/qs_fb_matrix_data_types.F +++ b/src/qs_fb_matrix_data_types.F @@ -60,11 +60,11 @@ MODULE qs_fb_matrix_data_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_matrix_data_data - INTEGER :: nmax - INTEGER :: nblks - INTEGER :: nencode - TYPE(fb_hash_table_obj) :: ind - TYPE(fb_buffer_d_obj) :: blks + INTEGER :: nmax = -1 + INTEGER :: nblks = -1 + INTEGER :: nencode = -1 + TYPE(fb_hash_table_obj) :: ind = fb_hash_table_obj() + TYPE(fb_buffer_d_obj) :: blks = fb_buffer_d_obj() INTEGER, DIMENSION(:), POINTER :: lds => NULL() END TYPE fb_matrix_data_data diff --git a/src/qs_fb_trial_fns_types.F b/src/qs_fb_trial_fns_types.F index 588b29c026..b25b648dcf 100644 --- a/src/qs_fb_trial_fns_types.F +++ b/src/qs_fb_trial_fns_types.F @@ -40,9 +40,9 @@ MODULE qs_fb_trial_fns_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_trial_fns_data - INTEGER :: ref_count - INTEGER, DIMENSION(:), POINTER :: nfunctions - INTEGER, DIMENSION(:, :), POINTER :: functions + INTEGER :: ref_count = -1 + INTEGER, DIMENSION(:), POINTER :: nfunctions => NULL() + INTEGER, DIMENSION(:, :), POINTER :: functions => NULL() END TYPE fb_trial_fns_data ! ************************************************************************************************** @@ -52,7 +52,7 @@ MODULE qs_fb_trial_fns_types !> \author Lianheng Tong (LT) lianheng.tong@kcl.ac.uk ! ************************************************************************************************** TYPE fb_trial_fns_obj - TYPE(fb_trial_fns_data), POINTER, PRIVATE :: obj + TYPE(fb_trial_fns_data), POINTER, PRIVATE :: obj => NULL() END TYPE fb_trial_fns_obj CONTAINS diff --git a/src/qs_force_types.F b/src/qs_force_types.F index 47bed518b6..4e74d8729c 100644 --- a/src/qs_force_types.F +++ b/src/qs_force_types.F @@ -26,30 +26,30 @@ MODULE qs_force_types PRIVATE TYPE qs_force_type - REAL(KIND=dp), DIMENSION(:, :), POINTER :: all_potential, & - core_overlap, & - gth_ppl, & - gth_nlcc, & - gth_ppnl, & - kinetic, & - overlap, & - overlap_admm, & - rho_core, & - rho_elec, & - rho_lri_elec, & - vhxc_atom, & - g0s_Vh_elec, & - repulsive, & - dispersion, & - gcp, & - other, & - ch_pulay, & - fock_4c, & - ehrenfest, & - efield, & - eev, & - mp2_non_sep, & - total + REAL(KIND=dp), DIMENSION(:, :), POINTER :: all_potential => NULL(), & + core_overlap => NULL(), & + gth_ppl => NULL(), & + gth_nlcc => NULL(), & + gth_ppnl => NULL(), & + kinetic => NULL(), & + overlap => NULL(), & + overlap_admm => NULL(), & + rho_core => NULL(), & + rho_elec => NULL(), & + rho_lri_elec => NULL(), & + vhxc_atom => NULL(), & + g0s_Vh_elec => NULL(), & + repulsive => NULL(), & + dispersion => NULL(), & + gcp => NULL(), & + other => NULL(), & + ch_pulay => NULL(), & + fock_4c => NULL(), & + ehrenfest => NULL(), & + efield => NULL(), & + eev => NULL(), & + mp2_non_sep => NULL(), & + total => NULL() END TYPE qs_force_type PUBLIC :: qs_force_type diff --git a/src/qs_gcp_types.F b/src/qs_gcp_types.F index 7e80b3d81d..2ae991e6a1 100644 --- a/src/qs_gcp_types.F +++ b/src/qs_gcp_types.F @@ -25,26 +25,26 @@ MODULE qs_gcp_types ! ************************************************************************************************** TYPE qs_gcp_kind_type - INTEGER :: za - REAL(KIND=dp) :: asto - REAL(KIND=dp) :: rcsto - INTEGER :: nq - REAL(KIND=dp) :: nbvirt - REAL(KIND=dp) :: eamiss - REAL(KIND=dp), DIMENSION(6) :: al - REAL(KIND=dp), DIMENSION(6) :: cl + INTEGER :: za = -1 + REAL(KIND=dp) :: asto = -1.0_dp + REAL(KIND=dp) :: rcsto = -1.0_dp + INTEGER :: nq = -1 + REAL(KIND=dp) :: nbvirt = -1.0_dp + REAL(KIND=dp) :: eamiss = -1.0_dp + REAL(KIND=dp), DIMENSION(6) :: al = -1.0_dp + REAL(KIND=dp), DIMENSION(6) :: cl = -1.0_dp END TYPE qs_gcp_kind_type ! ************************************************************************************************** TYPE qs_gcp_type LOGICAL :: do_gcp = .FALSE. - LOGICAL :: verbose !extended output - CHARACTER(LEN=default_string_length) :: parameter_file_name + LOGICAL :: verbose = .FALSE. !extended output + CHARACTER(LEN=default_string_length) :: parameter_file_name = "" ! parameter input CHARACTER(LEN=default_string_length), & DIMENSION(:), POINTER :: kind_type => NULL() REAL(KIND=dp), DIMENSION(:), POINTER :: ea => NULL() !global parameters - REAL(KIND=dp) :: alpha, beta, sigma, eta + REAL(KIND=dp) :: alpha = -1.0_dp, beta = -1.0_dp, sigma = -1.0_dp, eta = -1.0_dp !neighborlist TYPE(neighbor_list_set_p_type), & DIMENSION(:), POINTER :: sab_gcp => Null() ! neighborlists for pair interactions diff --git a/src/qs_grid_atom.F b/src/qs_grid_atom.F index 72622f1f3f..6cd1888b63 100644 --- a/src/qs_grid_atom.F +++ b/src/qs_grid_atom.F @@ -24,32 +24,32 @@ MODULE qs_grid_atom CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'qs_grid_atom' TYPE grid_batch_type - INTEGER :: np - REAL(KIND=dp), DIMENSION(3) :: rcenter - REAL(KIND=dp) :: rad + INTEGER :: np = -1 + REAL(KIND=dp), DIMENSION(3) :: rcenter = -1.0_dp + REAL(KIND=dp) :: rad = -1.0_dp REAL(dp), DIMENSION(:, :), ALLOCATABLE :: rco REAL(dp), DIMENSION(:), ALLOCATABLE :: weight END TYPE grid_batch_type TYPE atom_integration_grid_type - INTEGER :: nr, na - INTEGER :: np, ntot - INTEGER :: lebedev_grid + INTEGER :: nr = -1, na = -1 + INTEGER :: np = -1, ntot = -1 + INTEGER :: lebedev_grid = -1 REAL(dp), DIMENSION(:), ALLOCATABLE :: rr REAL(dp), DIMENSION(:), ALLOCATABLE :: wr, wa - INTEGER :: nbatch + INTEGER :: nbatch = -1 TYPE(grid_batch_type), DIMENSION(:), ALLOCATABLE :: batch END TYPE atom_integration_grid_type TYPE grid_atom_type - INTEGER :: quadrature - INTEGER :: nr, ng_sphere - REAL(dp), DIMENSION(:), POINTER :: rad, rad2, & - wr, wa, & - azi, cos_azi, sin_azi, & - pol, cos_pol, sin_pol, usin_azi + INTEGER :: quadrature = -1 + INTEGER :: nr = -1, ng_sphere = -1 + REAL(dp), DIMENSION(:), POINTER :: rad => NULL(), rad2 => NULL(), & + wr => NULL(), wa => NULL(), & + azi => NULL(), cos_azi => NULL(), sin_azi => NULL(), & + pol => NULL(), cos_pol => NULL(), sin_pol => NULL(), usin_azi => NULL() REAL(dp), DIMENSION(:, :), & - POINTER :: rad2l, oorad2l, weight + POINTER :: rad2l => NULL(), oorad2l => NULL(), weight => NULL() END TYPE grid_atom_type PUBLIC :: allocate_grid_atom, create_grid_atom, deallocate_grid_atom diff --git a/src/qs_harmonics_atom.F b/src/qs_harmonics_atom.F index 6bdbb908da..d7b58c71f8 100644 --- a/src/qs_harmonics_atom.F +++ b/src/qs_harmonics_atom.F @@ -30,17 +30,17 @@ MODULE qs_harmonics_atom CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'qs_harmonics_atom' TYPE harmonics_atom_type - INTEGER :: max_s_harm, llmax, & - max_iso_not0, & - dmax_iso_not0, & - damax_iso_not0, & - ngrid - REAL(dp), DIMENSION(:, :), POINTER :: a, slm - REAL(dp), DIMENSION(:, :, :), POINTER :: dslm, dslm_dxyz - REAL(dp), DIMENSION(:, :, :), POINTER :: my_CG - REAL(dp), DIMENSION(:, :, :, :), POINTER :: my_CG_dxyz - REAL(dp), DIMENSION(:, :, :, :), POINTER :: my_CG_dxyz_asym - REAL(dp), DIMENSION(:), POINTER :: slm_int + INTEGER :: max_s_harm = -1, llmax = -1, & + max_iso_not0 = -1, & + dmax_iso_not0 = -1, & + damax_iso_not0 = -1, & + ngrid = -1 + REAL(dp), DIMENSION(:, :), POINTER :: a => NULL(), slm => NULL() + REAL(dp), DIMENSION(:, :, :), POINTER :: dslm => NULL(), dslm_dxyz => NULL() + REAL(dp), DIMENSION(:, :, :), POINTER :: my_CG => NULL() + REAL(dp), DIMENSION(:, :, :, :), POINTER :: my_CG_dxyz => NULL() + REAL(dp), DIMENSION(:, :, :, :), POINTER :: my_CG_dxyz_asym => NULL() + REAL(dp), DIMENSION(:), POINTER :: slm_int => NULL() END TYPE harmonics_atom_type diff --git a/src/qs_initial_guess.F b/src/qs_initial_guess.F index ed8f279691..2194094aca 100644 --- a/src/qs_initial_guess.F +++ b/src/qs_initial_guess.F @@ -111,7 +111,7 @@ MODULE qs_initial_guess PUBLIC :: calculate_atomic_fock_matrix TYPE atom_matrix_type - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: mat + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: mat => NULL() END TYPE atom_matrix_type CONTAINS diff --git a/src/qs_kernel_types.F b/src/qs_kernel_types.F index ad97fe13f2..47ec4ded58 100644 --- a/src/qs_kernel_types.F +++ b/src/qs_kernel_types.F @@ -49,23 +49,23 @@ MODULE qs_kernel_types ! response density TYPE(xc_rho_set_type), POINTER :: xc_rho1_set => Null() !> first and second derivatives of exchange-correlation functional - TYPE(xc_derivative_set_type) :: xc_deriv_set + TYPE(xc_derivative_set_type) :: xc_deriv_set = xc_derivative_set_type() !> XC input section - LOGICAL :: do_exck + LOGICAL :: do_exck = .FALSE. TYPE(section_vals_type), POINTER :: xc_section => Null() !> flags which indicate required components of the exchange-correlation functional !> (density, gradient, etc) - TYPE(xc_rho_cflags_type) :: xc_rho1_cflags + TYPE(xc_rho_cflags_type) :: xc_rho1_cflags = xc_rho_cflags_type() !> the method used to compute position derivatives of densities and potentials - INTEGER :: deriv_method_id + INTEGER :: deriv_method_id = -1 !> the density smoothing method - INTEGER :: rho_smooth_id + INTEGER :: rho_smooth_id = -1 !> scaling coefficients in the linear combination: !> K = alpha * K_{\alpha,\alpha} + beta * K_{\alpha,\beta} - REAL(kind=dp) :: alpha, beta + REAL(kind=dp) :: alpha = -1.0_dp, beta = -1.0_dp !> flags for finite differences/analytic XC kernels - LOGICAL :: deriv2_analytic - LOGICAL :: deriv3_analytic + LOGICAL :: deriv2_analytic = .FALSE. + LOGICAL :: deriv3_analytic = .FALSE. ! Local resolution of the identity for Coulomb TYPE(lri_environment_type), POINTER :: lri_env => Null() TYPE(lri_density_type), POINTER :: lri_density => Null() diff --git a/src/qs_kind_types.F b/src/qs_kind_types.F index e646baf006..296f857422 100644 --- a/src/qs_kind_types.F +++ b/src/qs_kind_types.F @@ -128,7 +128,7 @@ MODULE qs_kind_types INTEGER :: max_scf = -1 REAL(KIND=dp) :: eps_u_ramping = 0.0_dp REAL(KIND=dp) :: eps_scf = HUGE(0.0_dp) - REAL(KIND=dp) :: u_minus_j_target + REAL(KIND=dp) :: u_minus_j_target = 0.0_dp REAL(KIND=dp) :: u_minus_j = 0.0_dp REAL(KIND=dp) :: u_ramping = 0.0_dp REAL(KIND=dp) :: U = 0.0_dp @@ -183,7 +183,7 @@ MODULE qs_kind_types TYPE(atom_upfpot_type), POINTER :: upf_potential => Null() ! TYPE(basis_set_container_type), & - DIMENSION(20) :: basis_sets + DIMENSION(20) :: basis_sets = basis_set_container_type() ! Atomic radii REAL(KIND=dp) :: covalent_radius = 0.0_dp REAL(KIND=dp) :: vdw_radius = 0.0_dp @@ -228,7 +228,7 @@ MODULE qs_kind_types ! ************************************************************************************************** TYPE qs_kind_p_type TYPE(qs_kind_type), DIMENSION(:), & - POINTER :: qs_kind_set + POINTER :: qs_kind_set => NULL() END TYPE qs_kind_p_type ! Public subroutines diff --git a/src/qs_ks_qmmm_types.F b/src/qs_ks_qmmm_types.F index 6cde704d61..ca44f4887b 100644 --- a/src/qs_ks_qmmm_types.F +++ b/src/qs_ks_qmmm_types.F @@ -45,14 +45,14 @@ MODULE qs_ks_qmmm_types !> \author Teodoro Laino ! ************************************************************************************************** TYPE qs_ks_qmmm_env_type - INTEGER :: n_evals - REAL(KIND=dp) :: pc_ener - TYPE(pw_env_type), POINTER :: pw_env - TYPE(pw_r3d_rs_type) :: v_qmmm_rspace - TYPE(pw_r3d_rs_type), POINTER :: v_metal_rspace - TYPE(cube_info_type), DIMENSION(:), POINTER :: cube_info + INTEGER :: n_evals = -1 + REAL(KIND=dp) :: pc_ener = -1.0_dp + TYPE(pw_env_type), POINTER :: pw_env => NULL() + TYPE(pw_r3d_rs_type) :: v_qmmm_rspace = pw_r3d_rs_type() + TYPE(pw_r3d_rs_type), POINTER :: v_metal_rspace => NULL() + TYPE(cube_info_type), DIMENSION(:), POINTER :: cube_info => NULL() TYPE(dbcsr_p_type), DIMENSION(:), & - POINTER :: matrix_h + POINTER :: matrix_h => NULL() END TYPE qs_ks_qmmm_env_type CONTAINS diff --git a/src/qs_linres_current.F b/src/qs_linres_current.F index 5ca4de3433..8ffa839e59 100644 --- a/src/qs_linres_current.F +++ b/src/qs_linres_current.F @@ -141,8 +141,8 @@ MODULE qs_linres_current CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'qs_linres_current' TYPE box_type - INTEGER :: n - REAL(dp), POINTER, DIMENSION(:, :) :: r + INTEGER :: n = -1 + REAL(dp), POINTER, DIMENSION(:, :) :: r => NULL() END TYPE box_type REAL(dp), DIMENSION(3, 3, 3), PARAMETER :: Levi_Civita = RESHAPE((/ & 0.0_dp, 0.0_dp, 0.0_dp, 0.0_dp, 0.0_dp, -1.0_dp, 0.0_dp, 1.0_dp, 0.0_dp, & diff --git a/src/qs_loc_types.F b/src/qs_loc_types.F index e95a8f08b2..d5109c2f78 100644 --- a/src/qs_loc_types.F +++ b/src/qs_loc_types.F @@ -78,10 +78,10 @@ MODULE qs_loc_types !> \author MI ! ************************************************************************************************** TYPE qs_loc_env_type - LOGICAL :: do_localize, first_time - LOGICAL :: molecular_states - LOGICAL :: wannier_states - CHARACTER(LEN=default_string_length) :: tag_mo + LOGICAL :: do_localize = .FALSE., first_time = .FALSE. + LOGICAL :: molecular_states = .FALSE. + LOGICAL :: wannier_states = .FALSE. + CHARACTER(LEN=default_string_length) :: tag_mo = "" TYPE(mp_para_env_type), POINTER :: para_env => NULL() TYPE(cp_fm_type), DIMENSION(:), & POINTER :: moloc_coeff => NULL() @@ -95,9 +95,9 @@ MODULE qs_loc_types POINTER :: particle_set => NULL() TYPE(dbcsr_p_type), DIMENSION(:, :), & POINTER :: op_sm_set => NULL() - REAL(KIND=dp) :: start_time, target_time - REAL(KIND=dp) :: weights(6) - INTEGER :: dim_op + REAL(KIND=dp) :: start_time = -1.0_dp, target_time = -1.0_dp + REAL(KIND=dp) :: weights(6) = -1.0_dp + INTEGER :: dim_op = -1 END TYPE qs_loc_env_type ! ************************************************************************************************** @@ -119,32 +119,32 @@ MODULE qs_loc_types !> \param spreads_file_name output file names ! ************************************************************************************************** TYPE localized_wfn_control_type - INTEGER :: ref_count - INTEGER :: min_or_max - INTEGER :: localization_method - INTEGER :: operator_type - INTEGER, DIMENSION(2) :: nloc_states, nguess - INTEGER :: set_of_states - INTEGER, DIMENSION(2, 2) :: lu_bound_states - INTEGER :: max_iter - INTEGER :: out_each - INTEGER :: nextra - INTEGER :: coeff_po_guess, coeff_po_guess_mo_space - REAL(KIND=dp) :: eps_localization - REAL(KIND=dp) :: max_crazy_angle - REAL(KIND=dp) :: crazy_scale - REAL(KIND=dp) :: eps_occ - REAL(KIND=dp), DIMENSION(2) :: lu_ene_bound - LOGICAL :: crazy_use_diag - LOGICAL :: print_cubes, jacobi_fallback, jacobi_refinement - LOGICAL :: print_centers - LOGICAL :: print_spreads - LOGICAL :: do_homo - LOGICAL :: do_mixed, do_cg_po - LOGICAL :: loc_restart - LOGICAL :: use_history + INTEGER :: ref_count = -1 + INTEGER :: min_or_max = -1 + INTEGER :: localization_method = -1 + INTEGER :: operator_type = -1 + INTEGER, DIMENSION(2) :: nloc_states = -1, nguess = -1 + INTEGER :: set_of_states = -1 + INTEGER, DIMENSION(2, 2) :: lu_bound_states = -1 + INTEGER :: max_iter = -1 + INTEGER :: out_each = -1 + INTEGER :: nextra = -1 + INTEGER :: coeff_po_guess = -1, coeff_po_guess_mo_space = -1 + REAL(KIND=dp) :: eps_localization = -1.0_dp + REAL(KIND=dp) :: max_crazy_angle = -1.0_dp + REAL(KIND=dp) :: crazy_scale = -1.0_dp + REAL(KIND=dp) :: eps_occ = -1.0_dp + REAL(KIND=dp), DIMENSION(2) :: lu_ene_bound = -1.0_dp + LOGICAL :: crazy_use_diag = .FALSE. + LOGICAL :: print_cubes = .FALSE., jacobi_fallback = .FALSE., jacobi_refinement = .FALSE. + LOGICAL :: print_centers = .FALSE. + LOGICAL :: print_spreads = .FALSE. + LOGICAL :: do_homo = .FALSE. + LOGICAL :: do_mixed = .FALSE., do_cg_po = .FALSE. + LOGICAL :: loc_restart = .FALSE. + LOGICAL :: use_history = .FALSE. INTEGER, POINTER, DIMENSION(:, :) :: loc_states => NULL() - TYPE(cp_2d_r_p_type), DIMENSION(2) :: centers_set + TYPE(cp_2d_r_p_type), DIMENSION(2) :: centers_set = cp_2d_r_p_type() END TYPE localized_wfn_control_type ! *** Public *** diff --git a/src/qs_local_rho_types.F b/src/qs_local_rho_types.F index 8560b519f8..72a2c166af 100644 --- a/src/qs_local_rho_types.F +++ b/src/qs_local_rho_types.F @@ -33,19 +33,19 @@ MODULE qs_local_rho_types ! ************************************************************************************************** TYPE rhoz_type - REAL(dp) :: one_atom - REAL(dp), DIMENSION(:), POINTER :: r_coef - REAL(dp), DIMENSION(:), POINTER :: dr_coef - REAL(dp), DIMENSION(:), POINTER :: vr_coef + REAL(dp) :: one_atom = -1.0_dp + REAL(dp), DIMENSION(:), POINTER :: r_coef => NULL() + REAL(dp), DIMENSION(:), POINTER :: dr_coef => NULL() + REAL(dp), DIMENSION(:), POINTER :: vr_coef => NULL() END TYPE rhoz_type ! ************************************************************************************************** TYPE local_rho_type - TYPE(rho_atom_type), DIMENSION(:), POINTER :: rho_atom_set - TYPE(rho0_mpole_type), POINTER :: rho0_mpole - TYPE(rho0_atom_type), DIMENSION(:), POINTER :: rho0_atom_set - TYPE(rhoz_type), DIMENSION(:), POINTER :: rhoz_set - REAL(dp) :: rhoz_tot + TYPE(rho_atom_type), DIMENSION(:), POINTER :: rho_atom_set => NULL() + TYPE(rho0_mpole_type), POINTER :: rho0_mpole => NULL() + TYPE(rho0_atom_type), DIMENSION(:), POINTER :: rho0_atom_set => NULL() + TYPE(rhoz_type), DIMENSION(:), POINTER :: rhoz_set => NULL() + REAL(dp) :: rhoz_tot = -1.0_dp END TYPE local_rho_type ! Public Types diff --git a/src/qs_localization_methods.F b/src/qs_localization_methods.F index 31f27e092e..cc1fe5cccb 100644 --- a/src/qs_localization_methods.F +++ b/src/qs_localization_methods.F @@ -75,10 +75,11 @@ MODULE qs_localization_methods PRIVATE TYPE set_c_1d_type - COMPLEX(KIND=dp), POINTER, DIMENSION(:) :: c_array + COMPLEX(KIND=dp), POINTER, DIMENSION(:) :: c_array => NULL() END TYPE + TYPE set_c_2d_type - COMPLEX(KIND=dp), POINTER, DIMENSION(:, :) :: c_array + COMPLEX(KIND=dp), POINTER, DIMENSION(:, :) :: c_array => NULL() END TYPE CONTAINS diff --git a/src/qs_matrix_pools.F b/src/qs_matrix_pools.F index debf17adb0..1a97786580 100644 --- a/src/qs_matrix_pools.F +++ b/src/qs_matrix_pools.F @@ -64,11 +64,11 @@ MODULE qs_matrix_pools !> \author fawzi ! ************************************************************************************************** TYPE qs_matrix_pools_type - INTEGER :: ref_count - TYPE(cp_fm_pool_p_type), DIMENSION(:), POINTER :: ao_mo_fm_pools, & - ao_ao_fm_pools, mo_mo_fm_pools - TYPE(cp_fm_pool_p_type), DIMENSION(:), POINTER :: ao_mosub_fm_pools, & - mosub_mosub_fm_pools + INTEGER :: ref_count = -1 + TYPE(cp_fm_pool_p_type), DIMENSION(:), POINTER :: ao_mo_fm_pools => NULL(), & + ao_ao_fm_pools => NULL(), mo_mo_fm_pools => NULL() + TYPE(cp_fm_pool_p_type), DIMENSION(:), POINTER :: ao_mosub_fm_pools => NULL(), & + mosub_mosub_fm_pools => NULL() END TYPE qs_matrix_pools_type CONTAINS diff --git a/src/qs_mo_types.F b/src/qs_mo_types.F index daed19449f..d62265a807 100644 --- a/src/qs_mo_types.F +++ b/src/qs_mo_types.F @@ -79,7 +79,7 @@ MODULE qs_mo_types END TYPE mo_set_type TYPE mo_set_p_type - TYPE(mo_set_type), POINTER :: mo_set + TYPE(mo_set_type), POINTER :: mo_set => NULL() END TYPE mo_set_p_type PUBLIC :: mo_set_p_type, & diff --git a/src/qs_neighbor_list_types.F b/src/qs_neighbor_list_types.F index 97f9e65a0b..59fd050e2f 100644 --- a/src/qs_neighbor_list_types.F +++ b/src/qs_neighbor_list_types.F @@ -34,63 +34,63 @@ MODULE qs_neighbor_list_types ! ************************************************************************************************** TYPE neighbor_node_type PRIVATE - TYPE(neighbor_node_type), POINTER :: next_neighbor_node - REAL(dp), DIMENSION(3) :: r - INTEGER, DIMENSION(3) :: cell - INTEGER :: neighbor + TYPE(neighbor_node_type), POINTER :: next_neighbor_node => NULL() + REAL(dp), DIMENSION(3) :: r = -1.0_dp + INTEGER, DIMENSION(3) :: cell = -1 + INTEGER :: neighbor = -1 END TYPE neighbor_node_type ! ************************************************************************************************** TYPE neighbor_list_type PRIVATE - TYPE(neighbor_list_type), POINTER :: next_neighbor_list - TYPE(neighbor_node_type), POINTER :: first_neighbor_node, & - last_neighbor_node - INTEGER :: atom, nnode + TYPE(neighbor_list_type), POINTER :: next_neighbor_list => NULL() + TYPE(neighbor_node_type), POINTER :: first_neighbor_node => NULL(), & + last_neighbor_node => NULL() + INTEGER :: atom = -1, nnode = -1 END TYPE neighbor_list_type ! ************************************************************************************************** TYPE neighbor_list_set_type PRIVATE - TYPE(neighbor_list_type), POINTER :: first_neighbor_list, & - last_neighbor_list - INTEGER :: nlist - LOGICAL :: symmetric + TYPE(neighbor_list_type), POINTER :: first_neighbor_list => NULL(), & + last_neighbor_list => NULL() + INTEGER :: nlist = -1 + LOGICAL :: symmetric = .FALSE. END TYPE neighbor_list_set_type ! ************************************************************************************************** TYPE neighbor_list_p_type - TYPE(neighbor_list_type), POINTER :: neighbor_list + TYPE(neighbor_list_type), POINTER :: neighbor_list => NULL() END TYPE neighbor_list_p_type ! ************************************************************************************************** TYPE neighbor_list_set_p_type - TYPE(neighbor_list_set_type), POINTER :: neighbor_list_set - INTEGER :: nl_size - INTEGER :: nl_start - INTEGER :: nl_end - TYPE(neighbor_list_task_type), DIMENSION(:), POINTER :: nlist_task + TYPE(neighbor_list_set_type), POINTER :: neighbor_list_set => NULL() + INTEGER :: nl_size = -1 + INTEGER :: nl_start = -1 + INTEGER :: nl_end = -1 + TYPE(neighbor_list_task_type), DIMENSION(:), POINTER :: nlist_task => NULL() END TYPE neighbor_list_set_p_type ! ************************************************************************************************** TYPE list_search_type PRIVATE - INTEGER :: nlist - INTEGER, DIMENSION(:), POINTER :: atom_list - INTEGER, DIMENSION(:), POINTER :: atom_index + INTEGER :: nlist = -1 + INTEGER, DIMENSION(:), POINTER :: atom_list => NULL() + INTEGER, DIMENSION(:), POINTER :: atom_index => NULL() TYPE(neighbor_list_p_type), & - DIMENSION(:), POINTER :: neighbor_list + DIMENSION(:), POINTER :: neighbor_list => NULL() END TYPE list_search_type ! ************************************************************************************************** TYPE neighbor_list_task_type - INTEGER :: iatom, jatom, & - ikind, jkind, nkind, & - ilist, nlist, inode, nnode - REAL(KIND=dp), DIMENSION(3) :: r - INTEGER, DIMENSION(3) :: cell + INTEGER :: iatom = -1, jatom = -1, & + ikind = -1, jkind = -1, nkind = -1, & + ilist = -1, nlist = -1, inode = -1, nnode = -1 + REAL(KIND=dp), DIMENSION(3) :: r = -1.0_dp + INTEGER, DIMENSION(3) :: cell = -1 TYPE(neighbor_list_task_type), & - POINTER :: next ! Pointer for forming a linked list of tasks + POINTER :: next => NULL() ! Pointer for forming a linked list of tasks END TYPE neighbor_list_task_type INTERFACE nl_sub_iterate @@ -103,21 +103,21 @@ MODULE qs_neighbor_list_types ! ************************************************************************************************** TYPE neighbor_list_iterator_type PRIVATE - INTEGER :: ikind, jkind, ilist, inode - INTEGER :: nkind, nlist, nnode - INTEGER :: iatom, jatom + INTEGER :: ikind = -1, jkind = -1, ilist = -1, inode = -1 + INTEGER :: nkind = -1, nlist = -1, nnode = -1 + INTEGER :: iatom = -1, jatom = -1 TYPE(neighbor_list_set_p_type), & - DIMENSION(:), POINTER :: nl - TYPE(neighbor_list_type), POINTER :: neighbor_list - TYPE(neighbor_node_type), POINTER :: neighbor_node + DIMENSION(:), POINTER :: nl => NULL() + TYPE(neighbor_list_type), POINTER :: neighbor_list => NULL() + TYPE(neighbor_node_type), POINTER :: neighbor_node => NULL() TYPE(list_search_type), & - DIMENSION(:), POINTER :: list_search + DIMENSION(:), POINTER :: list_search => NULL() END TYPE neighbor_list_iterator_type TYPE neighbor_list_iterator_p_type PRIVATE - TYPE(neighbor_list_iterator_type), POINTER :: neighbor_list_iterator - INTEGER :: last + TYPE(neighbor_list_iterator_type), POINTER :: neighbor_list_iterator => NULL() + INTEGER :: last = -1 END TYPE neighbor_list_iterator_p_type ! ************************************************************************************************** diff --git a/src/qs_neighbor_lists.F b/src/qs_neighbor_lists.F index 4159e4dd56..ea649b0481 100644 --- a/src/qs_neighbor_lists.F +++ b/src/qs_neighbor_lists.F @@ -102,12 +102,12 @@ MODULE qs_neighbor_lists ! ************************************************************************************************** TYPE local_atoms_type - INTEGER, DIMENSION(:), POINTER :: list, & - list_local_a_index, & - list_local_b_index, & - list_1d, & - list_a_mol, & - list_b_mol + INTEGER, DIMENSION(:), POINTER :: list => NULL(), & + list_local_a_index => NULL(), & + list_local_b_index => NULL(), & + list_1d => NULL(), & + list_a_mol => NULL(), & + list_b_mol => NULL() END TYPE local_atoms_type ! ************************************************************************************************** diff --git a/src/qs_nl_hash_table_types.F b/src/qs_nl_hash_table_types.F index e8c653bcfe..054ff49357 100644 --- a/src/qs_nl_hash_table_types.F +++ b/src/qs_nl_hash_table_types.F @@ -63,8 +63,8 @@ MODULE qs_nl_hash_table_types !> \param val : value of the entry ! ************************************************************************************************** TYPE nl_hash_table_element - INTEGER(KIND=int_8) :: key - TYPE(neighbor_list_task_type), POINTER :: val + INTEGER(KIND=int_8) :: key = -1_int_8 + TYPE(neighbor_list_task_type), POINTER :: val => NULL() END TYPE nl_hash_table_element ! ************************************************************************************************** @@ -78,9 +78,9 @@ MODULE qs_nl_hash_table_types ! ************************************************************************************************** TYPE nl_hash_table_data TYPE(nl_hash_table_element), DIMENSION(:), POINTER :: table => NULL() - INTEGER :: nelements - INTEGER :: nmax - INTEGER :: prime + INTEGER :: nelements = -1 + INTEGER :: nmax = -1 + INTEGER :: prime = -1 END TYPE nl_hash_table_data ! ************************************************************************************************** diff --git a/src/qs_o3c_types.F b/src/qs_o3c_types.F index 9b490ec5bf..01501fc04f 100644 --- a/src/qs_o3c_types.F +++ b/src/qs_o3c_types.F @@ -32,40 +32,40 @@ MODULE qs_o3c_types TYPE o3c_int_type PRIVATE - INTEGER :: katom, kkind - INTEGER :: ni, nj, nk - REAL(KIND=dp), DIMENSION(3) :: rik - INTEGER, DIMENSION(3) :: cellk - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: integral - REAL(KIND=dp), DIMENSION(:, :), POINTER :: tvec - REAL(KIND=dp), DIMENSION(:, :), POINTER :: force_i - REAL(KIND=dp), DIMENSION(:, :), POINTER :: force_j - REAL(KIND=dp), DIMENSION(:, :), POINTER :: force_k + INTEGER :: katom = -1, kkind = -1 + INTEGER :: ni = -1, nj = -1, nk = -1 + REAL(KIND=dp), DIMENSION(3) :: rik = -1.0_dp + INTEGER, DIMENSION(3) :: cellk = -1 + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: integral => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: tvec => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: force_i => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: force_j => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: force_k => NULL() END TYPE o3c_int_type TYPE o3c_pair_type PRIVATE - INTEGER :: iatom, ikind - INTEGER :: jatom, jkind - REAL(KIND=dp), DIMENSION(3) :: rij - INTEGER, DIMENSION(3) :: cellj - INTEGER :: nklist - TYPE(o3c_int_type), DIMENSION(:), POINTER :: ijk + INTEGER :: iatom = -1, ikind = -1 + INTEGER :: jatom = -1, jkind = -1 + REAL(KIND=dp), DIMENSION(3) :: rij = -1.0_dp + INTEGER, DIMENSION(3) :: cellj = -1 + INTEGER :: nklist = -1 + TYPE(o3c_int_type), DIMENSION(:), POINTER :: ijk => NULL() END TYPE o3c_pair_type TYPE o3c_container_type PRIVATE - LOGICAL :: ijsymmetric - INTEGER :: nijpairs - INTEGER :: nspin - TYPE(o3c_pair_type), DIMENSION(:), POINTER :: ijpair + LOGICAL :: ijsymmetric = .FALSE. + INTEGER :: nijpairs = -1 + INTEGER :: nspin = -1 + TYPE(o3c_pair_type), DIMENSION(:), POINTER :: ijpair => NULL() ! basis sets and neighbor lists are pointing to other resources ! we don't keep track if the data is available and correct TYPE(gto_basis_set_p_type), DIMENSION(:), & - POINTER :: basis_set_list_a, basis_set_list_b, & - basis_set_list_c + POINTER :: basis_set_list_a => NULL(), basis_set_list_b => NULL(), & + basis_set_list_c => NULL() TYPE(neighbor_list_set_p_type), & - DIMENSION(:), POINTER :: sab_nl, sac_nl + DIMENSION(:), POINTER :: sab_nl => NULL(), sac_nl => NULL() END TYPE o3c_container_type ! ************************************************************************************************** @@ -74,9 +74,9 @@ MODULE qs_o3c_types TYPE o3c_iterator_type PRIVATE - TYPE(o3c_container_type), POINTER :: o3c - INTEGER :: ijp_last, k_last - INTEGER, DIMENSION(:), POINTER :: ijp_thread, k_thread + TYPE(o3c_container_type), POINTER :: o3c => NULL() + INTEGER :: ijp_last = -1, k_last = -1 + INTEGER, DIMENSION(:), POINTER :: ijp_thread => NULL(), k_thread => NULL() END TYPE o3c_iterator_type ! ************************************************************************************************** @@ -85,8 +85,8 @@ MODULE qs_o3c_types TYPE o3c_vec_type PRIVATE - INTEGER :: n - REAL(KIND=dp), DIMENSION(:), POINTER :: v + INTEGER :: n = -1 + REAL(KIND=dp), DIMENSION(:), POINTER :: v => NULL() END TYPE o3c_vec_type ! ************************************************************************************************** diff --git a/src/qs_ot_types.F b/src/qs_ot_types.F index 26730a9691..a623a1ebfc 100644 --- a/src/qs_ot_types.F +++ b/src/qs_ot_types.F @@ -63,142 +63,142 @@ MODULE qs_ot_types ! needed for spins as e.g. in qs_ot_scf ! ! ************************************************************************************************** TYPE qs_ot_settings_type - LOGICAL :: do_rotation, do_ener - LOGICAL :: ks - CHARACTER(LEN=4) :: ot_method - CHARACTER(LEN=3) :: ot_algorithm - CHARACTER(LEN=4) :: line_search_method - CHARACTER(LEN=20) :: preconditioner_name - INTEGER :: preconditioner_type - INTEGER :: cholesky_type - CHARACTER(LEN=20) :: precond_solver_name - INTEGER :: precond_solver_type - LOGICAL :: safer_diis - REAL(KIND=dp) :: ds_min - REAL(KIND=dp) :: energy_gap - INTEGER :: diis_m - REAL(KIND=dp) :: gold_target - REAL(KIND=dp) :: eps_taylor ! minimum accuracy of the taylor expansion - INTEGER :: max_taylor ! maximum order of the taylor expansion before switching to diagonalization - INTEGER :: irac_degree ! this is used to control the refinement polynomial degree - INTEGER :: max_irac ! maximum number of iteration for the refinement - REAL(KIND=dp) :: eps_irac ! target accuracy for the refinement - REAL(KIND=dp) :: eps_irac_quick_exit - REAL(dp) :: eps_irac_filter_matrix - REAL(KIND=dp) :: eps_irac_switch - LOGICAL :: on_the_fly_loc - CHARACTER(LEN=4) :: ortho_irac - LOGICAL :: occupation_preconditioner, add_nondiag_energy - REAL(KIND=dp) :: nondiag_energy_strength - REAL(KIND=dp) :: broyden_beta, broyden_gamma, broyden_sigma - REAL(KIND=dp) :: broyden_eta, broyden_omega, broyden_sigma_decrease - REAL(KIND=dp) :: broyden_sigma_min - LOGICAL :: broyden_forget_history, broyden_adaptive_sigma - LOGICAL :: broyden_enable_flip + LOGICAL :: do_rotation = .FALSE., do_ener = .FALSE. + LOGICAL :: ks = .FALSE. + CHARACTER(LEN=4) :: ot_method = "" + CHARACTER(LEN=3) :: ot_algorithm = "" + CHARACTER(LEN=4) :: line_search_method = "" + CHARACTER(LEN=20) :: preconditioner_name = "" + INTEGER :: preconditioner_type = -1 + INTEGER :: cholesky_type = -1 + CHARACTER(LEN=20) :: precond_solver_name = "" + INTEGER :: precond_solver_type = -1 + LOGICAL :: safer_diis = .FALSE. + REAL(KIND=dp) :: ds_min = -1.0_dp + REAL(KIND=dp) :: energy_gap = -1.0_dp + INTEGER :: diis_m = -1 + REAL(KIND=dp) :: gold_target = -1.0_dp + REAL(KIND=dp) :: eps_taylor = -1.0_dp ! minimum accuracy of the taylor expansion + INTEGER :: max_taylor = -1 ! maximum order of the taylor expansion before switching to diagonalization + INTEGER :: irac_degree = -1 ! this is used to control the refinement polynomial degree + INTEGER :: max_irac = -1 ! maximum number of iteration for the refinement + REAL(KIND=dp) :: eps_irac = -1.0_dp ! target accuracy for the refinement + REAL(KIND=dp) :: eps_irac_quick_exit = -1.0_dp + REAL(KIND=dp) :: eps_irac_filter_matrix = -1.0_dp + REAL(KIND=dp) :: eps_irac_switch = -1.0_dp + LOGICAL :: on_the_fly_loc = .FALSE. + CHARACTER(LEN=4) :: ortho_irac = "" + LOGICAL :: occupation_preconditioner = .FALSE., add_nondiag_energy = .FALSE. + REAL(KIND=dp) :: nondiag_energy_strength = -1.0_dp + REAL(KIND=dp) :: broyden_beta = -1.0_dp, broyden_gamma = -1.0_dp, broyden_sigma = -1.0_dp + REAL(KIND=dp) :: broyden_eta = -1.0_dp, broyden_omega = -1.0_dp, broyden_sigma_decrease = -1.0_dp + REAL(KIND=dp) :: broyden_sigma_min = -1.0_dp + LOGICAL :: broyden_forget_history = .FALSE., broyden_adaptive_sigma = .FALSE. + LOGICAL :: broyden_enable_flip = .FALSE. END TYPE qs_ot_settings_type ! ************************************************************************************************** TYPE qs_ot_type ! this sets the method to be used - TYPE(qs_ot_settings_type) :: settings - LOGICAL :: restricted + TYPE(qs_ot_settings_type) :: settings = qs_ot_settings_type() + LOGICAL :: restricted = .FALSE. ! first part of the variables, for occupied subspace invariant optimisation ! add a preconditioner matrix. should be symmetric and positive definite ! the type of this matrix might change in the future - TYPE(preconditioner_type), POINTER :: preconditioner + TYPE(preconditioner_type), POINTER :: preconditioner => NULL() ! these will/might change during iterations ! OT / TOD - TYPE(dbcsr_type), POINTER :: matrix_p - TYPE(dbcsr_type), POINTER :: matrix_r - TYPE(dbcsr_type), POINTER :: matrix_sinp - TYPE(dbcsr_type), POINTER :: matrix_cosp - TYPE(dbcsr_type), POINTER :: matrix_sinp_b - TYPE(dbcsr_type), POINTER :: matrix_cosp_b - TYPE(dbcsr_type), POINTER :: matrix_buf1 - TYPE(dbcsr_type), POINTER :: matrix_buf2 - TYPE(dbcsr_type), POINTER :: matrix_buf3 - TYPE(dbcsr_type), POINTER :: matrix_buf4 - TYPE(dbcsr_type), POINTER :: matrix_os - TYPE(dbcsr_type), POINTER :: matrix_buf1_ortho - TYPE(dbcsr_type), POINTER :: matrix_buf2_ortho - - REAL(KIND=dp), DIMENSION(:), POINTER :: evals - REAL(KIND=dp), DIMENSION(:), POINTER :: dum + TYPE(dbcsr_type), POINTER :: matrix_p => NULL() + TYPE(dbcsr_type), POINTER :: matrix_r => NULL() + TYPE(dbcsr_type), POINTER :: matrix_sinp => NULL() + TYPE(dbcsr_type), POINTER :: matrix_cosp => NULL() + TYPE(dbcsr_type), POINTER :: matrix_sinp_b => NULL() + TYPE(dbcsr_type), POINTER :: matrix_cosp_b => NULL() + TYPE(dbcsr_type), POINTER :: matrix_buf1 => NULL() + TYPE(dbcsr_type), POINTER :: matrix_buf2 => NULL() + TYPE(dbcsr_type), POINTER :: matrix_buf3 => NULL() + TYPE(dbcsr_type), POINTER :: matrix_buf4 => NULL() + TYPE(dbcsr_type), POINTER :: matrix_os => NULL() + TYPE(dbcsr_type), POINTER :: matrix_buf1_ortho => NULL() + TYPE(dbcsr_type), POINTER :: matrix_buf2_ortho => NULL() + + REAL(KIND=dp), DIMENSION(:), POINTER :: evals => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: dum => NULL() ! matrix os valid - LOGICAL os_valid + LOGICAL :: os_valid = .FALSE. ! for efficient/parallel writing to the blacs_matrix - TYPE(mp_para_env_type), POINTER :: para_env - TYPE(cp_blacs_env_type), POINTER :: blacs_env + TYPE(mp_para_env_type), POINTER :: para_env => NULL() + TYPE(cp_blacs_env_type), POINTER :: blacs_env => NULL() ! mo-like vectors - TYPE(dbcsr_type), POINTER :: matrix_c0, matrix_sc0, matrix_psc0 + TYPE(dbcsr_type), POINTER :: matrix_c0 => NULL(), matrix_sc0 => NULL(), matrix_psc0 => NULL() ! OT / IR - TYPE(dbcsr_type), POINTER :: buf1_k_k_nosym, buf2_k_k_nosym, & - buf3_k_k_nosym, buf4_k_k_nosym, & - buf1_k_k_sym, buf2_k_k_sym, buf3_k_k_sym, buf4_k_k_sym, & - p_k_k_sym, buf1_n_k, buf1_n_k_dp + TYPE(dbcsr_type), POINTER :: buf1_k_k_nosym => NULL(), buf2_k_k_nosym => NULL(), & + buf3_k_k_nosym => NULL(), buf4_k_k_nosym => NULL(), & + buf1_k_k_sym => NULL(), buf2_k_k_sym => NULL(), buf3_k_k_sym => NULL(), buf4_k_k_sym => NULL(), & + p_k_k_sym => NULL(), buf1_n_k => NULL(), buf1_n_k_dp => NULL() ! only here for the ease of programming. These will have to be supplied ! explicitly at all times - TYPE(dbcsr_type), POINTER :: matrix_x, matrix_sx, matrix_gx - TYPE(dbcsr_type), POINTER :: matrix_dx, matrix_gx_old - - LOGICAL :: use_gx_old, use_dx - - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: matrix_h_e, matrix_h_x - - REAL(KIND=dp), DIMENSION(:, :), POINTER :: ls_diis - REAL(KIND=dp), DIMENSION(:, :), POINTER :: lss_diis - REAL(KIND=dp), DIMENSION(:), POINTER :: c_diis - REAL(KIND=dp), DIMENSION(:), POINTER :: c_broy - REAL(KIND=dp), DIMENSION(:), POINTER :: energy_h - INTEGER, DIMENSION(:), POINTER :: ipivot - - REAL(KIND=dp) :: ot_pos(53), ot_energy(53), ot_grad(53) ! HARD LIMIT FOR THE LS - INTEGER :: line_search_left, line_search_right, line_search_mid - INTEGER :: line_search_count - LOGICAL :: line_search_might_be_done - REAL(KIND=dp) :: delta, gnorm, gnorm_old, etotal, gradient - LOGICAL :: energy_only - INTEGER :: diis_iter - CHARACTER(LEN=8) :: OT_METHOD_FULL - INTEGER :: OT_count - REAL(KIND=dp) :: ds_min - REAL(KIND=dp) :: broyden_adaptive_sigma - - LOGICAL :: do_taylor - INTEGER :: taylor_order - REAL(KIND=dp) :: largest_eval_upper_bound + TYPE(dbcsr_type), POINTER :: matrix_x => NULL(), matrix_sx => NULL(), matrix_gx => NULL() + TYPE(dbcsr_type), POINTER :: matrix_dx => NULL(), matrix_gx_old => NULL() + + LOGICAL :: use_gx_old = .FALSE., use_dx = .FALSE. + + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: matrix_h_e => NULL(), matrix_h_x => NULL() + + REAL(KIND=dp), DIMENSION(:, :), POINTER :: ls_diis => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: lss_diis => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: c_diis => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: c_broy => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: energy_h => NULL() + INTEGER, DIMENSION(:), POINTER :: ipivot => NULL() + + REAL(KIND=dp) :: ot_pos(53) = -1.0_dp, ot_energy(53) = -1.0_dp, ot_grad(53) = -1.0_dp ! HARD LIMIT FOR THE LS + INTEGER :: line_search_left = -1, line_search_right = -1, line_search_mid = -1 + INTEGER :: line_search_count = -1 + LOGICAL :: line_search_might_be_done = .FALSE. + REAL(KIND=dp) :: delta = -1.0_dp, gnorm = -1.0_dp, gnorm_old = -1.0_dp, etotal = -1.0_dp, gradient = -1.0_dp + LOGICAL :: energy_only = .FALSE. + INTEGER :: diis_iter = -1 + CHARACTER(LEN=8) :: OT_METHOD_FULL = "" + INTEGER :: OT_count = -1 + REAL(KIND=dp) :: ds_min = -1.0_dp + REAL(KIND=dp) :: broyden_adaptive_sigma = -1.0_dp + + LOGICAL :: do_taylor = .FALSE. + INTEGER :: taylor_order = -1 + REAL(KIND=dp) :: largest_eval_upper_bound = -1.0_dp ! second part of the variables, if an explicit rotation is required as well - TYPE(dbcsr_type), POINTER :: rot_mat_u ! rotation matrix - TYPE(dbcsr_type), POINTER :: rot_mat_x ! antisymmetric matrix that parametrises rot_matrix_u - TYPE(dbcsr_type), POINTER :: rot_mat_dedu ! derivative of the total energy wrt to u - TYPE(dbcsr_type), POINTER :: rot_mat_chc ! for convencience, the matrix c^T H c + TYPE(dbcsr_type), POINTER :: rot_mat_u => NULL() ! rotation matrix + TYPE(dbcsr_type), POINTER :: rot_mat_x => NULL() ! antisymmetric matrix that parametrises rot_matrix_u + TYPE(dbcsr_type), POINTER :: rot_mat_dedu => NULL() ! derivative of the total energy wrt to u + TYPE(dbcsr_type), POINTER :: rot_mat_chc => NULL() ! for convencience, the matrix c^T H c - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: rot_mat_h_e - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: rot_mat_h_x - TYPE(dbcsr_type), POINTER :: rot_mat_gx - TYPE(dbcsr_type), POINTER :: rot_mat_gx_old - TYPE(dbcsr_type), POINTER :: rot_mat_dx + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: rot_mat_h_e => NULL() + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: rot_mat_h_x => NULL() + TYPE(dbcsr_type), POINTER :: rot_mat_gx => NULL() + TYPE(dbcsr_type), POINTER :: rot_mat_gx_old => NULL() + TYPE(dbcsr_type), POINTER :: rot_mat_dx => NULL() - REAL(KIND=dp), DIMENSION(:), POINTER :: rot_mat_evals - TYPE(dbcsr_type), POINTER :: rot_mat_evec + REAL(KIND=dp), DIMENSION(:), POINTER :: rot_mat_evals => NULL() + TYPE(dbcsr_type), POINTER :: rot_mat_evec => NULL() ! third part of the variables, if we need to optimize orbital energies - REAL(KIND=dp), POINTER, DIMENSION(:) :: ener_x - REAL(KIND=dp), POINTER, DIMENSION(:) :: ener_dx - REAL(KIND=dp), POINTER, DIMENSION(:) :: ener_gx - REAL(KIND=dp), POINTER, DIMENSION(:) :: ener_gx_old - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: ener_h_e - REAL(KIND=dp), POINTER, DIMENSION(:, :) :: ener_h_x + REAL(KIND=dp), POINTER, DIMENSION(:) :: ener_x => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:) :: ener_dx => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:) :: ener_gx => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:) :: ener_gx_old => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: ener_h_e => NULL() + REAL(KIND=dp), POINTER, DIMENSION(:, :) :: ener_h_x => NULL() END TYPE qs_ot_type CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'qs_ot_types' diff --git a/src/qs_p_env_types.F b/src/qs_p_env_types.F index 219ad22d81..8d2591e7b6 100644 --- a/src/qs_p_env_types.F +++ b/src/qs_p_env_types.F @@ -56,7 +56,7 @@ MODULE qs_p_env_types !> for the moment no smearing of the orbitals. ! ************************************************************************************************** TYPE qs_p_env_type - LOGICAL :: orthogonal_orbitals + LOGICAL :: orthogonal_orbitals = .FALSE. TYPE(qs_kpp1_env_type), POINTER :: kpp1_env => NULL() TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: kpp1 => NULL() TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: kpp1_admm => NULL() @@ -70,8 +70,8 @@ MODULE qs_p_env_types TYPE(qs_rho_type), POINTER :: rho1 => NULL() TYPE(qs_rho_type), POINTER :: rho1_xc => NULL() TYPE(qs_rho_type), POINTER :: rho1_admm => NULL() - INTEGER, DIMENSION(2) :: n_mo, & ! no of molecular orbitals - n_ao ! no of basis functions + INTEGER, DIMENSION(2) :: n_mo = -1, & ! no of molecular orbitals + n_ao = -1 ! no of basis functions ! GAPW stuff TYPE(hartree_local_type), POINTER :: hartree_local => NULL() TYPE(local_rho_type), POINTER :: local_rho_set => NULL() @@ -81,7 +81,7 @@ MODULE qs_p_env_types TYPE(cp_fm_type), DIMENSION(:), POINTER :: PS_psi0 => NULL() ! preconditioner matrix should be symmetric and positive definite - LOGICAL :: new_preconditioner + LOGICAL :: new_preconditioner = .FALSE. TYPE(preconditioner_type), DIMENSION(:), POINTER :: preconditioner => NULL() END TYPE qs_p_env_type diff --git a/src/qs_pdos.F b/src/qs_pdos.F index aca48d5a7a..54ee145aed 100644 --- a/src/qs_pdos.F +++ b/src/qs_pdos.F @@ -88,29 +88,29 @@ MODULE qs_pdos PUBLIC :: calculate_projected_dos TYPE ldos_type - INTEGER :: maxl, nlist - LOGICAL :: separate_components - INTEGER, DIMENSION(:), POINTER :: list_index + INTEGER :: maxl = -1, nlist = -1 + LOGICAL :: separate_components = .FALSE. + INTEGER, DIMENSION(:), POINTER :: list_index => NULL() REAL(KIND=dp), DIMENSION(:, :), & - POINTER :: pdos_array + POINTER :: pdos_array => NULL() END TYPE ldos_type TYPE r_ldos_type - INTEGER :: nlist, npoints - INTEGER, DIMENSION(:, :), POINTER :: index_grid_local - INTEGER, DIMENSION(:), POINTER :: list_index - REAL(KIND=dp), DIMENSION(:), POINTER :: x_range, y_range, z_range - REAL(KIND=dp), DIMENSION(:), POINTER :: eval_range + INTEGER :: nlist = -1, npoints = -1 + INTEGER, DIMENSION(:, :), POINTER :: index_grid_local => NULL() + INTEGER, DIMENSION(:), POINTER :: list_index => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: x_range => NULL(), y_range => NULL(), z_range => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: eval_range => NULL() REAL(KIND=dp), DIMENSION(:), & - POINTER :: pdos_array + POINTER :: pdos_array => NULL() END TYPE r_ldos_type TYPE ldos_p_type - TYPE(ldos_type), POINTER :: ldos + TYPE(ldos_type), POINTER :: ldos => NULL() END TYPE ldos_p_type TYPE r_ldos_p_type - TYPE(r_ldos_type), POINTER :: ldos + TYPE(r_ldos_type), POINTER :: ldos => NULL() END TYPE r_ldos_p_type CONTAINS diff --git a/src/qs_period_efield_types.F b/src/qs_period_efield_types.F index 97ccdbf069..b9c08c7edc 100644 --- a/src/qs_period_efield_types.F +++ b/src/qs_period_efield_types.F @@ -30,11 +30,11 @@ MODULE qs_period_efield_types set_efield_matrices TYPE efield_berry_type - REAL(KIND=dp) :: field_energy - REAL(KIND=dp), DIMENSION(3) :: polarisation - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: cosmat - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: sinmat - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: dipmat + REAL(KIND=dp) :: field_energy = -1.0_dp + REAL(KIND=dp), DIMENSION(3) :: polarisation = -1.0_dp + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: cosmat => NULL() + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: sinmat => NULL() + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: dipmat => NULL() END TYPE efield_berry_type CONTAINS diff --git a/src/qs_resp.F b/src/qs_resp.F index 64778ce251..99cca51625 100644 --- a/src/qs_resp.F +++ b/src/qs_resp.F @@ -96,30 +96,30 @@ MODULE qs_resp PUBLIC :: resp_fit TYPE resp_type - LOGICAL :: equal_charges, itc, & - molecular_sys, rheavies, & - use_repeat_method - INTEGER :: nres, ncons, & - nrest_sec, ncons_sec, & - npoints, stride(3), my_fit, & - npoints_proc, & - auto_vdw_radii_table - INTEGER, DIMENSION(:), POINTER :: atom_surf_list - INTEGER, DIMENSION(:, :), POINTER :: fitpoints - REAL(KIND=dp) :: rheavies_strength, & - length, eta, & - sum_vhartree, offset - REAL(KIND=dp), DIMENSION(3) :: box_hi, box_low - REAL(KIND=dp), DIMENSION(:), POINTER :: rmin_kind, & - rmax_kind - REAL(KIND=dp), DIMENSION(:), POINTER :: range_surf - REAL(KIND=dp), DIMENSION(:), POINTER :: rhs - REAL(KIND=dp), DIMENSION(:), POINTER :: sum_vpot - REAL(KIND=dp), DIMENSION(:, :), POINTER :: matrix + LOGICAL :: equal_charges = .FALSE., itc = .FALSE., & + molecular_sys = .FALSE., rheavies = .FALSE., & + use_repeat_method = .FALSE. + INTEGER :: nres = -1, ncons = -1, & + nrest_sec = -1, ncons_sec = -1, & + npoints = -1, stride(3) = -1, my_fit = -1, & + npoints_proc = -1, & + auto_vdw_radii_table = -1 + INTEGER, DIMENSION(:), POINTER :: atom_surf_list => NULL() + INTEGER, DIMENSION(:, :), POINTER :: fitpoints => NULL() + REAL(KIND=dp) :: rheavies_strength = -1.0_dp, & + length = -1.0_dp, eta = -1.0_dp, & + sum_vhartree = -1.0_dp, offset = -1.0_dp + REAL(KIND=dp), DIMENSION(3) :: box_hi = -1.0_dp, box_low = -1.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: rmin_kind => NULL(), & + rmax_kind => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: range_surf => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: rhs => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: sum_vpot => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: matrix => NULL() END TYPE resp_type TYPE resp_p_type - TYPE(resp_type), POINTER :: p_resp + TYPE(resp_type), POINTER :: p_resp => NULL() END TYPE resp_p_type CONTAINS diff --git a/src/qs_rho0_types.F b/src/qs_rho0_types.F index 72d697e7fc..7770e27f19 100644 --- a/src/qs_rho0_types.F +++ b/src/qs_rho0_types.F @@ -33,40 +33,40 @@ MODULE qs_rho0_types ! ************************************************************************************************** TYPE mpole_rho_atom - REAL(dp), DIMENSION(:), POINTER :: Qlm_h, & - Qlm_s, & - Qlm_tot, & - Qlm_car - REAL(dp) :: Qlm_z - REAL(dp), DIMENSION(2) :: Q0 + REAL(dp), DIMENSION(:), POINTER :: Qlm_h => NULL(), & + Qlm_s => NULL(), & + Qlm_tot => NULL(), & + Qlm_car => NULL() + REAL(dp) :: Qlm_z = -1.0_dp + REAL(dp), DIMENSION(2) :: Q0 = -1.0_dp END TYPE mpole_rho_atom ! ************************************************************************************************** TYPE mpole_gau_overlap - REAL(dp), DIMENSION(:, :, :), POINTER :: Qlm_gg - REAL(dp), DIMENSION(:, :), POINTER :: g0_h, vg0_h - REAL(dp) :: rpgf0_h, rpgf0_s + REAL(dp), DIMENSION(:, :, :), POINTER :: Qlm_gg => NULL() + REAL(dp), DIMENSION(:, :), POINTER :: g0_h => NULL(), vg0_h => NULL() + REAL(dp) :: rpgf0_h = -1.0_dp, rpgf0_s = -1.0_dp END TYPE mpole_gau_overlap ! ************************************************************************************************** TYPE rho0_mpole_type - TYPE(mpole_rho_atom), DIMENSION(:), POINTER :: mp_rho + TYPE(mpole_rho_atom), DIMENSION(:), POINTER :: mp_rho => NULL() TYPE(mpole_gau_overlap), DIMENSION(:), & - POINTER :: mp_gau - REAL(dp) :: zet0_h, & - total_rho0_h - REAL(dp) :: max_rpgf0_s - REAL(dp), DIMENSION(:), POINTER :: norm_g0l_h - INTEGER, DIMENSION(:), POINTER :: lmax0_kind - INTEGER :: lmax_0, igrid_zet0_s - TYPE(pw_r3d_rs_type), POINTER :: rho0_s_rs - TYPE(pw_c1d_gs_type), POINTER :: rho0_s_gs + POINTER :: mp_gau => NULL() + REAL(dp) :: zet0_h = -1.0_dp, & + total_rho0_h = -1.0_dp + REAL(dp) :: max_rpgf0_s = -1.0_dp + REAL(dp), DIMENSION(:), POINTER :: norm_g0l_h => NULL() + INTEGER, DIMENSION(:), POINTER :: lmax0_kind => NULL() + INTEGER :: lmax_0 = -1, igrid_zet0_s = -1 + TYPE(pw_r3d_rs_type), POINTER :: rho0_s_rs => NULL() + TYPE(pw_c1d_gs_type), POINTER :: rho0_s_gs => NULL() END TYPE rho0_mpole_type ! ************************************************************************************************** TYPE rho0_atom_type - TYPE(rho_atom_coeff), POINTER :: rho0_rad_h, & - vrho0_rad_h + TYPE(rho_atom_coeff), POINTER :: rho0_rad_h => NULL(), & + vrho0_rad_h => NULL() END TYPE rho0_atom_type ! Public Types diff --git a/src/qs_rho_types.F b/src/qs_rho_types.F index 38804c1c1b..0e806109f5 100644 --- a/src/qs_rho_types.F +++ b/src/qs_rho_types.F @@ -61,8 +61,8 @@ MODULE qs_rho_types ! ************************************************************************************************** TYPE qs_rho_type PRIVATE - TYPE(kpoint_transitional_type) :: rho_ao - TYPE(kpoint_transitional_type) :: rho_ao_im + TYPE(kpoint_transitional_type) :: rho_ao = kpoint_transitional_type() + TYPE(kpoint_transitional_type) :: rho_ao_im = kpoint_transitional_type() TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: rho_r => Null() TYPE(pw_c1d_gs_type), DIMENSION(:), POINTER :: rho_g => Null() TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: tau_r => Null() @@ -85,7 +85,7 @@ MODULE qs_rho_types ! ************************************************************************************************** TYPE qs_rho_p_type - TYPE(qs_rho_type), POINTER :: rho + TYPE(qs_rho_type), POINTER :: rho => NULL() END TYPE qs_rho_p_type CONTAINS diff --git a/src/qs_scf_types.F b/src/qs_scf_types.F index 04faf30aa0..10bf8c453f 100644 --- a/src/qs_scf_types.F +++ b/src/qs_scf_types.F @@ -68,55 +68,57 @@ MODULE qs_scf_types !> \author fawzi ! ************************************************************************************************** TYPE krylov_space_type - INTEGER :: nkrylov, nblock, nmo_conv, nmo_nc, max_iter - LOGICAL :: always_check_conv - REAL(dp) :: eps_std_diag, eps_conv, eps_adapt, max_res_norm, min_res_norm - REAL(dp), DIMENSION(:), POINTER :: c_eval, t_eval - TYPE(cp_fm_type), DIMENSION(:), POINTER :: v_mat, mo_conv, mo_refine - TYPE(cp_fm_type), POINTER :: tmp_mat + INTEGER :: nkrylov = -1, nblock = -1, nmo_conv = -1, nmo_nc = -1, max_iter = -1 + LOGICAL :: always_check_conv = .FALSE. + REAL(dp) :: eps_std_diag = -1.0_dp, eps_conv = -1.0_dp, eps_adapt = -1.0_dp, max_res_norm = -1.0_dp, min_res_norm = -1.0_dp + REAL(dp), DIMENSION(:), POINTER :: c_eval => NULL(), t_eval => NULL() + TYPE(cp_fm_type), DIMENSION(:), POINTER :: v_mat => NULL(), mo_conv => NULL(), mo_refine => NULL() + TYPE(cp_fm_type), POINTER :: tmp_mat => NULL() !NOTE: the following matrices are small and could be used as standard array rather than distributed fm - TYPE(cp_fm_type), POINTER :: block1_mat, block2_mat, block3_mat, block4_mat, block5_mat - TYPE(cp_fm_type), DIMENSION(:), POINTER :: c_vec, chc_mat + TYPE(cp_fm_type), POINTER :: block1_mat => NULL(), block2_mat => NULL(), block3_mat => NULL(), & + block4_mat => NULL(), block5_mat => NULL() + TYPE(cp_fm_type), DIMENSION(:), POINTER :: c_vec => NULL(), chc_mat => NULL() END TYPE krylov_space_type TYPE subspace_env_type - INTEGER :: max_iter, mixing_method - REAL(dp) :: eps_diag_sub, eps_ene, eps_adapt - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: p_matrix_store - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: p_matrix_mix - TYPE(cp_fm_type), DIMENSION(:), POINTER :: chc_mat, c_vec, c0 - TYPE(mixing_storage_type), POINTER :: mixing_store + INTEGER :: max_iter = -1, mixing_method = -1 + REAL(dp) :: eps_diag_sub = -1.0_dp, eps_ene = -1.0_dp, eps_adapt = -1.0_dp + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: p_matrix_store => NULL() + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: p_matrix_mix => NULL() + TYPE(cp_fm_type), DIMENSION(:), POINTER :: chc_mat => NULL(), c_vec => NULL(), c0 => NULL() + TYPE(mixing_storage_type), POINTER :: mixing_store => NULL() END TYPE subspace_env_type TYPE floating_basis_type - REAL(KIND=dp), DIMENSION(:, :), POINTER :: gradient + REAL(KIND=dp), DIMENSION(:, :), POINTER :: gradient => NULL() END TYPE floating_basis_type ! ************************************************************************************************** TYPE qs_scf_env_type - TYPE(qs_outer_scf_type) :: outer_scf - INTEGER :: iter_count - INTEGER :: cholesky_method, nelectron, method, mixing_method, nskip_mixing - REAL(KIND=dp) :: iter_param, iter_delta, p_mix_alpha, sum_zeff_corr - CHARACTER(len=15) :: iter_method - COMPLEX(KIND=dp), DIMENSION(:, :, :), POINTER :: cc_buffer - LOGICAL :: print_iter_line, skip_mixing, skip_diis, needs_ortho - TYPE(mixing_storage_type), POINTER :: mixing_store - TYPE(cp_fm_type), DIMENSION(:), POINTER :: scf_work1 - TYPE(cp_fm_type), POINTER :: scf_work2, ortho, ortho_m1, s_half, s_minus_one - TYPE(krylov_space_type), POINTER :: krylov_space - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: p_delta, p_mix_new - TYPE(dbcsr_type), POINTER :: ortho_dbcsr, buf1_dbcsr, buf2_dbcsr - TYPE(preconditioner_p_type), DIMENSION(:), POINTER :: ot_preconditioner - TYPE(qs_ot_type), POINTER, DIMENSION(:) :: qs_ot_env - TYPE(qs_diis_buffer_type), POINTER :: scf_diis_buffer - TYPE(subspace_env_type), POINTER :: subspace_env - TYPE(davidson_type), POINTER, DIMENSION(:) :: block_davidson_env - TYPE(fb_env_obj) :: filter_matrix_env - TYPE(floating_basis_type) :: floating_basis + TYPE(qs_outer_scf_type) :: outer_scf = qs_outer_scf_type() + INTEGER :: iter_count = -1 + INTEGER :: cholesky_method = -1, nelectron = -1, method = -1, mixing_method = -1, nskip_mixing = -1 + REAL(KIND=dp) :: iter_param = -1.0_dp, iter_delta = -1.0_dp, p_mix_alpha = -1.0_dp, sum_zeff_corr = -1.0_dp + CHARACTER(len=15) :: iter_method = "" + COMPLEX(KIND=dp), DIMENSION(:, :, :), POINTER :: cc_buffer => NULL() + LOGICAL :: print_iter_line = .FALSE., skip_mixing = .FALSE., skip_diis = .FALSE., needs_ortho = .FALSE. + TYPE(mixing_storage_type), POINTER :: mixing_store => NULL() + TYPE(cp_fm_type), DIMENSION(:), POINTER :: scf_work1 => NULL() + TYPE(cp_fm_type), POINTER :: scf_work2 => NULL(), ortho => NULL(), ortho_m1 => NULL(), & + s_half => NULL(), s_minus_one => NULL() + TYPE(krylov_space_type), POINTER :: krylov_space => NULL() + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: p_delta => NULL(), p_mix_new => NULL() + TYPE(dbcsr_type), POINTER :: ortho_dbcsr => NULL(), buf1_dbcsr => NULL(), buf2_dbcsr => NULL() + TYPE(preconditioner_p_type), DIMENSION(:), POINTER :: ot_preconditioner => NULL() + TYPE(qs_ot_type), POINTER, DIMENSION(:) :: qs_ot_env => NULL() + TYPE(qs_diis_buffer_type), POINTER :: scf_diis_buffer => NULL() + TYPE(subspace_env_type), POINTER :: subspace_env => NULL() + TYPE(davidson_type), POINTER, DIMENSION(:) :: block_davidson_env => NULL() + TYPE(fb_env_obj) :: filter_matrix_env = fb_env_obj() + TYPE(floating_basis_type) :: floating_basis = floating_basis_type() !> reference molecular orbitals for the maximum overlap method - TYPE(cp_fm_type), DIMENSION(:), POINTER :: mom_ref_mo_coeff + TYPE(cp_fm_type), DIMENSION(:), POINTER :: mom_ref_mo_coeff => NULL() !> MOM-related work matrices - TYPE(cp_fm_type), DIMENSION(:), POINTER :: mom_overlap, mom_s_mo_coeff + TYPE(cp_fm_type), DIMENSION(:), POINTER :: mom_overlap => NULL(), mom_s_mo_coeff => NULL() END TYPE qs_scf_env_type CONTAINS diff --git a/src/qs_tddfpt2_stda_types.F b/src/qs_tddfpt2_stda_types.F index 640833b1c6..535ef35284 100644 --- a/src/qs_tddfpt2_stda_types.F +++ b/src/qs_tddfpt2_stda_types.F @@ -31,30 +31,30 @@ MODULE qs_tddfpt2_stda_types PRIVATE TYPE stda_kind_type - CHARACTER(LEN=2) :: symbol !element symbol - INTEGER :: z !atomic_number - INTEGER :: kind_number !kind number - REAL(KIND=dp) :: hardness_param !hardness_parameter eta - REAL(KIND=dp) :: rcut !cutoff radius for short-range Coulomb + CHARACTER(LEN=2) :: symbol = "" !element symbol + INTEGER :: z = -1 !atomic_number + INTEGER :: kind_number = -1 !kind number + REAL(KIND=dp) :: hardness_param = -1.0_dp !hardness_parameter eta + REAL(KIND=dp) :: rcut = -1.0_dp !cutoff radius for short-range Coulomb END TYPE TYPE stda_kind_p_type - TYPE(stda_kind_type), POINTER :: kind_param + TYPE(stda_kind_type), POINTER :: kind_param => NULL() END TYPE TYPE stda_env_type !fraction of non-local HF exchange - REAL(KIND=dp) :: hfx_fraction - LOGICAL :: do_exchange + REAL(KIND=dp) :: hfx_fraction = -1.0_dp + LOGICAL :: do_exchange = .FALSE. ! empirical parameters - REAL(KIND=dp) :: alpha_param - REAL(KIND=dp) :: beta_param + REAL(KIND=dp) :: alpha_param = -1.0_dp + REAL(KIND=dp) :: beta_param = -1.0_dp ! filter for TD matrix - REAL(KIND=dp) :: eps_td_filter - TYPE(stda_kind_p_type), DIMENSION(:), POINTER:: kind_param_set + REAL(KIND=dp) :: eps_td_filter = -1.0_dp + TYPE(stda_kind_p_type), DIMENSION(:), POINTER:: kind_param_set => NULL() !number of atomic orbitals, number of occupied orbitals - INTEGER, DIMENSION(2) :: n_ao - INTEGER, DIMENSION(2) :: nactive + INTEGER, DIMENSION(2) :: n_ao = -1 + INTEGER, DIMENSION(2) :: nactive = -1 END TYPE !PARAMETERS diff --git a/src/qs_tddfpt2_types.F b/src/qs_tddfpt2_types.F index 0fa1576c90..5fdc9164f1 100644 --- a/src/qs_tddfpt2_types.F +++ b/src/qs_tddfpt2_types.F @@ -85,13 +85,13 @@ MODULE qs_tddfpt2_types ! ************************************************************************************************** TYPE tddfpt_ground_state_mos !> occupied MOs stored in a matrix form [nao x nmo_occ] - TYPE(cp_fm_type), POINTER :: mos_occ + TYPE(cp_fm_type), POINTER :: mos_occ => NULL() !> virtual MOs stored in a matrix form [nao x nmo_virt] - TYPE(cp_fm_type), POINTER :: mos_virt + TYPE(cp_fm_type), POINTER :: mos_virt => NULL() !> negated occupied orbital energy matrix [nmo_occ x nmo_occ]: - mos_occ^T * KS * mos_occ . !> Allocated when orbital energy correction is in use, otherwise it is just a diagonal !> matrix with 'evals_occ' on its diagonal - TYPE(cp_fm_type), POINTER :: evals_occ_matrix + TYPE(cp_fm_type), POINTER :: evals_occ_matrix => NULL() !> (non-corrected) occupied orbital energies REAL(kind=dp), ALLOCATABLE, DIMENSION(:) :: evals_occ !> (non-corrected) virtual orbital energies @@ -130,76 +130,76 @@ MODULE qs_tddfpt2_types !> action of TDDFPT operator on trial vectors distributed across parallel (sub)groups TYPE(cp_fm_type), ALLOCATABLE, DIMENSION(:, :) :: Aop_evects_sub !> electron density expressed in terms of atomic orbitals using primary basis set - TYPE(cp_fm_type), POINTER :: rho_ao_orb_fm_sub + TYPE(cp_fm_type), POINTER :: rho_ao_orb_fm_sub => NULL() ! ! NOTE: we do not need the next 2 matrices in case of a sparse matrix 'tddfpt_subgroup_env_type%admm_A' ! !> electron density expressed in terms of atomic orbitals using auxiliary basis set; !> can be seen as a group-specific version of the matrix 'admm_type%work_aux_aux' - TYPE(cp_fm_type), POINTER :: rho_ao_aux_fit_fm_sub + TYPE(cp_fm_type), POINTER :: rho_ao_aux_fit_fm_sub => NULL() !> group-specific version of the matrix 'admm_type%work_aux_orb' with shape [nao_aux x nao] - TYPE(cp_fm_type), POINTER :: wfm_aux_orb_sub + TYPE(cp_fm_type), POINTER :: wfm_aux_orb_sub => NULL() ! ! *** sparse matrices distributed across parallel (sub)groups *** ! !> sparse matrix with shape [nao x nao] distributed across subgroups; !> Aop_evects_sub(spin,:) = A_ia_munu_sub(spin) * mos_occ(spin) - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: A_ia_munu_sub + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: A_ia_munu_sub => NULL() ! ! *** structures to store electron densities distributed across parallel (sub)groups *** ! !> electron density in terms of primary basis set - TYPE(qs_rho_type), POINTER :: rho_orb_struct_sub + TYPE(qs_rho_type), POINTER :: rho_orb_struct_sub => NULL() !> electron density for XC in GAPW_XC - TYPE(qs_rho_type), POINTER :: rho_xc_struct_sub + TYPE(qs_rho_type), POINTER :: rho_xc_struct_sub => NULL() !> electron density in terms of auxiliary basis set - TYPE(qs_rho_type), POINTER :: rho_aux_fit_struct_sub + TYPE(qs_rho_type), POINTER :: rho_aux_fit_struct_sub => NULL() !> group-specific copy of a Coulomb/xc-potential on a real-space grid - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: A_ia_rspace_sub + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: A_ia_rspace_sub => NULL() !> group-specific copy of a reciprocal-space grid - TYPE(pw_c1d_gs_type), DIMENSION(:), POINTER :: wpw_gspace_sub + TYPE(pw_c1d_gs_type), DIMENSION(:), POINTER :: wpw_gspace_sub => NULL() !> group-specific copy of a real-space grid - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: wpw_rspace_sub + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: wpw_rspace_sub => NULL() !> group-specific copy of a real-space grid for the kinetic energy density - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: wpw_tau_rspace_sub + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: wpw_tau_rspace_sub => NULL() ! ! *** real space pw grid to hold fxc kernel <> A_ia_rspace_sub *** ! - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: fxc_rspace_sub + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: fxc_rspace_sub => NULL() ! ! *** globally distributed matrices required to compute exact exchange terms *** ! !> globally distributed version of the matrix 'rho_ao_orb_fm_sub' to store the electron density - TYPE(cp_fm_type), POINTER :: hfx_fm_ao_ao + TYPE(cp_fm_type), POINTER :: hfx_fm_ao_ao => NULL() !> sparse matrix to store the electron density in terms of auxiliary (ADMM calculation) !> or primary (regular calculation) basis set - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: hfx_rho_ao_symm, hfx_rho_ao_asymm + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: hfx_rho_ao_symm => NULL(), hfx_rho_ao_asymm => NULL() !> exact exchange expressed in terms of auxiliary or primary basis set - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: hfx_hmat_symm, hfx_hmat_asymm + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: hfx_hmat_symm => NULL(), hfx_hmat_asymm => NULL() !> SR exact exchage matrices - TYPE(cp_fm_type), POINTER :: hfxsr_fm_ao_ao - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: hfxsr_rho_ao_symm, hfxsr_rho_ao_asymm - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: hfxsr_hmat_symm, hfxsr_hmat_asymm + TYPE(cp_fm_type), POINTER :: hfxsr_fm_ao_ao => NULL() + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: hfxsr_rho_ao_symm => NULL(), hfxsr_rho_ao_asymm => NULL() + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: hfxsr_hmat_symm => NULL(), hfxsr_hmat_asymm => NULL() ! ! *** matrices required for sTDA kernel, all matrices are within subgroups ! ! Short-range gamma exchange matrix - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: gamma_exchange + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: gamma_exchange => NULL() !Lowdin MO coefficients: NAO*NOCC - TYPE(cp_fm_type), DIMENSION(:), POINTER :: ctransformed + TYPE(cp_fm_type), DIMENSION(:), POINTER :: ctransformed => NULL() !S^1/2 - TYPE(dbcsr_type), POINTER :: shalf + TYPE(dbcsr_type), POINTER :: shalf => NULL() !Eigenvalues/eigenvectors of the overlap matrix, used in sTDA forces (Lowdin derivatives) - REAL(KIND=dp), DIMENSION(:), POINTER :: S_eigenvalues - TYPE(cp_fm_type), POINTER :: S_eigenvectors - TYPE(cp_fm_type), POINTER :: slambda + REAL(KIND=dp), DIMENSION(:), POINTER :: S_eigenvalues => NULL() + TYPE(cp_fm_type), POINTER :: S_eigenvectors => NULL() + TYPE(cp_fm_type), POINTER :: slambda => NULL() !Ewald environments - TYPE(ewald_environment_type), POINTER :: ewald_env - TYPE(ewald_pw_type), POINTER :: ewald_pw + TYPE(ewald_environment_type), POINTER :: ewald_env => NULL() + TYPE(ewald_pw_type), POINTER :: ewald_pw => NULL() !> GAPW local atomic grids - TYPE(hartree_local_type), POINTER :: hartree_local - TYPE(local_rho_type), POINTER :: local_rho_set - TYPE(local_rho_type), POINTER :: local_rho_set_admm + TYPE(hartree_local_type), POINTER :: hartree_local => NULL() + TYPE(local_rho_type), POINTER :: local_rho_set => NULL() + TYPE(local_rho_type), POINTER :: local_rho_set_admm => NULL() END TYPE tddfpt_work_matrices CONTAINS diff --git a/src/qs_tddfpt_types.F b/src/qs_tddfpt_types.F index bb45a60cb3..c6acaeed3c 100644 --- a/src/qs_tddfpt_types.F +++ b/src/qs_tddfpt_types.F @@ -30,12 +30,12 @@ MODULE qs_tddfpt_types ! ************************************************************************************************** TYPE tddfpt_env_type - REAL(KIND=dp), DIMENSION(:), POINTER :: evals ! eigenvalues + REAL(KIND=dp), DIMENSION(:), POINTER :: evals => NULL() ! eigenvalues TYPE(cp_fm_type), DIMENSION(:, :), & - POINTER :: evecs ! eigenvectors - TYPE(cp_fm_type), DIMENSION(:), POINTER :: invS ! the inverse of the metric + POINTER :: evecs => NULL() ! eigenvectors + TYPE(cp_fm_type), DIMENSION(:), POINTER :: invS => NULL() ! the inverse of the metric TYPE(cp_fm_pool_p_type), DIMENSION(:), & - POINTER :: ao_mo_fm_pools + POINTER :: ao_mo_fm_pools => NULL() END TYPE tddfpt_env_type CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'qs_tddfpt_types' diff --git a/src/qs_tddfpt_utils.F b/src/qs_tddfpt_utils.F index 7fef4e1879..2a686f287d 100644 --- a/src/qs_tddfpt_utils.F +++ b/src/qs_tddfpt_utils.F @@ -50,10 +50,10 @@ MODULE qs_tddfpt_utils ! ************************************************************************************************** TYPE simple_solution_sorter - INTEGER :: orbit - INTEGER :: lumo - REAL(KIND=DP) :: value - TYPE(simple_solution_sorter), POINTER :: next + INTEGER :: orbit = -1 + INTEGER :: lumo = -1 + REAL(KIND=DP) :: value = -1.0_dp + TYPE(simple_solution_sorter), POINTER :: next => NULL() END TYPE simple_solution_sorter PRIVATE diff --git a/src/qs_wannier90.F b/src/qs_wannier90.F index 765c40a8fb..4c5e8e7dcb 100644 --- a/src/qs_wannier90.F +++ b/src/qs_wannier90.F @@ -82,7 +82,7 @@ MODULE qs_wannier90 CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'qs_wannier90' TYPE berry_matrix_type - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: sinmat, cosmat + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: sinmat => NULL(), cosmat => NULL() END TYPE berry_matrix_type PUBLIC :: wannier90_interface diff --git a/src/qs_wf_history_types.F b/src/qs_wf_history_types.F index f25f49e90e..a13b6b51b5 100644 --- a/src/qs_wf_history_types.F +++ b/src/qs_wf_history_types.F @@ -56,14 +56,14 @@ MODULE qs_wf_history_types !> \author fawzi ! ************************************************************************************************** TYPE qs_wf_snapshot_type - TYPE(cp_fm_type), DIMENSION(:), POINTER :: wf - TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: rho_r - TYPE(pw_c1d_gs_type), DIMENSION(:), POINTER :: rho_g - TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: rho_ao - TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: rho_ao_kp - TYPE(dbcsr_type), POINTER :: overlap - TYPE(qs_rho_type), POINTER :: rho_frozen - REAL(KIND=dp) :: dt + TYPE(cp_fm_type), DIMENSION(:), POINTER :: wf => NULL() + TYPE(pw_r3d_rs_type), DIMENSION(:), POINTER :: rho_r => NULL() + TYPE(pw_c1d_gs_type), DIMENSION(:), POINTER :: rho_g => NULL() + TYPE(dbcsr_p_type), DIMENSION(:), POINTER :: rho_ao => NULL() + TYPE(dbcsr_p_type), DIMENSION(:, :), POINTER :: rho_ao_kp => NULL() + TYPE(dbcsr_type), POINTER :: overlap => NULL() + TYPE(qs_rho_type), POINTER :: rho_frozen => NULL() + REAL(KIND=dp) :: dt = 0.0_dp END TYPE qs_wf_snapshot_type ! ************************************************************************************************** @@ -74,7 +74,7 @@ MODULE qs_wf_history_types !> \author fawzi ! ************************************************************************************************** TYPE qs_wf_snapshot_p_type - TYPE(qs_wf_snapshot_type), POINTER :: snapshot + TYPE(qs_wf_snapshot_type), POINTER :: snapshot => NULL() END TYPE qs_wf_snapshot_p_type ! ************************************************************************************************** @@ -96,11 +96,12 @@ MODULE qs_wf_history_types !> \author fawzi ! ************************************************************************************************** TYPE qs_wf_history_type - INTEGER :: ref_count, memory_depth, last_state_index, & - interpolation_method_nr, snapshot_count - LOGICAL :: store_wf, store_rho_r, store_rho_g, store_rho_ao, store_rho_ao_kp, & - store_overlap, store_frozen_density - TYPE(qs_wf_snapshot_p_type), DIMENSION(:), POINTER :: past_states + INTEGER :: ref_count = -1, memory_depth = -1, last_state_index = -1, & + interpolation_method_nr = -1, snapshot_count = -1 + LOGICAL :: store_wf = .FALSE., store_rho_r = .FALSE., store_rho_g = .FALSE., & + store_rho_ao = .FALSE., store_rho_ao_kp = .FALSE., & + store_overlap = .FALSE., store_frozen_density = .FALSE. + TYPE(qs_wf_snapshot_p_type), DIMENSION(:), POINTER :: past_states => NULL() END TYPE qs_wf_history_type ! ************************************************************************************************** @@ -109,7 +110,7 @@ MODULE qs_wf_history_types !> \author fawzi ! ************************************************************************************************** TYPE qs_wf_history_p_type - TYPE(qs_wf_history_type), POINTER :: wf_history + TYPE(qs_wf_history_type), POINTER :: wf_history => NULL() END TYPE qs_wf_history_p_type CONTAINS diff --git a/src/rel_control_types.F b/src/rel_control_types.F index f2ea424d49..03b55156b8 100644 --- a/src/rel_control_types.F +++ b/src/rel_control_types.F @@ -53,12 +53,12 @@ MODULE rel_control_types !> \author Fawzi Mohamed ! ************************************************************************************************** TYPE rel_control_type - INTEGER :: rel_method - INTEGER :: rel_DKH_order - INTEGER :: rel_ZORA_type - INTEGER :: rel_transformation - INTEGER :: rel_z_cutoff - INTEGER :: rel_potential + INTEGER :: rel_method = -1 + INTEGER :: rel_DKH_order = -1 + INTEGER :: rel_ZORA_type = -1 + INTEGER :: rel_transformation = -1 + INTEGER :: rel_z_cutoff = -1 + INTEGER :: rel_potential = -1 END TYPE rel_control_type CONTAINS diff --git a/src/replica_types.F b/src/replica_types.F index f1949d20b9..97974e1331 100644 --- a/src/replica_types.F +++ b/src/replica_types.F @@ -94,21 +94,21 @@ MODULE replica_types !> \author fawzi ! ************************************************************************************************** TYPE replica_env_type - INTEGER :: ref_count, id_nr, f_env_id, & - nrep, ndim, nparticle, & - my_rep_group, force_dim - REAL(kind=dp), DIMENSION(:, :), POINTER :: r, v, f - LOGICAL :: sync_v, keep_wf_history - CHARACTER(LEN=default_path_length) :: original_project_name - TYPE(qs_wf_history_p_type), DIMENSION(:), POINTER :: wf_history - TYPE(cp_result_p_type), DIMENSION(:), POINTER :: results - INTEGER, DIMENSION(:), POINTER :: local_rep_indices - INTEGER, DIMENSION(:), POINTER :: replica_owner, force_rank, & - inter_rep_rank - LOGICAL, DIMENSION(:), POINTER :: rep_is_local - TYPE(mp_para_cart_type), POINTER :: cart - TYPE(mp_para_env_type), POINTER :: para_env, para_env_f, & - para_env_inter_rep + INTEGER :: ref_count = -1, id_nr = -1, f_env_id = -1, & + nrep = -1, ndim = -1, nparticle = -1, & + my_rep_group = -1, force_dim = -1 + REAL(kind=dp), DIMENSION(:, :), POINTER :: r => NULL(), v => NULL(), f => NULL() + LOGICAL :: sync_v = .FALSE., keep_wf_history = .FALSE. + CHARACTER(LEN=default_path_length) :: original_project_name = "" + TYPE(qs_wf_history_p_type), DIMENSION(:), POINTER :: wf_history => NULL() + TYPE(cp_result_p_type), DIMENSION(:), POINTER :: results => NULL() + INTEGER, DIMENSION(:), POINTER :: local_rep_indices => NULL() + INTEGER, DIMENSION(:), POINTER :: replica_owner => NULL(), force_rank => NULL(), & + inter_rep_rank => NULL() + LOGICAL, DIMENSION(:), POINTER :: rep_is_local => NULL() + TYPE(mp_para_cart_type), POINTER :: cart => NULL() + TYPE(mp_para_env_type), POINTER :: para_env => NULL(), para_env_f => NULL(), & + para_env_inter_rep => NULL() END TYPE replica_env_type ! ************************************************************************************************** @@ -119,7 +119,7 @@ MODULE replica_types !> \author fawzi ! ************************************************************************************************** TYPE replica_env_p_type - TYPE(replica_env_type), POINTER :: rep_env + TYPE(replica_env_type), POINTER :: rep_env => NULL() END TYPE replica_env_p_type TYPE(replica_env_p_type), POINTER, DIMENSION(:), PRIVATE :: rep_envs diff --git a/src/scf_control_types.F b/src/scf_control_types.F index 534c47a574..8f4eab9e35 100644 --- a/src/scf_control_types.F +++ b/src/scf_control_types.F @@ -88,56 +88,57 @@ MODULE scf_control_types !> \author Fawzi Mohamed ! ************************************************************************************************** TYPE smear_type - LOGICAL :: do_smear - LOGICAL :: common_mu - INTEGER :: method - REAL(KIND=dp) :: electronic_temperature, & - fixed_mag_mom, & - eps_fermi_dirac, & - window_size - REAL(KIND=dp), DIMENSION(:), POINTER :: list + LOGICAL :: do_smear = .FALSE. + LOGICAL :: common_mu = .FALSE. + INTEGER :: method = -1 + REAL(KIND=dp) :: electronic_temperature = -1.0_dp, & + fixed_mag_mom = -1.0_dp, & + eps_fermi_dirac = -1.0_dp, & + window_size = -1.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: list => NULL() END TYPE smear_type TYPE diagonalization_type - INTEGER :: method - REAL(KIND=dp) :: eps_jacobi - REAL(KIND=dp) :: jacobi_threshold - INTEGER :: max_iter, nkrylov, nblock_krylov + INTEGER :: method = -1 + REAL(KIND=dp) :: eps_jacobi = -1.0_dp + REAL(KIND=dp) :: jacobi_threshold = -1.0_dp + INTEGER :: max_iter = -1, nkrylov = -1, nblock_krylov = -1 ! Maximum Overlap Method - LOGICAL :: mom, mom_didguess - INTEGER :: mom_proj_formula + LOGICAL :: mom = .FALSE., mom_didguess = .FALSE. + INTEGER :: mom_proj_formula = -1 ! indices of de-occupied and newly occupied alpha / beta molecular orbitals - INTEGER, DIMENSION(:), POINTER :: mom_deoccA, mom_deoccB, mom_occA, mom_occB + INTEGER, DIMENSION(:), POINTER :: mom_deoccA => NULL(), mom_deoccB => NULL(), mom_occA => NULL(), mom_occB => NULL() ! determines on SCF which iteration MOM will be switched on; ! since MOs from the previous iteration should be available, it might be at least ! 1 when wave-function has been read from restart file, or ! 2 when the atomic guess method has been used - INTEGER :: mom_start - INTEGER :: mom_type - REAL(KIND=dp) :: eps_iter - REAL(KIND=dp) :: eps_adapt - TYPE(qs_ot_settings_type) :: ot_settings + INTEGER :: mom_start = -1 + INTEGER :: mom_type = -1 + REAL(KIND=dp) :: eps_iter = -1.0_dp + REAL(KIND=dp) :: eps_adapt = -1.0_dp + TYPE(qs_ot_settings_type) :: ot_settings = qs_ot_settings_type() END TYPE diagonalization_type TYPE scf_control_type - TYPE(outer_scf_control_type) :: outer_scf - TYPE(smear_type), POINTER :: smear - TYPE(diagonalization_type) :: diagonalization - INTEGER :: density_guess, mixing_method - REAL(KIND=dp) :: eps_eigval, eps_scf, eps_scf_hist, & - level_shift, & - eps_lumos, eps_diis - INTEGER :: max_iter_lumos, max_diis, nmixing - INTEGER :: max_scf, max_scf_hist, & - maxl, nkind - LOGICAL :: do_diag_sub, & - use_cholesky, use_ot, use_diag, do_outer_scf_reortho, & - ignore_convergence_failure - LOGICAL :: non_selfconsistent - INTEGER, DIMENSION(2) :: added_mos - INTEGER :: roks_scheme - REAL(KIND=dp) :: roks_f - REAL(KIND=dp), DIMENSION(0:2, 0:2, 1:2) :: roks_parameter + TYPE(outer_scf_control_type) :: outer_scf = outer_scf_control_type() + TYPE(smear_type), POINTER :: smear => NULL() + TYPE(diagonalization_type) :: diagonalization = diagonalization_type() + INTEGER :: density_guess = -1, mixing_method = -1 + REAL(KIND=dp) :: eps_eigval = -1.0_dp, eps_scf = -1.0_dp, eps_scf_hist = -1.0_dp, & + level_shift = -1.0_dp, & + eps_lumos = -1.0_dp, eps_diis = -1.0_dp + INTEGER :: max_iter_lumos = -1, max_diis = -1, nmixing = -1 + INTEGER :: max_scf = -1, max_scf_hist = -1, & + maxl = -1, nkind = -1 + LOGICAL :: do_diag_sub = .FALSE., & + use_cholesky = .FALSE., use_ot = .FALSE., & + use_diag = .FALSE., do_outer_scf_reortho = .FALSE., & + ignore_convergence_failure = .FALSE. + LOGICAL :: non_selfconsistent = .FALSE. + INTEGER, DIMENSION(2) :: added_mos = -1 + INTEGER :: roks_scheme = -1 + REAL(KIND=dp) :: roks_f = -1.0_dp + REAL(KIND=dp), DIMENSION(0:2, 0:2, 1:2) :: roks_parameter = -1.0_dp END TYPE scf_control_type CONTAINS diff --git a/src/semi_empirical_expns3_types.F b/src/semi_empirical_expns3_types.F index b72311740e..a9d193a206 100644 --- a/src/semi_empirical_expns3_types.F +++ b/src/semi_empirical_expns3_types.F @@ -22,9 +22,9 @@ MODULE semi_empirical_expns3_types !> \author Teodoro Laino [tlaino] - 12.2008 ! ************************************************************************************************** TYPE semi_empirical_expns3_type - REAL(KIND=dp) :: core_core - REAL(KIND=dp), DIMENSION(9) :: e1b, e2a - REAL(KIND=dp), DIMENSION(81) :: w + REAL(KIND=dp) :: core_core = -1.0_dp + REAL(KIND=dp), DIMENSION(9) :: e1b = -1.0_dp, e2a = -1.0_dp + REAL(KIND=dp), DIMENSION(81) :: w = -1.0_dp END TYPE semi_empirical_expns3_type ! ************************************************************************************************** @@ -32,7 +32,7 @@ MODULE semi_empirical_expns3_types !> \author Teodoro Laino [tlaino] - 12.2008 ! ************************************************************************************************** TYPE semi_empirical_expns3_p_type - TYPE(semi_empirical_expns3_type), POINTER :: expns3 + TYPE(semi_empirical_expns3_type), POINTER :: expns3 => NULL() END TYPE semi_empirical_expns3_p_type ! *** Global parameters *** diff --git a/src/semi_empirical_int_debug.F b/src/semi_empirical_int_debug.F index 13be7b895a..9ed2f06717 100644 --- a/src/semi_empirical_int_debug.F +++ b/src/semi_empirical_int_debug.F @@ -35,12 +35,20 @@ SUBROUTINE check_rotmat_der(sepi, sepj, rjiv, ij_matrix, do_invert) CHARACTER(len=*), PARAMETER :: moduleN = 'semi_empirical_int_debug', & routineN = 'check_rotmat_der', routineP = moduleN//':'//routineN - LOGICAL :: check_value REAL(KIND=dp) :: dx, r, r0(3), x(3) TYPE(rotmat_type), POINTER :: matrix, matrix_m, matrix_n, & matrix_p INTEGER :: imap(3), i, j, k, l + INTERFACE + FUNCTION check_value(num, ana, minval, thrs) RESULT(passed) + USE kinds, ONLY: dp + IMPLICIT NONE + REAL(KIND=dp) :: num, ana, thrs, minval + LOGICAL :: passed + END FUNCTION check_value + END INTERFACE + NULLIFY (matrix_m, matrix_p, matrix_n, matrix) CALL rotmat_create(matrix_p) CALL rotmat_create(matrix_m) @@ -179,11 +187,19 @@ SUBROUTINE rot_2el_2c_first_debug(sepi, sepj, rijv, se_int_control, se_taper, in LOGICAL, DIMENSION(45, 45) :: logv REAL(KIND=dp), DIMENSION(45, 45) :: v_n, v_p, v_m - LOGICAL :: check_value REAL(KIND=dp) :: dx, r, r0(3), x(3) TYPE(rotmat_type), POINTER :: matrix INTEGER :: imap(3), i, j, k, limkl + INTERFACE + FUNCTION check_value(num, ana, minval, thrs) RESULT(passed) + USE kinds, ONLY: dp + IMPLICIT NONE + REAL(KIND=dp) :: num, ana, thrs, minval + LOGICAL :: passed + END FUNCTION check_value + END INTERFACE + NULLIFY (matrix) dx = 1.0E-6_dp imap(1) = 1 @@ -269,7 +285,15 @@ SUBROUTINE check_dssss_nucint_ana(sepi, sepj, r, dssss, itype, se_int_control, s routineN = 'check_dssss_nucint_ana', routineP = moduleN//':'//routineN REAL(dp) :: delta, nssss, od, rn, ssssm, ssssp - LOGICAL :: check_value + + INTERFACE + FUNCTION check_value(num, ana, minval, thrs) RESULT(passed) + USE kinds, ONLY: dp + IMPLICIT NONE + REAL(KIND=dp) :: num, ana, thrs, minval + LOGICAL :: passed + END FUNCTION check_value + END INTERFACE delta = 1.0E-8_dp od = 0.5_dp/delta @@ -323,7 +347,15 @@ SUBROUTINE check_dcore_nucint_ana(sepi, sepj, r, dcore, itype, se_int_control, s INTEGER :: i, j REAL(dp) :: delta, od, rn REAL(dp), DIMENSION(10, 2) :: corem, corep, ncore - LOGICAL :: check_value + + INTERFACE + FUNCTION check_value(num, ana, minval, thrs) RESULT(passed) + USE kinds, ONLY: dp + IMPLICIT NONE + REAL(KIND=dp) :: num, ana, thrs, minval + LOGICAL :: passed + END FUNCTION check_value + END INTERFACE delta = 1.0E-8_dp od = 0.5_dp/delta @@ -426,11 +458,20 @@ SUBROUTINE check_drotnuc_ana(sepi, sepj, rijv, itype, se_int_control, se_taper, INTEGER :: i, j LOGICAL :: l_de1b, l_de2a, l_e1b, l_e2a, & - lgrad, check_value + lgrad REAL(dp) :: delta REAL(KIND=dp), DIMENSION(45) :: e1b2, e2a2 REAL(KIND=dp), DIMENSION(3, 45) :: de1b2, de2a2 + INTERFACE + FUNCTION check_value(num, ana, minval, thrs) RESULT(passed) + USE kinds, ONLY: dp + IMPLICIT NONE + REAL(KIND=dp) :: num, ana, thrs, minval + LOGICAL :: passed + END FUNCTION check_value + END INTERFACE + l_e1b = PRESENT(e1b) l_e2a = PRESENT(e2a) l_de1b = PRESENT(de1b) @@ -528,11 +569,19 @@ SUBROUTINE check_dcorecore_ana(sepi, sepj, rijv, itype, se_int_control, se_taper CHARACTER(len=*), PARAMETER :: moduleN = 'semi_empirical_int_debug', & routineN = 'check_dcorecore_ana', routineP = moduleN//':'//routineN - LOGICAL :: check_value INTEGER :: j REAL(dp) :: enuc_num, delta REAL(dp), DIMENSION(3) :: denuc_num + INTERFACE + FUNCTION check_value(num, ana, minval, thrs) RESULT(passed) + USE kinds, ONLY: dp + IMPLICIT NONE + REAL(KIND=dp) :: num, ana, thrs, minval + LOGICAL :: passed + END FUNCTION check_value + END INTERFACE + WRITE (*, *) "DEBUG::"//routineP delta = 1.0E-7_dp ! check @@ -589,11 +638,19 @@ SUBROUTINE check_dterep_ana(sepi, sepj, r, ri, dri, se_int_control, se_taper, lg CHARACTER(len=*), PARAMETER :: moduleN = 'semi_empirical_int_debug', & routineN = 'check_dterep_ana', routineP = moduleN//':'//routineN - LOGICAL :: check_value INTEGER :: j, i REAL(dp) :: delta, od, rn REAL(dp), DIMENSION(491) :: nri, ri0, rim, rip + INTERFACE + FUNCTION check_value(num, ana, minval, thrs) RESULT(passed) + USE kinds, ONLY: dp + IMPLICIT NONE + REAL(KIND=dp) :: num, ana, thrs, minval + LOGICAL :: passed + END FUNCTION check_value + END INTERFACE + delta = 1.0E-8_dp od = 0.5_dp/delta rn = r @@ -664,10 +721,18 @@ SUBROUTINE check_rotint_ana(sepi, sepj, rijv, w, dw, se_int_control, se_taper) REAL(dp), DIMENSION(2025) :: w2 REAL(dp), DIMENSION(3, 2025) :: dw2 - LOGICAL :: check_value INTEGER :: j, i REAL(KIND=dp) :: delta + INTERFACE + FUNCTION check_value(num, ana, minval, thrs) RESULT(passed) + USE kinds, ONLY: dp + IMPLICIT NONE + REAL(KIND=dp) :: num, ana, thrs, minval + LOGICAL :: passed + END FUNCTION check_value + END INTERFACE + delta = 1.0E-6_dp WRITE (*, *) "DEBUG::"//routineP IF (PRESENT(w)) THEN diff --git a/src/semi_empirical_mpole_types.F b/src/semi_empirical_mpole_types.F index 3d1e310530..4937a8bf7f 100644 --- a/src/semi_empirical_mpole_types.F +++ b/src/semi_empirical_mpole_types.F @@ -27,16 +27,16 @@ MODULE semi_empirical_mpole_types !> \author Teodoro Laino [tlaino] - 08.2008 Zurich University ! ************************************************************************************************** TYPE semi_empirical_mpole_type - LOGICAL, DIMENSION(3) :: task - INTEGER :: indi, indj - REAL(KIND=dp) :: c - REAL(KIND=dp), DIMENSION(3) :: d - REAL(KIND=dp), DIMENSION(3, 3) :: qc ! quadrupole cartesian - REAL(KIND=dp), DIMENSION(5) :: qs ! quadrupole spherical + LOGICAL, DIMENSION(3) :: task = .FALSE. + INTEGER :: indi = -1, indj = -1 + REAL(KIND=dp) :: c = -1.0_dp + REAL(KIND=dp), DIMENSION(3) :: d = -1.0_dp + REAL(KIND=dp), DIMENSION(3, 3) :: qc = -1.0_dp ! quadrupole cartesian + REAL(KIND=dp), DIMENSION(5) :: qs = -1.0_dp ! quadrupole spherical ! alternative definition used in GKS integral routines - REAL(KIND=dp) :: cs - REAL(KIND=dp), DIMENSION(3) :: ds - REAL(KIND=dp), DIMENSION(3, 3) :: qq ! quadrupole cartesian + REAL(KIND=dp) :: cs = -1.0_dp + REAL(KIND=dp), DIMENSION(3) :: ds = -1.0_dp + REAL(KIND=dp), DIMENSION(3, 3) :: qq = -1.0_dp ! quadrupole cartesian END TYPE semi_empirical_mpole_type ! ************************************************************************************************** @@ -44,7 +44,7 @@ MODULE semi_empirical_mpole_types !> \author Teodoro Laino [tlaino] - 08.2008 Zurich University ! ************************************************************************************************** TYPE semi_empirical_mpole_p_type - TYPE(semi_empirical_mpole_type), POINTER :: mpole + TYPE(semi_empirical_mpole_type), POINTER :: mpole => NULL() END TYPE semi_empirical_mpole_p_type ! ************************************************************************************************** @@ -52,9 +52,9 @@ MODULE semi_empirical_mpole_types !> \author Teodoro Laino [tlaino] - 08.2008 Zurich University ! ************************************************************************************************** TYPE nddo_mpole_type - REAL(KIND=dp), DIMENSION(:), POINTER :: charge, efield0 - REAL(KIND=dp), DIMENSION(:, :), POINTER :: dipole, efield1, efield2 - REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: quadrupole + REAL(KIND=dp), DIMENSION(:), POINTER :: charge => NULL(), efield0 => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: dipole => NULL(), efield1 => NULL(), efield2 => NULL() + REAL(KIND=dp), DIMENSION(:, :, :), POINTER :: quadrupole => NULL() END TYPE nddo_mpole_type PUBLIC :: semi_empirical_mpole_type, & diff --git a/src/semi_empirical_store_int_types.F b/src/semi_empirical_store_int_types.F index f5a1782ab3..aa8cfdffab 100644 --- a/src/semi_empirical_store_int_types.F +++ b/src/semi_empirical_store_int_types.F @@ -41,14 +41,14 @@ MODULE semi_empirical_store_int_types !> \date 05.2008 ! ************************************************************************************************** TYPE semi_empirical_si_type - LOGICAL :: filling_containers, compress - INTEGER :: nbuffer - REAL(KIND=dp), POINTER, DIMENSION(:) :: max_val_buffer, uncompressed_container - TYPE(hfx_memory_type) :: memory_parameter + LOGICAL :: filling_containers = .FALSE., compress = .FALSE. + INTEGER :: nbuffer = -1 + REAL(KIND=dp), POINTER, DIMENSION(:) :: max_val_buffer => NULL(), uncompressed_container => NULL() + TYPE(hfx_memory_type) :: memory_parameter = hfx_memory_type() TYPE(hfx_cache_type), DIMENSION(:), & - POINTER :: integral_caches + POINTER :: integral_caches => NULL() TYPE(hfx_container_type), DIMENSION(:), & - POINTER :: integral_containers + POINTER :: integral_containers => NULL() END TYPE semi_empirical_si_type PUBLIC :: semi_empirical_si_type, & diff --git a/src/semi_empirical_types.F b/src/semi_empirical_types.F index 9bb21832bf..5dd5fc52ea 100644 --- a/src/semi_empirical_types.F +++ b/src/semi_empirical_types.F @@ -55,53 +55,54 @@ MODULE semi_empirical_types !> \brief Semi-empirical type ! ************************************************************************************************** TYPE semi_empirical_type - INTEGER :: typ - INTEGER :: nr - INTEGER :: core_size, atm_int_size - CHARACTER(LEN=default_string_length) :: name - LOGICAL :: defined, dorb, extended_basis_set - LOGICAL :: p_orbitals_on_h - INTEGER :: z - REAL(KIND=dp) :: zeff - INTEGER :: natorb - REAL(KIND=dp), DIMENSION(:), POINTER :: beta - REAL(KIND=dp), DIMENSION(:), POINTER :: sto_exponents - REAL(KIND=dp), DIMENSION(:), POINTER :: zn - TYPE(sto_basis_set_type), POINTER :: basis - INTEGER :: ngauss - REAL(KIND=dp) :: eheat - REAL(KIND=dp) :: uss, upp, udd, uff - REAL(KIND=dp) :: alp - REAL(KIND=dp) :: eisol - REAL(KIND=dp) :: ass, asp, app, de, acoul - REAL(KIND=dp) :: gss, gsp, gpp, gp2 - REAL(KIND=dp) :: gsd, gpd, gdd - REAL(KIND=dp) :: hsp - REAL(KIND=dp) :: dd, qq, am, ad, aq - REAL(KIND=dp), DIMENSION(2) :: pre, d - REAL(KIND=dp), DIMENSION(4) :: fn1, fn2, fn3 - REAL(KIND=dp), DIMENSION(4, 4) :: bfn1, bfn2, bfn3 - REAL(KIND=dp) :: f0dd, f2dd, f4dd, f0sd, f0pd, f2pd, & - g1pd, g2sd, g3pd - REAL(KIND=dp), DIMENSION(9) :: ko - REAL(KIND=dp), DIMENSION(6) :: cs - REAL(KIND=dp), DIMENSION(52) :: onec2el + INTEGER :: typ = -1 + INTEGER :: nr = -1 + INTEGER :: core_size = -1, atm_int_size = -1 + CHARACTER(LEN=default_string_length) :: name = "" + LOGICAL :: defined = .FALSE., dorb = .FALSE., extended_basis_set = .FALSE. + LOGICAL :: p_orbitals_on_h = .FALSE. + INTEGER :: z = -1 + REAL(KIND=dp) :: zeff = -1.0_dp + INTEGER :: natorb = -1 + REAL(KIND=dp), DIMENSION(:), POINTER :: beta => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: sto_exponents => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: zn => NULL() + TYPE(sto_basis_set_type), POINTER :: basis => NULL() + INTEGER :: ngauss = -1 + REAL(KIND=dp) :: eheat = -1.0_dp + REAL(KIND=dp) :: uss = -1.0_dp, upp = -1.0_dp, udd = -1.0_dp, uff = -1.0_dp + REAL(KIND=dp) :: alp = -1.0_dp + REAL(KIND=dp) :: eisol = -1.0_dp + REAL(KIND=dp) :: ass = -1.0_dp, asp = -1.0_dp, app = -1.0_dp, de = -1.0_dp, acoul = -1.0_dp + REAL(KIND=dp) :: gss = -1.0_dp, gsp = -1.0_dp, gpp = -1.0_dp, gp2 = -1.0_dp + REAL(KIND=dp) :: gsd = -1.0_dp, gpd = -1.0_dp, gdd = -1.0_dp + REAL(KIND=dp) :: hsp = -1.0_dp + REAL(KIND=dp) :: dd = -1.0_dp, qq = -1.0_dp, am = -1.0_dp, ad = -1.0_dp, aq = -1.0_dp + REAL(KIND=dp), DIMENSION(2) :: pre = -1.0_dp, d = -1.0_dp + REAL(KIND=dp), DIMENSION(4) :: fn1 = -1.0_dp, fn2 = -1.0_dp, fn3 = -1.0_dp + REAL(KIND=dp), DIMENSION(4, 4) :: bfn1 = -1.0_dp, bfn2 = -1.0_dp, bfn3 = -1.0_dp + REAL(KIND=dp) :: f0dd = -1.0_dp, f2dd = -1.0_dp, f4dd = -1.0_dp, & + f0sd = -1.0_dp, f0pd = -1.0_dp, f2pd = -1.0_dp, & + g1pd = -1.0_dp, g2sd = -1.0_dp, g3pd = -1.0_dp + REAL(KIND=dp), DIMENSION(9) :: ko = -1.0_dp + REAL(KIND=dp), DIMENSION(6) :: cs = -1.0_dp + REAL(KIND=dp), DIMENSION(52) :: onec2el = -1.0_dp ! Specific for PM6 & PM6-FM - REAL(KIND=dp), DIMENSION(0:115) :: xab - REAL(KIND=dp), DIMENSION(0:115) :: aab - REAL(KIND=dp) :: a, b, c, rho + REAL(KIND=dp), DIMENSION(0:115) :: xab = -1.0_dp + REAL(KIND=dp), DIMENSION(0:115) :: aab = -1.0_dp + REAL(KIND=dp) :: a = -1.0_dp, b = -1.0_dp, c = -1.0_dp, rho = -1.0_dp ! One center - two electron integrals REAL(KIND=dp), DIMENSION(:, :), & - POINTER :: w + POINTER :: w => NULL() TYPE(semi_empirical_mpole_p_type), & - POINTER, DIMENSION(:) :: w_mpole + POINTER, DIMENSION(:) :: w_mpole => NULL() ! 1/R^3 residual integral part TYPE(semi_empirical_expns3_p_type), & - POINTER, DIMENSION(:) :: expns3_int + POINTER, DIMENSION(:) :: expns3_int => NULL() END TYPE semi_empirical_type TYPE semi_empirical_p_type - TYPE(semi_empirical_type), POINTER :: se_param + TYPE(semi_empirical_type), POINTER :: se_param => NULL() END TYPE semi_empirical_p_type ! ************************************************************************************************** @@ -110,17 +111,17 @@ MODULE semi_empirical_types ! ************************************************************************************************** TYPE rotmat_type ! Value of Rotation Matrices - REAL(KIND=dp), DIMENSION(3, 3) :: sp - REAL(KIND=dp), DIMENSION(5, 5) :: sd - REAL(KIND=dp), DIMENSION(6, 3, 3) :: pp - REAL(KIND=dp), DIMENSION(15, 5, 3) :: pd - REAL(KIND=dp), DIMENSION(15, 5, 5) :: dd + REAL(KIND=dp), DIMENSION(3, 3) :: sp = -1.0_dp + REAL(KIND=dp), DIMENSION(5, 5) :: sd = -1.0_dp + REAL(KIND=dp), DIMENSION(6, 3, 3) :: pp = -1.0_dp + REAL(KIND=dp), DIMENSION(15, 5, 3) :: pd = -1.0_dp + REAL(KIND=dp), DIMENSION(15, 5, 5) :: dd = -1.0_dp ! Derivatives of Rotation Matrices - REAL(KIND=dp), DIMENSION(3, 3, 3) :: sp_d - REAL(KIND=dp), DIMENSION(3, 5, 5) :: sd_d - REAL(KIND=dp), DIMENSION(3, 6, 3, 3) :: pp_d - REAL(KIND=dp), DIMENSION(3, 15, 5, 3) :: pd_d - REAL(KIND=dp), DIMENSION(3, 15, 5, 5) :: dd_d + REAL(KIND=dp), DIMENSION(3, 3, 3) :: sp_d = -1.0_dp + REAL(KIND=dp), DIMENSION(3, 5, 5) :: sd_d = -1.0_dp + REAL(KIND=dp), DIMENSION(3, 6, 3, 3) :: pp_d = -1.0_dp + REAL(KIND=dp), DIMENSION(3, 15, 5, 3) :: pd_d = -1.0_dp + REAL(KIND=dp), DIMENSION(3, 15, 5, 5) :: dd_d = -1.0_dp END TYPE rotmat_type ! ************************************************************************************************** @@ -128,19 +129,19 @@ MODULE semi_empirical_types !> \author Teodoro Laino [tlaino] - 12.2008 ! ************************************************************************************************** TYPE ewald_gks_type - REAL(KIND=dp) :: alpha - TYPE(dg_type), POINTER :: dg - TYPE(pw_pool_type), POINTER :: pw_pool + REAL(KIND=dp) :: alpha = -1.0_dp + TYPE(dg_type), POINTER :: dg => NULL() + TYPE(pw_pool_type), POINTER :: pw_pool => NULL() END TYPE ewald_gks_type TYPE se_int_control_type - LOGICAL :: shortrange - LOGICAL :: do_ewald_r3 - LOGICAL :: do_ewald_gks - LOGICAL :: pc_coulomb_int - INTEGER :: integral_screening - INTEGER :: max_multipole - TYPE(ewald_gks_type) :: ewald_gks + LOGICAL :: shortrange = .FALSE. + LOGICAL :: do_ewald_r3 = .FALSE. + LOGICAL :: do_ewald_gks = .FALSE. + LOGICAL :: pc_coulomb_int = .FALSE. + INTEGER :: integral_screening = -1 + INTEGER :: max_multipole = -1 + TYPE(ewald_gks_type) :: ewald_gks = ewald_gks_type() END TYPE se_int_control_type ! ************************************************************************************************** @@ -148,19 +149,19 @@ MODULE semi_empirical_types !> for screened integrals ! ************************************************************************************************** TYPE se_int_screen_type - REAL(KIND=dp) :: ft, dft + REAL(KIND=dp) :: ft = -1.0_dp, dft = -1.0_dp END TYPE se_int_screen_type ! ************************************************************************************************** !> \brief Taper type use in semi-empirical calculations ! ************************************************************************************************** TYPE se_taper_type - TYPE(taper_type), POINTER :: taper - TYPE(taper_type), POINTER :: taper_cou - TYPE(taper_type), POINTER :: taper_exc - TYPE(taper_type), POINTER :: taper_lrc + TYPE(taper_type), POINTER :: taper => NULL() + TYPE(taper_type), POINTER :: taper_cou => NULL() + TYPE(taper_type), POINTER :: taper_exc => NULL() + TYPE(taper_type), POINTER :: taper_lrc => NULL() ! This taper is for KDSO-D integrals - TYPE(taper_type), POINTER :: taper_add + TYPE(taper_type), POINTER :: taper_add => NULL() END TYPE se_taper_type PUBLIC :: semi_empirical_type, & diff --git a/src/simpar_types.F b/src/simpar_types.F index 612a15837b..fce67916d2 100644 --- a/src/simpar_types.F +++ b/src/simpar_types.F @@ -28,67 +28,67 @@ MODULE simpar_types !> reorganization of the original routines/modules ! ************************************************************************************************** TYPE simpar_type - INTEGER :: nsteps - INTEGER :: max_steps - REAL(KIND=dp) :: dt - REAL(KIND=dp) :: dt_fact - REAL(KIND=dp) :: dr_tol - REAL(KIND=dp) :: dsc_tol - REAL(KIND=dp) :: temp_ext - REAL(KIND=dp) :: temp_baro_ext - REAL(KIND=dp) :: temp_baro - REAL(KIND=dp) :: temp_tol - REAL(KIND=dp) :: temp_baro_tol - REAL(KIND=dp) :: p_ext - REAL(KIND=dp) :: cmass - REAL(KIND=dp) :: cmass_nph - REAL(KIND=dp) :: v0 - REAL(KIND=dp) :: e0 - REAL(KIND=dp) :: v_shock - REAL(KIND=dp) :: p0 - REAL(KIND=dp) :: f_annealing - REAL(KIND=dp) :: f_annealing_cell - REAL(KIND=dp) :: f_temperature_annealing - REAL(KIND=dp) :: gamma_nph - INTEGER :: ensemble - LOGICAL :: constraint - LOGICAL :: annealing - LOGICAL :: annealing_cell - LOGICAL :: temperature_annealing - LOGICAL :: dump_lm - LOGICAL :: angvel_zero - LOGICAL :: variable_dt - INTEGER :: nfree, nfree_rot_transl - INTEGER :: info_constraint - INTEGER :: lagrange_multipliers - REAL(KIND=dp) :: tau_cell + INTEGER :: nsteps = -1 + INTEGER :: max_steps = -1 + REAL(KIND=dp) :: dt = -1.0_dp + REAL(KIND=dp) :: dt_fact = -1.0_dp + REAL(KIND=dp) :: dr_tol = -1.0_dp + REAL(KIND=dp) :: dsc_tol = -1.0_dp + REAL(KIND=dp) :: temp_ext = -1.0_dp + REAL(KIND=dp) :: temp_baro_ext = -1.0_dp + REAL(KIND=dp) :: temp_baro = -1.0_dp + REAL(KIND=dp) :: temp_tol = -1.0_dp + REAL(KIND=dp) :: temp_baro_tol = -1.0_dp + REAL(KIND=dp) :: p_ext = -1.0_dp + REAL(KIND=dp) :: cmass = -1.0_dp + REAL(KIND=dp) :: cmass_nph = -1.0_dp + REAL(KIND=dp) :: v0 = -1.0_dp + REAL(KIND=dp) :: e0 = -1.0_dp + REAL(KIND=dp) :: v_shock = -1.0_dp + REAL(KIND=dp) :: p0 = -1.0_dp + REAL(KIND=dp) :: f_annealing = -1.0_dp + REAL(KIND=dp) :: f_annealing_cell = -1.0_dp + REAL(KIND=dp) :: f_temperature_annealing = -1.0_dp + REAL(KIND=dp) :: gamma_nph = -1.0_dp + INTEGER :: ensemble = -1 + LOGICAL :: constraint = .FALSE. + LOGICAL :: annealing = .FALSE. + LOGICAL :: annealing_cell = .FALSE. + LOGICAL :: temperature_annealing = .FALSE. + LOGICAL :: dump_lm = .FALSE. + LOGICAL :: angvel_zero = .FALSE. + LOGICAL :: variable_dt = .FALSE. + INTEGER :: nfree = -1, nfree_rot_transl = -1 + INTEGER :: info_constraint = -1 + INTEGER :: lagrange_multipliers = -1 + REAL(KIND=dp) :: tau_cell = -1.0_dp ! Constraints Parameters - REAL(KIND=dp) :: shake_tol, roll_tol + REAL(KIND=dp) :: shake_tol = -1.0_dp, roll_tol = -1.0_dp ! Langevin Parameters - REAL(KIND=dp) :: gamma - REAL(KIND=dp) :: noisy_gamma - REAL(KIND=dp) :: shadow_gamma - REAL(KIND=dp) :: var_w + REAL(KIND=dp) :: gamma = -1.0_dp + REAL(KIND=dp) :: noisy_gamma = -1.0_dp + REAL(KIND=dp) :: shadow_gamma = -1.0_dp + REAL(KIND=dp) :: var_w = -1.0_dp ! RESPA Parameters - LOGICAL :: multi_time_switch, do_respa - INTEGER :: n_time_steps + LOGICAL :: multi_time_switch = .FALSE., do_respa = .FALSE. + INTEGER :: n_time_steps = -1 ! SHELL parameters - REAL(KIND=dp) :: temp_sh_ext - REAL(KIND=dp) :: temp_sh_tol - LOGICAL :: temperature_per_kind - LOGICAL :: scale_temperature_per_kind - LOGICAL :: do_thermal_region + REAL(KIND=dp) :: temp_sh_ext = -1.0_dp + REAL(KIND=dp) :: temp_sh_tol = -1.0_dp + LOGICAL :: temperature_per_kind = .FALSE. + LOGICAL :: scale_temperature_per_kind = .FALSE. + LOGICAL :: do_thermal_region = .FALSE. ! ADIABATIC parameters - REAL(KIND=dp) :: temp_slow - REAL(KIND=dp) :: temp_fast - REAL(KIND=dp) :: temp_tol_fast, temp_tol_slow - INTEGER :: n_resp_fast + REAL(KIND=dp) :: temp_slow = -1.0_dp + REAL(KIND=dp) :: temp_fast = -1.0_dp + REAL(KIND=dp) :: temp_tol_fast = -1.0_dp, temp_tol_slow = -1.0_dp + INTEGER :: n_resp_fast = -1 ! Velocity softening Parameters - INTEGER :: soften_nsteps - REAL(KIND=dp) :: soften_alpha - REAL(KIND=dp) :: soften_delta + INTEGER :: soften_nsteps = -1 + REAL(KIND=dp) :: soften_alpha = -1.0_dp + REAL(KIND=dp) :: soften_delta = -1.0_dp ! MD initialisation method - INTEGER :: initialization_method + INTEGER :: initialization_method = -1 END TYPE simpar_type PUBLIC :: simpar_type, & diff --git a/src/splines_types.F b/src/splines_types.F index 73b3be6a22..1a3acb1f74 100644 --- a/src/splines_types.F +++ b/src/splines_types.F @@ -38,41 +38,41 @@ MODULE splines_types !> \author unknown ! ************************************************************************************************** TYPE spline_data_type - INTEGER :: ref_count - REAL(KIND=dp), POINTER :: y(:) ! the function values y(x) - REAL(KIND=dp), POINTER :: y2(:) ! the 2nd derivative via interpolation - INTEGER :: n ! dimension of above arrays + INTEGER :: ref_count = -1 + REAL(KIND=dp), POINTER :: y(:) => NULL() ! the function values y(x) + REAL(KIND=dp), POINTER :: y2(:) => NULL() ! the 2nd derivative via interpolation + INTEGER :: n = -1 ! dimension of above arrays ! not used if uniform increments - REAL(KIND=dp) :: h ! uniform increment of x if applicable - REAL(KIND=dp) :: invh ! inverse of h - REAL(KIND=dp) :: h26 ! 1/6 * h**2 if uniform increments + REAL(KIND=dp) :: h = -1.0_dp ! uniform increment of x if applicable + REAL(KIND=dp) :: invh = -1.0_dp ! inverse of h + REAL(KIND=dp) :: h26 = -1.0_dp ! 1/6 * h**2 if uniform increments ! 1/6 otherwise - REAL(KIND=dp) :: x1 ! starting x value if uniform incr. - REAL(KIND=dp) :: xn ! end x value if uniform incr. + REAL(KIND=dp) :: x1 = -1.0_dp ! starting x value if uniform incr. + REAL(KIND=dp) :: xn = -1.0_dp ! end x value if uniform incr. END TYPE spline_data_type ! ************************************************************************************************** TYPE spline_data_p_type - TYPE(spline_data_type), POINTER :: spline_data + TYPE(spline_data_type), POINTER :: spline_data => NULL() END TYPE spline_data_p_type ! ************************************************************************************************** TYPE spline_data_pp_type - TYPE(spline_data_p_type), POINTER, DIMENSION(:) :: spl_p + TYPE(spline_data_p_type), POINTER, DIMENSION(:) :: spl_p => NULL() END TYPE spline_data_pp_type ! ************************************************************************************************** TYPE spline_environment_type - TYPE(spline_data_pp_type), POINTER, DIMENSION(:) :: spl_pp - INTEGER, POINTER, DIMENSION(:, :) :: spltab + TYPE(spline_data_pp_type), POINTER, DIMENSION(:) :: spl_pp => NULL() + INTEGER, POINTER, DIMENSION(:, :) :: spltab => NULL() END TYPE spline_environment_type ! ************************************************************************************************** TYPE spline_factor_type - REAL(KIND=dp) :: rcutsq_f, cutoff - REAL(KIND=dp), DIMENSION(:), POINTER :: rscale - REAL(KIND=dp), DIMENSION(:), POINTER :: fscale - REAL(KIND=dp), DIMENSION(:), POINTER :: dscale + REAL(KIND=dp) :: rcutsq_f = -1.0_dp, cutoff = -1.0_dp + REAL(KIND=dp), DIMENSION(:), POINTER :: rscale => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: fscale => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: dscale => NULL() END TYPE spline_factor_type CONTAINS diff --git a/src/subcell_types.F b/src/subcell_types.F index 06bef2a3ff..22d1615475 100644 --- a/src/subcell_types.F +++ b/src/subcell_types.F @@ -26,10 +26,10 @@ MODULE subcell_types ! ************************************************************************************************** TYPE subcell_type - INTEGER :: natom - REAL(KIND=dp), DIMENSION(3) :: s_max, s_min - INTEGER, DIMENSION(:), POINTER :: atom_list - REAL(KIND=dp), DIMENSION(3, 8) :: corners + INTEGER :: natom = -1 + REAL(KIND=dp), DIMENSION(3) :: s_max = -1.0_dp, s_min = -1.0_dp + INTEGER, DIMENSION(:), POINTER :: atom_list => NULL() + REAL(KIND=dp), DIMENSION(3, 8) :: corners = -1.0_dp END TYPE subcell_type CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'subcell_types' diff --git a/src/submatrix_dissection.F b/src/submatrix_dissection.F index 26e531588c..8be715a8c0 100644 --- a/src/submatrix_dissection.F +++ b/src/submatrix_dissection.F @@ -67,10 +67,11 @@ MODULE submatrix_dissection TYPE(dbcsr_type) :: dbcsr_mat TYPE(dbcsr_distribution_type) :: dist LOGICAL :: initialized = .FALSE. - TYPE(mp_comm_type) :: group - INTEGER :: numnodes, myrank, nblkcols, nblkrows, nblks, local_blocks, & - cols_per_sm, number_of_submatrices - INTEGER, DIMENSION(:), POINTER :: row_blk_size, col_blk_size + TYPE(mp_comm_type) :: group = mp_comm_type() + INTEGER :: numnodes = -1, myrank = -1, nblkcols = -1, & + nblkrows = -1, nblks = -1, local_blocks = -1, & + cols_per_sm = -1, number_of_submatrices = -1 + INTEGER, DIMENSION(:), POINTER :: row_blk_size => NULL(), col_blk_size => NULL() INTEGER, DIMENSION(:), ALLOCATABLE :: coo_cols, coo_rows, coo_col_offsets, coo_cols_local, coo_rows_local, & coo_col_offsets_local, submatrix_owners, submatrix_sizes TYPE(buffer_type), DIMENSION(:), ALLOCATABLE :: recvbufs, result_sendbufs ! Indexing starts with 0 to match rank ids! diff --git a/src/submatrix_types.F b/src/submatrix_types.F index 8119ebc140..a5d854c117 100644 --- a/src/submatrix_types.F +++ b/src/submatrix_types.F @@ -27,7 +27,7 @@ MODULE submatrix_types END TYPE extvec_type TYPE, PUBLIC :: set_type - TYPE(extvec_type), DIMENSION(0:set_modulus - 1) :: data + TYPE(extvec_type), DIMENSION(0:set_modulus - 1) :: data = extvec_type() INTEGER, DIMENSION(:), ALLOCATABLE :: sorted INTEGER :: elements = 0 LOGICAL :: sorted_up_to_date = .FALSE. @@ -41,7 +41,7 @@ MODULE submatrix_types END TYPE set_type TYPE, PUBLIC :: intBuffer_type - INTEGER, DIMENSION(:), POINTER :: data + INTEGER, DIMENSION(:), POINTER :: data => NULL() INTEGER :: size = 0 LOGICAL :: allocated = .FALSE. TYPE(mp_request_type) :: mpi_request = mp_request_null @@ -52,7 +52,7 @@ MODULE submatrix_types ! TODO: Make data type generic TYPE, PUBLIC :: buffer_type - REAL(KIND=dp), DIMENSION(:), POINTER :: data + REAL(KIND=dp), DIMENSION(:), POINTER :: data => NULL() INTEGER :: size = 0 LOGICAL :: allocated = .FALSE. TYPE(mp_request_type) :: mpi_request = mp_request_null diff --git a/src/taper_types.F b/src/taper_types.F index b9425b54f5..ce8eebc4c9 100644 --- a/src/taper_types.F +++ b/src/taper_types.F @@ -26,8 +26,8 @@ MODULE taper_types !> \brief Taper type ! ************************************************************************************************** TYPE taper_type - LOGICAL :: apply_taper - REAL(KIND=dp) :: r0, rscale + LOGICAL :: apply_taper = .FALSE. + REAL(KIND=dp) :: r0 = -1.0_dp, rscale = -1.0_dp END TYPE taper_type PUBLIC :: taper_type, taper_create, taper_release, taper_eval, dtaper_eval diff --git a/src/tip_scan_types.F b/src/tip_scan_types.F index bc07c3b07b..668ef5cede 100644 --- a/src/tip_scan_types.F +++ b/src/tip_scan_types.F @@ -24,13 +24,13 @@ MODULE tip_scan_types ! ************************************************************************************************** TYPE scanning_type - INTEGER :: num_scan_points - REAL(KIND=dp), DIMENSION(3) :: ref_point + INTEGER :: num_scan_points = -1 + REAL(KIND=dp), DIMENSION(3) :: ref_point = -1.0_dp REAL(KIND=dp), DIMENSION(:, :), & ALLOCATABLE :: tip_pos - CHARACTER(LEN=default_string_length) :: tip_cube_file - TYPE(pw_r3d_rs_type), POINTER :: tip_pw_r - TYPE(pw_c1d_gs_type), POINTER :: tip_pw_g + CHARACTER(LEN=default_string_length) :: tip_cube_file = "" + TYPE(pw_r3d_rs_type), POINTER :: tip_pw_r => NULL() + TYPE(pw_c1d_gs_type), POINTER :: tip_pw_g => NULL() END TYPE scanning_type ! ************************************************************************************************** diff --git a/src/topology_types.F b/src/topology_types.F index b9e989857b..36e92f8f68 100644 --- a/src/topology_types.F +++ b/src/topology_types.F @@ -33,151 +33,152 @@ MODULE topology_types ! ************************************************************************************************** TYPE atom_info_type - INTEGER, DIMENSION(:), POINTER :: id_molname - INTEGER, DIMENSION(:), POINTER :: id_resname - INTEGER, DIMENSION(:), POINTER :: id_atmname - INTEGER, DIMENSION(:), POINTER :: id_atom_names - INTEGER, DIMENSION(:), POINTER :: id_element - INTEGER, POINTER :: resid(:) - REAL(KIND=dp), DIMENSION(:, :), POINTER :: r - INTEGER, POINTER :: map_mol_typ(:) - INTEGER, POINTER :: map_mol_num(:) - INTEGER, POINTER :: map_mol_res(:) - REAL(KIND=dp), POINTER :: atm_charge(:) - REAL(KIND=dp), POINTER :: atm_mass(:) - REAL(KIND=dp), POINTER :: occup(:) - REAL(KIND=dp), POINTER :: beta(:) + INTEGER, DIMENSION(:), POINTER :: id_molname => NULL() + INTEGER, DIMENSION(:), POINTER :: id_resname => NULL() + INTEGER, DIMENSION(:), POINTER :: id_atmname => NULL() + INTEGER, DIMENSION(:), POINTER :: id_atom_names => NULL() + INTEGER, DIMENSION(:), POINTER :: id_element => NULL() + INTEGER, POINTER :: resid(:) => NULL() + REAL(KIND=dp), DIMENSION(:, :), POINTER :: r => NULL() + INTEGER, POINTER :: map_mol_typ(:) => NULL() + INTEGER, POINTER :: map_mol_num(:) => NULL() + INTEGER, POINTER :: map_mol_res(:) => NULL() + REAL(KIND=dp), POINTER :: atm_charge(:) => NULL() + REAL(KIND=dp), POINTER :: atm_mass(:) => NULL() + REAL(KIND=dp), POINTER :: occup(:) => NULL() + REAL(KIND=dp), POINTER :: beta(:) => NULL() END TYPE atom_info_type ! ************************************************************************************************** TYPE connectivity_info_type - INTEGER, POINTER :: bond_a(:), bond_b(:), bond_type(:) - INTEGER, POINTER :: ub_a(:), ub_b(:), ub_c(:) - INTEGER, POINTER :: theta_a(:), theta_b(:), theta_c(:), theta_type(:) - INTEGER, POINTER :: phi_a(:), phi_b(:), phi_c(:), phi_d(:), phi_type(:) - INTEGER, POINTER :: impr_a(:), impr_b(:), impr_c(:), impr_d(:), impr_type(:) - INTEGER, POINTER :: onfo_a(:), onfo_b(:) - INTEGER, POINTER :: c_bond_a(:), c_bond_b(:), c_bond_type(:) + INTEGER, POINTER :: bond_a(:) => NULL(), bond_b(:) => NULL(), bond_type(:) => NULL() + INTEGER, POINTER :: ub_a(:) => NULL(), ub_b(:) => NULL(), ub_c(:) => NULL() + INTEGER, POINTER :: theta_a(:) => NULL(), theta_b(:) => NULL(), theta_c(:) => NULL(), theta_type(:) => NULL() + INTEGER, POINTER :: phi_a(:) => NULL(), phi_b(:) => NULL(), phi_c(:) => NULL(), phi_d(:) => NULL(), phi_type(:) => NULL() + INTEGER, POINTER :: impr_a(:) => NULL(), impr_b(:) => NULL(), impr_c(:) => NULL(), & + impr_d(:) => NULL(), impr_type(:) => NULL() + INTEGER, POINTER :: onfo_a(:) => NULL(), onfo_b(:) => NULL() + INTEGER, POINTER :: c_bond_a(:) => NULL(), c_bond_b(:) => NULL(), c_bond_type(:) => NULL() END TYPE connectivity_info_type ! ************************************************************************************************** TYPE constraint_info_type ! Bonds involving Hydrogens - LOGICAL :: hbonds_restraint ! Restraints control - REAL(KIND=dp) :: hbonds_k0 ! Restraints control + LOGICAL :: hbonds_restraint = .FALSE. ! Restraints control + REAL(KIND=dp) :: hbonds_k0 = -1.0_dp ! Restraints control ! Fixed Atoms - INTEGER :: nfixed_atoms - INTEGER, POINTER :: fixed_atoms(:), fixed_type(:), fixed_mol_type(:) - LOGICAL, POINTER :: fixed_restraint(:) ! Restraints control - REAL(KIND=dp), POINTER :: fixed_k0(:) ! Restraints control + INTEGER :: nfixed_atoms = -1 + INTEGER, POINTER :: fixed_atoms(:) => NULL(), fixed_type(:) => NULL(), fixed_mol_type(:) => NULL() + LOGICAL, POINTER :: fixed_restraint(:) => NULL() ! Restraints control + REAL(KIND=dp), POINTER :: fixed_k0(:) => NULL() ! Restraints control ! Freeze QM or MM - INTEGER :: freeze_qm, freeze_mm, freeze_qm_type, freeze_mm_type - LOGICAL :: fixed_mm_restraint, fixed_qm_restraint ! Restraints control - REAL(KIND=dp) :: fixed_mm_k0, fixed_qm_k0 ! Restraints control + INTEGER :: freeze_qm = -1, freeze_mm = -1, freeze_qm_type = -1, freeze_mm_type = -1 + LOGICAL :: fixed_mm_restraint = .FALSE., fixed_qm_restraint = .FALSE. ! Restraints control + REAL(KIND=dp) :: fixed_mm_k0 = -1.0_dp, fixed_qm_k0 = -1.0_dp ! Restraints control ! Freeze with molnames - LOGICAL, POINTER :: fixed_mol_restraint(:) ! Restraints control - REAL(KIND=dp), POINTER :: fixed_mol_k0(:) ! Restraints control - CHARACTER(LEN=default_string_length), POINTER :: fixed_molnames(:) - LOGICAL, POINTER, DIMENSION(:) :: fixed_exclude_qm, fixed_exclude_mm + LOGICAL, POINTER :: fixed_mol_restraint(:) => NULL() ! Restraints control + REAL(KIND=dp), POINTER :: fixed_mol_k0(:) => NULL() ! Restraints control + CHARACTER(LEN=default_string_length), POINTER :: fixed_molnames(:) => NULL() + LOGICAL, POINTER, DIMENSION(:) :: fixed_exclude_qm => NULL(), fixed_exclude_mm => NULL() ! Collective constraints - INTEGER :: nconst_colv - INTEGER, POINTER :: const_colv_mol(:) - CHARACTER(LEN=default_string_length), POINTER :: const_colv_molname(:) - REAL(KIND=dp), POINTER :: const_colv_target(:) - REAL(KIND=dp), POINTER :: const_colv_target_growth(:) - TYPE(colvar_p_type), POINTER, DIMENSION(:) :: colvar_set - LOGICAL, POINTER :: colv_intermolecular(:) - LOGICAL, POINTER :: colv_restraint(:) ! Restraints control - REAL(KIND=dp), POINTER :: colv_k0(:) ! Restraints control - LOGICAL, POINTER, DIMENSION(:) :: colv_exclude_qm, colv_exclude_mm + INTEGER :: nconst_colv = -1 + INTEGER, POINTER :: const_colv_mol(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: const_colv_molname(:) => NULL() + REAL(KIND=dp), POINTER :: const_colv_target(:) => NULL() + REAL(KIND=dp), POINTER :: const_colv_target_growth(:) => NULL() + TYPE(colvar_p_type), POINTER, DIMENSION(:) :: colvar_set => NULL() + LOGICAL, POINTER :: colv_intermolecular(:) => NULL() + LOGICAL, POINTER :: colv_restraint(:) => NULL() ! Restraints control + REAL(KIND=dp), POINTER :: colv_k0(:) => NULL() ! Restraints control + LOGICAL, POINTER, DIMENSION(:) :: colv_exclude_qm => NULL(), colv_exclude_mm => NULL() ! G3x3 - INTEGER :: nconst_g33 - INTEGER, POINTER :: const_g33_mol(:) - CHARACTER(LEN=default_string_length), POINTER :: const_g33_molname(:) - INTEGER, POINTER :: const_g33_a(:) - INTEGER, POINTER :: const_g33_b(:) - INTEGER, POINTER :: const_g33_c(:) - REAL(KIND=dp), POINTER :: const_g33_dab(:) - REAL(KIND=dp), POINTER :: const_g33_dac(:) - REAL(KIND=dp), POINTER :: const_g33_dbc(:) - LOGICAL, POINTER :: g33_intermolecular(:) - LOGICAL, POINTER :: g33_restraint(:) ! Restraints control - REAL(KIND=dp), POINTER :: g33_k0(:) ! Restraints control - LOGICAL, POINTER, DIMENSION(:) :: g33_exclude_qm, g33_exclude_mm + INTEGER :: nconst_g33 = -1 + INTEGER, POINTER :: const_g33_mol(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: const_g33_molname(:) => NULL() + INTEGER, POINTER :: const_g33_a(:) => NULL() + INTEGER, POINTER :: const_g33_b(:) => NULL() + INTEGER, POINTER :: const_g33_c(:) => NULL() + REAL(KIND=dp), POINTER :: const_g33_dab(:) => NULL() + REAL(KIND=dp), POINTER :: const_g33_dac(:) => NULL() + REAL(KIND=dp), POINTER :: const_g33_dbc(:) => NULL() + LOGICAL, POINTER :: g33_intermolecular(:) => NULL() + LOGICAL, POINTER :: g33_restraint(:) => NULL() ! Restraints control + REAL(KIND=dp), POINTER :: g33_k0(:) => NULL() ! Restraints control + LOGICAL, POINTER, DIMENSION(:) :: g33_exclude_qm => NULL(), g33_exclude_mm => NULL() ! G4x6 - INTEGER :: nconst_g46 - INTEGER, POINTER :: const_g46_mol(:) - CHARACTER(LEN=default_string_length), POINTER :: const_g46_molname(:) - INTEGER, POINTER :: const_g46_a(:) - INTEGER, POINTER :: const_g46_b(:) - INTEGER, POINTER :: const_g46_c(:) - INTEGER, POINTER :: const_g46_d(:) - REAL(KIND=dp), POINTER :: const_g46_dab(:) - REAL(KIND=dp), POINTER :: const_g46_dac(:) - REAL(KIND=dp), POINTER :: const_g46_dbc(:) - REAL(KIND=dp), POINTER :: const_g46_dad(:) - REAL(KIND=dp), POINTER :: const_g46_dbd(:) - REAL(KIND=dp), POINTER :: const_g46_dcd(:) - LOGICAL, POINTER :: g46_intermolecular(:) - LOGICAL, POINTER :: g46_restraint(:) ! Restraints control - REAL(KIND=dp), POINTER :: g46_k0(:) ! Restraints control - LOGICAL, POINTER, DIMENSION(:) :: g46_exclude_qm, g46_exclude_mm + INTEGER :: nconst_g46 = -1 + INTEGER, POINTER :: const_g46_mol(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: const_g46_molname(:) => NULL() + INTEGER, POINTER :: const_g46_a(:) => NULL() + INTEGER, POINTER :: const_g46_b(:) => NULL() + INTEGER, POINTER :: const_g46_c(:) => NULL() + INTEGER, POINTER :: const_g46_d(:) => NULL() + REAL(KIND=dp), POINTER :: const_g46_dab(:) => NULL() + REAL(KIND=dp), POINTER :: const_g46_dac(:) => NULL() + REAL(KIND=dp), POINTER :: const_g46_dbc(:) => NULL() + REAL(KIND=dp), POINTER :: const_g46_dad(:) => NULL() + REAL(KIND=dp), POINTER :: const_g46_dbd(:) => NULL() + REAL(KIND=dp), POINTER :: const_g46_dcd(:) => NULL() + LOGICAL, POINTER :: g46_intermolecular(:) => NULL() + LOGICAL, POINTER :: g46_restraint(:) => NULL() ! Restraints control + REAL(KIND=dp), POINTER :: g46_k0(:) => NULL() ! Restraints control + LOGICAL, POINTER, DIMENSION(:) :: g46_exclude_qm => NULL(), g46_exclude_mm => NULL() ! virtual_site - INTEGER :: nconst_vsite - INTEGER, POINTER :: const_vsite_mol(:) - CHARACTER(LEN=default_string_length), POINTER :: const_vsite_molname(:) - INTEGER, POINTER :: const_vsite_a(:) - INTEGER, POINTER :: const_vsite_b(:) - INTEGER, POINTER :: const_vsite_c(:) - INTEGER, POINTER :: const_vsite_d(:) - REAL(KIND=dp), POINTER :: const_vsite_wbc(:) - REAL(KIND=dp), POINTER :: const_vsite_wdc(:) - LOGICAL, POINTER :: vsite_intermolecular(:) - LOGICAL, POINTER :: vsite_restraint(:) ! Restraints control - REAL(KIND=dp), POINTER :: vsite_k0(:) ! Restraints control - LOGICAL, POINTER, DIMENSION(:) :: vsite_exclude_qm, vsite_exclude_mm + INTEGER :: nconst_vsite = -1 + INTEGER, POINTER :: const_vsite_mol(:) => NULL() + CHARACTER(LEN=default_string_length), POINTER :: const_vsite_molname(:) => NULL() + INTEGER, POINTER :: const_vsite_a(:) => NULL() + INTEGER, POINTER :: const_vsite_b(:) => NULL() + INTEGER, POINTER :: const_vsite_c(:) => NULL() + INTEGER, POINTER :: const_vsite_d(:) => NULL() + REAL(KIND=dp), POINTER :: const_vsite_wbc(:) => NULL() + REAL(KIND=dp), POINTER :: const_vsite_wdc(:) => NULL() + LOGICAL, POINTER :: vsite_intermolecular(:) => NULL() + LOGICAL, POINTER :: vsite_restraint(:) => NULL() ! Restraints control + REAL(KIND=dp), POINTER :: vsite_k0(:) => NULL() ! Restraints control + LOGICAL, POINTER, DIMENSION(:) :: vsite_exclude_qm => NULL(), vsite_exclude_mm => NULL() END TYPE constraint_info_type ! ************************************************************************************************** TYPE topology_parameters_type - TYPE(atom_info_type), POINTER :: atom_info - TYPE(connectivity_info_type), POINTER :: conn_info - TYPE(constraint_info_type), POINTER :: cons_info - TYPE(cell_type), POINTER :: cell, cell_ref, cell_muc - INTEGER :: conn_type - INTEGER :: coord_type - INTEGER :: exclude_vdw - INTEGER :: exclude_ei - INTEGER :: bondparm_type + TYPE(atom_info_type), POINTER :: atom_info => NULL() + TYPE(connectivity_info_type), POINTER :: conn_info => NULL() + TYPE(constraint_info_type), POINTER :: cons_info => NULL() + TYPE(cell_type), POINTER :: cell => NULL(), cell_ref => NULL(), cell_muc => NULL() + INTEGER :: conn_type = -1 + INTEGER :: coord_type = -1 + INTEGER :: exclude_vdw = -1 + INTEGER :: exclude_ei = -1 + INTEGER :: bondparm_type = -1 !TRY TO REMOVE THIS FIVE VARIABLE IN THE FUTURE - INTEGER :: natoms, natom_type - INTEGER :: nmol, nmol_type, nmol_conn + INTEGER :: natoms = -1, natom_type = -1 + INTEGER :: nmol = -1, nmol_type = -1, nmol_conn = -1 !TRY TO REMOVE THIS FIVE VARIABLE IN THE FUTURE - LOGICAL :: aa_element - LOGICAL :: molname_generated - REAL(KIND=dp) :: bondparm_factor - LOGICAL :: create_molecules - LOGICAL :: reorder_atom - LOGICAL :: molecules_check - LOGICAL :: coordinate - LOGICAL :: use_g96_velocity - CHARACTER(LEN=default_path_length) :: coord_file_name - CHARACTER(LEN=default_path_length) :: conn_file_name - LOGICAL :: const_atom - LOGICAL :: const_hydr - LOGICAL :: const_colv - LOGICAL :: const_33 - LOGICAL :: const_46 - LOGICAL :: const_vsite - LOGICAL :: charge_occup - LOGICAL :: charge_beta - LOGICAL :: charge_extended - LOGICAL :: para_res + LOGICAL :: aa_element = .FALSE. + LOGICAL :: molname_generated = .FALSE. + REAL(KIND=dp) :: bondparm_factor = -1.0_dp + LOGICAL :: create_molecules = .FALSE. + LOGICAL :: reorder_atom = .FALSE. + LOGICAL :: molecules_check = .FALSE. + LOGICAL :: coordinate = .FALSE. + LOGICAL :: use_g96_velocity = .FALSE. + CHARACTER(LEN=default_path_length) :: coord_file_name = "" + CHARACTER(LEN=default_path_length) :: conn_file_name = "" + LOGICAL :: const_atom = .FALSE. + LOGICAL :: const_hydr = .FALSE. + LOGICAL :: const_colv = .FALSE. + LOGICAL :: const_33 = .FALSE. + LOGICAL :: const_46 = .FALSE. + LOGICAL :: const_vsite = .FALSE. + LOGICAL :: charge_occup = .FALSE. + LOGICAL :: charge_beta = .FALSE. + LOGICAL :: charge_extended = .FALSE. + LOGICAL :: para_res = .FALSE. END TYPE topology_parameters_type ! ************************************************************************************************** TYPE constr_list_type - INTEGER, DIMENSION(:), POINTER :: constr + INTEGER, DIMENSION(:), POINTER :: constr => NULL() END TYPE constr_list_type PUBLIC :: atom_info_type, & diff --git a/src/transport_env_types.F b/src/transport_env_types.F index d47990cf41..38070a8153 100644 --- a/src/transport_env_types.F +++ b/src/transport_env_types.F @@ -38,63 +38,63 @@ MODULE transport_env_types ! DO NOT change the ORDERING or the NAMES in the following data type TYPE, BIND(C) :: cp2k_transport_parameters - INTEGER(C_INT) :: n_occ - INTEGER(C_INT) :: n_atoms - REAL(C_DOUBLE) :: energy_diff - REAL(C_DOUBLE) :: evoltfactor - REAL(C_DOUBLE) :: e_charge - REAL(C_DOUBLE) :: boltzmann - REAL(C_DOUBLE) :: h_bar - INTEGER(C_INT) :: iscf - INTEGER(C_INT) :: method - INTEGER(C_INT) :: qt_formalism - INTEGER(C_INT) :: injection_method - INTEGER(C_INT) :: rlaxis_integration_method - INTEGER(C_INT) :: linear_solver - INTEGER(C_INT) :: matrixinv_method - INTEGER(C_INT) :: transport_neutral - INTEGER(C_INT) :: num_pole - INTEGER(C_INT) :: ordering - INTEGER(C_INT) :: row_ordering - INTEGER(C_INT) :: verbosity - INTEGER(C_INT) :: pexsi_np_symb_fact - INTEGER(C_INT) :: n_kpoint - INTEGER(C_INT) :: num_interval - INTEGER(C_INT) :: num_contacts - INTEGER(C_INT) :: stride_contacts - INTEGER(C_INT) :: tasks_per_energy_point - INTEGER(C_INT) :: tasks_per_pole - INTEGER(C_INT) :: gpus_per_point - INTEGER(C_INT) :: n_points_beyn - INTEGER(C_INT) :: ncrc_beyn - INTEGER(C_INT) :: tasks_per_integration_point - INTEGER(C_INT) :: n_points_inv - INTEGER(C_INT) :: cutout(2) - REAL(C_DOUBLE) :: colzero_threshold - REAL(C_DOUBLE) :: eps_limit - REAL(C_DOUBLE) :: eps_limit_cc - REAL(C_DOUBLE) :: eps_decay - REAL(C_DOUBLE) :: eps_singularity_curvatures - REAL(C_DOUBLE) :: eps_mu - REAL(C_DOUBLE) :: eps_eigval_degen - REAL(C_DOUBLE) :: eps_fermi - REAL(C_DOUBLE) :: energy_interval - REAL(C_DOUBLE) :: min_interval - REAL(C_DOUBLE) :: temperature - REAL(C_DOUBLE) :: dens_mixing - REAL(C_DOUBLE) :: n_rand_beyn - REAL(C_DOUBLE) :: n_rand_cc_beyn - REAL(C_DOUBLE) :: svd_cutoff - TYPE(C_PTR) :: contacts_data - TYPE(C_PTR) :: nsgf - TYPE(C_PTR) :: zeff - LOGICAL(C_BOOL) :: obc_equilibrium - LOGICAL(C_BOOL) :: extra_scf + INTEGER(C_INT) :: n_occ = -1_C_INT + INTEGER(C_INT) :: n_atoms = -1_C_INT + REAL(C_DOUBLE) :: energy_diff = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: evoltfactor = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: e_charge = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: boltzmann = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: h_bar = -1.0_C_DOUBLE + INTEGER(C_INT) :: iscf = -1_C_INT + INTEGER(C_INT) :: method = -1_C_INT + INTEGER(C_INT) :: qt_formalism = -1_C_INT + INTEGER(C_INT) :: injection_method = -1_C_INT + INTEGER(C_INT) :: rlaxis_integration_method = -1_C_INT + INTEGER(C_INT) :: linear_solver = -1_C_INT + INTEGER(C_INT) :: matrixinv_method = -1_C_INT + INTEGER(C_INT) :: transport_neutral = -1_C_INT + INTEGER(C_INT) :: num_pole = -1_C_INT + INTEGER(C_INT) :: ordering = -1_C_INT + INTEGER(C_INT) :: row_ordering = -1_C_INT + INTEGER(C_INT) :: verbosity = -1_C_INT + INTEGER(C_INT) :: pexsi_np_symb_fact = -1_C_INT + INTEGER(C_INT) :: n_kpoint = -1_C_INT + INTEGER(C_INT) :: num_interval = -1_C_INT + INTEGER(C_INT) :: num_contacts = -1_C_INT + INTEGER(C_INT) :: stride_contacts = -1_C_INT + INTEGER(C_INT) :: tasks_per_energy_point = -1_C_INT + INTEGER(C_INT) :: tasks_per_pole = -1_C_INT + INTEGER(C_INT) :: gpus_per_point = -1_C_INT + INTEGER(C_INT) :: n_points_beyn = -1_C_INT + INTEGER(C_INT) :: ncrc_beyn = -1_C_INT + INTEGER(C_INT) :: tasks_per_integration_point = -1_C_INT + INTEGER(C_INT) :: n_points_inv = -1_C_INT + INTEGER(C_INT) :: cutout(2) = -1_C_INT + REAL(C_DOUBLE) :: colzero_threshold = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: eps_limit = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: eps_limit_cc = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: eps_decay = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: eps_singularity_curvatures = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: eps_mu = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: eps_eigval_degen = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: eps_fermi = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: energy_interval = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: min_interval = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: temperature = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: dens_mixing = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: n_rand_beyn = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: n_rand_cc_beyn = -1.0_C_DOUBLE + REAL(C_DOUBLE) :: svd_cutoff = -1.0_C_DOUBLE + TYPE(C_PTR) :: contacts_data = C_NULL_PTR + TYPE(C_PTR) :: nsgf = C_NULL_PTR + TYPE(C_PTR) :: zeff = C_NULL_PTR + LOGICAL(C_BOOL) :: obc_equilibrium = .FALSE._C_BOOL + LOGICAL(C_BOOL) :: extra_scf = .FALSE._C_BOOL END TYPE cp2k_transport_parameters TYPE transport_env_type TYPE(C_FUNPTR) :: ext_c_method_ptr = C_NULL_FUNPTR - TYPE(cp2k_transport_parameters) :: params + TYPE(cp2k_transport_parameters) :: params = cp2k_transport_parameters() TYPE(dbcsr_type) :: template_matrix_sym TYPE(dbcsr_type) :: template_matrix_nosym TYPE(dbcsr_type) :: csr_sparsity @@ -103,7 +103,7 @@ MODULE transport_env_types TYPE(dbcsr_csr_type) :: ks_matrix TYPE(dbcsr_csr_type) :: p_matrix TYPE(dbcsr_csr_type) :: imagp_matrix - LOGICAL :: csr_screening + LOGICAL :: csr_screening = .FALSE. INTEGER, DIMENSION(:), POINTER :: contacts_data => NULL() INTEGER, DIMENSION(:), POINTER :: nsgf => NULL() REAL(dp), DIMENSION(:), POINTER :: zeff => NULL() @@ -111,17 +111,17 @@ MODULE transport_env_types ! DO NOT change the ORDERING or the NAMES in the following data type TYPE, BIND(C) :: cp2k_csr_interop_type - INTEGER(C_INT) :: nrows_total - INTEGER(C_INT) :: ncols_total - INTEGER(C_INT) :: nze_total - INTEGER(C_INT) :: nze_local - INTEGER(C_INT) :: nrows_local - INTEGER(C_INT) :: data_type - INTEGER(C_INT) :: first_row - TYPE(C_PTR) :: rowptr_local - TYPE(C_PTR) :: colind_local - TYPE(C_PTR) :: nzerow_local - TYPE(C_PTR) :: nzvals_local + INTEGER(C_INT) :: nrows_total = -1_C_INT + INTEGER(C_INT) :: ncols_total = -1_C_INT + INTEGER(C_INT) :: nze_total = -1_C_INT + INTEGER(C_INT) :: nze_local = -1_C_INT + INTEGER(C_INT) :: nrows_local = -1_C_INT + INTEGER(C_INT) :: data_type = -1_C_INT + INTEGER(C_INT) :: first_row = -1_C_INT + TYPE(C_PTR) :: rowptr_local = C_NULL_PTR + TYPE(C_PTR) :: colind_local = C_NULL_PTR + TYPE(C_PTR) :: nzerow_local = C_NULL_PTR + TYPE(C_PTR) :: nzvals_local = C_NULL_PTR END TYPE cp2k_csr_interop_type PUBLIC :: csr_interop_nullify, & diff --git a/src/xtb_matrices.F b/src/xtb_matrices.F index 47d3e04acd..0790e652a3 100644 --- a/src/xtb_matrices.F +++ b/src/xtb_matrices.F @@ -111,9 +111,9 @@ MODULE xtb_matrices IMPLICIT NONE TYPE neighbor_atoms_type - REAL(KIND=dp), DIMENSION(:, :), POINTER :: coord - REAL(KIND=dp), DIMENSION(:), POINTER :: rab - INTEGER, DIMENSION(:), POINTER :: katom + REAL(KIND=dp), DIMENSION(:, :), POINTER :: coord => NULL() + REAL(KIND=dp), DIMENSION(:), POINTER :: rab => NULL() + INTEGER, DIMENSION(:), POINTER :: katom => NULL() END TYPE neighbor_atoms_type PRIVATE diff --git a/src/xtb_types.F b/src/xtb_types.F index b467c7b289..da5ab47e9f 100644 --- a/src/xtb_types.F +++ b/src/xtb_types.F @@ -41,38 +41,38 @@ MODULE xtb_types ! ************************************************************************************************** TYPE xtb_atom_type ! PRIVATE - CHARACTER(LEN=default_string_length) :: typ - CHARACTER(LEN=default_string_length) :: aname - CHARACTER(LEN=2) :: symbol - LOGICAL :: defined - INTEGER :: z !atomic number - REAL(KIND=dp) :: zeff !effective core charge - INTEGER :: natorb !number of orbitals - INTEGER :: lmax !max angular momentum + CHARACTER(LEN=default_string_length) :: typ = "" + CHARACTER(LEN=default_string_length) :: aname = "" + CHARACTER(LEN=2) :: symbol = "" + LOGICAL :: defined = .FALSE. + INTEGER :: z = -1 !atomic number + REAL(KIND=dp) :: zeff = -1.0_dp !effective core charge + INTEGER :: natorb = -1 !number of orbitals + INTEGER :: lmax = -1 !max angular momentum ! - REAL(KIND=dp) :: rcut !cutoff radius for sr-Coulomb - REAL(KIND=dp) :: rcov !covalent radius - REAL(KIND=dp) :: electronegativity !electronegativity + REAL(KIND=dp) :: rcut = -1.0_dp !cutoff radius for sr-Coulomb + REAL(KIND=dp) :: rcov = -1.0_dp !covalent radius + REAL(KIND=dp) :: electronegativity = -1.0_dp !electronegativity ! - REAL(KIND=dp) :: kx !scaling for halogen term + REAL(KIND=dp) :: kx = -1.0_dp !scaling for halogen term ! - REAL(KIND=dp) :: eta !Atomic Hubbard parameter - REAL(KIND=dp) :: xgamma !charge derivative of eta - REAL(KIND=dp) :: alpha !exponential scaling parameter for repulsion potential - REAL(KIND=dp) :: zneff !effective core charge for repulsion potential + REAL(KIND=dp) :: eta = -1.0_dp !Atomic Hubbard parameter + REAL(KIND=dp) :: xgamma = -1.0_dp !charge derivative of eta + REAL(KIND=dp) :: alpha = -1.0_dp !exponential scaling parameter for repulsion potential + REAL(KIND=dp) :: zneff = -1.0_dp !effective core charge for repulsion potential ! shell specific parameters - INTEGER :: nshell !number of orbital shells - INTEGER, DIMENSION(5) :: nval ! n-quantum number of shell i - INTEGER, DIMENSION(5) :: lval ! l-quantum number of shell i - INTEGER, DIMENSION(5) :: occupation ! occupation of shell i - REAL(KIND=dp), DIMENSION(5) :: kpoly - REAL(KIND=dp), DIMENSION(5) :: kappa - REAL(KIND=dp), DIMENSION(5) :: hen - REAL(KIND=dp), DIMENSION(5) :: zeta + INTEGER :: nshell = -1 !number of orbital shells + INTEGER, DIMENSION(5) :: nval = -1 ! n-quantum number of shell i + INTEGER, DIMENSION(5) :: lval = -1 ! l-quantum number of shell i + INTEGER, DIMENSION(5) :: occupation = -1 ! occupation of shell i + REAL(KIND=dp), DIMENSION(5) :: kpoly = -1.0_dp + REAL(KIND=dp), DIMENSION(5) :: kappa = -1.0_dp + REAL(KIND=dp), DIMENSION(5) :: hen = -1.0_dp + REAL(KIND=dp), DIMENSION(5) :: zeta = -1.0_dp ! AO to shell pointer - INTEGER, DIMENSION(25) :: nao, lao + INTEGER, DIMENSION(25) :: nao = -1, lao = -1 ! Upper limit of Mulliken charge - REAL(KIND=dp) :: chmax + REAL(KIND=dp) :: chmax = -1.0_dp END TYPE xtb_atom_type ! *** Public data types *** diff --git a/tools/conventions/conventions.supp b/tools/conventions/conventions.supp index ed629b4748..46f992fe10 100644 --- a/tools/conventions/conventions.supp +++ b/tools/conventions/conventions.supp @@ -53,14 +53,6 @@ eip_silicon.F: Found WRITE statement with hardcoded unit in "eip_bazant_silicon" eip_silicon.F: Found WRITE statement with hardcoded unit in "eip_lenosky_silicon" https://cp2k.org/conv#c012 eip_silicon.F: Found WRITE statement with hardcoded unit in "subfeniat_b" https://cp2k.org/conv#c012 eip_silicon.F: Found WRITE statement with hardcoded unit in "subfeniat_l" https://cp2k.org/conv#c012 -ewald_environment_types.F: Found type ewald_environment_type without initializer https://cp2k.org/conv#c016 -ewalds_multipole.F: 'tij_a[0]' is used uninitialized [-Wuninitialized] -ewalds_multipole.F: 'tij_a[1]' is used uninitialized [-Wuninitialized] -ewalds_multipole.F: 'tij_ab[2]' is used uninitialized [-Wuninitialized] -ewalds_multipole.F: 'tij_ab[5]' is used uninitialized [-Wuninitialized] -exclusion_types.F: Found type exclusion_type without initializer https://cp2k.org/conv#c016 -exstates_types.F: Found type excited_energy_type without initializer https://cp2k.org/conv#c016 -exstates_types.F: Found type wfn_history_type without initializer https://cp2k.org/conv#c016 extended_system_init.F: Found WRITE statement with hardcoded unit in "init_barostat_variables" https://cp2k.org/conv#c012 extended_system_types.F: Found type lnhc_parameters_type without initializer https://cp2k.org/conv#c016 extended_system_types.F: Found type map_info_type without initializer https://cp2k.org/conv#c016 @@ -69,42 +61,14 @@ extended_system_types.F: Found type npt_info_type without initializer https://cp extended_system_types.F: Found type point_info_type without initializer https://cp2k.org/conv#c016 farming_methods.F: Found CLOSE statement in procedure "farming_parse_input" https://cp2k.org/conv#c204 farming_methods.F: Found OPEN statement in procedure "farming_parse_input" https://cp2k.org/conv#c203 -farming_types.F: Found type farming_env_type without initializer https://cp2k.org/conv#c016 -farming_types.F: Found type job_type without initializer https://cp2k.org/conv#c016 -fftw3_lib.F: 'dim_istride' is used uninitialized [-Wuninitialized] -fftw3_lib.F: 'dim_n' is used uninitialized [-Wuninitialized] -fftw3_lib.F: 'dim_ostride' is used uninitialized [-Wuninitialized] fftw3_lib.F: Same actual argument associated with INTENT(OUT) argument 'in' and INTENT(OUT) argument 'out' at (1) -fist_efield_types.F: Found type fist_efield_type without initializer https://cp2k.org/conv#c016 -fist_energy_types.F: Found type fist_energy_type without initializer https://cp2k.org/conv#c016 -fist_environment_types.F: Found type fist_environment_type without initializer https://cp2k.org/conv#c016 -fist_force.F: Found type debug_variables_type without initializer https://cp2k.org/conv#c016 -fist_neighbor_lists.F: Found type local_atoms_type without initializer https://cp2k.org/conv#c016 -fist_neighbor_list_types.F: Found type fist_neighbor_type without initializer https://cp2k.org/conv#c016 -fist_neighbor_list_types.F: Found type neighbor_kind_pairs_type without initializer https://cp2k.org/conv#c016 -force_field_types.F: Found type amber_info_type without initializer https://cp2k.org/conv#c016 -force_field_types.F: Found type charmm_info_type without initializer https://cp2k.org/conv#c016 -force_field_types.F: Found type force_field_type without initializer https://cp2k.org/conv#c016 -force_field_types.F: Found type gromos_info_type without initializer https://cp2k.org/conv#c016 -force_field_types.F: Found type input_info_type without initializer https://cp2k.org/conv#c016 fparser.F: Found WRITE statement with hardcoded unit in "parseerrmsg" https://cp2k.org/conv#c012 -fp_types.F: Found type fp_type without initializer https://cp2k.org/conv#c016 free_energy_methods.F: Found WRITE statement with hardcoded unit in "ui_check_norm_sc" https://cp2k.org/conv#c012 free_energy_methods.F: Found WRITE statement with hardcoded unit in "ui_check_norm_sc_low" https://cp2k.org/conv#c012 free_energy_methods.F: Found WRITE statement with hardcoded unit in "ui_check_trend" https://cp2k.org/conv#c012 -free_energy_types.F: Found type free_energy_type without initializer https://cp2k.org/conv#c016 -free_energy_types.F: Found type statistical_type without initializer https://cp2k.org/conv#c016 -free_energy_types.F: Found type ui_conv_type without initializer https://cp2k.org/conv#c016 -free_energy_types.F: Found type ui_var_type without initializer https://cp2k.org/conv#c016 glbopt_history.F: Found WRITE statement with hardcoded unit in "verify_history_lookup" https://cp2k.org/conv#c012 glbopt_mincrawl.F: Found WRITE statement with hardcoded unit in "print_tempdist" https://cp2k.org/conv#c012 -gle_system_types.F: Found type gle_thermo_type without initializer https://cp2k.org/conv#c016 -gle_system_types.F: Found type gle_type without initializer https://cp2k.org/conv#c016 graphcon.F: Found GOTO statement in procedure "all_permutations" https://cp2k.org/conv#c201 -graphcon.F: Found type class without initializer https://cp2k.org/conv#c016 -graphcon.F: Found type graph_type without initializer https://cp2k.org/conv#c016 -graphcon.F: Found type superclass without initializer https://cp2k.org/conv#c016 -graphcon.F: Found type vertex without initializer https://cp2k.org/conv#c016 graphcon.F: Found WRITE statement with hardcoded unit in "reorder_graph" https://cp2k.org/conv#c012 graph.F: Found CALL RANDOM_SEED in procedure "graph" https://cp2k.org/conv#c105 graph.F: Found WRITE statement with hardcoded unit in "graph" https://cp2k.org/conv#c012 @@ -113,57 +77,16 @@ graph_methods.F: Found WRITE statement with hardcoded unit in "fes_cube_write" h graph_methods.F: Found WRITE statement with hardcoded unit in "fes_min" https://cp2k.org/conv#c012 graph_methods.F: Found WRITE statement with hardcoded unit in "fes_path" https://cp2k.org/conv#c012 graph_utils.F: Found WRITE statement with hardcoded unit in "get_val_res" https://cp2k.org/conv#c012 -hartree_local_types.F: Found type ecoul_1center_type without initializer https://cp2k.org/conv#c016 -hartree_local_types.F: Found type hartree_local_type without initializer https://cp2k.org/conv#c016 hfx_compression_methods.F: Found READ with unchecked STAT in "hfx_decompress_cache" https://cp2k.org/conv#c001 hfx_energy_potential.F: Found WRITE statement with hardcoded unit in "print_integrals" https://cp2k.org/conv#c012 -hirshfeld_types.F: Found type hirshfeld_type without initializer https://cp2k.org/conv#c016 -hirshfeld_types.F: Found type shape_fn without initializer https://cp2k.org/conv#c016 input_enumeration_types.F: Found WRITE statement with hardcoded unit in "enum_i2c" https://cp2k.org/conv#c012 input_keyword_types.F: Found type keyword_type without initializer https://cp2k.org/conv#c016 input_parsing.F: Found WRITE statement with hardcoded unit in "section_vals_parse" https://cp2k.org/conv#c012 -integration_grid_types.F: Found type grid_batch_info_type without initializer https://cp2k.org/conv#c016 -integration_grid_types.F: Found type grid_batch_val_1d_type without initializer https://cp2k.org/conv#c016 -integration_grid_types.F: Found type grid_batch_val_2d_type without initializer https://cp2k.org/conv#c016 -integration_grid_types.F: Found type integration_grid_type without initializer https://cp2k.org/conv#c016 -integration_grid_types.F: Found type integration_grid_value_type without initializer https://cp2k.org/conv#c016 -integrator_utils.F: Found type old_variables_type without initializer https://cp2k.org/conv#c016 -integrator_utils.F: Found type tmp_variables_type without initializer https://cp2k.org/conv#c016 -kg_environment_types.F: Found type energy_correction_type without initializer https://cp2k.org/conv#c016 -kg_environment_types.F: Found type kg_environment_type without initializer https://cp2k.org/conv#c016 -kg_environment_types.F: Found type subset_type without initializer https://cp2k.org/conv#c016 -kg_vertex_coloring_methods.F: Found type vertex_p_type without initializer https://cp2k.org/conv#c016 -kg_vertex_coloring_methods.F: Found type vertex without initializer https://cp2k.org/conv#c016 -kpoint_types.F: Found type kpoint_env_p_type without initializer https://cp2k.org/conv#c016 -kpoint_types.F: Found type kpoint_env_type without initializer https://cp2k.org/conv#c016 -kpoint_types.F: Found type kpoint_sym_p_type without initializer https://cp2k.org/conv#c016 -kpoint_types.F: Found type kpoint_sym_type without initializer https://cp2k.org/conv#c016 -kpoint_types.F: Found type kpoint_type without initializer https://cp2k.org/conv#c016 libcp2k.F: Found type eri2array without initializer https://cp2k.org/conv#c016 library_tests.F: Found CALL RANDOM_NUMBER in procedure "copy_test" https://cp2k.org/conv#c104 library_tests.F: Found CALL RANDOM_NUMBER in procedure "cp_fm_gemm_test" https://cp2k.org/conv#c104 library_tests.F: Found CALL RANDOM_NUMBER in procedure "fft_test" https://cp2k.org/conv#c104 library_tests.F: Found CALL RANDOM_NUMBER in procedure "rs_pw_transfer_test" https://cp2k.org/conv#c104 -lri_environment_types.F: Found type carray without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type int_container without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_bas_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_clebsch_gordon_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_environment_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_force_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_int_rho_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_int_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_kind_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_ppl_int_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_ppl_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_rhoab_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type lri_spin_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type ri_fit_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type stat_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type wbas_type without initializer https://cp2k.org/conv#c016 -lri_environment_types.F: Found type wmat_type without initializer https://cp2k.org/conv#c016 -lri_optimize_ri_basis_types.F: Found type lri_gcc_p_type without initializer https://cp2k.org/conv#c016 -lri_optimize_ri_basis_types.F: Found type lri_opt_type without initializer https://cp2k.org/conv#c016 -lri_optimize_ri_basis_types.F: Found type lri_subset_type without initializer https://cp2k.org/conv#c016 machine.F: Found CALL m_abort in procedure "m_getcwd" https://cp2k.org/conv#c102 machine.F: Found CALL m_abort in procedure "m_hostnm" https://cp2k.org/conv#c102 machine.F: Found CALL m_abort in procedure "m_mov" https://cp2k.org/conv#c102 @@ -174,12 +97,9 @@ machine.F: Found OPEN statement in procedure "m_memory" https://cp2k.org/conv#c2 machine.F: Found WRITE statement with hardcoded unit in "m_getcwd" https://cp2k.org/conv#c012 machine.F: Found WRITE statement with hardcoded unit in "m_hostnm" https://cp2k.org/conv#c012 machine.F: Found WRITE statement with hardcoded unit in "m_mov" https://cp2k.org/conv#c012 -mao_methods.F: Found type mblocks without initializer https://cp2k.org/conv#c016 -mao_types.F: Found type mao_type without initializer https://cp2k.org/conv#c016 mathlib.F: Found WRITE statement with hardcoded unit in "diag" https://cp2k.org/conv#c012 mc_coordinates.F: Found WRITE statement with hardcoded unit in "generate_cbmc_swap_config" https://cp2k.org/conv#c012 mc_move_control.F: Found WRITE statement with hardcoded unit in "mc_move_update" https://cp2k.org/conv#c012 -mdctrl_types.F: Found type glbopt_mdctrl_data_type without initializer https://cp2k.org/conv#c016 memory_utilities_unittest.F: Found WRITE statement with hardcoded unit in "check_real_rank1_allocated" https://cp2k.org/conv#c012 memory_utilities_unittest.F: Found WRITE statement with hardcoded unit in "check_real_rank1_unallocated" https://cp2k.org/conv#c012 memory_utilities_unittest.F: Found WRITE statement with hardcoded unit in "check_real_rank2_allocated" https://cp2k.org/conv#c012 @@ -198,57 +118,12 @@ message_passing.fypp: Rank mismatch between actual argument at (1) and actual ar message_passing.fypp: Rank mismatch between actual argument at (1) and actual argument at (2) (scalar and rank-3) message_passing.fypp: Rank mismatch between actual argument at (1) and actual argument at (2) (scalar and rank-4) message_passing.fypp: Type mismatch between actual argument at (1) and actual argument at (2) (COMPLEX(8)/COMPLEX(4)). -metadynamics_types.F: Found type hills_env_type without initializer https://cp2k.org/conv#c016 -metadynamics_types.F: Found type meta_env_type without initializer https://cp2k.org/conv#c016 -metadynamics_types.F: Found type metavar_type without initializer https://cp2k.org/conv#c016 -metadynamics_types.F: Found type multiple_walkers_type without initializer https://cp2k.org/conv#c016 -metadynamics_types.F: Found type wall_type without initializer https://cp2k.org/conv#c016 -mixed_cdft_types.F: Found type buffers without initializer https://cp2k.org/conv#c016 -mixed_cdft_types.F: Found type mixed_cdft_dlb_type without initializer https://cp2k.org/conv#c016 -mixed_cdft_types.F: Found type mixed_cdft_settings_type without initializer https://cp2k.org/conv#c016 -mixed_cdft_types.F: Found type mixed_cdft_type without initializer https://cp2k.org/conv#c016 -mixed_cdft_types.F: Found type mixed_cdft_work_type without initializer https://cp2k.org/conv#c016 -mixed_cdft_types.F: Found type p_buffers without initializer https://cp2k.org/conv#c016 -mixed_cdft_types.F: Found type repl_info without initializer https://cp2k.org/conv#c016 -mixed_energy_types.F: Found type mixed_energy_type without initializer https://cp2k.org/conv#c016 -mixed_energy_types.F: Found type mixed_force_type without initializer https://cp2k.org/conv#c016 mltfftsg_tools.F: Found WRITE statement with hardcoded unit in "ctrig" https://cp2k.org/conv#c012 -mm_mapping_library.F: Found type ff_map_type without initializer https://cp2k.org/conv#c016 mode_selective.F: Found READ with unchecked STAT in "bfgs_guess" https://cp2k.org/conv#c001 -mode_selective.F: Found type ms_vib_type without initializer https://cp2k.org/conv#c016 -molsym.F: Found type molsym_type without initializer https://cp2k.org/conv#c016 -mscfg_types.F: Found type molecular_scf_guess_env_type without initializer https://cp2k.org/conv#c016 -negf_atom_map.F: Found type negf_atom_map_type without initializer https://cp2k.org/conv#c016 -negf_control_types.F: Found type negf_control_contact_type without initializer https://cp2k.org/conv#c016 -negf_control_types.F: Found type negf_control_type without initializer https://cp2k.org/conv#c016 -negf_env_types.F: Found type negf_env_contact_type without initializer https://cp2k.org/conv#c016 -negf_env_types.F: Found type negf_env_type without initializer https://cp2k.org/conv#c016 -negf_green_methods.F: Found type sancho_work_matrices_type without initializer https://cp2k.org/conv#c016 -negf_integr_cc.F: Found type ccquad_type without initializer https://cp2k.org/conv#c016 -negf_integr_simpson.F: Found type simpsonrule_subinterval_type without initializer https://cp2k.org/conv#c016 -negf_integr_simpson.F: Found type simpsonrule_type without initializer https://cp2k.org/conv#c016 negf_methods.F: Found CALL with NULL() as argument in procedure "converge_density" https://cp2k.org/conv#c007 negf_methods.F: Found CALL with NULL() as argument in procedure "guess_fermi_level" https://cp2k.org/conv#c007 negf_methods.F: Found CALL with NULL() as argument in procedure "shift_potential" https://cp2k.org/conv#c007 -negf_methods.F: Found type integration_status_type without initializer https://cp2k.org/conv#c016 nequip_unittest.F: Found WRITE statement with hardcoded unit in "nequip_unittest" https://cp2k.org/conv#c012 -nnp_environment_types.F: Found type nnp_acsf_ang_type without initializer https://cp2k.org/conv#c016 -nnp_environment_types.F: Found type nnp_acsf_rad_type without initializer https://cp2k.org/conv#c016 -nnp_environment_types.F: Found type nnp_arc_type without initializer https://cp2k.org/conv#c016 -nnp_environment_types.F: Found type nnp_neighbor_type without initializer https://cp2k.org/conv#c016 -nnp_environment_types.F: Found type nnp_symfgrp_type without initializer https://cp2k.org/conv#c016 -nnp_environment_types.F: Found type nnp_type without initializer https://cp2k.org/conv#c016 -optimize_basis_types.F: Found type basis_optimization_type without initializer https://cp2k.org/conv#c016 -optimize_basis_types.F: Found type derived_basis_info without initializer https://cp2k.org/conv#c016 -optimize_basis_types.F: Found type exp_constraint_type without initializer https://cp2k.org/conv#c016 -optimize_basis_types.F: Found type flex_basis_type without initializer https://cp2k.org/conv#c016 -optimize_basis_types.F: Found type kind_basis_type without initializer https://cp2k.org/conv#c016 -optimize_basis_types.F: Found type subset_type without initializer https://cp2k.org/conv#c016 -optimize_input.F: Found type fm_env_type without initializer https://cp2k.org/conv#c016 -optimize_input.F: Found type oi_env_type without initializer https://cp2k.org/conv#c016 -optimize_input.F: Found type variable_type without initializer https://cp2k.org/conv#c016 -outer_scf_control_types.F: Found type outer_scf_control_type without initializer https://cp2k.org/conv#c016 -outer_scf_control_types.F: Found type qs_outer_scf_type without initializer https://cp2k.org/conv#c016 parallel_gemm_api.F: Found CALL cp_fm_gemm in procedure "parallel_gemm_fm" https://cp2k.org/conv#c101 parallel_rng_types_unittest.F: Found WRITE statement with hardcoded unit in "dump_reload_check" https://cp2k.org/conv#c012 parallel_rng_types_unittest.F: Found WRITE statement with hardcoded unit in "parallel_rng_types_test" https://cp2k.org/conv#c012 @@ -257,8 +132,6 @@ pexsi_types.F: Found type lib_pexsi_env without initializer https://cp2k.org/con powell.F: Found GOTO statement in procedure "newuob" https://cp2k.org/conv#c201 preconditioner_makes.F: Found WRITE statement with hardcoded unit in "make_full_all" https://cp2k.org/conv#c012 preconditioner_makes.F: Found WRITE statement with hardcoded unit in "make_full_all_ortho" https://cp2k.org/conv#c012 -preconditioner_types.F: Found type preconditioner_p_type without initializer https://cp2k.org/conv#c016 -preconditioner_types.F: Found type preconditioner_type without initializer https://cp2k.org/conv#c016 ps_implicit_methods.F: OMP PARALLEL without DEFAULT(NONE) found in "ps_implicit_prepare_blocks" https://cp2k.org/conv#c006 ps_wavelet_base.F: Found WRITE statement with hardcoded unit in "f_poissonsolver" https://cp2k.org/conv#c012 ps_wavelet_base.F: Found WRITE statement with hardcoded unit in "p_poissonsolver" https://cp2k.org/conv#c012 @@ -272,160 +145,25 @@ ps_wavelet_scaling_function.F: Found WRITE statement with hardcoded unit in "wav ps_wavelet_util.F: Found WRITE statement with hardcoded unit in "p_fft_dimensions" https://cp2k.org/conv#c012 ps_wavelet_util.F: Found WRITE statement with hardcoded unit in "s_fft_dimensions" https://cp2k.org/conv#c012 pw_grids.F: Found WRITE statement with hardcoded unit in "pw_grid_sort" https://cp2k.org/conv#c012 -qmmm_gaussian_types.F: Found type qmmm_gaussian_p_type without initializer https://cp2k.org/conv#c016 -qmmm_gaussian_types.F: Found type qmmm_gaussian_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type add_env_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type add_set_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type add_shell_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type gridlevel_info_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type image_charge_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_env_mm_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_env_qm_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_imomm_link_p_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_imomm_link_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_links_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_per_pot_p_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_per_pot_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_pot_p_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_pot_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_pseudo_link_p_type without initializer https://cp2k.org/conv#c016 -qmmm_types_low.F: Found type qmmm_pseudo_link_type without initializer https://cp2k.org/conv#c016 qs_active_space_methods.F: Found type eri_fcidump_checksum without initializer https://cp2k.org/conv#c016 qs_active_space_methods.F: Found type eri_fcidump_print without initializer https://cp2k.org/conv#c016 -qs_atomic_block.F: Found type atom_matrix_type without initializer https://cp2k.org/conv#c016 -qs_block_davidson_types.F: Found type davidson_type without initializer https://cp2k.org/conv#c016 -qs_cdft_opt_types.F: Found type cdft_opt_type without initializer https://cp2k.org/conv#c016 -qs_cdft_types.F: Found type becke_constraint_type without initializer https://cp2k.org/conv#c016 -qs_cdft_types.F: Found type becke_vector_buffer without initializer https://cp2k.org/conv#c016 -qs_cdft_types.F: Found type cdft_control_type without initializer https://cp2k.org/conv#c016 -qs_cdft_types.F: Found type cdft_group_type without initializer https://cp2k.org/conv#c016 -qs_cdft_types.F: Found type hirshfeld_constraint_type without initializer https://cp2k.org/conv#c016 -qs_charges_types.F: Found type qs_charges_type without initializer https://cp2k.org/conv#c016 -qs_density_mixing_types.F: Found type cp_1d_z_p_type without initializer https://cp2k.org/conv#c016 -qs_density_mixing_types.F: Found type mixing_storage_type without initializer https://cp2k.org/conv#c016 -qs_dftb_types.F: Found type qs_dftb_atom_type without initializer https://cp2k.org/conv#c016 -qs_dftb_types.F: Found type qs_dftb_pairpot_type without initializer https://cp2k.org/conv#c016 -qs_dispersion_pairpot.F: Found type dcnum_type without initializer https://cp2k.org/conv#c016 -qs_dispersion_types.F: Found type cn_atom_list without initializer https://cp2k.org/conv#c016 -qs_dispersion_types.F: Found type cn_kind_list without initializer https://cp2k.org/conv#c016 -qs_dispersion_types.F: Found type qs_atom_dispersion_type without initializer https://cp2k.org/conv#c016 -qs_dispersion_types.F: Found type qs_dispersion_type without initializer https://cp2k.org/conv#c016 -qs_energy_types.F: Found type qs_energy_type without initializer https://cp2k.org/conv#c016 -qs_environment_types.F: Found type qs_environment_type without initializer https://cp2k.org/conv#c016 qs_external_density.F: Found WRITE statement with hardcoded unit in "external_read_density" https://cp2k.org/conv#c012 -qs_fb_atomic_halo_types.F: Found type fb_atomic_halo_data without initializer https://cp2k.org/conv#c016 -qs_fb_atomic_halo_types.F: Found type fb_atomic_halo_list_data without initializer https://cp2k.org/conv#c016 -qs_fb_atomic_halo_types.F: Found type fb_atomic_halo_list_obj without initializer https://cp2k.org/conv#c016 -qs_fb_atomic_halo_types.F: Found type fb_atomic_halo_obj without initializer https://cp2k.org/conv#c016 -qs_fb_buffer_types.F: Found type fb_buffer_d_data without initializer https://cp2k.org/conv#c016 -qs_fb_buffer_types.F: Found type fb_buffer_i_data without initializer https://cp2k.org/conv#c016 -qs_fb_com_tasks_types.F: Found type fb_com_atom_pairs_data without initializer https://cp2k.org/conv#c016 -qs_fb_com_tasks_types.F: Found type fb_com_atom_pairs_obj without initializer https://cp2k.org/conv#c016 -qs_fb_com_tasks_types.F: Found type fb_com_tasks_data without initializer https://cp2k.org/conv#c016 -qs_fb_com_tasks_types.F: Found type fb_com_tasks_obj without initializer https://cp2k.org/conv#c016 -qs_fb_distribution_methods.F: Found type fb_distribution_element without initializer https://cp2k.org/conv#c016 -qs_fb_distribution_methods.F: Found type fb_distribution_list without initializer https://cp2k.org/conv#c016 -qs_fb_distribution_methods.F: Found type fb_preferred_procs_list without initializer https://cp2k.org/conv#c016 qs_fb_env_methods.F: Found CALL cp_fm_gemm in procedure "fb_env_do_diag" https://cp2k.org/conv#c101 -qs_fb_env_types.F: Found type fb_env_data without initializer https://cp2k.org/conv#c016 -qs_fb_env_types.F: Found type fb_env_obj without initializer https://cp2k.org/conv#c016 qs_fb_filter_matrix_methods.F: Found WRITE statement with hardcoded unit in "fb_fltrmat_build_atomic_fltrmat" https://cp2k.org/conv#c012 -qs_fb_hash_table_types.F: Found type fb_hash_table_data without initializer https://cp2k.org/conv#c016 -qs_fb_hash_table_types.F: Found type fb_hash_table_element without initializer https://cp2k.org/conv#c016 -qs_fb_matrix_data_types.F: Found type fb_matrix_data_data without initializer https://cp2k.org/conv#c016 -qs_fb_trial_fns_types.F: Found type fb_trial_fns_data without initializer https://cp2k.org/conv#c016 -qs_fb_trial_fns_types.F: Found type fb_trial_fns_obj without initializer https://cp2k.org/conv#c016 -qs_force_types.F: Found type qs_force_type without initializer https://cp2k.org/conv#c016 -qs_gcp_types.F: Found type qs_gcp_kind_type without initializer https://cp2k.org/conv#c016 -qs_gcp_types.F: Found type qs_gcp_type without initializer https://cp2k.org/conv#c016 -qs_grid_atom.F: Found type atom_integration_grid_type without initializer https://cp2k.org/conv#c016 -qs_grid_atom.F: Found type grid_atom_type without initializer https://cp2k.org/conv#c016 -qs_grid_atom.F: Found type grid_batch_type without initializer https://cp2k.org/conv#c016 -qs_harmonics_atom.F: Found type harmonics_atom_type without initializer https://cp2k.org/conv#c016 -qs_initial_guess.F: Found type atom_matrix_type without initializer https://cp2k.org/conv#c016 qs_initial_guess.F: Found WRITE statement with hardcoded unit in "calculate_first_density_matrix" https://cp2k.org/conv#c012 -qs_kernel_types.F: Found type full_kernel_env_type without initializer https://cp2k.org/conv#c016 -qs_kind_types.F: Found type dft_plus_u_type without initializer https://cp2k.org/conv#c016 -qs_kind_types.F: Found type qs_kind_p_type without initializer https://cp2k.org/conv#c016 -qs_ks_qmmm_types.F: Found type qs_ks_qmmm_env_type without initializer https://cp2k.org/conv#c016 qs_linres_atom_current.F: Found WRITE statement with hardcoded unit in "calculate_jrho_atom_rad" https://cp2k.org/conv#c012 -qs_linres_current.F: Found type box_type without initializer https://cp2k.org/conv#c016 qs_linres_current.F: Found WRITE statement with hardcoded unit in "box_atoms" https://cp2k.org/conv#c012 qs_linres_current.F: Found WRITE statement with hardcoded unit in "box_atoms_new" https://cp2k.org/conv#c012 qs_linres_current.F: Found WRITE statement with hardcoded unit in "calculate_jrho_resp" https://cp2k.org/conv#c012 qs_linres_current.F: Found WRITE statement with hardcoded unit in "collocate_gauge_new" https://cp2k.org/conv#c012 qs_linres_issc_utils.F: Found WRITE statement with hardcoded unit in "issc_issc" https://cp2k.org/conv#c012 -qs_localization_methods.F: Found type set_c_1d_type without initializer https://cp2k.org/conv#c016 -qs_localization_methods.F: Found type set_c_2d_type without initializer https://cp2k.org/conv#c016 -qs_local_rho_types.F: Found type local_rho_type without initializer https://cp2k.org/conv#c016 -qs_local_rho_types.F: Found type rhoz_type without initializer https://cp2k.org/conv#c016 -qs_loc_types.F: Found type localized_wfn_control_type without initializer https://cp2k.org/conv#c016 -qs_loc_types.F: Found type qs_loc_env_type without initializer https://cp2k.org/conv#c016 -qs_matrix_pools.F: Found type qs_matrix_pools_type without initializer https://cp2k.org/conv#c016 -qs_mo_types.F: Found type mo_set_p_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_lists.F: Found type local_atoms_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type list_search_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type neighbor_list_iterator_p_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type neighbor_list_iterator_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type neighbor_list_p_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type neighbor_list_set_p_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type neighbor_list_set_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type neighbor_list_task_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type neighbor_list_type without initializer https://cp2k.org/conv#c016 -qs_neighbor_list_types.F: Found type neighbor_node_type without initializer https://cp2k.org/conv#c016 -qs_nl_hash_table_types.F: Found type nl_hash_table_data without initializer https://cp2k.org/conv#c016 -qs_nl_hash_table_types.F: Found type nl_hash_table_element without initializer https://cp2k.org/conv#c016 -qs_o3c_types.F: Found type o3c_container_type without initializer https://cp2k.org/conv#c016 -qs_o3c_types.F: Found type o3c_int_type without initializer https://cp2k.org/conv#c016 -qs_o3c_types.F: Found type o3c_iterator_type without initializer https://cp2k.org/conv#c016 -qs_o3c_types.F: Found type o3c_pair_type without initializer https://cp2k.org/conv#c016 -qs_o3c_types.F: Found type o3c_vec_type without initializer https://cp2k.org/conv#c016 qs_ot.F: Found WRITE statement with hardcoded unit in "qs_ot_generate_rotation" https://cp2k.org/conv#c012 -qs_ot_types.F: Found type qs_ot_settings_type without initializer https://cp2k.org/conv#c016 -qs_ot_types.F: Found type qs_ot_type without initializer https://cp2k.org/conv#c016 -qs_pdos.F: Found type ldos_p_type without initializer https://cp2k.org/conv#c016 -qs_pdos.F: Found type ldos_type without initializer https://cp2k.org/conv#c016 -qs_pdos.F: Found type r_ldos_p_type without initializer https://cp2k.org/conv#c016 -qs_pdos.F: Found type r_ldos_type without initializer https://cp2k.org/conv#c016 -qs_p_env_types.F: Found type qs_p_env_type without initializer https://cp2k.org/conv#c016 -qs_period_efield_types.F: Found type efield_berry_type without initializer https://cp2k.org/conv#c016 -qs_resp.F: Found type resp_p_type without initializer https://cp2k.org/conv#c016 -qs_resp.F: Found type resp_type without initializer https://cp2k.org/conv#c016 -qs_rho0_types.F: Found type mpole_gau_overlap without initializer https://cp2k.org/conv#c016 -qs_rho0_types.F: Found type mpole_rho_atom without initializer https://cp2k.org/conv#c016 -qs_rho0_types.F: Found type rho0_atom_type without initializer https://cp2k.org/conv#c016 -qs_rho0_types.F: Found type rho0_mpole_type without initializer https://cp2k.org/conv#c016 qs_rho_atom_methods.F: Found WRITE statement with hardcoded unit in "init_rho_atom" https://cp2k.org/conv#c012 -qs_rho_types.F: Found type qs_rho_p_type without initializer https://cp2k.org/conv#c016 -qs_scf_types.F: Found type floating_basis_type without initializer https://cp2k.org/conv#c016 -qs_scf_types.F: Found type krylov_space_type without initializer https://cp2k.org/conv#c016 -qs_scf_types.F: Found type qs_scf_env_type without initializer https://cp2k.org/conv#c016 -qs_scf_types.F: Found type subspace_env_type without initializer https://cp2k.org/conv#c016 -qs_tddfpt2_stda_types.F: Found type stda_env_type without initializer https://cp2k.org/conv#c016 -qs_tddfpt2_stda_types.F: Found type stda_kind_p_type without initializer https://cp2k.org/conv#c016 -qs_tddfpt2_stda_types.F: Found type stda_kind_type without initializer https://cp2k.org/conv#c016 -qs_tddfpt2_types.F: Found type tddfpt_ground_state_mos without initializer https://cp2k.org/conv#c016 -qs_tddfpt2_types.F: Found type tddfpt_work_matrices without initializer https://cp2k.org/conv#c016 -qs_tddfpt_types.F: Found type tddfpt_env_type without initializer https://cp2k.org/conv#c016 -qs_tddfpt_utils.F: Found type simple_solution_sorter without initializer https://cp2k.org/conv#c016 -qs_wannier90.F: Found type berry_matrix_type without initializer https://cp2k.org/conv#c016 -qs_wf_history_types.F: Found type qs_wf_history_p_type without initializer https://cp2k.org/conv#c016 -qs_wf_history_types.F: Found type qs_wf_history_type without initializer https://cp2k.org/conv#c016 -qs_wf_history_types.F: Found type qs_wf_snapshot_p_type without initializer https://cp2k.org/conv#c016 -qs_wf_history_types.F: Found type qs_wf_snapshot_type without initializer https://cp2k.org/conv#c016 -rel_control_types.F: Found type rel_control_type without initializer https://cp2k.org/conv#c016 -replica_types.F: Found type replica_env_p_type without initializer https://cp2k.org/conv#c016 -replica_types.F: Found type replica_env_type without initializer https://cp2k.org/conv#c016 -scf_control_types.F: Found type diagonalization_type without initializer https://cp2k.org/conv#c016 -scf_control_types.F: Found type scf_control_type without initializer https://cp2k.org/conv#c016 -scf_control_types.F: Found type smear_type without initializer https://cp2k.org/conv#c016 se_core_matrix.F: Found WRITE statement with hardcoded unit in "aa" https://cp2k.org/conv#c012 se_core_matrix.F: Found WRITE statement with hardcoded unit in "makeds" https://cp2k.org/conv#c012 se_core_matrix.F: Found WRITE statement with hardcoded unit in "makes" https://cp2k.org/conv#c012 se_fock_matrix_coulomb.F: Found WRITE statement with hardcoded unit in "build_fock_matrix_coulomb_lr" https://cp2k.org/conv#c012 se_fock_matrix_dbg.F: Found WRITE statement with hardcoded unit in "dbg_energy_coulomb_lr" https://cp2k.org/conv#c012 -semi_empirical_expns3_types.F: Found type semi_empirical_expns3_p_type without initializer https://cp2k.org/conv#c016 -semi_empirical_expns3_types.F: Found type semi_empirical_expns3_type without initializer https://cp2k.org/conv#c016 semi_empirical_int_debug.F: Found WRITE statement with hardcoded unit in "check_dcorecore_ana" https://cp2k.org/conv#c012 semi_empirical_int_debug.F: Found WRITE statement with hardcoded unit in "check_dcore_nucint_ana" https://cp2k.org/conv#c012 semi_empirical_int_debug.F: Found WRITE statement with hardcoded unit in "check_drotnuc_ana" https://cp2k.org/conv#c012 @@ -435,38 +173,14 @@ semi_empirical_int_debug.F: Found WRITE statement with hardcoded unit in "check_ semi_empirical_int_debug.F: Found WRITE statement with hardcoded unit in "check_rotmat_der" https://cp2k.org/conv#c012 semi_empirical_int_debug.F: Found WRITE statement with hardcoded unit in "check_value" https://cp2k.org/conv#c012 semi_empirical_int_debug.F: Found WRITE statement with hardcoded unit in "rot_2el_2c_first_debug" https://cp2k.org/conv#c012 -semi_empirical_int_debug.F: Procedure 'check_value' called with an implicit interface at (1) [-Wimplicit-interface] semi_empirical_mpole_methods.F: Found WRITE statement with hardcoded unit in "semi_empirical_mpole_p_setup" https://cp2k.org/conv#c012 -semi_empirical_mpole_types.F: Found type nddo_mpole_type without initializer https://cp2k.org/conv#c016 -semi_empirical_mpole_types.F: Found type semi_empirical_mpole_p_type without initializer https://cp2k.org/conv#c016 -semi_empirical_mpole_types.F: Found type semi_empirical_mpole_type without initializer https://cp2k.org/conv#c016 -semi_empirical_store_int_types.F: Found type semi_empirical_si_type without initializer https://cp2k.org/conv#c016 -semi_empirical_types.F: Found type ewald_gks_type without initializer https://cp2k.org/conv#c016 -semi_empirical_types.F: Found type rotmat_type without initializer https://cp2k.org/conv#c016 -semi_empirical_types.F: Found type se_int_control_type without initializer https://cp2k.org/conv#c016 -semi_empirical_types.F: Found type se_int_screen_type without initializer https://cp2k.org/conv#c016 -semi_empirical_types.F: Found type semi_empirical_p_type without initializer https://cp2k.org/conv#c016 -semi_empirical_types.F: Found type semi_empirical_type without initializer https://cp2k.org/conv#c016 -semi_empirical_types.F: Found type se_taper_type without initializer https://cp2k.org/conv#c016 -simpar_types.F: Found type simpar_type without initializer https://cp2k.org/conv#c016 spherical_harmonics.F: Found WRITE statement with hardcoded unit in "cgc" https://cp2k.org/conv#c012 spherical_harmonics.F: Found WRITE statement with hardcoded unit in "get_factor" https://cp2k.org/conv#c012 -splines_types.F: Found type spline_data_pp_type without initializer https://cp2k.org/conv#c016 -splines_types.F: Found type spline_data_p_type without initializer https://cp2k.org/conv#c016 -splines_types.F: Found type spline_data_type without initializer https://cp2k.org/conv#c016 -splines_types.F: Found type spline_environment_type without initializer https://cp2k.org/conv#c016 -splines_types.F: Found type spline_factor_type without initializer https://cp2k.org/conv#c016 statistical_methods.F: Found WRITE statement with hardcoded unit in "tests" https://cp2k.org/conv#c012 -subcell_types.F: Found type subcell_type without initializer https://cp2k.org/conv#c016 -submatrix_dissection.F: Found type submatrix_dissection_type without initializer https://cp2k.org/conv#c016 -submatrix_types.F: Found type buffer_type without initializer https://cp2k.org/conv#c016 -submatrix_types.F: Found type intbuffer_type without initializer https://cp2k.org/conv#c016 swarm_mpi.F: Found CLOSE statement in procedure "logger_init_master" https://cp2k.org/conv#c204 swarm_mpi.F: Found OPEN statement in procedure "logger_finalize" https://cp2k.org/conv#c203 -taper_types.F: Found type taper_type without initializer https://cp2k.org/conv#c016 task_list_methods.F: Found WRITE statement with hardcoded unit in "generate_qs_task_list" https://cp2k.org/conv#c012 timings.F: Found WRITE statement with hardcoded unit in "timestop_handler" https://cp2k.org/conv#c012 -tip_scan_types.F: Found type scanning_type without initializer https://cp2k.org/conv#c016 tmc_analysis.F: Found WRITE statement with hardcoded unit in "print_average_displacement" https://cp2k.org/conv#c012 tmc_analysis.F: Found WRITE statement with hardcoded unit in "print_dipole_moment" https://cp2k.org/conv#c012 tmc_analysis.F: Found WRITE statement with hardcoded unit in "print_paircorrelation" https://cp2k.org/conv#c012 @@ -483,13 +197,6 @@ topology_generate_util.F: Found WRITE statement with hardcoded unit in "generate topology_generate_util.F: Found WRITE statement with hardcoded unit in "topology_generate_molecule" https://cp2k.org/conv#c012 topology_gromos.F: Found READ with unchecked STAT in "read_topology_gromos" https://cp2k.org/conv#c001 topology_pdb.F: Found READ with unchecked STAT in "read_coordinate_pdb" https://cp2k.org/conv#c001 -topology_types.F: Found type atom_info_type without initializer https://cp2k.org/conv#c016 -topology_types.F: Found type connectivity_info_type without initializer https://cp2k.org/conv#c016 -topology_types.F: Found type constraint_info_type without initializer https://cp2k.org/conv#c016 -topology_types.F: Found type constr_list_type without initializer https://cp2k.org/conv#c016 -topology_types.F: Found type topology_parameters_type without initializer https://cp2k.org/conv#c016 -transport_env_types.F: Found type cp2k_csr_interop_type without initializer https://cp2k.org/conv#c016 -transport_env_types.F: Found type cp2k_transport_parameters without initializer https://cp2k.org/conv#c016 transport_env_types.F: Found type transport_env_type without initializer https://cp2k.org/conv#c016 xc.F: Found CLOSE statement in procedure "xc_vxc_pw_create_debug" https://cp2k.org/conv#c204 xc.F: Found CLOSE statement in procedure "xc_vxc_pw_create_test_lsd" https://cp2k.org/conv#c204 @@ -497,8 +204,6 @@ xc.F: Found OPEN statement in procedure "xc_vxc_pw_create_debug" https://cp2k.or xc.F: Found OPEN statement in procedure "xc_vxc_pw_create_test_lsd" https://cp2k.org/conv#c203 xc.F: Found WRITE statement with hardcoded unit in "xc_vxc_pw_create_debug" https://cp2k.org/conv#c012 xc.F: Found WRITE statement with hardcoded unit in "xc_vxc_pw_create_test_lsd" https://cp2k.org/conv#c012 -xtb_matrices.F: Found type neighbor_atoms_type without initializer https://cp2k.org/conv#c016 -xtb_types.F: Found type xtb_atom_type without initializer https://cp2k.org/conv#c016 xyz2dcd.F: Found CLOSE statement in procedure "xyz2dcd" https://cp2k.org/conv#c204 xyz2dcd.F: Found OPEN statement in procedure "xyz2dcd" https://cp2k.org/conv#c203 xyz2dcd.F: Found STOP statement in procedure "abort_program" https://cp2k.org/conv#c205 diff --git a/tools/toolchain/scripts/generate_arch_files.sh b/tools/toolchain/scripts/generate_arch_files.sh index d2838ea796..a02b2a4149 100755 --- a/tools/toolchain/scripts/generate_arch_files.sh +++ b/tools/toolchain/scripts/generate_arch_files.sh @@ -74,7 +74,7 @@ WFLAGS_ERROR="-Werror=aliasing -Werror=ampersand -Werror=c-binding-type -Werror= # we just warn for those (that eventually might be promoted to WFLAGSERROR). It is useless to put something here with 100s of warnings. WFLAGS_WARN="-Wuninitialized -Wuse-without-only" # while here we collect all other warnings, some we'll ignore -# TODO: -Wpedantic with -std2008 requires an upgrade of the MPI interfaces from mpi to mpi_f08 +# TODO: -Wpedantic with -std2008 requires us to drop the old MPI-90 interface entirely and SIRIUS (-Wuninitialized) and DBCSR (default initializers) to initialize their types WFLAGS_WARNALL="-Wno-pedantic -Wall -Wextra -Wsurprising -Warray-temporaries -Wcharacter-truncation -Wconversion-extra -Wimplicit-interface -Wimplicit-procedure -Wreal-q-constant -Walign-commons -Wfunction-elimination -Wrealloc-lhs -Wcompare-reals -Wzerotrip" # IEEE_EXCEPTIONS dependency