summaryrefslogtreecommitdiffstats
path: root/gsl-1.9/cdf
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2011-04-08 17:33:11 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2011-04-08 17:33:11 +0000
commit73f643f3f4a55310b2c8c1a9858906b2dd676e72 (patch)
treeb1df97f18dace4a5702b0bc7aafdfee8a2f25ada /gsl-1.9/cdf
parent2011-04-08 Joel Sherrill <joel.sherrill@oarcorp.com> (diff)
downloadrtems-addon-packages-73f643f3f4a55310b2c8c1a9858906b2dd676e72.tar.bz2
2011-04-08 Joel Sherrill <joel.sherrill@oarcorp.com>
* AUTHORS, BUGS, COPYING, ChangeLog, INSTALL, Makefile.am, Makefile.in, NEWS, README, SUPPORT, THANKS, TODO, acconfig.h, aclocal.m4, autogen.sh, config.guess, config.h.in, config.sub, configure, configure.ac, gsl-config.in, gsl-histogram.c, gsl-randist.c, gsl.m4, gsl.pc.in, gsl.spec.in, gsl_machine.h, gsl_math.h, gsl_mode.h, gsl_nan.h, gsl_pow_int.h, gsl_precision.h, gsl_types.h, gsl_version.h.in, install-sh, ltmain.sh, mdate-sh, missing, mkinstalldirs, templates_off.h, templates_on.h, test_gsl_histogram.sh, version.c, blas/ChangeLog, blas/Makefile.am, blas/Makefile.in, blas/TODO, blas/blas.c, blas/gsl_blas.h, blas/gsl_blas_types.h, block/ChangeLog, block/Makefile.am, block/Makefile.in, block/block.c, block/block_source.c, block/file.c, block/fprintf_source.c, block/fwrite_source.c, block/gsl_block.h, block/gsl_block_char.h, block/gsl_block_complex_double.h, block/gsl_block_complex_float.h, block/gsl_block_complex_long_double.h, block/gsl_block_double.h, block/gsl_block_float.h, block/gsl_block_int.h, block/gsl_block_long.h, block/gsl_block_long_double.h, block/gsl_block_short.h, block/gsl_block_uchar.h, block/gsl_block_uint.h, block/gsl_block_ulong.h, block/gsl_block_ushort.h, block/gsl_check_range.h, block/init.c, block/init_source.c, block/test.c, block/test_complex_io.c, block/test_complex_source.c, block/test_io.c, block/test_source.c, bspline/ChangeLog, bspline/Makefile.am, bspline/Makefile.in, bspline/TODO, bspline/bspline.c, bspline/gsl_bspline.h, bspline/test.c, cblas/ChangeLog, cblas/Makefile.am, cblas/Makefile.in, cblas/TODO, cblas/caxpy.c, cblas/cblas.h, cblas/ccopy.c, cblas/cdotc_sub.c, cblas/cdotu_sub.c, cblas/cgbmv.c, cblas/cgemm.c, cblas/cgemv.c, cblas/cgerc.c, cblas/cgeru.c, cblas/chbmv.c, cblas/chemm.c, cblas/chemv.c, cblas/cher.c, cblas/cher2.c, cblas/cher2k.c, cblas/cherk.c, cblas/chpmv.c, cblas/chpr.c, cblas/chpr2.c, cblas/cscal.c, cblas/csscal.c, cblas/cswap.c, cblas/csymm.c, cblas/csyr2k.c, cblas/csyrk.c, cblas/ctbmv.c, cblas/ctbsv.c, cblas/ctpmv.c, cblas/ctpsv.c, cblas/ctrmm.c, cblas/ctrmv.c, cblas/ctrsm.c, cblas/ctrsv.c, cblas/dasum.c, cblas/daxpy.c, cblas/dcopy.c, cblas/ddot.c, cblas/dgbmv.c, cblas/dgemm.c, cblas/dgemv.c, cblas/dger.c, cblas/dnrm2.c, cblas/drot.c, cblas/drotg.c, cblas/drotm.c, cblas/drotmg.c, cblas/dsbmv.c, cblas/dscal.c, cblas/dsdot.c, cblas/dspmv.c, cblas/dspr.c, cblas/dspr2.c, cblas/dswap.c, cblas/dsymm.c, cblas/dsymv.c, cblas/dsyr.c, cblas/dsyr2.c, cblas/dsyr2k.c, cblas/dsyrk.c, cblas/dtbmv.c, cblas/dtbsv.c, cblas/dtpmv.c, cblas/dtpsv.c, cblas/dtrmm.c, cblas/dtrmv.c, cblas/dtrsm.c, cblas/dtrsv.c, cblas/dzasum.c, cblas/dznrm2.c, cblas/gsl_cblas.h, cblas/hypot.c, cblas/icamax.c, cblas/idamax.c, cblas/isamax.c, cblas/izamax.c, cblas/sasum.c, cblas/saxpy.c, cblas/scasum.c, cblas/scnrm2.c, cblas/scopy.c, cblas/sdot.c, cblas/sdsdot.c, cblas/sgbmv.c, cblas/sgemm.c, cblas/sgemv.c, cblas/sger.c, cblas/snrm2.c, cblas/source_asum_c.h, cblas/source_asum_r.h, cblas/source_axpy_c.h, cblas/source_axpy_r.h, cblas/source_copy_c.h, cblas/source_copy_r.h, cblas/source_dot_c.h, cblas/source_dot_r.h, cblas/source_gbmv_c.h, cblas/source_gbmv_r.h, cblas/source_gemm_c.h, cblas/source_gemm_r.h, cblas/source_gemv_c.h, cblas/source_gemv_r.h, cblas/source_ger.h, cblas/source_gerc.h, cblas/source_geru.h, cblas/source_hbmv.h, cblas/source_hemm.h, cblas/source_hemv.h, cblas/source_her.h, cblas/source_her2.h, cblas/source_her2k.h, cblas/source_herk.h, cblas/source_hpmv.h, cblas/source_hpr.h, cblas/source_hpr2.h, cblas/source_iamax_c.h, cblas/source_iamax_r.h, cblas/source_nrm2_c.h, cblas/source_nrm2_r.h, cblas/source_rot.h, cblas/source_rotg.h, cblas/source_rotm.h, cblas/source_rotmg.h, cblas/source_sbmv.h, cblas/source_scal_c.h, cblas/source_scal_c_s.h, cblas/source_scal_r.h, cblas/source_spmv.h, cblas/source_spr.h, cblas/source_spr2.h, cblas/source_swap_c.h, cblas/source_swap_r.h, cblas/source_symm_c.h, cblas/source_symm_r.h, cblas/source_symv.h, cblas/source_syr.h, cblas/source_syr2.h, cblas/source_syr2k_c.h, cblas/source_syr2k_r.h, cblas/source_syrk_c.h, cblas/source_syrk_r.h, cblas/source_tbmv_c.h, cblas/source_tbmv_r.h, cblas/source_tbsv_c.h, cblas/source_tbsv_r.h, cblas/source_tpmv_c.h, cblas/source_tpmv_r.h, cblas/source_tpsv_c.h, cblas/source_tpsv_r.h, cblas/source_trmm_c.h, cblas/source_trmm_r.h, cblas/source_trmv_c.h, cblas/source_trmv_r.h, cblas/source_trsm_c.h, cblas/source_trsm_r.h, cblas/source_trsv_c.h, cblas/source_trsv_r.h, cblas/srot.c, cblas/srotg.c, cblas/srotm.c, cblas/srotmg.c, cblas/ssbmv.c, cblas/sscal.c, cblas/sspmv.c, cblas/sspr.c, cblas/sspr2.c, cblas/sswap.c, cblas/ssymm.c, cblas/ssymv.c, cblas/ssyr.c, cblas/ssyr2.c, cblas/ssyr2k.c, cblas/ssyrk.c, cblas/stbmv.c, cblas/stbsv.c, cblas/stpmv.c, cblas/stpsv.c, cblas/strmm.c, cblas/strmv.c, cblas/strsm.c, cblas/strsv.c, cblas/test.c, cblas/test_amax.c, cblas/test_asum.c, cblas/test_axpy.c, cblas/test_copy.c, cblas/test_dot.c, cblas/test_gbmv.c, cblas/test_gemm.c, cblas/test_gemv.c, cblas/test_ger.c, cblas/test_hbmv.c, cblas/test_hemm.c, cblas/test_hemv.c, cblas/test_her.c, cblas/test_her2.c, cblas/test_her2k.c, cblas/test_herk.c, cblas/test_hpmv.c, cblas/test_hpr.c, cblas/test_hpr2.c, cblas/test_nrm2.c, cblas/test_rot.c, cblas/test_rotg.c, cblas/test_rotm.c, cblas/test_rotmg.c, cblas/test_sbmv.c, cblas/test_scal.c, cblas/test_spmv.c, cblas/test_spr.c, cblas/test_spr2.c, cblas/test_swap.c, cblas/test_symm.c, cblas/test_symv.c, cblas/test_syr.c, cblas/test_syr2.c, cblas/test_syr2k.c, cblas/test_syrk.c, cblas/test_tbmv.c, cblas/test_tbsv.c, cblas/test_tpmv.c, cblas/test_tpsv.c, cblas/test_trmm.c, cblas/test_trmv.c, cblas/test_trsm.c, cblas/test_trsv.c, cblas/tests.c, cblas/tests.h, cblas/xerbla.c, cblas/zaxpy.c, cblas/zcopy.c, cblas/zdotc_sub.c, cblas/zdotu_sub.c, cblas/zdscal.c, cblas/zgbmv.c, cblas/zgemm.c, cblas/zgemv.c, cblas/zgerc.c, cblas/zgeru.c, cblas/zhbmv.c, cblas/zhemm.c, cblas/zhemv.c, cblas/zher.c, cblas/zher2.c, cblas/zher2k.c, cblas/zherk.c, cblas/zhpmv.c, cblas/zhpr.c, cblas/zhpr2.c, cblas/zscal.c, cblas/zswap.c, cblas/zsymm.c, cblas/zsyr2k.c, cblas/zsyrk.c, cblas/ztbmv.c, cblas/ztbsv.c, cblas/ztpmv.c, cblas/ztpsv.c, cblas/ztrmm.c, cblas/ztrmv.c, cblas/ztrsm.c, cblas/ztrsv.c, cdf/ChangeLog, cdf/Makefile.am, cdf/Makefile.in, cdf/beta.c, cdf/beta_inc.c, cdf/betainv.c, cdf/binomial.c, cdf/cauchy.c, cdf/cauchyinv.c, cdf/chisq.c, cdf/chisqinv.c, cdf/error.h, cdf/exponential.c, cdf/exponentialinv.c, cdf/exppow.c, cdf/fdist.c, cdf/fdistinv.c, cdf/flat.c, cdf/flatinv.c, cdf/gamma.c, cdf/gammainv.c, cdf/gauss.c, cdf/gaussinv.c, cdf/geometric.c, cdf/gsl_cdf.h, cdf/gumbel1.c, cdf/gumbel1inv.c, cdf/gumbel2.c, cdf/gumbel2inv.c, cdf/hypergeometric.c, cdf/laplace.c, cdf/laplaceinv.c, cdf/logistic.c, cdf/logisticinv.c, cdf/lognormal.c, cdf/lognormalinv.c, cdf/nbinomial.c, cdf/pareto.c, cdf/paretoinv.c, cdf/pascal.c, cdf/poisson.c, cdf/rat_eval.h, cdf/rayleigh.c, cdf/rayleighinv.c, cdf/tdist.c, cdf/tdistinv.c, cdf/test.c, cdf/test_auto.c, cdf/weibull.c, cdf/weibullinv.c, cheb/ChangeLog, cheb/Makefile.am, cheb/Makefile.in, cheb/deriv.c, cheb/eval.c, cheb/gsl_chebyshev.h, cheb/init.c, cheb/integ.c, cheb/test.c, combination/ChangeLog, combination/Makefile.am, combination/Makefile.in, combination/combination.c, combination/file.c, combination/gsl_combination.h, combination/init.c, combination/test.c, complex/ChangeLog, complex/Makefile.am, complex/Makefile.in, complex/TODO, complex/gsl_complex.h, complex/gsl_complex_math.h, complex/math.c, complex/results.h, complex/results1.h, complex/results_real.h, complex/test.c, const/ChangeLog, const/Makefile.am, const/Makefile.in, const/TODO, const/gsl_const.h, const/gsl_const_cgs.h, const/gsl_const_cgsm.h, const/gsl_const_mks.h, const/gsl_const_mksa.h, const/gsl_const_num.h, const/test.c, deriv/ChangeLog, deriv/Makefile.am, deriv/Makefile.in, deriv/deriv.c, deriv/gsl_deriv.h, deriv/test.c, dht/ChangeLog, dht/Makefile.am, dht/Makefile.in, dht/dht.c, dht/gsl_dht.h, dht/test.c, diff/ChangeLog, diff/Makefile.am, diff/Makefile.in, diff/diff.c, diff/gsl_diff.h, diff/test.c, doc/12-cities.eps, doc/ChangeLog, doc/Makefile.am, doc/Makefile.in, doc/algorithm.sty, doc/algorithmic.sty, doc/autoconf.texi, doc/blas.texi, doc/bspline.eps, doc/bspline.texi, doc/calc.sty, doc/cblas.texi, doc/cheb.eps, doc/cheb.texi, doc/combination.texi, doc/complex.texi, doc/const.texi, doc/debug.texi, doc/dht.texi, doc/diff.texi, doc/dwt-orig.eps, doc/dwt-samp.eps, doc/dwt.texi, doc/eigen.texi, doc/err.texi, doc/fdl.texi, doc/fft-complex-radix2-f.eps, doc/fft-complex-radix2-t.eps, doc/fft-complex-radix2.eps, doc/fft-real-mixedradix.eps, doc/fft.texi, doc/fftalgorithms.bib, doc/fftalgorithms.tex, doc/final-route.eps, doc/fit-exp.eps, doc/fit-wlinear.eps, doc/fit-wlinear2.eps, doc/fitting.texi, doc/freemanuals.texi, doc/gpl.texi, doc/gsl-config.1, doc/gsl-design.texi, doc/gsl-histogram.1, doc/gsl-randist.1, doc/gsl-ref.info, doc/gsl-ref.info-1, doc/gsl-ref.info-2, doc/gsl-ref.info-3, doc/gsl-ref.info-4, doc/gsl-ref.info-5, doc/gsl-ref.info-6, doc/gsl-ref.texi, doc/gsl.3, doc/histogram.eps, doc/histogram.texi, doc/histogram2d.eps, doc/ieee754.texi, doc/initial-route.eps, doc/integration.texi, doc/interp.texi, doc/interp2.eps, doc/interpp2.eps, doc/intro.texi, doc/landau.dat, doc/linalg.texi, doc/math.texi, doc/mdate-sh, doc/min-interval.eps, doc/min.texi, doc/montecarlo.texi, doc/multifit.texi, doc/multimin.eps, doc/multimin.texi, doc/multiroots.texi, doc/ntuple.eps, doc/ntuple.texi, doc/ode-initval.texi, doc/permutation.texi, doc/poly.texi, doc/qrng.eps, doc/qrng.texi, doc/rand-bernoulli.tex, doc/rand-beta.tex, doc/rand-binomial.tex, doc/rand-bivariate-gaussian.tex, doc/rand-cauchy.tex, doc/rand-chisq.tex, doc/rand-erlang.tex, doc/rand-exponential.tex, doc/rand-exppow.tex, doc/rand-fdist.tex, doc/rand-flat.tex, doc/rand-gamma.tex, doc/rand-gaussian-tail.tex, doc/rand-gaussian.tex, doc/rand-geometric.tex, doc/rand-gumbel.tex, doc/rand-gumbel1.tex, doc/rand-gumbel2.tex, doc/rand-hypergeometric.tex, doc/rand-landau.tex, doc/rand-laplace.tex, doc/rand-levy.tex, doc/rand-levyskew.tex, doc/rand-logarithmic.tex, doc/rand-logistic.tex, doc/rand-lognormal.tex, doc/rand-nbinomial.tex, doc/rand-pareto.tex, doc/rand-pascal.tex, doc/rand-poisson.tex, doc/rand-rayleigh-tail.tex, doc/rand-rayleigh.tex, doc/rand-tdist.tex, doc/rand-weibull.tex, doc/randist.texi, doc/random-walk.tex, doc/randplots.gnp, doc/rng.texi, doc/roots-bisection.eps, doc/roots-false-position.eps, doc/roots-newtons-method.eps, doc/roots-secant-method.eps, doc/roots.texi, doc/siman-energy.eps, doc/siman-test.eps, doc/siman.texi, doc/sort.texi, doc/specfunc-airy.texi, doc/specfunc-bessel.texi, doc/specfunc-clausen.texi, doc/specfunc-coulomb.texi, doc/specfunc-coupling.texi, doc/specfunc-dawson.texi, doc/specfunc-debye.texi, doc/specfunc-dilog.texi, doc/specfunc-elementary.texi, doc/specfunc-ellint.texi, doc/specfunc-elljac.texi, doc/specfunc-erf.texi, doc/specfunc-exp.texi, doc/specfunc-expint.texi, doc/specfunc-fermi-dirac.texi, doc/specfunc-gamma.texi, doc/specfunc-gegenbauer.texi, doc/specfunc-hyperg.texi, doc/specfunc-laguerre.texi, doc/specfunc-lambert.texi, doc/specfunc-legendre.texi, doc/specfunc-log.texi, doc/specfunc-mathieu.texi, doc/specfunc-pow-int.texi, doc/specfunc-psi.texi, doc/specfunc-synchrotron.texi, doc/specfunc-transport.texi, doc/specfunc-trig.texi, doc/specfunc-zeta.texi, doc/specfunc.texi, doc/stamp-vti, doc/statistics.texi, doc/sum.texi, doc/texinfo.tex, doc/usage.texi, doc/vdp.eps, doc/vectors.texi, doc/version-ref.texi, doc/examples/blas.c, doc/examples/blas.out, doc/examples/block.c, doc/examples/block.out, doc/examples/bspline.c, doc/examples/cblas.c, doc/examples/cblas.out, doc/examples/cdf.c, doc/examples/cdf.out, doc/examples/cheb.c, doc/examples/combination.c, doc/examples/combination.out, doc/examples/const.c, doc/examples/const.out, doc/examples/demo_fn.c, doc/examples/demo_fn.h, doc/examples/diff.c, doc/examples/diff.out, doc/examples/dwt.c, doc/examples/dwt.dat, doc/examples/ecg.dat, doc/examples/eigen.c, doc/examples/eigen_nonsymm.c, doc/examples/expfit.c, doc/examples/fft.c, doc/examples/fftmr.c, doc/examples/fftreal.c, doc/examples/fitting.c, doc/examples/fitting2.c, doc/examples/fitting3.c, doc/examples/histogram.c, doc/examples/histogram2d.c, doc/examples/ieee.c, doc/examples/ieeeround.c, doc/examples/integration.c, doc/examples/integration.out, doc/examples/interp.c, doc/examples/interpp.c, doc/examples/intro.c, doc/examples/intro.out, doc/examples/linalglu.c, doc/examples/linalglu.out, doc/examples/matrix.c, doc/examples/matrixw.c, doc/examples/min.c, doc/examples/min.out, doc/examples/monte.c, doc/examples/nlfit.c, doc/examples/ntupler.c, doc/examples/ntuplew.c, doc/examples/ode-initval.c, doc/examples/odefixed.c, doc/examples/permseq.c, doc/examples/permshuffle.c, doc/examples/polyroots.c, doc/examples/polyroots.out, doc/examples/qrng.c, doc/examples/randpoisson.2.out, doc/examples/randpoisson.c, doc/examples/randpoisson.out, doc/examples/randwalk.c, doc/examples/rng.c, doc/examples/rng.out, doc/examples/rngunif.2.out, doc/examples/rngunif.c, doc/examples/rngunif.out, doc/examples/rootnewt.c, doc/examples/roots.c, doc/examples/siman.c, doc/examples/sortsmall.c, doc/examples/sortsmall.out, doc/examples/specfun.c, doc/examples/specfun.out, doc/examples/specfun_e.c, doc/examples/specfun_e.out, doc/examples/stat.c, doc/examples/stat.out, doc/examples/statsort.c, doc/examples/statsort.out, doc/examples/sum.c, doc/examples/sum.out, doc/examples/vector.c, doc/examples/vectorr.c, doc/examples/vectorview.c, doc/examples/vectorview.out, doc/examples/vectorw.c, eigen/ChangeLog, eigen/Makefile.am, eigen/Makefile.in, eigen/TODO, eigen/francis.c, eigen/gsl_eigen.h, eigen/herm.c, eigen/hermv.c, eigen/jacobi.c, eigen/nonsymm.c, eigen/nonsymmv.c, eigen/qrstep.c, eigen/schur.c, eigen/schur.h, eigen/sort.c, eigen/symm.c, eigen/symmv.c, eigen/test.c, err/ChangeLog, err/Makefile.am, err/Makefile.in, err/TODO, err/error.c, err/gsl_errno.h, err/gsl_message.h, err/message.c, err/stream.c, err/strerror.c, err/test.c, fft/ChangeLog, fft/Makefile.am, fft/Makefile.in, fft/TODO, fft/bitreverse.c, fft/bitreverse.h, fft/c_init.c, fft/c_main.c, fft/c_pass.h, fft/c_pass_2.c, fft/c_pass_3.c, fft/c_pass_4.c, fft/c_pass_5.c, fft/c_pass_6.c, fft/c_pass_7.c, fft/c_pass_n.c, fft/c_radix2.c, fft/compare.h, fft/compare_source.c, fft/complex_internal.h, fft/dft.c, fft/dft_source.c, fft/factorize.c, fft/factorize.h, fft/fft.c, fft/gsl_dft_complex.h, fft/gsl_dft_complex_float.h, fft/gsl_fft.h, fft/gsl_fft_complex.h, fft/gsl_fft_complex_float.h, fft/gsl_fft_halfcomplex.h, fft/gsl_fft_halfcomplex_float.h, fft/gsl_fft_real.h, fft/gsl_fft_real_float.h, fft/hc_init.c, fft/hc_main.c, fft/hc_pass.h, fft/hc_pass_2.c, fft/hc_pass_3.c, fft/hc_pass_4.c, fft/hc_pass_5.c, fft/hc_pass_n.c, fft/hc_radix2.c, fft/hc_unpack.c, fft/real_init.c, fft/real_main.c, fft/real_pass.h, fft/real_pass_2.c, fft/real_pass_3.c, fft/real_pass_4.c, fft/real_pass_5.c, fft/real_pass_n.c, fft/real_radix2.c, fft/real_unpack.c, fft/signals.c, fft/signals.h, fft/signals_source.c, fft/test.c, fft/test_complex_source.c, fft/test_real_source.c, fft/test_trap_source.c, fft/urand.c, fit/ChangeLog, fit/Makefile.am, fit/Makefile.in, fit/gsl_fit.h, fit/linear.c, fit/test.c, gsl/Makefile.am, gsl/Makefile.in, histogram/ChangeLog, histogram/Makefile.am, histogram/Makefile.in, histogram/TODO, histogram/add.c, histogram/add2d.c, histogram/calloc_range.c, histogram/calloc_range2d.c, histogram/copy.c, histogram/copy2d.c, histogram/file.c, histogram/file2d.c, histogram/find.c, histogram/find2d.c, histogram/get.c, histogram/get2d.c, histogram/gsl_histogram.h, histogram/gsl_histogram2d.h, histogram/init.c, histogram/init2d.c, histogram/maxval.c, histogram/maxval2d.c, histogram/oper.c, histogram/oper2d.c, histogram/params.c, histogram/params2d.c, histogram/pdf.c, histogram/pdf2d.c, histogram/reset.c, histogram/reset2d.c, histogram/stat.c, histogram/stat2d.c, histogram/test.c, histogram/test1d.c, histogram/test1d_resample.c, histogram/test1d_trap.c, histogram/test2d.c, histogram/test2d_resample.c, histogram/test2d_trap.c, histogram/urand.c, ieee-utils/ChangeLog, ieee-utils/Makefile.am, ieee-utils/Makefile.in, ieee-utils/TODO, ieee-utils/endian.c, ieee-utils/env.c, ieee-utils/fp-aix.c, ieee-utils/fp-darwin.c, ieee-utils/fp-darwin86.c, ieee-utils/fp-freebsd.c, ieee-utils/fp-gnuc99.c, ieee-utils/fp-gnum68k.c, ieee-utils/fp-gnuppc.c, ieee-utils/fp-gnusparc.c, ieee-utils/fp-gnux86.c, ieee-utils/fp-hpux.c, ieee-utils/fp-hpux11.c, ieee-utils/fp-irix.c, ieee-utils/fp-netbsd.c, ieee-utils/fp-openbsd.c, ieee-utils/fp-os2emx.c, ieee-utils/fp-solaris.c, ieee-utils/fp-sunos4.c, ieee-utils/fp-tru64.c, ieee-utils/fp-unknown.c, ieee-utils/fp.c, ieee-utils/gsl_ieee_utils.h, ieee-utils/make_rep.c, ieee-utils/print.c, ieee-utils/read.c, ieee-utils/standardize.c, ieee-utils/test.c, integration/ChangeLog, integration/Makefile.am, integration/Makefile.in, integration/TODO, integration/append.c, integration/err.c, integration/gsl_integration.h, integration/initialise.c, integration/positivity.c, integration/ptsort.c, integration/qag.c, integration/qagp.c, integration/qags.c, integration/qawc.c, integration/qawf.c, integration/qawo.c, integration/qaws.c, integration/qc25c.c, integration/qc25f.c, integration/qc25s.c, integration/qcheb.c, integration/qelg.c, integration/qk.c, integration/qk15.c, integration/qk21.c, integration/qk31.c, integration/qk41.c, integration/qk51.c, integration/qk61.c, integration/qmomo.c, integration/qmomof.c, integration/qng.c, integration/qng.h, integration/qpsrt.c, integration/qpsrt2.c, integration/reset.c, integration/set_initial.c, integration/test.c, integration/tests.c, integration/tests.h, integration/util.c, integration/workspace.c, interpolation/ChangeLog, interpolation/Makefile.am, interpolation/Makefile.in, interpolation/TODO, interpolation/accel.c, interpolation/akima.c, interpolation/bsearch.c, interpolation/bsearch.h, interpolation/cspline.c, interpolation/gsl_interp.h, interpolation/gsl_spline.h, interpolation/integ_eval.h, interpolation/interp.c, interpolation/linear.c, interpolation/poly.c, interpolation/spline.c, interpolation/test.c, linalg/ChangeLog, linalg/Makefile.am, linalg/Makefile.in, linalg/TODO, linalg/apply_givens.c, linalg/balance.c, linalg/balancemat.c, linalg/bidiag.c, linalg/cholesky.c, linalg/exponential.c, linalg/givens.c, linalg/gsl_linalg.h, linalg/hermtd.c, linalg/hessenberg.c, linalg/hh.c, linalg/householder.c, linalg/householdercomplex.c, linalg/lq.c, linalg/lu.c, linalg/luc.c, linalg/multiply.c, linalg/ptlq.c, linalg/qr.c, linalg/qrpt.c, linalg/svd.c, linalg/svdstep.c, linalg/symmtd.c, linalg/test.c, linalg/tridiag.c, linalg/tridiag.h, matrix/ChangeLog, matrix/Makefile.am, matrix/Makefile.in, matrix/TODO, matrix/copy.c, matrix/copy_source.c, matrix/file.c, matrix/file_source.c, matrix/getset.c, matrix/getset_source.c, matrix/gsl_matrix.h, matrix/gsl_matrix_char.h, matrix/gsl_matrix_complex_double.h, matrix/gsl_matrix_complex_float.h, matrix/gsl_matrix_complex_long_double.h, matrix/gsl_matrix_double.h, matrix/gsl_matrix_float.h, matrix/gsl_matrix_int.h, matrix/gsl_matrix_long.h, matrix/gsl_matrix_long_double.h, matrix/gsl_matrix_short.h, matrix/gsl_matrix_uchar.h, matrix/gsl_matrix_uint.h, matrix/gsl_matrix_ulong.h, matrix/gsl_matrix_ushort.h, matrix/init.c, matrix/init_source.c, matrix/matrix.c, matrix/matrix_source.c, matrix/minmax.c, matrix/minmax_source.c, matrix/oper.c, matrix/oper_complex_source.c, matrix/oper_source.c, matrix/prop.c, matrix/prop_source.c, matrix/rowcol.c, matrix/rowcol_source.c, matrix/submatrix.c, matrix/submatrix_source.c, matrix/swap.c, matrix/swap_source.c, matrix/test.c, matrix/test_complex_source.c, matrix/test_source.c, matrix/test_static.c, matrix/view.c, matrix/view.h, matrix/view_source.c, min/ChangeLog, min/Makefile.am, min/Makefile.in, min/bracketing.c, min/brent.c, min/convergence.c, min/fsolver.c, min/golden.c, min/gsl_min.h, min/min.h, min/test.c, min/test.h, min/test_funcs.c, monte/ChangeLog, monte/Makefile.am, monte/Makefile.in, monte/README, monte/TODO, monte/gsl_monte.h, monte/gsl_monte_miser.h, monte/gsl_monte_plain.h, monte/gsl_monte_vegas.h, monte/miser.c, monte/plain.c, monte/test.c, monte/test_main.c, monte/vegas.c, multifit/ChangeLog, multifit/Makefile.am, multifit/Makefile.in, multifit/TODO, multifit/convergence.c, multifit/covar.c, multifit/fdfsolver.c, multifit/fsolver.c, multifit/gradient.c, multifit/gsl_multifit.h, multifit/gsl_multifit_nlin.h, multifit/lmder.c, multifit/lmiterate.c, multifit/lmpar.c, multifit/lmset.c, multifit/lmutil.c, multifit/multilinear.c, multifit/qrsolv.c, multifit/test.c, multifit/test_brown.c, multifit/test_enso.c, multifit/test_estimator.c, multifit/test_filip.c, multifit/test_fn.c, multifit/test_hahn1.c, multifit/test_kirby2.c, multifit/test_longley.c, multifit/test_nelson.c, multifit/test_pontius.c, multifit/work.c, multimin/ChangeLog, multimin/Makefile.am, multimin/Makefile.in, multimin/TODO, multimin/conjugate_fr.c, multimin/conjugate_pr.c, multimin/convergence.c, multimin/diff.c, multimin/directional_minimize.c, multimin/fdfminimizer.c, multimin/fminimizer.c, multimin/gsl_multimin.h, multimin/linear_minimize.c, multimin/linear_wrapper.c, multimin/simplex.c, multimin/steepest_descent.c, multimin/test.c, multimin/test_funcs.c, multimin/test_funcs.h, multimin/vector_bfgs.c, multimin/vector_bfgs2.c, multiroots/ChangeLog, multiroots/Makefile.am, multiroots/Makefile.in, multiroots/broyden.c, multiroots/convergence.c, multiroots/dnewton.c, multiroots/dogleg.c, multiroots/enorm.c, multiroots/fdfsolver.c, multiroots/fdjac.c, multiroots/fsolver.c, multiroots/gnewton.c, multiroots/gsl_multiroots.h, multiroots/hybrid.c, multiroots/hybridj.c, multiroots/newton.c, multiroots/test.c, multiroots/test_funcs.c, multiroots/test_funcs.h, ntuple/ChangeLog, ntuple/Makefile.am, ntuple/Makefile.in, ntuple/gsl_ntuple.h, ntuple/ntuple.c, ntuple/test.c, ode-initval/ChangeLog, ode-initval/Makefile.am, ode-initval/Makefile.in, ode-initval/TODO, ode-initval/bsimp.c, ode-initval/control.c, ode-initval/cscal.c, ode-initval/cstd.c, ode-initval/evolve.c, ode-initval/gear1.c, ode-initval/gear2.c, ode-initval/gsl_odeiv.h, ode-initval/odeiv_util.h, ode-initval/rk2.c, ode-initval/rk2imp.c, ode-initval/rk2simp.c, ode-initval/rk4.c, ode-initval/rk4imp.c, ode-initval/rk8pd.c, ode-initval/rkck.c, ode-initval/rkf45.c, ode-initval/step.c, ode-initval/test.c, permutation/ChangeLog, permutation/Makefile.am, permutation/Makefile.in, permutation/canonical.c, permutation/file.c, permutation/gsl_permutation.h, permutation/gsl_permute.h, permutation/gsl_permute_char.h, permutation/gsl_permute_complex_double.h, permutation/gsl_permute_complex_float.h, permutation/gsl_permute_complex_long_double.h, permutation/gsl_permute_double.h, permutation/gsl_permute_float.h, permutation/gsl_permute_int.h, permutation/gsl_permute_long.h, permutation/gsl_permute_long_double.h, permutation/gsl_permute_short.h, permutation/gsl_permute_uchar.h, permutation/gsl_permute_uint.h, permutation/gsl_permute_ulong.h, permutation/gsl_permute_ushort.h, permutation/gsl_permute_vector.h, permutation/gsl_permute_vector_char.h, permutation/gsl_permute_vector_complex_double.h, permutation/gsl_permute_vector_complex_float.h, permutation/gsl_permute_vector_complex_long_double.h, permutation/gsl_permute_vector_double.h, permutation/gsl_permute_vector_float.h, permutation/gsl_permute_vector_int.h, permutation/gsl_permute_vector_long.h, permutation/gsl_permute_vector_long_double.h, permutation/gsl_permute_vector_short.h, permutation/gsl_permute_vector_uchar.h, permutation/gsl_permute_vector_uint.h, permutation/gsl_permute_vector_ulong.h, permutation/gsl_permute_vector_ushort.h, permutation/init.c, permutation/permutation.c, permutation/permute.c, permutation/permute_source.c, permutation/test.c, poly/ChangeLog, poly/Makefile.am, poly/Makefile.in, poly/TODO, poly/balance.c, poly/companion.c, poly/dd.c, poly/eval.c, poly/gsl_poly.h, poly/qr.c, poly/solve_cubic.c, poly/solve_quadratic.c, poly/test.c, poly/zsolve.c, poly/zsolve_cubic.c, poly/zsolve_init.c, poly/zsolve_quadratic.c, qrng/ChangeLog, qrng/Makefile.am, qrng/Makefile.in, qrng/TODO, qrng/gsl_qrng.h, qrng/niederreiter-2.c, qrng/qrng.c, qrng/sobol.c, qrng/test.c, randist/ChangeLog, randist/Makefile.am, randist/Makefile.in, randist/TODO, randist/bernoulli.c, randist/beta.c, randist/bigauss.c, randist/binomial.c, randist/binomial_tpe.c, randist/cauchy.c, randist/chisq.c, randist/dirichlet.c, randist/discrete.c, randist/erlang.c, randist/exponential.c, randist/exppow.c, randist/fdist.c, randist/flat.c, randist/gamma.c, randist/gauss.c, randist/gausstail.c, randist/gausszig.c, randist/geometric.c, randist/gsl_randist.h, randist/gumbel.c, randist/hyperg.c, randist/landau.c, randist/laplace.c, randist/levy.c, randist/logarithmic.c, randist/logistic.c, randist/lognormal.c, randist/multinomial.c, randist/nbinomial.c, randist/pareto.c, randist/pascal.c, randist/poisson.c, randist/rayleigh.c, randist/shuffle.c, randist/sphere.c, randist/tdist.c, randist/test.c, randist/weibull.c, rng/ChangeLog, rng/Makefile.am, rng/Makefile.in, rng/TODO, rng/borosh13.c, rng/cmrg.c, rng/coveyou.c, rng/default.c, rng/file.c, rng/fishman18.c, rng/fishman20.c, rng/fishman2x.c, rng/gfsr4.c, rng/gsl_rng.h, rng/knuthran.c, rng/knuthran2.c, rng/knuthran2002.c, rng/lecuyer21.c, rng/minstd.c, rng/mrg.c, rng/mt.c, rng/r250.c, rng/ran0.c, rng/ran1.c, rng/ran2.c, rng/ran3.c, rng/rand.c, rng/rand48.c, rng/random.c, rng/randu.c, rng/ranf.c, rng/ranlux.c, rng/ranlxd.c, rng/ranlxs.c, rng/ranmar.c, rng/rng.c, rng/schrage.c, rng/slatec.c, rng/taus.c, rng/taus113.c, rng/test.c, rng/transputer.c, rng/tt.c, rng/types.c, rng/uni.c, rng/uni32.c, rng/vax.c, rng/waterman14.c, rng/zuf.c, roots/ChangeLog, roots/Makefile.am, roots/Makefile.in, roots/TODO, roots/bisection.c, roots/brent.c, roots/convergence.c, roots/falsepos.c, roots/fdfsolver.c, roots/fsolver.c, roots/gsl_roots.h, roots/newton.c, roots/roots.h, roots/secant.c, roots/steffenson.c, roots/test.c, roots/test.h, roots/test_funcs.c, siman/ChangeLog, siman/Makefile.am, siman/Makefile.in, siman/TODO, siman/gsl_siman.h, siman/siman.c, siman/siman_test_driver.sh, siman/siman_tsp.c, siman/test.c, sort/ChangeLog, sort/Makefile.am, sort/Makefile.in, sort/TODO, sort/gsl_heapsort.h, sort/gsl_sort.h, sort/gsl_sort_char.h, sort/gsl_sort_double.h, sort/gsl_sort_float.h, sort/gsl_sort_int.h, sort/gsl_sort_long.h, sort/gsl_sort_long_double.h, sort/gsl_sort_short.h, sort/gsl_sort_uchar.h, sort/gsl_sort_uint.h, sort/gsl_sort_ulong.h, sort/gsl_sort_ushort.h, sort/gsl_sort_vector.h, sort/gsl_sort_vector_char.h, sort/gsl_sort_vector_double.h, sort/gsl_sort_vector_float.h, sort/gsl_sort_vector_int.h, sort/gsl_sort_vector_long.h, sort/gsl_sort_vector_long_double.h, sort/gsl_sort_vector_short.h, sort/gsl_sort_vector_uchar.h, sort/gsl_sort_vector_uint.h, sort/gsl_sort_vector_ulong.h, sort/gsl_sort_vector_ushort.h, sort/sort.c, sort/sortind.c, sort/sortvec.c, sort/sortvec_source.c, sort/sortvecind.c, sort/sortvecind_source.c, sort/subset.c, sort/subset_source.c, sort/subsetind.c, sort/subsetind_source.c, sort/test.c, sort/test_heapsort.c, sort/test_source.c, specfunc/ChangeLog, specfunc/Makefile.am, specfunc/Makefile.in, specfunc/TODO, specfunc/airy.c, specfunc/airy_der.c, specfunc/airy_zero.c, specfunc/atanint.c, specfunc/bessel.c, specfunc/bessel.h, specfunc/bessel_I0.c, specfunc/bessel_I1.c, specfunc/bessel_In.c, specfunc/bessel_Inu.c, specfunc/bessel_J0.c, specfunc/bessel_J1.c, specfunc/bessel_Jn.c, specfunc/bessel_Jnu.c, specfunc/bessel_K0.c, specfunc/bessel_K1.c, specfunc/bessel_Kn.c, specfunc/bessel_Knu.c, specfunc/bessel_Y0.c, specfunc/bessel_Y1.c, specfunc/bessel_Yn.c, specfunc/bessel_Ynu.c, specfunc/bessel_amp_phase.c, specfunc/bessel_amp_phase.h, specfunc/bessel_i.c, specfunc/bessel_j.c, specfunc/bessel_k.c, specfunc/bessel_olver.c, specfunc/bessel_olver.h, specfunc/bessel_sequence.c, specfunc/bessel_temme.c, specfunc/bessel_temme.h, specfunc/bessel_y.c, specfunc/bessel_zero.c, specfunc/beta.c, specfunc/beta_inc.c, specfunc/cheb_eval.c, specfunc/cheb_eval_mode.c, specfunc/chebyshev.h, specfunc/check.h, specfunc/clausen.c, specfunc/coulomb.c, specfunc/coulomb_bound.c, specfunc/coupling.c, specfunc/dawson.c, specfunc/debye.c, specfunc/dilog.c, specfunc/elementary.c, specfunc/ellint.c, specfunc/elljac.c, specfunc/erfc.c, specfunc/error.h, specfunc/eval.h, specfunc/exp.c, specfunc/expint.c, specfunc/expint3.c, specfunc/fermi_dirac.c, specfunc/gamma.c, specfunc/gamma_inc.c, specfunc/gegenbauer.c, specfunc/gsl_sf.h, specfunc/gsl_sf_airy.h, specfunc/gsl_sf_bessel.h, specfunc/gsl_sf_clausen.h, specfunc/gsl_sf_coulomb.h, specfunc/gsl_sf_coupling.h, specfunc/gsl_sf_dawson.h, specfunc/gsl_sf_debye.h, specfunc/gsl_sf_dilog.h, specfunc/gsl_sf_elementary.h, specfunc/gsl_sf_ellint.h, specfunc/gsl_sf_elljac.h, specfunc/gsl_sf_erf.h, specfunc/gsl_sf_exp.h, specfunc/gsl_sf_expint.h, specfunc/gsl_sf_fermi_dirac.h, specfunc/gsl_sf_gamma.h, specfunc/gsl_sf_gegenbauer.h, specfunc/gsl_sf_hyperg.h, specfunc/gsl_sf_laguerre.h, specfunc/gsl_sf_lambert.h, specfunc/gsl_sf_legendre.h, specfunc/gsl_sf_log.h, specfunc/gsl_sf_mathieu.h, specfunc/gsl_sf_pow_int.h, specfunc/gsl_sf_psi.h, specfunc/gsl_sf_result.h, specfunc/gsl_sf_synchrotron.h, specfunc/gsl_sf_transport.h, specfunc/gsl_sf_trig.h, specfunc/gsl_sf_zeta.h, specfunc/gsl_specfunc.h, specfunc/hyperg.c, specfunc/hyperg.h, specfunc/hyperg_0F1.c, specfunc/hyperg_1F1.c, specfunc/hyperg_2F0.c, specfunc/hyperg_2F1.c, specfunc/hyperg_U.c, specfunc/laguerre.c, specfunc/lambert.c, specfunc/legendre.h, specfunc/legendre_H3d.c, specfunc/legendre_Qn.c, specfunc/legendre_con.c, specfunc/legendre_poly.c, specfunc/log.c, specfunc/mathieu_angfunc.c, specfunc/mathieu_charv.c, specfunc/mathieu_coeff.c, specfunc/mathieu_radfunc.c, specfunc/mathieu_workspace.c, specfunc/poch.c, specfunc/pow_int.c, specfunc/psi.c, specfunc/recurse.h, specfunc/result.c, specfunc/shint.c, specfunc/sinint.c, specfunc/synchrotron.c, specfunc/test_airy.c, specfunc/test_bessel.c, specfunc/test_coulomb.c, specfunc/test_dilog.c, specfunc/test_gamma.c, specfunc/test_hyperg.c, specfunc/test_legendre.c, specfunc/test_mathieu.c, specfunc/test_sf.c, specfunc/test_sf.h, specfunc/transport.c, specfunc/trig.c, specfunc/zeta.c, statistics/ChangeLog, statistics/Makefile.am, statistics/Makefile.in, statistics/TODO, statistics/absdev.c, statistics/absdev_source.c, statistics/covariance.c, statistics/covariance_source.c, statistics/gsl_statistics.h, statistics/gsl_statistics_char.h, statistics/gsl_statistics_double.h, statistics/gsl_statistics_float.h, statistics/gsl_statistics_int.h, statistics/gsl_statistics_long.h, statistics/gsl_statistics_long_double.h, statistics/gsl_statistics_short.h, statistics/gsl_statistics_uchar.h, statistics/gsl_statistics_uint.h, statistics/gsl_statistics_ulong.h, statistics/gsl_statistics_ushort.h, statistics/kurtosis.c, statistics/kurtosis_source.c, statistics/lag1.c, statistics/lag1_source.c, statistics/mean.c, statistics/mean_source.c, statistics/median.c, statistics/median_source.c, statistics/minmax.c, statistics/minmax_source.c, statistics/p_variance.c, statistics/p_variance_source.c, statistics/quantiles.c, statistics/quantiles_source.c, statistics/skew.c, statistics/skew_source.c, statistics/test.c, statistics/test_float_source.c, statistics/test_int_source.c, statistics/test_nist.c, statistics/ttest.c, statistics/ttest_source.c, statistics/variance.c, statistics/variance_source.c, statistics/wabsdev.c, statistics/wabsdev_source.c, statistics/wkurtosis.c, statistics/wkurtosis_source.c, statistics/wmean.c, statistics/wmean_source.c, statistics/wskew.c, statistics/wskew_source.c, statistics/wvariance.c, statistics/wvariance_source.c, sum/ChangeLog, sum/Makefile.am, sum/Makefile.in, sum/gsl_sum.h, sum/levin_u.c, sum/levin_utrunc.c, sum/test.c, sum/work_u.c, sum/work_utrunc.c, sys/ChangeLog, sys/Makefile.am, sys/Makefile.in, sys/coerce.c, sys/expm1.c, sys/fcmp.c, sys/fdiv.c, sys/gsl_sys.h, sys/hypot.c, sys/infnan.c, sys/invhyp.c, sys/ldfrexp.c, sys/log1p.c, sys/minmax.c, sys/pow_int.c, sys/prec.c, sys/test.c, test/ChangeLog, test/Makefile.am, test/Makefile.in, test/gsl_test.h, test/results.c, utils/Makefile.am, utils/Makefile.in, utils/README, utils/memcpy.c, utils/memmove.c, utils/placeholder.c, utils/strdup.c, utils/strtol.c, utils/strtoul.c, utils/system.h, vector/ChangeLog, vector/Makefile.am, vector/Makefile.in, vector/TODO, vector/copy.c, vector/copy_source.c, vector/file.c, vector/file_source.c, vector/gsl_vector.h, vector/gsl_vector_char.h, vector/gsl_vector_complex.h, vector/gsl_vector_complex_double.h, vector/gsl_vector_complex_float.h, vector/gsl_vector_complex_long_double.h, vector/gsl_vector_double.h, vector/gsl_vector_float.h, vector/gsl_vector_int.h, vector/gsl_vector_long.h, vector/gsl_vector_long_double.h, vector/gsl_vector_short.h, vector/gsl_vector_uchar.h, vector/gsl_vector_uint.h, vector/gsl_vector_ulong.h, vector/gsl_vector_ushort.h, vector/init.c, vector/init_source.c, vector/minmax.c, vector/minmax_source.c, vector/oper.c, vector/oper_source.c, vector/prop.c, vector/prop_source.c, vector/reim.c, vector/reim_source.c, vector/subvector.c, vector/subvector_source.c, vector/swap.c, vector/swap_source.c, vector/test.c, vector/test_complex_source.c, vector/test_source.c, vector/test_static.c, vector/vector.c, vector/vector_source.c, vector/view.c, vector/view.h, vector/view_source.c, wavelet/ChangeLog, wavelet/Makefile.am, wavelet/Makefile.in, wavelet/TODO, wavelet/bspline.c, wavelet/daubechies.c, wavelet/dwt.c, wavelet/gsl_wavelet.h, wavelet/gsl_wavelet2d.h, wavelet/haar.c, wavelet/test.c, wavelet/wavelet.c: New files.
Diffstat (limited to 'gsl-1.9/cdf')
-rw-r--r--gsl-1.9/cdf/ChangeLog87
-rw-r--r--gsl-1.9/cdf/Makefile.am17
-rw-r--r--gsl-1.9/cdf/Makefile.in554
-rw-r--r--gsl-1.9/cdf/beta.c66
-rw-r--r--gsl-1.9/cdf/beta_inc.c177
-rw-r--r--gsl-1.9/cdf/betainv.c195
-rw-r--r--gsl-1.9/cdf/binomial.c108
-rw-r--r--gsl-1.9/cdf/cauchy.c59
-rw-r--r--gsl-1.9/cdf/cauchyinv.c75
-rw-r--r--gsl-1.9/cdf/chisq.c34
-rw-r--r--gsl-1.9/cdf/chisqinv.c34
-rw-r--r--gsl-1.9/cdf/error.h4
-rw-r--r--gsl-1.9/cdf/exponential.c59
-rw-r--r--gsl-1.9/cdf/exponentialinv.c39
-rw-r--r--gsl-1.9/cdf/exppow.c70
-rw-r--r--gsl-1.9/cdf/fdist.c81
-rw-r--r--gsl-1.9/cdf/fdistinv.c104
-rw-r--r--gsl-1.9/cdf/flat.c65
-rw-r--r--gsl-1.9/cdf/flatinv.c59
-rw-r--r--gsl-1.9/cdf/gamma.c74
-rw-r--r--gsl-1.9/cdf/gammainv.c185
-rw-r--r--gsl-1.9/cdf/gauss.c351
-rw-r--r--gsl-1.9/cdf/gaussinv.c202
-rw-r--r--gsl-1.9/cdf/geometric.c89
-rw-r--r--gsl-1.9/cdf/gsl_cdf.h170
-rw-r--r--gsl-1.9/cdf/gumbel1.c49
-rw-r--r--gsl-1.9/cdf/gumbel1inv.c61
-rw-r--r--gsl-1.9/cdf/gumbel2.c59
-rw-r--r--gsl-1.9/cdf/gumbel2inv.c61
-rw-r--r--gsl-1.9/cdf/hypergeometric.c183
-rw-r--r--gsl-1.9/cdf/laplace.c59
-rw-r--r--gsl-1.9/cdf/laplaceinv.c75
-rw-r--r--gsl-1.9/cdf/logistic.c59
-rw-r--r--gsl-1.9/cdf/logisticinv.c61
-rw-r--r--gsl-1.9/cdf/lognormal.c39
-rw-r--r--gsl-1.9/cdf/lognormalinv.c65
-rw-r--r--gsl-1.9/cdf/nbinomial.c83
-rw-r--r--gsl-1.9/cdf/pareto.c57
-rw-r--r--gsl-1.9/cdf/paretoinv.c61
-rw-r--r--gsl-1.9/cdf/pascal.c40
-rw-r--r--gsl-1.9/cdf/poisson.c84
-rw-r--r--gsl-1.9/cdf/rat_eval.h25
-rw-r--r--gsl-1.9/cdf/rayleigh.c39
-rw-r--r--gsl-1.9/cdf/rayleighinv.c61
-rw-r--r--gsl-1.9/cdf/tdist.c271
-rw-r--r--gsl-1.9/cdf/tdistinv.c232
-rw-r--r--gsl-1.9/cdf/test.c1327
-rw-r--r--gsl-1.9/cdf/test_auto.c1464
-rw-r--r--gsl-1.9/cdf/weibull.c37
-rw-r--r--gsl-1.9/cdf/weibullinv.c61
50 files changed, 7571 insertions, 0 deletions
diff --git a/gsl-1.9/cdf/ChangeLog b/gsl-1.9/cdf/ChangeLog
new file mode 100644
index 0000000..6b4dc47
--- /dev/null
+++ b/gsl-1.9/cdf/ChangeLog
@@ -0,0 +1,87 @@
+2007-01-23 Brian Gough <bjg@network-theory.co.uk>
+
+ * betainv.c (gsl_cdf_beta_Pinv): avoid generating a NaN for lx > 0
+
+2006-04-18 Brian Gough <bjg@network-theory.co.uk>
+
+ * betainv.c (gsl_cdf_beta_Qinv): fix prototype const
+
+2006-03-07 Brian Gough <bjg@network-theory.co.uk>
+
+ * poisson.c: added poisson cdf
+
+ * nbinomial.c: added negative binomial cdf
+
+ * hypergeometric.c: added hypergeometric cdf
+
+ * geometric.c: added geometric cdf
+
+ * binomial.c (gsl_cdf_binomial_Q): added binomial cdf
+
+ * test.c: added discrete function tests
+
+ * gamma.c (gsl_cdf_gamma_P, gsl_cdf_gamma_Q): clean up unused
+ code, ensure that branches make P+Q=1 always true
+
+ * fdistinv.c (gsl_cdf_fdist_Pinv): use P instead of p for consistency
+
+ * fdist.c (gsl_cdf_fdist_Q): use Q instead of P for consistency
+
+ * beta.c (gsl_cdf_beta_Q): use Q instead of P for consistency
+
+2006-02-27 Brian Gough <bjg@network-theory.co.uk>
+
+ * fdistinv.c (gsl_cdf_fdist_Pinv, gsl_cdf_fdist_Qinv): added
+ inverse functions
+
+ * betainv.c (gsl_cdf_beta_Pinv, gsl_cdf_beta_Qinv): added inverse
+ functions
+
+ * tdistinv.c (gsl_cdf_tdist_Qinv, gsl_cdf_tdist_Pinv): max 32
+ iterations, prevent infinite loop
+
+ * gammainv.c (gsl_cdf_gamma_Qinv, gsl_cdf_gamma_Pinv): max 32
+ iterations, prevent infinite loop
+
+2005-06-20 Brian Gough <bjg@network-theory.co.uk>
+
+ * test.c: removed tests using subnormal values, since they tend to
+ fail when extended precision registers are not available.
+
+2004-10-26 Brian Gough <bjg@network-theory.co.uk>
+
+ * exppow.c: added exppow distribution
+
+2004-10-01 Brian Gough <bjg@network-theory.co.uk>
+
+ * beta.c (gsl_cdf_beta_P, gsl_cdf_beta_P): return consistent
+ results for out of range values.
+
+2003-08-27 Brian Gough <bjg@network-theory.co.uk>
+
+ * gauss.c: use parentheses around constant macros to avoid -(-X)
+ being interpreted as --X
+
+2003-07-27 Brian Gough <bjg@network-theory.co.uk>
+
+ * gumbel1.c (gsl_cdf_gumbel1_Q): use pow in place of exp since
+ compilers seem to handle overflow better in this case (perhaps
+ because it is not an intrinsic function).
+
+ * gumbel2.c (gsl_cdf_gumbel2_P): handle case of x = 0 explicitly
+ (gsl_cdf_gumbel2_Q): handle case of x = 0 explicitly
+
+2003-07-22 Brian Gough <bjg@network-theory.co.uk>
+
+ * gamma.c (gsl_cdf_gamma_P): Peizer and Pratt approximation for
+ large a seems to be inaccurate in tails
+ (gsl_cdf_gamma_Q): Peizer and Pratt approximation for large a
+ seems to be inaccurate in tails
+
+ * test.c (main): added test for large a for gamma
+
+ * cauchyinv.c (gsl_cdf_cauchy_Qinv): corrected limiting value for
+ Q=1
+
+ * added Cumulative Distribution functions from savannah.gnu.org
+
diff --git a/gsl-1.9/cdf/Makefile.am b/gsl-1.9/cdf/Makefile.am
new file mode 100644
index 0000000..5e389d3
--- /dev/null
+++ b/gsl-1.9/cdf/Makefile.am
@@ -0,0 +1,17 @@
+## Process this file with automake to produce Makefile.in
+noinst_LTLIBRARIES = libgslcdf.la
+
+pkginclude_HEADERS= gsl_cdf.h
+
+INCLUDES= -I$(top_builddir)
+
+libgslcdf_la_SOURCES = beta.c betainv.c cauchy.c cauchyinv.c chisq.c chisqinv.c exponential.c exponentialinv.c exppow.c fdist.c fdistinv.c flat.c flatinv.c gamma.c gammainv.c gauss.c gaussinv.c gumbel1.c gumbel1inv.c gumbel2.c gumbel2inv.c laplace.c laplaceinv.c logistic.c logisticinv.c lognormal.c lognormalinv.c pareto.c paretoinv.c rayleigh.c rayleighinv.c tdist.c tdistinv.c weibull.c weibullinv.c binomial.c poisson.c geometric.c nbinomial.c pascal.c hypergeometric.c
+
+noinst_HEADERS = beta_inc.c rat_eval.h test_auto.c error.h
+
+TESTS = $(check_PROGRAMS)
+
+check_PROGRAMS = test
+
+test_SOURCES = test.c
+test_LDADD = libgslcdf.la ../randist/libgslrandist.la ../rng/libgslrng.la ../specfunc/libgslspecfunc.la ../complex/libgslcomplex.la ../ieee-utils/libgslieeeutils.la ../err/libgslerr.la ../test/libgsltest.la ../sys/libgslsys.la ../utils/libutils.la
diff --git a/gsl-1.9/cdf/Makefile.in b/gsl-1.9/cdf/Makefile.in
new file mode 100644
index 0000000..b7cdb79
--- /dev/null
+++ b/gsl-1.9/cdf/Makefile.in
@@ -0,0 +1,554 @@
+# Makefile.in generated by automake 1.9.6 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005 Free Software Foundation, Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+
+srcdir = @srcdir@
+top_srcdir = @top_srcdir@
+VPATH = @srcdir@
+pkgdatadir = $(datadir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+top_builddir = ..
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+INSTALL = @INSTALL@
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+check_PROGRAMS = test$(EXEEXT)
+subdir = cdf
+DIST_COMMON = $(noinst_HEADERS) $(pkginclude_HEADERS) \
+ $(srcdir)/Makefile.am $(srcdir)/Makefile.in ChangeLog
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
+CONFIG_HEADER = $(top_builddir)/config.h
+CONFIG_CLEAN_FILES =
+LTLIBRARIES = $(noinst_LTLIBRARIES)
+libgslcdf_la_LIBADD =
+am_libgslcdf_la_OBJECTS = beta.lo betainv.lo cauchy.lo cauchyinv.lo \
+ chisq.lo chisqinv.lo exponential.lo exponentialinv.lo \
+ exppow.lo fdist.lo fdistinv.lo flat.lo flatinv.lo gamma.lo \
+ gammainv.lo gauss.lo gaussinv.lo gumbel1.lo gumbel1inv.lo \
+ gumbel2.lo gumbel2inv.lo laplace.lo laplaceinv.lo logistic.lo \
+ logisticinv.lo lognormal.lo lognormalinv.lo pareto.lo \
+ paretoinv.lo rayleigh.lo rayleighinv.lo tdist.lo tdistinv.lo \
+ weibull.lo weibullinv.lo binomial.lo poisson.lo geometric.lo \
+ nbinomial.lo pascal.lo hypergeometric.lo
+libgslcdf_la_OBJECTS = $(am_libgslcdf_la_OBJECTS)
+am_test_OBJECTS = test.$(OBJEXT)
+test_OBJECTS = $(am_test_OBJECTS)
+test_DEPENDENCIES = libgslcdf.la ../randist/libgslrandist.la \
+ ../rng/libgslrng.la ../specfunc/libgslspecfunc.la \
+ ../complex/libgslcomplex.la ../ieee-utils/libgslieeeutils.la \
+ ../err/libgslerr.la ../test/libgsltest.la ../sys/libgslsys.la \
+ ../utils/libutils.la
+DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)
+depcomp =
+am__depfiles_maybe =
+COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
+ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) \
+ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+ $(AM_CFLAGS) $(CFLAGS)
+CCLD = $(CC)
+LINK = $(LIBTOOL) --tag=CC --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
+SOURCES = $(libgslcdf_la_SOURCES) $(test_SOURCES)
+DIST_SOURCES = $(libgslcdf_la_SOURCES) $(test_SOURCES)
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+ *) f=$$p;; \
+ esac;
+am__strip_dir = `echo $$p | sed -e 's|^.*/||'`;
+am__installdirs = "$(DESTDIR)$(pkgincludedir)"
+pkgincludeHEADERS_INSTALL = $(INSTALL_HEADER)
+HEADERS = $(noinst_HEADERS) $(pkginclude_HEADERS)
+ETAGS = etags
+CTAGS = ctags
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+ECHO = @ECHO@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+GSL_CFLAGS = @GSL_CFLAGS@
+GSL_LIBS = @GSL_LIBS@
+GSL_LT_CBLAS_VERSION = @GSL_LT_CBLAS_VERSION@
+GSL_LT_VERSION = @GSL_LT_VERSION@
+HAVE_AIX_IEEE_INTERFACE = @HAVE_AIX_IEEE_INTERFACE@
+HAVE_DARWIN86_IEEE_INTERFACE = @HAVE_DARWIN86_IEEE_INTERFACE@
+HAVE_DARWIN_IEEE_INTERFACE = @HAVE_DARWIN_IEEE_INTERFACE@
+HAVE_EXTENDED_PRECISION_REGISTERS = @HAVE_EXTENDED_PRECISION_REGISTERS@
+HAVE_FREEBSD_IEEE_INTERFACE = @HAVE_FREEBSD_IEEE_INTERFACE@
+HAVE_GNUM68K_IEEE_INTERFACE = @HAVE_GNUM68K_IEEE_INTERFACE@
+HAVE_GNUPPC_IEEE_INTERFACE = @HAVE_GNUPPC_IEEE_INTERFACE@
+HAVE_GNUSPARC_IEEE_INTERFACE = @HAVE_GNUSPARC_IEEE_INTERFACE@
+HAVE_GNUX86_IEEE_INTERFACE = @HAVE_GNUX86_IEEE_INTERFACE@
+HAVE_HPUX11_IEEE_INTERFACE = @HAVE_HPUX11_IEEE_INTERFACE@
+HAVE_HPUX_IEEE_INTERFACE = @HAVE_HPUX_IEEE_INTERFACE@
+HAVE_IEEE_COMPARISONS = @HAVE_IEEE_COMPARISONS@
+HAVE_IEEE_DENORMALS = @HAVE_IEEE_DENORMALS@
+HAVE_INLINE = @HAVE_INLINE@
+HAVE_IRIX_IEEE_INTERFACE = @HAVE_IRIX_IEEE_INTERFACE@
+HAVE_NETBSD_IEEE_INTERFACE = @HAVE_NETBSD_IEEE_INTERFACE@
+HAVE_OPENBSD_IEEE_INTERFACE = @HAVE_OPENBSD_IEEE_INTERFACE@
+HAVE_OS2EMX_IEEE_INTERFACE = @HAVE_OS2EMX_IEEE_INTERFACE@
+HAVE_PRINTF_LONGDOUBLE = @HAVE_PRINTF_LONGDOUBLE@
+HAVE_SOLARIS_IEEE_INTERFACE = @HAVE_SOLARIS_IEEE_INTERFACE@
+HAVE_SUNOS4_IEEE_INTERFACE = @HAVE_SUNOS4_IEEE_INTERFACE@
+HAVE_TRU64_IEEE_INTERFACE = @HAVE_TRU64_IEEE_INTERFACE@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LDFLAGS = @LDFLAGS@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+MAINT = @MAINT@
+MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@
+MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@
+MAKEINFO = @MAKEINFO@
+OBJEXT = @OBJEXT@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+RANLIB = @RANLIB@
+RELEASED = @RELEASED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+VERSION = @VERSION@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_RANLIB = @ac_ct_RANLIB@
+ac_ct_STRIP = @ac_ct_STRIP@
+am__leading_dot = @am__leading_dot@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+datadir = @datadir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+noinst_LTLIBRARIES = libgslcdf.la
+pkginclude_HEADERS = gsl_cdf.h
+INCLUDES = -I$(top_builddir)
+libgslcdf_la_SOURCES = beta.c betainv.c cauchy.c cauchyinv.c chisq.c chisqinv.c exponential.c exponentialinv.c exppow.c fdist.c fdistinv.c flat.c flatinv.c gamma.c gammainv.c gauss.c gaussinv.c gumbel1.c gumbel1inv.c gumbel2.c gumbel2inv.c laplace.c laplaceinv.c logistic.c logisticinv.c lognormal.c lognormalinv.c pareto.c paretoinv.c rayleigh.c rayleighinv.c tdist.c tdistinv.c weibull.c weibullinv.c binomial.c poisson.c geometric.c nbinomial.c pascal.c hypergeometric.c
+noinst_HEADERS = beta_inc.c rat_eval.h test_auto.c error.h
+TESTS = $(check_PROGRAMS)
+test_SOURCES = test.c
+test_LDADD = libgslcdf.la ../randist/libgslrandist.la ../rng/libgslrng.la ../specfunc/libgslspecfunc.la ../complex/libgslcomplex.la ../ieee-utils/libgslieeeutils.la ../err/libgslerr.la ../test/libgsltest.la ../sys/libgslsys.la ../utils/libutils.la
+all: all-am
+
+.SUFFIXES:
+.SUFFIXES: .c .lo .o .obj
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
+ && exit 0; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu --ignore-deps cdf/Makefile'; \
+ cd $(top_srcdir) && \
+ $(AUTOMAKE) --gnu --ignore-deps cdf/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+clean-noinstLTLIBRARIES:
+ -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
+ @list='$(noinst_LTLIBRARIES)'; for p in $$list; do \
+ dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
+ test "$$dir" != "$$p" || dir=.; \
+ echo "rm -f \"$${dir}/so_locations\""; \
+ rm -f "$${dir}/so_locations"; \
+ done
+libgslcdf.la: $(libgslcdf_la_OBJECTS) $(libgslcdf_la_DEPENDENCIES)
+ $(LINK) $(libgslcdf_la_LDFLAGS) $(libgslcdf_la_OBJECTS) $(libgslcdf_la_LIBADD) $(LIBS)
+
+clean-checkPROGRAMS:
+ @list='$(check_PROGRAMS)'; for p in $$list; do \
+ f=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
+ echo " rm -f $$p $$f"; \
+ rm -f $$p $$f ; \
+ done
+test$(EXEEXT): $(test_OBJECTS) $(test_DEPENDENCIES)
+ @rm -f test$(EXEEXT)
+ $(LINK) $(test_LDFLAGS) $(test_OBJECTS) $(test_LDADD) $(LIBS)
+
+mostlyclean-compile:
+ -rm -f *.$(OBJEXT)
+
+distclean-compile:
+ -rm -f *.tab.c
+
+.c.o:
+ $(COMPILE) -c $<
+
+.c.obj:
+ $(COMPILE) -c `$(CYGPATH_W) '$<'`
+
+.c.lo:
+ $(LTCOMPILE) -c -o $@ $<
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+distclean-libtool:
+ -rm -f libtool
+uninstall-info-am:
+install-pkgincludeHEADERS: $(pkginclude_HEADERS)
+ @$(NORMAL_INSTALL)
+ test -z "$(pkgincludedir)" || $(mkdir_p) "$(DESTDIR)$(pkgincludedir)"
+ @list='$(pkginclude_HEADERS)'; for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ f=$(am__strip_dir) \
+ echo " $(pkgincludeHEADERS_INSTALL) '$$d$$p' '$(DESTDIR)$(pkgincludedir)/$$f'"; \
+ $(pkgincludeHEADERS_INSTALL) "$$d$$p" "$(DESTDIR)$(pkgincludedir)/$$f"; \
+ done
+
+uninstall-pkgincludeHEADERS:
+ @$(NORMAL_UNINSTALL)
+ @list='$(pkginclude_HEADERS)'; for p in $$list; do \
+ f=$(am__strip_dir) \
+ echo " rm -f '$(DESTDIR)$(pkgincludedir)/$$f'"; \
+ rm -f "$(DESTDIR)$(pkgincludedir)/$$f"; \
+ done
+
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ mkid -fID $$unique
+tags: TAGS
+
+TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$tags $$unique; \
+ fi
+ctags: CTAGS
+CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ test -z "$(CTAGS_ARGS)$$tags$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$tags $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && cd $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) $$here
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+
+check-TESTS: $(TESTS)
+ @failed=0; all=0; xfail=0; xpass=0; skip=0; \
+ srcdir=$(srcdir); export srcdir; \
+ list='$(TESTS)'; \
+ if test -n "$$list"; then \
+ for tst in $$list; do \
+ if test -f ./$$tst; then dir=./; \
+ elif test -f $$tst; then dir=; \
+ else dir="$(srcdir)/"; fi; \
+ if $(TESTS_ENVIRONMENT) $${dir}$$tst; then \
+ all=`expr $$all + 1`; \
+ case " $(XFAIL_TESTS) " in \
+ *" $$tst "*) \
+ xpass=`expr $$xpass + 1`; \
+ failed=`expr $$failed + 1`; \
+ echo "XPASS: $$tst"; \
+ ;; \
+ *) \
+ echo "PASS: $$tst"; \
+ ;; \
+ esac; \
+ elif test $$? -ne 77; then \
+ all=`expr $$all + 1`; \
+ case " $(XFAIL_TESTS) " in \
+ *" $$tst "*) \
+ xfail=`expr $$xfail + 1`; \
+ echo "XFAIL: $$tst"; \
+ ;; \
+ *) \
+ failed=`expr $$failed + 1`; \
+ echo "FAIL: $$tst"; \
+ ;; \
+ esac; \
+ else \
+ skip=`expr $$skip + 1`; \
+ echo "SKIP: $$tst"; \
+ fi; \
+ done; \
+ if test "$$failed" -eq 0; then \
+ if test "$$xfail" -eq 0; then \
+ banner="All $$all tests passed"; \
+ else \
+ banner="All $$all tests behaved as expected ($$xfail expected failures)"; \
+ fi; \
+ else \
+ if test "$$xpass" -eq 0; then \
+ banner="$$failed of $$all tests failed"; \
+ else \
+ banner="$$failed of $$all tests did not behave as expected ($$xpass unexpected passes)"; \
+ fi; \
+ fi; \
+ dashes="$$banner"; \
+ skipped=""; \
+ if test "$$skip" -ne 0; then \
+ skipped="($$skip tests were not run)"; \
+ test `echo "$$skipped" | wc -c` -le `echo "$$banner" | wc -c` || \
+ dashes="$$skipped"; \
+ fi; \
+ report=""; \
+ if test "$$failed" -ne 0 && test -n "$(PACKAGE_BUGREPORT)"; then \
+ report="Please report to $(PACKAGE_BUGREPORT)"; \
+ test `echo "$$report" | wc -c` -le `echo "$$banner" | wc -c` || \
+ dashes="$$report"; \
+ fi; \
+ dashes=`echo "$$dashes" | sed s/./=/g`; \
+ echo "$$dashes"; \
+ echo "$$banner"; \
+ test -z "$$skipped" || echo "$$skipped"; \
+ test -z "$$report" || echo "$$report"; \
+ echo "$$dashes"; \
+ test "$$failed" -eq 0; \
+ else :; fi
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
+ list='$(DISTFILES)'; for file in $$list; do \
+ case $$file in \
+ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
+ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
+ esac; \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test "$$dir" != "$$file" && test "$$dir" != "."; then \
+ dir="/$$dir"; \
+ $(mkdir_p) "$(distdir)$$dir"; \
+ else \
+ dir=''; \
+ fi; \
+ if test -d $$d/$$file; then \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+ fi; \
+ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+ else \
+ test -f $(distdir)/$$file \
+ || cp -p $$d/$$file $(distdir)/$$file \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+ $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS)
+ $(MAKE) $(AM_MAKEFLAGS) check-TESTS
+check: check-am
+all-am: Makefile $(LTLIBRARIES) $(HEADERS)
+installdirs:
+ for dir in "$(DESTDIR)$(pkgincludedir)"; do \
+ test -z "$$dir" || $(mkdir_p) "$$dir"; \
+ done
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-checkPROGRAMS clean-generic clean-libtool \
+ clean-noinstLTLIBRARIES mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-compile distclean-generic \
+ distclean-libtool distclean-tags
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+info: info-am
+
+info-am:
+
+install-data-am: install-pkgincludeHEADERS
+
+install-exec-am:
+
+install-info: install-info-am
+
+install-man:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-compile mostlyclean-generic \
+ mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am: uninstall-info-am uninstall-pkgincludeHEADERS
+
+.PHONY: CTAGS GTAGS all all-am check check-TESTS check-am clean \
+ clean-checkPROGRAMS clean-generic clean-libtool \
+ clean-noinstLTLIBRARIES ctags distclean distclean-compile \
+ distclean-generic distclean-libtool distclean-tags distdir dvi \
+ dvi-am html html-am info info-am install install-am \
+ install-data install-data-am install-exec install-exec-am \
+ install-info install-info-am install-man \
+ install-pkgincludeHEADERS install-strip installcheck \
+ installcheck-am installdirs maintainer-clean \
+ maintainer-clean-generic mostlyclean mostlyclean-compile \
+ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+ tags uninstall uninstall-am uninstall-info-am \
+ uninstall-pkgincludeHEADERS
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/gsl-1.9/cdf/beta.c b/gsl-1.9/cdf/beta.c
new file mode 100644
index 0000000..524391d
--- /dev/null
+++ b/gsl-1.9/cdf/beta.c
@@ -0,0 +1,66 @@
+/* cdf/cdf_beta.c
+ *
+ * Copyright (C) 2003 Brian Gough.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_sf_gamma.h>
+#include <gsl/gsl_math.h>
+
+#include "beta_inc.c"
+
+double
+gsl_cdf_beta_P (const double x, const double a, const double b)
+{
+ double P;
+
+ if (x <= 0.0 )
+ {
+ return 0.0;
+ }
+
+ if ( x >= 1.0 )
+ {
+ return 1.0;
+ }
+
+ P = beta_inc_AXPY (1.0, 0.0, a, b, x);
+
+ return P;
+}
+
+double
+gsl_cdf_beta_Q (const double x, const double a, const double b)
+{
+ double Q;
+
+ if ( x >= 1.0)
+ {
+ return 0.0;
+ }
+
+ if ( x <= 0.0 )
+ {
+ return 1.0;
+ }
+
+ Q = beta_inc_AXPY (-1.0, 1.0, a, b, x);
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/beta_inc.c b/gsl-1.9/cdf/beta_inc.c
new file mode 100644
index 0000000..8a0165a
--- /dev/null
+++ b/gsl-1.9/cdf/beta_inc.c
@@ -0,0 +1,177 @@
+/* specfunc/beta_inc.c
+ *
+ * Copyright (C) 1996, 1997, 1998, 1999, 2000 Gerard Jungman
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+/* Author: G. Jungman */
+/* Modified for cdfs by Brian Gough, June 2003 */
+
+static double
+beta_cont_frac (const double a, const double b, const double x,
+ const double epsabs)
+{
+ const unsigned int max_iter = 512; /* control iterations */
+ const double cutoff = 2.0 * GSL_DBL_MIN; /* control the zero cutoff */
+ unsigned int iter_count = 0;
+ double cf;
+
+ /* standard initialization for continued fraction */
+ double num_term = 1.0;
+ double den_term = 1.0 - (a + b) * x / (a + 1.0);
+
+ if (fabs (den_term) < cutoff)
+ den_term = GSL_NAN;
+
+ den_term = 1.0 / den_term;
+ cf = den_term;
+
+ while (iter_count < max_iter)
+ {
+ const int k = iter_count + 1;
+ double coeff = k * (b - k) * x / (((a - 1.0) + 2 * k) * (a + 2 * k));
+ double delta_frac;
+
+ /* first step */
+ den_term = 1.0 + coeff * den_term;
+ num_term = 1.0 + coeff / num_term;
+
+ if (fabs (den_term) < cutoff)
+ den_term = GSL_NAN;
+
+ if (fabs (num_term) < cutoff)
+ num_term = GSL_NAN;
+
+ den_term = 1.0 / den_term;
+
+ delta_frac = den_term * num_term;
+ cf *= delta_frac;
+
+ coeff = -(a + k) * (a + b + k) * x / ((a + 2 * k) * (a + 2 * k + 1.0));
+
+ /* second step */
+ den_term = 1.0 + coeff * den_term;
+ num_term = 1.0 + coeff / num_term;
+
+ if (fabs (den_term) < cutoff)
+ den_term = GSL_NAN;
+
+ if (fabs (num_term) < cutoff)
+ num_term = GSL_NAN;
+
+ den_term = 1.0 / den_term;
+
+ delta_frac = den_term * num_term;
+ cf *= delta_frac;
+
+ if (fabs (delta_frac - 1.0) < 2.0 * GSL_DBL_EPSILON)
+ break;
+
+ if (cf * fabs (delta_frac - 1.0) < epsabs)
+ break;
+
+ ++iter_count;
+ }
+
+ if (iter_count >= max_iter)
+ return GSL_NAN;
+
+ return cf;
+}
+
+/* The function beta_inc_AXPY(A,Y,a,b,x) computes A * beta_inc(a,b,x)
+ + Y taking account of possible cancellations when using the
+ hypergeometric transformation beta_inc(a,b,x)=1-beta_inc(b,a,1-x).
+
+ It also adjusts the accuracy of beta_inc() to fit the overall
+ absolute error when A*beta_inc is added to Y. (e.g. if Y >>
+ A*beta_inc then the accuracy of beta_inc can be reduced) */
+
+static double
+beta_inc_AXPY (const double A, const double Y,
+ const double a, const double b, const double x)
+{
+ if (x == 0.0)
+ {
+ return A * 0 + Y;
+ }
+ else if (x == 1.0)
+ {
+ return A * 1 + Y;
+ }
+ else
+ {
+ double ln_beta = gsl_sf_lnbeta (a, b);
+ double ln_pre = -ln_beta + a * log (x) + b * log1p (-x);
+
+ double prefactor = exp (ln_pre);
+
+ if (x < (a + 1.0) / (a + b + 2.0))
+ {
+ /* Apply continued fraction directly. */
+ double epsabs = fabs (Y / (A * prefactor / a)) * GSL_DBL_EPSILON;
+
+ double cf = beta_cont_frac (a, b, x, epsabs);
+
+ return A * (prefactor * cf / a) + Y;
+ }
+ else
+ {
+ /* Apply continued fraction after hypergeometric transformation. */
+ double epsabs =
+ fabs ((A + Y) / (A * prefactor / b)) * GSL_DBL_EPSILON;
+ double cf = beta_cont_frac (b, a, 1.0 - x, epsabs);
+ double term = prefactor * cf / b;
+
+ if (A == -Y)
+ {
+ return -A * term;
+ }
+ else
+ {
+ return A * (1 - term) + Y;
+ }
+ }
+ }
+}
+
+/* Direct series evaluation for testing purposes only */
+
+#if 0
+static double
+beta_series (const double a, const double b, const double x,
+ const double epsabs)
+{
+ double f = x / (1 - x);
+ double c = (b - 1) / (a + 1) * f;
+ double s = 1;
+ double n = 0;
+
+ s += c;
+
+ do
+ {
+ n++;
+ c *= -f * (2 + n - b) / (2 + n + a);
+ s += c;
+ }
+ while (n < 512 && fabs (c) > GSL_DBL_EPSILON * fabs (s) + epsabs);
+
+ s /= (1 - x);
+
+ return s;
+}
+#endif
diff --git a/gsl-1.9/cdf/betainv.c b/gsl-1.9/cdf/betainv.c
new file mode 100644
index 0000000..b9fac7b
--- /dev/null
+++ b/gsl-1.9/cdf/betainv.c
@@ -0,0 +1,195 @@
+/* cdf/betainv.c
+ *
+ * Copyright (C) 2004 Free Software Foundation, Inc.
+ * Copyright (C) 2006 Brian Gough
+ * Written by Jason H. Stover.
+ * Modified for GSL by Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/*
+ * Invert the Beta distribution.
+ *
+ * References:
+ *
+ * Roger W. Abernathy and Robert P. Smith. "Applying Series Expansion
+ * to the Inverse Beta Distribution to Find Percentiles of the
+ * F-Distribution," ACM Transactions on Mathematical Software, volume
+ * 19, number 4, December 1993, pages 474-480.
+ *
+ * G.W. Hill and A.W. Davis. "Generalized asymptotic expansions of a
+ * Cornish-Fisher type," Annals of Mathematical Statistics, volume 39,
+ * number 8, August 1968, pages 1264-1273.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+#include <gsl/gsl_sf_gamma.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_randist.h>
+
+#include "error.h"
+
+double
+gsl_cdf_beta_Pinv (const double P, const double a, const double b)
+{
+ double x, mean;
+
+ if (P < 0.0 || P > 1.0)
+ {
+ CDF_ERROR ("P must be in range 0 < P < 1", GSL_EDOM);
+ }
+
+ if (a < 0.0)
+ {
+ CDF_ERROR ("a < 0", GSL_EDOM);
+ }
+
+ if (b < 0.0)
+ {
+ CDF_ERROR ("b < 0", GSL_EDOM);
+ }
+
+ if (P == 0.0)
+ {
+ return 0.0;
+ }
+
+ if (P == 1.0)
+ {
+ return 1.0;
+ }
+
+ if (P > 0.5)
+ {
+ return gsl_cdf_beta_Qinv (1 - P, a, b);
+ }
+
+ mean = a / (a + b);
+
+ if (P < 0.1)
+ {
+ /* small x */
+
+ double lg_ab = gsl_sf_lngamma (a + b);
+ double lg_a = gsl_sf_lngamma (a);
+ double lg_b = gsl_sf_lngamma (b);
+
+ double lx = (log (a) + lg_a + lg_b - lg_ab + log (P)) / a;
+ if (lx <= 0) {
+ x = exp (lx); /* first approximation */
+ x *= pow (1 - x, -(b - 1) / a); /* second approximation */
+ } else {
+ x = mean;
+ }
+
+ if (x > mean)
+ x = mean;
+ }
+ else
+ {
+ /* Use expected value as first guess */
+ x = mean;
+ }
+
+ {
+ double lambda, dP, phi;
+ unsigned int n = 0;
+
+ start:
+ dP = P - gsl_cdf_beta_P (x, a, b);
+ phi = gsl_ran_beta_pdf (x, a, b);
+
+ if (dP == 0.0 || n++ > 64)
+ goto end;
+
+ lambda = dP / GSL_MAX (2 * fabs (dP / x), phi);
+
+ {
+ double step0 = lambda;
+ double step1 = -((a - 1) / x - (b - 1) / (1 - x)) * lambda * lambda / 2;
+
+ double step = step0;
+
+ if (fabs (step1) < fabs (step0))
+ {
+ step += step1;
+ }
+ else
+ {
+ /* scale back step to a reasonable size when too large */
+ step *= 2 * fabs (step0 / step1);
+ };
+
+ if (x + step > 0 && x + step < 1)
+ {
+ x += step;
+ }
+ else
+ {
+ x = sqrt (x) * sqrt (mean); /* try a new starting point */
+ }
+
+ if (fabs (step0) > 1e-10 * x)
+ goto start;
+ }
+
+ end:
+ return x;
+
+ }
+}
+
+double
+gsl_cdf_beta_Qinv (const double Q, const double a, const double b)
+{
+
+ if (Q < 0.0 || Q > 1.0)
+ {
+ CDF_ERROR ("Q must be inside range 0 < Q < 1", GSL_EDOM);
+ }
+
+ if (a < 0.0)
+ {
+ CDF_ERROR ("a < 0", GSL_EDOM);
+ }
+
+ if (b < 0.0)
+ {
+ CDF_ERROR ("b < 0", GSL_EDOM);
+ }
+
+ if (Q == 0.0)
+ {
+ return 1.0;
+ }
+
+ if (Q == 1.0)
+ {
+ return 0.0;
+ }
+
+ if (Q > 0.5)
+ {
+ return gsl_cdf_beta_Pinv (1 - Q, a, b);
+ }
+ else
+ {
+ return 1 - gsl_cdf_beta_Pinv (Q, b, a);
+ };
+}
diff --git a/gsl-1.9/cdf/binomial.c b/gsl-1.9/cdf/binomial.c
new file mode 100644
index 0000000..40a8d58
--- /dev/null
+++ b/gsl-1.9/cdf/binomial.c
@@ -0,0 +1,108 @@
+/* cdf/binomial.c
+ *
+ * Copyright (C) 2004 Jason H. Stover.
+ * Copyright (C) 2004 Giulio Bottazzi
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_sf_gamma.h>
+
+#include "error.h"
+
+/* Computes the cumulative distribution function for a binomial
+ random variable. For a binomial random variable X with n trials
+ and success probability p,
+
+ Pr( X <= k ) = Pr( Y >= p )
+
+ where Y is a beta random variable with parameters k+1 and n-k.
+
+ The binomial distribution has the form,
+
+ prob(k) = n!/(k!(n-k)!) * p^k (1-p)^(n-k) for k = 0, 1, ..., n
+
+ The cumulated distributions can be expressed in terms of normalized
+ incomplete beta functions (see Abramowitz & Stegun eq. 26.5.26 and
+ eq. 6.6.3).
+
+ Reference:
+
+ W. Feller, "An Introduction to Probability and Its
+ Applications," volume 1. Wiley, 1968. Exercise 45, page 173,
+ chapter 6.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_binomial_P (const unsigned int k, const double p, const unsigned int n)
+{
+ double P;
+ double a;
+ double b;
+
+ if (p > 1.0 || p < 0.0)
+ {
+ CDF_ERROR ("p < 0 or p > 1", GSL_EDOM);
+ }
+
+ if (k >= n)
+ {
+ P = 1.0;
+ }
+ else
+ {
+ a = (double) k + 1.0;
+ b = (double) n - k;
+ P = gsl_cdf_beta_Q (p, a, b);
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_binomial_Q (const unsigned int k, const double p, const unsigned int n)
+{
+ double Q;
+ double a;
+ double b;
+
+ if (p > 1.0 || p < 0.0)
+ {
+ CDF_ERROR ("p < 0 or p > 1", GSL_EDOM);
+ }
+
+ if (k >= n)
+ {
+ Q = 0.0;
+ }
+ else
+ {
+ a = (double) k + 1.0;
+ b = (double) n - k;
+ Q = gsl_cdf_beta_P (p, a, b);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/cauchy.c b/gsl-1.9/cdf/cauchy.c
new file mode 100644
index 0000000..7a2ccb3
--- /dev/null
+++ b/gsl-1.9/cdf/cauchy.c
@@ -0,0 +1,59 @@
+/* cdf/cauchy.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_cauchy_P (const double x, const double a)
+{
+ double P;
+ double u = x / a;
+
+ if (u > -1)
+ {
+ P = 0.5 + atan (u) / M_PI;
+ }
+ else
+ {
+ P = atan(-1/u) / M_PI;
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_cauchy_Q (const double x, const double a)
+{
+ double Q;
+ double u = x / a;
+
+ if (u < 1)
+ {
+ Q = 0.5 - atan (u) / M_PI;
+ }
+ else
+ {
+ Q = atan(1/u) / M_PI;
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/cauchyinv.c b/gsl-1.9/cdf/cauchyinv.c
new file mode 100644
index 0000000..291ca88
--- /dev/null
+++ b/gsl-1.9/cdf/cauchyinv.c
@@ -0,0 +1,75 @@
+/* cdf/cauchyinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_cauchy_Pinv (const double P, const double a)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ if (P > 0.5)
+ {
+ x = a * tan (M_PI * (P - 0.5));
+ }
+ else
+ {
+ x = -a / tan (M_PI * P);
+ }
+
+ return x;
+}
+
+double
+gsl_cdf_cauchy_Qinv (const double Q, const double a)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ if (Q > 0.5)
+ {
+ x = a * tan (M_PI * (0.5 - Q));
+ }
+ else
+ {
+ x = a / tan (M_PI * Q);
+ }
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/chisq.c b/gsl-1.9/cdf/chisq.c
new file mode 100644
index 0000000..ec5c70d
--- /dev/null
+++ b/gsl-1.9/cdf/chisq.c
@@ -0,0 +1,34 @@
+/* cdf/cdf_chisq.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_sf_gamma.h>
+
+double
+gsl_cdf_chisq_P (const double x, const double nu)
+{
+ return gsl_cdf_gamma_P (x, nu / 2, 2.0);
+}
+
+double
+gsl_cdf_chisq_Q (const double x, const double nu)
+{
+ return gsl_cdf_gamma_Q (x, nu / 2, 2.0);
+}
diff --git a/gsl-1.9/cdf/chisqinv.c b/gsl-1.9/cdf/chisqinv.c
new file mode 100644
index 0000000..941db52
--- /dev/null
+++ b/gsl-1.9/cdf/chisqinv.c
@@ -0,0 +1,34 @@
+/* cdf/chisqinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_sf_gamma.h>
+
+double
+gsl_cdf_chisq_Pinv (const double P, const double nu)
+{
+ return gsl_cdf_gamma_Pinv (P, nu / 2, 2.0);
+}
+
+double
+gsl_cdf_chisq_Qinv (const double Q, const double nu)
+{
+ return gsl_cdf_gamma_Qinv (Q, nu / 2, 2.0);
+}
diff --git a/gsl-1.9/cdf/error.h b/gsl-1.9/cdf/error.h
new file mode 100644
index 0000000..83db7ba
--- /dev/null
+++ b/gsl-1.9/cdf/error.h
@@ -0,0 +1,4 @@
+/* CDF_ERROR: call the error handler, and return a NAN. */
+
+#define CDF_ERROR(reason, gsl_errno) GSL_ERROR_VAL(reason, gsl_errno, GSL_NAN)
+
diff --git a/gsl-1.9/cdf/exponential.c b/gsl-1.9/cdf/exponential.c
new file mode 100644
index 0000000..e997bb0
--- /dev/null
+++ b/gsl-1.9/cdf/exponential.c
@@ -0,0 +1,59 @@
+/* cdf/exponential.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+/* The exponential distribution has the form
+
+ p(x) dx = exp(-x/mu) dx/mu
+
+ for x = 0 ... +infty */
+
+double
+gsl_cdf_exponential_P (const double x, const double mu)
+{
+ if (x < 0)
+ {
+ return 0;
+ }
+ else
+ {
+ double P = -expm1 (-x / mu);
+
+ return P;
+ }
+}
+
+double
+gsl_cdf_exponential_Q (const double x, const double mu)
+{
+ if (x < 0)
+ {
+ return 1;
+ }
+ else
+ {
+ double Q = exp (-x / mu);
+
+ return Q;
+ }
+}
diff --git a/gsl-1.9/cdf/exponentialinv.c b/gsl-1.9/cdf/exponentialinv.c
new file mode 100644
index 0000000..035340c
--- /dev/null
+++ b/gsl-1.9/cdf/exponentialinv.c
@@ -0,0 +1,39 @@
+/* cdf/exponentialinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_exponential_Pinv (const double P, const double mu)
+{
+ double x = -mu * log1p (-P);
+
+ return x;
+}
+
+double
+gsl_cdf_exponential_Qinv (const double Q, const double mu)
+{
+ double x = -mu * log (Q);
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/exppow.c b/gsl-1.9/cdf/exppow.c
new file mode 100644
index 0000000..440f5c4
--- /dev/null
+++ b/gsl-1.9/cdf/exppow.c
@@ -0,0 +1,70 @@
+/* cdf/exppow.c
+ *
+ * Copyright (C) 2004 Giulio Bottazzi
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_sf_gamma.h>
+
+/* The exponential power density is parametrized according to
+
+ p(x) dx = (1/(2 a Gamma(1 + 1/b))) * exp(-|x/a|^b) dx
+
+ so that the distribution reads
+
+ / x<0 0.5 - Gamma_inc_P(1/b,|x/a|^b)
+ P(x) = | x=0 0.5
+ \ x>0 0.5 + Gamma_inc_P(1/b,|x/a|^b)
+
+
+ for x in (-infty,+infty) */
+
+double
+gsl_cdf_exppow_P (const double x, const double a, const double b)
+{
+ const double u = x / a;
+
+ if (u < 0)
+ {
+ double P = 0.5 * gsl_sf_gamma_inc_Q (1.0 / b, pow (-u, b));
+ return P;
+ }
+ else
+ {
+ double P = 0.5 * (1.0 + gsl_sf_gamma_inc_P (1.0 / b, pow (u, b)));
+ return P;
+ }
+}
+
+double
+gsl_cdf_exppow_Q (const double x, const double a, const double b)
+{
+ const double u = x / a;
+
+ if (u < 0)
+ {
+ double Q = 0.5 * (1.0 + gsl_sf_gamma_inc_P (1.0 / b, pow (-u, b)));
+ return Q;
+ }
+ else
+ {
+ double Q = 0.5 * gsl_sf_gamma_inc_Q (1.0 / b, pow (u, b));
+ return Q;
+ }
+}
diff --git a/gsl-1.9/cdf/fdist.c b/gsl-1.9/cdf/fdist.c
new file mode 100644
index 0000000..fb3321f
--- /dev/null
+++ b/gsl-1.9/cdf/fdist.c
@@ -0,0 +1,81 @@
+/* cdf/fdist.c
+ *
+ * Copyright (C) 2002 Przemyslaw Sliwa and Jason H. Stover.
+ * Copyright (C) 2006 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_sf_gamma.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+
+#include "error.h"
+#include "beta_inc.c"
+
+/*
+ * Lower tail.
+ */
+
+double
+gsl_cdf_fdist_P (const double x, const double nu1, const double nu2)
+{
+ double P;
+ double r = nu2 / nu1;
+
+ if (x < r)
+ {
+ double u = x / (r + x);
+
+ P = beta_inc_AXPY (1.0, 0.0, nu1 / 2.0, nu2 / 2.0, u);
+ }
+ else
+ {
+ double u = r / (r + x);
+
+ P = beta_inc_AXPY (-1.0, 1.0, nu2 / 2.0, nu1 / 2.0, u);
+ }
+
+ return P;
+}
+
+/*
+ * Upper tail.
+ */
+
+double
+gsl_cdf_fdist_Q (const double x, const double nu1, const double nu2)
+{
+ double Q;
+ double r = nu2 / nu1;
+
+ if (x < r)
+ {
+ double u = x / (r + x);
+
+ Q = beta_inc_AXPY (-1.0, 1.0, nu1 / 2.0, nu2 / 2.0, u);
+ }
+ else
+ {
+ double u = r / (r + x);
+
+ Q = beta_inc_AXPY (1.0, 0.0, nu2 / 2.0, nu1 / 2.0, u);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/fdistinv.c b/gsl-1.9/cdf/fdistinv.c
new file mode 100644
index 0000000..231f5c1
--- /dev/null
+++ b/gsl-1.9/cdf/fdistinv.c
@@ -0,0 +1,104 @@
+/* cdf/fdistinv.c
+ *
+ * Copyright (C) 2002 Przemyslaw Sliwa and Jason H. Stover.
+ * Copyright (C) 2006 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+
+#include "error.h"
+
+double
+gsl_cdf_fdist_Pinv (const double P, const double nu1, const double nu2)
+{
+ double result;
+ double y;
+
+ if (P < 0.0)
+ {
+ CDF_ERROR ("P < 0.0", GSL_EDOM);
+ }
+ if (P > 1.0)
+ {
+ CDF_ERROR ("P > 1.0", GSL_EDOM);
+ }
+ if (nu1 < 1.0)
+ {
+ CDF_ERROR ("nu1 < 1", GSL_EDOM);
+ }
+ if (nu2 < 1.0)
+ {
+ CDF_ERROR ("nu2 < 1", GSL_EDOM);
+ }
+
+ if (P < 0.5)
+ {
+ y = gsl_cdf_beta_Pinv (P, nu1 / 2.0, nu2 / 2.0);
+
+ result = nu2 * y / (nu1 * (1.0 - y));
+ }
+ else
+ {
+ y = gsl_cdf_beta_Qinv (P, nu2 / 2.0, nu1 / 2.0);
+
+ result = nu2 * (1 - y) / (nu1 * y);
+ }
+
+ return result;
+}
+
+double
+gsl_cdf_fdist_Qinv (const double Q, const double nu1, const double nu2)
+{
+ double result;
+ double y;
+
+ if (Q < 0.0)
+ {
+ CDF_ERROR ("Q < 0.0", GSL_EDOM);
+ }
+ if (Q > 1.0)
+ {
+ CDF_ERROR ("Q > 1.0", GSL_EDOM);
+ }
+ if (nu1 < 1.0)
+ {
+ CDF_ERROR ("nu1 < 1", GSL_EDOM);
+ }
+ if (nu2 < 1.0)
+ {
+ CDF_ERROR ("nu2 < 1", GSL_EDOM);
+ }
+
+ if (Q > 0.5)
+ {
+ y = gsl_cdf_beta_Qinv (Q, nu1 / 2.0, nu2 / 2.0);
+
+ result = nu2 * y / (nu1 * (1.0 - y));
+ }
+ else
+ {
+ y = gsl_cdf_beta_Pinv (Q, nu2 / 2.0, nu1 / 2.0);
+
+ result = nu2 * (1 - y) / (nu1 * y);
+ }
+
+ return result;
+}
diff --git a/gsl-1.9/cdf/flat.c b/gsl-1.9/cdf/flat.c
new file mode 100644
index 0000000..407b195
--- /dev/null
+++ b/gsl-1.9/cdf/flat.c
@@ -0,0 +1,65 @@
+/* cdf/flat.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_flat_P (const double x, const double a, const double b)
+{
+ double P;
+
+ if (x < a)
+ {
+ P = 0;
+ }
+ else if (x > b)
+ {
+ P = 1;
+ }
+ else
+ {
+ P = (x-a)/(b-a);
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_flat_Q (const double x, const double a, const double b)
+{
+ double Q;
+
+ if (x < a)
+ {
+ Q = 1;
+ }
+ else if (x > b)
+ {
+ Q = 0;
+ }
+ else
+ {
+ Q = (b-x)/(b-a);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/flatinv.c b/gsl-1.9/cdf/flatinv.c
new file mode 100644
index 0000000..d31014e
--- /dev/null
+++ b/gsl-1.9/cdf/flatinv.c
@@ -0,0 +1,59 @@
+/* cdf/flatinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_flat_Pinv (const double P, const double a, const double b)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return b;
+ }
+ else if (P == 0.0)
+ {
+ return a;
+ }
+
+ x = (1 - P) * a + P * b;
+
+ return x;
+}
+
+double
+gsl_cdf_flat_Qinv (const double Q, const double a, const double b)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return b;
+ }
+ else if (Q == 1.0)
+ {
+ return a;
+ }
+
+ x = Q * a + (1 - Q) * b;
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/gamma.c b/gsl-1.9/cdf/gamma.c
new file mode 100644
index 0000000..8174408
--- /dev/null
+++ b/gsl-1.9/cdf/gamma.c
@@ -0,0 +1,74 @@
+/* cdf/cdf_gamma.c
+ *
+ * Copyright (C) 2003 Jason Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/*
+ * Author: J. Stover
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_sf_gamma.h>
+
+double
+gsl_cdf_gamma_P (const double x, const double a, const double b)
+{
+ double P;
+ double y = x / b;
+
+ if (x <= 0.0)
+ {
+ return 0.0;
+ }
+
+ if (y > a)
+ {
+ P = 1 - gsl_sf_gamma_inc_Q (a, y);
+ }
+ else
+ {
+ P = gsl_sf_gamma_inc_P (a, y);
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_gamma_Q (const double x, const double a, const double b)
+{
+ double Q;
+ double y = x / b;
+
+ if (x <= 0.0)
+ {
+ return 1.0;
+ }
+
+ if (y < a)
+ {
+ Q = 1 - gsl_sf_gamma_inc_P (a, y);
+ }
+ else
+ {
+ Q = gsl_sf_gamma_inc_Q (a, y);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/gammainv.c b/gsl-1.9/cdf/gammainv.c
new file mode 100644
index 0000000..47a77dd
--- /dev/null
+++ b/gsl-1.9/cdf/gammainv.c
@@ -0,0 +1,185 @@
+/* cdf/gammainv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_randist.h>
+#include <gsl/gsl_sf_gamma.h>
+
+#include <stdio.h>
+
+double
+gsl_cdf_gamma_Pinv (const double P, const double a, const double b)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return 0.0;
+ }
+
+ /* Consider, small, large and intermediate cases separately. The
+ boundaries at 0.05 and 0.95 have not been optimised, but seem ok
+ for an initial approximation. */
+
+ if (P < 0.05)
+ {
+ double x0 = exp ((gsl_sf_lngamma (a) + log (P)) / a);
+ x = x0;
+ }
+ else if (P > 0.95)
+ {
+ double x0 = -log1p (-P) + gsl_sf_lngamma (a);
+ x = x0;
+ }
+ else
+ {
+ double xg = gsl_cdf_ugaussian_Pinv (P);
+ double x0 = (xg < -sqrt (a)) ? a : sqrt (a) * xg + a;
+ x = x0;
+ }
+
+ /* Use Lagrange's interpolation for E(x)/phi(x0) to work backwards
+ to an improved value of x (Abramowitz & Stegun, 3.6.6)
+
+ where E(x)=P-integ(phi(u),u,x0,x) and phi(u) is the pdf.
+ */
+
+ {
+ double lambda, dP, phi;
+ unsigned int n = 0;
+
+ start:
+ dP = P - gsl_cdf_gamma_P (x, a, 1.0);
+ phi = gsl_ran_gamma_pdf (x, a, 1.0);
+
+ if (dP == 0.0 || n++ > 32)
+ goto end;
+
+ lambda = dP / GSL_MAX (2 * fabs (dP / x), phi);
+
+ {
+ double step0 = lambda;
+ double step1 = -((a - 1) / x - 1) * lambda * lambda / 4.0;
+
+ double step = step0;
+ if (fabs (step1) < fabs (step0))
+ step += step1;
+
+ if (x + step > 0)
+ x += step;
+ else
+ {
+ x /= 2.0;
+ }
+
+ if (fabs (step0) > 1e-10 * x)
+ goto start;
+ }
+
+ }
+
+end:
+ return b * x;
+}
+
+double
+gsl_cdf_gamma_Qinv (const double Q, const double a, const double b)
+{
+ double x;
+
+ if (Q == 1.0)
+ {
+ return 0.0;
+ }
+ else if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+
+ /* Consider, small, large and intermediate cases separately. The
+ boundaries at 0.05 and 0.95 have not been optimised, but seem ok
+ for an initial approximation. */
+
+ if (Q < 0.05)
+ {
+ double x0 = -log (Q) + gsl_sf_lngamma (a);
+ x = x0;
+ }
+ else if (Q > 0.95)
+ {
+ double x0 = exp ((gsl_sf_lngamma (a) + log1p (-Q)) / a);
+ x = x0;
+ }
+ else
+ {
+ double xg = gsl_cdf_ugaussian_Qinv (Q);
+ double x0 = (xg < -sqrt (a)) ? a : sqrt (a) * xg + a;
+ x = x0;
+ }
+
+ /* Use Lagrange's interpolation for E(x)/phi(x0) to work backwards
+ to an improved value of x (Abramowitz & Stegun, 3.6.6)
+
+ where E(x)=P-integ(phi(u),u,x0,x) and phi(u) is the pdf.
+ */
+
+ {
+ double lambda, dQ, phi;
+ unsigned int n = 0;
+
+ start:
+ dQ = Q - gsl_cdf_gamma_Q (x, a, 1.0);
+ phi = gsl_ran_gamma_pdf (x, a, 1.0);
+
+ if (dQ == 0.0 || n++ > 32)
+ goto end;
+
+ lambda = -dQ / GSL_MAX (2 * fabs (dQ / x), phi);
+
+ {
+ double step0 = lambda;
+ double step1 = -((a - 1) / x - 1) * lambda * lambda / 4.0;
+
+ double step = step0;
+ if (fabs (step1) < fabs (step0))
+ step += step1;
+
+ if (x + step > 0)
+ x += step;
+ else
+ {
+ x /= 2.0;
+ }
+
+ if (fabs (step0) > 1e-10 * x)
+ goto start;
+ }
+
+ }
+
+end:
+ return b * x;
+}
diff --git a/gsl-1.9/cdf/gauss.c b/gsl-1.9/cdf/gauss.c
new file mode 100644
index 0000000..235c978
--- /dev/null
+++ b/gsl-1.9/cdf/gauss.c
@@ -0,0 +1,351 @@
+/* cdf/gauss.c
+ *
+ * Copyright (C) 2002, 2004 Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/*
+ * Computes the cumulative distribution function for the Gaussian
+ * distribution using a rational function approximation. The
+ * computation is for the standard Normal distribution, i.e., mean 0
+ * and standard deviation 1. If you want to compute Pr(X < t) for a
+ * Gaussian random variable X with non-zero mean m and standard
+ * deviation sd not equal to 1, find gsl_cdf_ugaussian ((t-m)/sd).
+ * This approximation is accurate to at least double precision. The
+ * accuracy was verified with a pari-gp script. The largest error
+ * found was about 1.4E-20. The coefficients were derived by Cody.
+ *
+ * References:
+ *
+ * W.J. Cody. "Rational Chebyshev Approximations for the Error
+ * Function," Mathematics of Computation, v23 n107 1969, 631-637.
+ *
+ * W. Fraser, J.F Hart. "On the Computation of Rational Approximations
+ * to Continuous Functions," Communications of the ACM, v5 1962.
+ *
+ * W.J. Kennedy Jr., J.E. Gentle. "Statistical Computing." Marcel Dekker. 1980.
+ *
+ *
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+#ifndef M_1_SQRT2PI
+#define M_1_SQRT2PI (M_2_SQRTPI * M_SQRT1_2 / 2.0)
+#endif
+
+#define SQRT32 (4.0 * M_SQRT2)
+
+/*
+ * IEEE double precision dependent constants.
+ *
+ * GAUSS_EPSILON: Smallest positive value such that
+ * gsl_cdf_gaussian(x) > 0.5.
+ * GAUSS_XUPPER: Largest value x such that gsl_cdf_gaussian(x) < 1.0.
+ * GAUSS_XLOWER: Smallest value x such that gsl_cdf_gaussian(x) > 0.0.
+ */
+
+#define GAUSS_EPSILON (GSL_DBL_EPSILON / 2)
+#define GAUSS_XUPPER (8.572)
+#define GAUSS_XLOWER (-37.519)
+
+#define GAUSS_SCALE (16.0)
+
+static double
+get_del (double x, double rational)
+{
+ double xsq = 0.0;
+ double del = 0.0;
+ double result = 0.0;
+
+ xsq = floor (x * GAUSS_SCALE) / GAUSS_SCALE;
+ del = (x - xsq) * (x + xsq);
+ del *= 0.5;
+
+ result = exp (-0.5 * xsq * xsq) * exp (-1.0 * del) * rational;
+
+ return result;
+}
+
+/*
+ * Normal cdf for fabs(x) < 0.66291
+ */
+static double
+gauss_small (const double x)
+{
+ unsigned int i;
+ double result = 0.0;
+ double xsq;
+ double xnum;
+ double xden;
+
+ const double a[5] = {
+ 2.2352520354606839287,
+ 161.02823106855587881,
+ 1067.6894854603709582,
+ 18154.981253343561249,
+ 0.065682337918207449113
+ };
+ const double b[4] = {
+ 47.20258190468824187,
+ 976.09855173777669322,
+ 10260.932208618978205,
+ 45507.789335026729956
+ };
+
+ xsq = x * x;
+ xnum = a[4] * xsq;
+ xden = xsq;
+
+ for (i = 0; i < 3; i++)
+ {
+ xnum = (xnum + a[i]) * xsq;
+ xden = (xden + b[i]) * xsq;
+ }
+
+ result = x * (xnum + a[3]) / (xden + b[3]);
+
+ return result;
+}
+
+/*
+ * Normal cdf for 0.66291 < fabs(x) < sqrt(32).
+ */
+static double
+gauss_medium (const double x)
+{
+ unsigned int i;
+ double temp = 0.0;
+ double result = 0.0;
+ double xnum;
+ double xden;
+ double absx;
+
+ const double c[9] = {
+ 0.39894151208813466764,
+ 8.8831497943883759412,
+ 93.506656132177855979,
+ 597.27027639480026226,
+ 2494.5375852903726711,
+ 6848.1904505362823326,
+ 11602.651437647350124,
+ 9842.7148383839780218,
+ 1.0765576773720192317e-8
+ };
+ const double d[8] = {
+ 22.266688044328115691,
+ 235.38790178262499861,
+ 1519.377599407554805,
+ 6485.558298266760755,
+ 18615.571640885098091,
+ 34900.952721145977266,
+ 38912.003286093271411,
+ 19685.429676859990727
+ };
+
+ absx = fabs (x);
+
+ xnum = c[8] * absx;
+ xden = absx;
+
+ for (i = 0; i < 7; i++)
+ {
+ xnum = (xnum + c[i]) * absx;
+ xden = (xden + d[i]) * absx;
+ }
+
+ temp = (xnum + c[7]) / (xden + d[7]);
+
+ result = get_del (x, temp);
+
+ return result;
+}
+
+/*
+ * Normal cdf for
+ * {sqrt(32) < x < GAUSS_XUPPER} union { GAUSS_XLOWER < x < -sqrt(32) }.
+ */
+static double
+gauss_large (const double x)
+{
+ int i;
+ double result;
+ double xsq;
+ double temp;
+ double xnum;
+ double xden;
+ double absx;
+
+ const double p[6] = {
+ 0.21589853405795699,
+ 0.1274011611602473639,
+ 0.022235277870649807,
+ 0.001421619193227893466,
+ 2.9112874951168792e-5,
+ 0.02307344176494017303
+ };
+ const double q[5] = {
+ 1.28426009614491121,
+ 0.468238212480865118,
+ 0.0659881378689285515,
+ 0.00378239633202758244,
+ 7.29751555083966205e-5
+ };
+
+ absx = fabs (x);
+ xsq = 1.0 / (x * x);
+ xnum = p[5] * xsq;
+ xden = xsq;
+
+ for (i = 0; i < 4; i++)
+ {
+ xnum = (xnum + p[i]) * xsq;
+ xden = (xden + q[i]) * xsq;
+ }
+
+ temp = xsq * (xnum + p[4]) / (xden + q[4]);
+ temp = (M_1_SQRT2PI - temp) / absx;
+
+ result = get_del (x, temp);
+
+ return result;
+}
+
+double
+gsl_cdf_ugaussian_P (const double x)
+{
+ double result;
+ double absx = fabs (x);
+
+ if (absx < GAUSS_EPSILON)
+ {
+ result = 0.5;
+ return result;
+ }
+ else if (absx < 0.66291)
+ {
+ result = 0.5 + gauss_small (x);
+ return result;
+ }
+ else if (absx < SQRT32)
+ {
+ result = gauss_medium (x);
+
+ if (x > 0.0)
+ {
+ result = 1.0 - result;
+ }
+
+ return result;
+ }
+ else if (x > GAUSS_XUPPER)
+ {
+ result = 1.0;
+ return result;
+ }
+ else if (x < GAUSS_XLOWER)
+ {
+ result = 0.0;
+ return result;
+ }
+ else
+ {
+ result = gauss_large (x);
+
+ if (x > 0.0)
+ {
+ result = 1.0 - result;
+ }
+ }
+
+ return result;
+}
+
+double
+gsl_cdf_ugaussian_Q (const double x)
+{
+ double result;
+ double absx = fabs (x);
+
+ if (absx < GAUSS_EPSILON)
+ {
+ result = 0.5;
+ return result;
+ }
+ else if (absx < 0.66291)
+ {
+ result = gauss_small (x);
+
+ if (x < 0.0)
+ {
+ result = fabs (result) + 0.5;
+ }
+ else
+ {
+ result = 0.5 - result;
+ }
+
+ return result;
+ }
+ else if (absx < SQRT32)
+ {
+ result = gauss_medium (x);
+
+ if (x < 0.0)
+ {
+ result = 1.0 - result;
+ }
+
+ return result;
+ }
+ else if (x > -(GAUSS_XLOWER))
+ {
+ result = 0.0;
+ return result;
+ }
+ else if (x < -(GAUSS_XUPPER))
+ {
+ result = 1.0;
+ return result;
+ }
+ else
+ {
+ result = gauss_large (x);
+
+ if (x < 0.0)
+ {
+ result = 1.0 - result;
+ }
+
+ }
+
+ return result;
+}
+
+double
+gsl_cdf_gaussian_P (const double x, const double sigma)
+{
+ return gsl_cdf_ugaussian_P (x / sigma);
+}
+
+double
+gsl_cdf_gaussian_Q (const double x, const double sigma)
+{
+ return gsl_cdf_ugaussian_Q (x / sigma);
+}
diff --git a/gsl-1.9/cdf/gaussinv.c b/gsl-1.9/cdf/gaussinv.c
new file mode 100644
index 0000000..fbddb9e
--- /dev/null
+++ b/gsl-1.9/cdf/gaussinv.c
@@ -0,0 +1,202 @@
+/* cdf/inverse_normal.c
+ *
+ * Copyright (C) 2002 Przemyslaw Sliwa and Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/*
+ * Computes the inverse normal cumulative distribution function
+ * according to the algorithm shown in
+ *
+ * Wichura, M.J. (1988).
+ * Algorithm AS 241: The Percentage Points of the Normal Distribution.
+ * Applied Statistics, 37, 477-484.
+ */
+
+#include <config.h>
+#include <gsl/gsl_errno.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+#include "rat_eval.h"
+
+static double
+small (double q)
+{
+ const double a[8] = { 3.387132872796366608, 133.14166789178437745,
+ 1971.5909503065514427, 13731.693765509461125,
+ 45921.953931549871457, 67265.770927008700853,
+ 33430.575583588128105, 2509.0809287301226727
+ };
+
+ const double b[8] = { 1.0, 42.313330701600911252,
+ 687.1870074920579083, 5394.1960214247511077,
+ 21213.794301586595867, 39307.89580009271061,
+ 28729.085735721942674, 5226.495278852854561
+ };
+
+ double r = 0.180625 - q * q;
+
+ double x = q * rat_eval (a, 8, b, 8, r);
+
+ return x;
+}
+
+static double
+intermediate (double r)
+{
+ const double a[] = { 1.42343711074968357734, 4.6303378461565452959,
+ 5.7694972214606914055, 3.64784832476320460504,
+ 1.27045825245236838258, 0.24178072517745061177,
+ 0.0227238449892691845833, 7.7454501427834140764e-4
+ };
+
+ const double b[] = { 1.0, 2.05319162663775882187,
+ 1.6763848301838038494, 0.68976733498510000455,
+ 0.14810397642748007459, 0.0151986665636164571966,
+ 5.475938084995344946e-4, 1.05075007164441684324e-9
+ };
+
+ double x = rat_eval (a, 8, b, 8, (r - 1.6));
+
+ return x;
+}
+
+static double
+tail (double r)
+{
+ const double a[] = { 6.6579046435011037772, 5.4637849111641143699,
+ 1.7848265399172913358, 0.29656057182850489123,
+ 0.026532189526576123093, 0.0012426609473880784386,
+ 2.71155556874348757815e-5, 2.01033439929228813265e-7
+ };
+
+ const double b[] = { 1.0, 0.59983220655588793769,
+ 0.13692988092273580531, 0.0148753612908506148525,
+ 7.868691311456132591e-4, 1.8463183175100546818e-5,
+ 1.4215117583164458887e-7, 2.04426310338993978564e-15
+ };
+
+ double x = rat_eval (a, 8, b, 8, (r - 5.0));
+
+ return x;
+}
+
+double
+gsl_cdf_ugaussian_Pinv (const double P)
+{
+ double r, x, pp;
+
+ double dP = P - 0.5;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ if (fabs (dP) <= 0.425)
+ {
+ x = small (dP);
+
+ return x;
+ }
+
+ pp = (P < 0.5) ? P : 1.0 - P;
+
+ r = sqrt (-log (pp));
+
+ if (r <= 5.0)
+ {
+ x = intermediate (r);
+ }
+ else
+ {
+ x = tail (r);
+ }
+
+ if (P < 0.5)
+ {
+ return -x;
+ }
+ else
+ {
+ return x;
+ }
+
+}
+
+double
+gsl_cdf_ugaussian_Qinv (const double Q)
+{
+ double r, x, pp;
+
+ double dQ = Q - 0.5;
+
+ if (Q == 1.0)
+ {
+ return GSL_NEGINF;
+ }
+ else if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+
+ if (fabs (dQ) <= 0.425)
+ {
+ x = small (dQ);
+
+ return -x;
+ }
+
+ pp = (Q < 0.5) ? Q : 1.0 - Q;
+
+ r = sqrt (-log (pp));
+
+ if (r <= 5.0)
+ {
+ x = intermediate (r);
+ }
+ else
+ {
+ x = tail (r);
+ }
+
+ if (Q < 0.5)
+ {
+ return x;
+ }
+ else
+ {
+ return -x;
+ }
+}
+
+
+double
+gsl_cdf_gaussian_Pinv (const double P, const double sigma)
+{
+ return sigma * gsl_cdf_ugaussian_Pinv (P);
+}
+
+double
+gsl_cdf_gaussian_Qinv (const double Q, const double sigma)
+{
+ return sigma * gsl_cdf_ugaussian_Qinv (Q);
+}
diff --git a/gsl-1.9/cdf/geometric.c b/gsl-1.9/cdf/geometric.c
new file mode 100644
index 0000000..1f671be
--- /dev/null
+++ b/gsl-1.9/cdf/geometric.c
@@ -0,0 +1,89 @@
+/* cdf/geometric.c
+ *
+ * Copyright (C) 2004 Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+#include <gsl/gsl_cdf.h>
+
+#include "error.h"
+
+/* Pr (X <= k), i.e., the probability of n or fewer failures until the
+ first success. */
+
+double
+gsl_cdf_geometric_P (const unsigned int k, const double p)
+{
+ double P, a, q;
+
+ if (p > 1.0 || p < 0.0)
+ {
+ CDF_ERROR ("p < 0 or p > 1", GSL_EDOM);
+ }
+
+ if (k < 1)
+ {
+ return 0.0;
+ }
+
+ q = 1.0 - p;
+ a = (double) k;
+
+ if (p < 0.5)
+ {
+ P = -expm1 (a * log1p (-p));
+ }
+ else
+ {
+ P = 1.0 - pow (q, a);
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_geometric_Q (const unsigned int k, const double p)
+{
+ double Q, a, q;
+
+ if (p > 1.0 || p < 0.0)
+ {
+ CDF_ERROR ("p < 0 or p > 1", GSL_EDOM);
+ }
+
+ if (k < 1)
+ {
+ Q = 1.0;
+ }
+
+ q = 1.0 - p;
+ a = (double) k;
+
+ if (p < 0.5)
+ {
+ Q = exp (a * log1p (-p));
+ }
+ else
+ {
+ Q = pow (q, a);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/gsl_cdf.h b/gsl-1.9/cdf/gsl_cdf.h
new file mode 100644
index 0000000..662cf5d
--- /dev/null
+++ b/gsl-1.9/cdf/gsl_cdf.h
@@ -0,0 +1,170 @@
+/* cdf/gsl_cdf.h
+ *
+ * Copyright (C) 2002 Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/* Author: J. Stover */
+
+#ifndef __GSL_CDF_H__
+#define __GSL_CDF_H__
+
+#undef __BEGIN_DECLS
+#undef __END_DECLS
+#ifdef __cplusplus
+# define __BEGIN_DECLS extern "C" {
+# define __END_DECLS }
+#else
+# define __BEGIN_DECLS /* empty */
+# define __END_DECLS /* empty */
+#endif
+
+__BEGIN_DECLS
+
+double gsl_cdf_ugaussian_P (const double x);
+double gsl_cdf_ugaussian_Q (const double x);
+
+double gsl_cdf_ugaussian_Pinv (const double P);
+double gsl_cdf_ugaussian_Qinv (const double Q);
+
+double gsl_cdf_gaussian_P (const double x, const double sigma);
+double gsl_cdf_gaussian_Q (const double x, const double sigma);
+
+double gsl_cdf_gaussian_Pinv (const double P, const double sigma);
+double gsl_cdf_gaussian_Qinv (const double Q, const double sigma);
+
+double gsl_cdf_gamma_P (const double x, const double a, const double b);
+double gsl_cdf_gamma_Q (const double x, const double a, const double b);
+
+double gsl_cdf_gamma_Pinv (const double P, const double a, const double b);
+double gsl_cdf_gamma_Qinv (const double Q, const double a, const double b);
+
+double gsl_cdf_cauchy_P (const double x, const double a);
+double gsl_cdf_cauchy_Q (const double x, const double a);
+
+double gsl_cdf_cauchy_Pinv (const double P, const double a);
+double gsl_cdf_cauchy_Qinv (const double Q, const double a);
+
+double gsl_cdf_laplace_P (const double x, const double a);
+double gsl_cdf_laplace_Q (const double x, const double a);
+
+double gsl_cdf_laplace_Pinv (const double P, const double a);
+double gsl_cdf_laplace_Qinv (const double Q, const double a);
+
+double gsl_cdf_rayleigh_P (const double x, const double sigma);
+double gsl_cdf_rayleigh_Q (const double x, const double sigma);
+
+double gsl_cdf_rayleigh_Pinv (const double P, const double sigma);
+double gsl_cdf_rayleigh_Qinv (const double Q, const double sigma);
+
+double gsl_cdf_chisq_P (const double x, const double nu);
+double gsl_cdf_chisq_Q (const double x, const double nu);
+
+double gsl_cdf_chisq_Pinv (const double P, const double nu);
+double gsl_cdf_chisq_Qinv (const double Q, const double nu);
+
+double gsl_cdf_exponential_P (const double x, const double mu);
+double gsl_cdf_exponential_Q (const double x, const double mu);
+
+double gsl_cdf_exponential_Pinv (const double P, const double mu);
+double gsl_cdf_exponential_Qinv (const double Q, const double mu);
+
+double gsl_cdf_exppow_P (const double x, const double a, const double b);
+double gsl_cdf_exppow_Q (const double x, const double a, const double b);
+
+double gsl_cdf_tdist_P (const double x, const double nu);
+double gsl_cdf_tdist_Q (const double x, const double nu);
+
+double gsl_cdf_tdist_Pinv (const double P, const double nu);
+double gsl_cdf_tdist_Qinv (const double Q, const double nu);
+
+double gsl_cdf_fdist_P (const double x, const double nu1, const double nu2);
+double gsl_cdf_fdist_Q (const double x, const double nu1, const double nu2);
+
+double gsl_cdf_fdist_Pinv (const double P, const double nu1, const double nu2);
+double gsl_cdf_fdist_Qinv (const double Q, const double nu1, const double nu2);
+
+double gsl_cdf_beta_P (const double x, const double a, const double b);
+double gsl_cdf_beta_Q (const double x, const double a, const double b);
+
+double gsl_cdf_beta_Pinv (const double P, const double a, const double b);
+double gsl_cdf_beta_Qinv (const double Q, const double a, const double b);
+
+double gsl_cdf_flat_P (const double x, const double a, const double b);
+double gsl_cdf_flat_Q (const double x, const double a, const double b);
+
+double gsl_cdf_flat_Pinv (const double P, const double a, const double b);
+double gsl_cdf_flat_Qinv (const double Q, const double a, const double b);
+
+double gsl_cdf_lognormal_P (const double x, const double zeta, const double sigma);
+double gsl_cdf_lognormal_Q (const double x, const double zeta, const double sigma);
+
+double gsl_cdf_lognormal_Pinv (const double P, const double zeta, const double sigma);
+double gsl_cdf_lognormal_Qinv (const double Q, const double zeta, const double sigma);
+
+double gsl_cdf_gumbel1_P (const double x, const double a, const double b);
+double gsl_cdf_gumbel1_Q (const double x, const double a, const double b);
+
+double gsl_cdf_gumbel1_Pinv (const double P, const double a, const double b);
+double gsl_cdf_gumbel1_Qinv (const double Q, const double a, const double b);
+
+double gsl_cdf_gumbel2_P (const double x, const double a, const double b);
+double gsl_cdf_gumbel2_Q (const double x, const double a, const double b);
+
+double gsl_cdf_gumbel2_Pinv (const double P, const double a, const double b);
+double gsl_cdf_gumbel2_Qinv (const double Q, const double a, const double b);
+
+double gsl_cdf_weibull_P (const double x, const double a, const double b);
+double gsl_cdf_weibull_Q (const double x, const double a, const double b);
+
+double gsl_cdf_weibull_Pinv (const double P, const double a, const double b);
+double gsl_cdf_weibull_Qinv (const double Q, const double a, const double b);
+
+double gsl_cdf_pareto_P (const double x, const double a, const double b);
+double gsl_cdf_pareto_Q (const double x, const double a, const double b);
+
+double gsl_cdf_pareto_Pinv (const double P, const double a, const double b);
+double gsl_cdf_pareto_Qinv (const double Q, const double a, const double b);
+
+double gsl_cdf_logistic_P (const double x, const double a);
+double gsl_cdf_logistic_Q (const double x, const double a);
+
+double gsl_cdf_logistic_Pinv (const double P, const double a);
+double gsl_cdf_logistic_Qinv (const double Q, const double a);
+
+double gsl_cdf_binomial_P (const unsigned int k, const double p, const unsigned int n);
+double gsl_cdf_binomial_Q (const unsigned int k, const double p, const unsigned int n);
+
+double gsl_cdf_poisson_P (const unsigned int k, const double mu);
+double gsl_cdf_poisson_Q (const unsigned int k, const double mu);
+
+double gsl_cdf_geometric_P (const unsigned int k, const double p);
+double gsl_cdf_geometric_Q (const unsigned int k, const double p);
+
+double gsl_cdf_negative_binomial_P (const unsigned int k, const double p, const double n);
+double gsl_cdf_negative_binomial_Q (const unsigned int k, const double p, const double n);
+
+double gsl_cdf_pascal_P (const unsigned int k, const double p, const unsigned int n);
+double gsl_cdf_pascal_Q (const unsigned int k, const double p, const unsigned int n);
+
+double gsl_cdf_hypergeometric_P (const unsigned int k, const unsigned int n1,
+ const unsigned int n2, const unsigned int t);
+double gsl_cdf_hypergeometric_Q (const unsigned int k, const unsigned int n1,
+ const unsigned int n2, const unsigned int t);
+
+__END_DECLS
+
+#endif /* __GSL_CDF_H__ */
diff --git a/gsl-1.9/cdf/gumbel1.c b/gsl-1.9/cdf/gumbel1.c
new file mode 100644
index 0000000..ec8ef21
--- /dev/null
+++ b/gsl-1.9/cdf/gumbel1.c
@@ -0,0 +1,49 @@
+/* cdf/gumbel1.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_gumbel1_P (const double x, const double a, const double b)
+{
+ double P = pow(exp (-b), exp (-a * x));
+ return P;
+}
+
+double
+gsl_cdf_gumbel1_Q (const double x, const double a, const double b)
+{
+ double u = exp (-a * x);
+ double Q;
+ double P = pow(exp (-b), u);
+
+ if (P < 0.5)
+ {
+ Q = 1 - P;
+ }
+ else
+ {
+ Q = -expm1 (-b * u);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/gumbel1inv.c b/gsl-1.9/cdf/gumbel1inv.c
new file mode 100644
index 0000000..c17ad93
--- /dev/null
+++ b/gsl-1.9/cdf/gumbel1inv.c
@@ -0,0 +1,61 @@
+/* cdf/gumbel1inv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_gumbel1_Pinv (const double P, const double a, const double b)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ x = log(-b / log(P)) / a;
+
+ return x;
+}
+
+double
+gsl_cdf_gumbel1_Qinv (const double Q, const double a, const double b)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ x = log(-b / log1p(-Q)) / a;
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/gumbel2.c b/gsl-1.9/cdf/gumbel2.c
new file mode 100644
index 0000000..62df56b
--- /dev/null
+++ b/gsl-1.9/cdf/gumbel2.c
@@ -0,0 +1,59 @@
+/* cdf/gumbel2.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_gumbel2_P (const double x, const double a, const double b)
+{
+ double P;
+
+ if (x == 0)
+ {
+ P = 0;
+ }
+ else
+ {
+ double u = pow (x, a);
+ P = exp (-b / u);
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_gumbel2_Q (const double x, const double a, const double b)
+{
+ double Q;
+
+ if (x == 0)
+ {
+ Q = 1;
+ }
+ else
+ {
+ double u = pow (x, a);
+ Q = -expm1 (-b / u);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/gumbel2inv.c b/gsl-1.9/cdf/gumbel2inv.c
new file mode 100644
index 0000000..b397f80
--- /dev/null
+++ b/gsl-1.9/cdf/gumbel2inv.c
@@ -0,0 +1,61 @@
+/* cdf/gumbel2inv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_gumbel2_Pinv (const double P, const double a, const double b)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return 0.0;
+ }
+
+ x = pow(b / (-log(P)), 1/a);
+
+ return x;
+}
+
+double
+gsl_cdf_gumbel2_Qinv (const double Q, const double a, const double b)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return 0.0;
+ }
+
+ x = pow(b / (-log1p(-Q)), 1/a);
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/hypergeometric.c b/gsl-1.9/cdf/hypergeometric.c
new file mode 100644
index 0000000..c0dee39
--- /dev/null
+++ b/gsl-1.9/cdf/hypergeometric.c
@@ -0,0 +1,183 @@
+/* cdf/hypergeometric.c
+ *
+ * Copyright (C) 2004 Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/*
+ * Computes the cumulative distribution function for a hypergeometric
+ * random variable. A hypergeometric random variable X is the number
+ * of elements of type 1 in a sample of size t, drawn from a population
+ * of size n1 + n2, in which n1 are of type 1 and n2 are of type 2.
+ *
+ * This algorithm computes Pr( X <= k ) by summing the terms from
+ * the mass function, Pr( X = k ).
+ *
+ * References:
+ *
+ * T. Wu. An accurate computation of the hypergeometric distribution
+ * function. ACM Transactions on Mathematical Software. Volume 19, number 1,
+ * March 1993.
+ * This algorithm is not used, since it requires factoring the
+ * numerator and denominator, then cancelling. It is more accurate
+ * than the algorithm used here, but the cancellation requires more
+ * time than the algorithm used here.
+ *
+ * W. Feller. An Introduction to Probability Theory and Its Applications,
+ * third edition. 1968. Chapter 2, section 6.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_randist.h>
+
+#include "error.h"
+
+static double
+lower_tail (const unsigned int k, const unsigned int n1,
+ const unsigned int n2, const unsigned int t)
+{
+ double relerr;
+ int i = k;
+ double s, P;
+
+ s = gsl_ran_hypergeometric_pdf (i, n1, n2, t);
+ P = s;
+
+ while (i > 0)
+ {
+ double factor =
+ (i / (n1 - i + 1.0)) * ((n2 + i - t) / (t - i + 1.0));
+ s *= factor;
+ P += s;
+ relerr = s / P;
+ if (relerr < GSL_DBL_EPSILON)
+ break;
+ i--;
+ }
+
+ return P;
+}
+
+static double
+upper_tail (const unsigned int k, const unsigned int n1,
+ const unsigned int n2, const unsigned int t)
+{
+ double relerr;
+ unsigned int i = k + 1;
+ double s, Q;
+
+ s = gsl_ran_hypergeometric_pdf (i, n1, n2, t);
+ Q = s;
+
+ while (i < t)
+ {
+ double factor =
+ ((n1 - i) / (i + 1.0)) * ((t - i) / (n2 + i + 1.0 - t));
+ s *= factor;
+ Q += s;
+ relerr = s / Q;
+ if (relerr < GSL_DBL_EPSILON)
+ break;
+ i++;
+ }
+
+ return Q;
+}
+
+
+
+
+/*
+ * Pr (X <= k)
+ */
+double
+gsl_cdf_hypergeometric_P (const unsigned int k,
+ const unsigned int n1,
+ const unsigned int n2, const unsigned int t)
+{
+ double P;
+
+ if (t > (n1 + n2))
+ {
+ CDF_ERROR ("t larger than population size", GSL_EDOM);
+ }
+ else if (k >= n1 || k >= t)
+ {
+ P = 1.0;
+ }
+ else if (k < 0.0)
+ {
+ P = 0.0;
+ }
+ else
+ {
+ double midpoint = (int) (t * n1 / (n1 + n2));
+
+ if (k >= midpoint)
+ {
+ P = 1 - upper_tail (k, n1, n2, t);
+ }
+ else
+ {
+ P = lower_tail (k, n1, n2, t);
+ }
+ }
+
+ return P;
+}
+
+/*
+ * Pr (X > k)
+ */
+double
+gsl_cdf_hypergeometric_Q (const unsigned int k,
+ const unsigned int n1,
+ const unsigned int n2, const unsigned int t)
+{
+ double Q;
+
+ if (t > (n1 + n2))
+ {
+ CDF_ERROR ("t larger than population size", GSL_EDOM);
+ }
+ else if (k >= n1 || k >= t)
+ {
+ Q = 0.0;
+ }
+ else if (k < 0.0)
+ {
+ Q = 1.0;
+ }
+ else
+ {
+ double midpoint = (int) (t * n1 / (n1 + n2));
+
+ if (k < midpoint)
+ {
+ Q = 1 - lower_tail (k, n1, n2, t);
+ }
+ else
+ {
+ Q = upper_tail (k, n1, n2, t);
+ }
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/laplace.c b/gsl-1.9/cdf/laplace.c
new file mode 100644
index 0000000..a92237c
--- /dev/null
+++ b/gsl-1.9/cdf/laplace.c
@@ -0,0 +1,59 @@
+/* cdf/laplace.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_laplace_P (const double x, const double a)
+{
+ double P;
+ double u = x / a;
+
+ if (u > 0)
+ {
+ P = 0.5 + 0.5*(1 - exp(-u)) ;
+ }
+ else
+ {
+ P = 0.5 * exp(u);
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_laplace_Q (const double x, const double a)
+{
+ double Q;
+ double u = x / a;
+
+ if (u > 0)
+ {
+ Q = 0.5 * exp(-u);
+ }
+ else
+ {
+ Q = 1 - 0.5 *exp(u);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/laplaceinv.c b/gsl-1.9/cdf/laplaceinv.c
new file mode 100644
index 0000000..2c21642
--- /dev/null
+++ b/gsl-1.9/cdf/laplaceinv.c
@@ -0,0 +1,75 @@
+/* cdf/laplaceinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_laplace_Pinv (const double P, const double a)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ if (P < 0.5)
+ {
+ x = a * log(2*P);
+ }
+ else
+ {
+ x = -a * log(2*(1-P));
+ }
+
+ return x;
+}
+
+double
+gsl_cdf_laplace_Qinv (const double Q, const double a)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ if (Q < 0.5)
+ {
+ x = -a * log(2*Q);
+ }
+ else
+ {
+ x = a * log(2*(1-Q));
+ }
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/logistic.c b/gsl-1.9/cdf/logistic.c
new file mode 100644
index 0000000..3b1e1ed
--- /dev/null
+++ b/gsl-1.9/cdf/logistic.c
@@ -0,0 +1,59 @@
+/* cdf/logistic.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_logistic_P (const double x, const double a)
+{
+ double P;
+ double u = x / a;
+
+ if (u >= 0)
+ {
+ P = 1 / (1 + exp (-u));
+ }
+ else
+ {
+ P = exp (u) / (1 + exp (u));
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_logistic_Q (const double x, const double a)
+{
+ double Q;
+ double u = x / a;
+
+ if (u >= 0)
+ {
+ Q = exp (-u) / (1 + exp (-u));
+ }
+ else
+ {
+ Q = 1 / (1 + exp (u));
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/logisticinv.c b/gsl-1.9/cdf/logisticinv.c
new file mode 100644
index 0000000..1873c1b
--- /dev/null
+++ b/gsl-1.9/cdf/logisticinv.c
@@ -0,0 +1,61 @@
+/* cdf/logisticinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_logistic_Pinv (const double P, const double a)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ x = a * log(P/(1-P));
+
+ return x;
+}
+
+double
+gsl_cdf_logistic_Qinv (const double Q, const double a)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ x = a * log((1-Q)/Q);
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/lognormal.c b/gsl-1.9/cdf/lognormal.c
new file mode 100644
index 0000000..5e2923e
--- /dev/null
+++ b/gsl-1.9/cdf/lognormal.c
@@ -0,0 +1,39 @@
+/* cdf/lognormal.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_lognormal_P (const double x, const double zeta, const double sigma)
+{
+ double u = (log (x) - zeta) / sigma;
+ double P = gsl_cdf_ugaussian_P (u);
+ return P;
+}
+
+double
+gsl_cdf_lognormal_Q (const double x, const double zeta, const double sigma)
+{
+ double u = (log (x) - zeta) / sigma;
+ double Q = gsl_cdf_ugaussian_Q (u);
+ return Q;
+}
diff --git a/gsl-1.9/cdf/lognormalinv.c b/gsl-1.9/cdf/lognormalinv.c
new file mode 100644
index 0000000..c2c47e8
--- /dev/null
+++ b/gsl-1.9/cdf/lognormalinv.c
@@ -0,0 +1,65 @@
+/* cdf/lognormalinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_lognormal_Pinv (const double P, const double zeta, const double sigma)
+{
+ double x, u;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return 0.0;
+ }
+
+ u = gsl_cdf_ugaussian_Pinv (P);
+
+ x = exp (zeta + sigma * u);
+
+ return x;
+}
+
+double
+gsl_cdf_lognormal_Qinv (const double Q, const double zeta, const double sigma)
+{
+ double x, u;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return 0.0;
+ }
+
+ u = gsl_cdf_ugaussian_Qinv (Q);
+
+ x = exp (zeta + sigma * u);
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/nbinomial.c b/gsl-1.9/cdf/nbinomial.c
new file mode 100644
index 0000000..c2c17e7
--- /dev/null
+++ b/gsl-1.9/cdf/nbinomial.c
@@ -0,0 +1,83 @@
+/* cdf/negbinom.c
+ *
+ * Copyright (C) 2004 Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+#include <gsl/gsl_cdf.h>
+
+#include "error.h"
+
+/*
+ * Pr(X <= k) for a negative binomial random variable X, i.e.,
+ * the probability of k or fewer failuers before success n.
+ */
+
+double
+gsl_cdf_negative_binomial_P (const unsigned int k, const double p, const double n)
+{
+ double P;
+ double a;
+ double b;
+
+ if (p > 1.0 || p < 0.0)
+ {
+ CDF_ERROR ("p < 0 or p > 1", GSL_EDOM);
+ }
+
+ if (n < 0)
+ {
+ CDF_ERROR ("n < 0", GSL_EDOM);
+ }
+
+ a = (double) n;
+ b = (double) k + 1.0;
+ P = gsl_cdf_beta_P (p, a, b);
+
+ return P;
+}
+
+/*
+ * Pr ( X > k ).
+ */
+
+double
+gsl_cdf_negative_binomial_Q (const unsigned int k, const double p, const double n)
+{
+ double Q;
+ double a;
+ double b;
+
+ if (p > 1.0 || p < 0.0)
+ {
+ CDF_ERROR ("p < 0 or p > 1", GSL_EDOM);
+ }
+
+ if (n < 0)
+ {
+ CDF_ERROR ("n < 0", GSL_EDOM);
+ }
+
+ a = (double) n;
+ b = (double) k + 1.0;
+ Q = gsl_cdf_beta_Q (p, a, b);
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/pareto.c b/gsl-1.9/cdf/pareto.c
new file mode 100644
index 0000000..3919155
--- /dev/null
+++ b/gsl-1.9/cdf/pareto.c
@@ -0,0 +1,57 @@
+/* cdf/pareto.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_pareto_P (const double x, const double a, const double b)
+{
+ double P;
+
+ if (x < b)
+ {
+ P = 0;
+ }
+ else
+ {
+ P = 1 - pow(b/x, a);
+ }
+
+ return P;
+}
+
+double
+gsl_cdf_pareto_Q (const double x, const double a, const double b)
+{
+ double Q;
+
+ if (x < b)
+ {
+ Q = 1;
+ }
+ else
+ {
+ Q = pow(b/x, a);
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/paretoinv.c b/gsl-1.9/cdf/paretoinv.c
new file mode 100644
index 0000000..04fff30
--- /dev/null
+++ b/gsl-1.9/cdf/paretoinv.c
@@ -0,0 +1,61 @@
+/* cdf/paretoinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_pareto_Pinv (const double P, const double a, const double b)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return b;
+ }
+
+ x = b * exp(-log1p(-P)/a);
+
+ return x;
+}
+
+double
+gsl_cdf_pareto_Qinv (const double Q, const double a, const double b)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return b;
+ }
+
+ x = b * exp(-log(Q) / a);
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/pascal.c b/gsl-1.9/cdf/pascal.c
new file mode 100644
index 0000000..5eb0265
--- /dev/null
+++ b/gsl-1.9/cdf/pascal.c
@@ -0,0 +1,40 @@
+/* cdf/pascal.c
+ *
+ * Copyright (C) 2006 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+/* The Pascal distribution is a negative binomial with valued integer n */
+
+
+double
+gsl_cdf_pascal_P (const unsigned int k, const double p, const unsigned int n)
+{
+ double P = gsl_cdf_negative_binomial_P (k, p, (double) n);
+ return P;
+}
+
+double
+gsl_cdf_pascal_Q (const unsigned int k, const double p, const unsigned int n)
+{
+ double Q = gsl_cdf_negative_binomial_Q (k, p, (double) n);
+ return Q;
+}
diff --git a/gsl-1.9/cdf/poisson.c b/gsl-1.9/cdf/poisson.c
new file mode 100644
index 0000000..cab0450
--- /dev/null
+++ b/gsl-1.9/cdf/poisson.c
@@ -0,0 +1,84 @@
+/* cdf/poisson.c
+ *
+ * Copyright (C) 2004 Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/*
+ * Computes the cumulative distribution function for a Poisson
+ * random variable. For a Poisson random variable X with parameter
+ * mu,
+ *
+ * Pr( X <= k ) = Pr( Y >= p )
+ *
+ * where Y is a gamma random variable with parameters k+1 and 1.
+ *
+ * Reference:
+ *
+ * W. Feller, "An Introduction to Probability and Its
+ * Applications," volume 1. Wiley, 1968. Exercise 46, page 173,
+ * chapter 6.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+#include <gsl/gsl_cdf.h>
+
+#include "error.h"
+
+/*
+ * Pr (X <= k) for a Poisson random variable X.
+ */
+
+double
+gsl_cdf_poisson_P (const unsigned int k, const double mu)
+{
+ double P;
+ double a;
+
+ if (mu <= 0.0)
+ {
+ CDF_ERROR ("mu <= 0", GSL_EDOM);
+ }
+
+ a = (double) k + 1.0;
+ P = gsl_cdf_gamma_Q (mu, a, 1.0);
+
+ return P;
+}
+
+/*
+ * Pr ( X > k ) for a Possion random variable X.
+ */
+
+double
+gsl_cdf_poisson_Q (const unsigned int k, const double mu)
+{
+ double Q;
+ double a;
+
+ if (mu <= 0.0)
+ {
+ CDF_ERROR ("mu <= 0", GSL_EDOM);
+ }
+
+ a = (double) k + 1.0;
+ Q = gsl_cdf_gamma_P (mu, a, 1.0);
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/rat_eval.h b/gsl-1.9/cdf/rat_eval.h
new file mode 100644
index 0000000..5e6fc19
--- /dev/null
+++ b/gsl-1.9/cdf/rat_eval.h
@@ -0,0 +1,25 @@
+static double
+rat_eval (const double a[], const size_t na,
+ const double b[], const size_t nb, const double x)
+{
+ size_t i, j;
+ double u, v, r;
+
+ u = a[na - 1];
+
+ for (i = na - 1; i > 0; i--)
+ {
+ u = x * u + a[i - 1];
+ }
+
+ v = b[nb - 1];
+
+ for (j = nb - 1; j > 0; j--)
+ {
+ v = x * v + b[j - 1];
+ }
+
+ r = u / v;
+
+ return r;
+}
diff --git a/gsl-1.9/cdf/rayleigh.c b/gsl-1.9/cdf/rayleigh.c
new file mode 100644
index 0000000..e0c3695
--- /dev/null
+++ b/gsl-1.9/cdf/rayleigh.c
@@ -0,0 +1,39 @@
+/* cdf/rayleigh.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_rayleigh_P (const double x, const double sigma)
+{
+ double u = x / sigma;
+ double P = -expm1 (-u*u/2);
+ return P;
+}
+
+double
+gsl_cdf_rayleigh_Q (const double x, const double sigma)
+{
+ double u = x / sigma;
+ double Q = exp (-u*u/2);
+ return Q;
+}
diff --git a/gsl-1.9/cdf/rayleighinv.c b/gsl-1.9/cdf/rayleighinv.c
new file mode 100644
index 0000000..f80de73
--- /dev/null
+++ b/gsl-1.9/cdf/rayleighinv.c
@@ -0,0 +1,61 @@
+/* cdf/rayleighinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_rayleigh_Pinv (const double P, const double sigma)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return 0.0;
+ }
+
+ x = sigma * M_SQRT2 * sqrt (-log1p (-P));
+
+ return x;
+}
+
+double
+gsl_cdf_rayleigh_Qinv (const double Q, const double sigma)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return 0.0;
+ }
+
+ x = sigma * M_SQRT2 * sqrt (-log (Q));
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/tdist.c b/gsl-1.9/cdf/tdist.c
new file mode 100644
index 0000000..77e6bb8
--- /dev/null
+++ b/gsl-1.9/cdf/tdist.c
@@ -0,0 +1,271 @@
+/* cdf/tdist.c
+ *
+ * Copyright (C) 2002 Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/*
+ * Computes the Student's t cumulative distribution function using
+ * the method detailed in
+ *
+ * W.J. Kennedy and J.E. Gentle, "Statistical Computing." 1980.
+ * Marcel Dekker. ISBN 0-8247-6898-1.
+ *
+ * G.W. Hill and A.W. Davis. "Generalized asymptotic expansions
+ * of Cornish-Fisher type." Annals of Mathematical Statistics,
+ * vol. 39, 1264-1273. 1968.
+ *
+ * G.W. Hill. "Algorithm 395: Student's t-distribution," Communications
+ * of the ACM, volume 13, number 10, page 617. October 1970.
+ *
+ * G.W. Hill, "Remark on algorithm 395: Student's t-distribution,"
+ * Transactions on Mathematical Software, volume 7, number 2, page
+ * 247. June 1982.
+ */
+
+#include <config.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_sf_gamma.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_errno.h>
+
+#include "beta_inc.c"
+
+static double
+poly_eval (const double c[], unsigned int n, double x)
+{
+ unsigned int i;
+ double y = c[0] * x;
+
+ for (i = 1; i < n; i++)
+ {
+ y = x * (y + c[i]);
+ }
+
+ y += c[n];
+
+ return y;
+}
+
+/*
+ * Use the Cornish-Fisher asymptotic expansion to find a point u such
+ * that gsl_cdf_gauss(y) = tcdf(t).
+ *
+ */
+
+static double
+cornish_fisher (double t, double n)
+{
+ const double coeffs6[10] = {
+ 0.265974025974025974026,
+ 5.449696969696969696970,
+ 122.20294372294372294372,
+ 2354.7298701298701298701,
+ 37625.00902597402597403,
+ 486996.1392857142857143,
+ 4960870.65,
+ 37978595.55,
+ 201505390.875,
+ 622437908.625
+ };
+ const double coeffs5[8] = {
+ 0.2742857142857142857142,
+ 4.499047619047619047619,
+ 78.45142857142857142857,
+ 1118.710714285714285714,
+ 12387.6,
+ 101024.55,
+ 559494.0,
+ 1764959.625
+ };
+ const double coeffs4[6] = {
+ 0.3047619047619047619048,
+ 3.752380952380952380952,
+ 46.67142857142857142857,
+ 427.5,
+ 2587.5,
+ 8518.5
+ };
+ const double coeffs3[4] = {
+ 0.4,
+ 3.3,
+ 24.0,
+ 85.5
+ };
+
+ double a = n - 0.5;
+ double b = 48.0 * a * a;
+
+ double z2 = a * log1p (t * t / n);
+ double z = sqrt (z2);
+
+ double p5 = z * poly_eval (coeffs6, 9, z2);
+ double p4 = -z * poly_eval (coeffs5, 7, z2);
+ double p3 = z * poly_eval (coeffs4, 5, z2);
+ double p2 = -z * poly_eval (coeffs3, 3, z2);
+ double p1 = z * (z2 + 3.0);
+ double p0 = z;
+
+ double y = p5;
+ y = (y / b) + p4;
+ y = (y / b) + p3;
+ y = (y / b) + p2;
+ y = (y / b) + p1;
+ y = (y / b) + p0;
+
+ if (t < 0)
+ y *= -1;
+
+ return y;
+}
+
+#if 0
+/*
+ * Series approximation for t > 4.0. This needs to be fixed;
+ * it shouldn't subtract the result from 1.0. A better way is
+ * to use two different series expansions. Figuring this out
+ * means rummaging through Fisher's paper in Metron, v5, 1926,
+ * "Expansion of Student's integral in powers of n^{-1}."
+ */
+
+#define MAXI 40
+
+static double
+normal_approx (const double x, const double nu)
+{
+ double y;
+ double num;
+ double diff;
+ double q;
+ int i;
+ double lg1, lg2;
+
+ y = 1 / sqrt (1 + x * x / nu);
+ num = 1.0;
+ q = 0.0;
+ diff = 2 * GSL_DBL_EPSILON;
+ for (i = 2; (i < MAXI) && (diff > GSL_DBL_EPSILON); i += 2)
+ {
+ diff = q;
+ num *= y * y * (i - 1) / i;
+ q += num / (nu + i);
+ diff = q - diff;
+ }
+ q += 1 / nu;
+ lg1 = gsl_sf_lngamma (nu / 2.0);
+ lg2 = gsl_sf_lngamma ((nu + 1.0) / 2.0);
+
+ diff = lg2 - lg1;
+ q *= pow (y, nu) * exp (diff) / sqrt (M_PI);
+
+ return q;
+}
+#endif
+
+double
+gsl_cdf_tdist_P (const double x, const double nu)
+{
+ double P;
+
+ double x2 = x * x;
+
+ if (nu > 30 && x2 < 10 * nu)
+ {
+ double u = cornish_fisher (x, nu);
+ P = gsl_cdf_ugaussian_P (u);
+
+ return P;
+ }
+
+ if (x2 < nu)
+ {
+ double u = x2 / nu;
+ double eps = u / (1 + u);
+
+ if (x >= 0)
+ {
+ P = beta_inc_AXPY (0.5, 0.5, 0.5, nu / 2.0, eps);
+ }
+ else
+ {
+ P = beta_inc_AXPY (-0.5, 0.5, 0.5, nu / 2.0, eps);
+ }
+ }
+ else
+ {
+ double v = nu / (x * x);
+ double eps = v / (1 + v);
+
+ if (x >= 0)
+ {
+ P = beta_inc_AXPY (-0.5, 1.0, nu / 2.0, 0.5, eps);
+ }
+ else
+ {
+ P = beta_inc_AXPY (0.5, 0.0, nu / 2.0, 0.5, eps);
+ }
+ }
+
+ return P;
+}
+
+
+double
+gsl_cdf_tdist_Q (const double x, const double nu)
+{
+ double Q;
+
+ double x2 = x * x;
+
+ if (nu > 30 && x2 < 10 * nu)
+ {
+ double u = cornish_fisher (x, nu);
+ Q = gsl_cdf_ugaussian_Q (u);
+
+ return Q;
+ }
+
+ if (x2 < nu)
+ {
+ double u = x2 / nu;
+ double eps = u / (1 + u);
+
+ if (x >= 0)
+ {
+ Q = beta_inc_AXPY (-0.5, 0.5, 0.5, nu / 2.0, eps);
+ }
+ else
+ {
+ Q = beta_inc_AXPY (0.5, 0.5, 0.5, nu / 2.0, eps);
+ }
+ }
+ else
+ {
+ double v = nu / (x * x);
+ double eps = v / (1 + v);
+
+ if (x >= 0)
+ {
+ Q = beta_inc_AXPY (0.5, 0.0, nu / 2.0, 0.5, eps);
+ }
+ else
+ {
+ Q = beta_inc_AXPY (-0.5, 1.0, nu / 2.0, 0.5, eps);
+ }
+ }
+
+ return Q;
+}
diff --git a/gsl-1.9/cdf/tdistinv.c b/gsl-1.9/cdf/tdistinv.c
new file mode 100644
index 0000000..63ac409
--- /dev/null
+++ b/gsl-1.9/cdf/tdistinv.c
@@ -0,0 +1,232 @@
+/* cdf/tdistinv.c
+ *
+ * Copyright (C) 2002 Jason H. Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_randist.h>
+#include <gsl/gsl_sf_gamma.h>
+
+#include <stdio.h>
+
+static double
+inv_cornish_fisher (double z, double nu)
+{
+ double a = 1 / (nu - 0.5);
+ double b = 48.0 / (a * a);
+
+ double cf1 = z * (3 + z * z);
+ double cf2 = z * (945 + z * z * (360 + z * z * (63 + z * z * 4)));
+
+ double y = z - cf1 / b + cf2 / (10 * b * b);
+
+ double t = GSL_SIGN (z) * sqrt (nu * expm1 (a * y * y));
+
+ return t;
+}
+
+
+double
+gsl_cdf_tdist_Pinv (const double P, const double nu)
+{
+ double x, ptail;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ if (nu == 1.0)
+ {
+ x = tan (M_PI * (P - 0.5));
+ }
+ else if (nu == 2.0)
+ {
+ double a = 2 * P - 1;
+ x = a / sqrt (2 * (1 - a * a));
+ }
+
+ ptail = (P < 0.5) ? P : 1 - P;
+
+ if (sqrt (M_PI * nu / 2) * ptail > pow (0.05, nu / 2))
+ {
+ double xg = gsl_cdf_ugaussian_Pinv (P);
+ x = inv_cornish_fisher (xg, nu);
+ }
+ else
+ {
+ /* Use an asymptotic expansion of the tail of integral */
+
+ double beta = gsl_sf_beta (0.5, nu / 2);
+
+ if (P < 0.5)
+ {
+ x = -sqrt (nu) * pow (beta * nu * P, -1.0 / nu);
+ }
+ else
+ {
+ x = sqrt (nu) * pow (beta * nu * (1 - P), -1.0 / nu);
+ }
+
+ /* Correct nu -> nu/(1+nu/x^2) in the leading term to account
+ for higher order terms. This avoids overestimating x, which
+ makes the iteration unstable due to the rapidly decreasing
+ tails of the distribution. */
+
+ x /= sqrt (1 + nu / (x * x));
+ }
+
+ {
+ double dP, phi;
+ unsigned int n = 0;
+
+ start:
+ dP = P - gsl_cdf_tdist_P (x, nu);
+ phi = gsl_ran_tdist_pdf (x, nu);
+
+ if (dP == 0.0 || n++ > 32)
+ goto end;
+
+ {
+ double lambda = dP / phi;
+ double step0 = lambda;
+ double step1 = ((nu + 1) * x / (x * x + nu)) * (lambda * lambda / 4.0);
+
+ double step = step0;
+
+ if (fabs (step1) < fabs (step0))
+ {
+ step += step1;
+ }
+
+ if (P > 0.5 && x + step < 0)
+ x /= 2;
+ else if (P < 0.5 && x + step > 0)
+ x /= 2;
+ else
+ x += step;
+
+ if (fabs (step) > 1e-10 * fabs (x))
+ goto start;
+ }
+ }
+
+end:
+
+ return x;
+}
+
+double
+gsl_cdf_tdist_Qinv (const double Q, const double nu)
+{
+ double x, qtail;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return GSL_NEGINF;
+ }
+
+ if (nu == 1.0)
+ {
+ x = tan (M_PI * (0.5 - Q));
+ }
+ else if (nu == 2.0)
+ {
+ double a = 2 * (1 - Q) - 1;
+ x = a / sqrt (2 * (1 - a * a));
+ }
+
+ qtail = (Q < 0.5) ? Q : 1 - Q;
+
+ if (sqrt (M_PI * nu / 2) * qtail > pow (0.05, nu / 2))
+ {
+ double xg = gsl_cdf_ugaussian_Qinv (Q);
+ x = inv_cornish_fisher (xg, nu);
+ }
+ else
+ {
+ /* Use an asymptotic expansion of the tail of integral */
+
+ double beta = gsl_sf_beta (0.5, nu / 2);
+
+ if (Q < 0.5)
+ {
+ x = sqrt (nu) * pow (beta * nu * Q, -1.0 / nu);
+ }
+ else
+ {
+ x = -sqrt (nu) * pow (beta * nu * (1 - Q), -1.0 / nu);
+ }
+
+ /* Correct nu -> nu/(1+nu/x^2) in the leading term to account
+ for higher order terms. This avoids overestimating x, which
+ makes the iteration unstable due to the rapidly decreasing
+ tails of the distribution. */
+
+ x /= sqrt (1 + nu / (x * x));
+ }
+
+ {
+ double dQ, phi;
+ unsigned int n = 0;
+
+ start:
+ dQ = Q - gsl_cdf_tdist_Q (x, nu);
+ phi = gsl_ran_tdist_pdf (x, nu);
+
+ if (dQ == 0.0 || n++ > 32)
+ goto end;
+
+ {
+ double lambda = - dQ / phi;
+ double step0 = lambda;
+ double step1 = ((nu + 1) * x / (x * x + nu)) * (lambda * lambda / 4.0);
+
+ double step = step0;
+
+ if (fabs (step1) < fabs (step0))
+ {
+ step += step1;
+ }
+
+ if (Q < 0.5 && x + step < 0)
+ x /= 2;
+ else if (Q > 0.5 && x + step > 0)
+ x /= 2;
+ else
+ x += step;
+
+ if (fabs (step) > 1e-10 * fabs (x))
+ goto start;
+ }
+ }
+
+end:
+
+ return x;
+}
diff --git a/gsl-1.9/cdf/test.c b/gsl-1.9/cdf/test.c
new file mode 100644
index 0000000..b07702c
--- /dev/null
+++ b/gsl-1.9/cdf/test.c
@@ -0,0 +1,1327 @@
+/* cdf/test.c
+ *
+ * Copyright (C) 2002 Jason H Stover.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <config.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_randist.h>
+#include <gsl/gsl_cdf.h>
+#include <gsl/gsl_test.h>
+#include <gsl/gsl_ieee_utils.h>
+
+#define TEST(func, args, value, tol) { double res = func args ; gsl_test_rel (res, value, tol, #func #args); } ;
+
+#define TEST_TOL0 (2.0*GSL_DBL_EPSILON)
+#define TEST_TOL1 (16.0*GSL_DBL_EPSILON)
+#define TEST_TOL2 (256.0*GSL_DBL_EPSILON)
+#define TEST_TOL3 (2048.0*GSL_DBL_EPSILON)
+#define TEST_TOL4 (16384.0*GSL_DBL_EPSILON)
+#define TEST_TOL5 (131072.0*GSL_DBL_EPSILON)
+#define TEST_TOL6 (1048576.0*GSL_DBL_EPSILON)
+
+void test_ugaussian (void);
+void test_ugaussianinv (void);
+void test_exponential (void);
+void test_exponentialinv (void);
+void test_exppow (void);
+void test_tdist (void);
+void test_fdist (void);
+void test_gamma (void);
+void test_chisq (void);
+void test_beta (void);
+void test_gammainv (void);
+void test_chisqinv (void);
+void test_tdistinv (void);
+void test_betainv (void);
+void test_finv (void);
+
+#include "test_auto.c"
+
+struct range { unsigned int min; unsigned int max; } ;
+double test_binomial_pdf (unsigned int n);
+double test_binomial_cdf_P (unsigned int n);
+double test_binomial_cdf_Q (unsigned int n);
+
+struct range
+test_binomial_range (void)
+{
+ struct range r = {0, 5};
+ return r;
+}
+
+double
+test_binomial_pdf (unsigned int k)
+{
+ return gsl_ran_binomial_pdf (k, 0.3, 5);
+}
+
+double
+test_binomial_cdf_P (unsigned int k)
+{
+ return gsl_cdf_binomial_P (k, 0.3, 5);
+}
+
+double
+test_binomial_cdf_Q (unsigned int k)
+{
+ return gsl_cdf_binomial_Q (k, 0.3, 5);
+}
+
+struct range
+test_poisson_range (void)
+{
+ struct range r = {0, 25};
+ return r;
+}
+
+double
+test_poisson_pdf (unsigned int k)
+{
+ return gsl_ran_poisson_pdf (k, 2.3);
+}
+
+double
+test_poisson_cdf_P (unsigned int k)
+{
+ return gsl_cdf_poisson_P (k, 2.3);
+}
+
+double
+test_poisson_cdf_Q (unsigned int k)
+{
+ return gsl_cdf_poisson_Q (k, 2.3);
+}
+
+struct range
+test_geometric_range (void)
+{
+ struct range r = {0, 25};
+ return r;
+}
+
+double
+test_geometric_pdf (unsigned int k)
+{
+ return gsl_ran_geometric_pdf (k, 0.3);
+}
+
+double
+test_geometric_cdf_P (unsigned int k)
+{
+ return gsl_cdf_geometric_P (k, 0.3);
+}
+
+double
+test_geometric_cdf_Q (unsigned int k)
+{
+ return gsl_cdf_geometric_Q (k, 0.3);
+}
+
+struct range
+test_negative_binomial_range (void)
+{
+ struct range r = {0, 15};
+ return r;
+}
+
+double
+test_negative_binomial_pdf (unsigned int k)
+{
+ return gsl_ran_negative_binomial_pdf (k, 0.3, 5.3);
+}
+
+double
+test_negative_binomial_cdf_P (unsigned int k)
+{
+ return gsl_cdf_negative_binomial_P (k, 0.3, 5.3);
+}
+
+double
+test_negative_binomial_cdf_Q (unsigned int k)
+{
+ return gsl_cdf_negative_binomial_Q (k, 0.3, 5.3);
+}
+
+struct range
+test_pascal_range (void)
+{
+ struct range r = {0, 15};
+ return r;
+}
+
+double
+test_pascal_pdf (unsigned int k)
+{
+ return gsl_ran_pascal_pdf (k, 0.3, 5);
+}
+
+double
+test_pascal_cdf_P (unsigned int k)
+{
+ return gsl_cdf_pascal_P (k, 0.3, 5);
+}
+
+double
+test_pascal_cdf_Q (unsigned int k)
+{
+ return gsl_cdf_pascal_Q (k, 0.3, 5);
+}
+
+struct range
+test_hypergeometric_range (void)
+{
+ struct range r = {0, 26};
+ return r;
+}
+
+double
+test_hypergeometric_pdf (unsigned int k)
+{
+ return gsl_ran_hypergeometric_pdf (k, 7, 19, 13);
+}
+
+double
+test_hypergeometric_cdf_P (unsigned int k)
+{
+ return gsl_cdf_hypergeometric_P (k, 7, 19, 13);
+}
+
+double
+test_hypergeometric_cdf_Q (unsigned int k)
+{
+ return gsl_cdf_hypergeometric_Q (k, 7, 19, 13);
+}
+
+#ifdef LOGARITHMIC
+struct range
+test_logarithmic_range (void)
+{
+ struct range r = {1, 200};
+ return r;
+}
+
+double
+test_logarithmic_pdf (unsigned int k)
+{
+ return gsl_ran_logarithmic_pdf (k, 0.9);
+}
+
+double
+test_logarithmic_cdf_P (unsigned int k)
+{
+ return gsl_cdf_logarithmic_P (k, 0.9);
+}
+
+double
+test_logarithmic_cdf_Q (unsigned int k)
+{
+ return gsl_cdf_logarithmic_Q (k, 0.9);
+}
+#endif
+
+void
+test_discrete_cdf_P (double (*pdf)(unsigned int),
+ double (*cdf_P)(unsigned int),
+ struct range (*range)(void),
+ const char * desc)
+{
+ double sum;
+ double tol = TEST_TOL2;
+ int i, min, max;
+
+ struct range r = range();
+
+ min = r.min;
+ max = r.max;
+ sum = 0.0;
+
+ for (i = min; i <= max; i++)
+ {
+ double pi = pdf(i);
+ double Pi = cdf_P(i);
+ sum += pi;
+ gsl_test_rel (Pi, sum, tol, desc, i);
+ }
+}
+
+void
+test_discrete_cdf_Q (double (*pdf)(unsigned int),
+ double (*cdf_Q)(unsigned int),
+ struct range (*range)(void),
+ const char * desc)
+{
+ double sum;
+ double tol = TEST_TOL2;
+ int i, min, max;
+
+ struct range r = range();
+
+ min = r.min;
+ max = r.max;
+ sum = cdf_Q(max);
+
+ for (i = max; i >= min; i--)
+ {
+ double pi = pdf(i);
+ double Qi = cdf_Q(i);
+ gsl_test_rel (Qi, sum, tol, desc, i);
+ sum += pi;
+ }
+}
+
+void
+test_discrete_cdf_PQ (double (*cdf_P)(unsigned int),
+ double (*cdf_Q)(unsigned int),
+ struct range (*range)(void),
+ const char * desc)
+{
+ double sum;
+ double tol = GSL_DBL_EPSILON;
+ int i, min, max;
+
+ struct range r = range();
+
+ min = r.min;
+ max = r.max;
+
+ for (i = min; i <= max; i++)
+ {
+ double Pi = cdf_P(i);
+ double Qi = cdf_Q(i);
+ sum = Pi + Qi;
+ gsl_test_rel (sum, 1.0, tol, desc, i);
+ }
+
+}
+
+#define TEST_DISCRETE(name) do { \
+ test_discrete_cdf_P(&test_ ## name ## _pdf, &test_ ## name ## _cdf_P, &test_ ## name ## _range, "test gsl_cdf_" #name "_P (k=%d)") ; \
+ test_discrete_cdf_Q(&test_ ## name ## _pdf, &test_ ## name ## _cdf_Q, &test_ ## name ## _range, "test gsl_cdf_" #name "_Q (k=%d)") ; \
+ test_discrete_cdf_PQ(&test_ ## name ## _cdf_P, &test_ ## name ## _cdf_Q, &test_ ## name ## _range, "test gsl_cdf_" #name "_P+Q (k=%d)") ; \
+} while (0);
+
+int
+main (void)
+{
+ gsl_ieee_env_setup ();
+
+ TEST_DISCRETE(binomial);
+ TEST_DISCRETE(poisson);
+ TEST_DISCRETE(geometric);
+ TEST_DISCRETE(negative_binomial);
+ TEST_DISCRETE(pascal);
+ TEST_DISCRETE(hypergeometric);
+
+#ifdef LOGARITHMIC
+ TEST_DISCRETE(logarithmic);
+#endif
+
+ /* exit (gsl_test_summary ()); */
+
+ /* Tests for gaussian cumulative distribution function
+ Function values computed with PARI, 28 digits precision */
+
+ test_ugaussian ();
+ test_exponential ();
+ test_exppow ();
+ test_tdist ();
+ test_fdist ();
+ test_gamma ();
+ test_chisq ();
+ test_beta ();
+
+ test_ugaussianinv ();
+ test_exponentialinv ();
+ test_gammainv ();
+ test_chisqinv ();
+ test_tdistinv ();
+ test_betainv ();
+ test_finv ();
+
+ test_auto_beta ();
+ test_auto_fdist ();
+ test_auto_cauchy ();
+ test_auto_gaussian ();
+ test_auto_laplace ();
+ test_auto_rayleigh ();
+ test_auto_flat ();
+ test_auto_lognormal ();
+ test_auto_gamma ();
+ test_auto_chisq ();
+ test_auto_tdist ();
+ test_auto_gumbel1 ();
+ test_auto_gumbel2 ();
+ test_auto_weibull ();
+ test_auto_pareto ();
+ test_auto_logistic ();
+ test_auto_gammalarge ();
+
+ exit (gsl_test_summary ());
+}
+
+void test_ugaussian (void)
+{
+ TEST (gsl_cdf_ugaussian_P, (0.0), 0.5, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (1e-32), 0.5, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (1e-16), 0.5000000000000000398942280401, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (1e-8), 0.5000000039894228040143267129, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (0.5), 0.6914624612740131036377046105, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (0.7), 0.7580363477769269852506495717, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (5.0), 0.9999997133484281208060883262, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (10.0), 0.9999999999999999999999923801, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (30.0), 1.000000000000000000000000000, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (40.0), 1.000000000000000000000000000, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (1e10), 1.000000000000000000000000000, TEST_TOL0);
+
+ TEST (gsl_cdf_ugaussian_P, (-1e-32), 0.5, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (-1e-16), 0.4999999999999999601057719598, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (-1e-8), 0.4999999960105771959856732870, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (-0.5), 0.3085375387259868963622953894, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (-0.7), 0.2419636522230730147493504282, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_P, (-5.0), 0.0000002866515718791939116737523329, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_P, (-10.0), 7.619853024160526065973343257e-24, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_P, (-30.0), 4.906713927148187059533809288e-198, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_P, (-1e10), 0.0, 0.0);
+
+ TEST (gsl_cdf_ugaussian_Q, (0.0), 0.5, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (1e-32), 0.5, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (1e-16), 0.4999999999999999601057719598, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (1e-8), 0.4999999960105771959856732870, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (0.5), 0.3085375387259868963622953894, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (0.7), 0.2419636522230730147493504282, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (5.0), 0.0000002866515718791939116737523329, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_Q, (10.0), 7.619853024160526065973343257e-24, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_Q, (30.0), 4.906713927148187059533809288e-198, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_Q, (1e10), 0.0, 0.0);
+
+ TEST (gsl_cdf_ugaussian_Q, (-1e-32), 0.5, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-1e-16), 0.5000000000000000398942280401, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-1e-8), 0.5000000039894228040143267129, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-0.5), 0.6914624612740131036377046105, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-0.7), 0.7580363477769269852506495717, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-5.0), 0.9999997133484281208060883262, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-10.0), 0.9999999999999999999999923801, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-30.0), 1.000000000000000000000000000, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-40.0), 1.000000000000000000000000000, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Q, (-1e10), 1.000000000000000000000000000, TEST_TOL0);
+}
+ /* Test values from Abramowitz & Stegun, Handbook of Mathematical
+ Functions, Table 26.1. Error term is given by dx = dP / Z(x) */
+
+void test_ugaussianinv (void) {
+ TEST (gsl_cdf_ugaussian_Pinv, (0.9999997133), 5.0, 1e-4);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.9999683288), 4.0, 1e-6);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.9986501020), 3.0, 1e-8);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.977249868051821), 2.0, 1e-14);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.841344746068543), 1.0, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.691462461274013), 0.5, TEST_TOL2);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.655421741610324), 0.4, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.617911422188953), 0.3, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.579259709439103), 0.2, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.539827837277029), 0.1, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Pinv, (0.5), 0.0, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Pinv, (4.60172162722971e-1), -0.1, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Pinv, (4.20740290560897e-1), -0.2, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Pinv, (3.82088577811047e-1), -0.3, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Pinv, (3.44578258389676e-1), -0.4, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Pinv, (3.08537538725987e-1), -0.5, TEST_TOL2);
+ TEST (gsl_cdf_ugaussian_Pinv, (1.58655253931457e-1), -1.0, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_Pinv, (2.2750131948179e-2), -2.0, 1e-14);
+ TEST (gsl_cdf_ugaussian_Pinv, (1.349898e-3), -3.0, 1e-8);
+ TEST (gsl_cdf_ugaussian_Pinv, (3.16712e-5), -4.0, 1e-6);
+ TEST (gsl_cdf_ugaussian_Pinv, (2.86648e-7), -5.0, 1e-4);
+
+ TEST (gsl_cdf_ugaussian_Pinv, (7.61985302416052e-24), -10.0, 1e-4);
+
+ TEST (gsl_cdf_ugaussian_Qinv, (7.61985302416052e-24), 10.0, 1e-4);
+
+ TEST (gsl_cdf_ugaussian_Qinv, (2.86648e-7), 5.0, 1e-4);
+ TEST (gsl_cdf_ugaussian_Qinv, (3.16712e-5), 4.0, 1e-6);
+ TEST (gsl_cdf_ugaussian_Qinv, (1.349898e-3), 3.0, 1e-8);
+ TEST (gsl_cdf_ugaussian_Qinv, (2.2750131948179e-2), 2.0, 1e-14);
+ TEST (gsl_cdf_ugaussian_Qinv, (1.58655253931457e-1), 1.0, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_Qinv, (3.08537538725987e-1), 0.5, TEST_TOL2);
+ TEST (gsl_cdf_ugaussian_Qinv, (3.44578258389676e-1), 0.4, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Qinv, (3.82088577811047e-1), 0.3, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Qinv, (4.20740290560897e-1), 0.2, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Qinv, (4.60172162722971e-1), 0.1, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.5), 0.0, TEST_TOL0);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.539827837277029), -0.1, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.579259709439103), -0.2, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.617911422188953), -0.3, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.655421741610324), -0.4, TEST_TOL1);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.691462461274013), -0.5, TEST_TOL2);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.841344746068543), -1.0, TEST_TOL3);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.977249868051821), -2.0, 1e-14);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.9986501020), -3.0, 1e-8);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.9999683288), -4.0, 1e-6);
+ TEST (gsl_cdf_ugaussian_Qinv, (0.9999997133), -5.0, 1e-4);
+}
+
+
+ /* Tests for exponential cumulative distribution function
+ Function values computed with PARI, 28 digits precision */
+
+void test_exponential (void)
+{
+ TEST (gsl_cdf_exponential_P, (0.1, 0.7), 1.33122100249818372e-1, TEST_TOL0);
+ TEST (gsl_cdf_exponential_P, (1e-32, 0.7), 1.42857142857142857e-32, TEST_TOL0);
+ TEST (gsl_cdf_exponential_P, (1000.0, 0.7), 1.0, TEST_TOL6);
+
+ TEST (gsl_cdf_exponential_Q, (0.1, 0.7), 8.66877899750181628e-1, TEST_TOL0);
+ TEST (gsl_cdf_exponential_Q, (1e-32, 0.7), 1.0, TEST_TOL0);
+ TEST (gsl_cdf_exponential_Q, (1000.0, 0.7), 0.0, TEST_TOL6);
+}
+
+void test_exponentialinv (void) {
+ TEST (gsl_cdf_exponential_Pinv, (0.13, 0.7), 9.74834471334553546e-2, TEST_TOL0);
+ TEST (gsl_cdf_exponential_Pinv, (1.42e-32, 0.7), 9.94000000000000000e-33, TEST_TOL0);
+
+ TEST (gsl_cdf_exponential_Qinv, (0.86, 0.7), 1.05576022814208545e-1, TEST_TOL0);
+ TEST (gsl_cdf_exponential_Qinv, (0.99999, 0.7), 7.00003500023333508e-6, TEST_TOL6);
+}
+
+
+
+void test_exppow (void)
+{
+ TEST (gsl_cdf_exppow_P, (-1000.0, 0.7, 1.8), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_exppow_P, (-0.1, 0.7, 1.8), 0.4205349082867515493458053850, TEST_TOL0);
+ TEST (gsl_cdf_exppow_P, (-1e-32, 0.7, 1.8), 0.4999999999999999999999999999, TEST_TOL0);
+
+ TEST (gsl_cdf_exppow_P, (0.1, 0.7, 1.8), 0.5794650917132484506541946149, TEST_TOL0);
+ TEST (gsl_cdf_exppow_P, (1e-32, 0.7, 1.8), 0.5, TEST_TOL0);
+ TEST (gsl_cdf_exppow_P, (1000.0, 0.7, 1.8), 0.9999999999999999999999956212, TEST_TOL6);
+
+ TEST (gsl_cdf_exppow_Q, (-1000.0, 0.7, 1.8), 0.9999999999999999999999956212, TEST_TOL6);
+ TEST (gsl_cdf_exppow_Q, (-0.1, 0.7, 1.8), 0.5794650917132484506541946149, TEST_TOL0);
+ TEST (gsl_cdf_exppow_Q, (-1e-32, 0.7, 1.8), 0.5, TEST_TOL0);
+
+ TEST (gsl_cdf_exppow_Q, (0.1, 0.7, 1.8), 0.4205349082867515493458053850, TEST_TOL0);
+ TEST (gsl_cdf_exppow_Q, (1e-32, 0.7, 1.8), 0.4999999999999999999999999999, TEST_TOL0);
+ TEST (gsl_cdf_exppow_Q, (1000.0, 0.7, 1.8), 0.0, TEST_TOL6);
+}
+
+
+ /* Tests for student's T distribution */
+
+ /* p(x,nu) = (1/2)*(1+sign(x)*betaI(x^2/(nu+x^2),1/2,nu/2))
+ q(x,nu) = (1/2)*(1-sign(x)*betaI(x^2/(nu+x^2),1/2,nu/2)) */
+
+void test_tdist (void) {
+ TEST (gsl_cdf_tdist_P, (0.0, 1.0), 0.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1e-100, 1.0), 0.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.001, 1.0), 5.00318309780080559e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.01, 1.0), 5.03182992764908255e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.1, 1.0), 5.31725517430553569e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.325, 1.0), 6.00023120032852123e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1.0, 1.0), 0.75000000000000000e0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1.5, 1.0), 8.12832958189001183e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (2.0, 1.0), 8.52416382349566726e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (10.0, 1.0), 9.68274482569446430e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (20.0, 1.0), 9.84097748743823625e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (100.0, 1.0), 9.96817007235091745e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1000.0, 1.0), 9.99681690219919441e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (10000.0, 1.0), 9.99968169011487724e-1, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Q, (0.0, 1.0), 0.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1e-100, 1.0), 0.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.001, 1.0), 4.99681690219919441e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.01, 1.0), 4.96817007235091745e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.1, 1.0), 4.68274482569446430e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.325, 1.0), 3.99976879967147876e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1.0, 1.0), 2.5e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1.5, 1.0), 1.87167041810998816e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (2.0, 1.0), 1.47583617650433274e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (10.0, 1.0), 3.17255174305535695e-2, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (20.0, 1.0), 1.59022512561763752e-2, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (100.0, 1.0), 3.18299276490825515e-3, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1000.0, 1.0), 3.18309780080558939e-4, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (10000.0, 1.0), 3.18309885122757724e-5, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_P, (-1e-100, 1.0), 0.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.001, 1.0), 4.99681690219919441e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.01, 1.0), 4.96817007235091744e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.1, 1.0), 4.68274482569446430e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.325, 1.0), 3.99976879967147876e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1.0, 1.0), 0.25, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1.5, 1.0), 1.87167041810998816e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-2.0, 1.0), 1.47583617650433274e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-10.0, 1.0), 3.17255174305535695e-2, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-20.0, 1.0), 1.59022512561763751e-2, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-100.0, 1.0), 3.18299276490825514e-3, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1000.0, 1.0), 3.18309780080558938e-4, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-10000.0, 1.0), 3.18309885122757724e-5, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Q, (-1e-100, 1.0), 0.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.001, 1.0), 5.00318309780080559e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.01, 1.0), 5.03182992764908255e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.1, 1.0), 5.31725517430553570e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.325, 1.0), 6.00023120032852124e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1.0, 1.0), 7.5e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1.5, 1.0), 8.12832958189001184e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-2.0, 1.0), 8.52416382349566726e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-10.0, 1.0), 9.68274482569446430e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-20.0, 1.0), 9.84097748743823625e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-100.0, 1.0), 9.96817007235091745e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1000.0, 1.0), 9.99681690219919441e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-10000.0, 1.0), 9.99968169011487724e-1, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_P, (0.0, 2.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1e-100, 2.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.001, 2.0), 5.00353553302204959e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.01, 2.0), 5.03535445520899514e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.1, 2.0), 5.35267280792929913e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.325, 2.0), 6.11985772746873767e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1.0, 2.0), 7.88675134594812882e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1.5, 2.0), 8.63803437554499460e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (2.0, 2.0), 9.08248290463863016e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (10.0, 2.0), 9.95073771488337154e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (20.0, 2.0), 9.98754668053816452e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (100.0, 2.0), 9.99950007498750219e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1000.0, 2.0), 9.99999500000749945e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (10000.0, 2.0), 9.999999950000000739e-01, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Q, (0.0, 2.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1e-100, 2.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.001, 2.0), 4.99646446697795041e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.01, 2.0), 4.96464554479100486e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.1, 2.0), 4.64732719207070087e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.325, 2.0), 3.88014227253126233e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1.0, 2.0), 2.11324865405187118e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1.5, 2.0), 1.36196562445500540e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (2.0, 2.0), 9.17517095361369836e-2, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (10.0, 2.0), 4.92622851166284542e-3, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (20.0, 2.0), 1.24533194618354849e-3, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (100.0, 2.0), 4.99925012497812894e-5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1000.0, 2.0), 4.99999250001249998e-7, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (10000.0, 2.0), 4.99999992500000125e-9, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_P, (-1e-100, 2.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.001, 2.0), 4.99646446697795041e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.01, 2.0), 4.96464554479100486e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.1, 2.0), 4.64732719207070087e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.325, 2.0), 3.88014227253126233e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1.0, 2.0), 2.11324865405187118e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1.5, 2.0), 1.36196562445500540e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-2.0, 2.0), 9.17517095361369836e-02, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-10.0, 2.0), 4.92622851166284542e-03, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-20.0, 2.0), 1.24533194618354849e-03, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-100.0, 2.0), 4.99925012497812894e-05, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1000.0, 2.0), 4.99999250001249998e-07, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-10000.0, 2.0), 4.99999992500000125e-09, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Q, (-1e-100, 2.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.001, 2.0), 5.00353553302204959e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.01, 2.0), 5.03535445520899514e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.1, 2.0), 5.35267280792929913e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.325, 2.0), 6.11985772746873767e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1.0, 2.0), 7.88675134594812882e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1.5, 2.0), 8.63803437554499460e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-2.0, 2.0), 9.08248290463863016e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-10.0, 2.0), 9.95073771488337155e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-20.0, 2.0), 9.98754668053816452e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-100.0, 2.0), 9.99950007498750219e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1000.0, 2.0), 9.99999500000749999e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-10000.0, 2.0), 9.99999995000000075e-1, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_P, (0.0, 300.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1e-100, 300.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.001, 300.0), 5.00398609900942949e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.01, 300.0), 5.03986033020559088e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.1, 300.0), 5.39794441177768194e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (0.325, 300.0), 6.27296201542523812e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1.0, 300.0), 8.40941797784686861e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1.5, 300.0), 9.32666983425369137e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (2.0, 300.0), 9.76799239508425455e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (10.0, 300.0), 1.00000000000000000e+00, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (20.0, 300.0), 1.00000000000000000e+00, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (100.0, 300.0), 1.00000000000000000e+00, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (1000.0, 300.0), 1.00000000000000000e+00, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (10000.0, 300.0), 1.00000000000000000e+00, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Q, (0.0, 300.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1e-100, 300.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.001, 300.0), 4.99601390099057051e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.01, 300.0), 4.96013966979440912e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.1, 300.0), 4.60205558822231806e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (0.325, 300.0), 3.72703798457476188e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1.0, 300.0), 1.59058202215313138e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1.5, 300.0), 6.73330165746308628e-2, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (2.0, 300.0), 2.32007604915745452e-2, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (10.0, 300.0), 8.279313677e-21, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (20.0, 300.0), 1.93159812815803978e-57, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (100.0, 300.0), 1.02557519997736154e-232, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (1000.0, 300.0), 0.00000000000000000e+00, 0.0);
+ TEST (gsl_cdf_tdist_Q, (10000.0, 300.0), 0.00000000000000000e+00, 0.0);
+
+ TEST (gsl_cdf_tdist_P, (-1e-100, 300.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.001, 300.0), 4.99601390099057051e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.01, 300.0), 4.96013966979440912e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.1, 300.0), 4.60205558822231806e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-0.325, 300.0), 3.72703798457476188e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1.0, 300.0), 1.59058202215313138e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1.5, 300.0), 6.73330165746308628e-02, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-2.0, 300.0), 2.32007604915745452e-02, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-10.0, 300.0), 8.279313675556272534e-21, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-20.0, 300.0), 1.93159812815803978e-57, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-100.0, 300.0), 1.02557519997736154e-232, TEST_TOL6);
+ TEST (gsl_cdf_tdist_P, (-1000.0, 300.0), 0.0, 0.0);
+ TEST (gsl_cdf_tdist_P, (-10000.0, 300.0), 0.0, 0.0);
+
+ TEST (gsl_cdf_tdist_Q, (-1e-100, 300.0), 5.00000000000000000e-01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.001, 300.0), 5.00398609900942949e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.01, 300.0), 5.03986033020559088e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.1, 300.0), 5.39794441177768194e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-0.325, 300.0), 6.27296201542523812e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1.0, 300.0), 8.40941797784686862e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1.5, 300.0), 9.32666983425369137e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-2.0, 300.0), 9.76799239508425455e-1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-10.0, 300.0), 1.000000000000000000e0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-20.0, 300.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-100.0, 300.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-1000.0, 300.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Q, (-10000.0, 300.0), 1.0, TEST_TOL6);
+}
+
+ /* Tests for F distribution */
+
+ /* p(x, nu1, nu2) := betaI(1 / (1 + nu2 / nu1 * x), nu1 / 2, nu2 / 2) */
+
+void test_fdist (void) {
+ TEST (gsl_cdf_fdist_P, (0.0, 1.2, 1.3), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_P, (1e-100, 1.2, 1.3), 6.98194275525039002e-61, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.001, 1.2, 1.3), 1.10608485860238564e-2, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.01, 1.2, 1.3), 4.38636757068313850e-2, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.1, 1.2, 1.3), 1.68242392712840734e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.325, 1.2, 1.3), 3.14130045246195449e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1.0, 1.2, 1.3), 5.09630779074755253e-01, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1.5, 1.2, 1.3), 5.83998640641553852e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (2.0, 1.2, 1.3), 6.34733581351938787e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (10.0, 1.2, 1.3), 8.48446237879200975e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (20.0, 1.2, 1.3), 9.00987726336875039e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (100.0, 1.2, 1.3), 9.64489127047688435e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1000.0, 1.2, 1.3), 9.92012051694116388e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (10000.0, 1.2, 1.3), 9.98210862808842585e-1, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Q, (0.0, 1.2, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1e-100, 1.2, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.001, 1.2, 1.3), 9.88939151413976144e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.01, 1.2, 1.3), 9.56136324293168615e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.1, 1.2, 1.3), 8.31757607287159265e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.325, 1.2, 1.3), 6.85869954753804551e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1.0, 1.2, 1.3), 4.90369220925244747e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1.5, 1.2, 1.3), 4.16001359358446148e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (2.0, 1.2, 1.3), 3.65266418648061213e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (10.0, 1.2, 1.3), 1.51553762120799025e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (20.0, 1.2, 1.3), 9.90122736631249612e-2, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (100.0, 1.2, 1.3), 3.55108729523115643e-2, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1000.0, 1.2, 1.3), 7.98794830588361109e-3, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (10000.0, 1.2, 1.3), 1.7891371911574145e-3, TEST_TOL6);
+
+
+ TEST (gsl_cdf_fdist_P, (0.0, 500.0, 1.3), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_P, (1e-100, 500.0, 1.3), 0.0, 0.0);
+
+ TEST (gsl_cdf_fdist_P, (0.001, 500.0, 1.3), 9.83434460393304765e-141, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.01, 500.0, 1.3), 1.45915624888550014e-26, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.1, 500.0, 1.3), 5.89976509619688165e-4, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.325, 500.0, 1.3), 6.86110486051542533e-2, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1.0, 500.0, 1.3), 3.38475053806404615e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1.5, 500.0, 1.3), 4.52016245247457422e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (2.0, 500.0, 1.3), 5.27339068937388798e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (10.0, 500.0, 1.3), 8.16839628578413905e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (20.0, 500.0, 1.3), 8.81784623056911406e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (100.0, 500.0, 1.3), 9.58045057204221295e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1000.0, 500.0, 1.3), 9.90585749380655275e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (10000.0, 500.0, 1.3), 9.97891924831461387e-1, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Q, (0.0, 500.0, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1e-100, 500.0, 1.3), 1.0, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Q, (0.001, 500.0, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.01, 500.0, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.1, 500.0, 1.3), 9.99410023490380312e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.325, 500.0, 1.3), 9.31388951394845747e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1.0, 500.0, 1.3), 6.61524946193595385e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1.5, 500.0, 1.3), 5.47983754752542572e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (2.0, 500.0, 1.3), 4.72660931062611202e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (10.0, 500.0, 1.3), 1.83160371421586096e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (20.0, 500.0, 1.3), 1.18215376943088595e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (100.0, 500.0, 1.3), 4.19549427957787016e-2, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1000.0, 500.0, 1.3), 9.41425061934473424e-3, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (10000.0, 500.0, 1.3), 2.10807516853862603e-3, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_P, (0.0, 1.2, 500.0), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_P, (1e-100, 1.2, 500.0), 8.23342055585482999e-61, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.001, 1.2, 500.0), 1.30461496441289529e-2, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.01, 1.2, 500.0), 5.18324224608033294e-2, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.1, 1.2, 500.0), 2.02235101716076289e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.325, 1.2, 500.0), 3.90502983219393749e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1.0, 1.2, 500.0), 6.67656191574653619e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1.5, 1.2, 500.0), 7.75539230271467054e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (2.0, 1.2, 500.0), 8.45209114904613705e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (10.0, 1.2, 500.0), 9.99168017659120988e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (20.0, 1.2, 500.0), 9.99998005738371669e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (100.0, 1.2, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1000.0, 1.2, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (10000.0, 1.2, 500.0), 1.0, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Q, (0.0, 1.2, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1e-100, 1.2, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.001, 1.2, 500.0), 9.86953850355871047e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.01, 1.2, 500.0), 9.48167577539196671e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.1, 1.2, 500.0), 7.97764898283923711e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.325, 1.2, 500.0), 6.09497016780606251e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1.0, 1.2, 500.0), 3.32343808425346381e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1.5, 1.2, 500.0), 2.24460769728532946e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (2.0, 1.2, 500.0), 1.54790885095386295e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (10.0, 1.2, 500.0), 8.3198234087901168e-4, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (20.0, 1.2, 500.0), 1.99426162833131e-6, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (100.0, 1.2, 500.0), 6.23302662288217117e-25, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1000.0, 1.2, 500.0), 1.14328577259666930e-134, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (10000.0, 1.2, 500.0), 0.0, 0.0);
+
+
+ TEST (gsl_cdf_fdist_P, (0.0, 200.0, 500.0), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_P, (1e-100, 200.0, 500.0), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_P, (0.001, 200.0, 500.0), 4.09325080403669893e-251, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.01, 200.0, 500.0), 1.17894325419628688e-151, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.1, 200.0, 500.0), 5.92430940796861258e-57, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (0.325, 200.0, 500.0), 3.18220452357263554e-18, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1.0, 200.0, 500.0), 5.06746326121168266e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1.5, 200.0, 500.0), 9.99794175718712438e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (2.0, 200.0, 500.0), 9.99999999528236152e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (10.0, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (20.0, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (100.0, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (1000.0, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_P, (10000.0, 200.0, 500.0), 1.0, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Q, (0.0, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1e-100, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.001, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.01, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.1, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (0.325, 200.0, 500.0), 9.99999999999999997e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1.0, 200.0, 500.0), 4.93253673878831734e-1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1.5, 200.0, 500.0), 2.05824281287561795e-4, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (2.0, 200.0, 500.0), 4.71763848371410786e-10, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (10.0, 200.0, 500.0), 5.98048337181948436e-96, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (20.0, 200.0, 500.0), 2.92099265879979502e-155, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Q, (1000.0, 200.0, 500.0), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_Q, (10000.0, 200.0, 500.0), 0.0, 0.0);
+}
+
+void test_finv (void) {
+ TEST (gsl_cdf_fdist_Pinv, (0.0, 1.2, 1.3), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_Pinv, ( 6.98194275525039002e-61, 1.2, 1.3), 1e-100, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.10608485860238564e-2, 1.2, 1.3), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 4.38636757068313850e-2, 1.2, 1.3), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.68242392712840734e-1, 1.2, 1.3), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 3.14130045246195449e-1, 1.2, 1.3), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 5.09630779074755253e-01, 1.2, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 5.83998640641553852e-1, 1.2, 1.3), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 6.34733581351938787e-1, 1.2, 1.3), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 8.48446237879200975e-1, 1.2, 1.3), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.00987726336875039e-1, 1.2, 1.3), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.64489127047688435e-1, 1.2, 1.3), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.92012051694116388e-1, 1.2, 1.3), 1000.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.98210862808842585e-1, 1.2, 1.3), 10000.0, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Qinv, ( 1.0, 1.2, 1.3), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 9.88939151413976144e-1, 1.2, 1.3), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 9.56136324293168615e-1, 1.2, 1.3), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 8.31757607287159265e-1, 1.2, 1.3), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 6.85869954753804551e-1, 1.2, 1.3), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 4.90369220925244747e-1, 1.2, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 4.16001359358446148e-1, 1.2, 1.3), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 3.65266418648061213e-1, 1.2, 1.3), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 1.51553762120799025e-1, 1.2, 1.3), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 9.90122736631249612e-2, 1.2, 1.3), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 3.55108729523115643e-2, 1.2, 1.3), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 7.98794830588361109e-3, 1.2, 1.3), 1000.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 1.7891371911574145e-3, 1.2, 1.3), 10000.0, TEST_TOL6);
+
+
+ TEST (gsl_cdf_fdist_Pinv, ( 0.0, 500.0, 1.3), 0.0, 0.0);
+
+ TEST (gsl_cdf_fdist_Pinv, ( 9.83434460393304765e-141, 500.0, 1.3), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.45915624888550014e-26, 500.0, 1.3), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 5.89976509619688165e-4, 500.0, 1.3), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 6.86110486051542533e-2, 500.0, 1.3), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 3.38475053806404615e-1, 500.0, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 4.52016245247457422e-1, 500.0, 1.3), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 5.27339068937388798e-1, 500.0, 1.3), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 8.16839628578413905e-1, 500.0, 1.3), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 8.81784623056911406e-1, 500.0, 1.3), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.58045057204221295e-1, 500.0, 1.3), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.90585749380655275e-1, 500.0, 1.3), 1000.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.97891924831461387e-1, 500.0, 1.3), 10000.0, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Qinv, ( 1.0, 500.0, 1.3), 0.0, TEST_TOL6);
+
+ /*
+ * The algorithm currently implemented in gsl_cdf_fdist_Qinv and Pinv
+ * are not accurate for very large degrees of freedom, so the tests
+ * here are commented out. Another algorithm more suitable for
+ * these extreme values might pass these tests.
+ */
+
+ TEST (gsl_cdf_fdist_Qinv, ( 9.99410023490380312e-1, 500.0, 1.3), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 9.31388951394845747e-1, 500.0, 1.3), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 6.61524946193595385e-1, 500.0, 1.3), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 5.47983754752542572e-1, 500.0, 1.3), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 4.72660931062611202e-1, 500.0, 1.3), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 1.83160371421586096e-1, 500.0, 1.3), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 1.18215376943088595e-1, 500.0, 1.3), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 4.19549427957787016e-2, 500.0, 1.3), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 9.41425061934473424e-3, 500.0, 1.3), 1000.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 2.10807516853862603e-3, 500.0, 1.3), 10000.0, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Pinv, ( 0.0, 1.2, 500.0), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_Pinv, ( 8.23342055585482999e-61, 1.2, 500.0), 1e-100, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.30461496441289529e-2, 1.2, 500.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 5.18324224608033294e-2, 1.2, 500.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 2.02235101716076289e-1, 1.2, 500.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 3.90502983219393749e-1, 1.2, 500.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 6.67656191574653619e-1, 1.2, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 7.75539230271467054e-1, 1.2, 500.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 8.45209114904613705e-1, 1.2, 500.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.99168017659120988e-1, 1.2, 500.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.99998005738371669e-1, 1.2, 500.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.0, 1.2, 500.0), GSL_POSINF, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.0, 1.2, 500.0), GSL_POSINF, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.0, 1.2, 500.0), GSL_POSINF, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Qinv, ( 1.0, 1.2, 500.0), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 9.86953850355871047e-1, 1.2, 500.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 9.48167577539196671e-1, 1.2, 500.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 7.97764898283923711e-1, 1.2, 500.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 6.09497016780606251e-1, 1.2, 500.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 3.32343808425346381e-1, 1.2, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 2.24460769728532946e-1, 1.2, 500.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 1.54790885095386295e-1, 1.2, 500.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 8.3198234087901168e-4, 1.2, 500.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 1.99426162833131e-6, 1.2, 500.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 6.23302662288217117e-25, 1.2, 500.0), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 1.14328577259666930e-134, 1.2, 500.0), 1000.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 0.0, 1.2, 500.0), GSL_POSINF, 0.0);
+
+ TEST (gsl_cdf_fdist_Pinv, ( 0.0, 200.0, 500.0), 0.0, 0.0);
+ TEST (gsl_cdf_fdist_Pinv, ( 4.09325080403669893e-251, 200.0, 500.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.17894325419628688e-151, 200.0, 500.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 5.92430940796861258e-57, 200.0, 500.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 3.18220452357263554e-18, 200.0, 500.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 5.06746326121168266e-1, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 9.99794175718712438e-1, 200.0, 500.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Pinv, ( 1.0, 200.0, 500.0), GSL_POSINF, TEST_TOL6);
+
+ TEST (gsl_cdf_fdist_Qinv, ( 1.0, 200.0, 500.0), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 4.93253673878831734e-1, 200.0, 500.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 2.05824281287561795e-4, 200.0, 500.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 4.71763848371410786e-10, 200.0, 500.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 5.98048337181948436e-96, 200.0, 500.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 2.92099265879979502e-155, 200.0, 500.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_fdist_Qinv, ( 0.0, 200.0, 500.0), GSL_POSINF, 0.0);
+
+ TEST (gsl_cdf_fdist_Pinv, (0.95,1.0,261.0), 3.8773340322508720313e+00, TEST_TOL3);
+}
+
+ /* Tests for gamma distribution */
+
+ /* p(x, a, b) := gammaP(b, x / a) */
+
+void test_gamma (void)
+{
+ TEST (gsl_cdf_gamma_P, (0.0, 1.0, 1.0), 0.0, 0.0);
+ TEST (gsl_cdf_gamma_P, (1e-100, 1.0, 1.0), 1e-100, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.001, 1.0, 1.0), 9.99500166625008332e-4, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.01, 1.0, 1.0), 9.95016625083194643e-3, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.1, 1.0, 1.0), 9.51625819640404268e-2, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.325, 1.0, 1.0), 2.77472646357927811e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1.0, 1.0, 1.0), 6.32120558828557678e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1.5, 1.0, 1.0), 7.76869839851570171e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (2.0, 1.0, 1.0), 8.64664716763387308e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (10.0, 1.0, 1.0), 9.99954600070237515e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (20.0, 1.0, 1.0), 9.99999997938846378e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (100.0, 1.0, 1.0), 1e0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1000.0, 1.0, 1.0), 1e0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (10000.0, 1.0, 1.0), 1e0, TEST_TOL6);
+
+ TEST (gsl_cdf_gamma_Q, (0.0, 1.0, 1.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1e-100, 1.0, 1.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.001, 1.0, 1.0), 9.99000499833374992e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.01, 1.0, 1.0), 9.90049833749168054e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.1, 1.0, 1.0), 9.04837418035959573e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.325, 1.0, 1.0), 7.22527353642072189e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1.0, 1.0, 1.0), 3.67879441171442322e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1.5, 1.0, 1.0), 2.23130160148429829e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (2.0, 1.0, 1.0), 1.35335283236612692e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (10.0, 1.0, 1.0), 4.53999297624848515e-5, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (20.0, 1.0, 1.0), 2.06115362243855783e-9, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (100.0, 1.0, 1.0), 3.72007597602083596e-44, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1000.0, 1.0, 1.0), 0.0, 0.0);
+ TEST (gsl_cdf_gamma_Q, (10000.0, 1.0, 1.0), 0.0, 0.0);
+
+ TEST (gsl_cdf_gamma_P, (0.0, 1.0, 10.0), 0.0, 0.0);
+ TEST (gsl_cdf_gamma_P, (1e-100, 1.0, 10.0), 1e-101, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.001, 1.0, 10.0), 9.99950001666625001e-5, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.01, 1.0, 10.0), 9.99500166625008332e-4, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.1, 1.0, 10.0), 9.95016625083194643e-3, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.325, 1.0, 10.0), 3.19775501686939529e-2, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1.0, 1.0, 10.0), 9.51625819640404268e-2, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1.5, 1.0, 10.0), 1.39292023574942193e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (2.0, 1.0, 10.0), 1.81269246922018141e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (10.0, 1.0, 10.0), 6.32120558828557678e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (20.0, 1.0, 10.0), 8.64664716763387308e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (100.0, 1.0, 10.0), 9.99954600070237515e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1000.0, 1.0, 10.0), 1e0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (10000.0, 1.0, 10.0), 1e0, TEST_TOL6);
+
+ TEST (gsl_cdf_gamma_Q, (0.0, 1.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1e-100, 1.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.001, 1.0, 10.0), 9.99900004999833337e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.01, 1.0, 10.0), 9.99000499833374992e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.1, 1.0, 10.0), 9.90049833749168054e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.325, 1.0, 10.0), 9.68022449831306047e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1.0, 1.0, 10.0), 9.04837418035959573e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1.5, 1.0, 10.0), 8.60707976425057807e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (2.0, 1.0, 10.0), 8.18730753077981859e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (10.0, 1.0, 10.0), 3.67879441171442322e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (20.0, 1.0, 10.0), 1.35335283236612692e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (100.0, 1.0, 10.0), 4.53999297624848515e-5, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1000.0, 1.0, 10.0), 3.72007597602083596e-44, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (10000.0, 1.0, 10.0), 0.0, 0.0);
+
+ TEST (gsl_cdf_gamma_P, (0.0, 17.0, 10.0), 0e0, 0.0);
+ TEST (gsl_cdf_gamma_P, (1e-100, 17.0, 10.0), 0e0, 0.0);
+ TEST (gsl_cdf_gamma_P, (0.001, 17.0, 10.0), 2.81119174040422844e-83, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.01, 17.0, 10.0), 2.80880324651985887e-66, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.1, 17.0, 10.0), 2.78502998087492130e-49, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (0.325, 17.0, 10.0), 1.37283653245125844e-40, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1.0, 17.0, 10.0), 2.55811932292544243e-32, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1.5, 17.0, 10.0), 2.40420441175422372e-29, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (2.0, 17.0, 10.0), 3.05092926217898577e-27, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (10.0, 17.0, 10.0), 1.094920130378183e-15, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (20.0, 17.0, 10.0), 5.60605096173161688e-11, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (100.0, 17.0, 10.0), 2.70416097848011280e-2, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (1000.0, 17.0, 10.0), 1.000000000000000000e0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_P, (10000.0, 17.0, 10.0), 1.000000000000000000e0, TEST_TOL6);
+
+ TEST (gsl_cdf_gamma_Q, (0.0, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1e-100, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.001, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.01, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.1, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (0.325, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1.0, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1.5, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (2.0, 17.0, 10.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (10.0, 17.0, 10.0), 9.99999999999998905e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (20.0, 17.0, 10.0), 9.99999999943939490e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (100.0, 17.0, 10.0), 9.72958390215198872e-1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (1000.0, 17.0, 10.0), 2.11200951633948570e-25, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Q, (10000.0, 17.0, 10.0), 0.0, 0.0);
+}
+
+void test_chisq (void) {
+ TEST (gsl_cdf_chisq_P, (0.0, 13.0), 0.0, 0.0);
+ TEST (gsl_cdf_chisq_P, (1e-100, 13.0), 0.0, 0.0);
+ TEST (gsl_cdf_chisq_P, (0.001, 13.0), 1.86631102655845996e-25, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (0.01, 13.0), 5.87882248504529790e-19, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (0.1, 13.0), 1.78796983358555410e-12, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (0.325, 13.0), 3.44611313779905183e-9, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (1.0, 13.0), 3.83473473513595154e-6, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (1.5, 13.0), 4.31718389201041932e-5, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (2.0, 13.0), 2.26250084656047180e-4, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (10.0, 13.0), 3.06065632019251110e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (20.0, 13.0), 9.04789743921908487e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (100.0, 13.0), 9.99999999999998341e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (1000.0, 13.0), 1e0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_P, (10000.0, 13.0), 1e0, TEST_TOL6);
+
+ TEST (gsl_cdf_chisq_Q, (0.0, 13.0), 1e0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (1e-100, 13.0), 1e0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (0.001, 13.0), 1e0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (0.01, 13.0), 9.99999999999999999e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (0.1, 13.0), 9.99999999998212030e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (0.325, 13.0), 9.99999996553886862e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (1.0, 13.0), 9.99996165265264864e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (1.5, 13.0), 9.99956828161079896e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (2.0, 13.0), 9.99773749915343953e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (10.0, 13.0), 6.93934367980748890e-1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (20.0, 13.0), 9.52102560780915127e-2, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (100.0, 13.0), 1.65902608070858809e-15, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (1000.0, 13.0), 1.74851191544860225e-205, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Q, (10000.0, 13.0), 0.0, 0.0);
+}
+
+
+ /* Beta distribution */
+
+void test_beta (void) {
+ TEST (gsl_cdf_beta_P, (0.0, 1.2, 1.3), 0.0, 0.0);
+ TEST (gsl_cdf_beta_P, (1e-100, 1.2, 1.3), 1.34434944656489596e-120, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (0.001, 1.2, 1.3), 3.37630042504535813e-4, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (0.01, 1.2, 1.3), 5.34317264038929473e-3, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (0.1, 1.2, 1.3), 8.33997828306748346e-2, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (0.325, 1.2, 1.3), 3.28698654180583916e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (0.5, 1.2, 1.3), 5.29781429451299081e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (0.9, 1.2, 1.3), 9.38529397224430659e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (0.99, 1.2, 1.3), 9.96886438341254380e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (0.999, 1.2, 1.3), 9.99843792833067634e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_P, (1.0, 1.2, 1.3), 1.0, TEST_TOL6);
+
+ TEST (gsl_cdf_beta_Q, (0.0, 1.2, 1.3), 1.0, 0.0);
+ TEST (gsl_cdf_beta_Q, (1e-100, 1.2, 1.3), 1e0, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (0.001, 1.2, 1.3), 9.99662369957495464e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (0.01, 1.2, 1.3), 9.94656827359610705e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (0.1, 1.2, 1.3), 9.16600217169325165e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (0.325, 1.2, 1.3), 6.71301345819416084e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (0.5, 1.2, 1.3), 4.70218570548700919e-1, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (0.9, 1.2, 1.3), 6.14706027755693408e-2, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (0.99, 1.2, 1.3), 3.11356165874561958e-3, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (0.999, 1.2, 1.3), 1.56207166932365759e-4, TEST_TOL6);
+ TEST (gsl_cdf_beta_Q, (1.0, 1.2, 1.3), 0.0, TEST_TOL6);
+}
+
+void test_betainv (void) {
+ TEST (gsl_cdf_beta_Pinv, (0.0, 1.2, 1.3), 0.0, 0.0);
+ TEST (gsl_cdf_beta_Pinv, ( 1.34434944656489596e-120, 1.2, 1.3), 1e-100, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 3.37630042504535813e-4, 1.2, 1.3), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 5.34317264038929473e-3, 1.2, 1.3), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 8.33997828306748346e-2, 1.2, 1.3), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 3.28698654180583916e-1, 1.2, 1.3), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 5.29781429451299081e-1, 1.2, 1.3), 0.5, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 9.38529397224430659e-1, 1.2, 1.3), 0.9, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 9.96886438341254380e-1, 1.2, 1.3), 0.99, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 9.99843792833067634e-1, 1.2, 1.3), 0.999, TEST_TOL6);
+ TEST (gsl_cdf_beta_Pinv, ( 1.0, 1.2, 1.3), 1.0, TEST_TOL6);
+
+ TEST (gsl_cdf_beta_Qinv, ( 1.0, 1.2, 1.3), 0.0, 0.0);
+ TEST (gsl_cdf_beta_Qinv, ( 1e0, 1.2, 1.3), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 9.99662369957495464e-1, 1.2, 1.3), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 9.94656827359610705e-1, 1.2, 1.3), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 9.16600217169325165e-1, 1.2, 1.3), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 6.71301345819416084e-1, 1.2, 1.3), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 4.70218570548700919e-1, 1.2, 1.3), 0.5, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 6.14706027755693408e-2, 1.2, 1.3), 0.9, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 3.11356165874561958e-3, 1.2, 1.3), 0.99, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 1.56207166932365759e-4, 1.2, 1.3), 0.999, TEST_TOL6);
+ TEST (gsl_cdf_beta_Qinv, ( 0.0, 1.2, 1.3), 1.0, TEST_TOL6);
+}
+
+void test_gammainv (void) {
+ TEST (gsl_cdf_gamma_Pinv, (0.0, 1.0, 1.0), 0.0, 0.0);
+ TEST (gsl_cdf_gamma_Pinv, (1e-100, 1.0, 1.0), 1e-100, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (9.99500166625008332e-4, 1.0, 1.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (9.95016625083194643e-3, 1.0, 1.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (9.51625819640404268e-2, 1.0, 1.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (2.77472646357927811e-1, 1.0, 1.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (6.32120558828557678e-1, 1.0, 1.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (7.76869839851570171e-1, 1.0, 1.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (8.64664716763387308e-1, 1.0, 1.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (9.99954600070237515e-1, 1.0, 1.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (9.99999997938846378e-1, 1.0, 1.0), 20.0, 100 * TEST_TOL6);
+ TEST (gsl_cdf_gamma_Pinv, (1.0, 1.0, 1.0), GSL_POSINF, 0.0);
+
+ TEST (gsl_cdf_gamma_Qinv, (0.0, 1.0, 1.0), GSL_POSINF, 0.0);
+ TEST (gsl_cdf_gamma_Qinv, (2.06115362243855783e-9, 1.0, 1.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (4.53999297624848515e-5, 1.0, 1.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (1.35335283236612692e-1, 1.0, 1.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (2.23130160148429829e-1, 1.0, 1.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (3.67879441171442322e-1, 1.0, 1.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (7.22527353642072189e-1, 1.0, 1.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (9.04837418035959573e-1, 1.0, 1.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (9.90049833749168054e-1, 1.0, 1.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (9.99000499833374992e-1, 1.0, 1.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_gamma_Qinv, (1.0, 1.0, 1.0), 0.0, 0.0);
+}
+
+void test_chisqinv (void) {
+ TEST (gsl_cdf_chisq_Pinv, (0.0, 13.0), 0.0, 0.0);
+ TEST (gsl_cdf_chisq_Pinv, (1.86631102655845996e-25, 13.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (5.87882248504529790e-19, 13.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (1.78796983358555410e-12, 13.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (3.44611313779905183e-9, 13.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (3.83473473513595154e-6, 13.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (4.31718389201041932e-5, 13.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (2.26250084656047180e-4, 13.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (3.06065632019251110e-1, 13.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (9.04789743921908487e-1, 13.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Pinv, (9.99999999999998341e-1, 13.0), 100.0, 0.01);
+ TEST (gsl_cdf_chisq_Pinv, (1e0, 13.0), GSL_POSINF, 0.0);
+
+ TEST (gsl_cdf_chisq_Qinv, (0.0, 13.0), GSL_POSINF, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Qinv, (1.65902608070858809e-15, 13.0), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Qinv, (9.52102560780915127e-2, 13.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Qinv, (6.93934367980748892e-1, 13.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Qinv, (9.99773749915343954e-1, 13.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Qinv, (9.99956828161079894e-1, 13.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Qinv, (9.99996165265264863e-1, 13.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_chisq_Qinv, (9.99999996553886862e-1, 13.0), 0.325, 1e-6);
+ TEST (gsl_cdf_chisq_Qinv, (9.99999999998212031e-1, 13.0), 0.1, 1e-5);
+ TEST (gsl_cdf_chisq_Qinv, (1.0, 13.0), 0.0, 0.0);
+}
+
+void test_tdistinv (void) {
+ TEST (gsl_cdf_tdist_Pinv, (0.5, 1.0), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (5.00318309780080559e-1, 1.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (5.03182992764908255e-1, 1.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (5.31725517430553569e-1, 1.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (6.00023120032852123e-1, 1.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (0.75000000000000000e0, 1.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (8.12832958189001183e-1, 1.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (8.52416382349566726e-1, 1.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (9.68274482569446430e-1, 1.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (9.84097748743823625e-1, 1.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (9.96817007235091745e-1, 1.0), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (9.99681690219919441e-1, 1.0), 1000.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (9.99968169011487724e-1, 1.0), 10000.0, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Pinv, (4.99681690219919441e-1, 1.0), -0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.96817007235091744e-1, 1.0), -0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.68274482569446430e-1, 1.0), -0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.99976879967147876e-1, 1.0), -0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (0.25, 1.0), -1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.87167041810998816e-1, 1.0), -1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.47583617650433274e-1, 1.0), -2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.17255174305535695e-2, 1.0), -10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.59022512561763751e-2, 1.0), -20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.18299276490825514e-3, 1.0), -100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.18309780080558938e-4, 1.0), -1000.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.18309885122757724e-5, 1.0), -10000.0, TEST_TOL6);
+
+
+ TEST (gsl_cdf_tdist_Qinv, (0.5, 1.0), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (4.99681690219919441e-1, 1.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (4.96817007235091745e-1, 1.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (4.68274482569446430e-1, 1.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (3.99976879967147876e-1, 1.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (2.5e-1, 1.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (1.87167041810998816e-1, 1.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (1.47583617650433274e-1, 1.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (3.17255174305535695e-2, 1.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (1.59022512561763752e-2, 1.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (3.18299276490825515e-3, 1.0), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (3.18309780080558939e-4, 1.0), 1000.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (3.18309885122757724e-5, 1.0), 10000.0, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Pinv, (4.99681690219919441e-1, 1.0), -0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.96817007235091744e-1, 1.0), -0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.68274482569446430e-1, 1.0), -0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.99976879967147876e-1, 1.0), -0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (0.25, 1.0), -1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.87167041810998816e-1, 1.0), -1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.47583617650433274e-1, 1.0), -2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.17255174305535695e-2, 1.0), -10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.59022512561763751e-2, 1.0), -20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.18299276490825514e-3, 1.0), -100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.18309780080558938e-4, 1.0), -1000.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.18309885122757724e-5, 1.0), -10000.0, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Qinv, (5.00318309780080559e-1, 1.0), -0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (5.03182992764908255e-1, 1.0), -0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (5.31725517430553570e-1, 1.0), -0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (6.00023120032852124e-1, 1.0), -0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (7.5e-1, 1.0), -1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (8.12832958189001184e-1, 1.0), -1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (8.52416382349566726e-1, 1.0), -2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.68274482569446430e-1, 1.0), -10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.84097748743823625e-1, 1.0), -20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.96817007235091745e-1, 1.0), -100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.99681690219919441e-1, 1.0), -1000.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.99968169011487724e-1, 1.0), -10000.0, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Pinv, (4.99646446697795041e-01, 2.0), -0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.96464554479100486e-01, 2.0), -0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.64732719207070087e-01, 2.0), -0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.88014227253126233e-01, 2.0), -0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (2.11324865405187118e-01, 2.0), -1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.36196562445500540e-01, 2.0), -1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (9.17517095361369836e-02, 2.0), -2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.92622851166284542e-03, 2.0), -10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.24533194618354849e-03, 2.0), -20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.99925012497812894e-05, 2.0), -100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.99999250001249998e-07, 2.0), -1000.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.99999992500000125e-09, 2.0), -10000.0, TEST_TOL6);
+
+ TEST (gsl_cdf_tdist_Qinv, (5.00353553302204959e-1, 2.0), -0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (5.03535445520899514e-1, 2.0), -0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (5.35267280792929913e-1, 2.0), -0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (6.11985772746873767e-1, 2.0), -0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (7.88675134594812882e-1, 2.0), -1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (8.63803437554499460e-1, 2.0), -1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.08248290463863016e-1, 2.0), -2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.95073771488337155e-1, 2.0), -10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.98754668053816452e-1, 2.0), -20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.99950007498750219e-1, 2.0), -100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.99999500000749999e-1, 2.0), -1000.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.99999995000000075e-1, 2.0), -10000.0, 1e-6);
+
+ TEST (gsl_cdf_tdist_Pinv, (5.00000000000000000e-01, 300.0), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (5.00398609900942949e-01, 300.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (5.03986033020559088e-01, 300.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (5.39794441177768194e-01, 300.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (6.27296201542523812e-01, 300.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (8.40941797784686861e-01, 300.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (9.32666983425369137e-01, 300.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (9.76799239508425455e-01, 300.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.00000000000000000e+00, 300.0), GSL_POSINF, 0.0);
+
+ TEST (gsl_cdf_tdist_Qinv, (5.00000000000000000e-01, 300.0), 0.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (4.99601390099057051e-1, 300.0), 0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (4.96013966979440912e-1, 300.0), 0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (4.60205558822231806e-1, 300.0), 0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (3.72703798457476188e-1, 300.0), 0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (1.59058202215313138e-1, 300.0), 1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (6.73330165746308628e-2, 300.0), 1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (2.32007604915745452e-2, 300.0), 2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (8.279313677e-21, 300.0), 10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (1.93159812815803978e-57, 300.0), 20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (1.02557519997736154e-232, 300.0), 100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (0.00000000000000000e+00, 300.0), GSL_POSINF, 0.0);
+
+ TEST (gsl_cdf_tdist_Pinv, (4.99601390099057051e-01, 300.0), -0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.96013966979440912e-01, 300.0), -0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (4.60205558822231806e-01, 300.0), -0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (3.72703798457476188e-01, 300.0), -0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.59058202215313138e-01, 300.0), -1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (6.73330165746308628e-02, 300.0), -1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (2.32007604915745452e-02, 300.0), -2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (8.279313675556272534e-21, 300.0), -10.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.93159812815803978e-57, 300.0), -20.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (1.02557519997736154e-232, 300.0), -100.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Pinv, (0.0, 300.0), GSL_NEGINF, 0.0);
+
+ TEST (gsl_cdf_tdist_Qinv, (5.00398609900942949e-1, 300.0), -0.001, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (5.03986033020559088e-1, 300.0), -0.01, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (5.39794441177768194e-1, 300.0), -0.1, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (6.27296201542523812e-1, 300.0), -0.325, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (8.40941797784686862e-1, 300.0), -1.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.32666983425369137e-1, 300.0), -1.5, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (9.76799239508425455e-1, 300.0), -2.0, TEST_TOL6);
+ TEST (gsl_cdf_tdist_Qinv, (1.000000000000000000e0, 300.0), GSL_NEGINF, TEST_TOL6);
+}
+
+
+
diff --git a/gsl-1.9/cdf/test_auto.c b/gsl-1.9/cdf/test_auto.c
new file mode 100644
index 0000000..cf6f610
--- /dev/null
+++ b/gsl-1.9/cdf/test_auto.c
@@ -0,0 +1,1464 @@
+void test_auto_beta (void);
+
+void
+test_auto_beta (void)
+{
+ TEST(gsl_cdf_beta_P, (0.0000000000000000e+00,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000000e-10,1.3,2.7), 3.329258013904e-13, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000001e-09,1.3,2.7), 6.642743046207e-12, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000000e-08,1.3,2.7), 1.325401475350e-10, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (9.9999999999999995e-08,1.3,2.7), 2.644523387276e-09, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (9.9999999999999995e-07,1.3,2.7), 5.276513292646e-08, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000001e-05,1.3,2.7), 1.052793708285e-06, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000000e-04,1.3,2.7), 2.100417958505e-05, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000000e-03,1.3,2.7), 4.187261218400e-04, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000000e-02,1.3,2.7), 8.282559388393e-03, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000001e-01,1.3,2.7), 1.512194578010e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (2.0000000000000001e-01,1.3,2.7), 3.358123280407e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (2.9999999999999999e-01,1.3,2.7), 5.104163996495e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (4.0000000000000002e-01,1.3,2.7), 6.620682399410e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (5.0000000000000000e-01,1.3,2.7), 7.852786981833e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (5.9999999999999998e-01,1.3,2.7), 8.784005878950e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (8.0000000000000004e-01,1.3,2.7), 9.801824171406e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (9.0000000000000002e-01,1.3,2.7), 9.968736852365e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (9.8999999999999999e-01,1.3,2.7), 9.999936324464e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (9.9900000000000000e-01,1.3,2.7), 9.999999872699e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (9.9990000000000001e-01,1.3,2.7), 9.999999999746e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (9.9999000000000005e-01,1.3,2.7), 9.999999999999e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_P, (1.0000000000000000e+00,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_beta_Q, (1.0000000000000000e+00,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (9.9999000000000005e-01,1.3,2.7), 5.069044353228e-14, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (9.9990000000000001e-01,1.3,2.7), 2.540490259443e-11, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (9.9900000000000000e-01,1.3,2.7), 1.273010336738e-08, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (9.8999999999999999e-01,1.3,2.7), 6.367553598351e-06, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (9.0000000000000002e-01,1.3,2.7), 3.126314763488e-03, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (8.0000000000000004e-01,1.3,2.7), 1.981758285937e-02, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (5.9999999999999998e-01,1.3,2.7), 1.215994121050e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (5.0000000000000000e-01,1.3,2.7), 2.147213018167e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (4.0000000000000002e-01,1.3,2.7), 3.379317600590e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (2.9999999999999999e-01,1.3,2.7), 4.895836003505e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (2.0000000000000001e-01,1.3,2.7), 6.641876719593e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (1.0000000000000001e-01,1.3,2.7), 8.487805421990e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (1.0000000000000000e-02,1.3,2.7), 9.917174406116e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (1.0000000000000000e-03,1.3,2.7), 9.995812738782e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (1.0000000000000000e-04,1.3,2.7), 9.999789958204e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (1.0000000000000001e-05,1.3,2.7), 9.999989472063e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (9.9999999999999995e-07,1.3,2.7), 9.999999472349e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (9.9999999999999995e-08,1.3,2.7), 9.999999973555e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (1.0000000000000000e-08,1.3,2.7), 9.999999998675e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (1.0000000000000001e-09,1.3,2.7), 9.999999999934e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (1.0000000000000000e-10,1.3,2.7), 9.999999999997e-01, TEST_TOL6);
+ TEST(gsl_cdf_beta_Q, (0.0000000000000000e+00,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_fdist (void);
+
+void
+test_auto_fdist (void)
+{
+ TEST(gsl_cdf_fdist_P, (0.0000000000000000e+00,5.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e-10,5.3,2.7), 3.231380663090e-26, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000001e-09,5.3,2.7), 1.443404714791e-23, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e-08,5.3,2.7), 6.447451698511e-21, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (9.9999999999999995e-08,5.3,2.7), 2.879969407315e-18, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (9.9999999999999995e-07,5.3,2.7), 1.286428479993e-15, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000001e-05,5.3,2.7), 5.745970138195e-13, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e-04,5.3,2.7), 2.565314230632e-10, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e-03,5.3,2.7), 1.140026203760e-07, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e-02,5.3,2.7), 4.840333162527e-05, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000001e-01,5.3,2.7), 1.360698992545e-02, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+00,5.3,2.7), 4.532720490874e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+01,5.3,2.7), 9.461328174717e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+02,5.3,2.7), 9.973356976994e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+03,5.3,2.7), 9.998797338050e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+04,5.3,2.7), 9.999946222456e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+05,5.3,2.7), 9.999997597592e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+06,5.3,2.7), 9.999999892687e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+07,5.3,2.7), 9.999999995207e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+08,5.3,2.7), 9.999999999786e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+09,5.3,2.7), 9.999999999990e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_P, (1.0000000000000000e+10,5.3,2.7), 1.000000000000e-00, TEST_TOL6);
+
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+10,5.3,2.7), 4.272202262298e-14, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+09,5.3,2.7), 9.564269502770e-13, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+08,5.3,2.7), 2.141173208523e-11, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+07,5.3,2.7), 4.793489218238e-10, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+06,5.3,2.7), 1.073127433440e-08, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+05,5.3,2.7), 2.402407758939e-07, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+04,5.3,2.7), 5.377754447932e-06, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+03,5.3,2.7), 1.202661950234e-04, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+02,5.3,2.7), 2.664302300604e-03, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+01,5.3,2.7), 5.386718252832e-02, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e+00,5.3,2.7), 5.467279509126e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000001e-01,5.3,2.7), 9.863930100746e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e-02,5.3,2.7), 9.999515966684e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e-03,5.3,2.7), 9.999998859974e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e-04,5.3,2.7), 9.999999997435e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000001e-05,5.3,2.7), 9.999999999994e-01, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (9.9999999999999995e-07,5.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (9.9999999999999995e-08,5.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e-08,5.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000001e-09,5.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (1.0000000000000000e-10,5.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_fdist_Q, (0.0000000000000000e+00,5.3,2.7), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_cauchy (void);
+
+void
+test_auto_cauchy (void)
+{
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+10,1.3), 4.138028520389e-11, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1380285203892783e-11,1.3), -1.000000000000e+10, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+09,1.3), 4.138028520389e-10, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1380285203892792e-10,1.3), -1.000000000000e+09, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+08,1.3), 4.138028520389e-09, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1380285203892787e-09,1.3), -1.000000000000e+08, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+07,1.3), 4.138028520389e-08, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1380285203892555e-08,1.3), -1.000000000000e+07, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+06,1.3), 4.138028520387e-07, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1380285203869488e-07,1.3), -1.000000000000e+06, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+05,1.3), 4.138028520156e-06, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1380285201561693e-06,1.3), -1.000000000000e+05, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+04,1.3), 4.138028497078e-05, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1380284970783855e-05,1.3), -1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+03,1.3), 4.138026189302e-04, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1380261893022424e-04,1.3), -1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+02,1.3), 4.137795435084e-03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1377954350836910e-03,1.3), -1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+01,1.3), 4.114951182497e-02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.1149511824973506e-02,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e+00,1.3), 2.912855998398e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (2.9128559983984725e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000001e-01,1.3), 4.755627480278e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.7556274802780252e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e-02,1.3), 4.975515107069e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.9755151070688325e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e-03,1.3), 4.997551462897e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (4.9975514628969159e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e-04,1.3), 4.999755146242e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000001e-05,1.3), 4.999975514624e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-9.9999999999999995e-07,1.3), 4.999997551462e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-9.9999999999999995e-08,1.3), 4.999999755146e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e-08,1.3), 4.999999975515e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000001e-09,1.3), 4.999999997551e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (-1.0000000000000000e-10,1.3), 4.999999999755e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (5.0000000000000011e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e-10,1.3), 5.000000000245e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000001e-09,1.3), 5.000000002449e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e-08,1.3), 5.000000024485e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (9.9999999999999995e-08,1.3), 5.000000244854e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (9.9999999999999995e-07,1.3), 5.000002448538e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000001e-05,1.3), 5.000024485376e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e-04,1.3), 5.000244853758e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e-03,1.3), 5.002448537103e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (5.0024485371030836e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e-02,1.3), 5.024484892931e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (5.0244848929311670e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000001e-01,1.3), 5.244372519722e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (5.2443725197219748e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+00,1.3), 7.087144001602e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (7.0871440016015275e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+01,1.3), 9.588504881750e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (9.5885048817502649e-01,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+02,1.3), 9.958622045649e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (9.9586220456491636e-01,1.3), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+03,1.3), 9.995861973811e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Pinv, (9.9958619738106980e-01,1.3), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+04,1.3), 9.999586197150e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+05,1.3), 9.999958619715e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+06,1.3), 9.999995861971e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+07,1.3), 9.999999586197e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+08,1.3), 9.999999958620e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+09,1.3), 9.999999995862e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_P, (1.0000000000000000e+10,1.3), 9.999999999586e-01, TEST_TOL6);
+
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+10,1.3), 4.138028520389e-11, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1380285203892783e-11,1.3), 1.000000000000e+10, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+09,1.3), 4.138028520389e-10, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1380285203892792e-10,1.3), 1.000000000000e+09, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+08,1.3), 4.138028520389e-09, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1380285203892787e-09,1.3), 1.000000000000e+08, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+07,1.3), 4.138028520389e-08, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1380285203892555e-08,1.3), 1.000000000000e+07, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+06,1.3), 4.138028520387e-07, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1380285203869488e-07,1.3), 1.000000000000e+06, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+05,1.3), 4.138028520156e-06, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1380285201561693e-06,1.3), 1.000000000000e+05, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+04,1.3), 4.138028497078e-05, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1380284970783855e-05,1.3), 1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+03,1.3), 4.138026189302e-04, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1380261893022424e-04,1.3), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+02,1.3), 4.137795435084e-03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1377954350836910e-03,1.3), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+01,1.3), 4.114951182497e-02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.1149511824973506e-02,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e+00,1.3), 2.912855998398e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (2.9128559983984725e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000001e-01,1.3), 4.755627480278e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.7556274802780252e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e-02,1.3), 4.975515107069e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.9755151070688325e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e-03,1.3), 4.997551462897e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (4.9975514628969159e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e-04,1.3), 4.999755146242e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000001e-05,1.3), 4.999975514624e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (9.9999999999999995e-07,1.3), 4.999997551462e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (9.9999999999999995e-08,1.3), 4.999999755146e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e-08,1.3), 4.999999975515e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000001e-09,1.3), 4.999999997551e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (1.0000000000000000e-10,1.3), 4.999999999755e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (5.0000000000000011e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e-10,1.3), 5.000000000245e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000001e-09,1.3), 5.000000002449e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e-08,1.3), 5.000000024485e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-9.9999999999999995e-08,1.3), 5.000000244854e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-9.9999999999999995e-07,1.3), 5.000002448538e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000001e-05,1.3), 5.000024485376e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e-04,1.3), 5.000244853758e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e-03,1.3), 5.002448537103e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (5.0024485371030836e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e-02,1.3), 5.024484892931e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (5.0244848929311670e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000001e-01,1.3), 5.244372519722e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (5.2443725197219748e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+00,1.3), 7.087144001602e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (7.0871440016015275e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+01,1.3), 9.588504881750e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (9.5885048817502649e-01,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+02,1.3), 9.958622045649e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (9.9586220456491636e-01,1.3), -1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+03,1.3), 9.995861973811e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Qinv, (9.9958619738106980e-01,1.3), -1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+04,1.3), 9.999586197150e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+05,1.3), 9.999958619715e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+06,1.3), 9.999995861971e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+07,1.3), 9.999999586197e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+08,1.3), 9.999999958620e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+09,1.3), 9.999999995862e-01, TEST_TOL6);
+ TEST(gsl_cdf_cauchy_Q, (-1.0000000000000000e+10,1.3), 9.999999999586e-01, TEST_TOL6);
+}
+
+void test_auto_gaussian (void);
+
+void
+test_auto_gaussian (void)
+{
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+10,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+09,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+08,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+07,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+06,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+05,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+04,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+03,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+02,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+01,1.3), 7.225229227927e-15, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (7.2252292279265077e-15,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e+00,1.3), 2.208781637125e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (2.2087816371245972e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000001e-01,1.3), 4.693423696034e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (4.6934236960338749e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e-02,1.3), 4.969312434916e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (4.9693124349158196e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e-03,1.3), 4.996931213530e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (4.9969312135303229e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e-04,1.3), 4.999693121323e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000001e-05,1.3), 4.999969312132e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-9.9999999999999995e-07,1.3), 4.999996931213e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-9.9999999999999995e-08,1.3), 4.999999693121e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e-08,1.3), 4.999999969312e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000001e-09,1.3), 4.999999996931e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (-1.0000000000000000e-10,1.3), 4.999999999693e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (5.0000000000000000e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e-10,1.3), 5.000000000307e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000001e-09,1.3), 5.000000003069e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e-08,1.3), 5.000000030688e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (9.9999999999999995e-08,1.3), 5.000000306879e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (9.9999999999999995e-07,1.3), 5.000003068787e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000001e-05,1.3), 5.000030687868e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e-04,1.3), 5.000306878677e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e-03,1.3), 5.003068786470e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (5.0030687864696777e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e-02,1.3), 5.030687565084e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (5.0306875650841798e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000001e-01,1.3), 5.306576303966e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (5.3065763039661251e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+00,1.3), 7.791218362875e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Pinv, (7.7912183628754028e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+01,1.3), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+02,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+03,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+04,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+05,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+06,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+07,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+08,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_P, (1.0000000000000000e+10,1.3), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+10,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+09,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+08,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+07,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+06,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+05,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+04,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+03,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+02,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+01,1.3), 7.225229227927e-15, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (7.2252292279265077e-15,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e+00,1.3), 2.208781637125e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (2.2087816371245972e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000001e-01,1.3), 4.693423696034e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (4.6934236960338749e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e-02,1.3), 4.969312434916e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (4.9693124349158196e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e-03,1.3), 4.996931213530e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (4.9969312135303229e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e-04,1.3), 4.999693121323e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000001e-05,1.3), 4.999969312132e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (9.9999999999999995e-07,1.3), 4.999996931213e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (9.9999999999999995e-08,1.3), 4.999999693121e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e-08,1.3), 4.999999969312e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000001e-09,1.3), 4.999999996931e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (1.0000000000000000e-10,1.3), 4.999999999693e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (5.0000000000000000e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e-10,1.3), 5.000000000307e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000001e-09,1.3), 5.000000003069e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e-08,1.3), 5.000000030688e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-9.9999999999999995e-08,1.3), 5.000000306879e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-9.9999999999999995e-07,1.3), 5.000003068787e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000001e-05,1.3), 5.000030687868e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e-04,1.3), 5.000306878677e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e-03,1.3), 5.003068786470e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (5.0030687864696777e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e-02,1.3), 5.030687565084e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (5.0306875650841798e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000001e-01,1.3), 5.306576303966e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (5.3065763039661251e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+00,1.3), 7.791218362875e-01, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Qinv, (7.7912183628754028e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+01,1.3), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+02,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+03,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+04,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+05,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+06,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+07,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+08,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gaussian_Q, (-1.0000000000000000e+10,1.3), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_laplace (void);
+
+void
+test_auto_laplace (void)
+{
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+10,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+09,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+08,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+07,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+06,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+05,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+04,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+03,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+02,1.3), 1.957501779912e-34, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (1.9575017799122328e-34,1.3), -1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+01,1.3), 2.281619502905e-04, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (2.2816195029051560e-04,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e+00,1.3), 2.316846846156e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (2.3168468461558764e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000001e-01,1.3), 4.629805393212e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (4.6298053932115801e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e-02,1.3), 4.961686011956e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (4.9616860119557432e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e-03,1.3), 4.996155325065e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (4.9961553250645546e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e-04,1.3), 4.999615399408e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000001e-05,1.3), 4.999961538609e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-9.9999999999999995e-07,1.3), 4.999996153848e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-9.9999999999999995e-08,1.3), 4.999999615385e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e-08,1.3), 4.999999961538e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000001e-09,1.3), 4.999999996154e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (-1.0000000000000000e-10,1.3), 4.999999999615e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (5.0000000000000000e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e-10,1.3), 5.000000000385e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000001e-09,1.3), 5.000000003846e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e-08,1.3), 5.000000038462e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (9.9999999999999995e-08,1.3), 5.000000384615e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (9.9999999999999995e-07,1.3), 5.000003846152e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000001e-05,1.3), 5.000038461391e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e-04,1.3), 5.000384600592e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e-03,1.3), 5.003844674935e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (5.0038446749354448e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e-02,1.3), 5.038313988044e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (5.0383139880442562e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000001e-01,1.3), 5.370194606788e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (5.3701946067884199e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+00,1.3), 7.683153153844e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (7.6831531538441233e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+01,1.3), 9.997718380497e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Pinv, (9.9977183804970948e-01,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+02,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+03,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+04,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+05,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+06,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+07,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+08,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_P, (1.0000000000000000e+10,1.3), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+10,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+09,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+08,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+07,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+06,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+05,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+04,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+03,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+02,1.3), 1.957501779912e-34, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (1.9575017799122328e-34,1.3), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+01,1.3), 2.281619502905e-04, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (2.2816195029051560e-04,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e+00,1.3), 2.316846846156e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (2.3168468461558764e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000001e-01,1.3), 4.629805393212e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (4.6298053932115801e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e-02,1.3), 4.961686011956e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (4.9616860119557432e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e-03,1.3), 4.996155325065e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (4.9961553250645546e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e-04,1.3), 4.999615399408e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000001e-05,1.3), 4.999961538609e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (9.9999999999999995e-07,1.3), 4.999996153848e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (9.9999999999999995e-08,1.3), 4.999999615385e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e-08,1.3), 4.999999961538e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000001e-09,1.3), 4.999999996154e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (1.0000000000000000e-10,1.3), 4.999999999615e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (5.0000000000000000e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e-10,1.3), 5.000000000385e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000001e-09,1.3), 5.000000003846e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e-08,1.3), 5.000000038462e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-9.9999999999999995e-08,1.3), 5.000000384615e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-9.9999999999999995e-07,1.3), 5.000003846152e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000001e-05,1.3), 5.000038461391e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e-04,1.3), 5.000384600592e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e-03,1.3), 5.003844674935e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (5.0038446749354448e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e-02,1.3), 5.038313988044e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (5.0383139880442562e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000001e-01,1.3), 5.370194606788e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (5.3701946067884199e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+00,1.3), 7.683153153844e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (7.6831531538441233e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+01,1.3), 9.997718380497e-01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Qinv, (9.9977183804970948e-01,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+02,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+03,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+04,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+05,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+06,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+07,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+08,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_laplace_Q, (-1.0000000000000000e+10,1.3), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_rayleigh (void);
+
+void
+test_auto_rayleigh (void)
+{
+ TEST(gsl_cdf_rayleigh_P, (0.0000000000000000e+00,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e-10,1.3), 2.958579881657e-21, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585798816568050e-21,1.3), 1.000000000000e-10, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000001e-09,1.3), 2.958579881657e-19, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585798816568049e-19,1.3), 1.000000000000e-09, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e-08,1.3), 2.958579881657e-17, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585798816568048e-17,1.3), 1.000000000000e-08, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (9.9999999999999995e-08,1.3), 2.958579881657e-15, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585798816568001e-15,1.3), 1.000000000000e-07, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (9.9999999999999995e-07,1.3), 2.958579881656e-13, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585798816563665e-13,1.3), 1.000000000000e-06, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000001e-05,1.3), 2.958579881613e-11, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585798816130393e-11,1.3), 1.000000000000e-05, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e-04,1.3), 2.958579877280e-09, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585798772802076e-09,1.3), 1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e-03,1.3), 2.958579443997e-07, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585794439971025e-07,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e-02,1.3), 2.958536116114e-05, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9585361161138382e-05,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000001e-01,1.3), 2.954207597179e-03, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.9542075971792496e-03,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+00,1.3), 2.561069378624e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Pinv, (2.5610693786235361e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+01,1.3), 9.999999999999e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+02,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+03,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+04,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+05,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+06,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+07,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+08,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_P, (1.0000000000000000e+10,1.3), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+10,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+09,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+08,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+07,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+06,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+05,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+04,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+03,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+02,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+01,1.3), 1.415959498849e-13, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Qinv, (1.4159594988487832e-13,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e+00,1.3), 7.438930621376e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Qinv, (7.4389306213764639e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000001e-01,1.3), 9.970457924028e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Qinv, (9.9704579240282076e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e-02,1.3), 9.999704146388e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e-03,1.3), 9.999997041421e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e-04,1.3), 9.999999970414e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000001e-05,1.3), 9.999999999704e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (9.9999999999999995e-07,1.3), 9.999999999997e-01, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (9.9999999999999995e-08,1.3), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e-08,1.3), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000001e-09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (1.0000000000000000e-10,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_rayleigh_Q, (0.0000000000000000e+00,1.3), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_flat (void);
+
+void
+test_auto_flat (void)
+{
+ TEST(gsl_cdf_flat_P, (0.0000000000000000e+00,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e-10,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000001e-09,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e-08,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (9.9999999999999995e-08,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (9.9999999999999995e-07,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000001e-05,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e-04,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e-03,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e-02,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000001e-01,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+00,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+01,1.3,750.0), 1.162014157874e-02, TEST_TOL6);
+ TEST(gsl_cdf_flat_Pinv, (1.1620141578738545e-02,1.3,750.0), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+02,1.3,750.0), 1.318285027381e-01, TEST_TOL6);
+ TEST(gsl_cdf_flat_Pinv, (1.3182850273808142e-01,1.3,750.0), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+03,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+04,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+05,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+06,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+07,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+08,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+09,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_P, (1.0000000000000000e+10,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+10,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+09,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+08,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+07,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+06,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+05,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+04,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+03,1.3,750.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+02,1.3,750.0), 8.681714972619e-01, TEST_TOL6);
+ TEST(gsl_cdf_flat_Qinv, (8.6817149726190368e-01,1.3,750.0), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+01,1.3,750.0), 9.883798584213e-01, TEST_TOL6);
+ TEST(gsl_cdf_flat_Qinv, (9.8837985842125353e-01,1.3,750.0), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e+00,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000001e-01,1.3,750.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e-02,1.3,750.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e-03,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e-04,1.3,750.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000001e-05,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (9.9999999999999995e-07,1.3,750.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (9.9999999999999995e-08,1.3,750.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e-08,1.3,750.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000001e-09,1.3,750.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (1.0000000000000000e-10,1.3,750.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_flat_Q, (0.0000000000000000e+00,1.3,750.0), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_lognormal (void);
+
+void
+test_auto_lognormal (void)
+{
+ TEST(gsl_cdf_lognormal_P, (0.0000000000000000e+00,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e-10,1.3,2.7), 1.034288276012e-19, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (1.0342882760115472e-19,1.3,2.7), 1.000000000000e-10, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000001e-09,1.3,2.7), 1.720583234428e-16, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (1.7205832344275183e-16,1.3,2.7), 1.000000000000e-09, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e-08,1.3,2.7), 1.397140696550e-13, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (1.3971406965496307e-13,1.3,2.7), 1.000000000000e-08, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (9.9999999999999995e-08,1.3,2.7), 5.550354890102e-11, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (5.5503548901015757e-11,1.3,2.7), 1.000000000000e-07, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (9.9999999999999995e-07,1.3,2.7), 1.082087222875e-08, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (1.0820872228749844e-08,1.3,2.7), 1.000000000000e-06, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000001e-05,1.3,2.7), 1.039815967490e-06, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (1.0398159674903829e-06,1.3,2.7), 1.000000000000e-05, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e-04,1.3,2.7), 4.956354352667e-05, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (4.9563543526667839e-05,1.3,2.7), 1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e-03,1.3,2.7), 1.183246775456e-03, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (1.1832467754562060e-03,1.3,2.7), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e-02,1.3,2.7), 1.436760981041e-02, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (1.4367609810406523e-02,1.3,2.7), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000001e-01,1.3,2.7), 9.105428982941e-02, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (9.1054289829405582e-02,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+00,1.3,2.7), 3.150871690838e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (3.1508716908375517e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+01,1.3,2.7), 6.448033073717e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (6.4480330737174019e-01,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+02,1.3,2.7), 8.895497448370e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (8.8954974483702642e-01,1.3,2.7), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+03,1.3,2.7), 9.810967467052e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (9.8109674670518154e-01,1.3,2.7), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+04,1.3,2.7), 9.983038570318e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (9.9830385703184354e-01,1.3,2.7), 1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+05,1.3,2.7), 9.999223897251e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Pinv, (9.9992238972508574e-01,1.3,2.7), 1.000000000000e+05, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+06,1.3,2.7), 9.999982185389e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+07,1.3,2.7), 9.999999796956e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+08,1.3,2.7), 9.999999998859e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+09,1.3,2.7), 9.999999999997e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_P, (1.0000000000000000e+10,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+10,1.3,2.7), 4.255893513650e-16, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (4.2558935136502785e-16,1.3,2.7), 1.000000000000e+10, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+09,1.3,2.7), 3.150574023842e-13, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (3.1505740238418296e-13,1.3,2.7), 1.000000000000e+09, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+08,1.3,2.7), 1.141445550080e-10, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (1.1414455500802107e-10,1.3,2.7), 1.000000000000e+08, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+07,1.3,2.7), 2.030439602858e-08, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (2.0304396028576915e-08,1.3,2.7), 1.000000000000e+07, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+06,1.3,2.7), 1.781461076603e-06, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (1.7814610766031938e-06,1.3,2.7), 1.000000000000e+06, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+05,1.3,2.7), 7.761027491429e-05, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (7.7610274914290006e-05,1.3,2.7), 1.000000000000e+05, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+04,1.3,2.7), 1.696142968157e-03, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (1.6961429681565346e-03,1.3,2.7), 1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+03,1.3,2.7), 1.890325329482e-02, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (1.8903253294818529e-02,1.3,2.7), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+02,1.3,2.7), 1.104502551630e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (1.1045025516297369e-01,1.3,2.7), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+01,1.3,2.7), 3.551966926283e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (3.5519669262825992e-01,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e+00,1.3,2.7), 6.849128309162e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (6.8491283091624500e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000001e-01,1.3,2.7), 9.089457101706e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (9.0894571017059467e-01,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e-02,1.3,2.7), 9.856323901896e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (9.8563239018959370e-01,1.3,2.7), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e-03,1.3,2.7), 9.988167532245e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Qinv, (9.9881675322454400e-01,1.3,2.7), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e-04,1.3,2.7), 9.999504364565e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000001e-05,1.3,2.7), 9.999989601840e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (9.9999999999999995e-07,1.3,2.7), 9.999999891791e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (9.9999999999999995e-08,1.3,2.7), 9.999999999445e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e-08,1.3,2.7), 9.999999999999e-01, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000001e-09,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (1.0000000000000000e-10,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_lognormal_Q, (0.0000000000000000e+00,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_gamma (void);
+
+void
+test_auto_gamma (void)
+{
+ TEST(gsl_cdf_gamma_P, (0.0000000000000000e+00,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-10,1.3,2.7), 2.356478475164e-14, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (2.3564784751638661e-14,1.3,2.7), 1.000000000000e-10, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000001e-09,1.3,2.7), 4.701792696644e-13, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (4.7017926966439445e-13,1.3,2.7), 1.000000000000e-09, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-08,1.3,2.7), 9.381309762735e-12, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (9.3813097627346386e-12,1.3,2.7), 1.000000000000e-08, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (9.9999999999999995e-08,1.3,2.7), 1.871817348197e-10, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (1.8718173481972823e-10,1.3,2.7), 1.000000000000e-07, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (9.9999999999999995e-07,1.3,2.7), 3.734765911711e-09, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (3.7347659117114240e-09,1.3,2.7), 1.000000000000e-06, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000001e-05,1.3,2.7), 7.451823639191e-08, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (7.4518236391910116e-08,1.3,2.7), 1.000000000000e-05, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-04,1.3,2.7), 1.486806276026e-06, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (1.4868062760263472e-06,1.3,2.7), 1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-03,1.3,2.7), 2.966009681152e-05, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (2.9660096811518665e-05,1.3,2.7), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-02,1.3,2.7), 5.906831032950e-04, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (5.9068310329499826e-04,1.3,2.7), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000001e-01,1.3,2.7), 1.156629233128e-02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (1.1566292331279586e-02,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+00,1.3,2.7), 1.921237769663e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (1.9212377696630473e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+01,1.3,2.7), 9.565035356115e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (9.5650353561153789e-01,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+02,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+03,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+04,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+05,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+06,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+07,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+08,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+09,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+10,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+10,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+09,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+08,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+07,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+06,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+05,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+04,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+03,1.3,2.7), 9.292091038794e-161, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (9.2920910387939860e-161,1.3,2.7), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+02,1.3,2.7), 2.729167976527e-16, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (2.7291679765273174e-16,1.3,2.7), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+01,1.3,2.7), 4.349646438846e-02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (4.3496464388462192e-02,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+00,1.3,2.7), 8.078762230337e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (8.0787622303369533e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000001e-01,1.3,2.7), 9.884337076687e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (9.8843370766872041e-01,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-02,1.3,2.7), 9.994093168967e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (9.9940931689670498e-01,1.3,2.7), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-03,1.3,2.7), 9.999703399032e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-04,1.3,2.7), 9.999985131937e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000001e-05,1.3,2.7), 9.999999254818e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (9.9999999999999995e-07,1.3,2.7), 9.999999962652e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (9.9999999999999995e-08,1.3,2.7), 9.999999998128e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-08,1.3,2.7), 9.999999999906e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000001e-09,1.3,2.7), 9.999999999995e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-10,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (0.0000000000000000e+00,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_chisq (void);
+
+void
+test_auto_chisq (void)
+{
+ TEST(gsl_cdf_chisq_P, (0.0000000000000000e+00,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e-10,1.3), 2.238884178785e-07, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (2.2388841787852728e-07,1.3), 1.000000000000e-10, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000001e-09,1.3), 1.000072827212e-06, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (1.0000728272124926e-06,1.3), 1.000000000000e-09, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e-08,1.3), 4.467161220799e-06, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (4.4671612207994108e-06,1.3), 1.000000000000e-08, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (9.9999999999999995e-08,1.3), 1.995407585451e-05, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (1.9954075854510294e-05,1.3), 1.000000000000e-07, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (9.9999999999999995e-07,1.3), 8.913156700686e-05, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (8.9131567006858211e-05,1.3), 1.000000000000e-06, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000001e-05,1.3), 3.981353794611e-04, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (3.9813537946105002e-04,1.3), 1.000000000000e-05, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e-04,1.3), 1.778373888800e-03, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (1.7783738888003920e-03,1.3), 1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e-03,1.3), 7.942296379590e-03, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (7.9422963795896199e-03,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e-02,1.3), 3.541413902540e-02, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (3.5414139025402407e-02,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000001e-01,1.3), 1.554268895840e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (1.5542688958403586e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+00,1.3), 5.878620132779e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (5.8786201327788579e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+01,1.3), 9.973867890205e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Pinv, (9.9738678902053046e-01,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+02,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+03,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+04,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+05,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+06,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+07,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+08,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_P, (1.0000000000000000e+10,1.3), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+10,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+09,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+08,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+07,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+06,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+05,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+04,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+03,1.3), 5.840240518729e-219, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (5.8402405187288964e-219,1.3), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+02,1.3), 3.517864771108e-23, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (3.5178647711076648e-23,1.3), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+01,1.3), 2.613210979470e-03, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (2.6132109794696230e-03,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e+00,1.3), 4.121379867221e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (4.1213798672211427e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000001e-01,1.3), 8.445731104160e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (8.4457311041596417e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e-02,1.3), 9.645858609746e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (9.6458586097459775e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e-03,1.3), 9.920577036204e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (9.9205770362041057e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e-04,1.3), 9.982216261112e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (9.9822162611119969e-01,1.3), 1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000001e-05,1.3), 9.996018646205e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Qinv, (9.9960186462053913e-01,1.3), 1.000000000000e-05, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (9.9999999999999995e-07,1.3), 9.999108684330e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (9.9999999999999995e-08,1.3), 9.999800459241e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e-08,1.3), 9.999955328388e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000001e-09,1.3), 9.999989999272e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (1.0000000000000000e-10,1.3), 9.999997761116e-01, TEST_TOL6);
+ TEST(gsl_cdf_chisq_Q, (0.0000000000000000e+00,1.3), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_tdist (void);
+
+void
+test_auto_tdist (void)
+{
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+10,1.3), 3.467848111850e-14, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (3.4678481118500305e-14,1.3), -1.000000000000e+10, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+09,1.3), 6.919266651610e-13, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (6.9192666516103524e-13,1.3), -1.000000000000e+09, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+08,1.3), 1.380575199718e-11, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (1.3805751997179027e-11,1.3), -1.000000000000e+08, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+07,1.3), 2.754609668978e-10, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (2.7546096689777484e-10,1.3), -1.000000000000e+07, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+06,1.3), 5.496168864957e-09, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (5.4961688649569980e-09,1.3), -1.000000000000e+06, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+05,1.3), 1.096629861231e-07, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (1.0966298612314582e-07,1.3), -1.000000000000e+05, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+04,1.3), 2.188064222827e-06, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (2.1880642228271703e-06,1.3), -1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+03,1.3), 4.365759541083e-05, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (4.3657595410833571e-05,1.3), -1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+02,1.3), 8.710327647608e-04, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (8.7103276476079201e-04,1.3), -1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+01,1.3), 1.727893386820e-02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (1.7278933868204446e-02,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e+00,1.3), 2.336211937932e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (2.3362119379322516e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000001e-01,1.3), 4.667575980083e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (4.6675759800826139e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e-02,1.3), 4.966660755117e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (4.9666607551169606e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e-03,1.3), 4.996665978189e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (4.9966659781887629e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e-04,1.3), 4.999666597722e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000001e-05,1.3), 4.999966659772e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-9.9999999999999995e-07,1.3), 4.999996665977e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-9.9999999999999995e-08,1.3), 4.999999666598e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e-08,1.3), 4.999999966660e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000001e-09,1.3), 4.999999996666e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (-1.0000000000000000e-10,1.3), 4.999999999667e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (4.9999999999999900e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e-10,1.3), 5.000000000333e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000001e-09,1.3), 5.000000003334e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e-08,1.3), 5.000000033340e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (9.9999999999999995e-08,1.3), 5.000000333402e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (9.9999999999999995e-07,1.3), 5.000003334023e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000001e-05,1.3), 5.000033340228e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e-04,1.3), 5.000333402278e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e-03,1.3), 5.003334021811e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (5.0033340218112365e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e-02,1.3), 5.033339244883e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (5.0333392448830394e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000001e-01,1.3), 5.332424019917e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (5.3324240199173856e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+00,1.3), 7.663788062068e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (7.6637880620677490e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+01,1.3), 9.827210661318e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (9.8272106613179555e-01,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+02,1.3), 9.991289672352e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Pinv, (9.9912896723523925e-01,1.3), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+03,1.3), 9.999563424046e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+04,1.3), 9.999978119358e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+05,1.3), 9.999998903370e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+06,1.3), 9.999999945038e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+07,1.3), 9.999999997245e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+08,1.3), 9.999999999862e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+09,1.3), 9.999999999993e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_P, (1.0000000000000000e+10,1.3), 1.000000000000e-00, TEST_TOL6);
+
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+10,1.3), 3.467848111850e-14, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (3.4678481118500305e-14,1.3), 1.000000000000e+10, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+09,1.3), 6.919266651610e-13, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (6.9192666516103524e-13,1.3), 1.000000000000e+09, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+08,1.3), 1.380575199718e-11, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (1.3805751997179027e-11,1.3), 1.000000000000e+08, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+07,1.3), 2.754609668978e-10, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (2.7546096689777484e-10,1.3), 1.000000000000e+07, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+06,1.3), 5.496168864957e-09, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (5.4961688649569980e-09,1.3), 1.000000000000e+06, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+05,1.3), 1.096629861231e-07, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (1.0966298612314582e-07,1.3), 1.000000000000e+05, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+04,1.3), 2.188064222827e-06, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (2.1880642228271703e-06,1.3), 1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+03,1.3), 4.365759541083e-05, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (4.3657595410833571e-05,1.3), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+02,1.3), 8.710327647608e-04, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (8.7103276476079201e-04,1.3), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+01,1.3), 1.727893386820e-02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (1.7278933868204446e-02,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e+00,1.3), 2.336211937932e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (2.3362119379322516e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000001e-01,1.3), 4.667575980083e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (4.6675759800826139e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e-02,1.3), 4.966660755117e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (4.9666607551169606e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e-03,1.3), 4.996665978189e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (4.9966659781887629e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e-04,1.3), 4.999666597722e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000001e-05,1.3), 4.999966659772e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (9.9999999999999995e-07,1.3), 4.999996665977e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (9.9999999999999995e-08,1.3), 4.999999666598e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e-08,1.3), 4.999999966660e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000001e-09,1.3), 4.999999996666e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (1.0000000000000000e-10,1.3), 4.999999999667e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (4.9999999999999900e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e-10,1.3), 5.000000000333e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000001e-09,1.3), 5.000000003334e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e-08,1.3), 5.000000033340e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-9.9999999999999995e-08,1.3), 5.000000333402e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-9.9999999999999995e-07,1.3), 5.000003334023e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000001e-05,1.3), 5.000033340228e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e-04,1.3), 5.000333402278e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e-03,1.3), 5.003334021811e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (5.0033340218112365e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e-02,1.3), 5.033339244883e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (5.0333392448830394e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000001e-01,1.3), 5.332424019917e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (5.3324240199173856e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+00,1.3), 7.663788062068e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (7.6637880620677490e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+01,1.3), 9.827210661318e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (9.8272106613179555e-01,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+02,1.3), 9.991289672352e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Qinv, (9.9912896723523925e-01,1.3), -1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+03,1.3), 9.999563424046e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+04,1.3), 9.999978119358e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+05,1.3), 9.999998903370e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+06,1.3), 9.999999945038e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+07,1.3), 9.999999997245e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+08,1.3), 9.999999999862e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+09,1.3), 9.999999999993e-01, TEST_TOL6);
+ TEST(gsl_cdf_tdist_Q, (-1.0000000000000000e+10,1.3), 1.000000000000e-00, TEST_TOL6);
+}
+
+void test_auto_gumbel1 (void);
+
+void
+test_auto_gumbel1 (void)
+{
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+10,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+09,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+08,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+07,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+06,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+05,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+04,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+03,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+02,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+01,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e+00,1.3,2.7), 4.981965353092e-05, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (4.9819653530918237e-05,1.3,2.7), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000001e-01,1.3,2.7), 4.619717476780e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (4.6197174767798083e-02,1.3,2.7), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e-02,1.3,2.7), 6.487265128366e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (6.4872651283663055e-02,1.3,2.7), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e-03,1.3,2.7), 6.696988203722e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (6.6969882037217598e-02,1.3,2.7), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e-04,1.3,2.7), 6.718192621136e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (6.7181926211364873e-02,1.3,2.7), -1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000001e-05,1.3,2.7), 6.720315385232e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-9.9999999999999995e-07,1.3,2.7), 6.720527684866e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-9.9999999999999995e-08,1.3,2.7), 6.720548915062e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e-08,1.3,2.7), 6.720551038084e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000001e-09,1.3,2.7), 6.720551250386e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (-1.0000000000000000e-10,1.3,2.7), 6.720551271616e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (0.0000000000000000e+00,1.3,2.7), 6.720551273975e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (6.7205512739749951e-02,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e-10,1.3,2.7), 6.720551276334e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000001e-09,1.3,2.7), 6.720551297564e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e-08,1.3,2.7), 6.720551509866e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (9.9999999999999995e-08,1.3,2.7), 6.720553632889e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (9.9999999999999995e-07,1.3,2.7), 6.720574863136e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000001e-05,1.3,2.7), 6.720787167931e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e-04,1.3,2.7), 6.722910448133e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (6.7229104481333457e-02,1.3,2.7), 1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e-03,1.3,2.7), 6.744166476190e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (6.7441664761898834e-02,1.3,2.7), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e-02,1.3,2.7), 6.959050352518e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (6.9590503525179814e-02,1.3,2.7), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000001e-01,1.3,2.7), 9.340058564429e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (9.3400585644290435e-02,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+00,1.3,2.7), 4.791048360125e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Pinv, (4.7910483601248477e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+01,1.3,2.7), 9.999938971292e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+02,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+03,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+04,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+05,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+06,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+07,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+08,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+09,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_P, (1.0000000000000000e+10,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+10,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+09,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+08,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+07,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+06,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+05,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+04,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+03,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+02,1.3,2.7), 9.398988467742e-57, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.3989884677416057e-57,1.3,2.7), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+01,1.3,2.7), 6.102870776257e-06, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (6.1028707762572197e-06,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e+00,1.3,2.7), 5.208951639875e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (5.2089516398751523e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000001e-01,1.3,2.7), 9.065994143557e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.0659941435570957e-01,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e-02,1.3,2.7), 9.304094964748e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.3040949647482019e-01,1.3,2.7), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e-03,1.3,2.7), 9.325583352381e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.3255833523810117e-01,1.3,2.7), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e-04,1.3,2.7), 9.327708955187e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000001e-05,1.3,2.7), 9.327921283207e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (9.9999999999999995e-07,1.3,2.7), 9.327942513686e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (9.9999999999999995e-08,1.3,2.7), 9.327944636711e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e-08,1.3,2.7), 9.327944849013e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000001e-09,1.3,2.7), 9.327944870244e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (1.0000000000000000e-10,1.3,2.7), 9.327944872367e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (0.0000000000000000e+00,1.3,2.7), 9.327944872603e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.3279448726025027e-01,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e-10,1.3,2.7), 9.327944872838e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000001e-09,1.3,2.7), 9.327944874961e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e-08,1.3,2.7), 9.327944896192e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-9.9999999999999995e-08,1.3,2.7), 9.327945108494e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-9.9999999999999995e-07,1.3,2.7), 9.327947231513e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000001e-05,1.3,2.7), 9.327968461477e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e-04,1.3,2.7), 9.328180737886e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e-03,1.3,2.7), 9.330301179628e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.3303011796278246e-01,1.3,2.7), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e-02,1.3,2.7), 9.351273487163e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.3512734871633696e-01,1.3,2.7), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000001e-01,1.3,2.7), 9.538028252322e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.5380282523220195e-01,1.3,2.7), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+00,1.3,2.7), 9.999501803465e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Qinv, (9.9995018034646910e-01,1.3,2.7), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+02,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+03,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+04,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+05,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+06,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+07,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+08,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+09,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel1_Q, (-1.0000000000000000e+10,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_gumbel2 (void);
+
+void
+test_auto_gumbel2 (void)
+{
+ TEST(gsl_cdf_gumbel2_P, (0.0000000000000000e+00,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e-10,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000001e-09,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e-08,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (9.9999999999999995e-08,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (9.9999999999999995e-07,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000001e-05,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e-04,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e-03,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e-02,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000001e-01,1.3,2.7), 4.014688368993e-24, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Pinv, (4.0146883689934746e-24,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+00,1.3,2.7), 6.720551273975e-02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Pinv, (6.7205512739749743e-02,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+01,1.3,2.7), 8.734358842463e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Pinv, (8.7343588424628138e-01,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+02,1.3,2.7), 9.932408531257e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Pinv, (9.9324085312574451e-01,1.3,2.7), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+03,1.3,2.7), 9.996601479016e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Pinv, (9.9966014790162783e-01,1.3,2.7), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+04,1.3,2.7), 9.999829642968e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+05,1.3,2.7), 9.999991461854e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+06,1.3,2.7), 9.999999572079e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+07,1.3,2.7), 9.999999978553e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+08,1.3,2.7), 9.999999998925e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+09,1.3,2.7), 9.999999999946e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_P, (1.0000000000000000e+10,1.3,2.7), 9.999999999997e-01, TEST_TOL6);
+
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+10,1.3,2.7), 2.700000000000e-13, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (2.6999999999996492e-13,1.3,2.7), 1.000000000000e+10, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+09,1.3,2.7), 5.387208250401e-12, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (5.3872082504014914e-12,1.3,2.7), 1.000000000000e+09, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+08,1.3,2.7), 1.074889360437e-10, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (1.0748893604366781e-10,1.3,2.7), 1.000000000000e+08, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+07,1.3,2.7), 2.144686231456e-09, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (2.1446862314557286e-09,1.3,2.7), 1.000000000000e+07, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+06,1.3,2.7), 4.279211528087e-08, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (4.2792115280867646e-08,1.3,2.7), 1.000000000000e+06, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+05,1.3,2.7), 8.538146037456e-07, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (8.5381460374556900e-07,1.3,2.7), 1.000000000000e+05, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+04,1.3,2.7), 1.703570319173e-05, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (1.7035703191725618e-05,1.3,2.7), 1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+03,1.3,2.7), 3.398520983725e-04, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (3.3985209837246249e-04,1.3,2.7), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+02,1.3,2.7), 6.759146874256e-03, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (6.7591468742558315e-03,1.3,2.7), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+01,1.3,2.7), 1.265641157537e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (1.2656411575371904e-01,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e+00,1.3,2.7), 9.327944872603e-01, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Qinv, (9.3279448726025116e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000001e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e-02,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e-03,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e-04,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000001e-05,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (9.9999999999999995e-07,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (9.9999999999999995e-08,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e-08,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000001e-09,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (1.0000000000000000e-10,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gumbel2_Q, (0.0000000000000000e+00,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_weibull (void);
+
+void
+test_auto_weibull (void)
+{
+ TEST(gsl_cdf_weibull_P, (0.0000000000000000e+00,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e-10,1.3,2.7), 4.924395760785e-28, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (4.9243957607852698e-28,1.3,2.7), 1.000000000000e-10, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000001e-09,1.3,2.7), 2.468044288634e-25, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (2.4680442886338381e-25,1.3,2.7), 1.000000000000e-09, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e-08,1.3,2.7), 1.236952289490e-22, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (1.2369522894899823e-22,1.3,2.7), 1.000000000000e-08, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (9.9999999999999995e-08,1.3,2.7), 6.199446960984e-20, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (6.1994469609840516e-20,1.3,2.7), 1.000000000000e-07, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (9.9999999999999995e-07,1.3,2.7), 3.107083672395e-17, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (3.1070836723945982e-17,1.3,2.7), 1.000000000000e-06, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000001e-05,1.3,2.7), 1.557230670416e-14, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (1.5572306704159031e-14,1.3,2.7), 1.000000000000e-05, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e-04,1.3,2.7), 7.804641318223e-12, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (7.8046413182225018e-12,1.3,2.7), 1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e-03,1.3,2.7), 3.911586584098e-09, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (3.9115865840980536e-09,1.3,2.7), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e-02,1.3,2.7), 1.960435341356e-06, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (1.9604353413559907e-06,1.3,2.7), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000001e-01,1.3,2.7), 9.820635881537e-04, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (9.8206358815371392e-04,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+00,1.3,2.7), 3.888663329609e-01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Pinv, (3.8886633296085954e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+02,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+03,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+04,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+05,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+06,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+07,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+08,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+09,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_P, (1.0000000000000000e+10,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+10,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+09,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+08,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+07,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+06,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+05,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+04,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+03,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+02,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+01,1.3,2.7), 6.519262004070e-108, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Qinv, (6.5192620040698617e-108,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e+00,1.3,2.7), 6.111336670391e-01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Qinv, (6.1113366703914040e-01,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000001e-01,1.3,2.7), 9.990179364118e-01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Qinv, (9.9901793641184633e-01,1.3,2.7), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e-02,1.3,2.7), 9.999980395647e-01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e-03,1.3,2.7), 9.999999960884e-01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e-04,1.3,2.7), 9.999999999922e-01, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000001e-05,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (9.9999999999999995e-07,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (9.9999999999999995e-08,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e-08,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000001e-09,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (1.0000000000000000e-10,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_weibull_Q, (0.0000000000000000e+00,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_pareto (void);
+
+void
+test_auto_pareto (void)
+{
+ TEST(gsl_cdf_pareto_P, (0.0000000000000000e+00,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e-10,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000001e-09,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e-08,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (9.9999999999999995e-08,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (9.9999999999999995e-07,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000001e-05,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e-04,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e-03,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e-02,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000001e-01,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+00,1.3,2.7), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+01,1.3,2.7), 8.177057822240e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Pinv, (8.1770578222395374e-01,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+02,1.3,2.7), 9.908636465287e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Pinv, (9.9086364652869807e-01,1.3,2.7), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+03,1.3,2.7), 9.995420976279e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Pinv, (9.9954209762786816e-01,1.3,2.7), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+04,1.3,2.7), 9.999770505177e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+05,1.3,2.7), 9.999988498013e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+06,1.3,2.7), 9.999999423535e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+07,1.3,2.7), 9.999999971109e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+08,1.3,2.7), 9.999999998552e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+09,1.3,2.7), 9.999999999928e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_P, (1.0000000000000000e+10,1.3,2.7), 9.999999999997e-01, TEST_TOL6);
+
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+10,1.3,2.7), 3.637247829654e-13, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (3.6372478296536173e-13,1.3,2.7), 1.000000000000e+10, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+09,1.3,2.7), 7.257263524710e-12, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (7.2572635247102111e-12,1.3,2.7), 1.000000000000e+09, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+08,1.3,2.7), 1.448014442065e-10, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (1.4480144420652496e-10,1.3,2.7), 1.000000000000e+08, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+07,1.3,2.7), 2.889168647783e-09, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (2.8891686477834784e-09,1.3,2.7), 1.000000000000e+07, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+06,1.3,2.7), 5.764649324512e-08, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (5.7646493245119715e-08,1.3,2.7), 1.000000000000e+06, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+05,1.3,2.7), 1.150198755621e-06, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (1.1501987556209536e-06,1.3,2.7), 1.000000000000e+05, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+04,1.3,2.7), 2.294948231815e-05, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (2.2949482318145872e-05,1.3,2.7), 1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+03,1.3,2.7), 4.579023721744e-04, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (4.5790237217441070e-04,1.3,2.7), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+02,1.3,2.7), 9.136353471345e-03, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (9.1363534713445622e-03,1.3,2.7), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+01,1.3,2.7), 1.822942177761e-01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Qinv, (1.8229421777608898e-01,1.3,2.7), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e+00,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000001e-01,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e-02,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e-03,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e-04,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000001e-05,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (9.9999999999999995e-07,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (9.9999999999999995e-08,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e-08,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000001e-09,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (1.0000000000000000e-10,1.3,2.7), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_pareto_Q, (0.0000000000000000e+00,1.3,2.7), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_logistic (void);
+
+void
+test_auto_logistic (void)
+{
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+10,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+09,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+08,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+07,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+06,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+05,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+04,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+03,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+02,1.3), 3.915003559824e-34, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (3.9150035598244656e-34,1.3), -1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+01,1.3), 4.561157640565e-04, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (4.5611576405646045e-04,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e+00,1.3), 3.166455298122e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (3.1664552981221700e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000001e-01,1.3), 4.807787077894e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (4.8077870778939180e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e-02,1.3), 4.980769325595e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (4.9807693255949481e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e-03,1.3), 4.998076923172e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (4.9980769231717492e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e-04,1.3), 4.999807692308e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000001e-05,1.3), 4.999980769231e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-9.9999999999999995e-07,1.3), 4.999998076923e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-9.9999999999999995e-08,1.3), 4.999999807692e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e-08,1.3), 4.999999980769e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000001e-09,1.3), 4.999999998077e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (-1.0000000000000000e-10,1.3), 4.999999999808e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (5.0000000000000000e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e-10,1.3), 5.000000000192e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000001e-09,1.3), 5.000000001923e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e-08,1.3), 5.000000019231e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (9.9999999999999995e-08,1.3), 5.000000192308e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (9.9999999999999995e-07,1.3), 5.000001923077e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000001e-05,1.3), 5.000019230769e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e-04,1.3), 5.000192307692e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e-03,1.3), 5.001923076828e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (5.0019230768282508e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e-02,1.3), 5.019230674405e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (5.0192306744050519e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000001e-01,1.3), 5.192212922106e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (5.1922129221060820e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+00,1.3), 6.833544701878e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (6.8335447018778295e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+01,1.3), 9.995438842359e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Pinv, (9.9954388423594354e-01,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+02,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+03,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+04,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+05,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+06,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+07,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+08,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_P, (1.0000000000000000e+10,1.3), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+10,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+09,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+08,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+07,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+06,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+05,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+04,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+03,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+02,1.3), 3.915003559824e-34, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (3.9150035598244656e-34,1.3), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+01,1.3), 4.561157640565e-04, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (4.5611576405646045e-04,1.3), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e+00,1.3), 3.166455298122e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (3.1664552981221700e-01,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000001e-01,1.3), 4.807787077894e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (4.8077870778939180e-01,1.3), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e-02,1.3), 4.980769325595e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (4.9807693255949481e-01,1.3), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e-03,1.3), 4.998076923172e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (4.9980769231717492e-01,1.3), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e-04,1.3), 4.999807692308e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000001e-05,1.3), 4.999980769231e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (9.9999999999999995e-07,1.3), 4.999998076923e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (9.9999999999999995e-08,1.3), 4.999999807692e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e-08,1.3), 4.999999980769e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000001e-09,1.3), 4.999999998077e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (1.0000000000000000e-10,1.3), 4.999999999808e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (0.0000000000000000e+00,1.3), 5.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (5.0000000000000000e-01,1.3), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e-10,1.3), 5.000000000192e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000001e-09,1.3), 5.000000001923e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e-08,1.3), 5.000000019231e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-9.9999999999999995e-08,1.3), 5.000000192308e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-9.9999999999999995e-07,1.3), 5.000001923077e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000001e-05,1.3), 5.000019230769e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e-04,1.3), 5.000192307692e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e-03,1.3), 5.001923076828e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (5.0019230768282508e-01,1.3), -1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e-02,1.3), 5.019230674405e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (5.0192306744050519e-01,1.3), -1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000001e-01,1.3), 5.192212922106e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (5.1922129221060820e-01,1.3), -1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+00,1.3), 6.833544701878e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (6.8335447018778295e-01,1.3), -1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+01,1.3), 9.995438842359e-01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Qinv, (9.9954388423594354e-01,1.3), -1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+02,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+03,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+04,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+05,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+06,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+07,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+08,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+09,1.3), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_logistic_Q, (-1.0000000000000000e+10,1.3), 1.000000000000e+00, TEST_TOL6);
+}
+
+void test_auto_gammalarge (void);
+
+void
+test_auto_gammalarge (void)
+{
+ TEST(gsl_cdf_gamma_P, (0.0000000000000000e+00,1.3,123.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-10,1.3,123.0), 1.644976604681e-16, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (1.6449766046812008e-16,1.3,123.0), 1.000000000000e-10, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000001e-09,1.3,123.0), 3.282159828312e-15, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (3.2821598283122862e-15,1.3,123.0), 1.000000000000e-09, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-08,1.3,123.0), 6.548769816865e-14, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (6.5487698168653935e-14,1.3,123.0), 1.000000000000e-08, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (9.9999999999999995e-08,1.3,123.0), 1.306651361959e-12, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (1.3066513619593202e-12,1.3,123.0), 1.000000000000e-07, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (9.9999999999999995e-07,1.3,123.0), 2.607112210538e-11, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (2.6071122105378624e-11,1.3,123.0), 1.000000000000e-06, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000001e-05,1.3,123.0), 5.201872529446e-10, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (5.2018725294456393e-10,1.3,123.0), 1.000000000000e-05, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-04,1.3,123.0), 1.037909593275e-08, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (1.0379095932752980e-08,1.3,123.0), 1.000000000000e-04, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-03,1.3,123.0), 2.070893333124e-07, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (2.0708933331240137e-07,1.3,123.0), 1.000000000000e-03, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e-02,1.3,123.0), 4.131804542806e-06, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (4.1318045428061286e-06,1.3,123.0), 1.000000000000e-02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000001e-01,1.3,123.0), 8.240625287202e-05, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (8.2406252872017186e-05,1.3,123.0), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+00,1.3,123.0), 1.637438876041e-03, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (1.6374388760411608e-03,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+01,1.3,123.0), 3.135521671622e-02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (3.1355216716223523e-02,1.3,123.0), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+02,1.3,123.0), 4.240385705334e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (4.2403857053338523e-01,1.3,123.0), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+03,1.3,123.0), 9.993635318324e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Pinv, (9.9936353183235616e-01,1.3,123.0), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+04,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+05,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+06,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+07,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+08,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+09,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_P, (1.0000000000000000e+10,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+10,1.3,123.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+09,1.3,123.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+08,1.3,123.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+07,1.3,123.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+06,1.3,123.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+05,1.3,123.0), 0.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+04,1.3,123.0), 2.056363344745e-35, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (2.0563633447452943e-35,1.3,123.0), 1.000000000000e+04, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+03,1.3,123.0), 6.364681676440e-04, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (6.3646816764395531e-04,1.3,123.0), 1.000000000000e+03, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+02,1.3,123.0), 5.759614294666e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (5.7596142946661488e-01,1.3,123.0), 1.000000000000e+02, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+01,1.3,123.0), 9.686447832838e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (9.6864478328377646e-01,1.3,123.0), 1.000000000000e+01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e+00,1.3,123.0), 9.983625611240e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (9.9836256112395882e-01,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000001e-01,1.3,123.0), 9.999175937471e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Qinv, (9.9991759374712796e-01,1.3,123.0), 1.000000000000e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-02,1.3,123.0), 9.999958681955e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-03,1.3,123.0), 9.999997929107e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-04,1.3,123.0), 9.999999896209e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000001e-05,1.3,123.0), 9.999999994798e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (9.9999999999999995e-07,1.3,123.0), 9.999999999739e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (9.9999999999999995e-08,1.3,123.0), 9.999999999987e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-08,1.3,123.0), 9.999999999999e-01, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000001e-09,1.3,123.0), 1.000000000000e-00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (1.0000000000000000e-10,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+ TEST(gsl_cdf_gamma_Q, (0.0000000000000000e+00,1.3,123.0), 1.000000000000e+00, TEST_TOL6);
+}
+
diff --git a/gsl-1.9/cdf/weibull.c b/gsl-1.9/cdf/weibull.c
new file mode 100644
index 0000000..256d74a
--- /dev/null
+++ b/gsl-1.9/cdf/weibull.c
@@ -0,0 +1,37 @@
+/* cdf/weibull.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_weibull_P (const double x, const double a, const double b)
+{
+ double P = -expm1 (-pow(x/a, b));
+ return P;
+}
+
+double
+gsl_cdf_weibull_Q (const double x, const double a, const double b)
+{
+ double Q = exp (-pow(x/a, b));
+ return Q;
+}
diff --git a/gsl-1.9/cdf/weibullinv.c b/gsl-1.9/cdf/weibullinv.c
new file mode 100644
index 0000000..dce61e2
--- /dev/null
+++ b/gsl-1.9/cdf/weibullinv.c
@@ -0,0 +1,61 @@
+/* cdf/weibullinv.c
+ *
+ * Copyright (C) 2003 Brian Gough
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or (at
+ * your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ */
+
+#include <config.h>
+#include <math.h>
+#include <gsl/gsl_math.h>
+#include <gsl/gsl_cdf.h>
+
+double
+gsl_cdf_weibull_Pinv (const double P, const double a, const double b)
+{
+ double x;
+
+ if (P == 1.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (P == 0.0)
+ {
+ return 0.0;
+ }
+
+ x = a * pow(-log1p(-P), 1/b);
+
+ return x;
+}
+
+double
+gsl_cdf_weibull_Qinv (const double Q, const double a, const double b)
+{
+ double x;
+
+ if (Q == 0.0)
+ {
+ return GSL_POSINF;
+ }
+ else if (Q == 1.0)
+ {
+ return 0.0;
+ }
+
+ x = a * pow(-log(Q), 1/b);
+
+ return x;
+}