50 integer,
public,
parameter :: &
67 integer :: spin_channels
68 type(distributed_t) :: kpt
79 type(states_elec_dim_t),
intent(inout) :: dout
80 type(states_elec_dim_t),
intent(in) :: din
87 dout%ispin = din%ispin
88 dout%nspin = din%nspin
89 dout%spin_channels = din%spin_channels
100 type(states_elec_dim_t),
intent(inout) :: dim
114 logical pure function is_spin_up(ik)
115 integer,
intent(in) :: ik
124 integer pure function states_elec_dim_get_spin_index(this, iq) result(index)
125 class(states_elec_dim_t),
intent(in) :: this
126 integer,
intent(in) :: iq
128 if (this%ispin == spin_polarized)
then
129 index = 1 + mod(iq - 1, 2)
140 integer pure function states_elec_dim_get_kpoint_index(this, iq) result(index)
141 class(states_elec_dim_t),
intent(in) :: this
142 integer,
intent(in) :: iq
144 if (this%ispin == spin_polarized)
then
145 index = 1 + (iq - 1)/2
subroutine, public distributed_end(this)
subroutine, public distributed_copy(in, out)
@Brief Create a copy of a distributed instance
This module is intended to contain "only mathematical" functions and procedures.
logical pure function, public odd(n)
Returns if n is odd.
This module handles the communicators for the various parallelization strategies.
This module handles spin dimensions of the states and the k-point distribution.
integer pure function states_elec_dim_get_spin_index(this, iq)
extract the spin index from the combined spin and k index
integer, parameter, public spin_up
integer pure function states_elec_dim_get_kpoint_index(this, iq)
extract the k-point index from the combined spin and k index
subroutine, public states_elec_dim_copy(dout, din)
logical pure function, public is_spin_up(ik)
Returns true if k-point ik denotes spin-up, in spin-polarized case.
subroutine, public states_elec_dim_end(dim)
class for organizing spins and k-points