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

bind SymPy's ComplexInfinity #17493

Closed
rwst opened this issue Dec 13, 2014 · 35 comments
Closed

bind SymPy's ComplexInfinity #17493

rwst opened this issue Dec 13, 2014 · 35 comments

Comments

@rwst
Copy link

rwst commented Dec 13, 2014

sage: import sympy
sage: SR(sympy.factorial(-2))
---------------------------------------------------------------------------
...
AttributeError: 'ComplexInfinity' object has no attribute '_sage_'

Depends on #20185

Component: interfaces

Keywords: unsigned infinity

Author: Ralf Stephan

Branch/Commit: 0ef8018

Reviewer: Karl-Dieter Crisman, Marc Mezzarobba

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

@rwst rwst added this to the sage-6.5 milestone Dec 13, 2014
@rwst
Copy link
Author

rwst commented Dec 14, 2014

Branch: u/rws/bind_sympy_s_complexinfinity

@rwst
Copy link
Author

rwst commented Dec 14, 2014

Commit: 3dccb4e

@rwst
Copy link
Author

rwst commented Dec 14, 2014

comment:2

That would be all. However, I have no idea atm how to change sympify to convert to zoo. EDIT. it's not zoo, it's Infinity as well.


New commits:

3dccb4e17493: add `_sage_` method to ComplexInfinity

@rwst
Copy link
Author

rwst commented Dec 14, 2014

Author: Ralf Stephan

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Dec 14, 2014

Branch pushed to git repo; I updated commit sha1. New commits:

7ca600a17493: doctest

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Dec 14, 2014

Changed commit from 3dccb4e to 7ca600a

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Dec 16, 2014

Changed commit from 7ca600a to 4928fa4

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Dec 16, 2014

Branch pushed to git repo; I updated commit sha1. New commits:

4928fa417493: remove unrelated patchfile

@rwst
Copy link
Author

rwst commented Dec 16, 2014

Changed keywords from none to unsigned infinity

@kcrisman
Copy link
Member

comment:6

How does this one relate to #14723? I assume this is also part of your large upstream patch? I guess in principle this one can just depend on #14723 since the .p1 is correct if that one is .p0.

@kcrisman
Copy link
Member

Upstream: Not yet reported upstream; Will do shortly.

@rwst
Copy link
Author

rwst commented Dec 18, 2014

Dependencies: #14723

@rwst
Copy link
Author

rwst commented Dec 18, 2014

Changed upstream from Not yet reported upstream; Will do shortly. to Completely fixed; Fix reported upstream

@rwst
Copy link
Author

rwst commented Dec 18, 2014

comment:7

Replying to @kcrisman:

How does this one relate to #14723? I assume this is also part of your large upstream patch? I guess in principle this one can just depend on #14723 since the .p1 is correct if that one is .p0.

Yes and yes. Github pull request: sympy/sympy#8592

@kcrisman
Copy link
Member

comment:8

I have to say I'm totally mystified as to why this is called zoo. Is this a pun?

Here is something we might as well take care of here. But the change here itself is fine and useful.

sage: a = oo
sage: b = -oo
sage: c = UnsignedInfinityRing.gen()  
# really, the easiest way?  probably should do better than that, not here
sage: a
+Infinity
sage: b
-Infinity
sage: c
Infinity
sage: a._sympy_()
oo
sage: b._sympy_()
-oo
sage: c._sympy_()
---------------------------------------------------------------------------
AttributeError: 'UnsignedInfinity' object has no attribute '_sympy_'

A nice test for that would be

gamma(-3)._sympy_() is sympy.factorial(-2)
gamma(-3) is sympy.factorial(-2)._sage_()

(note that putting it in SR makes it == but not is).

@kcrisman
Copy link
Member

kcrisman commented Feb 3, 2015

Reviewer: Karl-Dieter Crisman

@kcrisman
Copy link
Member

kcrisman commented Feb 3, 2015

comment:9

We really should have both directions on this ticket, I think.

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Feb 3, 2015

Branch pushed to git repo; I updated commit sha1. New commits:

1aff5f2Merge branch 'develop' into t/17493/bind_sympy_s_complexinfinity
27e2fc717493: add unsigned_infinity conversion to sympy

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Feb 3, 2015

Changed commit from 4928fa4 to 27e2fc7

@rwst
Copy link
Author

rwst commented Feb 3, 2015

comment:11

Ah it was easier than thought.

@kcrisman
Copy link
Member

kcrisman commented Feb 3, 2015

comment:12

Ah it was easier than thought.

That's why I asked, otherwise it would have been a separate ticket for sure. I'll get to this today for sure.

@mezzarobba
Copy link
Member

comment:14

Conflicts with #14723

@rwst
Copy link
Author

rwst commented Feb 7, 2015

comment:15

Resolved in #14723.

@jdemeyer jdemeyer removed this from the sage-6.5 milestone Feb 13, 2015
@vbraun vbraun closed this as completed Sep 25, 2015
@vbraun vbraun reopened this Sep 25, 2015
@vbraun
Copy link
Member

vbraun commented Sep 25, 2015

comment:21

Sorry, misunderstood the last comment.

Whats up with the dependency?

PSA: sage-pending tickets are not getting merged

@rwst
Copy link
Author

rwst commented Sep 25, 2015

comment:22

The dependency is pending (because there is still no new SymPy release---0.7.6.1 is just a quick fix of Jupyter stuff) so this is pending, too.

@rwst
Copy link
Author

rwst commented Mar 14, 2016

Changed branch from u/kcrisman/ticket/17493 to public/17493

@rwst
Copy link
Author

rwst commented Mar 14, 2016

Changed commit from a514394 to 0ef8018

@rwst
Copy link
Author

rwst commented Mar 14, 2016

New commits:

f89b9e8Merge branch 'u/kcrisman/ticket/17493' of git://trac.sagemath.org/sage into i17493
0ef8018remove now unnecessary patch

@rwst
Copy link
Author

rwst commented Mar 14, 2016

Changed upstream from Completely fixed; Fix reported upstream to none

@rwst
Copy link
Author

rwst commented Mar 14, 2016

Changed dependencies from #14723 to #20185

@mezzarobba
Copy link
Member

Changed reviewer from Karl-Dieter Crisman to Karl-Dieter Crisman, Marc Mezzarobba

@vbraun
Copy link
Member

vbraun commented Mar 28, 2016

Changed branch from public/17493 to 0ef8018

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

5 participants