Base classes for Matrix Groups#

AUTHORS:

  • William Stein: initial version

  • David Joyner (2006-03-15): degree, base_ring, _contains_, list, random, order methods; examples

  • William Stein (2006-12): rewrite

  • David Joyner (2007-12): Added invariant_generators (with Martin Albrecht and Simon King)

  • David Joyner (2008-08): Added module_composition_factors (interface to GAP’s MeatAxe implementation) and as_permutation_group (returns isomorphic PermutationGroup).

  • Simon King (2010-05): Improve invariant_generators by using GAP for the construction of the Reynolds operator in Singular.

  • Sebastian Oehms (2018-07): Add subgroup() and ambient() see github issue #25894

class sage.groups.matrix_gps.matrix_group.MatrixGroup_base#

Bases: Group

Base class for all matrix groups.

This base class just holds the base ring, but not the degree. So it can be a base for affine groups where the natural matrix is larger than the degree of the affine group. Makes no assumption about the group except that its elements have a matrix() method.

ambient()#

Return the ambient group of a subgroup.

OUTPUT:

A group containing self. If self has not been defined as a subgroup, we just return self.

EXAMPLES:

sage: G = GL(2, QQ)
sage: m = matrix(QQ, 2, 2, [[3, 0], [~5,1]])
sage: S = G.subgroup([m])
sage: S.ambient() is G
True
as_matrix_group()#

Return a new matrix group from the generators.

This will throw away any extra structure (encoded in a derived class) that a group of special matrices has.

EXAMPLES:

sage: G = SU(4, GF(5))                                                      # optional - sage.rings.finite_rings
sage: G.as_matrix_group()                                                   # optional - sage.rings.finite_rings
Matrix group over Finite Field in a of size 5^2 with 2 generators (
[      a       0       0       0]  [      1       0 4*a + 3       0]
[      0 2*a + 3       0       0]  [      1       0       0       0]
[      0       0 4*a + 1       0]  [      0 2*a + 4       0       1]
[      0       0       0     3*a], [      0 3*a + 1       0       0]
)

sage: G = GO(3,GF(5))                                                       # optional - sage.rings.finite_rings
sage: G.as_matrix_group()                                                   # optional - sage.rings.finite_rings
Matrix group over Finite Field of size 5 with 2 generators (
[2 0 0]  [0 1 0]
[0 3 0]  [1 4 4]
[0 0 1], [0 2 1]
)
sign_representation(base_ring=None, side='twosided')#

Return the sign representation of self over base_ring.

Warning

Assumes self is a matrix group over a field which has embedding over real numbers.

INPUT:

  • base_ring – (optional) the base ring; the default is \(\ZZ\)

  • side – ignored

EXAMPLES:

sage: G = GL(2, QQ)
sage: V = G.sign_representation()                                           # optional - sage.combinat
sage: e = G.an_element()                                                    # optional - sage.combinat
sage: e                                                                     # optional - sage.combinat
[1 0]
[0 1]
sage: V._default_sign(e)                                                    # optional - sage.combinat
1
sage: m2 = V.an_element()                                                   # optional - sage.combinat
sage: m2                                                                    # optional - sage.combinat
2*B['v']
sage: m2*e                                                                  # optional - sage.combinat
2*B['v']
sage: m2*e*e                                                                # optional - sage.combinat
2*B['v']
subgroup(generators, check=True)#

Return the subgroup generated by the given generators.

INPUT:

  • generators – a list/tuple/iterable of group elements of self

  • check – boolean (optional, default: True). Whether to check that each matrix is invertible.

OUTPUT: The subgroup generated by generators as an instance of FinitelyGeneratedMatrixGroup_gap

EXAMPLES:

sage: UCF = UniversalCyclotomicField()                                      # optional - sage.rings.number_field
sage: G  = GL(3, UCF)                                                       # optional - sage.rings.number_field
sage: e3 = UCF.gen(3); e5 = UCF.gen(5)                                      # optional - sage.rings.number_field
sage: m = matrix(UCF, 3,3, [[e3, 1, 0], [0, e5, 7],[4, 3, 2]])              # optional - sage.rings.number_field
sage: S = G.subgroup([m]); S                                                # optional - sage.rings.number_field
Subgroup with 1 generators (
[E(3)    1    0]
[   0 E(5)    7]
[   4    3    2]
) of General Linear Group of degree 3 over Universal Cyclotomic Field

sage: CF3 = CyclotomicField(3)                                              # optional - sage.rings.number_field
sage: G  = GL(3, CF3)                                                       # optional - sage.rings.number_field
sage: e3 = CF3.gen()                                                        # optional - sage.rings.number_field
sage: m = matrix(CF3, 3,3, [[e3, 1, 0], [0, ~e3, 7],[4, 3, 2]])             # optional - sage.rings.number_field
sage: S = G.subgroup([m]); S                                                # optional - sage.rings.number_field
Subgroup with 1 generators (
[     zeta3          1          0]
[         0 -zeta3 - 1          7]
[         4          3          2]
) of General Linear Group of degree 3 over Cyclotomic Field of order 3 and degree 2
class sage.groups.matrix_gps.matrix_group.MatrixGroup_generic(degree, base_ring, category=None)#

Bases: MatrixGroup_base

Base class for matrix groups over generic base rings

You should not use this class directly. Instead, use one of the more specialized derived classes.

INPUT:

  • degree – integer. The degree (matrix size) of the matrix group.

  • base_ring – ring. The base ring of the matrices.

Element#

alias of MatrixGroupElement_generic

degree()#

Return the degree of this matrix group.

OUTPUT:

Integer. The size (number of rows equals number of columns) of the matrices.

EXAMPLES:

sage: SU(5,5).degree()                                                      # optional - sage.rings.finite_rings
5
matrix_space()#

Return the matrix space corresponding to this matrix group.

This is a matrix space over the field of definition of this matrix group.

EXAMPLES:

sage: F = GF(5); MS = MatrixSpace(F, 2, 2)                                  # optional - sage.rings.finite_rings
sage: G = MatrixGroup([MS(1), MS([1,2,3,4])])                               # optional - sage.rings.finite_rings
sage: G.matrix_space()                                                      # optional - sage.rings.finite_rings
Full MatrixSpace of 2 by 2 dense matrices over Finite Field of size 5
sage: G.matrix_space() is MS                                                # optional - sage.rings.finite_rings
True
sage.groups.matrix_gps.matrix_group.is_MatrixGroup(x)#

Test whether x is a matrix group.

EXAMPLES:

sage: from sage.groups.matrix_gps.matrix_group import is_MatrixGroup
sage: is_MatrixGroup(MatrixSpace(QQ, 3))
False
sage: is_MatrixGroup(Mat(QQ, 3))
False
sage: is_MatrixGroup(GL(2, ZZ))
True
sage: is_MatrixGroup(MatrixGroup([matrix(2, [1,1,0,1])]))
True