# Why is the GU(n,q) package the way it is?

So I would love to utilize the unitary group feature in Sage; however, it does not seem like Sage defines this group in the standard way that I have seen, namely $n\times n$ matrices over the finite field $\mathbb F_{q^2}$ such that $U^* U = I$, where $U^*$ is the transpose of the matrix in which each entry of $U$ is raised to the $q$ power.

For some weird reason it appears as though sage uses the antitranspose instead of the traditional transpose operation to define unitary matrices, since the following matrix, for example, is included:

\begin{bmatrix} 0 & 1\\ 1 & 1 \end{bmatrix}

Does anyone know why this is and how I can easily rectify my computations so these matrices still preserve the Hermitian form $\langle x,x \rangle = x^*x$?

These groups are defined using GAP, and GAP defines these groups so that they preserve the bilinear form defined by the matrix

`[[0, 1], [1, 0]]`

. Once you've defined`G = GU(2, 7)`

, you can evaluate`G.invariant_form()`

to see this. There is no obvious way (at least to me) to change the bilinear form.So from the documentation I found here: https://doc.sagemath.org/html/en/refe...

It looks like you can change the invariant form, but I tried this and Sage just yells at me saying that 'invariant_form" is an unexpected keyword argument, even if I copy and paste the exact code used there.

(a) What version of Sage are you using? (b) I should have been clearer about there being no obvious way to change the bilinear form: there is no obvious way to change it in the case when you are defining a finite group, as the example

`GU(3,3, invariant_form=[[1,0,0],[0,2,0],[0,0,1]])`

illustrates.