Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
grhkm21 committed Sep 1, 2023
1 parent 4454ce6 commit 0293a38
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/sage/matrix/berlekamp_massey.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,6 @@ def berlekamp_massey(a):
f0, f1 = R(a), x**(2 * M)
s0, s1 = 1, 0
while f1.degree() >= M:
f0, (qj, f1) = f1, f0.quo_rem(f1)
s0, s1 = s1, s0 - qj * s1
f0, (q, f1) = f1, f0.quo_rem(f1)
s0, s1 = s1, s0 - q * s1
return s1.reverse().monic()

0 comments on commit 0293a38

Please sign in to comment.