50 TYPE(
qs_kind_type),
DIMENSION(:),
INTENT(IN) :: qs_kind_set
51 INTEGER,
INTENT(IN) :: scr
52 CHARACTER(LEN=*),
INTENT(IN) :: title
53 REAL(kind=
dp),
DIMENSION(:, :),
INTENT(IN), &
54 OPTIONAL :: electronic_charges
57 CHARACTER(len=*),
PARAMETER :: routinen =
'print_atomic_charges'
59 CHARACTER(LEN=2) :: element_symbol
60 INTEGER :: handle, iatom, ikind, natom, nspin
61 REAL(kind=
dp) :: total_charge, zeff
63 CALL timeset(routinen, handle)
65 IF (
PRESENT(electronic_charges))
THEN
66 nspin =
SIZE(electronic_charges, 2)
67 natom =
SIZE(electronic_charges, 1)
75 IF (
SIZE(particle_set) /= natom)
THEN
76 cpabort(
"Unexpected number of atoms/charges")
78 WRITE (scr,
'(T2,A)') title
81 IF (title ==
"RESP charges:")
THEN
82 WRITE (scr,
'(A)')
" Type | Atom | Charge"
84 WRITE (scr,
'(A)')
" Atom | Charge"
87 WRITE (scr,
'(A)')
" Atom | Charge | Spin diff charge"
93 element_symbol=element_symbol, kind_number=ikind)
98 IF (title ==
"RESP charges:")
THEN
99 WRITE (scr,
'(T3,A4,2X,I6,A2,A2,F12.6)')
"RESP", iatom,
" ", element_symbol,
atomic_charges(iatom)
102 WRITE (scr,
'(I6,A2,A2,F12.6)') iatom,
" ", element_symbol,
atomic_charges(iatom)
106 WRITE (scr,
'(I6,A2,A2,F12.6)') iatom,
" ", element_symbol, zeff - electronic_charges(iatom, 1)
107 total_charge = total_charge + zeff - electronic_charges(iatom, 1)
109 WRITE (scr,
'(I6,A2,A2,2F12.6)') iatom,
" ", element_symbol, &
110 zeff - (electronic_charges(iatom, 1) + electronic_charges(iatom, 2)), &
111 (electronic_charges(iatom, 1) - electronic_charges(iatom, 2))
112 total_charge = total_charge + zeff - (electronic_charges(iatom, 1) + electronic_charges(iatom, 2))
115 IF (title ==
"RESP charges:")
THEN
116 WRITE (scr,
'(A,F10.6)')
" Total ", total_charge
118 WRITE (scr,
'(A,F10.6)')
" Total ", total_charge
120 WRITE (scr,
'(A)')
""
123 CALL timestop(handle)
subroutine, public get_atomic_kind(atomic_kind, fist_potential, element_symbol, name, mass, kind_number, natom, atom_list, rcov, rvdw, z, qeff, apol, cpol, mm_radius, shell, shell_active, damping)
Get attributes of an atomic kind.
Define the data structure for the particle information.
subroutine, public get_qs_kind(qs_kind, basis_set, basis_type, ncgf, nsgf, all_potential, tnadd_potential, gth_potential, sgp_potential, upf_potential, se_parameter, dftb_parameter, xtb_parameter, dftb3_param, zatom, zeff, elec_conf, mao, lmax_dftb, alpha_core_charge, ccore_charge, core_charge, core_charge_radius, paw_proj_set, paw_atom, hard_radius, hard0_radius, max_rad_local, covalent_radius, vdw_radius, gpw_type_forced, harmonics, max_iso_not0, max_s_harm, grid_atom, ngrid_ang, ngrid_rad, lmax_rho0, dft_plus_u_atom, l_of_dft_plus_u, n_of_dft_plus_u, u_minus_j, u_of_dft_plus_u, j_of_dft_plus_u, alpha_of_dft_plus_u, beta_of_dft_plus_u, j0_of_dft_plus_u, occupation_of_dft_plus_u, dispersion, bs_occupation, magnetization, no_optimize, addel, laddel, naddel, orbitals, max_scf, eps_scf, smear, u_ramping, u_minus_j_target, eps_u_ramping, init_u_ramping_each_scf, reltmat, ghost, floating, name, element_symbol, pao_basis_size, pao_model_file, pao_potentials, pao_descriptors, nelec)
Get attributes of an atomic kind.