]> gitweb.michael.orlitzky.com - sage.d.git/commitdiff
mjo/eja/eja_operator.py: fix test when spin algebra is trivial
authorMichael Orlitzky <michael@orlitzky.com>
Fri, 29 Nov 2024 01:16:43 +0000 (20:16 -0500)
committerMichael Orlitzky <michael@orlitzky.com>
Fri, 29 Nov 2024 01:16:43 +0000 (20:16 -0500)
mjo/eja/eja_operator.py

index 19bcf9673ee304bd78b349d3497dc8261899c3ad..0f1652a3eb9999be8999ba167c55d8348ab23f89 100644 (file)
@@ -775,8 +775,10 @@ class EJAOperator(Map):
             ....:                                   orthonormalize=False)
             sage: n = J.dimension()
             sage: I = identity_matrix(J.base_ring(), 1)
-            sage: U = random_unitary_matrix(J.base_ring(), n-1)
-            sage: M = block_matrix(2, [I,0,0,U])
+            sage: M = I
+            sage: if n >= 1:
+            ....:     U = random_unitary_matrix(J.base_ring(), n-1)
+            ....:     M = block_matrix(2, [I,0,0,U])
             sage: L = EJAOperator(J,J,M)
             sage: L.is_isomorphism()
             True