firedrakeproject / tsfc

Two-stage form compiler
Other
15 stars 24 forks source link

Bessel functions for complex numbers #176

Open miklos1 opened 5 years ago

miklos1 commented 5 years ago

There is apparent demand for using Bessel functions in complex-values PDEs, however, is there a C or C++ implementation available somewhere? Quasi-standard C libraries have j0, j1, jn, y0, y1, and yn, but only for reals. The Boost implementation is templated, but uses comparisons, therefore do not work when instantiated with complex numbers.

wence- commented 5 years ago

AFAICT, the whole world uses the implementation from here: https://dl.acm.org/citation.cfm?doid=7921.214331

A C++ wrapper is available here: https://blog.joey-dumont.ca/complex_bessel/