{"id":23838,"library":"hankel","title":"Hankel","description":"Hankel Transformations using the method of Ogata 2005. Current version 1.2.2, requires Python >=3.6. Maintenance mode with occasional bugfixes.","status":"active","version":"1.2.2","language":"python","source_language":"en","source_url":"https://github.com/steven-murray/hankel","tags":["hankel transform","numerical integration","bessel","physics"],"install":[{"cmd":"pip install hankel","lang":"bash","label":"PyPI"}],"dependencies":[{"reason":"Core numerical operations and FFT","package":"numpy","optional":false},{"reason":"Bessel functions and special functions","package":"scipy","optional":false}],"imports":[{"note":"","wrong":"","symbol":"HankelTransform","correct":"from hankel import HankelTransform"},{"note":"","wrong":"","symbol":"SymmetricFourierTransform","correct":"from hankel import SymmetricFourierTransform"}],"quickstart":{"code":"from hankel import HankelTransform\nimport numpy as np\n\nht = HankelTransform(nu=0, N=200, h=0.05)\nresult = ht.transform(lambda x: np.exp(-x**2), np.array([1.0, 2.0]))\nprint(result)","lang":"python","description":"Compute Hankel transform of f(x)=exp(-x^2) at points k=1,2."},"warnings":[{"fix":"Use `algorithm='direct' or 'ogata'` instead.","message":"The `algebraic_decay` parameter in `__init__` is deprecated since v1.0.","severity":"deprecated","affected_versions":">=1.0"},{"fix":"Increase `N` (e.g., 200-500) and compare results.","message":"Default `N` (number of integration points) may be too small for accurate transforms; always check convergence.","severity":"gotcha","affected_versions":"all"},{"fix":"Adjust `h` value and recompute, or pin to v0.3.x.","message":"In v1.0, the `h` parameter spacing was changed from logarithmic to semi-logarithmic scaling; results differ from v0.3.x.","severity":"breaking","affected_versions":"<1.0 and >=1.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Use `from hankel import HankelTransform`.","cause":"Wrong import path, e.g., `import hankel` and then `hankel.HankelTransform` instead of direct import.","error":"AttributeError: module 'hankel' has no attribute 'HankelTransform'"},{"fix":"Ensure `h` > 0, e.g., 0.05.","cause":"Provided non-positive `h` parameter.","error":"ValueError: h must be positive"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}