Skip to content
fn

spherical_bessel_j0

→Tensor
spherical_bessel_j0(x: Tensor)

Spherical Bessel function of the first kind, order 0.

Computes j0(x)=sin⁡x/xj_0(x) = \sin x / x with the continuous extension j0(0)=1j_0(0) = 1. Arises in 3D wave / scattering problems and is the radial component of plane waves expanded in spherical harmonics.

Parameters

Input tensor; any floating-point dtype.

Returns

Tensor

j0(x)j_0(x) element-wise, same shape and dtype as x.

Notes

Mathematical definition:

j0(x)=sin⁡xx,j0(0)=1,j0(±∞)=0.j_0(x) = \frac{\sin x}{x}, \qquad j_0(0) = 1, \qquad j_0(\pm\infty) = 0.

For ∣x∣<1|x| < 1 the value is the Maclaurin series in x2x^2, so the function is differentiable across the origin to every order (the quotient's own slope is the difference of two 1/x1/x terms and loses it); beyond, sin⁡x/x\sin x / x is evaluated as written. Related to the normalised sinc: j0(x)=sinc(x/π)j_0(x) = \mathrm{sinc}(x / \pi).

Examples

>>> import lucid
>>> from lucid.special import spherical_bessel_j0
>>> spherical_bessel_j0(lucid.tensor([0.0, 1.0, 2.0]))
tensor([1., 0.8415, 0.4546])