On Wed, Apr 3, 2019 at 2:47 PM wrote:
> The simplest example:
>
> f = piecewise([[[-pi-1, -pi/2], 0], [(-pi/2,pi/2), 1], [[pi/2, pi+1], 0]])
> print(f(-pi))
>
>
I'm not sure why it isn't evaluating symbolic numbers like pi, but here's a
work-around:
sage: f = piecewise([((-pi-*1*, -pi/*2*), *0*)
The simplest example:
f = piecewise([[[-pi-1, -pi/2], 0], [(-pi/2,pi/2), 1], [[pi/2, pi+1], 0]])
print(f(-pi))
which gives the traceback:
TypeError Traceback (most recent call last)
in ()
> 1 f(-pi)
/Applications/SageMath-8.7.app/Contents/Resources/sage/loca