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


Quelle  chap6.html   Sprache: unbekannt

 
<?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.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>GAP (IntPic) - Chapter 6: 
    Usage of IntPic in connection with the numericalsgps package
  </title>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<meta name="generator" content="GAPDoc2HTML" />
<link rel="stylesheet" type="text/css" href="manual.css" />
<script src="manual.js" type="text/javascript"></script>
<script type="text/javascript">overwriteStyle();</script>
</head>
<body class="chap6"  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>  <a href="chap3.html">3</a>  <a href="chap4.html">4</a>  <a href="chap5.html">5</a>  <a href="chap6.html">6</a>  <a href="chapBib.html">Bib</a>  <a href="chapInd.html">Ind</a>  </div>

<div class="chlinkprevnexttop"> <a href="chap0.html">[Top of Book]</a>   <a href="chap0.html#contents">[Contents]</a>    <a href="chap5.html">[Previous Chapter]</a>    <a href="chapBib.html">[Next Chapter]</a>   </div>

<p id="mathjaxlink" class="pcenter"><a href="chap6_mj.html">[MathJax on]</a></p>
<p><a id="X7E08032186064BAD" name="X7E08032186064BAD"></a></p>
<div class="ChapSects"><a href="chap6.html#X7E08032186064BAD">6 <span class="Heading">
    Usage of <strong class="pkg">IntPic</strong> in connection with the <strong class="pkg">numericalsgps</strong> package
  </span></a>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap6.html#X7B3048667C19F30D">6.1 <span class="Heading">Tikz code for drawing numerical semigroups</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap6.html#X7B3048667C19F30D">6.1-1 <span class="Heading">Tikz code for drawing numerical semigroups</span></a>
</span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap6.html#X84B40345825B0B0E">6.1-2 <span class="Heading">Drawing a numerical semigroup</span></a>
</span>
</div></div>
<div class="ContSect"><span class="tocline"><span class="nocss"> </span><a href="chap6.html#X7BF14BF082E52625">6.2 <span class="Heading">Drawing sets of numerical semigroups</span></a>
</span>
<div class="ContSSBlock">
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap6.html#X78B4B1D0810D457B">6.2-1 <span class="Heading">Set of numerical semigroups</span></a>
</span>
<span class="ContSS"><br /><span class="nocss">  </span><a href="chap6.html#X7D735F977FDCA8A0">6.2-2 <span class="Heading">Draw a set of numerical semigroups</span></a>
</span>
</div></div>
</div>

<h3>6 <span class="Heading">
    Usage of <strong class="pkg">IntPic</strong> in connection with the <strong class="pkg">numericalsgps</strong> package
  </span></h3>

<p>This chapter describes functions to be used in connection with the <strong class="pkg">numericalsgps</strong> package. We found it particularly useful to gain intuition that led to the obtention of the results stated in <a href="chapBib.html#biBDGSRP15">[DGR16]</a>.</p>

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

<h4>6.1 <span class="Heading">Tikz code for drawing numerical semigroups</span></h4>

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

<h5>6.1-1 <span class="Heading">Tikz code for drawing numerical semigroups</span></h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ TikzCodeForNumericalSemigroup</code>( <var class="Arg">arg</var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>The arguments (at most 4) are:</p>

<ol>
<li><p>a numerical semigroup</p>

</li>
<li><p>(optional) a list whose elements are either</p>


<ul>
<li><p>lists of integers <em>or</em></p>

</li>
<li><p>one of the strings "pseudo_frobenius""min_generators""frobenius_number""conductor""special_gaps""fundamental_gaps""small_elements" (the default: used when no list is present) <em>or</em></p>

</li>
<li><p>the string "ns_table" (the drawing obtained is a table whose top row corresponds to the threshold interval; as a side effect, if it is turned to "true", negative integers are not printed); alternatively, the option can be given in the usual way: <code class="code">rec(ns_table := true)</code></p>

</li>
</ul>
</li>
<li><p>a record whose fields are</p>


<ul>
<li><p>func -- a function name</p>

</li>
<li><p>(optional) argument -- an argument (that may be a function name also)</p>

</li>
</ul>
</li>
<li><p>(optional) a positive integer -- if it is bigger than the conductor or biggest minimal generator, it indicates the number of cells - 1 to be drawn and these are drawn in a single line; otherwise, it indicates the maximum number of cells per line.</p>

</li>
</ol>

<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">ns := NumericalSemigroup(5,7);;                                               </span>
<span class="GAPprompt">gap></span> <span class="GAPinput">tkz := TikzCodeForNumericalSemigroup(ns,["ns_table"],rec(negatives:=false));</span>
#I  In order to highlight some element, please use a list with one or more of the 
options given as strings: pseudo_frobenius, min_generators, frobenius_number, 
conductor, special_gaps, fundamental_gaps, small_elements

"%tikz\n\\begin{tikzpicture}[every node/.style={draw,scale=1pt,\nminimum width\
=20pt,inner sep=3pt,\nline width=0pt,draw=black}]\n\\matrix[row sep=2pt,column\
 sep=2pt]\n{\\node[]{24};&\n\\node[]{25};&\n\\node[]{26};&\n\\node[]{27};&\n\\\
node[]{28};\\\\\n\\node[]{19};&\n\\node[]{20};&\n\\node[]{21};&\n\\node[]{22};\
&\n\\node[]{23};\\\\\n\\node[]{14};&\n\\node[]{15};&\n\\node[]{16};&\n\\node[]\
{17};&\n\\node[]{18};\\\\\n\\node[]{9};&\n\\node[]{10};&\n\\node[]{11};&\n\\no\
de[]{12};&\n\\node[]{13};\\\\\n\\node[]{4};&\n\\node[]{5};&\n\\node[]{6};&\n\\\
node[]{7};&\n\\node[]{8};\\\\\n&\n\\node[]{0};&\n\\node[]{1};&\n\\node[]{2};&\
\n\\node[]{3};\\\\\n};\n\\end{tikzpicture}\n"
</pre></div>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">tkz := TikzCodeForNumericalSemigroup(ns,["small_elements"],</span>
<span class="GAPprompt">></span> <span class="GAPinput">rec(ns_table := true,negatives:=false));;</span></pre></div>

<p><br><center><img src="../images/ip_5-7-white.jpg"></center><br> <br><center><img src="../images/ip_5-7-smalls.jpg"></center><br></p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">ns1 := NumericalSemigroup(3,5);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">TikzCodeForNumericalSemigroup(ns1,[[3,4],"pseudo_frobenius"],20);</span>
"%tikz\n\\begin{tikzpicture}[every node/.style={draw,scale=1pt,\nminimum width\
=20pt,inner sep=3pt,\nline width=0pt,draw=black}]\n\\matrix[row sep=2pt,column\
 sep=2pt]\n{\\node[]{0};&\n\\node[]{1};&\n\\node[]{2};&\n\\node[fill=red]{3};&\
\n\\node[fill=red]{4};&\n\\node[]{5};&\n\\node[]{6};&\n\\node[fill=green]{7};&\
\n\\node[]{8};&\n\\node[]{9};&\n\\node[]{10};&\n\\node[]{11};&\n\\node[]{12};&\
\n\\node[]{13};&\n\\node[]{14};&\n\\node[]{15};&\n\\node[]{16};&\n\\node[]{17}\
;&\n\\node[]{18};&\n\\node[]{19};&\n\\node[]{20};\\\\\n};\n\\end{tikzpicture}\
\n"
</pre></div>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">IP_Splash(TikzCodeForNumericalSemigroup(NumericalSemigroup(7,13,19,23),</span>
<span class="GAPprompt">></span> <span class="GAPinput">[[3,4],"small_elements","fundamental_gaps"],20),rec(viewer := "evince"));    </span>
</pre></div>

<p><br><center><img src="../images/ip_splash_tikz_NS.jpg"></center><br></p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">ns := NumericalSemigroup(7,11,38,41);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">highlights := ["conductor""min_generators""small_elements"];;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">options := rec(ns_table:=true,colors:=["blue""red!70""-red""black!40"]);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">tkz := TikzCodeForNumericalSemigroup(ns,highlights,options);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">IP_Splash(tkz);</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">tkz := TikzCodeForNumericalSemigroup(ns,highlights,rec(ns_table:=true));;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">IP_Splash(tkz);</span>
</pre></div>

<p><br><center><img src="../images/ip_splash_tikz_NS_table.jpg"></center><br> <br><center><img src="../images/ip_splash_tikz_NS_table_default.jpg"></center><br></p>

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

<h5>6.1-2 <span class="Heading">Drawing a numerical semigroup</span></h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ DrawNumericalSemigroup</code>( <var class="Arg">ns</var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>This function abbreviates the production of tikz code to display the numerical semigroup <code class="code">ns</code> using some predefined options and elements to highlight (based on the ones of the above example). It also displays the image produced. Note that the production and displaying of the image depends on the function IP_Splash (which can be slow and depends on an appropriate configuration of the system). The output is the tikz code produced.</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">m := 31;;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">small_gens := [m,m+1,m+2,m+3];;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">other_gens := List([1..Int(m/7)], k -> 7*k+m);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">ns := NumericalSemigroup(Union(small_gens,other_gens));;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">DrawNumericalSemigroup(ns);;</span>
 </pre></div>

<p><br><center><img src="../images/drawNS-small-depth.jpg"></center><br></p>

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

<h4>6.2 <span class="Heading">Drawing sets of numerical semigroups</span></h4>

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

<h5>6.2-1 <span class="Heading">Set of numerical semigroups</span></h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ SetOfNumericalSemigroups</code>( <var class="Arg">arg</var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>This function is used to produce lists of numerical semigroups with a fixed genus or Frobenius number. They are filtered and ordered according to some criteria.</p>

<p>The argument is a record of options:</p>

<ol>
<li><p>set -- a record whose possible fields are genus or frobenius</p>

</li>
<li><p>(optional) filter -- a record whose possible fields are genus, type and/or multiplicity and/or frobenius and/or embedding_dimension</p>

</li>
<li><p>(optional) order -- ("genus""type""multiplicity""frobenius""embedding_dimension")</p>

</li>
</ol>

<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">ls := SetOfNumericalSemigroups(rec(set:=rec(genus:=6),filter:=rec(type:= 2),</span>
order:="multiplicity"));;
<span class="GAPprompt">gap></span> <span class="GAPinput">List(ls,MinimalGenerators);</span>
[ [ 3, 8, 13 ], [ 3, 10, 11 ], [ 4, 7, 9 ], [ 5, 6, 7 ], [ 5, 6, 8 ], 
  [ 6, 7, 8, 9, 11 ] ]
<span class="GAPprompt">gap></span> <span class="GAPinput">ls := SetOfNumericalSemigroups(rec(set:=rec(genus:=6),filter:=rec(type:= 2),</span>
order:="frobenius"));;
<span class="GAPprompt">gap></span> <span class="GAPinput">List(ls,MinimalGenerators);</span>
[ [ 3, 10, 11 ], [ 5, 6, 7 ], [ 5, 6, 8 ], [ 3, 8, 13 ], [ 4, 7, 9 ], 
  [ 6, 7, 8, 9, 11 ] ]
</pre></div>

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

<h5>6.2-2 <span class="Heading">Draw a set of numerical semigroups</span></h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">‣ DrawSetOfNumericalSemigroups</code>( <var class="Arg">arg</var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>Produces a single image from the images of a set of numerical semigroups.</p>

<p>The arguments (at most 3) are:</p>

<ol>
<li><p>a list of numerical semigroups (given as a list or each given as argument)</p>

</li>
<li><p>(optional) an integer that (when present) determines the length of each line</p>

</li>
<li><p>(optional) a record whose fields are</p>


<ul>
<li><p>(optional) splash -- which (when present) consists of a record of options for the Viz Splash function</p>

</li>
<li><p>(optional) highlights: a list to be passed to the function that produces the tikz code for each individual semigroup (whose aim is to say which elements are to be highlighted)</p>

</li>
</ul>
</li>
</ol>

<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">ns1 := NumericalSemigroup(3,5);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">ns2 := NumericalSemigroup(5,7,11);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">DrawSetOfNumericalSemigroups(ns1,rec(splash:=                          </span>
<span class="GAPprompt">></span> <span class="GAPinput">rec(viewer := "evince"),highlights := </span>
<span class="GAPprompt">></span> <span class="GAPinput">["pseudo_frobenius","small_elements","min_generators"]));</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">DrawSetOfNumericalSemigroups(ns1,ns2,rec(splash:= </span>
<span class="GAPprompt">></span> <span class="GAPinput">rec(viewer := "evince"),highlights := </span>
<span class="GAPprompt">></span> <span class="GAPinput">["pseudo_frobenius","small_elements","min_generators"]));</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">DrawSetOfNumericalSemigroups([ns1,ns2],rec(splash:=      </span>
<span class="GAPprompt">></span> <span class="GAPinput">rec(viewer := "evince"),highlights :=                    </span>
<span class="GAPprompt">></span> <span class="GAPinput">["small_elements","min_generators"]));                   </span>
</pre></div>

<p><br><center><img src="../images/set_3_5.jpg"></center><br> <br><center><img src="../images/set_3_5_and_5_7_11.jpg"></center><br> <br><center><img src="../images/set_3_5_and_5_7_11_v2.jpg"></center><br></p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">frob := 15;;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">tipo := 2;;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">set := SetOfNumericalSemigroups(rec(set := rec(frobenius := frob),</span>
<span class="GAPprompt">></span> <span class="GAPinput">filter := rec(type:= tipo),order := "embedding_dimension"));;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">DrawSetOfNumericalSemigroups(set,rec(splash:= rec(viewer := "evince"),</span>
<span class="GAPprompt">></span> <span class="GAPinput">highlights := ["small_elements","min_generators",</span>
<span class="GAPprompt">></span> <span class="GAPinput">rec(func:= "ForcedIntegersForPseudoFrobenius", </span>
<span class="GAPprompt">></span> <span class="GAPinput">argument := "PseudoFrobeniusOfNumericalSemigroup")]));</span>
</pre></div>

<p><br><center><img src="../images/draw_set_pseudo.jpg"></center><br> The following example helps in the understanding of the colors present in the first line of previous figure.</p>


<div class="example"><pre>
<span class="GAPprompt">gap></span> <span class="GAPinput">ns := NumericalSemigroup(4,9,19);;</span>
<span class="GAPprompt">gap></span> <span class="GAPinput">SmallElements(ns);</span>
[ 0, 4, 8, 9, 12, 13, 16 ]
<span class="GAPprompt">gap></span> <span class="GAPinput">MinimalGeneratingSystem(ns);</span>
[ 4, 9, 19 ]
<span class="GAPprompt">gap></span> <span class="GAPinput">ForcedIntegersForPseudoFrobenius(PseudoFrobeniusOfNumericalSemigroup(ns));</span>
[ [ 1, 2, 3, 5, 6, 7, 14, 15 ], [ 0, 8, 9, 12, 13, 16 ] ]
</pre></div>


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


<div class="chlinkbot"><span class="chlink1">Goto Chapter: </span><a href="chap0.html">Top</a>  <a href="chap1.html">1</a>  <a href="chap2.html">2</a>  <a href="chap3.html">3</a>  <a href="chap4.html">4</a>  <a href="chap5.html">5</a>  <a href="chap6.html">6</a>  <a href="chapBib.html">Bib</a>  <a href="chapInd.html">Ind</a>  </div>

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

100%


[ 0.14Quellennavigators  Projekt   ]

                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge