Sophie

Sophie

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

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>weightVector -- weight vector of a marked set of polynomials</title>
<link rel="stylesheet" type="text/css" href="../../../../Macaulay2/Style/doc.css"/>
</head>
<body>
<table class="buttons">
  <tr>
    <td><div>next | <a href="_universal__Groebner__Basis.html">previous</a> | forward | <a href="_universal__Groebner__Basis.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>weightVector -- weight vector of a marked set of polynomials</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>weightVector(inL,L)</tt></div>
</dd></dl>
</div>
</li>
<li><div class="single">Inputs:<ul><li><span><tt>inL</tt>, <span>a <a href="../../Macaulay2Doc/html/___List.html">list</a></span>, of monomials which are to be the lead terms of the elements of <tt>L</tt></span></li>
<li><span><tt>L</tt>, <span>a <a href="../../Macaulay2Doc/html/___List.html">list</a></span>, of polynomials</span></li>
</ul>
</div>
</li>
<li><div class="single">Outputs:<ul><li><span><span>a <a href="../../Macaulay2Doc/html/___List.html">list</a></span>, of positive integers giving a weight vector under which <tt>inL</tt> are the lead terms of <tt>L</tt></span></li>
</ul>
</div>
</li>
</ul>
</div>
<div class="single"><h2>Description</h2>
<div>If there is no weight vector, then <tt>null</tt> is returned.<table class="examples"><tr><td><pre>i1 : R = ZZ/32003[symbol a..symbol d]

o1 = R

o1 : PolynomialRing</pre>
</td></tr>
<tr><td><pre>i2 : inL = {c^4, b*d^2, b*c, b^2*d, b^3}

       4     2        2    3
o2 = {c , b*d , b*c, b d, b }

o2 : List</pre>
</td></tr>
<tr><td><pre>i3 : L = {c^4-a*d^3, -c^3+b*d^2, b*c-a*d, -a*c^2+b^2*d, b^3-a^2*c}

       4      3     3      2                  2    2    3    2
o3 = {c  - a*d , - c  + b*d , b*c - a*d, - a*c  + b d, b  - a c}

o3 : List</pre>
</td></tr>
<tr><td><pre>i4 : weightVector(inL,L)

o4 = {8, 8, 3, 1}

o4 : List</pre>
</td></tr>
<tr><td><pre>i5 : groebnerCone(inL,L)

o5 = (| 0  0  |, | 1  0 |)
      | 0  0  |  | 0  1 |
      | -2 -3 |  | -2 3 |
      | -3 -4 |  | -3 4 |

o5 : Sequence</pre>
</td></tr>
</table>
<p>Now we construct all of the initial ideals of the rational quartic curve in P^3, then compute weight vectors for each, and then verify that the initial ideals that gfan returned are the initial ideals using these weight vectors.</p>
<table class="examples"><tr><td><pre>i6 : I = monomialCurveIdeal(R,{1,3,4})

                        3      2     2    2    3    2
o6 = ideal (b*c - a*d, c  - b*d , a*c  - b d, b  - a c)

o6 : Ideal of R</pre>
</td></tr>
<tr><td><pre>i7 : time (inLs,Ls) = gfan I
LP algorithm being used: "cddgmp".
     -- used 0.002521 seconds

           2          2   2      3          2   2      3          2   2  
o7 = ({{b*d , a*d, a*c , a c}, {c , a*d, a*c , a c}, {c , b*c, a*c , a c,
     ------------------------------------------------------------------------
      3      3        4     2   2      3        3     2     3        2    3  
     a d}, {c , b*c, b , a*c , a c}, {c , b*c, b , a*c }, {c , b*c, b d, b },
     ------------------------------------------------------------------------
         2   2         2        2   2    3            2        2    3     3  
     {b*d , b d, a*d, a c}, {b*d , b d, b , a*d}, {b*d , b*c, b d, b , a*d },
     ------------------------------------------------------------------------
       4     2        2    3         3      2                  2    2      3
     {c , b*d , b*c, b d, b }}, {{- c  + b*d , - b*c + a*d, a*c  - b d, - b 
     ------------------------------------------------------------------------
        2      3      2                  2    2      3    2      3      2 
     + a c}, {c  - b*d , - b*c + a*d, a*c  - b d, - b  + a c}, {c  - b*d ,
     ------------------------------------------------------------------------
                   2    2      3    2      4    3      3      2            
     b*c - a*d, a*c  - b d, - b  + a c, - b  + a d}, {c  - b*d , b*c - a*d,
     ------------------------------------------------------------------------
      4    3      2    2      3    2      3      2              3    2      2
     b  - a d, a*c  - b d, - b  + a c}, {c  - b*d , b*c - a*d, b  - a c, a*c 
     ------------------------------------------------------------------------
        2      3      2                  2    2    3    2        3      2   
     - b d}, {c  - b*d , b*c - a*d, - a*c  + b d, b  - a c}, {- c  + b*d , -
     ------------------------------------------------------------------------
        2    2                   3    2        3      2       2    2    3  
     a*c  + b d, - b*c + a*d, - b  + a c}, {- c  + b*d , - a*c  + b d, b  -
     ------------------------------------------------------------------------
      2                     3      2                  2    2    3    2      4
     a c, - b*c + a*d}, {- c  + b*d , b*c - a*d, - a*c  + b d, b  - a c, - c 
     ------------------------------------------------------------------------
          3     4      3     3      2                  2    2    3    2
     + a*d }, {c  - a*d , - c  + b*d , b*c - a*d, - a*c  + b d, b  - a c}})

o7 : Sequence</pre>
</td></tr>
<tr><td><pre>i8 : wtvecs = apply(#inLs, i -> weightVector(inLs#i, Ls#i));</pre>
</td></tr>
<tr><td><pre>i9 : wtvecs/print;
{1, 1, 4, 6}
{1, 1, 4, 5}
{1, 1, 3, 2}
{2, 2, 3, 1}
{4, 4, 3, 1}
{6, 6, 3, 1}
{1, 1, 2, 4}
{2, 2, 1, 2}
{6, 6, 2, 1}
{8, 8, 3, 1}</pre>
</td></tr>
<tr><td><pre>i10 : inL1 = wtvecs/(w -> initialIdeal(w,I));</pre>
</td></tr>
<tr><td><pre>i11 : inL1/toString/print;
ideal(a^2*c,a*d,a*c^2,b*d^2)
ideal(a*d,a^2*c,a*c^2,c^3)
ideal(b*c,a^2*c,a^3*d,a*c^2,c^3)
ideal(b*c,a^2*c,a*c^2,b^4,c^3)
ideal(b*c,c^3,a*c^2,b^3)
ideal(b*c,c^3,b^2*d,b^3)
ideal(a^2*c,a*d,b^2*d,b*d^2)
ideal(a*d,b*d^2,b^2*d,b^3)
ideal(b*c,b*d^2,a*d^3,b^2*d,b^3)
ideal(b*d^2,b*c,c^4,b^2*d,b^3)</pre>
</td></tr>
<tr><td><pre>i12 : assert(inL1 == inLs/ideal)</pre>
</td></tr>
</table>
</div>
</div>
<div class="single"><h2>Caveat</h2>
<div>In the current implementation, it might be possible that a positive vector exists, but the algorithm fails to find it.  In this case, use groebnerCone and find one by hand.  You might want to email the package author to complain too!</div>
</div>
<div class="single"><h2>See also</h2>
<ul><li><span><a href="_gfan.html" title="all initial ideals of an ideal">gfan</a> -- all initial ideals of an ideal</span></li>
<li><span><a href="_initial__Ideal.html" title="initial ideal with respect to a weight vector">initialIdeal</a> -- initial ideal with respect to a weight vector</span></li>
<li><span><a href="_groebner__Cone.html" title="the cone whose interior weight vectors give the given initial ideal">groebnerCone</a> -- the cone whose interior weight vectors give the given initial ideal</span></li>
</ul>
</div>
<div class="waystouse"><h2>Ways to use <tt>weightVector</tt> :</h2>
<ul><li>weightVector(List,List)</li>
</ul>
</div>
</div>
</body>
</html>