#6926: multiple bugs in plotting symbolic expressions
----------------------+-----------------------------------------------------
 Reporter:  was       |       Owner:  was       
     Type:  defect    |      Status:  new       
 Priority:  major     |   Milestone:  sage-4.1.2
Component:  graphics  |    Keywords:            
 Reviewer:            |      Author:            
   Merged:            |  
----------------------+-----------------------------------------------------
 This is a bug:
 {{{
 sage: plot(abs(exp(i*x)), xmin=1,xmax=2)
 Traceback (most recent call last):
 ...
 TypeError: float() argument must be a string or a number
 }}}
 The above should never happen, since the outputs of the function should be
 floats.

 Doing the obvious workaround yields another totally different bug!
 {{{
 sage: plot(lambda x: float(abs(exp(i*x))), xmin=1,xmax=2)
 Traceback (most recent call last):
 ...
 ZeroDivisionError: float division
 }}}

 The above ZeroDivisionError comes from trying incorrectly to scale the
 y-axis!

 The following works, where we do two things explicitly, both of which
 should be completely automatic.
 {{{
 sage: plot(lambda x: float(abs(exp(i*x))), xmin=1,xmax=2, ymin=0,ymax=1)
 }}}

 This was reported by Andi Walz on sage-support.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/6926>
Sage <http://sagemath.org/>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to