goffice r2124 - in trunk: . goffice/math



Author: mortenw
Date: Wed Jun 25 00:44:33 2008
New Revision: 2124
URL: http://svn.gnome.org/viewvc/goffice?rev=2124&view=rev

Log:
2008-06-24  Morten Welinder  <terra gnome org>

	* goffice/math/go-rangefunc.c (go_range_median_inter_sorted): New
	function.



Modified:
   trunk/ChangeLog
   trunk/goffice/math/go-rangefunc.c
   trunk/goffice/math/go-rangefunc.h

Modified: trunk/goffice/math/go-rangefunc.c
==============================================================================
--- trunk/goffice/math/go-rangefunc.c	(original)
+++ trunk/goffice/math/go-rangefunc.c	Wed Jun 25 00:44:33 2008
@@ -219,6 +219,12 @@
 }
 
 int
+SUFFIX(go_range_median_inter_sorted) (DOUBLE const *xs, int n, DOUBLE *res)
+{
+	return SUFFIX(go_range_fractile_inter_sorted) (xs, n, res, 0.5);
+}
+
+int
 SUFFIX(go_range_median_inter_nonconst) (DOUBLE *xs, int n, DOUBLE *res)
 {
 	return SUFFIX(go_range_fractile_inter_nonconst) (xs, n, res, 0.5);

Modified: trunk/goffice/math/go-rangefunc.h
==============================================================================
--- trunk/goffice/math/go-rangefunc.h	(original)
+++ trunk/goffice/math/go-rangefunc.h	Wed Jun 25 00:44:33 2008
@@ -16,6 +16,7 @@
 int go_range_fractile_inter_sorted (double const *xs, int n, double *res, double f);
 int go_range_median_inter (double const *xs, int n, double *res);
 int go_range_median_inter_nonconst (double *xs, int n, double *res);
+int go_range_median_inter_sorted (double const *xs, int n, double *res);
 int go_range_increasing (double const *xs, int n);
 int go_range_decreasing (double const *xs, int n);
 int go_range_vary_uniformly (double const *xs, int n);
@@ -33,6 +34,7 @@
 int go_range_fractile_inter_sortedl (long double const *xs, int n, long double *res, long double f);
 int go_range_median_interl (long double const *xs, int n, long double *res);
 int go_range_median_inter_nonconstl (long double *xs, int n, long double *res);
+int go_range_median_inter_sortedl (long double const *xs, int n, long double *res);
 int go_range_increasingl (long double const *xs, int n);
 int go_range_decreasingl (long double const *xs, int n);
 int go_range_vary_uniformlyl (long double const *xs, int n);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]