changeset 273:c8c97224f3c7 sampling

Make yinv and yfun not static, so that they can be called from gdb.
author mas01cr
date Tue, 17 Jun 2008 12:27:01 +0000
parents 5d721f1ead01
children 1c76d5f41708
files sample.cpp
diffstat 1 files changed, 5 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/sample.cpp	Tue Jun 17 11:43:40 2008 +0000
+++ b/sample.cpp	Tue Jun 17 12:27:01 2008 +0000
@@ -2,11 +2,12 @@
 
 #include <gsl/gsl_sf.h>
 
-static double yfun(double d) {
+// static
+double yfun(double d) {
   return gsl_sf_log(d) - gsl_sf_psi(d);
 }
-
-static double yinv(double y) {
+// static
+double yinv(double y) {
   double a = 1.0e-5;
   double b = 1000.0;
 
@@ -151,7 +152,7 @@
       sumlogdist += log(dist);
       i++;
     } else {
-      VERB_LOG(1, "infinity found: %f %f %f\n", v1norm, v2norm, v1v2);
+      VERB_LOG(1, "infinity/NaN found: %f %f %f\n", v1norm, v2norm, v1v2);
     }
   }