Calculates the number of steps on the intermolecular (R) grid in current block. This is done either directly (if r_step > 0) or through the number of steps per half de Broglie wavelength
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | intent(in) | :: | largest_wavevector_ |
the largest wavevector in the block |
||
real(kind=dp), | intent(in) | :: | k_potential_depth_ |
correction from the depth of the potential well converted to wavevector units |
number of steps on the \(R\) grid
function calculate_number_of_steps(largest_wavevector_, &
k_potential_depth_) result(number_of_steps_)
!! Calculates the number of steps on the intermolecular (R) grid in
!! current block. This is done either directly (if r_step > 0)
!! or through the number of steps per half de Broglie wavelength
!---------------------------------------------------------------------!
real(dp), intent(in) :: largest_wavevector_
!! the largest wavevector in the block
real(dp), intent(in) :: k_potential_depth_
!! correction from the depth of the potential well converted
!! to wavevector units
integer(int32) :: number_of_steps_
!! number of steps on the \\(R\\) grid
!---------------------------------------------------------------------!
if (r_step <= 0) then
number_of_steps_ = nint( (r_max-r_min) / PI &
* ((largest_wavevector_+k_potential_depth_)*steps))
else
number_of_steps_ = nint((r_max-r_min)/r_step)+1
endif
!---------------------------------------------------------------------!
end function calculate_number_of_steps