Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
23077: fix jacobi_P numerics
Browse files Browse the repository at this point in the history
  • Loading branch information
rwst committed May 26, 2017
1 parent cb88513 commit b5c0864
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/sage/functions/orthogonal_polys.py
Original file line number Diff line number Diff line change
Expand Up @@ -1942,7 +1942,10 @@ def _evalf_(self, n, a, b, x, **kwds):
prec = the_parent.precision()
BF = CBF(prec+5)
ret = BF(x).jacobi_P(BF(n), BF(a), BF(b))
return the_parent(ret)
try:
return the_parent(ret)
except (TypeError, ValueError):
return the_parent.complex_field()(ret)

jacobi_P = Func_jacobi_P()

Expand Down

0 comments on commit b5c0864

Please sign in to comment.