# map(Matrix) -- make a matrix with a different degree

## Synopsis

• Function: map
• Usage:
map(f, Degree => d)
• Inputs:
• f,
• Optional inputs:
• Degree => ..., default value null, specify the degree of a map
• DegreeLift => ..., default value null, make a ring map
• DegreeMap => ..., default value null, make a ring map
• Outputs:
• , a map identical to f, except that it has degree d, and the source module has been tensored by a graded free module of rank 1 of the appropriate degree.

## Description

The input d should be an integer, or a list of integers.

This routine is often used to take a matrix that has a non-zero degree, and make the degree zero.

For example, multiplication of a matrix by a scalar increases the degree, leaving the source and target fixed:

 i1 : R = QQ[a,b]; i2 : f1 = matrix{{a,b}} o2 = | a b | 1 2 o2 : Matrix R <--- R i3 : f = a * f1 o3 = | a2 ab | 1 2 o3 : Matrix R <--- R i4 : degree f o4 = {1} o4 : List i5 : source f == source f1 o5 = true
One solution is to change the degree:
 i6 : g = map(f, Degree => 0) o6 = | a2 ab | 1 2 o6 : Matrix R <--- R i7 : degree g o7 = {0} o7 : List i8 : source g == (source f) ** R^{-1} o8 = true
An alternate solution would be to use tensor product with the scalar.
 i9 : g2 = a ** matrix{{a,b}} o9 = | a2 ab | 1 2 o9 : Matrix R <--- R i10 : degree g2 o10 = {0} o10 : List i11 : isHomogeneous g2 o11 = true