<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>FAUST compiler: aterm.hh Source File</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.6.3 --> <div class="navigation" id="top"> <div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> </ul> </div> <div class="tabs"> <ul> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>File Members</span></a></li> </ul> </div> <h1>aterm.hh</h1><a href="aterm_8hh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="preprocessor">#ifndef __ATERM__</span> <a name="l00002"></a>00002 <span class="preprocessor"></span><span class="preprocessor">#define __ATERM__</span> <a name="l00003"></a>00003 <span class="preprocessor"></span> <a name="l00004"></a>00004 <span class="preprocessor">#include <stdio.h></span> <a name="l00005"></a>00005 <span class="preprocessor">#include <assert.h></span> <a name="l00006"></a>00006 <span class="preprocessor">#include "<a class="code" href="tlib_8hh.html">tlib.hh</a>"</span> <a name="l00007"></a>00007 <span class="preprocessor">#include "<a class="code" href="signals_8hh.html">signals.hh</a>"</span> <a name="l00008"></a>00008 <span class="preprocessor">#include "<a class="code" href="sigprint_8hh.html">sigprint.hh</a>"</span> <a name="l00009"></a>00009 <span class="preprocessor">#include "<a class="code" href="simplify_8hh.html">simplify.hh</a>"</span> <a name="l00010"></a>00010 <span class="preprocessor">#include "<a class="code" href="normalize_8hh.html">normalize.hh</a>"</span> <a name="l00011"></a>00011 <span class="preprocessor">#include "<a class="code" href="sigorderrules_8hh.html">sigorderrules.hh</a>"</span> <a name="l00012"></a>00012 <span class="preprocessor">#include <map></span> <a name="l00013"></a>00013 <span class="preprocessor">#include <list></span> <a name="l00014"></a>00014 <a name="l00015"></a>00015 <span class="preprocessor">#include "<a class="code" href="mterm_8hh.html">mterm.hh</a>"</span> <a name="l00016"></a>00016 <a name="l00017"></a>00017 <span class="keyword">using namespace </span>std; <a name="l00018"></a>00018 <a name="l00023"></a><a class="code" href="classaterm.html">00023</a> <span class="keyword">class </span><a class="code" href="classaterm.html" title="Implements a additive term, a set of mterms added together m1 + m2 + m3 + .">aterm</a> <a name="l00024"></a>00024 { <a name="l00025"></a>00025 <a name="l00026"></a><a class="code" href="classaterm.html#ae8b30f7dacfc6e2fab5541e6e5c53245">00026</a> map<Tree,mterm> <a class="code" href="classaterm.html#ae8b30f7dacfc6e2fab5541e6e5c53245" title="mapping between signatures and corresponding mterms">fSig2MTerms</a>; <a name="l00027"></a>00027 <a name="l00028"></a>00028 <span class="keyword">public</span>: <a name="l00029"></a>00029 <a class="code" href="classaterm.html#a42df2a5723bf522cc9b06275d55bcd26" title="create an empty aterm (equivalent to 0)">aterm</a> (); <a name="l00030"></a>00030 <a class="code" href="classaterm.html#a42df2a5723bf522cc9b06275d55bcd26" title="create an empty aterm (equivalent to 0)">aterm</a> (<a class="code" href="classCTree.html" title="A CTree = (Node x [CTree]) is a Node associated with a list of subtrees called branches...">Tree</a> t); <a name="l00031"></a>00031 <a class="code" href="classaterm.html#a42df2a5723bf522cc9b06275d55bcd26" title="create an empty aterm (equivalent to 0)">aterm</a> (<span class="keyword">const</span> <a class="code" href="classaterm.html" title="Implements a additive term, a set of mterms added together m1 + m2 + m3 + .">aterm</a>& a); <a name="l00032"></a>00032 <a name="l00033"></a>00033 <span class="keyword">const</span> <a class="code" href="classaterm.html" title="Implements a additive term, a set of mterms added together m1 + m2 + m3 + .">aterm</a>& <a class="code" href="classaterm.html#a1651df562ad3e2544ecad194bccd19f0" title="add in place an additive expression tree">operator += </a>(<a class="code" href="classCTree.html" title="A CTree = (Node x [CTree]) is a Node associated with a list of subtrees called branches...">Tree</a> t); <a name="l00034"></a>00034 <span class="keyword">const</span> <a class="code" href="classaterm.html" title="Implements a additive term, a set of mterms added together m1 + m2 + m3 + .">aterm</a>& <a class="code" href="classaterm.html#a1544a0e91ff7c3c17782d1161925b11c" title="add in place an additive expression tree">operator -= </a>(<a class="code" href="classCTree.html" title="A CTree = (Node x [CTree]) is a Node associated with a list of subtrees called branches...">Tree</a> t); <a name="l00035"></a>00035 <a name="l00036"></a>00036 <span class="keyword">const</span> <a class="code" href="classaterm.html" title="Implements a additive term, a set of mterms added together m1 + m2 + m3 + .">aterm</a>& <a class="code" href="classaterm.html#a1651df562ad3e2544ecad194bccd19f0" title="add in place an additive expression tree">operator += </a>(<span class="keyword">const</span> <a class="code" href="classmterm.html" title="Implements a multiplicative term, a term of type k*x^n*y^m*.">mterm</a>& m); <a name="l00037"></a>00037 <span class="keyword">const</span> <a class="code" href="classaterm.html" title="Implements a additive term, a set of mterms added together m1 + m2 + m3 + .">aterm</a>& <a class="code" href="classaterm.html#a1544a0e91ff7c3c17782d1161925b11c" title="add in place an additive expression tree">operator -= </a>(<span class="keyword">const</span> <a class="code" href="classmterm.html" title="Implements a multiplicative term, a term of type k*x^n*y^m*.">mterm</a>& m); <a name="l00038"></a>00038 <a class="code" href="classCTree.html" title="A CTree = (Node x [CTree]) is a Node associated with a list of subtrees called branches...">Tree</a> <a class="code" href="classaterm.html#a793687477fd756925c4db2914d8a5820" title="return the corresponding normalized expression tree">normalizedTree</a>() <span class="keyword">const</span>; <a name="l00039"></a>00039 <a name="l00040"></a>00040 ostream& <a class="code" href="classaterm.html#a8cb1049e8b593acb1b451dd7db86a2cc" title="print a aterm m1 + m2 + m3 +...">print</a>(ostream& dst) <span class="keyword">const</span>; <a name="l00041"></a>00041 <a class="code" href="classmterm.html" title="Implements a multiplicative term, a term of type k*x^n*y^m*.">mterm</a> <a class="code" href="classaterm.html#a52130183f30e9b4e998532ca36536dc7" title="return the greatest divisor of any two mterms">greatestDivisor</a>() <span class="keyword">const</span>; <a name="l00042"></a>00042 <a class="code" href="classaterm.html" title="Implements a additive term, a set of mterms added together m1 + m2 + m3 + .">aterm</a> <a class="code" href="classaterm.html#ae6906479134fa7fac1486aa8f1fccd31" title="reorganize the aterm by factorizing d">factorize</a>(<span class="keyword">const</span> <a class="code" href="classmterm.html" title="Implements a multiplicative term, a term of type k*x^n*y^m*.">mterm</a>& d); <a name="l00043"></a>00043 }; <a name="l00044"></a>00044 <a name="l00045"></a><a class="code" href="aterm_8hh.html#ae8c228eaf7baa3157b3b47dda39d8750">00045</a> <span class="keyword">inline</span> ostream& <a class="code" href="ppbox_8hh.html#a23b1718100bac6cb41d43dd01f226eef">operator << </a>(ostream& s, <span class="keyword">const</span> <a class="code" href="classaterm.html" title="Implements a additive term, a set of mterms added together m1 + m2 + m3 + .">aterm</a>& a) { <span class="keywordflow">return</span> a.<a class="code" href="classaterm.html#a8cb1049e8b593acb1b451dd7db86a2cc" title="print a aterm m1 + m2 + m3 +...">print</a>(s); } <a name="l00046"></a>00046 <a name="l00047"></a>00047 <a name="l00048"></a>00048 <span class="preprocessor">#endif</span> </pre></div></div> <hr class="footer"/><address style="text-align: right;"><small>Generated on Wed Apr 28 23:59:58 2010 for FAUST compiler by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address> </body> </html>