The Hankel transform is essentially a radial version of the Fourier transform. For a circularly symmetric function , its zero-order Hankel transform is where denotes the Bessel function of the first kind. This transform preserves radial information and appears in solutions of wave and diffusion equations with cylindrical symmetry.
The ordinary Fourier transform decomposes a function into plane waves . In polar coordinates, radial waves involve Bessel functions because they satisfy the differential equation . The Hankel transform inherits orthogonality properties from these Bessel functions.
The Bessel function can be expressed as a power series . In practice we approximate using the first several terms. Because the integrand also contains , higher powers contribute less for moderate arguments, making the approximation effective.
To compute numerically, we evaluate the integrand on a grid from to a chosen upper limit. Simpson's rule averages pairs of intervals to approximate the integral with good accuracy. Because the Hankel transform integrates to infinity, we rely on the user to pick an upper limit large enough that the tail contributions are negligible for the function in question.
Choosing a larger limit may improve accuracy at the cost of more function evaluations. Similarly, decreasing the step size improves the Simpson approximation but requires more computation. The default values provide a reasonable trade-off for smooth, rapidly decaying functions like Gaussians.
Enter your radial function in terms of r
. Good examples include exp(-r^2)
or 1/(1+r^2)
. Specify the parameter where you want the transform evaluated and select an upper integration limit. When you press the button, the script samples the function at evenly spaced points, computes the Bessel factor with a short series, and applies Simpson's rule to produce an approximate value for .
The output appears below the form with six decimal places. You can explore how changes with or how different functions decay. Many problems in optics, acoustics, and electromagnetism reduce to Hankel transforms when radial symmetry is present. Understanding these transforms provides insight into diffraction patterns, beam propagation, and solutions of Bessel-type equations.
The integral is approximated as
where are Simpson weights and are equally spaced sample points. The series used for includes ten terms, providing good accuracy for arguments less than about . You can adjust the step size or extend the series for higher precision.
Because everything runs in your browser, no data leaves your computer. This makes it convenient for quick checks or classroom demonstrations. For heavy computational tasks, specialized numerical libraries might be preferable.
Try computing the transform of exp(-r^2)
at several values and compare it to the known analytic result . Seeing this numerical agreement reinforces both the theory and the correctness of the algorithm. The Hankel transform provides a window into radial phenomena ranging from sound waves in a cylindrical duct to the diffraction of laser beams.
Beyond physics, Hankel transforms also arise in probability theory and machine learning when dealing with radial basis functions. Because radial kernels depend only on distance, their Fourier transforms reduce to Hankel transforms. Understanding how these transforms behave helps in designing efficient algorithms for pattern recognition and density estimation on high-dimensional data sets.
Compute the covariance matrix for two or three datasets and explore its meaning.
Approximate the value of a double integral over a rectangular region.
Generate Padé approximants for a given function using series coefficients.