Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Function_cot.__evalf_() missing some cases #15179

Closed
burcin opened this issue Sep 9, 2013 · 2 comments
Closed

Function_cot.__evalf_() missing some cases #15179

burcin opened this issue Sep 9, 2013 · 2 comments

Comments

@burcin
Copy link

burcin commented Sep 9, 2013

From this sage-support thread:

sage: u = cot(pi*x)
sage: u.is_zero()  
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<snip>
/home/burcin/sage/sage-5.11.beta3/local/lib/python2.7/site-packages/sage/functions/trig.pyc in _evalf_(self, x, parent)
    377         if parent is float:
    378             return 1/math.tan(x)
--> 379         return x.cot()
    380 
    381     def _derivative_(self, x, diff_param=None):
<snip>
AttributeError: 'sage.rings.complex_interval.ComplexIntervalFieldElement' object has no attribute 'cot'

There are many objects which end up as x in Function_cot._evalf_() that do not support .cot().

We should check if the other functions in sage/functions/trig.py handle more input types properly.

CC: @eviatarbach

Component: symbolics

Reviewer: Jeroen Demeyer

Issue created by migration from https://trac.sagemath.org/ticket/15179

@burcin burcin added this to the sage-6.1 milestone Sep 9, 2013
@sagetrac-vbraun-spam sagetrac-vbraun-spam mannequin modified the milestones: sage-6.1, sage-6.2 Jan 30, 2014
@sagetrac-vbraun-spam sagetrac-vbraun-spam mannequin modified the milestones: sage-6.2, sage-6.3 May 6, 2014
@sagetrac-vbraun-spam sagetrac-vbraun-spam mannequin modified the milestones: sage-6.3, sage-6.4 Aug 10, 2014
@jdemeyer
Copy link

comment:4

worksforme:

sage: sage: u = cot(pi*x)
sage: sage: u.is_zero()  
False

@jdemeyer
Copy link

Reviewer: Jeroen Demeyer

@jdemeyer jdemeyer removed this from the sage-6.4 milestone Oct 11, 2014
@vbraun vbraun closed this as completed Oct 13, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants