![[next]](next.gif)
![[previous]](previous.gif)
![[up]](up.gif)
![[top]](top.gif)
Synopsis:
matrix f -- produce the matrix of a map f.
If the source and target of f are free, then the result is f itself. Otherwise, the source and target will be replaced by the free modules whose basis elements correspond to the generators of the modules.
See also:
Code:
-- ../../../Macaulay2/m2/matrix1.m2:290-295
matrix(Matrix) := Matrix => options -> (m) -> (
if isFreeModule target m and isFreeModule source m
and ring source m === ring target m
then m
else map(cover target m, cover source m ** ring target m, m, Degree => degree m)
)
![[next]](next.gif)
![[previous]](previous.gif)
![[up]](up.gif)
![[top]](top.gif)