************80
! DVLA computes parabolic cylinder functions Dv(x) for large argument.
Licensing:
This routine is copyrighted by Shanjie Zhang and Jianming Jin. However,
they give permission to incorporate this routine into a user program
provided that the copyright is acknowledged.
Modified:
06 July 2012
Author:
Shanjie Zhang, Jianming Jin
Reference:
Shanjie Zhang, Jianming Jin,
Computation of Special Functions,
Wiley, 1996,
ISBN: 0-471-11963-6,
LC: QA351.C45.
Parameters:
Input, real ( kind = 8 ) X, the argument.
Input, real ( kind = 8 ) VA, the order.
Output, real ( kind = 8 ) PD, the function value.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=8) | :: | va | ||||
real(kind=8) | :: | x | ||||
real(kind=8) | :: | pd |
subroutine dvla ( va, x, pd ) !*****************************************************************************80 ! !! DVLA computes parabolic cylinder functions Dv(x) for large argument. ! ! Licensing: ! ! This routine is copyrighted by Shanjie Zhang and Jianming Jin. However, ! they give permission to incorporate this routine into a user program ! provided that the copyright is acknowledged. ! ! Modified: ! ! 06 July 2012 ! ! Author: ! ! Shanjie Zhang, Jianming Jin ! ! Reference: ! ! Shanjie Zhang, Jianming Jin, ! Computation of Special Functions, ! Wiley, 1996, ! ISBN: 0-471-11963-6, ! LC: QA351.C45. ! ! Parameters: ! ! Input, real ( kind = 8 ) X, the argument. ! ! Input, real ( kind = 8 ) VA, the order. ! ! Output, real ( kind = 8 ) PD, the function value. ! implicit none real ( kind = 8 ) a0 real ( kind = 8 ) ep real ( kind = 8 ) eps real ( kind = 8 ) gl integer ( kind = 4 ) k real ( kind = 8 ) pd real ( kind = 8 ) pi real ( kind = 8 ) r real ( kind = 8 ) va real ( kind = 8 ) vl real ( kind = 8 ) x real ( kind = 8 ) x1 pi = 3.141592653589793D+00 eps = 1.0D-12 ep = exp ( -0.25D+00 * x * x ) a0 = abs ( x ) ** va * ep r = 1.0D+00 pd = 1.0D+00 do k = 1, 16 r = -0.5D+00 * r * ( 2.0D+00 * k - va - 1.0D+00 ) & * ( 2.0D+00 * k - va - 2.0D+00 ) / ( k * x * x ) pd = pd + r if ( abs ( r / pd ) < eps ) then exit end if end do pd = a0 * pd if ( x < 0.0D+00 ) then x1 = - x call vvla ( va, x1, vl ) call gammaf ( -va, gl ) pd = pi * vl / gl + cos ( pi * va ) * pd end if return end subroutine dvla