Blame view

fvn_fnlib/dlgams.f 478 Bytes
38581db0c   daniau   git-svn-id: https...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
        subroutine dlgams (x, dlgam, sgngam)
  c july 1977 edition.  w. fullerton, c3, los alamos scientific lab.
  c
  c evaluate log abs (gamma(x)) and return the sign of gamma(x) in sgngam.
  c sgngam is either +1.0 or -1.0.
  c
        double precision x, dlgam, sgngam, dint, dlngam
        external  dlngam
  c
        dlgam = dlngam(x)
        sgngam = 1.0d0
        if (x.gt.0.d0) return
  c
        int = dmod (-dint(x), 2.0d0) + 0.1d0
        if (int.eq.0) sgngam = -1.0d0
  c
        return
        end