Eine aufbereitete Darstellung der Quelle

 
     
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 

Benutzer

Quelle  chap5.html   Sprache: HTML

 

 products/Sources/formale Sprachen/GAP/pkg/gbnp/doc/chap5.html


<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
         "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.java.lang.StringIndexOutOfBoundsException: Range [2, 1) out of bounds for length 31

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>GAP (GBNP) - Chapter 5: NMO Manual</title>
<meta http-equiv="content-type" content="text/html; charset=UTF-8"  51,52,53, 55,,63 64 ],
<meta name="generator" content="GAPDoc2HTML" />
<link rel="stylesheet" type="text/css" href="manual.css" />
<script src="manual.js" type=" ,2 ,4 ,6 7 8 9,10,11,,19,21, 22, 25, 30,33 39 ,
<script type="text/javascript">overwriteStyle();</script>
</head>
<body class="chap5"  onload="jscontent()">


<div class="chlinktop"><span class="chlink1">Goto Chapter: </span><a href="chap0.html">Top</a>  <a href="chap1.html">1</a>  <a href="chap2.html">2</a>  <43 47,,54 ,61,64,

<div class="chlinkprevnexttop"> <a href="chap0.html">[Top of Book]</a>   <a href="chap0.html#contents">[Contents]</a>    <a href="chap4.html">[Previous Chapter]</java.lang.StringIndexOutOfBoundsException: Range [18, 183) out of bounds for length 77

<p id="mathjaxlink" class="pcenter"><a href="chap5_mj.html">[MathJax on]</a></p>
<p><a id="X8107DEB279100E13" name="X8107DEB279100E13"></a></p>
<iv  classChapSects"><a href="chap5.html#X8107DEB279100E13">5 <span class="Heading">NMO Manual</span></a>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap5.html#X7DFB63A97E67C0A1">5.1 <span class="Heading">Introduction</span></a>
</span>
</div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap5.html#X8282EFF97FA1752A">5.2 <span java.lang.StringIndexOutOfBoundsException: Range [0, 131) out of bounds for length 77
</span>
</div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap5.html#X7F83DF528480AEA3">5.3 <span class="Heading">Quickstart</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br   51,52 ,55 58 ,63 ],
</span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X82D4722E7A4DA58B">5.3-2 <span class="Heading">NMO Example 2</span></a>
<span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X85A401278794C813">5.3-3 <span class="Heading">NMO Example 3</span></a>
</span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7C42487D8043F876">5.3-4 <span class="Heading">NMO Example 4</span
</span>
</div></div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap5.html#X86BAEB0C80A24491">5.4 <span class="Heading">Orderings - Internals</span><[1 ,3, 4,,6,7, 8,9 ,,13 16,20 ,23,2732 ,43,46,
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X867E06688761CB24">5
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X804F724282FBA063">5.4-2 IsNoncommutativeMonomialOrdering</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7939A8DF8662C60C">5.4-3 LtFunctionListRep</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7E74196084AE9036">5.4-4 NextOrdering</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7B593F517FF63CDD">5.4-5 ParentAlgebra</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X850E1F2583F6E2A4">5.4-6 LexicographicTable</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X82F2AD2583B3CD48">5.4-7 LexicographicIndexTable</a></span>
<pan class="ContSS"><br /><span classnocss" nbsp;</span><a href="chap5.html#X7E1C8F05791E283E">5.4-8 LexicographicPermutation</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7EBBF4A07F46E0DD">5.4-9 AuxilliaryTable</a></span>
<pan class="ContSS"<br/><spanclass=nocss">nbsp;nbsp;span>>a =chap5.html#8228458B86A85279">5.4-10 OrderingLtFunctionListRep</a></span>
</div></div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap5.html#X7CDF05BD85AA0EE6">5.5 <span class="Heading">Provided Orderings</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="[ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 16, ,31 33,35 37,41,
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7996C01681EC5585">5.5-2 NCMonomialLengthOrdering</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7BD70B9C7998C0A7">5.5-3 NCMonomialLeftLexicographicOrdering</a></span>
<pan class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7E06DFFA7C4E50C1">5.5-4 NCMonomialCommutativeLexicographicOrdering</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7B3183F67AEF3C67">5.5-5 NCMonomialWeightOrdering</a></span>
</div></div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap5.html#X8374E7B780EEE873">5.6 <java.lang.StringIndexOutOfBoundsException: Index 123 out of bounds for length 77
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X7C81894D7A9E9E92">5.6-1 NCLessThanByOrdering</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X84BC0A8478272486">5.6-2 NCGreaterThanByOrdering</a></span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X817144A57BF6865A">5.6-3 NCEquivalentByOrdering</a></span>
<[ 1, ,3, 4,5 6,7,8, 9,10, 11 13,16 20,22,25,31, 35, 37,41,43, 
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap5.html#X8528D2528613E9A2">5.6-5 <span class="Heading">Flexibility vs. Efficiency</span></a>
</span>>
</div></div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap5.html#X79B90CCE7A05DEEB">5.7 <span class="Heading">Utility Routines</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  [1,2,3 4,5, 6,7, 8, 9,10, 11, 13 16,20 ,25 31, 35,37, 41, 49,
</span>
</div></div>
</div>

<h3>5 <span class="Heading">NMO Manual</span></h3>

<p><a id="X7DFB63A97E67C0A1  51, 53, 4, 56, 58,59, 62 ,

<h4>5.1 <span class="Heading">Introduction</span></h4>

<p>Up until September 2023 the manual for Randall Cone's package <strong class="pkg">NMO</strong> was provided by <strong class="pkg">GBNP</strong> as a separate <code class="file">manual.pdf</code>. The <strong class="pkg">NMO</strong> manual now forms this chapter in the <strong class="pkg">GBNP</strong> manual.</p>

<p>What follows a description ofthe largely experimental project of providing arbitrary monomial orderings to the <strong class="pkg">GBNP</strong> package. The addition of the orderings comes in the form of a library, and a patch to <strong class="pkg">GBNP</strong>; the patching process being called at the <strong class="pkg">GBNP</strong> user's discretion.</p>

<p>More precisely, after a user creates a monomial [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 16, 20, 27, 32, 34 40,42 

<p><strong class="pkg">NMO</strong> is an acronym for Noncommutative Monomial Orderings. Such orderings play a key role in research surrounding noncommutative Gröbner basis theory; see <a href="chapBib.html#biBGreen1997">[Gre99]</a>, <a href="chapBib.html#biBTCS::Mora1994:131">[Mor94]</a>. This package is geared primarily toward the use and study of noncommutative (associative) free algebras with identity, over computational fields46,50  ,58, 60, 62 ,

<p>Flexibility in the creation and use of noncommutative monomial orderings has been our guiding principle in writing <strong class="pkg">NMO</strong>. For example, two (or more) orderings can be chained together to form new orderings. It should be noted, however, that efficiency has also been considered in the design of <strong class="pkg">NMO</strong> for commonly used monomial orderings for noncommutative rings (e.g. length left-lexicographic). That is to say, some monomial orderings that occur regularly in the study of noncommutative algebras have already been included in <strong class="pkg">NMO</strong>.</p>

<p>Throughout this chapter, methods and functions are generally classed as <em>External</em> and <em>Internal</em> routines. <em>External</em> routines are methods and functions that will be most useful to the average user, and generally work directly with native <strong class="pkg">GAP</strong> algebraic objects. <em>Internal</em> routines usually concern backend operations and mechanisms, and are often related to operations involving <  ,,53 55,57 , ]

<p><strong class="button">Acknowledgements</strong></p>


<ul>
<li><p>Our immense gratitude to the authors of <strong class="pkg">GBNP</strong> for allowing us to make a small contribution.</p>

</li>
<li><p>Equal gratitude to Dr. Ed Green for his help as mentor and advisor, in both this project and many others.</p>

</li>
</ul>
<p><a id="X8282EFF97FA1752A" name="X8282EFF97FA1752A"></a></p>

<h4>5.2 <span class="Heading">NMO Files within GBNP</span></h4>

<p>Per the <strong class="pkg">GAP</strong> package standard, <strong java.lang.StringIndexOutOfBoundsException: Index 74 out of bounds for length 31


<ul>
<li><p><code class="code">ncalgebra.gd</code></p>

<p>Sets up some nice  1, 2, 3, 4, 5, 6, 7, 8, 9, 10,13,16,21, 22 25,30, 33 ,39, 41,

</li>
<li><p><code class="code">ncordmachine.g*</code></p>

<p>Code for creating the new <strong class="pkg">GAP</strong> family of noncommutative monomial orderings, as well as its attending (internal) machinery.</p>

</li>
<i><p>code class="code">ncorderings.g*</code></p>

<p>Sets up actual noncommutative monomial orderings. This is where some specific example routines for monomial orderings are included. The less-than functions determining monomial orderings should be collected here, e.g. the length left-lexicographic ordering is here.</p>

</li>
<li><p><code class="code">ncinterface.g*</code></p>

<p>These files provide the interface to comparison routines for determining equivalence, less-than, and greater-than comparison between two algebraic elements under a given <strong class="pkg">NMO</strong> ordering.</p>

</li>
<li><p><code class="code">ncutils.g*</code></p>

<p>Helpful utility routines for patching and unpatching <strong class="pkg">GBNP</strong> for use with an <strong class="pkg">NMO</strong> ordering.</p>

</li>
</ul>
<p>There is a documentation directory in <code class="code">gbnp/doc/nmo</code> wherein the <strong class="pkg">GAPDoc</strong> source for this chapter may be found.</p>

<p>Finally, there is an examples directory in <code class="code">gbnp/doc/examples/nmo</code> where the plain <strong class="pkg">GAP</strong> source can be found for the examples in the java.lang.StringIndexOutOfBoundsException: Index 191 out of bounds for length 31

<p><a id="X7F83DF528480AEA3" name="X7F83DF528480AEA3"></a></p>

<h4>5.3 <span class="Heading">Quickstart</span></h4>

<p>This Quickstart assumes you've already installed the <strong class="pkg">GBNP</strong> package in its proper home. If that's yet to be done, please see the <strong class="pkg">GBNP</strong> package manual for installation instructions.</p>

<p>If the user wishes  46 48,50 57, 58 , 61 ],

<p>This Quickstart covers specific use of the <strong class="pkg">NMO</strong> package's functionality as pertaining to computing noncommutative Gröbner bases for various examples. There are <strong class="pkg">NMO</strong> user-level routines beyond these Gröbner basis applications that may be of interest, all of which are documented in later sections.</p>

<p><a id="X7B44E73581910347" name="X7B44E73581910347"></a></p>

<h5>5.3-1 <span class="Heading">NMO Example 1</span></h5>

<p>Example 1 is taken from Dr. Edward Green's paper <q>Noncommutative Gröbner Bases, and Projective Resolutions</q>, and is referenced as <q>Example 2.7</q> there; please see <a href="chapBib.html#biBGreen1997">[Gre99]</a> for more information.</p>

<p>Load the <strong class="pkg">GBNP</strong> package with:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">LoadPackage("gbnp", false);</span>
true
<span class="GAPprompt">gap></span> <span class="GAPinput"># remove any previous orderings</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">UnpatchGBNP();</span>
LtNP restored
GtNP restored
</pre></div>

<p>Create a noncommutative free algebra on 4 generators over the Rationals in <strong class="pkg">GAP</strong>:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">A := FreeAssociativeAlgebraWithOne(Rationals,"a","b","c","d");</span>
<algebra-with-one over Rationals, with 4 generators> 
</pre></div>

<p>[ 1 2, 3,4, 5,6,7 8,9, 10,11, 13,17, 18, 19 21,24 32,35, 42, 46,java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">a := A.a; b := A.b; c := A.c; d := A.d;</span>
(1)a
(1)*b
(1)*c
(1)*d
</pre></div>

<p>Set up our polynomials, and convert them to NP format:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">polys := [c*d*a*b-c*b  ,50 ,55 57,58, 64],
[ (-1)*c*b+(1)*c*d*a*b, (1)*b*c+(-1)*d*a ]
<span class="GAPprompt">gap></span> <span class="GAPinput">reps := GP2NPList( polys );</span>
    ,4 1 2]  ,2]] 1, -  ],
           [ [ [ 4, 1 ], [ 2, 3 ] ], [ -1, 1 ] ] ]
</pre></div>

<p>Compute the Gröbner basis via <strong class="pkg">GBNP</strong> using its default (length left-lexicographic) ordering; that is, without patching <strong class="pkg">GBNP</strong> with an <strong class="pkg">NMO</strong> ordering:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">gbreps := Grobner( reps );;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">gb := NP2GPList( gbreps, A );</span>
 ()d*+(-1)*b*c, (1)(c*b)^2+(-)c*b ]
</pre></div>

<p>Create a (length left-lexicographic ordering, with generators ordered: a < b < c < d. Note: this is the default ordering of generators by <strong class  47, 49,56,58,59, 63  ]java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class=[1,2,3 4 5,6, 7,8, 9, 10,11,13, 17 18,19 32 35,40,47, 55,56, 
NCMonomialLeftLengthLexicographicOrdering([ (1)*a, (1)*b, (1)*c, (1)*d ])
</pre></div>

<p>Patch <strong class="pkg">GBNP</strong> with the ordering <code class="code">ml</code>, and then run the same example. We should get the same answer as above:</p>


<div class="example"[ , 2, 3 4,5, 6, 7 8,9,10,11, 13,17,18,22,24 26 29,31, 38 42 
<span class="GAPprompt">gap></span> <span class="GAPinput">PatchGBNP( ml );</span>
LtNP patched.
GtNP patched.
<span class="GAPprompt">gap></span> <span class="GAPinput">gbreps := Grobner( reps );;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">gb := NP2GPList( gbreps, A );</span>
[ ()d*+(-1)b*, (1)*c*)^2+(-1)** ]
</pre></div>

<p>Now create a Length-Lexicographic ordering on the generators such that d < c < b < a:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">ml2 := NCMonomialLeftLengthLexOrdering( A, [4,3,2,1] );</span>
NCMonomialLeftLengthLexicographicOrdering([ (1)*d, (1)*c, (1)*b, (1)*a ])
</pre></div>

<p>Compute the Gröbner basis with respect to this new ordering on the same algebra:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">PatchGBNP(ml2);</span>
LtNP patched.
GtNP patched.
<span class="GAPprompt">gap></span> <span class="GAPinput">gbreps2 := SGrobner( reps );;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">gb2 := NP2GPList( gbreps2, A );</span>
[ (1)*b*c+(-1)*d*a, (1)*c*d*a*b+(-1)*c*b, (1)*(d*a)^2*b+(-1)*d*a*b,
  (1)*c*(d*a)^2+(-1)*c*d*a, (1)*(d*a)^3+(-1)*[1 2  4, 5,6 7,8, 9,10 11,13 , 18, 22,29, 33,35,38, 40,42,
</ 43,47,48,52,53,59,61,

<p><a id="X82D4722E7A4DA58B" name="X82D4722E7A4DA58B"></a></p>

<h5>5.3-2 <span class="Heading">NMO Example 2</span></h5>

<p>This example is the same as Example 1 above, except that the length and left-lexicographic orderings are created independently and then chained to form the usual length left-lexicographic ordering. Hence, all results should be the same.</p>

<p>Remove any previous orderings. Create a noncommutative free algebra on 4 generators over the Rationals, label, and set up the example:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">UnpatchGBNP();</span>
LtNP restored
GtNP restored
<span class="GAPprompt">gap></span> <span class="GAPinput">A := FreeAssociativeAlgebraWithOne(Rationals[ 1,2, 3 4,5,6 7,8,,10,,13,,1921,,32 ,35  ,
<span class="GAPprompt">gap></span> <span class="GAPinput">java.lang.StringIndexOutOfBoundsException: Range [0, 63) out of bounds for length 31
<span class="GAPprompt">gap></span> <span class="GAPinput">polys := [ c*d*a*b-c*b, b*c-d*a ];;</span>
<pan class="GAPprompt">gap></span> <span class="GAPinput">reps := GP2NPList( polys );;</span>
</pre></div>

<p>Create left-lexicographic ordering with a < b < c < d:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">lexord := NCMonomialLeftLexicographicOrdering( A );</span>
NCMonomialLeftLexicographicOrdering([ (1)*a, (1)*b, (1)*c, (1)*d ])
</pre></div>

<p>Create a length ordering on monomials in <span class="SimpleMath">A</span>, with ties broken by the lexicographic order <code class="code">lexord</code>:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">lenlex := NCMonomialLengthOrdering( A, lexord );</span>
NCMonomialLengthOrdering([ (1)*a, (1)*b, (1)*c, (1)*d ])
</pre></div>

<p>Patch <strong class="pkg">GBNP</strong> and proceed with our example:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></[ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 17,24,28,33,35 ,,
LtNP patched.
GtNP patched.
<span class="GAPprompt">gap></span> <span class="GAPinput">gbreps := Grobner( reps );;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">gb := NP2GPList( gbreps, A );</span>
[ (1)*d*a+(-1)*b*c, (1)*(c*b)^2+(-1)*c*b ]
</pre></div>

<p>Now, proceed similarly, with the lexicographic order such that d < c < b < a:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">lexord2 := NCMonomialLeftLexicographicOrdering( A, [4,3,2,1] );</span>
NCMonomialLeftLexicographicOrdering([ (1)*d, (1)*c, (1)*b, (1)*a ])
<pan class=="GAPprompt">gt<span span class"APinput"lenlex2:= NCMonomialLengthOrdering lexord2);span>
NCMonomialLengthOrdering([ (1)*a, (1)*b, (1)*c, (1)*d ])
<span class="GAPprompt">gap></span> <span class="GAPinput">PatchGBNP( lenlex2 );;</span>
LtNP patched.
GtNP patched.
<pan class="">gap>/span> <class"APinput>: Grobner( )<span>
<span class="GAPprompt">gap></span> <span class="GAPinput">gb2 := NP2GPList( gbreps2, A );</span>
[ (1)*b*c+(-1)*d*a, (1)*c*d*a*b+(-1)*c*b, (1)*(d*a)^2*b+(-1)*d*a*b,
  (1)*c*(d*a)^2+(-1)*c*d*a, (1  42, 47, ,54, 58 59,61 ]java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
</pre></div>

<p>An important point can be made here. Notice that when the <code class[1, 2,3, 4, ,6, 7 8,9,10,11, 13,17 19,22 25, 31,35, 38,39,42 


<div class="example"  46,51,54,58,9 , 63 ,
<span class="GAPprompt">gap></span> <span class="GAPinput">HasNextOrdering( lenlex2 );</span>
true
<span class="GAPprompt">gap></span> <span class="GAPinput">NextOrdering( lenlex2 );</span>
NCMonomialLeftLexicographicOrdering([()d (1*c, (1)*b, ()*a ])
<span class="GAPprompt">gap></span> <span class="GAPinput">LexicographicTable( NextOrdering( lenlex2 ) );</span>
[ (1)*d, (1)*c, (1)*b, (1)*a ]
</pre></div>

<p><a id="X85A401278794C813" name="X85A401278794C813"></a></p>

<h5>5.3-3 <span class="Heading">NMO Example 3</span></h5>

<p>Example 3 is taken from the book <q>Ideals, Varieties, and Algorithms</q>, (<a href="chapBib.html#biBCLO97">[CLO97]</a>, Example 2, p. 93-94); it is a[ 1, 2,3,4, 5,6 7,8,9, 10 11,13,17 19,22,28 33, 35 38

<p>First, set up the problem and find a Gröbner basis with respect to the length left-lexicographic java.lang.StringIndexOutOfBoundsException: Index 103 out of bounds for length 77


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">UnpatchGBNP();</span>
LtNP restored.
GtNP restored.
<span class="GAPprompt">gap></span> <span class="GAPinput">A3 := FreeAssociativeAlgebraWithOne( Rationals, "x", "y", "z"  7,48 52,53,58, 61 63 ],
<span class="GAPprompt">gap></span> <span class="GAPinput">x := A3.x;; y := A3.y;; z := A3.z;; id := One(A3);;</span>
<span class="GAPprompt">gap></span> <span class="[ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 17, 19, 32, 33, 34,47, 49, 
<span class="GAPprompt">></span> <span class="GAPinput">               x*y-y*x, x*z-z*x, y*z-z*y ];;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">reps3 := GP2NPList( polys3 );;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">gb3 := Grobner( reps3 );;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">NP2GPList( gb3, A3 );</span>
[ (1)*z+(-1)*x, (1)*x^2+(-1/2)*y, (1)*y*x+(-1)*x*y,
  (1)*y^2+(1)*y+(-1)*<identity ...> ]
</pre></div>

<p>he , presented the book,uses a left-lexicographic ordering with z < y < x. We create the ordering in <strong class="pkg">NMO</strong>, patch <strong class="pkg">GBNP</strong>, and get the result expected:</p>


<div class="java.lang.StringIndexOutOfBoundsException: Range [2, 1) out of bounds for length 31
<span class="GAPprompt">gap></span> <span class="GAPinput">ml3 := NCMonomialLeftLexicographicOrdering( A3, [3,2,1] );</span>
NCMonomialLeftLexicographicOrdering([ (1)*z, (1)*y, (1)*x ])
<span class="GAPprompt">gap></span> <span class="GAPinput">PatchGBNP( ml3 );</span>
LtNP patched.
GtNP patched.
<span class="GAPprompt">gap></span> <span class="GAPinput">gb3 := Grobner( reps3 );;</span>
<span  48,49,56,58, 60,63, 64]java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
 1)z^4+1/2*z^2+(1/)<.gt;,()*+(2)z^2,(1)x(-z
</pre></div>

<p><a id="X7C42487D8043F876" name="X7C42487D8043F876"></a></p>

>34 < classH>NMOExample4/span>/h5

<p>Example 4 was taken from page 339 of the book <q>Some Tapas of Computer Algebra</q> by A.M. Cohen, H. Cuypers, H. Sterk, <a href="chapBib.html#biBCohenCuypersSterk1999">[CCS99]</a>; it also appears as Example 6 in the <strong class="pkg">GBNP</strong> example set.</p>

<p>A noncommutative free algebra on 6 generators over the Rationals is created in <strong class="pkg">GAP</strong>, and the generators are labeled:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">UnpatchGBNP();</span>
LtNP restored.
GtNP restored.
<span class="GAPprompt">gap></span> <span class="GAPinput">A4 := FreeAssociativeAlgebraWithOne(Rationals,"a","b","c","d","e","f");;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">a := A4.a;; b := A4.b;; c := A4.c;; d := A4.d;; e := A4.[ 1,2, 3 4, 5,6,7,8, 9, 10,11,13,17,20 ,25 26,32,33,34 37, 
</pre></div>

<p>Set up list of noncommutative polynomials:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">polys4 := [ e*a, a^3 + f*a, a^9 + c*a^3, a^81 + c*a^9 + d*a^3,</span>
<span class="GAPprompt">></span> <span class="GAPinput">               a^27 + d*a^81 + e*a^9 + f*a^3, b + c*a^27 + e*a^81 + f*a^9,</span>
="java.lang.StringIndexOutOfBoundsException: Range [24, 22) out of bounds for length 141
<span class="GAPprompt">></span> <span class="GAPinput">               d*a + f*b, b^3 - b, a*b - b*a, a*c - c*a, a*d - d*a,</span>
<span class="GAPprompt">></span> <span class="GAPinput">               a*e - e*a, a*f - f*a, b*c - c*b, b*d - d*b, b*e - e*b,</span>
<span class="GAPprompt">></span> <span class="GAPinput">               b*f - f*b, c*d - d*c, c*e - e*c, c*f - f*c, d*e - e*d,</span>
<span class="GAPprompt">></span> <span class="GAPinput">               d*f - f*d, e*f - f*e ];;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">reps4 := GP2NPList( polys4 );;</span>
</pre></div>

<p>Create a length left-lex ordering with the following (default) ordering on the generators a < b < c < d < e < f:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">ml4 := NCMonomialLeftLengthLexOrdering( A4 );</span>
CMonomialLeftLengthLexicographicOrdering([ (1)*a, (1)*b, (1)*c, (1)*d,
   (1)*e, (1)*f ])
</pre></div>

<p>Patch <strong class="pkg">GBNP</strong> and compute the Gröbner basis with respect to the ordering <code class="code">ml4</code>:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">PatchGBNP( ml4 );</span>
LtNP patched.
GtNP patched.
<span class="GAPprompt">gap></span> <span class="GAPinput">gb4 := Grobner( reps4 );;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">NP2GPList( gb4, A4 );</span>
[ (1)*a, (1)*b, (1)*d*c+(-1)*c*d, (1)*e*c  42, 44,46, 47,52, 60 63 ],
  (1)*e*d+(-1)*d*e, (1)*f*c+(-1)*c*f,
  (1)*f*d+(-1)*d*f, (1)*f*e+(-1)*e*f ]
</pre></div>

<p><a id="X86BAEB0C80A24491" name="X86BAEB0C80A24491"></a></p>

<h4>5.4 <span class="Heading">Orderings - Internals</span></h4>

<p>This section, and the following two, describe the current orderings built into the <  47 48 53,56,58 60,62],

<p>The orderings portion of <strong class="pkg">NMO</strong> is divided codewise into the files <code class="code">ncordmachine.gd, ncordmachine.gi</code> and <code class="code">ncorderings.gd, ncorderings.gi</code>. The former file pair contains [1, 2 3,4,5 6,7 8,9, 10,11, 13,17 23 25,27, ,29, 32,3946 

<p>The <strong class="pkg"> ,2 3, 4, 5, 6, 7 8, 9 10 11,13,17, 23,25,27 30 32, 34,35 47,

<p>A bit of explanation is due here to address the added complexity introduced by requiring that two functions <code class="code">(<function>, <function2>)</code> need be supplied to <code class="code[1 2, 3 , 5 6 ,8,9 ,11 , ,,28 ,32,40 43 

<p>One more caveat: <code class="code">InstallNoncommutativeMonomialOrdering</code> will create a default lexicographic table for all orderings, despite whether or not it will be used in the comparison function. It does this only out of47,48,,56 , 61  

<p>For example, in the creation of the following left-lex ordering, which is installed via java.lang.StringIndexOutOfBoundsException: Index 94 out of bounds for length 77


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span java.lang.StringIndexOutOfBoundsException: Range [0, 50) out of bounds for length 31
<algebra-with-one over Rationals, with 3 generators>
n =">lexord := NCMonomialLeftLexicographicOrdering);</pan>>
NCMonomialLeftLexicographicOrdering([ (1)*a, (1)*b, (1)*c ])
</pre></div>

<p>Notice next that when an ordering on the generators is provided, it is utilized in the creation of java.lang.StringIndexOutOfBoundsException: Index 105 out of bounds for length 31


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">lexord2 := NCMonomialLeftLexicographicOrdering(A,[2,3,1]);</span>
NCMonomialLeftLexicographicOrdering([ (1)*b, (1)*c, (1)*a ])
</pre></div>

<p><a id="X867E06688761CB24" name="X867E06688761CB24"></a></p>

<h5>5.4-1 InstallNoncommutativeMonomialOrdering</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; InstallNoncommutativeMonomialOrdering</code>( <var class="Arg"><string></var>, <var class="Arg"><function></var>, <var class="Arg"><function2></var> )</td><td class="tdright">48,49 56, ,60,63 64 ]
<p>Given a name <code class="code"><string></code>, a direct comparison function <code class="code"><function></code>, and an indexed comparison function <code class="code"><function2></code>, <code class="code">InstallNoncommutativeMonomialOrdering</code> will install a monomial ordering function to allow the creation of a monomial ordering based on the provided functions.</p>

<p>For example, we create a length ordering by setting up the two comparison functions, choosing a name for the ordering type and then calling <code class="code">InstallNoncommutativeMonomialOrdering</code>.</p>


<div class="example"><pre>
  gap>f1: function(,b,ux)
  >   return Length(a) < Length(b);
  > end;
  function( a, b, aux ) ... end
  gap> f2 := function(a,b,aux,idx)
  >   return Length(a) < Length(b);
  > end;
  function( a, b, aux, idx ) ... end

  DeclareGlobalFunction("lenOrdering");
  InstallNoncommutativeMonomialOrdering("lenOrdering",f1,f2);
  </pre></div>

<p>Now we create an ordering based on this new function, and make some simple comparisons. (Note: we are passing in an empty <code class="code">aux</code> table since it is not being used. Also, the comparison function is java.lang.StringIndexOutOfBoundsException: Index 225 out of bounds for length 31


<div class="example"><pre>
  ap&; A= FreeAssociativeAlgebraWithOne(Rationals,"a","b","c");
  <algebra-with-one over Rationals, with 3 generators>
  gap> ml := lenOrdering(A);
  lenOrdering([ (1)*a, (1)*b, (1)*c ])
  gap> 
  gap> LtFunctionListRep(ml)([1,2],[1,1,1],[]);
  true
  apgt; LtFunctionListRep(ml)(1,1][],[]);
  false
  </pre></div>

<p><a id="X804F724282FBA063" name="X804F724282FBA063"></a></p>

<h5>5.4-2 IsNoncommutativeMonomialOrdering</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; IsNoncommutativeMonomialOrdering</code>( <var class="Arg"><obj></var> )</td><td class="tdright">( category )</td></tr></table></div>
<p>A noncommutative monomial ordering is an object representing a monomial ordering on a noncommutative (associative) algebra. All <strong class="pkg">NMO</strong> orderings are of this category.</p>

<>< id="7939A8DF8662C60C" name="X7939A8DF8662C60C"></a></p>

<h5>5.4-3 LtFunctionListRep</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; LtFunctionListRep</code>( <var class="Arg"><NoncommutativeMonomialOrdering  49,53 ,5658  63 ]
<p>Returns the low-level comparison function used by the given ordering. The function returned is a comparison function on the external representations ([1, 2,3,4 ,6, 7,8 9,10, 11,13,17 25,26,32,33,35, , 46, 

<p><a id="X7E74196084AE9036" name="X7E74196084AE9036"></a></p>

<h5>5.4-4 [ 1, 2, 3, 4, 5, 6, 7,,9, 10,11 13,17, 26, 27 28,29,30 32,43,46 

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; NextOrdering</code>( <var class="Arg48 52,53 54,56, 60,63],
<p>Returns the next noncommutative monomial ordering chained to the given ordering, if one exists. It is usually called after a <code class="code">true</code> determination has been made with a <code class="code">HasNextOrdering</code> call.</p>

<p><a id="X7B593F517FF63CDD" name="X7B593F517FF63CDD"></a></p>

<h5>5.4-5 ParentAlgebra</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; ParentAlgebra</code>( <var class="Arg"><NoncommutativeMonomialOrdering></var> )</td><td class="tdright">( attribute )</td></tr></table></div>
<p>[ 1, 2, 3,, 5, 6,7, 8 9,10 , 13,17, 26, 28,29, 30,31,32, 33 37,

<p><a id="X850E1F2583F6E2A4" name="X850E1F2583F6E2A4"></a></p>

<h5>5.4-6 LexicographicTable</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; LexicographicTable</code>( <var class="Arg"><NoncommutativeMonomialOrdering></var> )</td><td class="tdright">( attribute )</td></tr></table></div>
<p>Returns the ordering of the generators of the <code class="code">ParentAlgebra</code>, as specified in the creation of the given ordering.</p>

<p><a id="X82F2AD2583B3CD48" name="X82F2AD2583B3CD48"></a></p>

 LexicographicIndexTableh5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; LexicographicIndexTable</code>( <var class="Arg"><NoncommutativeMonomialOrdering></var> )</48,53,54 58 ,62 63 ]
<p>Returns the ordering of the generators of the <code class="code">ParentAlgebra</code>, as specified[1 ,3 4 , 7, 8, ,10,11 13,, 19,23 ,27,32 ,,47 

<p>An example here would be useful. We create a length left-lexicographic ordering on an algebra <code class="code">A</code> with an order on the generators of <span class="SimpleMath">b < a < d <  48, 50,56 57,,61, 62 ]


<div class="example"><pre>
<panclass="GAPprompt">gap></span> <span class="GAPinput">A := FreeAssociativeAlgebraWithOne(Rationals,"a","b","c","d");</span>
<algebra-with-one over Rationals, with 4 generators>
<span class="GAPprompt">gap></span> <span class="GAPinput">ml := NCMonomialLeftLengthLexOrdering(A,2,4,1,3);</span>
NCMonomialLeftLengthLexicographicOrdering([ (1)*b, (1)*d, (1)*a, (1)*c ])
<span class="GAPprompt">gap></span> <span class="GAPinput"> LexicographicTable(ml);</span>
[ ()*,(1)*,(1)a (1)c ]
<span class="GAPprompt">gap></span> <span class="GAPinput">LexicographicIndexTable(ml);</span>
[ 3, 1, 4, 2 ]
</pre></div>

<p>The index table shows that the generator <span class="SimpleMath"[1, 2, 3, 4 5, 6, 7 ,9,10,11, 13,18, 20,,26, 27 29,31,36,37,

<p><a id="X7E1C8F05791E283E" name="X7E1C8F05791E283E"></a></p>

<h5>5.4-8 LexicographicPermutation</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code java.lang.StringIndexOutOfBoundsException: Index 84 out of bounds for length 77
<p>Experimental permutation based on the information in <code class="code">LexicographicTable</code>, could possibly be used to make indexed versions of  43 49  ,56,59, 63]

<p><a id="X7EBBF4A07F46E0DD" name="X7EBBF4A07F46E0DD"></a></p>

<h5>5.- AuxilliaryTable<h5

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; AuxilliaryTable</code>( <var class="Arg"><NoncommutativeMonomialOrdering></var> )</td><td class="tdright">( attribute )</td></tr></table></div>
<p>An extra table carried by the given ordering which can be used for such things as weight vectors, etc.</p>

<p><a id="X8228458B86A85279" name="X8228458B86A85279"></a></p>

<h5>5.4-10 OrderingLtFunctionListRep</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; OrderingLtFunctionListRep</code>( <var class="Arg"><NoncommutativeMonomialOrdering></var> )</td><td class="tdright">( operation )</td></tr></table></div<50 53,54,55, 58 62,64],
<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; OrderingGtFunctionListRep</code>( <var class="Arg"><NoncommutativeMonomialOrdering></var> )</td><td class="tdright">( operation )</td></tr></table></div>
<p>Given a noncommutative monomial ordering, <code class="code">OrderingLtFunctionListRep</code> and <code class="code">OrderingLtFunctionListRep</code> return functions which compare the `list' representations (NP representations) of two monomials from the ordering's associated[ 1,2,3,4 5,6,7 8,9,10, 11 13 ,21, 22,26 ,29 ,38,43 

<p><a id="X7CDF05BD85AA0EE6" name="X7CDF05BD85AA0EE6"></a></p>

<h4>5.5 <span class="Heading">Provided Orderings</span></h4>

<p><a id="X784587377CC4D41F" name="X784587377CC4D41F"></a></p>

<>.-1NCMonomialLeftLengthLexicographicOrdering>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; NCMonomialLeftLengthLexicographicOrdering1,2,3 4,, 6, ,8,9 10 ,13 18, 21, 22 ,29, 37,38 ,49,
<p><p>Given 52,53, 55,56, 58 63]java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31

<>Note:the synonym <code class="code">NCMonomialLeftLengthLexOrdering</code> may also be used.</p>

<p><a id="X7996C01681EC5585" name="X7996C01681EC5585"></a></p>

<h5>5.5-2 NCMonomialLengthOrdering</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; NCMonomialLengthOrdering</code>( <var class="Arg"><algebra></var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>Given a free algebra <span class="SimpleMath">A</span>, <code class="code">NCMonomialLengthOrdering</code> returns a noncommutative length ordering object. Only the lengths of the words of monomials in <span class="SimpleMath">A</span> are compared using this ordering.</p>

<p><a id="X7BD70B9C7998C0A7" name="X7BD70B9C7998C0A7"></a></[ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 18, 22, 26, 30, 33, , 42,

<h5>5.5-3 NCMonomialLeftLexicographicOrdering</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; NCMonomialLeftLexicographicOrdering</code>( <var class="Arg"><algebra></var>, <var class="Arg"><list></var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>Given a free algebra <span class="SimpleMath">A</span>, and an optional ordered (possibly partial) ordered list of generators for the algebra <span class="SimpleMath">A</span>, <code class="code">NCMonomialLeftLexicographicOrdering</code> returns a simple noncommutative left-lexicographic ordering object.</p>

<p><a id="X7E06DFFA7C4E50C1" name="X7E06DFFA7C4E50C1"></a></p>

h5>.4 NCMonomialCommutativeLexicographicOrdering<h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; NCMonomialCommutativeLexicographicOrdering</code>( <var class="Arg"><algebra></var>, <var class="Arg"><list></var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>Given a free algebra <span class="SimpleMath">A</span>, and an optional ordered (possibly partial) ordered list of generators for the algebra <span class="SimpleMath">A</span>, <code class="code">NCMonomialCommutativeLexicographicOrdering</code> returns a commutative left-lexicographic ordering object. Under this ordering, monomials from <span class="SimpleMath">A</span> are compared using their respective commutative analogues.</p>

<p><a id="X7B3183F67AEF3C67" name="X7B3183F67AEF3C67"></a></p>

<h5>5.5-5 NCMonomialWeightOrdering</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; NCMonomialWeightOrdering</code>( <var class="Arg"><algebra>47 53 56,57,58 59  ,
<p>Given a free algebra <span class="SimpleMath">A</span>, an ordered (possibly partial) ordered <code class="code"><list></code> of[ ,2 3,4, 5,6,7 ,9 ,11,13 19 ,21 ,26 27, 32, 37 41,

<p><a id="X8374E7B780EEE873" name="X8374E7B780EEE873"></a></p>

<h4>5.6 <span class="Heading">Orderings - Externals</span></h4>

<p>All user-level interface routines in the descriptions following allow for the comparisonof not only monomials from a given algebra with respect to a given ordering, but also compare general elements from an algebra by comparing their leading terms (again, with respect to the given ordering). These routines are located in the files <code class="code">ncinterface.gd</code> and <code class="code">ncinterface.gi</code>.</p>

<[ ,2 ,4 5, 6,7 8,9,11 13,19, 20,22,25,33, ,38,43 

<h5>5.6-1 NCLessThanByOrdering</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; NCLessThanByOrdering</code>( <var class="Arg"><NoncommutativeMonomialOrdering></var>, <var class="Arg"><a></var>, <var class="Arg"><b></var> )</td><td class="tdright">( operation )</td></tr></table></div>
<p>Given a <code class="code"><NoncommutativeMonomialOrdering></code> on an algebra <span class="SimpleMath">A</span> and <[1,2 ,4 5 ,7,8, 9  11 ,19,21,22,25 ,,35,36,38,

<p><a id  49 ,52, 56,59 63  ,

<h5>5.6-2 NCGreaterThanByOrdering</h5>

<div class="func"><table class="func" width="100%" 1,2,3,4,5,, 8, ,10,11,13,19,21,25, 33,35,36,38 ,
<p>Given a <code class="  50, 51 52,56, 58,62 63]

<p><a id="X817144A57BF6865A" name="X817144A57BF6865A"></a></p>

<h5>5.6-3 NCEquivalentByOrdering</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; NCEquivalentByOrdering</code>( <var class="Arg"><NoncommutativeMonomialOrdering></var>, <var class="Arg"><a><  46 50 ,57,58   ,
<p>Given a <code class="code"><[ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13,2426,31,33  38 ,

<p>Some examples of these methods in use:</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">A := FreeAssociativeAlgebraWithOne(Rationals,"x","y","z");</span>
java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 58
<span class="GAPprompt">gap></span> <span class="GAPinput">x := A.x;; y := A.y;; z := A.z;; id := One(A);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">w1 := x*x*y;; w2 := x*y*x;; w3 := z*x;;</span>

<span class="GAPprompt">gap></span> <span class="GAPinput">ml := NCMonomialLeftLengthLexOrdering(A);</span>
NCMonomialLeftLengthLexicographicOrdering([ (1)*x, (1)*y, (1)*z ])

<span class="GAPprompt">gap></span> <span class="GAPinput">ml2 := NCMonomialLengthOrdering(A);</span>
NCMonomialLengthOrdering[ (1,1*z]java.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49

<span class"GAPprompt">gt<span< ="ml7 : NCMonomialWeightOrdering(A,1,,][,,]<
NCMonomialWeightOrdering([ (1)*x, (1)*y, (1)*z ])

"gap&;/> < class=GAPinput> = NCMonomialWeightOrdering(A,[,3,1,1,,2];/span>
NCMonomialWeightOrdering([ (1)*y, (1)*z, (1)*x ])

<span class="GAPprompt">gap></span> <span class="GAPinput">#  Left length-lex ordering, x<y<z:</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">NCEquivalentByOrdering(ml,w1,w2);</span>
false
<span class="GAPprompt">gap></span> <span class="GAPinput">#  Length ordering:</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">NCEquivalentByOrdering(ml2,w1,w2);</span>
true
<span class="GAPprompt">gap></span> <span class="GAPinput">NCEquivalentByOrdering(ml2,w3,w2);</span>
false
<span class="GAPprompt">gap></span> <span class="GAPinput"># Weight ordering ( z=2, x=y=1 ):</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">NCEquivalentByOrdering(ml7,w1,w2);</span>
true
<span class="GAPprompt">gap></span> <span class="GAPinput">NCEquivalentByOrdering(ml7,w3,w2);</span>
java.lang.StringIndexOutOfBoundsException: Range [20, 21) out of bounds for length 4
<span class="GAPprompt">gap></span> <span class="GAPinput"># Weight ordering ( z=2, x=y=1 ), different lex:</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">NCEquivalentByOrdering(ml8,w1,w2);</span>
true
<span class="GAPprompt">gap></span> <span class="GAPinput">NCEquivalentByOrdering(ml8,w3,w2);  50 ,57, 58, 59,60, 64 ]
true
</pre></div[1 2, 3,4,5 6 ,8 9,10 11,13,20 23, 32,34 35,39 40, ,java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77

<p><a id="X86A2533780F2BC8C" name="X86A2533780F2BC8C"></a></p>

<h5>5.6-4 NCSortNP</h5>

<div class="func"><table class="func" width="100%"> 1,,3,4, 5,6, 7 ,9 10,11 13,23,25 26,27, 30,31,32,34,37 
<p>Given a <code class="code"><list></code> of NP `list' representations for monomials from a java.lang.StringIndexOutOfBoundsException: Index 111 out of bounds for length 31

<p><a id="X8528D2528613E9A2" name="X8528D2528613E9A2"></a></p>

<h5>5.6-5 <span class="Heading">Flexibility vs. Efficiency</span></h5>

<p>We recall that <code class="code">InstallNoncommutativeMonomialOrdering</code> completes a list of generators if only a partial one is provided. An example will provide clarity here. It is given in terms of length-lex, but the generator list completion functionality is identical for any <strong class="pkg">NMO</strong> ordering. Note: If at all possible, users are encouraged to use the default ordering on generators as it is more efficient47 50,55,57,58,59,61]


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">A := FreeAssociativeAlgebraWithOne(Rationals,"a","b","c","d");</span>
<algebra-with-one over Rationals, with 4 generators>
<span class="GAPprompt">gap></span> <span class="GAPinput">ml2 := NCMonomialLeftLengthLexOrdering(A,[3,1]);</span>
NCMonomialLeftLengthLexicographicOrdering([ (1)*c, (1)*a, (1)*b, (1)*d ])
<span class="GAPprompt">gap></span> <span class="GAPinput">LexicographicTable(ml2);</span>
[ (1)*c, (1)*a, (1)*  48,50 52 53,56,58,62]
</pre></div>

<p><a id="X79B90CCE7A05DEEB" name="X79B90CCE7A05DEEB"></a></p>

<h4>5.7 <span class="Heading">Utility Routines</span></h4>

<p><a id="X7B758C747AD2344B" name="X7B758C747AD2344B"></a></p>

<h5>5.7-1 <span class="Heading">GBNP Patching Routines</span></h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; java.lang.StringIndexOutOfBoundsException: Index 109 out of bounds for length 77
<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&#an style='color: green'>8227; UnpatchGBNP</code>(  )</td><td class="tdright">( function )</td></tr></table></div>
<p>Let <code class="code"><NoncommutativeMonomialOrdering></code> be a monomial ordering (on an algebra <span class="SimpleMath">A</span>). <code class="code">PatchGBNP</code> overwrites the <strong


<div class= 48,50,56, 57,58,61,64]
<span class="GAPprompt">gap></span> <span class="GAPinput">A := FreeAssociativeAlgebraWithOne(Rationals,"x","y","z");</span>
&[ 1 2, 4,5,6,7 8,9,10, 11, 13,24,,32, 34 ,40 46, 47,,java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
<span class="GAPprompt">gap  53 56,58, 59, 60, 62 64 ],
NCMonomialLeftLexicographicOrdering([ (1)*z, (1)*y, (1)*x ])
<gt;<span>> <span class="GAPinput"PatchGBNP(l;/span
LtNP patched.
GtNP patched.
<span class="GAPprompt">gap></span> <span class="GAPinput">UnpatchGBNP();</java.lang.StringIndexOutOfBoundsException: Index 80 out of bounds for length 31
LtNP restored.
GtNP restored.
</pre></div>


<div class="chlinkprevnextbot"> <a href="chap0.html">[Top of Book]</a>   <a href="chap0.html#contents">[Contents]</a>    <a href="chap4.html">[Previous Chapter]</a>    <a href="chapA.html">[Next Chapter]</a>   </div>


<div class="chlinkbot"><span class="chlink1">Goto Chapter: </span><a href="chap0.html[1,2 3 4 5 ,7,8 9,10,11 , 25 26,29,30,31 32, 33,40 47,

<hr />
<p class="foot">generated by <a href="https://www.math.rwth-aachen.de/~Frank.Luebeck/GAPDoc">GAPDoc2HTML</a></p>
</body>
</html>

Messung
CHZG
8210010094

¤ Dauer der Verarbeitung: 0.28 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover


Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Open Source Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Statistik
#Sources=1104857
#Domains=438786