<?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>matrix(BettiTally,ZZ,ZZ) -- Betti diagram to matrix</title> <link rel="stylesheet" type="text/css" href="../../../../Macaulay2/Style/doc.css"/> </head> <body> <table class="buttons"> <tr> <td><div><a href="_pure__All.html">next</a> | <a href="_mat2cohom.html">previous</a> | <a href="_pure__All.html">forward</a> | <a href="_mat2cohom.html">backward</a> | up | <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> <hr/> <div><h1>matrix(BettiTally,ZZ,ZZ) -- Betti diagram to matrix</h1> <div class="single"><h2>Synopsis</h2> <ul><li><div class="list"><dl class="element"><dt class="heading">Usage: </dt><dd class="value"><div><tt>matrix B</tt><br/><tt>matrix(B,lowDegree)</tt><br/><tt>matrix(B,lowDegree,highDegree)</tt></div> </dd></dl> </div> </li> <li><span>Function: <a href="../../Macaulay2Doc/html/_matrix.html" title="make a matrix">matrix</a></span></li> <li><div class="single">Inputs:<ul><li><span><tt>B</tt>, <span>a <a href="../../Macaulay2Doc/html/___Betti__Tally.html">Betti tally</a></span></span></li> <li><span><tt>lowDegree</tt>, <span>an <a href="../../Macaulay2Doc/html/___Z__Z.html">integer</a></span></span></li> <li><span><tt>highDegree</tt>, <span>an <a href="../../Macaulay2Doc/html/___Z__Z.html">integer</a></span></span></li> </ul> </div> </li> <li><div class="single">Outputs:<ul><li><span><span>a <a href="../../Macaulay2Doc/html/___Matrix.html">matrix</a></span>, The Betti diagram as a matrix</span></li> </ul> </div> </li> <li><div class="single"><a href="../../Macaulay2Doc/html/_using_spfunctions_spwith_spoptional_spinputs.html">Optional inputs</a>:<ul><li><span><a href="../../Macaulay2Doc/html/_matrix_lp__List_rp.html">Degree => ...</a>, -- create a matrix from a doubly-nested list of ring elements or matrices</span></li> </ul> </div> </li> </ul> </div> <div class="single"><h2>Description</h2> <div>If either lowDegree or highDegree is not given, then they are inferred from the Betti diagram itself. The result matrix has highDegree-lowDegree+1 rows, corresponding to these (slanted) degrees. <table class="examples"><tr><td><pre>i1 : B = pureBettiDiagram {0,1,4,7} 0 1 2 3 o1 = total: 9 14 7 2 0: 9 14 . . 1: . . . . 2: . . 7 . 3: . . . . 4: . . . 2 o1 : BettiTally</pre> </td></tr> <tr><td><pre>i2 : matrix B o2 = | 9 14 0 0 | | 0 0 0 0 | | 0 0 7 0 | | 0 0 0 0 | | 0 0 0 2 | 5 4 o2 : Matrix ZZ <--- ZZ</pre> </td></tr> <tr><td><pre>i3 : matrix(B,-2) o3 = | 0 0 0 0 | | 0 0 0 0 | | 9 14 0 0 | | 0 0 0 0 | | 0 0 7 0 | | 0 0 0 0 | | 0 0 0 2 | 7 4 o3 : Matrix ZZ <--- ZZ</pre> </td></tr> <tr><td><pre>i4 : matrix(B,-2,5) o4 = | 0 0 0 0 | | 0 0 0 0 | | 9 14 0 0 | | 0 0 0 0 | | 0 0 7 0 | | 0 0 0 0 | | 0 0 0 2 | | 0 0 0 0 | 8 4 o4 : Matrix ZZ <--- ZZ</pre> </td></tr> </table> This function is essentially the inverse of <a href="_mat2betti_lp__Matrix_cm__Z__Z_rp.html" title="matrix to Betti diagram">mat2betti</a>.<table class="examples"><tr><td><pre>i5 : R = ZZ/101[a..e];</pre> </td></tr> <tr><td><pre>i6 : I = ideal borel monomialIdeal"abc,ad3,e4"; o6 : Ideal of R</pre> </td></tr> <tr><td><pre>i7 : B = betti res I 0 1 2 3 4 5 o7 = total: 1 56 182 232 135 30 0: 1 . . . . . 1: . . . . . . 2: . 5 6 2 . . 3: . 51 176 230 135 30 o7 : BettiTally</pre> </td></tr> <tr><td><pre>i8 : C = matrix B o8 = | 1 0 0 0 0 0 | | 0 0 0 0 0 0 | | 0 5 6 2 0 0 | | 0 51 176 230 135 30 | 4 6 o8 : Matrix ZZ <--- ZZ</pre> </td></tr> <tr><td><pre>i9 : B == mat2betti C o9 = true</pre> </td></tr> </table> If the lowest degree of the matrix is not 0, then this information must be supplied in order to obtain the inverse operation.<table class="examples"><tr><td><pre>i10 : B = pureBettiDiagram {-2,0,1,2,5} 0 1 2 3 4 o10 = total: 5 42 70 35 2 -2: 5 . . . . -1: . 42 70 35 . 0: . . . . . 1: . . . . 2 o10 : BettiTally</pre> </td></tr> <tr><td><pre>i11 : C = matrix B o11 = | 5 0 0 0 0 | | 0 42 70 35 0 | | 0 0 0 0 0 | | 0 0 0 0 2 | 4 5 o11 : Matrix ZZ <--- ZZ</pre> </td></tr> <tr><td><pre>i12 : mat2betti(C,-2) 0 1 2 3 4 o12 = total: 5 42 70 35 2 -2: 5 . . . . -1: . 42 70 35 . 0: . . . . . 1: . . . . 2 o12 : BettiTally</pre> </td></tr> </table> </div> </div> <div class="single"><h2>Caveat</h2> <div>Currently, the error messages are not that illuminating. The [lowDegree, highDegree], if given, must be as large as the actual degree range</div> </div> <div class="single"><h2>See also</h2> <ul><li><span><a href="_mat2betti_lp__Matrix_cm__Z__Z_rp.html" title="matrix to Betti diagram">mat2betti</a> -- matrix to Betti diagram</span></li> <li><span><a href="_lowest__Degrees_lp__Betti__Tally_rp.html" title="list of lowest degree shifts">lowestDegrees</a> -- list of lowest degree shifts</span></li> <li><span><a href="_highest__Degrees_lp__Betti__Tally_rp.html" title="list of highest degree shifts">highestDegrees</a> -- list of highest degree shifts</span></li> <li><span><a href="_is__Pure_lp__Betti__Tally_rp.html" title="is a Betti diagram pure?">isPure</a> -- is a Betti diagram pure?</span></li> <li><span><a href="_pure__Betti__Diagram_lp__List_rp.html" title="pure Betti diagram given a list of degrees">pureBettiDiagram</a> -- pure Betti diagram given a list of degrees</span></li> </ul> </div> </div> </body> </html>