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

fix coefficients for symbolic series #17399

Closed
rwst opened this issue Nov 26, 2014 · 14 comments
Closed

fix coefficients for symbolic series #17399

rwst opened this issue Nov 26, 2014 · 14 comments

Comments

@rwst
Copy link

rwst commented Nov 26, 2014

There is no SR.function that gets the coefficients of SR.series; rather, coeffs() etc give confusing results; truncate() must be prepended manually.

sage: x=var('x')
sage: s=(1/(1-x)).series(x,6)
sage: s.coeffs()
[[x^5 + x^4 + x^3 + x^2 + x + Order(x^6) + 1, 0]]
sage: s.coefficient(4)
0

Working around with s.truncate() is only a fig leaf.

Extracted from http://ask.sagemath.org/question/24968/coefficients-in-polynomial-ring-over-symbolic-ring/

Depends on #17438

CC: @kcrisman

Component: symbolics

Author: Ralf Stephan

Branch/Commit: 0b9914f

Reviewer: Bruno Grenet

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

@rwst rwst added this to the sage-6.5 milestone Nov 26, 2014
@rwst

This comment has been minimized.

@rwst
Copy link
Author

rwst commented Dec 2, 2014

@rwst
Copy link
Author

rwst commented Dec 2, 2014

New commits:

32ae67c17399: do not let maxima handle ex.series coefficients

@rwst
Copy link
Author

rwst commented Dec 2, 2014

Commit: 32ae67c

@rwst
Copy link
Author

rwst commented Dec 2, 2014

Author: Ralf Stephan

@rwst
Copy link
Author

rwst commented Dec 3, 2014

Dependencies: #17438

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Dec 4, 2014

Changed commit from 32ae67c to 6cd5286

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Dec 4, 2014

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

99820cf17399: roll back previous commit to allow merge of 17428
d7da52c17438: implement coeff list
9452fa917438: deprecate ex.coeff/coeffs()
0fec12917438: implement ex.list()
168b659Merge branch 'u/rws/coefficients_of_symbolic_expressions_revamp' of trac.sagemath.org:sage into t/17399/fix_coefficients_for_symbolic_series
6cd528617399: handle series in ex.coefficients()

@bgrenet
Copy link

bgrenet commented Jan 6, 2015

comment:8

You have introduced lines made of blank symbols in src/sage/symbolic/expression.pyx. Please replace them by empty lines. It seems to be the case also on the code introduced for the related ticket #17348. Maybe you could replace all of them in expression.pyx at once.

Note. With sed: sed -i -e "s/^ *$//" src/sage/symbolic/expression.pyx.

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Jan 7, 2015

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

0b9914f17399: remove whitespace changes

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Jan 7, 2015

Changed commit from 6cd5286 to 0b9914f

@bgrenet
Copy link

bgrenet commented Jan 7, 2015

Reviewer: Bruno Grenet

@bgrenet
Copy link

bgrenet commented Jan 7, 2015

comment:11

Thanks, LGTM.

@vbraun
Copy link
Member

vbraun commented Jan 12, 2015

Changed branch from u/rws/fix_coefficients_for_symbolic_series to 0b9914f

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