diff options
author | Charles Harris <charlesr.harris@gmail.com> | 2011-12-18 17:43:10 -0700 |
---|---|---|
committer | Charles Harris <charlesr.harris@gmail.com> | 2012-01-09 10:45:13 -0700 |
commit | 26e2ae4b8b55bc82cd46d5d309ac5eced4bc8fe4 (patch) | |
tree | 366849a5c8586ba6105b995da7c7d7a038edd9d1 /numpy/polynomial/tests/test_polynomial.py | |
parent | 8e8b85d404e8453e469b3273528c4dc5f30b819f (diff) | |
download | numpy-26e2ae4b8b55bc82cd46d5d309ac5eced4bc8fe4.tar.gz |
BUG: The derivative tests were using incorrect test coefficients.
The coefficients used were [1] + [0]*i instead of [0]*i + [1].
Diffstat (limited to 'numpy/polynomial/tests/test_polynomial.py')
-rw-r--r-- | numpy/polynomial/tests/test_polynomial.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/numpy/polynomial/tests/test_polynomial.py b/numpy/polynomial/tests/test_polynomial.py index 4b93ea118..5fcb86946 100644 --- a/numpy/polynomial/tests/test_polynomial.py +++ b/numpy/polynomial/tests/test_polynomial.py @@ -209,21 +209,21 @@ class TestCalculus(TestCase) : # check that zeroth deriviative does nothing for i in range(5) : - tgt = [1] + [0]*i + tgt = [0]*i + [1] res = poly.polyder(tgt, m=0) assert_equal(trim(res), trim(tgt)) # check that derivation is the inverse of integration for i in range(5) : for j in range(2,5) : - tgt = [1] + [0]*i + tgt = [0]*i + [1] res = poly.polyder(poly.polyint(tgt, m=j), m=j) assert_almost_equal(trim(res), trim(tgt)) # check derivation with scaling for i in range(5) : for j in range(2,5) : - tgt = [1] + [0]*i + tgt = [0]*i + [1] res = poly.polyder(poly.polyint(tgt, m=j, scl=2), m=j, scl=.5) assert_almost_equal(trim(res), trim(tgt)) |