Matrix ^ [...] -- select some rows of blocks
Synopsis:
f^[i,j,k] -- extract some rows of blocks from a matrix f.
The target of f should be a direct sum, and the result is obtained by
composition with the projection onto the sum of the components numbered
i, j, k. Free modules are regarded as direct sums.
i1 : f = map(ZZ^2 ++ ZZ^2, ZZ^2, {{1,2},{3,4},{5,6},{7,8}})
o1 = | 1 2 |
| 3 4 |
| 5 6 |
| 7 8 |
4 2
o1 : Matrix ZZ <--- ZZ |
i2 : f^[0]
o2 = | 1 2 |
| 3 4 |
2 2
o2 : Matrix ZZ <--- ZZ |
i3 : f^[1]
o3 = | 5 6 |
| 7 8 |
2 2
o3 : Matrix ZZ <--- ZZ |
i4 : f^[1,0]
o4 = | 5 6 |
| 7 8 |
| 1 2 |
| 3 4 |
4 2
o4 : Matrix ZZ <--- ZZ |
See also:
submatrix -- select part of a matrix
Module ^ [...] -- projection onto some factors of a direct sum module
Matrix _ [...] -- select some columns of blocks
Code:
-- ../../../Macaulay2/m2/matrix1.m2:659
Matrix ^ Array := Matrix => (f,v) -> (target f)^v * f