~ubuntu-branches/debian/sid/r-cran-surveillance/sid

« back to all changes in this revision

Viewing changes to src/gsl_wrappers.h

  • Committer: Bazaar Package Importer
  • Author(s): Andreas Tille
  • Date: 2009-10-21 14:25:07 UTC
  • mfrom: (2.1.2 squeeze)
  • Revision ID: james.westby@ubuntu.com-20091021142507-qxc714tmnb8thj22
Tags: 1.1.2-1
* New upstream version
* debian/control:
  - XS-Autobuild: yes to enable autobuilding
  - Build-Depends: r-cran-matrix
  - Standards-Version: 3.8.3 (no changes needed)

Show diffs side-by-side

added added

removed removed

Lines of Context:
54
54
{
55
55
  double p;
56
56
  if (mu==0) {
57
 
    return(log(k == 0));
 
57
    return(log((double)(k == 0)));
58
58
  } else {
59
59
    double lf = lgammafn(k+1); /*gsl2R: gsl_sf_lnfact(k) */
60
60
 
82
82
  if (x < 0)
83
83
    {
84
84
      //This is problematic!
85
 
      return log(0) ;
 
85
      return log((double)0) ;
86
86
    }
87
87
  else if (x == 0)
88
88
    {
89
89
      if (a == 1)
90
90
        return log(1/b) ;
91
91
      else
92
 
        return log(0) ;
 
92
        return log((double)0) ;
93
93
    }
94
94
  else if (a == 1)
95
95
    {