The components can be recovered later with components or with formation.
Projection and inclusion maps for direct sums: i1 : F = directSum(a=>ZZ^1, b=>ZZ^2, c=>ZZ^3) 6 o1 = ZZ o1 : ZZ-module, free |
i2 : F_[b] o2 = | 0 0 | | 1 0 | | 0 1 | | 0 0 | | 0 0 | | 0 0 | 6 2 o2 : Matrix ZZ <--- ZZ |
i3 : F^[c] o3 = | 0 0 0 1 0 0 | | 0 0 0 0 1 0 | | 0 0 0 0 0 1 | 3 6 o3 : Matrix ZZ <--- ZZ |
i4 : F = (a => ZZ^1) ++ (b => ZZ^2) 3 o4 = ZZ o4 : ZZ-module, free |
i5 : F_[b] o5 = | 0 0 | | 1 0 | | 0 1 | 3 2 o5 : Matrix ZZ <--- ZZ |
The object directSum is a method function with a single argument.