Helper function to determine if the shear is small enough that we consider it to be zero for the purposes of periodicity etc.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real, | intent(in), | optional | :: | shear_in |
pure logical function is_effectively_zero_shear(shear_in) result(zero_shear)
use optionals, only: get_option_with_default
implicit none
real, intent(in), optional :: shear_in
real :: the_shear
the_shear = get_option_with_default(shear_in, shat)
zero_shear = abs(the_shear) <= smallest_non_zero_shear
end function is_effectively_zero_shear