]> gitweb.michael.orlitzky.com - sage.d.git/commitdiff
mjo/clan/normal_decomposition.py: another principal decomp test
authorMichael Orlitzky <michael@orlitzky.com>
Fri, 27 Mar 2026 18:07:17 +0000 (14:07 -0400)
committerMichael Orlitzky <michael@orlitzky.com>
Fri, 27 Mar 2026 18:07:17 +0000 (14:07 -0400)
There was a bug in the previous test, since we are using the Ishi
convention that gives us a lower-triangular normal decomposition: a
subclan is obtained by "deleting" the first idempotent rather than the
last. After fixing that, we add another test to show that this does
actually produce a subalgebra (the new test finds the bug).

mjo/clan/normal_decomposition.py

index 5cfd2a1f4d02a7a8028cc752dba735d656dc07d9..8ffcc62b0ff3ec24fb2f1c69312cd8b66b04b85c 100644 (file)
@@ -21,14 +21,32 @@ class NormalDecomposition(Clan):
     TESTS:
 
     If we start with a normal decomposition of a clan of rank ``r``
-    and if we "delete" the ``r``th idempotent, the result should still
+    and if we "delete" the first idempotent, the result should still
     be a (non unital) clan in its principal decomposition: a unital
-    clan of rank ``r-1`` plus what's left of the ``r``th column. (This
-    is stated without proof in my "Automorphisms of hyperbolic
-    polynomials" paper.) But rather than create a true, non-unital
-    subclan, we can just set the coordinates of the ``r``th idempotent
-    to zero. We then check the defining property of a principal
-    decomposition::
+    clan of rank ``r-1`` plus the (strictly) subdiagonal part of the
+    first column. This is stated without proof in my "Automorphisms of
+    hyperbolic polynomials" paper, although in Vinberg's notation we
+    would "delete" the ``r``th idempotent leaving a superdiagonal::
+
+        sage: clans = [VinbergClan(),
+        ....:          RealSymmetricClan(4),
+        ....:          ComplexHermitianClan(3),
+        ....:          JordanSpinClan(5)]
+        sage: all(
+        ....:     all(
+        ....:         (bi*bj).coefficient((0,0,1)).is_zero()
+        ....:         for bi in C.basis()
+        ....:         for bj in C.basis()
+        ....:         if not bi == C.idempotent(0)
+        ....:         and not bj == C.idempotent(0)
+        ....:     )
+        ....:     for C in clans
+        ....: )
+        True
+
+    Confirm the defining property of a principal decomposition for
+    this subalgebra. Rather than create a true, non-unital subclan, we
+    can just set the coordinates of the first idempotent to zero.
 
         sage: clans = [VinbergClan(),
         ....:          RealSymmetricClan(4),
@@ -36,13 +54,11 @@ class NormalDecomposition(Clan):
         ....:          JordanSpinClan(5)]
         sage: def subunit(C):
         ....:     # Unit of the subclan
-        ....:     r = C.rank()
-        ....:     return sum(C.idempotent(i) for i in range(r-1))
+        ....:     return sum(C.idempotent(i) for i in range(1, C.rank()))
         sage: def subelt(C):
         ....:     # random subclan element
-        ....:     r = C.rank()
         ....:     x = C.random_element()
-        ....:     return x - x.coefficient((r-1,r-1,1))*C.idempotent(r-1)
+        ....:     return x - x.coefficient((0,0,1))*C.idempotent(0)
         sage: all(
         ....:     x.leftreg().trace() == u.inner_product_vinberg(x)
         ....:     for C in clans