# tensor(Ring,RingMap,Matrix) -- tensor product via a ring map

## Synopsis

• Usage:
tensor(R,f,M)
tensor(f,M)
• Function: tensor
• Inputs:
• S, a ring
• f, , from R --> S
• M, , or over the source ring R of f
• Outputs:
• or the same type as M

## Description

None of the options are relevant for these uses of tensor.

 ```i1 : R = QQ[a..d] o1 = R o1 : PolynomialRing``` ```i2 : S = QQ[s,t] o2 = S o2 : PolynomialRing``` ```i3 : F = map(S,R,{s^4,s^3*t,s*t^3,t^4}) 4 3 3 4 o3 = map(S,R,{s , s t, s*t , t }) o3 : RingMap S <--- R``` ```i4 : f = matrix{{a,b,c,d}} o4 = | a b c d | 1 4 o4 : Matrix R <--- R``` ```i5 : tensor(F,f) o5 = | s4 s3t st3 t4 | 1 4 o5 : Matrix S <--- S``` ```i6 : tensor(F,image f) o6 = cokernel {1} | -s3t 0 -st3 0 0 -t4 | {1} | s4 -st3 0 0 -t4 0 | {1} | 0 s3t s4 -t4 0 0 | {1} | 0 0 0 st3 s3t s4 | 4 o6 : S-module, quotient of S```

If the ring S is given as an argument, then it must match the target of F, and the result is identical to the version without S given. The reason it is here is to mimic natural mathematical notation: S **_R M.

 ```i7 : tensor(S,F,f) o7 = | s4 s3t st3 t4 | 1 4 o7 : Matrix S <--- S``` ```i8 : tensor(S,F,image f) o8 = cokernel {1} | -s3t 0 -st3 0 0 -t4 | {1} | s4 -st3 0 0 -t4 0 | {1} | 0 s3t s4 -t4 0 0 | {1} | 0 0 0 st3 s3t s4 | 4 o8 : S-module, quotient of S```