-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathGeneralLinearGroup.class.st
More file actions
91 lines (77 loc) · 2.24 KB
/
Copy pathGeneralLinearGroup.class.st
File metadata and controls
91 lines (77 loc) · 2.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
"
The general linear group GL(V) of automorphisms of an R-module V. The elements are invertible linear transformations from V to itself (see LinearMap, LinearGroup).
Examples (two equivalent ways to create GL(V):
GeneralLinearGroup on: QQ ^ 3.
(QQ ^ 3) automorphisms
"
Class {
#name : #GeneralLinearGroup,
#superclass : #LinearGroup,
#category : #'Mathematics-Groups-Linear'
}
{ #category : #comparing }
GeneralLinearGroup >> >= anObject [
(anObject isKindOf: LinearGroup) ifTrue: [^ space >= anObject space].
^ super >= anObject
]
{ #category : #operations }
GeneralLinearGroup >> affine [
^ GeneralAffineGroup on: space
]
{ #category : #accessing }
GeneralLinearGroup >> ambient [
^ self
]
{ #category : #operations }
GeneralLinearGroup >> asMatrixGroup [
^ GeneralLinearMatrixGroup new: space rank over: space scalars
]
{ #category : #random }
GeneralLinearGroup >> atRandom: aRandom [
| answer |
[(answer := self space endomorphisms atRandom: aRandom) isInvertible] whileFalse.
^ answer
]
{ #category : #random }
GeneralLinearGroup >> atRandom: aRandom bits: bitSize [
| answer |
[(answer := self space endomorphisms atRandom: aRandom bits: bitSize) isInvertible] whileFalse.
^ answer
]
{ #category : #operations }
GeneralLinearGroup >> center [
^ ScalarGroup on: space
]
{ #category : #operations }
GeneralLinearGroup >> commutator [
(space dimension = 2 and: [space scalars size = 2])
ifFalse: [^ SpecialLinearGroup on: space].
^ self propertyAt: #commutator ifAbsentPut: [super commutator]
]
{ #category : #testing }
GeneralLinearGroup >> contains: aLinearMap [
"Answer true if the receiver contains the given element of its ambient."
^ true
]
{ #category : #operations }
GeneralLinearGroup >> orthogonal [
^ OrthogonalGroup on: space
]
{ #category : #printing }
GeneralLinearGroup >> shortName [
^ 'GL'
]
{ #category : #accessing }
GeneralLinearGroup >> size [
| q n |
self space isInfinite ifTrue: [^ self space size]. "?"
(self space scalars isField and: [self space scalars isFinite])
ifFalse: [^ super size].
q := self space scalars size.
n := self space dimension.
^ 'q ^ (n*(n-1)/2) * ((1 to: n) inject: 1 into: [:x :k| q^k - 1 * x])'
]
{ #category : #operations }
GeneralLinearGroup >> special [
^ SpecialLinearGroup on: space
]