next | previous | forward | backward | up | top | index | toc | Macaulay2 web site
Complexes :: directSum(Complex)

directSum(Complex) -- direct sum of complexes

Synopsis

Description

The direct sum of two complexes is another complex in the same category.

i1 : S = ZZ/101[a,b,c];
i2 : C1 = freeResolution coker vars S

      1      3      3      1
o2 = S  <-- S  <-- S  <-- S
                           
     0      1      2      3

o2 : Complex
i3 : C1 ++ complex(S^13)[-2]

      1      3      16      1
o3 = S  <-- S  <-- S   <-- S
                            
     0      1      2       3

o3 : Complex
i4 : C2 = complex (ideal(a,b,c))

o4 = image | a b c |
      
     0

o4 : Complex
i5 : C1 ++ C2

                            3      3      1
o5 = image | 1 0 0 0 | <-- S  <-- S  <-- S
           | 0 a b c |                    
                           1      2      3
     0

o5 : Complex

The direct sum of a sequence of complexes can be computed as follows.

i6 : C3 = directSum(C1,C2,C2[-2])

                            3                                    1
o6 = image | 1 0 0 0 | <-- S  <-- image {2} | 1 0 0 0 0 0 | <-- S
           | 0 a b c |                  {2} | 0 1 0 0 0 0 |      
                           1            {2} | 0 0 1 0 0 0 |     3
     0                                  {0} | 0 0 0 a b c |
                                   
                                  2

o6 : Complex

The direct sum is an n-ary operator with projection and inclusion maps from each component satisfying appropriate identities.

i7 : C4 = directSum(first => C1, second => C2)

                            3      3      1
o7 = image | 1 0 0 0 | <-- S  <-- S  <-- S
           | 0 a b c |                    
                           1      2      3
     0

o7 : Complex
i8 : C4_[first] -- inclusion map C1 --> C4

                                           1
o8 = 0 : image | 1 0 0 0 | <------------- S  : 0
               | 0 a b c |    {0} | 1 |
                              {1} | 0 |
                              {1} | 0 |
                              {1} | 0 |

          3                     3
     1 : S  <----------------- S  : 1
               {1} | 1 0 0 |
               {1} | 0 1 0 |
               {1} | 0 0 1 |

          3                     3
     2 : S  <----------------- S  : 2
               {2} | 1 0 0 |
               {2} | 0 1 0 |
               {2} | 0 0 1 |

          1                 1
     3 : S  <------------- S  : 3
               {3} | 1 |

o8 : ComplexMap
i9 : C4^[first] -- projection map C4 --> C1

          1
o9 = 0 : S  <--------------- image | 1 0 0 0 | : 0
               | 1 0 0 0 |         | 0 a b c |

          3                     3
     1 : S  <----------------- S  : 1
               {1} | 1 0 0 |
               {1} | 0 1 0 |
               {1} | 0 0 1 |

          3                     3
     2 : S  <----------------- S  : 2
               {2} | 1 0 0 |
               {2} | 0 1 0 |
               {2} | 0 0 1 |

          1                 1
     3 : S  <------------- S  : 3
               {3} | 1 |

o9 : ComplexMap
i10 : C4^[first] * C4_[first] == 1

o10 = true
i11 : C4^[second] * C4_[second] == 1

o11 = true
i12 : C4^[first] * C4_[second] == 0

o12 = true
i13 : C4^[second] * C4_[first] == 0

o13 = true
i14 : C4_[first] * C4^[first] + C4_[second] * C4^[second] == 1

o14 = true

Given a complex which is a direct sum, we obtain the component complexes and their names (indices) as follows.

i15 : components C4

        1      3      3      1
o15 = {S  <-- S  <-- S  <-- S , image | a b c |}
                                 
       0      1      2      3   0

o15 : List
i16 : indices C4

o16 = {first, second}

o16 : List

See also