Skip to content

Commit

Permalink
fix issue fricas#142
Browse files Browse the repository at this point in the history
The problem is independent of ")set stream calc 1".
It just happened to be hidden.

Before this commit the code below resulted in the values 0, 5, 3
for the last 3 commands.

ZZ ==> Integer
SULS ==> SparseUnivariateLaurentSeries(ZZ, 'q, 0)
Rec ==> Record(k: ZZ, c: ZZ)
S ==> Stream Rec
st := cons([0,3]$Rec, cons([1,5]$Rec, cons([2,7]$Rec,empty()$S)))$S
s := series(st)$SULS;
i x ==> x pretend InnerSparseUnivariatePowerSeries ZZ
explicitEntries?(getStream i s)
getRef i s
coefficient(s,0)
coefficient(s,1)
coefficient(s,0)
  • Loading branch information
hemmecke committed Nov 27, 2023
1 parent 2c29319 commit 1bc4cc7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/algebra/sups.spad
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ InnerSparseUnivariatePowerSeries(Coef) : Exports == Implementation where

series(x : ST) ==
empty? x => 0
n := getExpon frst x; refer := ref(n :: COM)
n := getExpon frst x; refer := ref((n-1) :: COM)
makeSeries(refer, iSeries(x, refer))

--% values
Expand Down

0 comments on commit 1bc4cc7

Please sign in to comment.