gauss_freq(x) = (1+erf(x/sqrt(2)))/2 = erfc(-x/sqrt(2))/2 - See comments in erf
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=dp), | intent(in) | :: | x |
function gauss_freq(x)
!---------------------------------------------------------------------
!
!! gauss_freq(x) = (1+erf(x/sqrt(2)))/2 = erfc(-x/sqrt(2))/2
!! - See comments in erf
!
use w90_constants, only: dp
implicit none
real(kind=dp), intent(in) :: x
real(kind=dp) :: gauss_freq
real(kind=dp), parameter :: c = 0.7071067811865475_dp
! ( c= sqrt(1/2) )
!
gauss_freq = 0.5_dp*qe_erfc(-x*c)
!
return
end function gauss_freq