On 2014-09-26, kcrisman <kcris...@gmail.com> wrote: > >> >> >> >> For Sage, fixing the problem is actually trivial: when the >> >> >> hypergeometric >> >> >> function is a polynomial (and at least when the inputs are exact), >> >> >> don't >> >> >> call mpmath; just evaluate the polynomial directly and then call >> .n() >> >> >> on the >> >> >> result. >> >> >> >> >> > >> >> > Except then Sage would have to know when it is a polynomial, and >> >> > probably we >> >> > would need to ask Maxima for that (assuming it knows). So maybe not >> >> > completely trivial to make sure it works. >> >> >> >> It's a polynomial when any of the first parameters is a nonpositive >> >> integer. >> >> >> > >> > Is that "if and only if"? That would certainly be convenient. >> >> Yes, that follows immediately from the definition. >> >> >> > Well, then I guess this shouldn't be too hard to implement... I will admit > that I will not be the one doing it, but sounds like a no-brainer.
IMHO it would be great to have this in mpmath rather than a Sage workaround. (AFAIK, hypergeometric_U is vulnerable to the very same problem, so this would mean the workaround would either be needed in several places...) Dima -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.