Compute parabolic cylinder function Vv(x)
for large argument
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(in) | :: | Va |
Order |
||
| real(kind=wp), | intent(in) | :: | x |
Argument |
||
| real(kind=wp), | intent(out) | :: | Pv |
|
subroutine vvla(Va,x,Pv) real(wp),intent(in) :: x !! Argument real(wp),intent(in) :: Va !! Order real(wp),intent(out) :: Pv !! `Vv(x)` real(wp) :: a0 , dsl , gl , pdl , qe , r , x1 integer :: k real(wp),parameter :: eps = 1.0e-12_wp qe = exp(0.25_wp*x*x) a0 = abs(x)**(-Va-1.0_wp)*sqrt(2.0_wp/pi)*qe r = 1.0_wp Pv = 1.0_wp do k = 1 , 18 r = 0.5_wp*r*(2.0_wp*k+Va-1.0_wp)*(2.0_wp*k+Va)/(k*x*x) Pv = Pv + r if ( abs(r/Pv)<eps ) exit enddo Pv = a0*Pv if ( x<0.0_wp ) then x1 = -x call dvla(Va,x1,pdl) call gamma2(-Va,gl) dsl = sin(pi*Va)*sin(pi*Va) Pv = dsl*gl/pi*pdl - cos(pi*Va)*Pv endif end subroutine vvla