From 7063bafbc796dff12fcb63e28a4bfc3024953141 Mon Sep 17 00:00:00 2001 From: Travis Scrimshaw Date: Tue, 12 Sep 2023 11:30:22 +0900 Subject: [PATCH] Fixing representation test for infinte dimensional Lie algebras. --- src/sage/algebras/lie_algebras/representation.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/sage/algebras/lie_algebras/representation.py b/src/sage/algebras/lie_algebras/representation.py index bebd13a65c7..685b6860e87 100644 --- a/src/sage/algebras/lie_algebras/representation.py +++ b/src/sage/algebras/lie_algebras/representation.py @@ -87,6 +87,8 @@ def _test_representation(self, **options): tester = self._tester(**options) S = tester.some_elements() elts = self._lie_algebra.basis() + if elts.cardinality() == float('inf'): + elts = list(elts.some_elements()) from sage.misc.misc import some_tuples for x, y in some_tuples(elts, 2, tester._max_runs): for v in S: