Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(cube) | :: | this | ||||
integer, | intent(in) | :: | k_vec(3) |
function dispersion_rel_cube(this, k_vec) result(disp)
class(cube) :: this
integer, intent(in) :: k_vec(3)
real(dp) :: disp
#ifdef DEBUG_
character(*), parameter :: this_routine = "dispersion_rel_cube"
#endif
ASSERT(this%is_periodic())
disp = 2.0_dp * (cos(2 * pi * (k_vec(1) + twisted_bc(1)) / this%length(1)) &
+ cos(2 * pi * (k_vec(2) + twisted_bc(2)) / this%length(2)) &
+ cos(2 * pi * (k_vec(3) + twisted_bc(3)) / this%length(3)))
end function dispersion_rel_cube