I need to use Hankel functions of the second kind, that is H_n^(2) with n in {0,1,2}, in Tensorflow. http://mathworld.wolfram.com/HankelFunctionoftheSecondKind.html
Tensorflow, however, does not have these functions in its standard library. It only offers modified Bessel functions of the first kind I0 and I1. https://www.tensorflow.org/api_docs/python/tf/math/bessel_i0 https://www.tensorflow.org/api_docs/python/tf/math/bessel_i1
I can maybe construct H_0(2) and H_1^(2) from I0 and I1, respectively, but what about H_2^(2)?
An alternative option I tested was calling scipy Hankel functions from Tensorflow but that doesn't ultimately work because the error cannot be back-propagated correctly through these non-Tensorflow functions.
Thus my question: has anyone sample code to implement H_n^(2) functions in Tensorflow or other recommendations/tricks?