Mark Dickinson
12748b003c
Issue #7518 : Move substitute definitions of C99 math functions from
...
pymath.c to Modules/_math.c.
2009-12-21 15:22:00 +00:00
Mark Dickinson
5698977186
math.factorial depends on PyLong_AsLong correctly converting floats; rewrite
...
it to do the conversion explicitly instead. See issue #7550 .
2009-12-20 13:58:18 +00:00
Mark Dickinson
5ff37ae14b
Issue #3366 : Add error function and complementary error function to
...
math module.
2009-12-19 11:07:23 +00:00
Mark Dickinson
9cae178f21
Issue #3366 : Add expm1 function to math module. Thanks Eric Smith for
...
testing on Windows.
2009-12-16 20:13:40 +00:00
Mark Dickinson
9be87bc992
Issue #3366 : Add lgamma function to math module.
2009-12-11 17:29:33 +00:00
Georg Brandl
a8f8bed203
Use a single style for all the docstrings in the math module.
2009-10-29 20:54:03 +00:00
Georg Brandl
40777e6606
Use the correct function name in docstring.
2009-10-29 20:38:32 +00:00
Mark Dickinson
b93fff0a57
Issue #3366 : Add gamma function to math module.
...
(lgamma, erf and erfc to follow).
2009-09-28 18:54:55 +00:00
Benjamin Peterson
9de7298102
remove redundant sentence
2008-12-20 22:49:24 +00:00
Benjamin Peterson
fed67fd41e
beef up docstring
2008-12-20 02:57:19 +00:00
Mark Dickinson
4c96fa5525
Issues #3167 , #3682 : tests for math.log and math.log10 were failing on
...
Solaris and OpenBSD. Fix this by handling special values and domain
errors directly in mathmodule.c, passing only positive nonspecial floats
to the system log/log10.
2008-12-11 19:28:08 +00:00
Mark Dickinson
ff3fdce0d2
Replace math.sum with math.fsum in a couple of comments
...
that were missed by r65308
2008-07-30 16:25:16 +00:00
Mark Dickinson
fef6b13c32
Rename math.sum to math.fsum
2008-07-30 16:20:10 +00:00
Mark Dickinson
abe0aee3cf
Fix special-value handling for math.sum.
...
Also minor cleanups to the code: fix tabbing, remove
trailing whitespace, and reformat to fit into 80
columns.
2008-07-30 12:01:41 +00:00
Mark Dickinson
2fcd8c9703
Fix another typo in math_sum comment
2008-06-20 15:26:19 +00:00
Andrew M. Kuchling
5f198bee4e
Fix comment typos
2008-06-20 02:11:42 +00:00
Raymond Hettinger
2281da42b0
Fix double decref.
2008-06-18 00:56:57 +00:00
Mark Dickinson
fb1c4b98e9
Issue 3118: make test_math pass on Ubuntu/ia64. exp(-745.0) was raising
...
OverflowError incorrectly on this platform, presumably as a result of
the libm setting errno = ERANGE for this call.
2008-06-17 21:16:55 +00:00
Raymond Hettinger
d623414141
Unhappy buildbots. Revert 64052. Long doubles have unexpected effects on some builds.
2008-06-09 11:24:47 +00:00
Raymond Hettinger
7b1ed66372
Address double-rounding scenarios by setting all variables to long doubles.
2008-06-09 09:29:17 +00:00
Raymond Hettinger
ecbdd2e9b0
Issue #2138 : Add math.factorial().
2008-06-09 06:54:45 +00:00
Raymond Hettinger
ef712d6fd3
* Mark intermedidate computes values (hi, lo, yr) as volatile.
...
* Expand comments.
* Swap variable names in the sum_exact code so that x and y
are consistently chosen as the larger and smaller magnitude
values respectively.
2008-05-30 18:20:50 +00:00
Raymond Hettinger
2a9179ac73
Fix two typos.
2008-05-29 08:38:23 +00:00
Raymond Hettinger
778d5cc4fb
Tweak the comments and formatting.
2008-05-23 04:32:43 +00:00
Mark Dickinson
99dfe92759
Issue #2819 : Add math.sum, a function that sums a sequence of floats
...
efficiently but with no intermediate loss of precision. Based on
Raymond Hettinger's ASPN recipe. Thanks Jean Brouwers for the patch.
2008-05-23 01:35:30 +00:00