Skip to content

Commit 103656e

Browse files
author
Release Manager
committed
gh-40452: Simplify fpylll.IntegerMatrix construction ### 📝 Checklist <!-- Put an `x` in all the boxes that apply. --> - [ ] The title is concise and informative. - [ ] The description explains in detail what this PR is about. - [ ] I have linked a relevant issue or discussion. - [ ] I have created tests covering the changes. - [ ] I have updated the documentation and checked the documentation preview. ### ⌛ Dependencies <!-- List all open PRs that this PR logically depends on. For example, --> <!-- - #12345: short description why this is a dependency --> <!-- - #34567: ... --> URL: #40452 Reported by: user202729 Reviewer(s):
2 parents f8bc894 + 46f2f26 commit 103656e

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/sage/modules/free_quadratic_module_integer_symmetric.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1559,14 +1559,10 @@ def _fplll_enumerate(self, target=None):
15591559
"""
15601560
L = self.LLL()
15611561
dim = L.dimension()
1562-
gram = L.gram_matrix()
15631562
basis = L.basis_matrix()
15641563

15651564
import fpylll
1566-
gmat = fpylll.IntegerMatrix(dim, dim)
1567-
for i in range(dim):
1568-
for j in range(dim):
1569-
gmat[i, j] = gram[i, j]
1565+
gmat = fpylll.IntegerMatrix.from_matrix(L.gram_matrix())
15701566
gso = fpylll.GSO.Mat(gmat, gram=True)
15711567
ok = gso.update_gso()
15721568
assert ok

0 commit comments

Comments
 (0)