Somebody called gh-JCGoran seems to have stumbled on this already, and reported Trac#27078.
I also note that the sympy representatin of this function is questionable...