The degree i is a multi-degree, represented as a list of integers. If the degree rank is 1, then i may be provided as an integer.
The algorithm uses the heft vector of the ring, and cannot proceed without one; see heft vectors.
i1 : R = ZZ/101[a..c];
|
i2 : basis(2, R)
o2 = | a2 ab ac b2 bc c2 |
1 6
o2 : Matrix R <--- R
|
i3 : M = ideal(a,b,c)/ideal(a^2,b^2,c^2)
o3 = subquotient (| a b c |, | a2 b2 c2 |)
1
o3 : R-module, subquotient of R
|
i4 : f = basis(2,M)
o4 = {1} | b c 0 |
{1} | 0 0 c |
{1} | 0 0 0 |
o4 : Matrix
|
Notice that the matrix of f above is expressed in terms of the generators of M. The reason is that the module M is the target of the map f, and matrices of maps such as f are always expressed in terms of the generators of the source and target.
i5 : target f
o5 = subquotient (| a b c |, | a2 b2 c2 |)
1
o5 : R-module, subquotient of R
|
The command super is useful for rewriting f in terms of the generators of module of which M is a submodule.
i6 : super f
o6 = | ab ac bc |
o6 : Matrix
|
When a ring is multi-graded, we specify the degree as a list of integers.
i7 : S = ZZ/101[x,y,z,Degrees=>{{1,3},{1,4},{1,-1}}];
|
i8 : basis({7,24}, S)
o8 = | x4y3 |
1 1
o8 : Matrix S <--- S
|
Here is an example showing the use of the SourceRing option. Using a ring of different degree length as the source ring is currently not well supported, because the graded free modules may not lift.
i9 : R = QQ[x]/x^6;
|
i10 : f = basis(R,SourceRing => ambient R)
o10 = | 1 x x2 x3 x4 x5 |
1 6
o10 : Matrix R <--- (QQ[x])
|
i11 : coimage f
o11 = cokernel {0} | x 0 0 0 0 0 |
{1} | -1 x 0 0 0 0 |
{2} | 0 -1 x 0 0 0 |
{3} | 0 0 -1 x 0 0 |
{4} | 0 0 0 -1 x 0 |
{5} | 0 0 0 0 -1 x |
6
o11 : QQ[x]-module, quotient of (QQ[x])
|
i12 : kernel f
o12 = image {0} | x 0 0 0 0 0 |
{1} | -1 x 0 0 0 0 |
{2} | 0 -1 x 0 0 0 |
{3} | 0 0 -1 x 0 0 |
{4} | 0 0 0 -1 x 0 |
{5} | 0 0 0 0 -1 x |
6
o12 : QQ[x]-module, submodule of (QQ[x])
|
i13 : g = basis(R,SourceRing => QQ)
o13 = | 1 x x2 x3 x4 x5 |
1 6
o13 : Matrix R <--- QQ
|
i14 : coimage g
6
o14 = QQ
o14 : QQ-module, free
|
i15 : kernel g
o15 = image 0
6
o15 : QQ-module, submodule of QQ
|
In some situations it may be desirable to retain the degrees of the generators, so a ring such as QQ[], which has degree length 1, can serve the purpose.
i16 : degrees source g
o16 = {{}, {}, {}, {}, {}, {}}
o16 : List
|
i17 : A = QQ[];
|
i18 : h = basis(R,SourceRing => A)
o18 = | 1 x x2 x3 x4 x5 |
1 6
o18 : Matrix R <--- A
|
i19 : degrees source h
o19 = {{0}, {1}, {2}, {3}, {4}, {5}}
o19 : List
|
i20 : coimage h
6
o20 = A
o20 : A-module, free, degrees {0, 1, 2, 3, 4, 5}
|
i21 : kernel h
o21 = image 0
6
o21 : A-module, submodule of A
|
Synopsis
-
- Inputs:
- Outputs:
- a map from a free module to M which sends the basis elements to a basis, over the coefficient field, of M
i22 : R = QQ[x,y,z]/(x^2,y^3,z^5)
o22 = R
o22 : QuotientRing
|
i23 : basis R
o23 = | 1 x xy xy2 xy2z xy2z2 xy2z3 xy2z4 xyz xyz2 xyz3 xyz4 xz xz2 xz3 xz4 y
-----------------------------------------------------------------------
y2 y2z y2z2 y2z3 y2z4 yz yz2 yz3 yz4 z z2 z3 z4 |
1 30
o23 : Matrix R <--- R
|
Synopsis
-
- Inputs:
- Outputs:
- a map from a free module to M which sends the basis elements to a basis, over the ground field, of the part of M spanned by elements of degrees between lo and hi. The degree rank must be 1.
i24 : R = QQ[x,y,z]/(x^3,y^2,z^5);
|
i25 : basis R
o25 = | 1 x x2 x2y x2yz x2yz2 x2yz3 x2yz4 x2z x2z2 x2z3 x2z4 xy xyz xyz2 xyz3
-----------------------------------------------------------------------
xyz4 xz xz2 xz3 xz4 y yz yz2 yz3 yz4 z z2 z3 z4 |
1 30
o25 : Matrix R <--- R
|
i26 : basis(-infinity,4,R)
o26 = | 1 x x2 x2y x2yz x2z x2z2 xy xyz xyz2 xz xz2 xz3 y yz yz2 yz3 z z2 z3
-----------------------------------------------------------------------
z4 |
1 21
o26 : Matrix R <--- R
|
i27 : basis(5,infinity,R)
o27 = | x2yz2 x2yz3 x2yz4 x2z3 x2z4 xyz3 xyz4 xz4 yz4 |
1 9
o27 : Matrix R <--- R
|
i28 : basis(2,4,R)
o28 = | x2 x2y x2yz x2z x2z2 xy xyz xyz2 xz xz2 xz3 yz yz2 yz3 z2 z3 z4 |
1 17
o28 : Matrix R <--- R
|