Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 7ebd25ac536d248d499a3ce2acda963a > files > 3808

Macaulay2-1.3.1-8.fc15.i686.rpm

<?xml version="1.0" encoding="utf-8" ?>  <!-- for emacs: -*- coding: utf-8 -*- -->
<!-- Apache may like this line in the file .htaccess: AddCharset utf-8 .html -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN"	 "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg-flat.dtd" >
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head><title>Singular Book 2.1.24 -- submodules, presentation of a module</title>
<link rel="stylesheet" type="text/css" href="../../../../Macaulay2/Style/doc.css"/>
</head>
<body>
<table class="buttons">
  <tr>
    <td><div><a href="___Singular_sp__Book_sp2.1.26.html">next</a> | <a href="___Singular_sp__Book_sp2.1.20.html">previous</a> | <a href="___Singular_sp__Book_sp2.1.26.html">forward</a> | <a href="___Singular_sp__Book_sp2.1.20.html">backward</a> | <a href="___M2__Singular__Book.html">up</a> | <a href="index.html">top</a> | <a href="master.html">index</a> | <a href="toc.html">toc</a> | <a href="http://www.math.uiuc.edu/Macaulay2/">Macaulay2 web site</a></div>

    </td>
  </tr>
</table>
<div><a href="index.html" title="">Macaulay2Doc</a> > <a href="_basic_spcommutative_spalgebra.html" title="">basic commutative algebra</a> > <a href="___M2__Singular__Book.html" title="Macaulay2 examples for the Singular book">M2SingularBook</a> > <a href="___Singular_sp__Book_sp2.1.24.html" title="submodules, presentation of a module">Singular Book 2.1.24</a></div>
<hr/>
<div><h1>Singular Book 2.1.24 -- submodules, presentation of a module</h1>
<div><table class="examples"><tr><td><pre>i1 : A = QQ[x,y,z]

o1 = A

o1 : PolynomialRing</pre>
</td></tr>
<tr><td><pre>i2 : N = image matrix{{x*y,0},{0,x*z},{y*z,z^2}}

o2 = image | xy 0  |
           | 0  xz |
           | yz z2 |

                             3
o2 : A-module, submodule of A</pre>
</td></tr>
</table>
The submodule is generated by the two columns of this matrix.<table class="examples"><tr><td><pre>i3 : N + x*N

o3 = image | xy 0  x2y 0   |
           | 0  xz 0   x2z |
           | yz z2 xyz xz2 |

                             3
o3 : A-module, submodule of A</pre>
</td></tr>
</table>
It is easy to go between matrices and submodules.  Use <a href="_generators_lp__Module_rp.html" title="the generator matrix of a module">generators(Module)</a> and <a href="_image.html" title="image of a map">image(Matrix)</a>(<tt>gens</tt> and <tt>generators</tt> are synonyms).  There is no automatic conversion between modules and matrices in Macaulay2.<table class="examples"><tr><td><pre>i4 : f = matrix{{x*y,x*z},{y*z,z^2}}

o4 = | xy xz |
     | yz z2 |

             2       2
o4 : Matrix A  &lt;--- A</pre>
</td></tr>
<tr><td><pre>i5 : M = image f

o5 = image | xy xz |
           | yz z2 |

                             2
o5 : A-module, submodule of A</pre>
</td></tr>
<tr><td><pre>i6 : g = gens M

o6 = | xy xz |
     | yz z2 |

             2       2
o6 : Matrix A  &lt;--- A</pre>
</td></tr>
<tr><td><pre>i7 : f == g

o7 = true</pre>
</td></tr>
</table>
In Macaulay2, matrices are not automatically either presentation matrices or generating matrices for a module.  You use whichever you have in mind.<table class="examples"><tr><td><pre>i8 : N = cokernel f

o8 = cokernel | xy xz |
              | yz z2 |

                            2
o8 : A-module, quotient of A</pre>
</td></tr>
<tr><td><pre>i9 : presentation N

o9 = | xy xz |
     | yz z2 |

             2       2
o9 : Matrix A  &lt;--- A</pre>
</td></tr>
<tr><td><pre>i10 : presentation M

o10 = {2} | -z |
      {2} | y  |

              2       1
o10 : Matrix A  &lt;--- A</pre>
</td></tr>
</table>
Notice that the presentation of N requires no computation, whereas the presentation of M requires a syzygy computation.<p/>
<a href="_kernel_lp__Matrix_rp.html" title="kernel of a matrix">kernel(Matrix)</a> gives a submodule, while <a href="_syz_lp__Matrix_rp.html" title="compute the syzygy matrix">syz(Matrix)</a> returns the matrix.<table class="examples"><tr><td><pre>i11 : syz f

o11 = {2} | -z |
      {2} | y  |

              2       1
o11 : Matrix A  &lt;--- A</pre>
</td></tr>
<tr><td><pre>i12 : kernel f

o12 = image {2} | -z |
            {2} | y  |

                              2
o12 : A-module, submodule of A</pre>
</td></tr>
</table>
</div>
</div>
</body>
</html>