Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(type_wrf_ko), | intent(in) | :: | self | |||
real(kind=real64), | intent(in) | :: | h |
module function calculate_wrf_ko_derivative(self, h) result(dqw_dh) implicit none class(type_wrf_ko), intent(in) :: self real(real64), intent(in) :: h real(real64) :: dqw_dh if (h < 0.0d0) then dqw_dh = -(self%theta_s - self%theta_r) * & exp(-(log(h / self%alpha1))**2.0d0 / (2.0d0 * self%n1**2.0d0)) / & (sqrt(2.0d0 * pi) * h * self%n1) else dqw_dh = 0.0d0 end if end function calculate_wrf_ko_derivative