exp(v\pi\imath/2) I_v(-\imath z)\qquad (\Im z > 0) J_v(z) = \exp(-v\pi\imath/2) I_v(\imath z)\qquad (\Im z < 0) For negative `v` values the formula, .. math:: J_{-v}(z) = J_v(z) \cos(\pi v) - Y_v(z) \sin(\pi v) is used, where :math:`Y_v(z)` is the Bessel function of the second kind, computed using the AMOS routine `zbesy`. Note that the second term is exactly zero for integer `v`; to improve accuracy the second term is explicitly omitted for `v` values such that `v = floor(v)`. Not to be confused with the spherical Bessel functions (see `spherical_jn`). References ---------- .. [1] Donald E. Amos, "AMOS, A Portable Package for Bessel Functions of a Complex Argument and Nonnegative Order", http://netlib.org/amos/ Examples -------- Evaluate the function of order 0 at one point. >>> from scipy.special import jv >>> jv(0, 1.) 0.7651976865579666 Evaluate the function at one point for different orders. >>> jv(0, 1.), jv(1, 1.), jv(1.5, 1.) (0.7651976865579666, 0.44005058574493355, 0.24029783912342725) The evaluation for different orders can be carried out in one call by providing a list or NumPy array as argument for the `v` parameter: >>> jv([0, 1, 1.5], 1.) array([0.76519769, 0.44005059, 0.24029784]) Evaluate the function at several points for order 0 by providing an array for `z`. >>> import numpy as np >>> points = np.array([-2., 0., 3.]) >>> jv(0, points) array([ 0.22389078, 1. , -0.26005195]) If `z` is an array, the order parameter `v` must be broadcastable to the correct shape if different orders shall be computed in one call. To calculate the orders 0 and 1 for an 1D array: >>> orders = np.array([[0], [1]]) >>> orders.shape (2, 1) >>> jv(orders, points) array([[ 0.22389078, 1. , -0.26005195], [-0.57672481, 0. , 0.33905896]]) Plot the functions of order 0 to 3 from -10 to 10. >>> import matplotlib.pyplot as plt >>> fig, ax = plt.subplots() >>> x = np.linspace(-10., 10., 1000) >>> for i in range(4): ... ax.plot(x, jv(i, x), label=f'$J_{i!r}$') >>> ax.legend() >>> plt.show() Ú