-
-
Notifications
You must be signed in to change notification settings - Fork 686
Closed
Milestone
Description
The polylog function (from Pynac) treats 1.0 like 1 and does not immediately evalf with some numeric arguments.
sage: polylog(2,1)
1/6*pi^2
sage: polylog(2.,1)
1.64493406684823
sage: polylog(2,1.0)
1/6*pi^2
sage: polylog(2,0.9)
polylog(2, 0.900000000000000)
sage: _.n()
TypeError: cannot evaluate symbolic expression numerically
What makes polylog different is that the Sage polylog has no special value logic and calls Pynac's Li_eval for everything. This handles special values (incorrectly if an arg is FP) and sends everything else back with .hold(). So you need N() to get FP results that are not special. With FP Pynac is called which then calls Sage/mpmath. But this then bombs with FP args.
Depends on #22969
Depends on #23077
Depends on #23134
CC: @kiwifb
Component: symbolics
Keywords: pynac special
Author: Ralf Stephan
Branch/Commit: 59d4b29
Reviewer: Paul Masson, Dima Pasechnik
Issue created by migration from https://trac.sagemath.org/ticket/18386