1gap> #Constructing form: BilinearFormByMatrix
2gap> mat := IdentityMat(4, GF(9));
3[ [ Z(3)^0, 0*Z(3), 0*Z(3), 0*Z(3) ], [ 0*Z(3), Z(3)^0, 0*Z(3), 0*Z(3) ],
4  [ 0*Z(3), 0*Z(3), Z(3)^0, 0*Z(3) ], [ 0*Z(3), 0*Z(3), 0*Z(3), Z(3)^0 ] ]
5gap> form := BilinearFormByMatrix(mat,GF(9));
6< bilinear form >
7gap> Display(form);
8Bilinear form
9Gram Matrix:
10 1 . . .
11 . 1 . .
12 . . 1 .
13 . . . 1
14gap> mat := [[0*Z(2),Z(16)^12,0*Z(2),Z(4)^2,Z(16)^13],
15>    [Z(16)^12,0*Z(2),0*Z(2),Z(16)^11,Z(16)],
16>    [0*Z(2),0*Z(2),0*Z(2),Z(4)^2,Z(16)^3],
17>    [Z(4)^2,Z(16)^11,Z(4)^2,0*Z(2),Z(16)^3],
18>    [Z(16)^13,Z(16),Z(16)^3,Z(16)^3,0*Z(2) ]];
19[ [ 0*Z(2), Z(2^4)^12, 0*Z(2), Z(2^2)^2, Z(2^4)^13 ],
20  [ Z(2^4)^12, 0*Z(2), 0*Z(2), Z(2^4)^11, Z(2^4) ],
21  [ 0*Z(2), 0*Z(2), 0*Z(2), Z(2^2)^2, Z(2^4)^3 ],
22  [ Z(2^2)^2, Z(2^4)^11, Z(2^2)^2, 0*Z(2), Z(2^4)^3 ],
23  [ Z(2^4)^13, Z(2^4), Z(2^4)^3, Z(2^4)^3, 0*Z(2) ] ]
24gap> form := BilinearFormByMatrix(mat,GF(16));
25< bilinear form >
26gap> Display(form);
27Bilinear form
28Gram Matrix:
29z = Z(16)
30    . z^12    . z^10 z^13
31 z^12    .    . z^11  z^1
32    .    .    . z^10  z^3
33 z^10 z^11 z^10    .  z^3
34 z^13  z^1  z^3  z^3    .
35gap> mat := [[1,0,0,0],[0,1,0,0],[0,0,0,1],[0,0,1,0]]*Z(7)^0;
36[ [ Z(7)^0, 0*Z(7), 0*Z(7), 0*Z(7) ], [ 0*Z(7), Z(7)^0, 0*Z(7), 0*Z(7) ],
37  [ 0*Z(7), 0*Z(7), 0*Z(7), Z(7)^0 ], [ 0*Z(7), 0*Z(7), Z(7)^0, 0*Z(7) ] ]
38gap> form := BilinearFormByMatrix(mat);
39< bilinear form >
40gap> WittIndex(form);
411
42gap> form := BilinearFormByMatrix(mat,GF(49));
43< bilinear form >
44gap> WittIndex(form);
452
46gap> quit;
47