Description
This function is provided by the package
InvariantRing.
The following example defines an action of a two-dimensional torus on a four-dimensional vector space with a basis of weight vectors whose weights are the columns of the input matrix.
i1 : R = QQ[x_1..x_4]
o1 = R
o1 : PolynomialRing
|
i2 : W = matrix{{0,1,-1,1},{1,0,-1,-1}}
o2 = | 0 1 -1 1 |
| 1 0 -1 -1 |
2 4
o2 : Matrix ZZ <--- ZZ
|
i3 : T = diagonalAction(W, R)
* 2
o3 = R <- (QQ ) via
| 0 1 -1 1 |
| 1 0 -1 -1 |
o3 : DiagonalAction
|
i4 : S = invariantRing T
o4 = 4 2 3 5 3 2 6 3 3 2
QQ[x x x x , x x x x , x x x , x x x , x x x ]
1 2 3 4 1 2 3 4 1 3 4 1 3 4 1 2 3
o4 : RingOfInvariants
|
The algebra generators for the ring of invariants are computed upon initialization by the method invariants.
Alternatively, we can use the following shortcut to construct a ring of invariants.
i5 : S = R^T
o5 = 4 2 3 5 3 2 6 3 3 2
QQ[x x x x , x x x x , x x x , x x x , x x x ]
1 2 3 4 1 2 3 4 1 3 4 1 3 4 1 2 3
o5 : RingOfInvariants
|
Caveat
By default, the invariants of a diagonal group action are computed over an infinite extension of the ground field specified by the user over which the action is defined. Provided the action is defined, it is possible to compute invariants literally over the specified ground field in prime characteristic using the option
UseCoefficientRing.