scipy.special.i0e#

scipy.special.i0e(x, out=None) = <ufunc 'i0e'>#

Exponentially scaled modified Bessel function of order 0.

Defined as:

i0e(x) = exp(-abs(x)) * i0(x).
Parameters:
xarray_like

Argument (float)

outndarray, optional

Optional output array for the function values

Returns:
Iscalar or ndarray

Value of the exponentially scaled modified Bessel function of order 0 at x.

See also

iv

Modified Bessel function of the first kind

i0

Modified Bessel function of order 0

Notes

The range is partitioned into the two intervals [0, 8] and (8, infinity). Chebyshev polynomial expansions are employed in each interval. The polynomial expansions used are the same as those in i0, but they are not multiplied by the dominant exponential factor.

This function is a wrapper for the Cephes [1] routine i0e.

References

[1]

Cephes Mathematical Functions Library, http://www.netlib.org/cephes/

Examples

Calculate the function at one point:

>>> from scipy.special import i0e
>>> i0e(1.)
0.46575960759364043

Calculate the function at several points:

>>> import numpy as np
>>> i0e(np.array([-2., 0., 3.]))
array([0.30850832, 1.        , 0.24300035])

Plot the function from -10 to 10.

>>> import matplotlib.pyplot as plt
>>> fig, ax = plt.subplots()
>>> x = np.linspace(-10., 10., 1000)
>>> y = i0e(x)
>>> ax.plot(x, y)
>>> plt.show()
../../_images/scipy-special-i0e-1_00_00.png

Exponentially scaled Bessel functions are useful for large arguments for which the unscaled Bessel functions overflow or lose precision. In the following example i0 returns infinity whereas i0e still returns a finite number.

>>> from scipy.special import i0
>>> i0(1000.), i0e(1000.)
(inf, 0.012617240455891257)