Nick Thompson
89d28ff323
Fix up documentation for adaptive trapezoidal quadrature.
2017-04-08 19:48:52 -05:00
Nick Thompson
76a5423666
Finally learned how to use quickbook. The documentation for the cubic b spline looks good now.
2017-04-08 18:47:42 -05:00
jzmaddock
70e82419d5
Fix for expression template types.
2017-04-08 20:12:23 +01:00
jzmaddock
f74da283aa
Add variadic gcd and lcm variations, update tests to match.
2017-04-08 19:42:33 +01:00
jzmaddock
e71629f1c0
Make gcd/lcm functions constexpr and noexcept where applicable.
2017-04-08 19:13:08 +01:00
jzmaddock
8ee33649c7
Remove dead code orphaned by previous commits.
2017-04-07 09:55:31 +01:00
jzmaddock
5ca0e2ead8
Tighten up polynomial-GCD algorithm selection.
...
Disallow GCD's of polynomials of bounded integers as overflow is too likely to occur.
2017-04-07 09:44:48 +01:00
jzmaddock
8e98f30cb2
Remove SFINAE-logic and replace with simpler numeric_limits based algorithm selection.
2017-04-07 09:43:40 +01:00
jzmaddock
39006ecaca
Reinstate gcd of rational numbers.
2017-04-06 19:22:45 +01:00
jzmaddock
141fcf0b15
Disable test case which invokes undefined behaviour
2017-04-06 11:34:08 +01:00
jzmaddock
7795ad3fd1
Merge branch 'gcd_polynomial' into gcd_cpp14
2017-04-06 11:28:32 +01:00
jzmaddock
9d0dac1df9
gcd: add the function objects back.
...
Improve the gcd/lcm tests.
2017-04-04 18:29:45 +01:00
jzmaddock
e4c0fdb0f2
Make gcd/lcm independent of type_traits and mpl.
...
Later we'll try and reconcile this version with that in Boost.Integer.
2017-04-02 20:10:46 +01:00
jzmaddock
8c9709b317
Fix cases where wchar_t is not an intrinsic type.
...
Fixes: https://svn.boost.org/trac/boost/ticket/12944
2017-03-30 19:35:59 +01:00
Nick Thompson
fff12aa16b
Improve documentation for trapezoidal quadrature, explaining the role of the L1 norm calculation. Throw correct error type.
2017-03-28 13:56:18 -05:00
Nick Thompson
9f58f0d337
Add facility to check L1 norm and hence condition number of the quadrature sum. Throw when condition number exceeds the number of significant digits of the type.
2017-03-26 13:45:50 -05:00
pabristow
c5ee664a51
Refactored with policies and passes tests and timing.
2017-03-23 14:15:37 +00:00
pabristow
bdee37743d
Bug in values near to -exp(-1) corrected.
2017-03-13 10:03:33 +00:00
Nick Thompson
6734b363dd
Include spline documentation in math.qbk so it gets added to the build.
2017-03-11 15:56:34 -06:00
pabristow
0048d41dd6
Added new constants expminusone and sixth
2017-03-10 13:06:44 +00:00
pabristow
cea2465e3e
Need expminusone constant
2017-03-06 18:23:54 +00:00
pabristow
94d3cf4043
refactored to use local test_value.hpp
2017-03-06 18:10:52 +00:00
Nick
36159a4426
Discuss how the interpolant extrapolates.
2017-03-06 11:57:25 -06:00
Nick Thompson
4efe710855
Add tests detailing the use cases which make it difficult to use std::unique_ptr for pimpl idiom. Also, test that evaluating the spline outside the interpolation region succeeds as best it can.
2017-03-06 11:12:51 -06:00
Nick Thompson
136e7411f5
Adaptive Trapezoidal Quadrature
...
This routine estimates the definite integral of a function f.
Assuming that f is periodic, it can be shown that this routine converges exponentially fast.
In fact, the test cases given exhibit exponential convergence with decreasing stepsize.
A potential improvement is using the Bulirsch sequence rather than the Romberg sequence to schedule the refinements.
However, the convergence is so rapid for functions of the class specified above that there seems to be no need at present.
This code is cppcheck clean, and runs successfully under AddressSanitizer and UndefinedBehaviorSanitizer.
2017-03-05 19:05:41 -06:00
Nick Thompson
446f8c415d
Cite Kress's book 'Numerical Analysis' in MLA format.
2017-03-05 10:49:22 -06:00
Nick Thompson
7dbd074343
Add population example.
2017-03-03 08:58:18 -06:00
Nick Thompson
2506d7ed1f
Use PIMPL so that the interpolant can be passed as a functor.
2017-03-02 17:16:21 -06:00
jzmaddock
60dc89c74d
Merge branch 'develop'
2017-03-02 18:57:32 +00:00
jzmaddock
47714b4e72
Doc update of TODO list.
2017-03-02 18:56:57 +00:00
Nick Thompson
c42e8feebe
Remove all traces of the linguistically incorrect word 'routine'.
2017-03-02 12:30:12 -06:00
Nick Thompson
2b9d88d352
Fixes suggested by code review of PR #57 .
2017-03-02 11:54:55 -06:00
Nick Thompson
b157403fd9
Do not use Kahan summation to compute average; use update procedure that cannot overflow recommended by Knuth.
2017-02-27 20:58:42 -06:00
jzmaddock
f35a3551b0
Merge pull request #56 from NAThompson/patch-2
...
Remove finished TODO list entries
2017-02-27 18:12:02 +00:00
jzmaddock
567f7c7548
Merge branch 'develop'
2017-02-25 18:49:46 +00:00
jzmaddock
b0b0810701
Update history and regenerate docs for 1.64.
2017-02-25 18:48:39 +00:00
Nick Thompson
fee20ab932
Given a function f, known at evenly spaced samples y_j = f(a + jh),
...
this function constructs an interpolant using compactly supported cubic b splines.
The advantage of using splines of compact support over traditional cubic splines
is that compact support makes the splines well-conditioned.
The interpolant is constructed in O(N) time and can be evaluated in constant time.
Its error is O(h^4), and obeys the interpolating condition s(x_j) = f(x_j) for all samples.
In addition, f' can be estimated from s', albeit with lower accuracy.
This routine is cppcheck clean, and is clean under AddressSanitizer and MemorySanitizer.
2017-02-23 18:21:06 -06:00
Nick
fa4dd6ff4c
Remove finished TODO list entries
...
Removing Jacobi elliptic functions and cylindrical Bessel/Neumann derivatives from TODO list, as they have been completed.
2017-02-22 14:08:22 -06:00
jzmaddock
4c19a1ec34
Remove unneeded parameters in new beesel J/K code.
...
Also fix some multiprecision-conceptual errors.
2017-01-29 19:18:36 +00:00
jzmaddock
38eb9d3e38
Update docs for new Bessel K0 and K1 approximation code.
2017-01-24 18:35:54 +00:00
jzmaddock
fe66909b23
Reorder some declarations to keep GCC happy.
...
Remove some dead code.
2017-01-23 19:34:34 +00:00
jzmaddock
7922883e7b
Add improved approximations for K0 and K1.
...
Based on http://www.advanpix.com/2016/01/05/rational-approximations-for-the-modified-bessel-function-of-the-second-kind-k1-for-computations-with-double-precision/
2017-01-23 17:45:51 +00:00
jzmaddock
2dc47a631a
Improve constant initialization for I0 and I1.
2017-01-23 17:45:00 +00:00
jzmaddock
cc8e300bae
Update I0 and I1 to use better approximations from Pavel Holoborodko
...
See: http://www.advanpix.com/2015/11/11/rational-approximations-for-the-modified-bessel-function-of-the-first-kind-i0-computations-double-precision/
2017-01-18 18:56:27 +00:00
jzmaddock
8507da5a59
Fix construct from floating point create_test_value overload.
2017-01-03 18:56:42 +00:00
pabristow
eb2707e8b0
Failed attempts to get create_test_value to work.
2017-01-02 18:31:16 +00:00
Michael Krasnyk
3a6a2952b8
Added missing header path, gmp and mpfr libraries
2016-12-29 23:37:40 +01:00
pabristow
ffb025ca2c
First very rough prototype of Lambert W function, example of calculating diode current versus voltage, and some tests, including multiprecision and fixed_point types. Not yet using policies and trouble near the singularity at z=-exp(-1) and large z.
2016-12-22 18:30:27 +00:00
pabristow
78320adb7a
return 0 to T(0) in float_distance changed because fixed-point requires explicit construction
2016-12-05 16:41:18 +00:00
jzmaddock
1844134d07
Changes to call correct error handlers in C99 annex F cases.
2016-11-30 18:57:11 +00:00