Sophie

Sophie

distrib > Mandriva > 2010.0 > i586 > media > contrib-release > by-pkgid > 5e1854624d3bc613bdd0dd13d1ef9ac7 > files > 3045

gap-system-4.4.12-5mdv2010.0.i586.rpm

<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
                      "DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>GAP (SgpViz) - Chapter 5: User friendly ways to give semigroups and automata</title>
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
<meta name="generator" content="GAPDoc2HTML" />
<link rel="stylesheet" type="text/css" href="manual.css" />
</head>
<body>


<div class="pcenter"><table class="chlink"><tr><td class="chlink1">Goto Chapter: </td><td><a href="chap0.html">Top</a></td><td><a href="chap1.html">1</a></td><td><a href="chap2.html">2</a></td><td><a href="chap3.html">3</a></td><td><a href="chap4.html">4</a></td><td><a href="chap5.html">5</a></td><td><a href="chapBib.html">Bib</a></td><td><a href="chapInd.html">Ind</a></td></tr></table><br /></div>
<p><a id="s0ss0" name="s0ss0"></a></p>

<h3>5. User friendly ways to give semigroups and automata</h3>

<p>This chapter describes two Tcl/Tk graphical interfaces that can be used to define and edit semigroups and automata.</p>

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

<h4>5.1  
Finite automata 
      </h4>

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

<h5>5.1-1 XAutomaton</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&gt; XAutomaton</code>( <var>[A]</var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>The function <code class="code"> Xautomaton </code> without arguments opens a new window where an automaton may be specified. A finite automaton (which may then be edited) may be given as argument.</p>


<table class="example">
<tr><td><pre>

gap&gt; XAutomaton();
      
</pre></td></tr></table>

<p>It opens a window like the following:</p>

<p><br><center><img src="images/xaut.gif"></center><br> <code class="code"> Var </code> is the <strong class="pkg">GAP</strong> name of the automaton, <code class="code"> States </code> is the number of states, <code class="code"> Alphabet </code> represents the alphabet and may be given through a positive integer (in this case the alphabet is understood to be <code class="code"> a,b,c,... </code>) or through a string whose symbols, in order, being the letters of the alphabet. The numbers corresponding to the initial and accepting states are placed in the respective boxes. The automaton may be specified to be deterministic, non deterministic or with epsilon transitions. After pressing the <strong class="button"> transition matrix </strong> button the window gets larger and the transition matrix of the automaton may be given. <br><center><img src="images/xAUT.gif"></center><br> A non deterministic automaton may be given as follows: <br><center><img src="images/xndAUT.gif"></center><br></p>

<p>By pressing the button <strong class="button"> Ok </strong> the <strong class="pkg">GAP</strong> shell aquires the aspect shown in the following picture and the automaton <code class="code"> ndAUT </code> may be used to do computations. Some computations such as getting a rational expression representing the language of the automaton, the (complete) minimal automaton representing the same language or the transition semigroup of the automaton, may be done directly after pressing the <strong class="button"> Functions</strong> button. <br><center><img src="images/xndAUTok.gif"></center><br></p>

<p>By pressing the button <strong class="button"> View </strong> an image representing the automaton is displayed in a new window. <br><center><img src="images/ndAutImage.gif"></center><br> An automaton with epsilon transitions may be given as follows shown in the following picture. The last letter of the alphabet is always considered to be the epsilon. In the images it is represented by @. <br><center><img src="images/EpsTrAut.gif"></center><br></p>

<p>A new window with an image representing the automaton may be obtained by pressing the button <strong class="button"> View </strong>. <br><center><img src="images/EpsTrAutImage.gif"></center><br></p>

<p>In the next example it is given an argument to the function <code class="code">XAutomaton</code>.</p>


<table class="example">
<tr><td><pre>

gap&gt; A := RandomAutomaton("det",2,2);
&lt; deterministic automaton on 2 letters with 2 states &gt;
gap&gt; XAutomaton(A);
      
</pre></td></tr></table>

<p>It opens a window like the following:</p>

<p><br><center><img src="images/xautgiven.gif"></center><br></p>

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

<h4>5.2  Finite semigroups </h4>

<p>The most common ways to give a semigroup to are through generators and relations, a set of (partial) transformations as generating set and as syntactic semigroups of automata or rational languages.</p>

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

<h5>5.2-1 XSemigroup</h5>

<div class="func"><table class="func" width="100%"><tr><td class="tdleft"><code class="func">&gt; XSemigroup</code>( <var>[S]</var> )</td><td class="tdright">( function )</td></tr></table></div>
<p>The function <code class="code"> XSemigroup </code> without arguments opens a new window where a semigroup (or monoid) may be specified. A finite semigroup (which may then be edited) may be given as argument.</p>


<table class="example">
<tr><td><pre>

gap&gt; XSemigroup();
      
</pre></td></tr></table>

<p>It opens a window like the following: <br><center><img src="images/xsgp.gif"></center><br> where one may choose how to give the semigroup.</p>

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

<h5>5.2-2  
Semigroups given through generators and relations 
      </h5>

<p>In the window opened by <code class="code">XSemigroup</code>, by pressing the button <strong class="button">Proceed</strong> the window should enlarge and have the following aspect. (If the window does not enlarge automatically, use the mouse to do it.)</p>

<p><br><center><img src="images/GenRelators2.gif"></center><br> <code class="code"> GAP variable </code> is the <strong class="pkg">GAP</strong> name of the semigroup. One has then to specify the number of generators, the number of relations (which does not to be exact) and whether one wants to produce a monoid or a semigroup. <br><center><img src="images/GenRelators3.gif"></center><br> <br><center><img src="images/xb21.gif"></center><br> Pressing the <strong class="button">Done</strong> button would output the following to the shell where <strong class="pkg">GAP</strong> is running: <br><center><img src="images/gapb21.gif"></center><br> By pressing the menu button <strong class="button">Functions</strong> and selecting "Draw Schutzenberger Graphs" would pop up the following window: <br><center><img src="images/ShuzenbergerGraphb21.gif"></center><br> By pressing the menu button <strong class="button">Functions</strong> and selecting "Draw Cayley Graph" would pop up the following window: <br><center><img src="images/CayleyGraphb21.gif"></center><br> By pressing the menu button <strong class="button">Functions</strong> and selecting "Draw D-Classes" would pop up the following window: <br><center><img src="images/DClassesb21.gif"></center><br></p>

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

<h5>5.2-3  
Semigroups given by partial transformations
      </h5>

<p><code class="code">XSemigroup(poi3);</code> would pop up the following window, where everything should be clear: <br><center><img src="images/Xsemigroup1.png"></center><br></p>

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

<h5>5.2-4  
Syntatic semigroups
      </h5>

<p><code class="code">XSemigroup();</code> would pop up the following window, where we would select "Syntatic semigroup", press the <strong class="button">Proceed</strong> button and then choose either to give a "Rational expression" or an "Automaton" by pressing one of those buttons: <br><center><img src="images/Xsemigroup2.png"></center><br></p>


<div class="pcenter">
<table class="chlink"><tr><td><a href="chap0.html">Top of Book</a></td><td><a href="chap4.html">Previous Chapter</a></td><td><a href="chapBib.html">Next Chapter</a></td></tr></table>
<br />


<div class="pcenter"><table class="chlink"><tr><td class="chlink1">Goto Chapter: </td><td><a href="chap0.html">Top</a></td><td><a href="chap1.html">1</a></td><td><a href="chap2.html">2</a></td><td><a href="chap3.html">3</a></td><td><a href="chap4.html">4</a></td><td><a href="chap5.html">5</a></td><td><a href="chapBib.html">Bib</a></td><td><a href="chapInd.html">Ind</a></td></tr></table><br /></div>

</div>

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