- S = _quaternion_hermitian_basis(n)
- (Qs, T) = _multiplication_table_from_matrix_basis(S)
-
- # Since a+bi+cj+dk on the diagonal is represented as
- #
- # a + bi +cj + dk = [ a b c d]
- # [ -b a -d c]
- # [ -c d a -b]
- # [ -d -c b a],
- #
- # we'll quadruple-count the "a" entries if we take the trace of
- # the embedding.
- ip = lambda X,Y: _matrix_ip(X,Y)/4
-
- return FiniteDimensionalEuclideanJordanAlgebra(field,
- Qs,
- rank=n,
- natural_basis=T,
- inner_product=ip)
-
+ @staticmethod
+ def __classcall_private__(cls, n, field=QQ):
+ S = _quaternion_hermitian_basis(n)
+ (Qs, T) = _multiplication_table_from_matrix_basis(S)