return elt.minimal_polynomial()
+ def quadratic_representation(self):
+ """
+ Return the quadratic representation of this element.
+
+ EXAMPLES:
+
+ The explicit form in the spin factor algebra is given by
+ Alizadeh's Example 11.12::
+
+ sage: n = ZZ.random_element(1,10).abs()
+ sage: J = eja_ln(n)
+ sage: x = J.random_element()
+ sage: x_vec = x.vector()
+ sage: x0 = x_vec[0]
+ sage: x_bar = x_vec[1:]
+ sage: A = matrix(QQ, 1, [x_vec.inner_product(x_vec)])
+ sage: B = 2*x0*x_bar.row()
+ sage: C = 2*x0*x_bar.column()
+ sage: D = identity_matrix(QQ, n-1)
+ sage: D = (x0^2 - x_bar.inner_product(x_bar))*D
+ sage: D = D + 2*x_bar.tensor_product(x_bar)
+ sage: Q = block_matrix(2,2,[A,B,C,D])
+ sage: Q == x.quadratic_representation()
+ True
+
+ """
+ return 2*(self.matrix()**2) - (self**2).matrix()
+
+
def span_of_powers(self):
"""
Return the vector space spanned by successive powers of