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

The gen() method for power series over power series works incorrectly #10085

Closed
haraldschilly opened this issue Oct 6, 2010 · 6 comments
Closed

Comments

@haraldschilly
Copy link
Member

If I type the following:

S1 = LazyPowerSeriesRing(ZZ)
S2 = LazyPowerSeriesRing(S1)
y = S2.gen()
y.coefficient(1) == 1

I get True, and

y.coefficient(1).coefficient(0)

gets me the "'int' object has no attribute 'coefficient'" error message.

I solved the problem by changing the following line in the gen() method:

res = self._new_initial(1, Stream([0,1,0]))

by

res = self.term(1, 1)

The coefficient of order 1 in the series y should not be the integer 1, but the power series [1, 0, ...] in S1.

CC: axel.bacher@labri.fr @mwhansen @mantepse

Component: combinatorics

Keywords: LazyPowerSeries

Reviewer: Travis Scrimshaw

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

@haraldschilly

This comment has been minimized.

@mantepse
Copy link
Collaborator

Changed keywords from none to LazyPowerSeries

@mwhansen
Copy link
Contributor

comment:5

A fix is in #15673

@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
@fchapoton

This comment has been minimized.

@mantepse
Copy link
Collaborator

comment:10

This is no longer relevant, since #32367. (the example works now and is tested)

@mantepse mantepse removed this from the sage-6.4 milestone Sep 21, 2022
@tscrim
Copy link
Collaborator

tscrim commented Oct 22, 2022

Reviewer: Travis Scrimshaw

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

7 participants