2
0
mirror of https://github.com/boostorg/math.git synced 2026-01-30 20:12:09 +00:00
Commit Graph

2542 Commits

Author SHA1 Message Date
jzmaddock
d1b2c7ea3c Correct BOOST_MATH_NO_LONG_DOUBLE_MATH_FUNCTIONS selection logic. 2021-02-07 10:47:21 +00:00
jzmaddock
cb146bff94 Disable long double support if it's a "double double".
Tentatively try and run some tests.
2021-02-07 08:20:19 +00:00
jzmaddock
561e892d7d More corrections, add first test case. 2021-02-06 18:42:58 +00:00
jzmaddock
a2b29c1132 Use BOOST_NO_CXX17_HDR_EXECUTION for <execution> detection. 2021-02-02 19:19:36 +00:00
Matt Borland
91ae2bfc77 Bivariate Stats Policies (#503)
* Add parallel impl and change seq impl [CI SKIP]

* Validate seq impl [CI SKIP]

* Remove old impl

* Add user interfaces [CI SKIP]

* Floating point covariance validated [CI SKIP]

* Integer covariance validated [CI SKIP]

* Change correlation_coeff impl interface [CI SKIP]

* Cleanup [CI SKIP]

* correlation passes all parameters for par impl
[CI SKIP]

* Finish framework [CI SKIP]

* Add correlation coefficient test cases

* Add benchmark and make small changes
[CI SKIP]

* Update docs
2021-01-30 11:09:12 -05:00
jzmaddock
bc92b924f8 Mostly cosmetic change on BOOST_MATH_NO_THREAD_LOCAL_WITH_NON_TRIVIAL_TYPES.
[CI SKIP]
2021-01-27 16:20:49 +00:00
Matt Borland
bfc1821a72 Fix missing headers and using std::sqrt (#501) 2021-01-25 12:51:22 -05:00
jzmaddock
480b5c0c09 Merge pull request #497 from boostorg/mingw_thread_local
static_assert when mingw is used in a way not supported.
2021-01-22 18:25:32 +00:00
Matt Borland
1eb3c71f8a Implement Policies in Statistics (#434)
* Initial Commit [WIP][CI SKIP]
Policies for mean implemented and forced vectorization

* First cut at integer variance [CI SKIP]

* Functional variance impl [WIP][CI SKIP]

* Work on variance [CI SKIP]
Details are now moved into detail files.
Recursively decomposes sufficient range size until max threads achieved.
Single failing test for integral, not implemented for Reals.

* Parallel integer variance complete [CI SKIP]

* All variance policies complete [CI SKIP]

* Update mean_and_sample_variance [CI SKIP]

* Median complete for all types [CI SKIP]

* Median absolute deviation complete for all types
[CI SKIP]

* Refactored sequential first four moments impls
[CI SKIP]

* Setup test cases for first four moments [WIP]
[CI SKIP]

* Sequential impl pass [CI SKIP]

* Parallel interface impl. Fails some tests
[CI SKIP]

* Interquartile range passes for all existing test
[CI SKIP]

* Gini coefficient generally implemented
Does not support long double or cpp_bin_float_50s
[CI SKIP]

* Sample gini coef implemented w/same constraints
[CI SKIP]

* Add benchmarks [CI SKIP]

* First four moments complete for most types
[CI SKIP]

* Skewness restructured. Currently INOP for non-seq
[CI SKIP]

* Fix floating point skewness [CI SKIP]

* Skewness complete [CI SKIP]

* Kurtosis complete [CI SKIP]

* Gini coefficient complete [CI SKIP]

Removes atomics which expands number of compatible types.

* Mode complete [CI SKIP]

Additionally mode now supports floating types by using an unordered_map to store frequency

* Garbage cleanup [CI SKIP]

* Doc updates [CI SKIP]

* Mean cleanup [CI SKIP]

* Cleanup variance [CI SKIP]

Remove duplicate impls that vary only be return type

* Variance Cleanup [CI SKIP]

Remove duplicate impls

* Skewness cleanup [CI SKIP]

* Update performance [CI SKIP]

* Add swap file to gitignore [CI SKIP]

* Add missing comma [CI SKIP]

* Improve par mode performance regression [CI SKIP]
[WIP] Parallel mode still ~2 orders of magnitude slower

* mode performance improvement [CI SKIP]

* Improved data handling - mode [CI SKIP]

* Additional overloads to match STL proposal
[CI SKIP]

* Updates to mode and documentation

* Remove dependency and fix todo [CI SKIP]

* Minor fixes [CI SKIP]

* Fix multiprecision issues [CI SKIP]

* Remove dependency. Minor change to thread counting
[CI SKIP]

* Standardize seq mean impl [CI SKIP]

* Fix doc brackets [CI SKIP]

* Remove duplicated sort on gini coef [CI SKIP]

* C++11 all that is required for sequential methods
[CI SKIP]

* Fixes for CI failure

* More CI fixes

* Fixes for MSVC issues
Fix gitignore merge conflict
Adjust test tol to match others

* Fix MSVC lang macro

* More small fixes for vinatge compilers

* Minor fix for MSVC 14.2 c++17 [CI SKIP]

* Cleanup docs, test file, and remove cruft
[CI SKIP]

* Delete par_unseq tests [CI SKIP]

* Change link to accumulators [CI SKIP]

* Add bigobj flag to failing build

* Remove redundant impl [WIP][CI SKIP]

* Initial cut at linear decomposition [WIP][CI SKIP]

* Passes tests [CI SKIP]

* Various CI fixes

* More CI fixes

* Delete extra impl and add linker flags

* Try CI without TBB

* Restrict compiler support

* Restrict c++ version
2021-01-22 09:42:16 -05:00
jzmaddock
f8a2e944da static_assert when mingw is used in a way not supported.
IT has issue with thread_local and non-trivial types.
2021-01-22 12:18:37 +00:00
Nick
d96b478791 Fix for division by 2, then multiplication by 2. (#495) 2021-01-21 09:45:33 -05:00
Matt Borland
bf3038bfcb Add Z-test (#494)
* Initial Commit

* Add tests

* Add docs

* Fix svg file dimensions [CI SKIP]

* Minor fixes [CI SKIP]

* Fixes to docs and tests [CI SKIP]

* More test fixes and cycle CI

* Cycle CI

* Update docs

* Fix for MSVC-14.2 C++17 misc failure [CI SKIP]
2021-01-17 09:53:49 -05:00
Matt Borland
f7e3fc17a6 Additional t-tests (#487)
* Add integer support to t_test

* Add paired samples t test

* Add two sample t test

* Add welch's t test

* Update docs

* Cleanup

* Add CHECK_ULP_CLOSE tests to test battery. Fix svg

* Remove all instances of ex [CI SKIP]

* Remove std::distance and note in docs [CI SKIP]

* Re-write test battery
2021-01-12 15:48:53 -05:00
jzmaddock
8efde8b9e5 Merge pull request #486 from mborland/issue430_beta
Fix for issue 430 in beta
2021-01-11 17:35:40 +00:00
Matt Borland
f8e35601b0 Add integer support to t_test (#485) 2021-01-10 11:35:51 -05:00
Matt Borland
579d89c163 Add integer support to linear regression (#484)
* Add integer support to linear regression

* Fix for MSVC error C2668: 'fpclassify' [CI SKIP]

* Fix naming [CI SKIP]
2021-01-09 12:15:43 -05:00
Matt Borland
e18bc5c84a Fix for issue 430 in beta 2021-01-09 11:45:01 +03:00
William Ledbetter
dc79545342 Make "v" accessible to derived classes (#483) 2021-01-08 11:30:24 -05:00
Matt Borland
fc7b75aceb Add integer support to bivariate statistics (#480)
* Add integer support to bivariate statistics
Reduce required CXXSTD from 17 to 11

* Fix failed test trying to use C++03 mode [CI SKIP]
2021-01-05 13:57:16 -05:00
jzmaddock
c845b0e82c Merge pull request #470 from mborland/issue464
Fix for issue #464
2020-12-30 19:01:55 +00:00
Matt Borland
c23f3fc5a7 Fix MSVC macro sub and warn others 2020-12-29 20:27:24 +03:00
Matt Borland
ebc6859559 CI Fixes [WINDOWS] 2020-12-29 15:44:02 +03:00
Matt Borland
0c20005e1b Eliminate -Wimplicit-int-float-conversion on clang 2020-12-27 19:47:09 +03:00
jzmaddock
787481c6ff Merge pull request #433 from boostorg/issue396
Try fix min Bn arg for recur.
2020-12-24 18:35:46 +00:00
Matt Borland
9a4fbed2c1 Qualify constexpr-ness of std::real and std::imag 2020-12-24 09:57:04 +03:00
Matt Borland
118863da21 Change PDF to be 0 for x = 0 or x = 1 2020-12-20 16:01:05 +03:00
John Maddock
358eda5039 Merge branch 'develop' into issue396 2020-12-19 19:37:31 +00:00
jzmaddock
75b9abc9ba Revert "[CI SKIP] Suggest use c++11 header when needed"
This reverts commit 5057e069c7.
2020-12-19 19:37:22 +00:00
jzmaddock
db42e6bced Add missing include.
Fixes issues exposed by changes to lexical_cast.
See https://github.com/boostorg/math/pull/433.
2020-12-19 19:31:01 +00:00
Christopher Kormanyos
b4fce630b7 Many CIs OK local try find what up on servers 2020-12-19 10:33:49 +01:00
Christopher Kormanyos
5057e069c7 [CI SKIP] Suggest use c++11 header when needed 2020-12-19 09:45:06 +01:00
Christopher Kormanyos
aedf8601c9 [CI SKIP] Remove useless semicolons and warnings 2020-12-19 09:05:30 +01:00
Christopher Kormanyos
f972e46850 On a guess, forward args and promote Chebyshev? 2020-12-17 08:46:32 +01:00
Christopher Kormanyos
728388856c Guesses for old, running on new compilers, try CI 2020-12-16 18:50:06 +01:00
Christopher Kormanyos
92417f5a7f Work the review findings including no constexpr, use 3 spaces and eliminate use of size_t and will try CI again 2020-12-16 15:04:27 +01:00
Christopher Kormanyos
603a37534e Issue396 gets better tests and fix of Bn recur 2020-12-16 11:02:08 +01:00
Christopher Kormanyos
1e61cea5df Improve fix, no pch, test spec fun locally 2020-12-14 07:21:52 +01:00
Christopher Kormanyos
90ee0013e7 Fix the fix of 396 and expand its test case 2020-12-13 20:33:25 +01:00
Christopher Kormanyos
da3babd117 Merge branch 'develop' into issue396 2020-11-25 23:11:37 +01:00
pulver
a0a97b768a Fix derivative of pow(x,y) when x=0 (#456)
* Fix pow(x,y) for variable x=0 and constant y #445

* Add pow0 test.

Co-authored-by: Matt Pulver <mpulver@unitytechgroup.com>
2020-11-16 11:52:28 -05:00
Nick
f3952b8b41 At least make error dimensionally correct. (#455) 2020-11-13 08:21:23 -05:00
jzmaddock
6cbd225994 Merge pull request #454 from boostorg/issue453
Fix up legendre_p(n, n-1, x) as special case.
2020-11-11 19:20:57 +00:00
jzmaddock
889620031a Fix up legendre_p(n, n-1, x) as special case.
Add tests.
Fixes https://github.com/boostorg/math/issues/453.
2020-11-08 20:47:25 +00:00
jzmaddock
56c4c890d1 Fix spurious overflow in gamma_p/q calculation.
Add tests.
Fixes: https://github.com/boostorg/math/issues/451
2020-11-05 19:43:52 +00:00
jzmaddock
e9da0ea36a Emscripten has no fully working long double functions.
Fixes https://github.com/boostorg/math/issues/441
2020-10-12 16:56:25 +01:00
Christopher Kormanyos
cb2bab6fd1 Fix min arg Bernoulli recur (TBD notes in PR) 2020-09-08 07:50:56 +02:00
Christopher Kormanyos
1afbce8b31 [CI SKIP] Try fix min Bn arg for recur. 2020-09-06 15:51:53 +02:00
Evan Miller
18ed616376 Kolmogorov-Smirnov distribution (#422)
* Kolmogorov-Smirnov distribution #421

Add a new distribution, kolmogorov_smirnov_distribution, which takes a
parameter that represents the number of observations used in a
Kolmogorov-Smirnov test. (The K-S test is a popular test for comparing
two CDFs, but the test statistic is not implemented here.)

This implementation includes Kolmogorov's original 1st order Taylor
expansion. There is a literature on the distribution's other
mathematical properties (higher order terms and exact version); this
literature is summarized in the main header file for anyone who may
want to expand the implementation later.

The CDF is implemented using a Jacobi theta function, and the PDF is a
hand-rolled derivative of that function. Quantiles plug the CDF and PDF
into a Newton-Raphson iteration. The mean and variance have nice
closed-form expressions, and the mode uses a dumb run-time maximizer.

This commit includes graphs, a ULP plotter for the PDF, and the usual
compilation and numerical tests. The test file is on the small side, but
it integrates the distribution from zero to infinity, and covers the
quantiles pretty well. As of now the numerical tests only verify
self-consistency (e.g. distribution moments and CDF-quantile relations),
so there's room to add some external checks.

* Implement skewness for K-S distribution [CI SKIP]

The third moment integrates nicely with the help of Apery's constant
(zeta_three). Verify the result via quadrature.

* Implement kurtosis for the K-S distribution

Verify the result via quadrature.
2020-09-04 08:48:51 -04:00
jzmaddock
eb668a01bd Merge pull request #432 from boostorg/improve_float_next
Update float_next/float_prior to handle types with exponents larger t…
2020-09-04 11:49:16 +01:00
jzmaddock
e39eca4f54 Update float_next/float_prior to handle types with exponents larger than type int. 2020-09-03 18:35:14 +01:00