    PROGRAM c06dbfe

!      C06DBF Example Program Text

!      Mark 23 Release. NAG Copyright 2011.

!      .. Use Statements ..
       USE nag_library, ONLY : c06dbf, nag_wp
!      .. Implicit None Statement ..
       IMPLICIT NONE
!      .. Parameters ..
       INTEGER, PARAMETER              :: n = 4, nout = 6
       REAL (KIND=nag_wp), PARAMETER   :: c(n) = (/ 1.0E0_nag_wp,              &
                                          1.0E0_nag_wp, 0.5E0_nag_wp,          &
                                          0.25E0_nag_wp/)
!      .. Local Scalars ..
       REAL (KIND=nag_wp)              :: calc, x
       INTEGER                         :: s
!      .. Executable Statements ..
       WRITE (nout,*) 'C06DBF Example Program Results'

       x = 0.5E0_nag_wp
       s = 1

       calc = c06dbf(x,c,n,s)

       WRITE (nout,*)
       WRITE (nout,99999) 'Sum =', calc

99999  FORMAT (1X,A,F8.4)
    END PROGRAM c06dbfe
