summaryrefslogtreecommitdiff
path: root/numpy/lib/function_base.py
diff options
context:
space:
mode:
authorTravis Oliphant <oliphant@enthought.com>2006-01-05 10:57:06 +0000
committerTravis Oliphant <oliphant@enthought.com>2006-01-05 10:57:06 +0000
commitf8f8ca74391b5681d4e16bccc282ada87a6d0b8d (patch)
treecc2ff81857bd9c26f215dba2d8ccff4e774f1ad7 /numpy/lib/function_base.py
parentcec9a2ee40ef84dab429e71825ea9c4c9765aa40 (diff)
downloadnumpy-f8f8ca74391b5681d4e16bccc282ada87a6d0b8d.tar.gz
Copy input for i0 calculation.
Diffstat (limited to 'numpy/lib/function_base.py')
-rw-r--r--numpy/lib/function_base.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/numpy/lib/function_base.py b/numpy/lib/function_base.py
index b3c94a264..77561246e 100644
--- a/numpy/lib/function_base.py
+++ b/numpy/lib/function_base.py
@@ -772,7 +772,7 @@ def _i0_2(x):
return exp(x) * _chbevl(32.0/x - 2.0, _i0B) / sqrt(x)
def i0(x):
- x = atleast_1d(x)
+ x = atleast_1d(x).copy()
y = empty_like(x)
ind = (x<0)
x[ind] = -x[ind]