From 47238f813474138159f1366d6786dac41e116a50 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 21 Apr 2021 14:39:30 +0200 Subject: add upstream patch to fix typo in function name --- .gitignore | 2 + PHPINFO | 5 + REFLECTION | 4 +- php-pecl-stats.spec | 19 +- stats-php7.patch | 444 ++++++++++++++++++++++++++++++++++ stats-php8.patch | 680 ++++++++++++++++------------------------------------ 6 files changed, 680 insertions(+), 474 deletions(-) create mode 100644 PHPINFO create mode 100644 stats-php7.patch diff --git a/.gitignore b/.gitignore index 1ab5c4f..01f0400 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,7 @@ +clog package-*.xml *.tgz +*.tar.bz2 *.tar.gz *.tar.xz *.tar.xz.asc diff --git a/PHPINFO b/PHPINFO new file mode 100644 index 0000000..484e024 --- /dev/null +++ b/PHPINFO @@ -0,0 +1,5 @@ + +stats + +Statistics Support => enabled +Version => 2.0.3 diff --git a/REFLECTION b/REFLECTION index d7fbc3c..caa23cd 100644 --- a/REFLECTION +++ b/REFLECTION @@ -1,4 +1,4 @@ -Extension [ extension #77 stats version 2.0.3 ] { +Extension [ extension #120 stats version 2.0.3 ] { - Functions { Function [ function stats_cdf_t ] { @@ -61,6 +61,8 @@ Extension [ extension #77 stats version 2.0.3 ] { } Function [ function stats_rand_gen_noncentral_chisquare ] { } + Function [ function stats_rand_gen_noncentral_f ] { + } Function [ function stats_rand_gen_noncenral_f ] { } Function [ function stats_rand_gen_normal ] { diff --git a/php-pecl-stats.spec b/php-pecl-stats.spec index 739ce3a..d3390e7 100644 --- a/php-pecl-stats.spec +++ b/php-pecl-stats.spec @@ -19,18 +19,20 @@ Summary: Routines for statistical computation Name: %{?scl_prefix}php-pecl-%{pecl_name} Version: 2.0.3 -Release: 9%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Release: 10%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} License: PHP URL: https://pecl.php.net/package/%{pecl_name} Source0: https://pecl.php.net/get/%{pecl_name}-%{version}.tgz -# Upstream patch for PHP 8 +# Upstream cumulative patch # Mostly output of: git diff 2.0.3 -- *.c *.h tests/ -Patch0: %{pecl_name}-php8.patch +Patch0: %{pecl_name}-php7.patch +# Upstream patch for PHP 8 +Patch1: %{pecl_name}-php8.patch BuildRequires: make BuildRequires: %{?dtsprefix}gcc -BuildRequires: %{?scl_prefix}php-devel >= 7 +BuildRequires: %{?scl_prefix}php-devel >= 7.0 BuildRequires: %{?scl_prefix}php-pear Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} @@ -76,8 +78,12 @@ sed -e 's/role="test"/role="src"/' \ -i package.xml cd NTS -%if "%{php_version}" > "8.0" %patch0 -p1 -b .upstream +%if "%{php_version}" > "8.0" +%patch1 -p1 -b .php8 +%else +# don't deprecate function with typo +sed -e 's/PHP_DEP_FALIAS/PHP_FALIAS/' -i php_stats.c %endif # Sanity check, really often broken @@ -211,6 +217,9 @@ REPORT_EXIT_STATUS=1 \ %changelog +* Wed Apr 21 2021 Remi Collet - 2.0.3-10 +- add upstream patch to fix typo in function name + * Mon Apr 19 2021 Remi Collet - 2.0.3-9 - add upstream patch for PHP 8 diff --git a/stats-php7.patch b/stats-php7.patch new file mode 100644 index 0000000..761cb4a --- /dev/null +++ b/stats-php7.patch @@ -0,0 +1,444 @@ +diff --git a/php_stats.c b/php_stats.c +index 32dc4e9..7d155a8 100644 +--- a/php_stats.c ++++ b/php_stats.c +@@ -16,9 +16,6 @@ + +----------------------------------------------------------------------+ + */ + +-/* $Id$ */ +- +- + #ifdef HAVE_CONFIG_H + #include "config.h" + #endif +@@ -83,7 +80,8 @@ zend_function_entry statistics_functions[] = { + PHP_FE(stats_rand_gen_f, NULL) + PHP_FE(stats_rand_gen_gamma, NULL) + PHP_FE(stats_rand_gen_noncentral_chisquare,NULL) +- PHP_FE(stats_rand_gen_noncenral_f, NULL) ++ PHP_FE(stats_rand_gen_noncentral_f, NULL) ++ PHP_DEP_FALIAS(stats_rand_gen_noncenral_f, stats_rand_gen_noncentral_f, NULL) + PHP_FE(stats_rand_gen_normal, NULL) + PHP_FE(stats_rand_phrase_to_seeds, NULL) + PHP_FE(stats_rand_ibinomial, NULL) +@@ -129,12 +127,12 @@ zend_module_entry stats_module_entry = { + STANDARD_MODULE_HEADER, + "stats", + statistics_functions, +- NULL, +- NULL, +- NULL, +- NULL, +- PHP_MINFO(stats), +- PHP_STATS_VERSION, ++ NULL, ++ NULL, ++ NULL, ++ NULL, ++ PHP_MINFO(stats), ++ PHP_STATS_VERSION, + STANDARD_MODULE_PROPERTIES, + }; + +@@ -432,10 +430,10 @@ PHP_FUNCTION(stats_cdf_normal) + } + + switch (which) { +- case 1: RETURN_DOUBLE(p); +- case 2: RETURN_DOUBLE(x); +- case 3: RETURN_DOUBLE(mean); +- case 4: RETURN_DOUBLE(sd); ++ case 1: RETURN_DOUBLE(p); ++ case 2: RETURN_DOUBLE(x); ++ case 3: RETURN_DOUBLE(mean); ++ case 4: RETURN_DOUBLE(sd); + } + RETURN_FALSE; /* should never be reached */ + } +@@ -588,10 +586,10 @@ PHP_FUNCTION(stats_cdf_gamma) + } + + switch (which) { +- case 1: RETURN_DOUBLE(p); +- case 2: RETURN_DOUBLE(x); +- case 3: RETURN_DOUBLE(shape); +- case 4: RETURN_DOUBLE(1 / rate); ++ case 1: RETURN_DOUBLE(p); ++ case 2: RETURN_DOUBLE(x); ++ case 3: RETURN_DOUBLE(shape); ++ case 4: RETURN_DOUBLE(1 / rate); + } + RETURN_FALSE; /* should never be reached */ + } +@@ -702,7 +700,7 @@ PHP_FUNCTION(stats_cdf_chisquare) + q = 1.0 - p; + } + +- cdfchi((int *)&which, &p, &q, &x, &df, &status, &bound); ++ cdfchi((int *)&which, &p, &q, &x, &df, &status, &bound); + if (status != 0) { + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Computation Error"); + RETURN_FALSE; +@@ -855,10 +853,10 @@ PHP_FUNCTION(stats_cdf_beta) + } + + switch (which) { +- case 1: RETURN_DOUBLE(p); +- case 2: RETURN_DOUBLE(x); +- case 3: RETURN_DOUBLE(a); +- case 4: RETURN_DOUBLE(b); ++ case 1: RETURN_DOUBLE(p); ++ case 2: RETURN_DOUBLE(x); ++ case 3: RETURN_DOUBLE(a); ++ case 4: RETURN_DOUBLE(b); + } + RETURN_FALSE; /* never here */ + } +@@ -994,10 +992,10 @@ PHP_FUNCTION(stats_cdf_binomial) + } + + switch (which) { +- case 1: RETURN_DOUBLE(p); +- case 2: RETURN_DOUBLE(sn); +- case 3: RETURN_DOUBLE(xn); +- case 4: RETURN_DOUBLE(pr); ++ case 1: RETURN_DOUBLE(p); ++ case 2: RETURN_DOUBLE(sn); ++ case 3: RETURN_DOUBLE(xn); ++ case 4: RETURN_DOUBLE(pr); + } + RETURN_FALSE; /* never here */ + } +@@ -1132,10 +1130,10 @@ PHP_FUNCTION(stats_cdf_noncentral_chisquare) + } + + switch (which) { +- case 1: RETURN_DOUBLE(p); +- case 2: RETURN_DOUBLE(x); +- case 3: RETURN_DOUBLE(df); +- case 4: RETURN_DOUBLE(pnonc); ++ case 1: RETURN_DOUBLE(p); ++ case 2: RETURN_DOUBLE(x); ++ case 3: RETURN_DOUBLE(df); ++ case 4: RETURN_DOUBLE(pnonc); + } + RETURN_FALSE; /* never here */ + } +@@ -1263,10 +1261,10 @@ PHP_FUNCTION(stats_cdf_f) + } + + switch (which) { +- case 1: RETURN_DOUBLE(p); +- case 2: RETURN_DOUBLE(f); +- case 3: RETURN_DOUBLE(dfn); +- case 4: RETURN_DOUBLE(dfd); ++ case 1: RETURN_DOUBLE(p); ++ case 2: RETURN_DOUBLE(f); ++ case 3: RETURN_DOUBLE(dfn); ++ case 4: RETURN_DOUBLE(dfd); + } + RETURN_FALSE; /* never here */ + } +@@ -1420,10 +1418,10 @@ PHP_FUNCTION(stats_cdf_noncentral_f) + } + + switch (which) { +- case 1: RETURN_DOUBLE(p); +- case 2: RETURN_DOUBLE(f); +- case 3: RETURN_DOUBLE(dfn); +- case 4: RETURN_DOUBLE(dfd); ++ case 1: RETURN_DOUBLE(p); ++ case 2: RETURN_DOUBLE(f); ++ case 3: RETURN_DOUBLE(dfn); ++ case 4: RETURN_DOUBLE(dfd); + case 5: RETURN_DOUBLE(pnonc); + } + RETURN_FALSE; /* never here */ +@@ -1839,7 +1837,7 @@ static double laplace_cdf(double x) + + + /* {{{ proto float stats_cdf_laplace(float par1, float par2, float par3, int which) +- Calculates any one parameter of the Laplace distribution given values for the others. */ ++ Calculates any one parameter of the Laplace distribution given values for the others. */ + PHP_FUNCTION(stats_cdf_laplace) + { + double arg1; +@@ -1909,7 +1907,7 @@ static double cauchy_cdf (double x) + } + + /* {{{ proto float stats_cdf_cauchy(float par1, float par2, float par3, int which) +- Calculates any one parameter of the Cauchy distribution given values for the others. */ ++ Calculates any one parameter of the Cauchy distribution given values for the others. */ + PHP_FUNCTION(stats_cdf_cauchy) + { + double arg1; +@@ -1978,7 +1976,7 @@ static double logistic_quantile (double p) + } + + /* {{{ proto float stats_cdf_logistic(float par1, float par2, float par3, int which) +- Calculates any one parameter of the logistic distribution given values for the others. */ ++ Calculates any one parameter of the logistic distribution given values for the others. */ + PHP_FUNCTION(stats_cdf_logistic) + { + double arg1; +@@ -2037,7 +2035,7 @@ PHP_FUNCTION(stats_cdf_logistic) + /* }}} */ + + /* {{{ proto float stats_cdf_weibull(float par1, float par2, float par3, int which) +- Calculates any one parameter of the Weibull distribution given values for the others. */ ++ Calculates any one parameter of the Weibull distribution given values for the others. */ + PHP_FUNCTION(stats_cdf_weibull) + { + double arg1; +@@ -2087,7 +2085,7 @@ PHP_FUNCTION(stats_cdf_weibull) + /* }}} */ + + /* {{{ proto float stats_cdf_uniform(float par1, float par2, float par3, int which) +- Calculates any one parameter of the uniform distribution given values for the others. */ ++ Calculates any one parameter of the uniform distribution given values for the others. */ + PHP_FUNCTION(stats_cdf_uniform) + { + double arg1; +@@ -2163,7 +2161,7 @@ static double exponential_cdf(double x) + } + + /* {{{ proto float stats_cdf_exponential(float par1, float par2, int which) +- Calculates any one parameter of the exponential distribution given values for the others. */ ++ Calculates any one parameter of the exponential distribution given values for the others. */ + PHP_FUNCTION(stats_cdf_exponential) + { + double arg1; +@@ -2243,7 +2241,7 @@ PHP_FUNCTION(stats_rand_getsd) + /* }}} */ + + /* {{{ proto int stats_rand_gen_iuniform(int low, int high) +- Generates integer uniformly distributed between LOW (inclusive) and HIGH (inclusive) */ ++ Generates integer uniformly distributed between LOW (inclusive) and HIGH (inclusive) */ + PHP_FUNCTION(stats_rand_gen_iuniform) + { + zend_long low; +@@ -2267,7 +2265,7 @@ PHP_FUNCTION(stats_rand_gen_iuniform) + /* }}} */ + + /* {{{ proto float stats_rand_gen_funiform(float low, float high) +- Generates uniform float between low (exclusive) and high (exclusive) */ ++ Generates uniform float between low (exclusive) and high (exclusive) */ + PHP_FUNCTION(stats_rand_gen_funiform) + { + double low; +@@ -2287,7 +2285,7 @@ PHP_FUNCTION(stats_rand_gen_funiform) + /* }}} */ + + /* {{{ proto int stats_rand_ignlgi(void) +- Generates random integer between 1 and 2147483562 */ ++ Generates random integer between 1 and 2147483562 */ + PHP_FUNCTION(stats_rand_ignlgi) + { + if (ZEND_NUM_ARGS() != 0) { +@@ -2299,7 +2297,7 @@ PHP_FUNCTION(stats_rand_ignlgi) + /* }}} */ + + /* {{{ proto float stats_rand_ranf(void) +- Returns a random floating point number from a uniform distribution over 0 - 1 (endpoints of this interval are not returned) using the current generator */ ++ Returns a random floating point number from a uniform distribution over 0 - 1 (endpoints of this interval are not returned) using the current generator */ + PHP_FUNCTION(stats_rand_ranf) + { + if (ZEND_NUM_ARGS() != 0) { +@@ -2428,9 +2426,9 @@ PHP_FUNCTION(stats_rand_gen_noncentral_chisquare) + } + /* }}} */ + +-/* {{{ proto float stats_rand_gen_noncenral_f(float dfn, float dfd, float xnonc) ++/* {{{ proto float stats_rand_gen_noncentral_f(float dfn, float dfd, float xnonc) + Generates a random deviate from the noncentral F (variance ratio) distribution with "dfn" degrees of freedom in the numerator, and "dfd" degrees of freedom in the denominator, and noncentrality parameter "xnonc". Method : directly generates ratio of noncentral numerator chisquare variate to central denominator chisquare variate. */ +-PHP_FUNCTION(stats_rand_gen_noncenral_f) ++PHP_FUNCTION(stats_rand_gen_noncentral_f) + { + double dfn; + double dfd; +@@ -2895,7 +2893,7 @@ PHP_FUNCTION(stats_dens_exponential) + /* }}} */ + + /* {{{ proto float stats_dens_f(float x, float dfr1, float dfr2) +- Not documented */ ++ Not documented */ + PHP_FUNCTION(stats_dens_f) + { + double dfr1; +@@ -3010,7 +3008,7 @@ PHP_FUNCTION(stats_dens_pmf_negative_binomial) + /* }}} */ + + /* {{{ proto float stats_dens_pmf_hypergeometric(float n1, float n2, float N1, float N2) +- Not documented */ ++ Not documented */ + PHP_FUNCTION(stats_dens_pmf_hypergeometric) + { + double y; +@@ -3071,7 +3069,7 @@ PHP_FUNCTION(stats_stat_powersum) + /* }}} */ + + /* {{{ proto float stats_stat_innerproduct(array arr1, array arr2) +- Not documented */ ++ Not documented */ + PHP_FUNCTION(stats_stat_innerproduct) + { + zval *arg1, *arg2; +@@ -3231,7 +3229,7 @@ PHP_FUNCTION(stats_stat_paired_t) + /* }}} */ + + /* {{{ proto float stats_stat_percentile(array arr, float perc) +- Not documented */ ++ Not documented */ + PHP_FUNCTION(stats_stat_percentile) + { + zval *arg1, *arg2; +@@ -3459,7 +3457,7 @@ static long double php_population_variance(zval *arr, zend_bool sample) + + + /* {{{ proto float stats_variance(array a [, bool sample = false]) +- Returns the population variance */ ++ Returns the population variance */ + PHP_FUNCTION(stats_variance) + { + zval *arr; +@@ -3481,7 +3479,7 @@ PHP_FUNCTION(stats_variance) + /* }}} */ + + /* {{{ proto float stats_standard_deviation(array a [, bool sample = false]) +- Returns the standard deviation */ ++ Returns the standard deviation */ + PHP_FUNCTION(stats_standard_deviation) + { + zval *arr; +@@ -3504,7 +3502,7 @@ PHP_FUNCTION(stats_standard_deviation) + + + /* {{{ proto float stats_absolute_deviation(array a) +- Returns the absolute deviation of an array of values */ ++ Returns the absolute deviation of an array of values */ + PHP_FUNCTION(stats_absolute_deviation) + { + zval *arr; +@@ -3534,7 +3532,7 @@ PHP_FUNCTION(stats_absolute_deviation) + /* }}} */ + + /* {{{ proto float stats_harmonic_mean(array a) +- Returns the harmonic mean of an array of values */ ++ Returns the harmonic mean of an array of values */ + PHP_FUNCTION(stats_harmonic_mean) + { + zval *arr; +@@ -3566,7 +3564,7 @@ PHP_FUNCTION(stats_harmonic_mean) + /* }}} */ + + /* {{{ proto float stats_skew(array a) +- Computes the skewness of the data in the array */ ++ Computes the skewness of the data in the array */ + PHP_FUNCTION(stats_skew) + { + zval *arr; +@@ -3604,7 +3602,7 @@ PHP_FUNCTION(stats_skew) + /* }}} */ + + /* {{{ proto float stats_kurtosis(array a) +- Computes the kurtosis of the data in the array */ ++ Computes the kurtosis of the data in the array */ + PHP_FUNCTION(stats_kurtosis) + { + zval *arr; +@@ -3644,7 +3642,7 @@ PHP_FUNCTION(stats_kurtosis) + + + /* {{{ proto float stats_covariance(array a, array b) +- Computes the covariance of two data sets */ ++ Computes the covariance of two data sets */ + PHP_FUNCTION(stats_covariance) + { + zval *arr_1, *arr_2; +diff --git a/php_stats.h b/php_stats.h +index af449b3..10a9b22 100644 +--- a/php_stats.h ++++ b/php_stats.h +@@ -16,8 +16,6 @@ + +----------------------------------------------------------------------+ + */ + +-/* $Id$ */ +- + #ifndef PHP_STATS_H + #define PHP_STATS_H + +@@ -65,7 +63,7 @@ PHP_FUNCTION(stats_rand_gen_exponential); + PHP_FUNCTION(stats_rand_gen_f); + PHP_FUNCTION(stats_rand_gen_gamma); + PHP_FUNCTION(stats_rand_gen_noncentral_chisquare); +-PHP_FUNCTION(stats_rand_gen_noncenral_f); ++PHP_FUNCTION(stats_rand_gen_noncentral_f); + PHP_FUNCTION(stats_rand_gen_normal); + PHP_FUNCTION(stats_rand_phrase_to_seeds); + PHP_FUNCTION(stats_rand_ibinomial); +diff --git a/tests/stats_rand_gen_noncenral_f.phpt b/tests/stats_rand_gen_noncenral_f.phpt +deleted file mode 100644 +index c0bb6e8..0000000 +--- a/tests/stats_rand_gen_noncenral_f.phpt ++++ /dev/null +@@ -1,26 +0,0 @@ +---TEST-- +-stats_rand_gen_noncenral_f() +---FILE-- +- +---EXPECTF-- +-bool(true) +- +-Warning: stats_rand_gen_noncenral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 9.000000E-1 dfd: 3.000000E+0 xnonc: 4.000000E+0 in %s on line %d +-bool(false) +- +-Warning: stats_rand_gen_noncenral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: -1.000000E-1 xnonc: 4.000000E+0 in %s on line %d +-bool(false) +- +-Warning: stats_rand_gen_noncenral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: 0.000000E+0 xnonc: 4.000000E+0 in %s on line %d +-bool(false) +- +-Warning: stats_rand_gen_noncenral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: 3.000000E+0 xnonc: -1.000000E-1 in %s on line %d +-bool(false) +diff --git a/tests/stats_rand_gen_noncentral_f.phpt b/tests/stats_rand_gen_noncentral_f.phpt +new file mode 100644 +index 0000000..39b846a +--- /dev/null ++++ b/tests/stats_rand_gen_noncentral_f.phpt +@@ -0,0 +1,26 @@ ++--TEST-- ++stats_rand_gen_noncentral_f() ++--FILE-- ++ ++--EXPECTF-- ++bool(true) ++ ++Warning: stats_rand_gen_noncentral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 9.000000E-1 dfd: 3.000000E+0 xnonc: 4.000000E+0 in %s on line %d ++bool(false) ++ ++Warning: stats_rand_gen_noncentral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: -1.000000E-1 xnonc: 4.000000E+0 in %s on line %d ++bool(false) ++ ++Warning: stats_rand_gen_noncentral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: 0.000000E+0 xnonc: 4.000000E+0 in %s on line %d ++bool(false) ++ ++Warning: stats_rand_gen_noncentral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: 3.000000E+0 xnonc: -1.000000E-1 in %s on line %d ++bool(false) diff --git a/stats-php8.patch b/stats-php8.patch index dabfa3f..f97d371 100644 --- a/stats-php8.patch +++ b/stats-php8.patch @@ -1,16 +1,26 @@ +From fac78cf926bb00c9974379c7131c58b7545e5b15 Mon Sep 17 00:00:00 2001 +From: Rasmus Lerdorf +Date: Thu, 14 Jan 2021 15:42:24 -0800 +Subject: [PATCH] Add PHP 8 support and drop PHP 5 support + +--- + php_stats.c | 423 +++++++++----------- + php_stats.h | 73 +--- + stats.stub.php | 77 ++++ + stats_arginfo.h | 406 +++++++++++++++++++ + tests/stats_dens_pmf_binomial.phpt | 2 + + tests/stats_dens_pmf_negative_binomial.phpt | 2 + + tests/stats_rand_gen_noncentral_f.phpt | 2 + + tests/stats_standard_deviation.phpt | 2 + + 8 files changed, 680 insertions(+), 307 deletions(-) + create mode 100644 stats.stub.php + create mode 100644 stats_arginfo.h + diff --git a/php_stats.c b/php_stats.c -index 32dc4e9..7418dd8 100644 +index 7d155a8..7418dd8 100644 --- a/php_stats.c +++ b/php_stats.c -@@ -16,27 +16,52 @@ - +----------------------------------------------------------------------+ - */ - --/* $Id$ */ -- -- - #ifdef HAVE_CONFIG_H - #include "config.h" +@@ -21,19 +21,47 @@ #endif #include "php.h" @@ -62,7 +72,7 @@ index 32dc4e9..7418dd8 100644 #ifdef PHP_WIN32 extern double fd_lgamma(double x); #define lgamma fd_lgamma -@@ -52,89 +77,16 @@ static double exponential_quantile(double p); +@@ -49,84 +77,10 @@ static double exponential_quantile(double p); static double exponential_cdf(double x); static double binom(double x, double n); @@ -97,7 +107,8 @@ index 32dc4e9..7418dd8 100644 - PHP_FE(stats_rand_gen_f, NULL) - PHP_FE(stats_rand_gen_gamma, NULL) - PHP_FE(stats_rand_gen_noncentral_chisquare,NULL) -- PHP_FE(stats_rand_gen_noncenral_f, NULL) +- PHP_FE(stats_rand_gen_noncentral_f, NULL) +- PHP_DEP_FALIAS(stats_rand_gen_noncenral_f, stats_rand_gen_noncentral_f, NULL) - PHP_FE(stats_rand_gen_normal, NULL) - PHP_FE(stats_rand_phrase_to_seeds, NULL) - PHP_FE(stats_rand_ibinomial, NULL) @@ -143,23 +154,11 @@ index 32dc4e9..7418dd8 100644 STANDARD_MODULE_HEADER, "stats", - statistics_functions, -- NULL, -- NULL, -- NULL, -- NULL, -- PHP_MINFO(stats), -- PHP_STATS_VERSION, + ext_functions, -+ NULL, -+ NULL, -+ NULL, -+ NULL, -+ PHP_MINFO(stats), -+ PHP_STATS_VERSION, - STANDARD_MODULE_PROPERTIES, - }; - -@@ -159,7 +111,7 @@ PHP_MINFO_FUNCTION(stats) + NULL, + NULL, + NULL, +@@ -157,7 +111,7 @@ PHP_MINFO_FUNCTION(stats) * * This is not correct any more, depends on what compare_func is set to. */ @@ -168,7 +167,7 @@ index 32dc4e9..7418dd8 100644 { Bucket *f; Bucket *s; -@@ -173,7 +125,7 @@ static int stats_array_data_compare(const void *a, const void *b TSRMLS_DC) +@@ -171,7 +125,7 @@ static int stats_array_data_compare(const void *a, const void *b TSRMLS_DC) first = f->val; second = s->val; @@ -177,7 +176,7 @@ index 32dc4e9..7418dd8 100644 if (result < 0) { return -1; -@@ -267,12 +219,12 @@ PHP_FUNCTION(stats_cdf_t) +@@ -265,12 +219,12 @@ PHP_FUNCTION(stats_cdf_t) zend_long which; int status = 0; @@ -192,7 +191,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -291,7 +243,7 @@ PHP_FUNCTION(stats_cdf_t) +@@ -289,7 +243,7 @@ PHP_FUNCTION(stats_cdf_t) cdft((int *)&which, &p, &q, &t, &df, &status, &bound); if (status != 0) { @@ -201,7 +200,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -397,12 +349,12 @@ PHP_FUNCTION(stats_cdf_normal) +@@ -395,12 +349,12 @@ PHP_FUNCTION(stats_cdf_normal) zend_long which; int status = 0; @@ -216,7 +215,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -427,15 +379,15 @@ PHP_FUNCTION(stats_cdf_normal) +@@ -425,7 +379,7 @@ PHP_FUNCTION(stats_cdf_normal) cdfnor((int *)&which, &p, &q, &x, &mean, &sd, &status, &bound); if (status != 0) { @@ -225,19 +224,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } - switch (which) { -- case 1: RETURN_DOUBLE(p); -- case 2: RETURN_DOUBLE(x); -- case 3: RETURN_DOUBLE(mean); -- case 4: RETURN_DOUBLE(sd); -+ case 1: RETURN_DOUBLE(p); -+ case 2: RETURN_DOUBLE(x); -+ case 3: RETURN_DOUBLE(mean); -+ case 4: RETURN_DOUBLE(sd); - } - RETURN_FALSE; /* should never be reached */ - } -@@ -544,13 +496,13 @@ PHP_FUNCTION(stats_cdf_gamma) +@@ -542,13 +496,13 @@ PHP_FUNCTION(stats_cdf_gamma) zend_long which; int status = 0; @@ -253,7 +240,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -583,15 +535,15 @@ PHP_FUNCTION(stats_cdf_gamma) +@@ -581,7 +535,7 @@ PHP_FUNCTION(stats_cdf_gamma) cdfgam((int *)&which, &p, &q, &x, &shape, &rate, &status, &bound); if (status != 0) { @@ -262,19 +249,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } - switch (which) { -- case 1: RETURN_DOUBLE(p); -- case 2: RETURN_DOUBLE(x); -- case 3: RETURN_DOUBLE(shape); -- case 4: RETURN_DOUBLE(1 / rate); -+ case 1: RETURN_DOUBLE(p); -+ case 2: RETURN_DOUBLE(x); -+ case 3: RETURN_DOUBLE(shape); -+ case 4: RETURN_DOUBLE(1 / rate); - } - RETURN_FALSE; /* should never be reached */ - } -@@ -679,13 +631,13 @@ PHP_FUNCTION(stats_cdf_chisquare) +@@ -677,13 +631,13 @@ PHP_FUNCTION(stats_cdf_chisquare) zend_long which; int status = 0; @@ -290,19 +265,16 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -702,9 +654,9 @@ PHP_FUNCTION(stats_cdf_chisquare) - q = 1.0 - p; - } +@@ -702,7 +656,7 @@ PHP_FUNCTION(stats_cdf_chisquare) -- cdfchi((int *)&which, &p, &q, &x, &df, &status, &bound); -+ cdfchi((int *)&which, &p, &q, &x, &df, &status, &bound); + cdfchi((int *)&which, &p, &q, &x, &df, &status, &bound); if (status != 0) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Computation Error"); + php_error_docref(NULL, E_WARNING, "Computation Error"); RETURN_FALSE; } -@@ -816,13 +768,13 @@ PHP_FUNCTION(stats_cdf_beta) +@@ -814,13 +768,13 @@ PHP_FUNCTION(stats_cdf_beta) zend_long which; int status = 0; @@ -318,7 +290,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -850,15 +802,15 @@ PHP_FUNCTION(stats_cdf_beta) +@@ -848,7 +802,7 @@ PHP_FUNCTION(stats_cdf_beta) cdfbet((int *)&which, &p, &q, &x, &y, &a, &b, &status, &bound); if (status != 0) { @@ -327,19 +299,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } - switch (which) { -- case 1: RETURN_DOUBLE(p); -- case 2: RETURN_DOUBLE(x); -- case 3: RETURN_DOUBLE(a); -- case 4: RETURN_DOUBLE(b); -+ case 1: RETURN_DOUBLE(p); -+ case 2: RETURN_DOUBLE(x); -+ case 3: RETURN_DOUBLE(a); -+ case 4: RETURN_DOUBLE(b); - } - RETURN_FALSE; /* never here */ - } -@@ -956,13 +908,13 @@ PHP_FUNCTION(stats_cdf_binomial) +@@ -954,13 +908,13 @@ PHP_FUNCTION(stats_cdf_binomial) zend_long which; int status = 0; @@ -355,7 +315,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -989,15 +941,15 @@ PHP_FUNCTION(stats_cdf_binomial) +@@ -987,7 +941,7 @@ PHP_FUNCTION(stats_cdf_binomial) cdfbin((int *)&which, &p, &q, &sn, &xn, &pr, &ompr, &status, &bound); if (status != 0) { @@ -364,19 +324,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } - switch (which) { -- case 1: RETURN_DOUBLE(p); -- case 2: RETURN_DOUBLE(sn); -- case 3: RETURN_DOUBLE(xn); -- case 4: RETURN_DOUBLE(pr); -+ case 1: RETURN_DOUBLE(p); -+ case 2: RETURN_DOUBLE(sn); -+ case 3: RETURN_DOUBLE(xn); -+ case 4: RETURN_DOUBLE(pr); - } - RETURN_FALSE; /* never here */ - } -@@ -1096,13 +1048,13 @@ PHP_FUNCTION(stats_cdf_noncentral_chisquare) +@@ -1094,13 +1048,13 @@ PHP_FUNCTION(stats_cdf_noncentral_chisquare) zend_long which; int status = 0; @@ -392,7 +340,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1127,15 +1079,15 @@ PHP_FUNCTION(stats_cdf_noncentral_chisquare) +@@ -1125,7 +1079,7 @@ PHP_FUNCTION(stats_cdf_noncentral_chisquare) cdfchn((int *)&which, &p, &q, &x, &df, &pnonc, &status, &bound); if (status != 0) { @@ -401,19 +349,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } - switch (which) { -- case 1: RETURN_DOUBLE(p); -- case 2: RETURN_DOUBLE(x); -- case 3: RETURN_DOUBLE(df); -- case 4: RETURN_DOUBLE(pnonc); -+ case 1: RETURN_DOUBLE(p); -+ case 2: RETURN_DOUBLE(x); -+ case 3: RETURN_DOUBLE(df); -+ case 4: RETURN_DOUBLE(pnonc); - } - RETURN_FALSE; /* never here */ - } -@@ -1230,13 +1182,13 @@ PHP_FUNCTION(stats_cdf_f) +@@ -1228,13 +1182,13 @@ PHP_FUNCTION(stats_cdf_f) zend_long which; int status = 0; @@ -429,7 +365,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } if (which < 4) { -@@ -1258,15 +1210,15 @@ PHP_FUNCTION(stats_cdf_f) +@@ -1256,7 +1210,7 @@ PHP_FUNCTION(stats_cdf_f) cdff((int *)&which, &p, &q, &f, &dfn, &dfd, &status, &bound); if (status != 0) { @@ -438,19 +374,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } - switch (which) { -- case 1: RETURN_DOUBLE(p); -- case 2: RETURN_DOUBLE(f); -- case 3: RETURN_DOUBLE(dfn); -- case 4: RETURN_DOUBLE(dfd); -+ case 1: RETURN_DOUBLE(p); -+ case 2: RETURN_DOUBLE(f); -+ case 3: RETURN_DOUBLE(dfn); -+ case 4: RETURN_DOUBLE(dfd); - } - RETURN_FALSE; /* never here */ - } -@@ -1378,13 +1330,13 @@ PHP_FUNCTION(stats_cdf_noncentral_f) +@@ -1376,13 +1330,13 @@ PHP_FUNCTION(stats_cdf_noncentral_f) zend_long which; int status = 0; @@ -466,7 +390,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1415,15 +1367,15 @@ PHP_FUNCTION(stats_cdf_noncentral_f) +@@ -1413,7 +1367,7 @@ PHP_FUNCTION(stats_cdf_noncentral_f) cdffnc((int *)&which, &p, &q, &f, &dfn, &dfd, &pnonc, &status, &bound); if (status != 0) { @@ -475,19 +399,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } - switch (which) { -- case 1: RETURN_DOUBLE(p); -- case 2: RETURN_DOUBLE(f); -- case 3: RETURN_DOUBLE(dfn); -- case 4: RETURN_DOUBLE(dfd); -+ case 1: RETURN_DOUBLE(p); -+ case 2: RETURN_DOUBLE(f); -+ case 3: RETURN_DOUBLE(dfn); -+ case 4: RETURN_DOUBLE(dfd); - case 5: RETURN_DOUBLE(pnonc); - } - RETURN_FALSE; /* never here */ -@@ -1512,13 +1464,13 @@ PHP_FUNCTION(stats_cdf_noncentral_t) +@@ -1510,13 +1464,13 @@ PHP_FUNCTION(stats_cdf_noncentral_t) zend_long which; int status = 0; @@ -503,7 +415,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1542,7 +1494,7 @@ PHP_FUNCTION(stats_cdf_noncentral_t) +@@ -1540,7 +1494,7 @@ PHP_FUNCTION(stats_cdf_noncentral_t) cdftnc((int *)&which, &p, &q, &t, &df, &pnonc, &status, &bound); if (status != 0) { @@ -512,7 +424,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1657,13 +1609,13 @@ PHP_FUNCTION(stats_cdf_negative_binomial) +@@ -1655,13 +1609,13 @@ PHP_FUNCTION(stats_cdf_negative_binomial) zend_long which; int status = 0; @@ -528,7 +440,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1689,7 +1641,7 @@ PHP_FUNCTION(stats_cdf_negative_binomial) +@@ -1687,7 +1641,7 @@ PHP_FUNCTION(stats_cdf_negative_binomial) cdfnbn((int *)&which, &p, &q, &sn, &xn, &pr, &ompr, &status, &bound); if (status != 0) { @@ -537,7 +449,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1780,13 +1732,13 @@ PHP_FUNCTION(stats_cdf_poisson) +@@ -1778,13 +1732,13 @@ PHP_FUNCTION(stats_cdf_poisson) zend_long which; int status = 0; @@ -553,7 +465,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1805,7 +1757,7 @@ PHP_FUNCTION(stats_cdf_poisson) +@@ -1803,7 +1757,7 @@ PHP_FUNCTION(stats_cdf_poisson) cdfpoi((int *)&which, &p, &q, &x, &xlam, &status, &bound); if (status != 0) { @@ -562,16 +474,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1839,7 +1791,7 @@ static double laplace_cdf(double x) - - - /* {{{ proto float stats_cdf_laplace(float par1, float par2, float par3, int which) -- Calculates any one parameter of the Laplace distribution given values for the others. */ -+ Calculates any one parameter of the Laplace distribution given values for the others. */ - PHP_FUNCTION(stats_cdf_laplace) - { - double arg1; -@@ -1852,13 +1804,13 @@ PHP_FUNCTION(stats_cdf_laplace) +@@ -1850,13 +1804,13 @@ PHP_FUNCTION(stats_cdf_laplace) double sd; zend_long which; @@ -587,16 +490,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1909,7 +1861,7 @@ static double cauchy_cdf (double x) - } - - /* {{{ proto float stats_cdf_cauchy(float par1, float par2, float par3, int which) -- Calculates any one parameter of the Cauchy distribution given values for the others. */ -+ Calculates any one parameter of the Cauchy distribution given values for the others. */ - PHP_FUNCTION(stats_cdf_cauchy) - { - double arg1; -@@ -1922,13 +1874,13 @@ PHP_FUNCTION(stats_cdf_cauchy) +@@ -1920,13 +1874,13 @@ PHP_FUNCTION(stats_cdf_cauchy) double sd; zend_long which; @@ -612,16 +506,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -1978,7 +1930,7 @@ static double logistic_quantile (double p) - } - - /* {{{ proto float stats_cdf_logistic(float par1, float par2, float par3, int which) -- Calculates any one parameter of the logistic distribution given values for the others. */ -+ Calculates any one parameter of the logistic distribution given values for the others. */ - PHP_FUNCTION(stats_cdf_logistic) - { - double arg1; -@@ -1991,13 +1943,13 @@ PHP_FUNCTION(stats_cdf_logistic) +@@ -1989,13 +1943,13 @@ PHP_FUNCTION(stats_cdf_logistic) double mean; zend_long which; @@ -637,16 +522,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2037,7 +1989,7 @@ PHP_FUNCTION(stats_cdf_logistic) - /* }}} */ - - /* {{{ proto float stats_cdf_weibull(float par1, float par2, float par3, int which) -- Calculates any one parameter of the Weibull distribution given values for the others. */ -+ Calculates any one parameter of the Weibull distribution given values for the others. */ - PHP_FUNCTION(stats_cdf_weibull) - { - double arg1; -@@ -2049,13 +2001,13 @@ PHP_FUNCTION(stats_cdf_weibull) +@@ -2047,13 +2001,13 @@ PHP_FUNCTION(stats_cdf_weibull) double b; zend_long which; @@ -662,16 +538,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2087,7 +2039,7 @@ PHP_FUNCTION(stats_cdf_weibull) - /* }}} */ - - /* {{{ proto float stats_cdf_uniform(float par1, float par2, float par3, int which) -- Calculates any one parameter of the uniform distribution given values for the others. */ -+ Calculates any one parameter of the uniform distribution given values for the others. */ - PHP_FUNCTION(stats_cdf_uniform) - { - double arg1; -@@ -2099,13 +2051,13 @@ PHP_FUNCTION(stats_cdf_uniform) +@@ -2097,13 +2051,13 @@ PHP_FUNCTION(stats_cdf_uniform) double b; zend_long which; @@ -687,7 +554,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2128,7 +2080,7 @@ PHP_FUNCTION(stats_cdf_uniform) +@@ -2126,7 +2080,7 @@ PHP_FUNCTION(stats_cdf_uniform) } if (which > 1 && (p < 0.0F || p > 1.0F)) { @@ -696,16 +563,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2163,7 +2115,7 @@ static double exponential_cdf(double x) - } - - /* {{{ proto float stats_cdf_exponential(float par1, float par2, int which) -- Calculates any one parameter of the exponential distribution given values for the others. */ -+ Calculates any one parameter of the exponential distribution given values for the others. */ - PHP_FUNCTION(stats_cdf_exponential) - { - double arg1; -@@ -2173,13 +2125,13 @@ PHP_FUNCTION(stats_cdf_exponential) +@@ -2171,13 +2125,13 @@ PHP_FUNCTION(stats_cdf_exponential) double scale; zend_long which; @@ -721,7 +579,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2209,18 +2161,19 @@ PHP_FUNCTION(stats_cdf_exponential) +@@ -2207,18 +2161,19 @@ PHP_FUNCTION(stats_cdf_exponential) /* RANDLIB functions */ /*********************/ @@ -743,14 +601,7 @@ index 32dc4e9..7418dd8 100644 } /* }}} */ -@@ -2243,22 +2196,22 @@ PHP_FUNCTION(stats_rand_getsd) - /* }}} */ - - /* {{{ proto int stats_rand_gen_iuniform(int low, int high) -- Generates integer uniformly distributed between LOW (inclusive) and HIGH (inclusive) */ -+ Generates integer uniformly distributed between LOW (inclusive) and HIGH (inclusive) */ - PHP_FUNCTION(stats_rand_gen_iuniform) - { +@@ -2247,16 +2202,16 @@ PHP_FUNCTION(stats_rand_gen_iuniform) zend_long low; zend_long high; @@ -770,14 +621,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2267,18 +2220,18 @@ PHP_FUNCTION(stats_rand_gen_iuniform) - /* }}} */ - - /* {{{ proto float stats_rand_gen_funiform(float low, float high) -- Generates uniform float between low (exclusive) and high (exclusive) */ -+ Generates uniform float between low (exclusive) and high (exclusive) */ - PHP_FUNCTION(stats_rand_gen_funiform) - { +@@ -2271,12 +2226,12 @@ PHP_FUNCTION(stats_rand_gen_funiform) double low; double high; @@ -792,25 +636,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2287,7 +2240,7 @@ PHP_FUNCTION(stats_rand_gen_funiform) - /* }}} */ - - /* {{{ proto int stats_rand_ignlgi(void) -- Generates random integer between 1 and 2147483562 */ -+ Generates random integer between 1 and 2147483562 */ - PHP_FUNCTION(stats_rand_ignlgi) - { - if (ZEND_NUM_ARGS() != 0) { -@@ -2299,7 +2252,7 @@ PHP_FUNCTION(stats_rand_ignlgi) - /* }}} */ - - /* {{{ proto float stats_rand_ranf(void) -- Returns a random floating point number from a uniform distribution over 0 - 1 (endpoints of this interval are not returned) using the current generator */ -+ Returns a random floating point number from a uniform distribution over 0 - 1 (endpoints of this interval are not returned) using the current generator */ - PHP_FUNCTION(stats_rand_ranf) - { - if (ZEND_NUM_ARGS() != 0) { -@@ -2317,12 +2270,12 @@ PHP_FUNCTION(stats_rand_gen_beta) +@@ -2315,12 +2270,12 @@ PHP_FUNCTION(stats_rand_gen_beta) double a; double b; @@ -825,7 +651,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2336,12 +2289,12 @@ PHP_FUNCTION(stats_rand_gen_chisquare) +@@ -2334,12 +2289,12 @@ PHP_FUNCTION(stats_rand_gen_chisquare) { double df; @@ -840,7 +666,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2355,12 +2308,12 @@ PHP_FUNCTION(stats_rand_gen_exponential) +@@ -2353,12 +2308,12 @@ PHP_FUNCTION(stats_rand_gen_exponential) { double av; @@ -855,7 +681,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2375,12 +2328,12 @@ PHP_FUNCTION(stats_rand_gen_f) +@@ -2373,12 +2328,12 @@ PHP_FUNCTION(stats_rand_gen_f) double dfn; double dfd; @@ -870,7 +696,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2395,12 +2348,12 @@ PHP_FUNCTION(stats_rand_gen_gamma) +@@ -2393,12 +2348,12 @@ PHP_FUNCTION(stats_rand_gen_gamma) double a; double r; @@ -885,7 +711,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2415,12 +2368,12 @@ PHP_FUNCTION(stats_rand_gen_noncentral_chisquare) +@@ -2413,12 +2368,12 @@ PHP_FUNCTION(stats_rand_gen_noncentral_chisquare) double df; double xnonc; @@ -900,17 +726,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2428,20 +2381,20 @@ PHP_FUNCTION(stats_rand_gen_noncentral_chisquare) - } - /* }}} */ - --/* {{{ proto float stats_rand_gen_noncenral_f(float dfn, float dfd, float xnonc) -+/* {{{ proto float stats_rand_gen_noncentral_f(float dfn, float dfd, float xnonc) - Generates a random deviate from the noncentral F (variance ratio) distribution with "dfn" degrees of freedom in the numerator, and "dfd" degrees of freedom in the denominator, and noncentrality parameter "xnonc". Method : directly generates ratio of noncentral numerator chisquare variate to central denominator chisquare variate. */ --PHP_FUNCTION(stats_rand_gen_noncenral_f) -+PHP_FUNCTION(stats_rand_gen_noncentral_f) - { - double dfn; +@@ -2434,12 +2389,12 @@ PHP_FUNCTION(stats_rand_gen_noncentral_f) double dfd; double xnonc; @@ -925,7 +741,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2456,12 +2409,12 @@ PHP_FUNCTION(stats_rand_gen_normal) +@@ -2454,12 +2409,12 @@ PHP_FUNCTION(stats_rand_gen_normal) double av; double sd; @@ -940,7 +756,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2478,7 +2431,7 @@ PHP_FUNCTION(stats_rand_phrase_to_seeds) +@@ -2476,7 +2431,7 @@ PHP_FUNCTION(stats_rand_phrase_to_seeds) long seed_1; long seed_2; @@ -949,7 +765,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } convert_to_string_ex(par1); -@@ -2500,12 +2453,12 @@ PHP_FUNCTION(stats_rand_ibinomial) +@@ -2498,12 +2453,12 @@ PHP_FUNCTION(stats_rand_ibinomial) zend_long n; double pp; @@ -964,7 +780,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2520,16 +2473,16 @@ PHP_FUNCTION(stats_rand_ibinomial_negative) +@@ -2518,16 +2473,16 @@ PHP_FUNCTION(stats_rand_ibinomial_negative) zend_long n; double p; @@ -984,7 +800,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2543,12 +2496,12 @@ PHP_FUNCTION(stats_rand_gen_ipoisson) +@@ -2541,12 +2496,12 @@ PHP_FUNCTION(stats_rand_gen_ipoisson) { double mu; @@ -999,7 +815,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2563,12 +2516,12 @@ PHP_FUNCTION(stats_rand_gen_noncentral_t) +@@ -2561,12 +2516,12 @@ PHP_FUNCTION(stats_rand_gen_noncentral_t) double df; double xnonc; @@ -1014,7 +830,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2583,7 +2536,7 @@ PHP_FUNCTION(stats_rand_gen_t) +@@ -2581,7 +2536,7 @@ PHP_FUNCTION(stats_rand_gen_t) zval *arg1; double df; @@ -1023,7 +839,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2591,7 +2544,7 @@ PHP_FUNCTION(stats_rand_gen_t) +@@ -2589,7 +2544,7 @@ PHP_FUNCTION(stats_rand_gen_t) df = Z_DVAL_P(arg1); if (df <= 0.0) { @@ -1032,7 +848,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2613,13 +2566,13 @@ PHP_FUNCTION(stats_dens_normal) +@@ -2611,13 +2566,13 @@ PHP_FUNCTION(stats_dens_normal) double y; double z; @@ -1048,7 +864,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2640,13 +2593,13 @@ PHP_FUNCTION(stats_dens_cauchy) +@@ -2638,13 +2593,13 @@ PHP_FUNCTION(stats_dens_cauchy) double y; double z; @@ -1064,7 +880,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2667,13 +2620,13 @@ PHP_FUNCTION(stats_dens_laplace) +@@ -2665,13 +2620,13 @@ PHP_FUNCTION(stats_dens_laplace) double y; double z; @@ -1080,7 +896,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2694,13 +2647,13 @@ PHP_FUNCTION(stats_dens_logistic) +@@ -2692,13 +2647,13 @@ PHP_FUNCTION(stats_dens_logistic) double y; double z; @@ -1096,7 +912,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2721,7 +2674,7 @@ PHP_FUNCTION(stats_dens_beta) +@@ -2719,7 +2674,7 @@ PHP_FUNCTION(stats_dens_beta) double x; double y; @@ -1105,7 +921,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2741,12 +2694,12 @@ PHP_FUNCTION(stats_dens_weibull) +@@ -2739,12 +2694,12 @@ PHP_FUNCTION(stats_dens_weibull) double x; double y; @@ -1120,7 +936,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2765,13 +2718,13 @@ PHP_FUNCTION(stats_dens_uniform) +@@ -2763,13 +2718,13 @@ PHP_FUNCTION(stats_dens_uniform) double x; double y; @@ -1136,7 +952,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2795,7 +2748,7 @@ PHP_FUNCTION(stats_dens_chisquare) +@@ -2793,7 +2748,7 @@ PHP_FUNCTION(stats_dens_chisquare) double y; double z; @@ -1145,7 +961,7 @@ index 32dc4e9..7418dd8 100644 "dd", &x, &dfr) == FAILURE) { RETURN_FALSE; } -@@ -2820,12 +2773,12 @@ PHP_FUNCTION(stats_dens_t) +@@ -2818,12 +2773,12 @@ PHP_FUNCTION(stats_dens_t) double fac3; double x; @@ -1160,7 +976,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2848,12 +2801,12 @@ PHP_FUNCTION(stats_dens_gamma) +@@ -2846,12 +2801,12 @@ PHP_FUNCTION(stats_dens_gamma) double x; double z; @@ -1175,7 +991,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2875,12 +2828,12 @@ PHP_FUNCTION(stats_dens_exponential) +@@ -2873,12 +2828,12 @@ PHP_FUNCTION(stats_dens_exponential) double x; double y; @@ -1190,16 +1006,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2895,7 +2848,7 @@ PHP_FUNCTION(stats_dens_exponential) - /* }}} */ - - /* {{{ proto float stats_dens_f(float x, float dfr1, float dfr2) -- Not documented */ -+ Not documented */ - PHP_FUNCTION(stats_dens_f) - { - double dfr1; -@@ -2909,7 +2862,7 @@ PHP_FUNCTION(stats_dens_f) +@@ -2907,7 +2862,7 @@ PHP_FUNCTION(stats_dens_f) double x; double z; @@ -1208,7 +1015,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2949,7 +2902,7 @@ PHP_FUNCTION(stats_dens_pmf_binomial) +@@ -2947,7 +2902,7 @@ PHP_FUNCTION(stats_dens_pmf_binomial) double n; double x; @@ -1217,7 +1024,7 @@ index 32dc4e9..7418dd8 100644 "ddd", &x, &n, &pi) == FAILURE) { RETURN_FALSE; } -@@ -2957,7 +2910,7 @@ PHP_FUNCTION(stats_dens_pmf_binomial) +@@ -2955,7 +2910,7 @@ PHP_FUNCTION(stats_dens_pmf_binomial) if ((x == 0.0 && n == 0.0) || (pi == 0.0 && x == 0.0) || ( (1.0 - pi) == 0.0 && (n - x) == 0) ) { @@ -1226,7 +1033,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2975,7 +2928,7 @@ PHP_FUNCTION(stats_dens_pmf_poisson) +@@ -2973,7 +2928,7 @@ PHP_FUNCTION(stats_dens_pmf_poisson) double z; double x; @@ -1235,7 +1042,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -2994,12 +2947,12 @@ PHP_FUNCTION(stats_dens_pmf_negative_binomial) +@@ -2992,12 +2947,12 @@ PHP_FUNCTION(stats_dens_pmf_negative_binomial) double n; double x; @@ -1250,16 +1057,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3010,7 +2963,7 @@ PHP_FUNCTION(stats_dens_pmf_negative_binomial) - /* }}} */ - - /* {{{ proto float stats_dens_pmf_hypergeometric(float n1, float n2, float N1, float N2) -- Not documented */ -+ Not documented */ - PHP_FUNCTION(stats_dens_pmf_hypergeometric) - { - double y; -@@ -3019,12 +2972,12 @@ PHP_FUNCTION(stats_dens_pmf_hypergeometric) +@@ -3017,12 +2972,12 @@ PHP_FUNCTION(stats_dens_pmf_hypergeometric) double n1; double n2; @@ -1274,7 +1072,7 @@ index 32dc4e9..7418dd8 100644 /* RETURN_FALSE; */ } -@@ -3047,7 +3000,7 @@ PHP_FUNCTION(stats_stat_powersum) +@@ -3045,7 +3000,7 @@ PHP_FUNCTION(stats_stat_powersum) double power; double sum = 0.0; @@ -1283,7 +1081,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3061,7 +3014,7 @@ PHP_FUNCTION(stats_stat_powersum) +@@ -3059,7 +3014,7 @@ PHP_FUNCTION(stats_stat_powersum) if (Z_DVAL_P(data) != 0 || power != 0) { sum += pow (Z_DVAL_P(data), power); } else { @@ -1292,16 +1090,7 @@ index 32dc4e9..7418dd8 100644 } zend_hash_move_forward_ex(Z_ARRVAL_P(arg1), &pos); } -@@ -3071,7 +3024,7 @@ PHP_FUNCTION(stats_stat_powersum) - /* }}} */ - - /* {{{ proto float stats_stat_innerproduct(array arr1, array arr2) -- Not documented */ -+ Not documented */ - PHP_FUNCTION(stats_stat_innerproduct) - { - zval *arg1, *arg2; -@@ -3081,14 +3034,14 @@ PHP_FUNCTION(stats_stat_innerproduct) +@@ -3079,14 +3034,14 @@ PHP_FUNCTION(stats_stat_innerproduct) double sum = 0.0; @@ -1318,7 +1107,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3130,7 +3083,7 @@ PHP_FUNCTION(stats_stat_independent_t) +@@ -3128,7 +3083,7 @@ PHP_FUNCTION(stats_stat_independent_t) double fc; double ts; @@ -1327,7 +1116,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } convert_to_array_ex(arg1); -@@ -3139,7 +3092,7 @@ PHP_FUNCTION(stats_stat_independent_t) +@@ -3137,7 +3092,7 @@ PHP_FUNCTION(stats_stat_independent_t) xnum = zend_hash_num_elements(Z_ARRVAL_P(arg1)); ynum = zend_hash_num_elements(Z_ARRVAL_P(arg2)); if ( xnum < 2 || ynum < 2) { @@ -1336,7 +1125,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3189,7 +3142,7 @@ PHP_FUNCTION(stats_stat_paired_t) +@@ -3187,7 +3142,7 @@ PHP_FUNCTION(stats_stat_paired_t) double ts; double cur; @@ -1345,7 +1134,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } convert_to_array_ex(arg1); -@@ -3199,11 +3152,11 @@ PHP_FUNCTION(stats_stat_paired_t) +@@ -3197,11 +3152,11 @@ PHP_FUNCTION(stats_stat_paired_t) ynum = zend_hash_num_elements(Z_ARRVAL_P(arg2)); if (xnum != ynum) { @@ -1359,16 +1148,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3231,7 +3184,7 @@ PHP_FUNCTION(stats_stat_paired_t) - /* }}} */ - - /* {{{ proto float stats_stat_percentile(array arr, float perc) -- Not documented */ -+ Not documented */ - PHP_FUNCTION(stats_stat_percentile) - { - zval *arg1, *arg2; -@@ -3246,7 +3199,7 @@ PHP_FUNCTION(stats_stat_percentile) +@@ -3244,7 +3199,7 @@ PHP_FUNCTION(stats_stat_percentile) double upp; double val = 0.0; @@ -1377,7 +1157,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3256,9 +3209,7 @@ PHP_FUNCTION(stats_stat_percentile) +@@ -3254,9 +3209,7 @@ PHP_FUNCTION(stats_stat_percentile) xnum = zend_hash_num_elements(Z_ARRVAL_P(arg1)); @@ -1388,7 +1168,7 @@ index 32dc4e9..7418dd8 100644 zend_hash_internal_pointer_reset_ex(Z_ARRVAL_P(arg1), &pos1); -@@ -3317,7 +3268,7 @@ PHP_FUNCTION(stats_stat_correlation) +@@ -3315,7 +3268,7 @@ PHP_FUNCTION(stats_stat_correlation) double cc; double rr; @@ -1397,7 +1177,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3328,7 +3279,7 @@ PHP_FUNCTION(stats_stat_correlation) +@@ -3326,7 +3279,7 @@ PHP_FUNCTION(stats_stat_correlation) ynum = zend_hash_num_elements(Z_ARRVAL_P(arg2)); if (xnum != ynum) { @@ -1406,7 +1186,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3371,7 +3322,7 @@ PHP_FUNCTION(stats_stat_binomial_coef) +@@ -3369,7 +3322,7 @@ PHP_FUNCTION(stats_stat_binomial_coef) zend_long x; double bc = 1.0; @@ -1415,7 +1195,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3391,7 +3342,7 @@ PHP_FUNCTION(stats_stat_factorial) +@@ -3389,7 +3342,7 @@ PHP_FUNCTION(stats_stat_factorial) zend_long i; double f = 1; @@ -1424,14 +1204,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3459,21 +3410,21 @@ static long double php_population_variance(zval *arr, zend_bool sample) - - - /* {{{ proto float stats_variance(array a [, bool sample = false]) -- Returns the population variance */ -+ Returns the population variance */ - PHP_FUNCTION(stats_variance) - { +@@ -3463,15 +3416,15 @@ PHP_FUNCTION(stats_variance) zval *arr; zend_bool sample = 0; @@ -1451,14 +1224,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } RETURN_DOUBLE(php_population_variance(arr, sample)); -@@ -3481,21 +3432,21 @@ PHP_FUNCTION(stats_variance) - /* }}} */ - - /* {{{ proto float stats_standard_deviation(array a [, bool sample = false]) -- Returns the standard deviation */ -+ Returns the standard deviation */ - PHP_FUNCTION(stats_standard_deviation) - { +@@ -3485,15 +3438,15 @@ PHP_FUNCTION(stats_standard_deviation) zval *arr; zend_bool sample = 0; @@ -1478,16 +1244,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } RETURN_DOUBLE(sqrt(php_population_variance(arr, sample))); -@@ -3504,7 +3455,7 @@ PHP_FUNCTION(stats_standard_deviation) - - - /* {{{ proto float stats_absolute_deviation(array a) -- Returns the absolute deviation of an array of values */ -+ Returns the absolute deviation of an array of values */ - PHP_FUNCTION(stats_absolute_deviation) - { - zval *arr; -@@ -3513,11 +3464,11 @@ PHP_FUNCTION(stats_absolute_deviation) +@@ -3511,11 +3464,11 @@ PHP_FUNCTION(stats_absolute_deviation) HashPosition pos; int elements_num; @@ -1502,16 +1259,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3534,7 +3485,7 @@ PHP_FUNCTION(stats_absolute_deviation) - /* }}} */ - - /* {{{ proto float stats_harmonic_mean(array a) -- Returns the harmonic mean of an array of values */ -+ Returns the harmonic mean of an array of values */ - PHP_FUNCTION(stats_harmonic_mean) - { - zval *arr; -@@ -3543,11 +3494,11 @@ PHP_FUNCTION(stats_harmonic_mean) +@@ -3541,11 +3494,11 @@ PHP_FUNCTION(stats_harmonic_mean) HashPosition pos; int elements_num; @@ -1526,16 +1274,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3566,7 +3517,7 @@ PHP_FUNCTION(stats_harmonic_mean) - /* }}} */ - - /* {{{ proto float stats_skew(array a) -- Computes the skewness of the data in the array */ -+ Computes the skewness of the data in the array */ - PHP_FUNCTION(stats_skew) - { - zval *arr; -@@ -3575,11 +3526,11 @@ PHP_FUNCTION(stats_skew) +@@ -3573,11 +3526,11 @@ PHP_FUNCTION(stats_skew) HashPosition pos; int elements_num, i = 0; @@ -1550,16 +1289,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3604,7 +3555,7 @@ PHP_FUNCTION(stats_skew) - /* }}} */ - - /* {{{ proto float stats_kurtosis(array a) -- Computes the kurtosis of the data in the array */ -+ Computes the kurtosis of the data in the array */ - PHP_FUNCTION(stats_kurtosis) - { - zval *arr; -@@ -3613,11 +3564,11 @@ PHP_FUNCTION(stats_kurtosis) +@@ -3611,11 +3564,11 @@ PHP_FUNCTION(stats_kurtosis) HashPosition pos; int elements_num, i = 0; @@ -1574,16 +1304,7 @@ index 32dc4e9..7418dd8 100644 RETURN_FALSE; } -@@ -3644,7 +3595,7 @@ PHP_FUNCTION(stats_kurtosis) - - - /* {{{ proto float stats_covariance(array a, array b) -- Computes the covariance of two data sets */ -+ Computes the covariance of two data sets */ - PHP_FUNCTION(stats_covariance) - { - zval *arr_1, *arr_2; -@@ -3653,19 +3604,19 @@ PHP_FUNCTION(stats_covariance) +@@ -3651,19 +3604,19 @@ PHP_FUNCTION(stats_covariance) HashPosition pos_1, pos_2; int elements_num, i = 0; @@ -1609,19 +1330,10 @@ index 32dc4e9..7418dd8 100644 } diff --git a/php_stats.h b/php_stats.h -index af449b3..090ef3d 100644 +index 10a9b22..090ef3d 100644 --- a/php_stats.h +++ b/php_stats.h -@@ -16,8 +16,6 @@ - +----------------------------------------------------------------------+ - */ - --/* $Id$ */ -- - #ifndef PHP_STATS_H - #define PHP_STATS_H - -@@ -35,77 +33,6 @@ extern zend_module_entry stats_module_entry; +@@ -33,77 +33,6 @@ extern zend_module_entry stats_module_entry; PHP_MINFO_FUNCTION(stats); @@ -1655,7 +1367,7 @@ index af449b3..090ef3d 100644 -PHP_FUNCTION(stats_rand_gen_f); -PHP_FUNCTION(stats_rand_gen_gamma); -PHP_FUNCTION(stats_rand_gen_noncentral_chisquare); --PHP_FUNCTION(stats_rand_gen_noncenral_f); +-PHP_FUNCTION(stats_rand_gen_noncentral_f); -PHP_FUNCTION(stats_rand_gen_normal); -PHP_FUNCTION(stats_rand_phrase_to_seeds); -PHP_FUNCTION(stats_rand_ibinomial); @@ -1699,6 +1411,89 @@ index af449b3..090ef3d 100644 #ifdef ZTS #define STATS_D zend_stats_globals *stats_globals #define STATS_G(v) (stats_globals->v) +diff --git a/stats.stub.php b/stats.stub.php +new file mode 100644 +index 0000000..8b6b006 +--- /dev/null ++++ b/stats.stub.php +@@ -0,0 +1,77 @@ ++ ----EXPECTF-- --bool(true) -- --Warning: stats_rand_gen_noncenral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 9.000000E-1 dfd: 3.000000E+0 xnonc: 4.000000E+0 in %s on line %d --bool(false) -- --Warning: stats_rand_gen_noncenral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: -1.000000E-1 xnonc: 4.000000E+0 in %s on line %d --bool(false) -- --Warning: stats_rand_gen_noncenral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: 0.000000E+0 xnonc: 4.000000E+0 in %s on line %d --bool(false) -- --Warning: stats_rand_gen_noncenral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: 3.000000E+0 xnonc: -1.000000E-1 in %s on line %d --bool(false) diff --git a/tests/stats_rand_gen_noncentral_f.phpt b/tests/stats_rand_gen_noncentral_f.phpt -new file mode 100644 -index 0000000..30f6426 ---- /dev/null +index 39b846a..30f6426 100644 +--- a/tests/stats_rand_gen_noncentral_f.phpt +++ b/tests/stats_rand_gen_noncentral_f.phpt -@@ -0,0 +1,28 @@ -+--TEST-- -+stats_rand_gen_noncentral_f() +@@ -1,5 +1,7 @@ + --TEST-- + stats_rand_gen_noncentral_f() +--INI-- +serialize_precision=14 -+--FILE-- -+ -+--EXPECTF-- -+bool(true) -+ -+Warning: stats_rand_gen_noncentral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 9.000000E-1 dfd: 3.000000E+0 xnonc: 4.000000E+0 in %s on line %d -+bool(false) -+ -+Warning: stats_rand_gen_noncentral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: -1.000000E-1 xnonc: 4.000000E+0 in %s on line %d -+bool(false) -+ -+Warning: stats_rand_gen_noncentral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: 0.000000E+0 xnonc: 4.000000E+0 in %s on line %d -+bool(false) -+ -+Warning: stats_rand_gen_noncentral_f(): Either (1) Numerator df < 1.0 or (2) Denominator df <= 0.0 or (3) Noncentrality parameter < 0.0. dfn: 2.000000E+0 dfd: 3.000000E+0 xnonc: -1.000000E-1 in %s on line %d -+bool(false) + --FILE-- +