Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 583ffa4ba069126c3ba0bc565dc0485a > files > 1670

cvc3-doc-2.4.1-1.fc15.noarch.rpm

<!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>CVC3: theory_arith_old.h 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.7.4 -->
<div id="top">
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">CVC3&#160;<span id="projectnumber">2.4.1</span></div>
  </td>
 </tr>
 </tbody>
</table>
</div>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</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 id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>File&#160;Members</span></a></li>
    </ul>
  </div>
<div class="header">
  <div class="headertitle">
<div class="title">theory_arith_old.h</div>  </div>
</div>
<div class="contents">
<a href="theory__arith__old_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*****************************************************************************/</span><span class="comment"></span>
<a name="l00002"></a>00002 <span class="comment">/*!</span>
<a name="l00003"></a>00003 <span class="comment"> * \file theory_arith_old.h</span>
<a name="l00004"></a>00004 <span class="comment"> *</span>
<a name="l00005"></a>00005 <span class="comment"> * Author: Clark Barrett</span>
<a name="l00006"></a>00006 <span class="comment"> *</span>
<a name="l00007"></a>00007 <span class="comment"> * Created: Thu Jun 14 13:22:11 2007</span>
<a name="l00008"></a>00008 <span class="comment"> *</span>
<a name="l00009"></a>00009 <span class="comment"> * &lt;hr&gt;</span>
<a name="l00010"></a>00010 <span class="comment"> *</span>
<a name="l00011"></a>00011 <span class="comment"> * License to use, copy, modify, sell and/or distribute this software</span>
<a name="l00012"></a>00012 <span class="comment"> * and its documentation for any purpose is hereby granted without</span>
<a name="l00013"></a>00013 <span class="comment"> * royalty, subject to the terms and conditions defined in the \ref</span>
<a name="l00014"></a>00014 <span class="comment"> * LICENSE file provided with this distribution.</span>
<a name="l00015"></a>00015 <span class="comment"> *</span>
<a name="l00016"></a>00016 <span class="comment"> * &lt;hr&gt;</span>
<a name="l00017"></a>00017 <span class="comment"> *</span>
<a name="l00018"></a>00018 <span class="comment"> */</span>
<a name="l00019"></a>00019 <span class="comment">/*****************************************************************************/</span>
<a name="l00020"></a>00020 
<a name="l00021"></a>00021 <span class="preprocessor">#ifndef _cvc3__include__theory_arith_old_h_</span>
<a name="l00022"></a>00022 <span class="preprocessor"></span><span class="preprocessor">#define _cvc3__include__theory_arith_old_h_</span>
<a name="l00023"></a>00023 <span class="preprocessor"></span>
<a name="l00024"></a>00024 <span class="preprocessor">#include &quot;<a class="code" href="theory__arith_8h.html">theory_arith.h</a>&quot;</span>
<a name="l00025"></a>00025 <span class="preprocessor">#include &lt;set&gt;</span>
<a name="l00026"></a>00026 <span class="preprocessor">#include &lt;list&gt;</span>
<a name="l00027"></a>00027 
<a name="l00028"></a>00028 <span class="keyword">namespace </span>CVC3 {
<a name="l00029"></a>00029 
<a name="l00030"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html">00030</a> <span class="keyword">class </span><a class="code" href="classCVC3_1_1TheoryArithOld.html">TheoryArithOld</a> :<span class="keyword">public</span> <a class="code" href="classCVC3_1_1TheoryArith.html" title="This theory handles basic linear arithmetic.">TheoryArith</a> {
<a name="l00031"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a475767dfdb12442c31b65bd944b00b10">00031</a>   <a class="code" href="classCVC3_1_1CDList.html">CDList&lt;Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a475767dfdb12442c31b65bd944b00b10">d_diseq</a>;  <span class="comment">// For concrete model generation</span>
<a name="l00032"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a2a0a551f54d4d406e672526fc863e982">00032</a>   <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;size_t&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a2a0a551f54d4d406e672526fc863e982">d_diseqIdx</a>; <span class="comment">// Index to the next unprocessed disequality</span>
<a name="l00033"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#aa9f5d8de688f66aecd61f2c079b0e4e8">00033</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aa9f5d8de688f66aecd61f2c079b0e4e8">diseqSplitAlready</a>; <span class="comment">// Have we eplit on this disequality already</span>
<a name="l00034"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a1f700d0b7e2e30c96ed9d9640d988860">00034</a>   <a class="code" href="classCVC3_1_1ArithProofRules.html">ArithProofRules</a>* <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1f700d0b7e2e30c96ed9d9640d988860">d_rules</a>;
<a name="l00035"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a40829e395fe9f98d5b1a043df470c50c">00035</a>   <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a40829e395fe9f98d5b1a043df470c50c">d_inModelCreation</a>;
<a name="l00036"></a>00036 <span class="comment"></span>
<a name="l00037"></a>00037 <span class="comment">  //! Data class for the strongest free constant in separation inqualities</span>
<a name="l00038"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html">00038</a> <span class="comment"></span>  <span class="keyword">class </span><a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html" title="Data class for the strongest free constant in separation inqualities.">FreeConst</a> {
<a name="l00039"></a>00039   <span class="keyword">private</span>:
<a name="l00040"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#ae60b31be79afae97d45d64a32ea7161f">00040</a>     <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#ae60b31be79afae97d45d64a32ea7161f">d_r</a>;
<a name="l00041"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#aa0b84b0f9606c1e94acb0a7e1d61f01f">00041</a>     <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#aa0b84b0f9606c1e94acb0a7e1d61f01f">d_strict</a>;
<a name="l00042"></a>00042   <span class="keyword">public</span>:
<a name="l00043"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#acab1dc19c810e929fa3dc26a3a7806ad">00043</a>     <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#acab1dc19c810e929fa3dc26a3a7806ad">FreeConst</a>() { }
<a name="l00044"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#a1d31cb00e4c1d0ec7383b579c9460263">00044</a>     <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#a1d31cb00e4c1d0ec7383b579c9460263">FreeConst</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; r, <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#aed7ca10a7659b945907016f3794d4e4a">strict</a>): <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#ae60b31be79afae97d45d64a32ea7161f">d_r</a>(r), <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#aa0b84b0f9606c1e94acb0a7e1d61f01f">d_strict</a>(strict) { }
<a name="l00045"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#a55ac7d7eb46f1eae437b995132af2aa9">00045</a>     <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#a55ac7d7eb46f1eae437b995132af2aa9">getConst</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#ae60b31be79afae97d45d64a32ea7161f">d_r</a>; }
<a name="l00046"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#aed7ca10a7659b945907016f3794d4e4a">00046</a>     <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#aed7ca10a7659b945907016f3794d4e4a">strict</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html#aa0b84b0f9606c1e94acb0a7e1d61f01f">d_strict</a>; }
<a name="l00047"></a>00047   };<span class="comment"></span>
<a name="l00048"></a>00048 <span class="comment">  //! Printing</span>
<a name="l00049"></a>00049 <span class="comment"></span>  <span class="keyword">friend</span> std::ostream&amp; <a class="code" href="classCVC3_1_1TheoryArithOld.html#a24b0687e8f0fa36a6d5bacc8155517e2" title="Printing.">operator&lt;&lt;</a>(std::ostream&amp; os, <span class="keyword">const</span> FreeConst&amp; fc);
<a name="l00050"></a>00050 <span class="comment"></span>
<a name="l00051"></a>00051 <span class="comment">  //! Private class for an inequality in the Fourier-Motzkin database</span>
<a name="l00052"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html">00052</a> <span class="comment"></span>  <span class="keyword">class </span><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html" title="Private class for an inequality in the Fourier-Motzkin database.">Ineq</a> {
<a name="l00053"></a>00053   <span class="keyword">private</span>:
<a name="l00054"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a82f90cb62e3cb417bca7af92fa67a716">00054</a>     <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a82f90cb62e3cb417bca7af92fa67a716" title="The inequality.">d_ineq</a>; <span class="comment">//!&lt; The inequality</span>
<a name="l00055"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a33c7901cb5e1810fab974a8d5aa40c23">00055</a> <span class="comment"></span>    <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a33c7901cb5e1810fab974a8d5aa40c23" title="Var is isolated on the RHS.">d_rhs</a>; <span class="comment">//!&lt; Var is isolated on the RHS</span>
<a name="l00056"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a9a9a4aa49efb6a417d088a662a37eb2b">00056</a> <span class="comment"></span>    <span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html" title="Data class for the strongest free constant in separation inqualities.">FreeConst</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a9a9a4aa49efb6a417d088a662a37eb2b">d_const</a>; <span class="comment">//!&lt; The max/min const for subsumption check</span>
<a name="l00057"></a>00057 <span class="comment"></span><span class="comment">    //! Default constructor is disabled</span>
<a name="l00058"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a26cf2ea9daf1db49aa7cd3fb8b2c65ba">00058</a> <span class="comment"></span>    <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a26cf2ea9daf1db49aa7cd3fb8b2c65ba" title="Default constructor is disabled.">Ineq</a>() { }
<a name="l00059"></a>00059   <span class="keyword">public</span>:<span class="comment"></span>
<a name="l00060"></a>00060 <span class="comment">    //! Initial constructor.  &#39;r&#39; is taken from the subsumption database.</span>
<a name="l00061"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#ab6837fd77cd03e61093f11ccdc20f8bd">00061</a> <span class="comment"></span>    <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a26cf2ea9daf1db49aa7cd3fb8b2c65ba" title="Default constructor is disabled.">Ineq</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a15f8c72ff78626bfc273a202040b047c" title="Get the inequality.">ineq</a>, <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a356ba30a472260912f9bc6f9273929e0" title="Flag whether var is isolated on the RHS.">varOnRHS</a>, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html" title="Data class for the strongest free constant in separation inqualities.">FreeConst</a>&amp; c):
<a name="l00062"></a>00062       <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a82f90cb62e3cb417bca7af92fa67a716" title="The inequality.">d_ineq</a>(ineq), <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a33c7901cb5e1810fab974a8d5aa40c23" title="Var is isolated on the RHS.">d_rhs</a>(varOnRHS), <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a9a9a4aa49efb6a417d088a662a37eb2b">d_const</a>(&amp;c) { }<span class="comment"></span>
<a name="l00063"></a>00063 <span class="comment">    //! Get the inequality</span>
<a name="l00064"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a15f8c72ff78626bfc273a202040b047c">00064</a> <span class="comment"></span>    <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a15f8c72ff78626bfc273a202040b047c" title="Get the inequality.">ineq</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a82f90cb62e3cb417bca7af92fa67a716" title="The inequality.">d_ineq</a>; }<span class="comment"></span>
<a name="l00065"></a>00065 <span class="comment">    //! Get the max/min constant</span>
<a name="l00066"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a2387b0669cceaf6432294824939ceb6c">00066</a> <span class="comment"></span>    <span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html" title="Data class for the strongest free constant in separation inqualities.">FreeConst</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a2387b0669cceaf6432294824939ceb6c" title="Get the max/min constant.">getConst</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> *<a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a9a9a4aa49efb6a417d088a662a37eb2b">d_const</a>; }<span class="comment"></span>
<a name="l00067"></a>00067 <span class="comment">    //! Flag whether var is isolated on the RHS</span>
<a name="l00068"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a356ba30a472260912f9bc6f9273929e0">00068</a> <span class="comment"></span>    <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a356ba30a472260912f9bc6f9273929e0" title="Flag whether var is isolated on the RHS.">varOnRHS</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a33c7901cb5e1810fab974a8d5aa40c23" title="Var is isolated on the RHS.">d_rhs</a>; }<span class="comment"></span>
<a name="l00069"></a>00069 <span class="comment">    //! Flag whether var is isolated on the LHS</span>
<a name="l00070"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a720977dd198a7418089d42a9e4dcd149">00070</a> <span class="comment"></span>    <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a720977dd198a7418089d42a9e4dcd149" title="Flag whether var is isolated on the LHS.">varOnLHS</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> !<a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a33c7901cb5e1810fab974a8d5aa40c23" title="Var is isolated on the RHS.">d_rhs</a>; }<span class="comment"></span>
<a name="l00071"></a>00071 <span class="comment">    //! Auto-cast to Theorem</span>
<a name="l00072"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a4cd41d9631ffb5dc11eb4cade2cbecfc">00072</a> <span class="comment"></span>    <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a4cd41d9631ffb5dc11eb4cade2cbecfc" title="Auto-cast to Theorem.">operator Theorem</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1Ineq.html#a82f90cb62e3cb417bca7af92fa67a716" title="The inequality.">d_ineq</a>; }
<a name="l00073"></a>00073   };<span class="comment"></span>
<a name="l00074"></a>00074 <span class="comment">  //! Printing</span>
<a name="l00075"></a>00075 <span class="comment"></span>  <span class="keyword">friend</span> std::ostream&amp; <a class="code" href="classCVC3_1_1TheoryArithOld.html#a24b0687e8f0fa36a6d5bacc8155517e2" title="Printing.">operator&lt;&lt;</a>(std::ostream&amp; os, <span class="keyword">const</span> Ineq&amp; ineq);
<a name="l00076"></a>00076 <span class="comment"></span>
<a name="l00077"></a>00077 <span class="comment">  //! Database of inequalities with a variable isolated on the right</span>
<a name="l00078"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#af89e9fc76620b5d170850e769cc0c785">00078</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;CDList&lt;Ineq&gt;</a> *&gt; <a class="code" href="classCVC3_1_1TheoryArithOld.html#af89e9fc76620b5d170850e769cc0c785" title="Database of inequalities with a variable isolated on the right.">d_inequalitiesRightDB</a>;
<a name="l00079"></a>00079 <span class="comment"></span>
<a name="l00080"></a>00080 <span class="comment">  //! Database of inequalities with a variable isolated on the left</span>
<a name="l00081"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#ad4df2ed12abb38f060e8c82515b8608c">00081</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;CDList&lt;Ineq&gt;</a> *&gt; <a class="code" href="classCVC3_1_1TheoryArithOld.html#ad4df2ed12abb38f060e8c82515b8608c" title="Database of inequalities with a variable isolated on the left.">d_inequalitiesLeftDB</a>;
<a name="l00082"></a>00082 <span class="comment"></span>
<a name="l00083"></a>00083 <span class="comment">  //! Mapping of inequalities to the largest/smallest free constant</span>
<a name="l00084"></a>00084 <span class="comment"></span><span class="comment">  /*! The Expr is the original inequality with the free constant</span>
<a name="l00085"></a>00085 <span class="comment">   * removed and inequality converted to non-strict (for indexing</span>
<a name="l00086"></a>00086 <span class="comment">   * purposes).  I.e. ax&lt;c+t becomes ax&lt;=t.  This inequality is mapped</span>
<a name="l00087"></a>00087 <span class="comment">   * to a pair&lt;c,strict&gt;, the smallest (largest for c+t&lt;ax) constant</span>
<a name="l00088"></a>00088 <span class="comment">   * among inequalities with the same &#39;a&#39;, &#39;x&#39;, and &#39;t&#39;, and a boolean</span>
<a name="l00089"></a>00089 <span class="comment">   * flag indicating whether the strongest inequality is strict.</span>
<a name="l00090"></a>00090 <span class="comment">   */</span>
<a name="l00091"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#abf3123ffb3e08ece66d6982e9a4b6c2e">00091</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, FreeConst&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#abf3123ffb3e08ece66d6982e9a4b6c2e" title="Mapping of inequalities to the largest/smallest free constant.">d_freeConstDB</a>;
<a name="l00092"></a>00092 
<a name="l00093"></a>00093 <span class="comment">//  /** Is the problem only difference logic */</span>
<a name="l00094"></a>00094 <span class="comment">//  CDO&lt;bool&gt; isDL;</span>
<a name="l00095"></a>00095 <span class="comment">//  CDO&lt;int&gt; total_buf_size;</span>
<a name="l00096"></a>00096 <span class="comment">//  CDO&lt;int&gt; processed;</span>
<a name="l00097"></a>00097 <span class="comment">//</span>
<a name="l00098"></a>00098   <span class="comment">// Input buffer to store the incoming inequalities</span>
<a name="l00099"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a4d49144bb8b5ce32137c7ed8ccf27b32">00099</a>   <a class="code" href="classCVC3_1_1CDList.html">CDList&lt;Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a4d49144bb8b5ce32137c7ed8ccf27b32" title="Buffer of input inequalities (high priority)">d_buffer_0</a>; <span class="comment">//!&lt; Buffer of input inequalities (high priority)</span>
<a name="l00100"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#abc136583724a477c0d748096580fe0b9">00100</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1CDList.html">CDList&lt;Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#abc136583724a477c0d748096580fe0b9" title="Buffer of input inequalities (one variable)">d_buffer_1</a>; <span class="comment">//!&lt; Buffer of input inequalities (one variable)</span>
<a name="l00101"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a435fac35fb032c091e227398972ad55e">00101</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1CDList.html">CDList&lt;Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a435fac35fb032c091e227398972ad55e" title="Buffer of input inequalities (small constraints)">d_buffer_2</a>; <span class="comment">//!&lt; Buffer of input inequalities (small constraints)</span>
<a name="l00102"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a4e33f5321cb15e4f7252772c58600bce">00102</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1CDList.html">CDList&lt;Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a4e33f5321cb15e4f7252772c58600bce" title="Buffer of input inequalities (big constraint)">d_buffer_3</a>; <span class="comment">//!&lt; Buffer of input inequalities (big constraint)</span>
<a name="l00103"></a>00103 <span class="comment"></span>
<a name="l00104"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#aa2f920e8cc39034f24cbe52a7edb7754">00104</a>   <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;size_t&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aa2f920e8cc39034f24cbe52a7edb7754" title="Buffer index of the next unprocessed inequality.">d_bufferIdx_0</a>; <span class="comment">//!&lt; Buffer index of the next unprocessed inequality</span>
<a name="l00105"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a06582edc6ff3081f420bccb4a35b33e3">00105</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;size_t&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a06582edc6ff3081f420bccb4a35b33e3" title="Buffer index of the next unprocessed inequality.">d_bufferIdx_1</a>; <span class="comment">//!&lt; Buffer index of the next unprocessed inequality</span>
<a name="l00106"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a31b271732e81b39fa2d228af1dff9a68">00106</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;size_t&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a31b271732e81b39fa2d228af1dff9a68" title="Buffer index of the next unprocessed inequality.">d_bufferIdx_2</a>; <span class="comment">//!&lt; Buffer index of the next unprocessed inequality</span>
<a name="l00107"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#aba34300626e64486129e1afa96da9837">00107</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;size_t&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aba34300626e64486129e1afa96da9837" title="Buffer index of the next unprocessed inequality.">d_bufferIdx_3</a>; <span class="comment">//!&lt; Buffer index of the next unprocessed inequality</span>
<a name="l00108"></a>00108 <span class="comment"></span>
<a name="l00109"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#ae176998a4531d73a2723680c45ef618c">00109</a>   <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;size_t&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ae176998a4531d73a2723680c45ef618c" title="Number of queries that are just difference logic.">diff_logic_size</a>; <span class="comment">//!&lt; Number of queries that are just difference logic</span>
<a name="l00110"></a>00110 <span class="comment"></span>
<a name="l00111"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a53b15103320c4dcce490238f380851ff">00111</a>   <span class="keyword">const</span> <span class="keywordtype">int</span>* <a class="code" href="classCVC3_1_1TheoryArithOld.html#a53b15103320c4dcce490238f380851ff" title="Threshold when the buffer must be processed.">d_bufferThres</a>; <span class="comment">//!&lt; Threshold when the buffer must be processed</span>
<a name="l00112"></a>00112 <span class="comment"></span>
<a name="l00113"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a7cee71daa7f8f8bbd33d0b6a333f61aa">00113</a>   <span class="keyword">const</span> <span class="keywordtype">bool</span>* <a class="code" href="classCVC3_1_1TheoryArithOld.html#a7cee71daa7f8f8bbd33d0b6a333f61aa">d_splitSign</a>; <span class="comment">// Whether to split on the signs of non-trivial nonlinear products</span>
<a name="l00114"></a>00114 
<a name="l00115"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#af606dcd2ddc8be8ad3f0bb6fea6eb4db">00115</a>   <span class="keyword">const</span> <span class="keywordtype">int</span>* <a class="code" href="classCVC3_1_1TheoryArithOld.html#af606dcd2ddc8be8ad3f0bb6fea6eb4db" title="Threshold on gray shadow size (ignore it and set incomplete)">d_grayShadowThres</a>; <span class="comment">//!&lt; Threshold on gray shadow size (ignore it and set incomplete)</span>
<a name="l00116"></a>00116 <span class="comment"></span>
<a name="l00117"></a>00117   <span class="comment">// Statistics for the variables</span>
<a name="l00118"></a>00118 <span class="comment"></span>
<a name="l00119"></a>00119 <span class="comment">  /*! @brief Mapping of a variable to the number of inequalities where</span>
<a name="l00120"></a>00120 <span class="comment">    the variable would be isolated on the right */</span>
<a name="l00121"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#ae642c380af492cdc4581a9182514c20c">00121</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, int&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ae642c380af492cdc4581a9182514c20c" title="Mapping of a variable to the number of inequalities where the variable would be isolated on the right...">d_countRight</a>;
<a name="l00122"></a>00122 <span class="comment"></span>
<a name="l00123"></a>00123 <span class="comment">  /*! @brief Mapping of a variable to the number of inequalities where</span>
<a name="l00124"></a>00124 <span class="comment">    the variable would be isolated on the left */</span>
<a name="l00125"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a69bd49fe441cf96f2c665deb97ab6859">00125</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, int&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a69bd49fe441cf96f2c665deb97ab6859" title="Mapping of a variable to the number of inequalities where the variable would be isolated on the left...">d_countLeft</a>;
<a name="l00126"></a>00126 <span class="comment"></span>
<a name="l00127"></a>00127 <span class="comment">  //! Set of shared terms (for counterexample generation)</span>
<a name="l00128"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a5c8d1f10ab619b668988eb866a5b8e45">00128</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a5c8d1f10ab619b668988eb866a5b8e45" title="Set of shared terms (for counterexample generation)">d_sharedTerms</a>;
<a name="l00129"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#abd3bec60e2dbe8e0c427d91227733dd2">00129</a>   <a class="code" href="classCVC3_1_1CDList.html">CDList&lt;Expr&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#abd3bec60e2dbe8e0c427d91227733dd2">d_sharedTermsList</a>;
<a name="l00130"></a>00130 <span class="comment"></span>
<a name="l00131"></a>00131 <span class="comment">  //! Set of shared integer variables (i-leaves)</span>
<a name="l00132"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a84b39d6978a6942723f608da58d54e51">00132</a> <span class="comment"></span>  <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a84b39d6978a6942723f608da58d54e51" title="Set of shared integer variables (i-leaves)">d_sharedVars</a>;
<a name="l00133"></a>00133 
<a name="l00134"></a>00134   <span class="comment">//Directed Acyclic Graph representing partial variable ordering for</span>
<a name="l00135"></a>00135   <span class="comment">//variable projection over inequalities.</span>
<a name="l00136"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html">00136</a>   <span class="keyword">class </span><a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html">VarOrderGraph</a> {
<a name="l00137"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#a11bc58175df42f2fd51489e06ddb57f0">00137</a>     <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;std::vector&lt;Expr&gt;</a> &gt; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#a11bc58175df42f2fd51489e06ddb57f0">d_edges</a>;
<a name="l00138"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#ae56759d90816a022aaf6b5afbe8d4604">00138</a>     <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#ae56759d90816a022aaf6b5afbe8d4604">d_cache</a>;
<a name="l00139"></a>00139     <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#a57473e1e2ab66d049df3859816a48c51">dfs</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e1, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e2);
<a name="l00140"></a>00140     <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#a57473e1e2ab66d049df3859816a48c51">dfs</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e1, std::vector&lt;Expr&gt;&amp; output_list);
<a name="l00141"></a>00141   <span class="keyword">public</span>:
<a name="l00142"></a>00142     <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#a23f0f51e26002bc941caa23a55ce812f">addEdge</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e1, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e2);
<a name="l00143"></a>00143     <span class="comment">//returns true if e1 &lt; e2, false otherwise.</span>
<a name="l00144"></a>00144     <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#acfccb17ecc31cede704da554e8d3f14e">lessThan</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e1, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e2);
<a name="l00145"></a>00145     <span class="comment">//selects those variables which are largest and incomparable among</span>
<a name="l00146"></a>00146     <span class="comment">//v1 and puts it into v2</span>
<a name="l00147"></a>00147     <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#a02fbf073e8ec356a753bf318b6701b13">selectLargest</a>(<span class="keyword">const</span> std::vector&lt;Expr&gt;&amp; v1, std::vector&lt;Expr&gt;&amp; v2);
<a name="l00148"></a>00148     <span class="comment">//selects those variables which are smallest and incomparable among</span>
<a name="l00149"></a>00149     <span class="comment">//v1, removes them from v1 and  puts them into v2.</span>
<a name="l00150"></a>00150     <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#a3fe7de5a6e79191b3086b05add92a766">selectSmallest</a>( std::vector&lt;Expr&gt;&amp; v1, std::vector&lt;Expr&gt;&amp; v2);
<a name="l00151"></a>00151     <span class="comment">//returns the list of vertices in the topological order</span>
<a name="l00152"></a>00152     <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html#a9813d7fd535f36502828ebda307d92d0">getVerticesTopological</a>(std::vector&lt;Expr&gt;&amp; output_list);
<a name="l00153"></a>00153   };
<a name="l00154"></a>00154 
<a name="l00155"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a3f242375ca87172a68b30c5a49a0cf2e">00155</a>   <a class="code" href="classCVC3_1_1TheoryArithOld_1_1VarOrderGraph.html">VarOrderGraph</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a3f242375ca87172a68b30c5a49a0cf2e">d_graph</a>;
<a name="l00156"></a>00156 
<a name="l00157"></a>00157   <span class="comment">// Private methods</span>
<a name="l00158"></a>00158 <span class="comment"></span>
<a name="l00159"></a>00159 <span class="comment">  //! Check the term t for integrality.</span>
<a name="l00160"></a>00160 <span class="comment"></span><span class="comment">  /*! \return a theorem of IS_INTEGER(t) or Null. */</span>
<a name="l00161"></a>00161   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a616b3e984904813383d6bc716496ef06" title="Check the term t for integrality.">isIntegerThm</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00162"></a>00162 <span class="comment"></span>
<a name="l00163"></a>00163 <span class="comment">  //! A helper method for isIntegerThm()</span>
<a name="l00164"></a>00164 <span class="comment"></span><span class="comment">  /*! Check if IS_INTEGER(e) is easily derivable from the given &#39;thm&#39; */</span>
<a name="l00165"></a>00165   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a6e0c686fb1eedbe704466bceb531dab7" title="A helper method for isIntegerThm()">isIntegerDerive</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; isIntE, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm);
<a name="l00166"></a>00166 <span class="comment"></span>
<a name="l00167"></a>00167 <span class="comment">  //! Extract the free constant from an inequality</span>
<a name="l00168"></a>00168 <span class="comment"></span>  <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld.html#a5adbc1a0946700ed1c6258fd29e044be" title="Extract the free constant from an inequality.">freeConstIneq</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; ineq, <span class="keywordtype">bool</span> varOnRHS);
<a name="l00169"></a>00169 <span class="comment"></span>
<a name="l00170"></a>00170 <span class="comment">  //! Update the free constant subsumption database with new inequality</span>
<a name="l00171"></a>00171 <span class="comment"></span><span class="comment">  /*! \return a reference to the max/min constant.</span>
<a name="l00172"></a>00172 <span class="comment">   *</span>
<a name="l00173"></a>00173 <span class="comment">   * Also, sets &#39;subsumed&#39; argument to true if the inequality is</span>
<a name="l00174"></a>00174 <span class="comment">   * subsumed by an existing inequality.</span>
<a name="l00175"></a>00175 <span class="comment">   */</span>
<a name="l00176"></a>00176   <span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1FreeConst.html" title="Data class for the strongest free constant in separation inqualities.">FreeConst</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1a20be9ae34b5301092b70364d8b4bb1" title="Update the free constant subsumption database with new inequality.">updateSubsumptionDB</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; ineq, <span class="keywordtype">bool</span> varOnRHS,
<a name="l00177"></a>00177               <span class="keywordtype">bool</span>&amp; subsumed);<span class="comment"></span>
<a name="l00178"></a>00178 <span class="comment">  //! Check if the kids of e are fully simplified and canonized (for debugging)</span>
<a name="l00179"></a>00179 <span class="comment"></span>  <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a787aa195e77ab9fd007352d5ad74cc7f" title="Check if the kids of e are fully simplified and canonized (for debugging)">kidsCanonical</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00180"></a>00180 <span class="comment"></span>
<a name="l00181"></a>00181 <span class="comment">  //! Canonize the expression e, assuming,  all children are canonical</span>
<a name="l00182"></a>00182 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a657b7b3914e46113e28b2e1fff310c26" title="Canonize the expression e, assuming, all children are canonical.">canon</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00183"></a>00183 <span class="comment"></span>
<a name="l00184"></a>00184 <span class="comment">  /*! @brief Canonize and reduce e w.r.t. union-find database; assume</span>
<a name="l00185"></a>00185 <span class="comment">   * all children are canonical */</span>
<a name="l00186"></a>00186   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1c6bb68d18ada95c8780bdce6e6cb5e5" title="Canonize and reduce e w.r.t. union-find database; assume all children are canonical.">canonSimplify</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00187"></a>00187 <span class="comment"></span>
<a name="l00188"></a>00188 <span class="comment">  /*! @brief Composition of canonSimplify(const Expr&amp;) by</span>
<a name="l00189"></a>00189 <span class="comment">   * transitivity: take e0 = e1, canonize and simplify e1 to e2,</span>
<a name="l00190"></a>00190 <span class="comment">   * return e0 = e2. */</span>
<a name="l00191"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a04fff631d56ee39c895818f6bb2014b6">00191</a>   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a04fff631d56ee39c895818f6bb2014b6" title="Composition of canonSimplify(const Expr&amp;) by transitivity: take e0 = e1, canonize and simplify e1 to ...">canonSimplify</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm) {
<a name="l00192"></a>00192     <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1Theory.html#a76f6507116e36f46dab074781fb9bf2d" title="(a1 == a2) &amp; (a2 == a3) ==&gt; (a1 == a3)">transitivityRule</a>(thm, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1c6bb68d18ada95c8780bdce6e6cb5e5" title="Canonize and reduce e w.r.t. union-find database; assume all children are canonical.">canonSimplify</a>(thm.<a class="code" href="classCVC3_1_1Theorem.html#a97d957fcbf9094480851b1d2e5d3729f">getRHS</a>()));
<a name="l00193"></a>00193   }
<a name="l00194"></a>00194 <span class="comment"></span>
<a name="l00195"></a>00195 <span class="comment">  //! Canonize predicate (x = y, x &lt; y, etc.)</span>
<a name="l00196"></a>00196 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a3190adc8a44721ed37dfa34333462a0c" title="Canonize predicate (x = y, x &lt; y, etc.)">canonPred</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm);
<a name="l00197"></a>00197 <span class="comment"></span>
<a name="l00198"></a>00198 <span class="comment">  //! Canonize predicate like canonPred except that the input theorem</span>
<a name="l00199"></a>00199 <span class="comment">  //! is an equivalent transformation.</span>
<a name="l00200"></a>00200 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a4933900b82159f8380754b386a895f84">canonPredEquiv</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm);
<a name="l00201"></a>00201 <span class="comment"></span>
<a name="l00202"></a>00202 <span class="comment">  //! Solve an equation and return an equivalent Theorem in the solved form</span>
<a name="l00203"></a>00203 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a7026fb3070c66f3e3001ca94c3153434" title="Solve an equation and return an equivalent Theorem in the solved form.">doSolve</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; e);
<a name="l00204"></a>00204 <span class="comment"></span>
<a name="l00205"></a>00205 <span class="comment">  //! takes in a conjunction equivalence Thm and canonizes it.</span>
<a name="l00206"></a>00206 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a43f9a32880731caf7956db77adf633c8" title="takes in a conjunction equivalence Thm and canonizes it.">canonConjunctionEquiv</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm);
<a name="l00207"></a>00207 <span class="comment"></span>
<a name="l00208"></a>00208 <span class="comment">  //! picks the monomial with the smallest abs(coeff) from the input</span>
<a name="l00209"></a>00209 <span class="comment"></span>  <span class="comment">//integer equation.</span>
<a name="l00210"></a>00210   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1c9bcf5e29f48498065f1d32a8c3f4b7" title="picks the monomial with the smallest abs(coeff) from the input">pickIntEqMonomial</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; <a class="code" href="namespaceMiniSat.html#a82558b7a36c52f5d3211d5d14bed99d4">right</a>, <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; isolated, <span class="keywordtype">bool</span>&amp; nonlin);
<a name="l00211"></a>00211 <span class="comment"></span>
<a name="l00212"></a>00212 <span class="comment">  //! processes equalities with 1 or more vars of type REAL</span>
<a name="l00213"></a>00213 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a8eee6ca3ee410677dea1209a8cbef65f" title="processes equalities with 1 or more vars of type REAL">processRealEq</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; eqn);
<a name="l00214"></a>00214 <span class="comment"></span>
<a name="l00215"></a>00215 <span class="comment">  //! processes equalities whose vars are all of type INT</span>
<a name="l00216"></a>00216 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a4f8a6f8aa73817d4696a4035713c1eaa" title="processes equalities whose vars are all of type INT">processIntEq</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; eqn);
<a name="l00217"></a>00217 <span class="comment"></span>
<a name="l00218"></a>00218 <span class="comment">  //! One step of INT equality processing (aux. method for processIntEq())</span>
<a name="l00219"></a>00219 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a8b94e299e5947b05b3e29757ff621b56" title="One step of INT equality processing (aux. method for processIntEq())">processSimpleIntEq</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; eqn);
<a name="l00220"></a>00220 <span class="comment"></span>
<a name="l00221"></a>00221 <span class="comment">  //! Process inequalities in the buffer</span>
<a name="l00222"></a>00222 <span class="comment"></span>  <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ad6d1693a1a81c87e64d51abb3596f21b" title="Process inequalities in the buffer.">processBuffer</a>();
<a name="l00223"></a>00223 <span class="comment"></span>
<a name="l00224"></a>00224 <span class="comment">  //! Take an inequality and isolate a variable</span>
<a name="l00225"></a>00225 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a3bef421de6f4579b54b76666d015ecb4" title="Take an inequality and isolate a variable.">isolateVariable</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; inputThm, <span class="keywordtype">bool</span>&amp; e1);
<a name="l00226"></a>00226 <span class="comment"></span>
<a name="l00227"></a>00227 <span class="comment">  //! Update the statistics counters for the variable with a coeff. c</span>
<a name="l00228"></a>00228 <span class="comment"></span>  <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aeda9acb0bae07ff39ce79f8b0e2e83f7" title="Update the statistics counters for the variable with a coeff. c.">updateStats</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; c, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; var);
<a name="l00229"></a>00229 <span class="comment"></span>
<a name="l00230"></a>00230 <span class="comment">  //! Update the statistics counters for the monomial</span>
<a name="l00231"></a>00231 <span class="comment"></span>  <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aeda9acb0bae07ff39ce79f8b0e2e83f7" title="Update the statistics counters for the variable with a coeff. c.">updateStats</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; monomial);
<a name="l00232"></a>00232 <span class="comment"></span>
<a name="l00233"></a>00233 <span class="comment">  //! Add an inequality to the input buffer.  See also d_buffer</span>
<a name="l00234"></a>00234 <span class="comment"></span>  <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a473d3204340c03e97f8eae1975b752cb" title="Add an inequality to the input buffer. See also d_buffer.">addToBuffer</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm, <span class="keywordtype">bool</span> priority = <span class="keyword">false</span>);
<a name="l00235"></a>00235 <span class="comment"></span>
<a name="l00236"></a>00236 <span class="comment">  /*! @brief Given a canonized term, compute a factor to make all</span>
<a name="l00237"></a>00237 <span class="comment">    coefficients integer and relatively prime */</span>
<a name="l00238"></a>00238   <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1b9f6be5cba7ac4ae67800f5b002ef09" title="Given a canonized term, compute a factor to make all coefficients integer and relatively prime...">computeNormalFactor</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; rhs, <span class="keywordtype">bool</span> normalizeConstants);
<a name="l00239"></a>00239 <span class="comment"></span>
<a name="l00240"></a>00240 <span class="comment">  //! Normalize an equation (make all coefficients rel. prime integers)</span>
<a name="l00241"></a>00241 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a19b5fc9e624049923d3bf7d561cf83a8" title="Normalize an equation (make all coefficients rel. prime integers)">normalize</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00242"></a>00242 <span class="comment"></span>
<a name="l00243"></a>00243 <span class="comment">  //! Normalize an equation (make all coefficients rel. prime integers)</span>
<a name="l00244"></a>00244 <span class="comment"></span><span class="comment">  /*! accepts a rewrite theorem over eqn|ineqn and normalizes it</span>
<a name="l00245"></a>00245 <span class="comment">   *  and returns a theorem to that effect.</span>
<a name="l00246"></a>00246 <span class="comment">   */</span>
<a name="l00247"></a>00247   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a19b5fc9e624049923d3bf7d561cf83a8" title="Normalize an equation (make all coefficients rel. prime integers)">normalize</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm);
<a name="l00248"></a>00248 
<a name="l00249"></a>00249   <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a12afa30f9322b35f5c79107522aa3d40">pickMonomial</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; <a class="code" href="namespaceMiniSat.html#a82558b7a36c52f5d3211d5d14bed99d4">right</a>);
<a name="l00250"></a>00250 
<a name="l00251"></a>00251   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1bd6e1f367ec9b69c2f511716c4d4b59">getFactors</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e, std::set&lt;Expr&gt;&amp; factors);
<a name="l00252"></a>00252 
<a name="l00253"></a>00253  <span class="keyword">public</span>: <span class="comment">// ArithTheoremProducer needs these functions, so make them public</span><span class="comment"></span>
<a name="l00254"></a>00254 <span class="comment">  //! Separate monomial e = c*p1*...*pn into c and 1*p1*...*pn</span>
<a name="l00255"></a>00255 <span class="comment"></span>  <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a7cf2bbefa118b69a416778e98cda8408" title="Separate monomial e = c*p1*...*pn into c and 1*p1*...*pn.">separateMonomial</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e, <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; c, <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; var);
<a name="l00256"></a>00256 <span class="comment"></span>
<a name="l00257"></a>00257 <span class="comment">  //! Check the term t for integrality (return bool)</span>
<a name="l00258"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a849e9094d3af74ee70e45112b353136c">00258</a> <span class="comment"></span>  <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a849e9094d3af74ee70e45112b353136c" title="Check the term t for integrality (return bool)">isInteger</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e)
<a name="l00259"></a>00259   { <span class="keywordflow">return</span>
<a name="l00260"></a>00260       <a class="code" href="namespaceCVC3.html#a8b193cc1fee34cb43707171b2ae6471e">isInt</a>(e.<a class="code" href="group__ExprPkg.html#ga42929221eb172250697b72c28af6de07" title="Get the type. Recursively compute if necessary.">getType</a>()) ? <span class="keyword">true</span> :
<a name="l00261"></a>00261       (<a class="code" href="namespaceCVC3.html#a6475c7ef78c59970a4525d5b3ff0ce86">isReal</a>(e.<a class="code" href="group__ExprPkg.html#ga42929221eb172250697b72c28af6de07" title="Get the type. Recursively compute if necessary.">getType</a>()) ? <span class="keyword">false</span> : !(<a class="code" href="classCVC3_1_1TheoryArithOld.html#a616b3e984904813383d6bc716496ef06" title="Check the term t for integrality.">isIntegerThm</a>(e).<a class="code" href="classCVC3_1_1Theorem.html#afc6fdb0507eb3669e28d9be5ed0bd333">isNull</a>())); }
<a name="l00262"></a>00262 
<a name="l00263"></a>00263  <span class="keyword">private</span>:
<a name="l00264"></a>00264 
<a name="l00265"></a>00265   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a7aaeb2f1987ed2be618088b8149dd329">lessThanVar</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; isolatedVar, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; var2);
<a name="l00266"></a>00266 <span class="comment"></span>
<a name="l00267"></a>00267 <span class="comment">  //! Check if the term expression is &quot;stale&quot;</span>
<a name="l00268"></a>00268 <span class="comment"></span>  <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ac623d777315532c14558cff5b16cd085" title="Check if the term expression is &quot;stale&quot;.">isStale</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00269"></a>00269 <span class="comment"></span>
<a name="l00270"></a>00270 <span class="comment">  //! Check if the inequality is &quot;stale&quot; or subsumed</span>
<a name="l00271"></a>00271 <span class="comment"></span>  <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ac623d777315532c14558cff5b16cd085" title="Check if the term expression is &quot;stale&quot;.">isStale</a>(<span class="keyword">const</span> Ineq&amp; ineq);
<a name="l00272"></a>00272 
<a name="l00273"></a>00273   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a03cf8b3d693cd9bc3237f9e1e1cacaf1">projectInequalities</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; theInequality,<span class="keywordtype">bool</span> isolatedVarOnRHS);
<a name="l00274"></a>00274 
<a name="l00275"></a>00275   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a515b32506fecca7cd6425d62b9ef5077">assignVariables</a>(std::vector&lt;Expr&gt;&amp;v);
<a name="l00276"></a>00276 
<a name="l00277"></a>00277   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ab26f578642a85785f9323fcabef94797">findRationalBound</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; varSide, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; ratSide,
<a name="l00278"></a>00278        <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; var,
<a name="l00279"></a>00279        <a class="code" href="classCVC3_1_1Rational.html">Rational</a> &amp;r);
<a name="l00280"></a>00280 
<a name="l00281"></a>00281   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a8dfcde6ee0edf0f14959b1b582575261">findBounds</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e, <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; lub, <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp;  glb);
<a name="l00282"></a>00282 
<a name="l00283"></a>00283   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a6998209aa1c4e1ed10a2be7b7303d89c">normalizeProjectIneqs</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; ineqThm1,
<a name="l00284"></a>00284         <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; ineqThm2);
<a name="l00285"></a>00285 <span class="comment"></span>
<a name="l00286"></a>00286 <span class="comment">  //! Take a system of equations and turn it into a solved form</span>
<a name="l00287"></a>00287 <span class="comment"></span>  <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a02f7b174fc1989343a087bb495cb7e75" title="Take a system of equations and turn it into a solved form.">solvedForm</a>(<span class="keyword">const</span> std::vector&lt;Theorem&gt;&amp; solvedEqs);
<a name="l00288"></a>00288 <span class="comment"></span>
<a name="l00289"></a>00289 <span class="comment">  /*! @brief Substitute all vars in term &#39;t&#39; according to the</span>
<a name="l00290"></a>00290 <span class="comment">   * substitution &#39;subst&#39; and canonize the result.</span>
<a name="l00291"></a>00291 <span class="comment">   */</span>
<a name="l00292"></a>00292   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a315acb4c55cf413c47c013853a534112" title="Substitute all vars in term &#39;t&#39; according to the substitution &#39;subst&#39; and canonize the result...">substAndCanonize</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;Theorem&gt;</a>&amp; subst);
<a name="l00293"></a>00293 <span class="comment"></span>
<a name="l00294"></a>00294 <span class="comment">  /*! @brief Substitute all vars in the RHS of the equation &#39;eq&#39; of</span>
<a name="l00295"></a>00295 <span class="comment">   * the form (x = t) according to the substitution &#39;subst&#39;, and</span>
<a name="l00296"></a>00296 <span class="comment">   * canonize the result.</span>
<a name="l00297"></a>00297 <span class="comment">   */</span>
<a name="l00298"></a>00298   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a315acb4c55cf413c47c013853a534112" title="Substitute all vars in term &#39;t&#39; according to the substitution &#39;subst&#39; and canonize the result...">substAndCanonize</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; eq, <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;Theorem&gt;</a>&amp; subst);
<a name="l00299"></a>00299 <span class="comment"></span>
<a name="l00300"></a>00300 <span class="comment">  //! Traverse &#39;e&#39; and push all the i-leaves into &#39;vars&#39; vector</span>
<a name="l00301"></a>00301 <span class="comment"></span>  <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aa3aac05d983610669f500fb761615fa0" title="Traverse &#39;e&#39; and push all the i-leaves into &#39;vars&#39; vector.">collectVars</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e, std::vector&lt;Expr&gt;&amp; vars,
<a name="l00302"></a>00302        std::set&lt;Expr&gt;&amp; cache);
<a name="l00303"></a>00303 <span class="comment"></span>
<a name="l00304"></a>00304 <span class="comment">  /*! @brief Check if alpha &lt;= ax &amp; bx &lt;= beta is a finite interval</span>
<a name="l00305"></a>00305 <span class="comment">   *  for integer var &#39;x&#39;, and assert the corresponding constraint</span>
<a name="l00306"></a>00306 <span class="comment">   */</span>
<a name="l00307"></a>00307   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#abc79fe4a559ac4d6e9b75a2cab81d2b0" title="Check if alpha &lt;= ax &amp; bx &lt;= beta is a finite interval for integer var &#39;x&#39;, and assert the correspondin...">processFiniteInterval</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; alphaLEax,
<a name="l00308"></a>00308            <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; bxLEbeta);
<a name="l00309"></a>00309 <span class="comment"></span>
<a name="l00310"></a>00310 <span class="comment">  //! For an integer var &#39;x&#39;, find and process all constraints A &lt;= ax &lt;= A+c</span>
<a name="l00311"></a>00311 <span class="comment"></span>  <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a9dc4aaaa3c9bf4cc53ed6e699b5cb67d" title="For an integer var &#39;x&#39;, find and process all constraints A &lt;= ax &lt;= A+c.">processFiniteIntervals</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x);
<a name="l00312"></a>00312 <span class="comment"></span>
<a name="l00313"></a>00313 <span class="comment">  //! Recursive setup for isolated inequalities (and other new expressions)</span>
<a name="l00314"></a>00314 <span class="comment"></span>  <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ac240d8f8712b716744824921cf46deb0" title="Recursive setup for isolated inequalities (and other new expressions)">setupRec</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00315"></a>00315 
<a name="l00316"></a>00316 <span class="keyword">public</span>:
<a name="l00317"></a>00317   <a class="code" href="classCVC3_1_1TheoryArithOld.html#a421bf72419f51b1a7e95363da00f4177">TheoryArithOld</a>(<a class="code" href="classCVC3_1_1TheoryCore.html" title="This theory handles the built-in logical connectives plus equality. It also handles the registration ...">TheoryCore</a>* core);
<a name="l00318"></a>00318   <a class="code" href="classCVC3_1_1TheoryArithOld.html#a72870e1afaa3d74f5de058116211b4a9">~TheoryArithOld</a>();
<a name="l00319"></a>00319 
<a name="l00320"></a>00320   <span class="comment">// Trusted method that creates the proof rules class (used in constructor).</span>
<a name="l00321"></a>00321   <span class="comment">// Implemented in arith_theorem_producer.cpp</span>
<a name="l00322"></a>00322   <a class="code" href="classCVC3_1_1ArithProofRules.html">ArithProofRules</a>* <a class="code" href="classCVC3_1_1TheoryArithOld.html#a80f0e73dede7d5072cf7941a39a8deb4">createProofRulesOld</a>();
<a name="l00323"></a>00323 
<a name="l00324"></a>00324   <span class="comment">// Theory interface</span>
<a name="l00325"></a>00325   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1503d539a5f25dfdb5fcfe486405b658" title="Notify theory of a new shared term.">addSharedTerm</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00326"></a>00326   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a998f71fde188c547c464a912058dd64d" title="Assert a new fact to the decision procedure.">assertFact</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; e);
<a name="l00327"></a>00327   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aa4dc2c586e3bf401a1940a2057508d9f" title="Process disequalities from the arrangement for model generation.">refineCounterExample</a>();
<a name="l00328"></a>00328   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ab0be6755fcb152cd582d064663e2d53f" title="Assign concrete values to basic-type variables in v.">computeModelBasic</a>(<span class="keyword">const</span> std::vector&lt;Expr&gt;&amp; v);
<a name="l00329"></a>00329   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ab89a3988c04c44852823fa598358ab67" title="Compute the value of a compound variable from the more primitive ones.">computeModel</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e, std::vector&lt;Expr&gt;&amp; vars);
<a name="l00330"></a>00330   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a966afeabb8016841de17f5c51fe165a0" title="Check for satisfiability in the theory.">checkSat</a>(<span class="keywordtype">bool</span> fullEffort);
<a name="l00331"></a>00331   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a17c6d2694c44f77da17d5b32620b0761" title="Theory-specific rewrite rules.">rewrite</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00332"></a>00332   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#af876aaea3321dd03faebd5f4b3f06ddd" title="Set up the term e for call-backs when e or its children change.">setup</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00333"></a>00333   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a314a1422f7fb05eb90d94cd88625fd0c" title="Notify a theory of a new equality.">update</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; e, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; d);
<a name="l00334"></a>00334   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a9488a6be1041e63a9519482ac7e854c8" title="An optional solver.">solve</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; e);
<a name="l00335"></a>00335   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a331a6d4320eee82cbb093fd587c96bb8" title="A debug check used by the primary solver.">checkAssertEqInvariant</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; e);
<a name="l00336"></a>00336   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ad3e9ede8154ffafbbfdefef3c79d5f78" title="Check that e is a valid Type expr.">checkType</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00337"></a>00337   <a class="code" href="namespaceCVC3.html#af969e724f8b7016909f5804e8cea3e54" title="Enum for cardinality of types.">Cardinality</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ae22b1b370ee8be1c54ef4a1c3f527d5f" title="Compute information related to finiteness of types.">finiteTypeInfo</a>(<a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e, <a class="code" href="classCVC3_1_1Unsigned.html">Unsigned</a>&amp; n,
<a name="l00338"></a>00338                              <span class="keywordtype">bool</span> enumerate, <span class="keywordtype">bool</span> computeSize);
<a name="l00339"></a>00339   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ae15e9cc1e826299a857a232c341402c1" title="Compute and store the type of e.">computeType</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00340"></a>00340   <a class="code" href="classCVC3_1_1Type.html" title="MS C++ specific settings.">Type</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#adaecdd481476e8db3e400a1bcecf25f3" title="Compute the base type of the top-level operator of an arbitrary type.">computeBaseType</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Type.html" title="MS C++ specific settings.">Type</a>&amp; t);
<a name="l00341"></a>00341   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a30991bcd4bbcf65cd1c6215725af9899" title="Add variables from &#39;e&#39; to &#39;v&#39; for constructing a concrete model.">computeModelTerm</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e, std::vector&lt;Expr&gt;&amp; v);
<a name="l00342"></a>00342   <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a5c1f93e8fcd10c7943895532cf0aa6f6" title="Theory specific computation of the subtyping predicate for type t applied to the expression e...">computeTypePred</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Type.html" title="MS C++ specific settings.">Type</a>&amp; t, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00343"></a>00343   <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a6f507fbe5ded9976e290274059611808" title="Compute and cache the TCC of e.">computeTCC</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00344"></a>00344   <a class="code" href="classCVC3_1_1ExprStream.html" title="Pretty-printing output stream for Expr. READ THE DOCS BEFORE USING!">ExprStream</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld.html#a887b53a4c32e7daab34048bdfe2a31c4" title="Theory-specific pretty-printing.">print</a>(<a class="code" href="classCVC3_1_1ExprStream.html" title="Pretty-printing output stream for Expr. READ THE DOCS BEFORE USING!">ExprStream</a>&amp; os, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00345"></a>00345   <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ae4d0208af0078ee314c94f199f8b50db" title="Theory-specific parsing implemented by the DP.">parseExprOp</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00346"></a>00346 
<a name="l00347"></a>00347 <span class="keyword">private</span>:
<a name="l00348"></a>00348 <span class="comment"></span>
<a name="l00349"></a>00349 <span class="comment">  /** Map from variables to the maximal (by absolute value) of one of it&#39;s coefficients */</span>
<a name="l00350"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a9600791c28f5e0d0cfd79c8eb025f5e3">00350</a>   <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;Rational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a9600791c28f5e0d0cfd79c8eb025f5e3">maxCoefficientLeft</a>;
<a name="l00351"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a667bd1e22b3275a0c8544e29bd8fe613">00351</a>   <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;Rational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a667bd1e22b3275a0c8544e29bd8fe613">maxCoefficientRight</a>;
<a name="l00352"></a>00352 <span class="comment"></span>
<a name="l00353"></a>00353 <span class="comment">  /** Map from variables to the fixed value of one of it&#39;s coefficients */</span>
<a name="l00354"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#afc337545f540e2e3301cfaa0ff240c29">00354</a>   <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;Rational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#afc337545f540e2e3301cfaa0ff240c29">fixedMaxCoefficient</a>;
<a name="l00355"></a>00355 <span class="comment"></span>
<a name="l00356"></a>00356 <span class="comment">  /**</span>
<a name="l00357"></a>00357 <span class="comment">   * Returns the current maximal coefficient of the variable.</span>
<a name="l00358"></a>00358 <span class="comment">   *</span>
<a name="l00359"></a>00359 <span class="comment">   * @param var the variable.</span>
<a name="l00360"></a>00360 <span class="comment">   */</span>
<a name="l00361"></a>00361   <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a44ca4928fb45298b5d5586c8b509fba3">currentMaxCoefficient</a>(<a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> var);
<a name="l00362"></a>00362 <span class="comment"></span>
<a name="l00363"></a>00363 <span class="comment">  /**</span>
<a name="l00364"></a>00364 <span class="comment">   * Fixes the current max coefficient to be used in the ordering. If the maximal coefficient</span>
<a name="l00365"></a>00365 <span class="comment">   * changes in the future, it will not be used in the ordering.</span>
<a name="l00366"></a>00366 <span class="comment">   *</span>
<a name="l00367"></a>00367 <span class="comment">   * @param variable the variable</span>
<a name="l00368"></a>00368 <span class="comment">   * @param max the value to set it to</span>
<a name="l00369"></a>00369 <span class="comment">   */</span>
<a name="l00370"></a>00370   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a7bb41aa46d0caeecb89a534fc9c359af">fixCurrentMaxCoefficient</a>(<a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> variable, <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="namespaceCVC3.html#a03dcd07dcbd01da970af13f1dfc5e2dd">max</a>);
<a name="l00371"></a>00371 <span class="comment"></span>
<a name="l00372"></a>00372 <span class="comment">  /**</span>
<a name="l00373"></a>00373 <span class="comment">   * Among given input variables, select the smallest ones with respect to the coefficients.</span>
<a name="l00374"></a>00374 <span class="comment">   */</span>
<a name="l00375"></a>00375   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a86f96d920118d4b8c7b6bf78bb6ee740">selectSmallestByCoefficient</a>(<span class="keyword">const</span> std::vector&lt;Expr&gt;&amp; input, std::vector&lt;Expr&gt;&amp; output);
<a name="l00376"></a>00376 <span class="comment"></span>
<a name="l00377"></a>00377 <span class="comment">  /**</span>
<a name="l00378"></a>00378 <span class="comment">   * Given an inequality theorem check if it is on integers and get rid of the non-integer</span>
<a name="l00379"></a>00379 <span class="comment">   * constants.</span>
<a name="l00380"></a>00380 <span class="comment">   */</span>
<a name="l00381"></a>00381   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aea59b6a8576bd484d6bcede8363e4076">rafineInequalityToInteger</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm);
<a name="l00382"></a>00382 <span class="comment"></span>
<a name="l00383"></a>00383 <span class="comment">  /**</span>
<a name="l00384"></a>00384 <span class="comment">   * Given an equality theorem check if it is on integers with a non-integer constant. If</span>
<a name="l00385"></a>00385 <span class="comment">   * yes, return a theorem 0 = 1</span>
<a name="l00386"></a>00386 <span class="comment">   */</span>
<a name="l00387"></a>00387   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1b75e191eff379114ec4ad4e73c73610">checkIntegerEquality</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; thm);
<a name="l00388"></a>00388 <span class="comment"></span>
<a name="l00389"></a>00389 <span class="comment">  /** Keep the expressions that are already in the buffer */</span>
<a name="l00390"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#ad1514cc33619de965117a48c4e3ea342">00390</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ad1514cc33619de965117a48c4e3ea342">bufferedInequalities</a>;
<a name="l00391"></a>00391 <span class="comment"></span>
<a name="l00392"></a>00392 <span class="comment">  /** Strict lower bounds on terms, so that we don&#39;t add inequalities to the buffer */</span>
<a name="l00393"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a14047821f94566b7a46950d1f6529332">00393</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, Rational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a14047821f94566b7a46950d1f6529332">termLowerBound</a>;
<a name="l00394"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#ab6d69b6422585056ed9ce55777d04590">00394</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ab6d69b6422585056ed9ce55777d04590">termLowerBoundThm</a>;<span class="comment"></span>
<a name="l00395"></a>00395 <span class="comment">  /** Strict upper bounds on terms, so that we don&#39;t add inequalities to the buffer */</span>
<a name="l00396"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a45ed4c2833167e036dbf682c8bd06e72">00396</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, Rational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a45ed4c2833167e036dbf682c8bd06e72">termUpperBound</a>;
<a name="l00397"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a21dd22e840f352a67dc6be3472a2bb5a">00397</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a21dd22e840f352a67dc6be3472a2bb5a">termUpperBoundThm</a>;
<a name="l00398"></a>00398 <span class="comment"></span>
<a name="l00399"></a>00399 <span class="comment">  /**</span>
<a name="l00400"></a>00400 <span class="comment">   * Which inequalities have already been projected (on which monomial).</span>
<a name="l00401"></a>00401 <span class="comment">   *  - if we get an update of an inequality that&#39;s not been projected, we don&#39;t care</span>
<a name="l00402"></a>00402 <span class="comment">   *    it will get projected (it&#39;s find)</span>
<a name="l00403"></a>00403 <span class="comment">   *  - when projecting, project the finds, not the originals</span>
<a name="l00404"></a>00404 <span class="comment">   *  - when done projecting add here, both original and the find</span>
<a name="l00405"></a>00405 <span class="comment">   */</span>
<a name="l00406"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a079cb45bf44fab2325badc15ec92c4e4">00406</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, Expr&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a079cb45bf44fab2325badc15ec92c4e4">alreadyProjected</a>;
<a name="l00407"></a>00407 <span class="comment"></span>
<a name="l00408"></a>00408 <span class="comment">  /**</span>
<a name="l00409"></a>00409 <span class="comment">   * Sometimes we know an inequality is in the buffer (as a find of something) and</span>
<a name="l00410"></a>00410 <span class="comment">   * we don&#39;t want it in the buffer, but we do want to pre-process it, so we put it</span>
<a name="l00411"></a>00411 <span class="comment">   * here.</span>
<a name="l00412"></a>00412 <span class="comment">   */</span>
<a name="l00413"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a939e94398d23870f3a43fc0d7067b581">00413</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a939e94398d23870f3a43fc0d7067b581">dontBuffer</a>;
<a name="l00414"></a>00414 <span class="comment"></span>
<a name="l00415"></a>00415 <span class="comment">  /**</span>
<a name="l00416"></a>00416 <span class="comment">   * Are we doing only difference logic?</span>
<a name="l00417"></a>00417 <span class="comment">   */</span>
<a name="l00418"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#affd5f1260775159e8b6b01783f3cfb9b">00418</a>   <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#affd5f1260775159e8b6b01783f3cfb9b">diffLogicOnly</a>;
<a name="l00419"></a>00419 <span class="comment"></span>
<a name="l00420"></a>00420 <span class="comment">  /**</span>
<a name="l00421"></a>00421 <span class="comment">   * Takes an inequality theorem and substitutes the rhs for it&#39;s find. It also get&#39;s normalized.</span>
<a name="l00422"></a>00422 <span class="comment">   */</span>
<a name="l00423"></a>00423   <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a83f995b3176a7faffae2a5fcd5c2386f">inequalityToFind</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; inequalityThm, <span class="keywordtype">bool</span> normalizeRHS);
<a name="l00424"></a>00424 
<a name="l00425"></a>00425   <span class="comment">// x -y &lt;= c</span>
<a name="l00426"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1GraphEdge.html">00426</a>   <span class="keyword">struct </span><a class="code" href="structCVC3_1_1TheoryArithOld_1_1GraphEdge.html">GraphEdge</a> {
<a name="l00427"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1GraphEdge.html#a29c75d397eed6fce817a5f0ade28bc2f">00427</a>     <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1GraphEdge.html#a29c75d397eed6fce817a5f0ade28bc2f">x</a>;
<a name="l00428"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1GraphEdge.html#aa65c3d91d67305d116c590cbdbf494e5">00428</a>     <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1GraphEdge.html#aa65c3d91d67305d116c590cbdbf494e5">y</a>;
<a name="l00429"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1GraphEdge.html#a5086804cdf1608a14617d314a254bfc0">00429</a>     <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1GraphEdge.html#a5086804cdf1608a14617d314a254bfc0">c</a>;
<a name="l00430"></a>00430   };
<a name="l00431"></a>00431 <span class="comment"></span>
<a name="l00432"></a>00432 <span class="comment">  /**</span>
<a name="l00433"></a>00433 <span class="comment">   * Take inequality of the form 0 op t and extract the c1, t1, c2 and t2, such that</span>
<a name="l00434"></a>00434 <span class="comment">   * c1 &lt;= t1 and t2 &lt;= c2, where c1 and c2 are constants, and t1 and t2 are either</span>
<a name="l00435"></a>00435 <span class="comment">   * sums of monomials or a monomial.</span>
<a name="l00436"></a>00436 <span class="comment">   *</span>
<a name="l00437"></a>00437 <span class="comment">   * @return the number of variables in terms t1 and t2</span>
<a name="l00438"></a>00438 <span class="comment">   */</span>
<a name="l00439"></a>00439   <span class="keywordtype">int</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a3244505fc75c1ef822b445c266da5bb5">extractTermsFromInequality</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; inequality,
<a name="l00440"></a>00440       <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; c1, <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t1,
<a name="l00441"></a>00441       <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; c2, <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t2);
<a name="l00442"></a>00442 
<a name="l00443"></a>00443   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ad4d5973db0c0b0d26e358450b0c0a4a1" title="Theory-specific registration of atoms.">registerAtom</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00444"></a>00444 
<a name="l00445"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a46d5c29d89249608a80159a17ef5c794">00445</a>   <span class="keyword">typedef</span> <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt; std::set&lt; std::pair&lt;Rational, Expr&gt;</a> &gt; &gt; <a class="code" href="classCVC3_1_1TheoryArithOld.html#a46d5c29d89249608a80159a17ef5c794">AtomsMap</a>;
<a name="l00446"></a>00446 <span class="comment"></span>
<a name="l00447"></a>00447 <span class="comment">  /** Map from terms to their lower bound (and the original formula expression) */</span>
<a name="l00448"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#af353ec3abe3d512a90dc8b83a28ccfb5">00448</a>   <a class="code" href="classCVC3_1_1ExprMap.html">AtomsMap</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#af353ec3abe3d512a90dc8b83a28ccfb5">formulaAtomLowerBound</a>;
<a name="l00449"></a>00449 <span class="comment"></span>
<a name="l00450"></a>00450 <span class="comment">  /** Map from terms to their upper bound (and the original formula expression) */</span>
<a name="l00451"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#af6089a946fd9248a222bd3a83d2e4478">00451</a>   <a class="code" href="classCVC3_1_1ExprMap.html">AtomsMap</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#af6089a946fd9248a222bd3a83d2e4478">formulaAtomUpperBound</a>;
<a name="l00452"></a>00452 <span class="comment"></span>
<a name="l00453"></a>00453 <span class="comment">  /** Map of all the atoms in the formula */</span>
<a name="l00454"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a1c52c54bc6c46167e0526723128c0e72">00454</a>   <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1c52c54bc6c46167e0526723128c0e72">formulaAtoms</a>;
<a name="l00455"></a>00455 
<a name="l00456"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html">00456</a>   <span class="keyword">class </span><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html">DifferenceLogicGraph</a> {
<a name="l00457"></a>00457 
<a name="l00458"></a>00458     <span class="keyword">public</span>:
<a name="l00459"></a>00459 <span class="comment"></span>
<a name="l00460"></a>00460 <span class="comment">      /**</span>
<a name="l00461"></a>00461 <span class="comment">         * EpsRational class ecapsulates the rationals with a symbolic small \f$\epsilon\f$ added. Each rational</span>
<a name="l00462"></a>00462 <span class="comment">         * number is presented as a pair \f$(q, k) = q + k\epsilon\f$, where \f$\epsilon\f$ is treated symbolically.</span>
<a name="l00463"></a>00463 <span class="comment">         * The operations on the new rationals are defined as</span>
<a name="l00464"></a>00464 <span class="comment">         * &lt;ul&gt;</span>
<a name="l00465"></a>00465 <span class="comment">         *  &lt;li&gt;\f$(q_1, k_1) + (q_2, k_2) \equiv (q_1 + q_2, k_1 + k_2)\f$</span>
<a name="l00466"></a>00466 <span class="comment">         *  &lt;li&gt;\f$a \times (q, k) \equiv (a \times q, a \times k)\f$</span>
<a name="l00467"></a>00467 <span class="comment">         *  &lt;li&gt;\f$(q_1, k_1) \leq (q_2, k_2) \equiv (q_1 &lt; q_2) \vee (q_1 = q_2 \wedge k_1 \leq k_2)\f$</span>
<a name="l00468"></a>00468 <span class="comment">         * &lt;/ul&gt;</span>
<a name="l00469"></a>00469 <span class="comment">         *</span>
<a name="l00470"></a>00470 <span class="comment">         * Note that the operations on the infinite values are not defined, as they are never used currently. Infinities can</span>
<a name="l00471"></a>00471 <span class="comment">         * only be asigned or compared.</span>
<a name="l00472"></a>00472 <span class="comment">         */</span>
<a name="l00473"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">00473</a>         <span class="keyword">class </span><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> {
<a name="l00474"></a>00474 
<a name="l00475"></a>00475           <span class="keyword">protected</span>:
<a name="l00476"></a>00476 <span class="comment"></span>
<a name="l00477"></a>00477 <span class="comment">            /** Type of rationals, normal and the two infinities */</span>
<a name="l00478"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74">00478</a>             <span class="keyword">typedef</span> <span class="keyword">enum</span> { <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74a5635f96de4ed27208b064451e41de217">PLUS_INFINITY</a>, <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74a4eacb58629f24f0d9fff053b4e59b157">MINUS_INFINITY</a> } <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74">RationalType</a>;
<a name="l00479"></a>00479 <span class="comment"></span>
<a name="l00480"></a>00480 <span class="comment">            /** The type of this rational */</span>
<a name="l00481"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">00481</a>             <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74">RationalType</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>;
<a name="l00482"></a>00482 <span class="comment"></span>
<a name="l00483"></a>00483 <span class="comment">            /** The rational part */</span>
<a name="l00484"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">00484</a>             <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>;
<a name="l00485"></a>00485 <span class="comment"></span>
<a name="l00486"></a>00486 <span class="comment">            /** The epsilon multiplier */</span>
<a name="l00487"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">00487</a>             <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>;
<a name="l00488"></a>00488 <span class="comment"></span>
<a name="l00489"></a>00489 <span class="comment">            /**</span>
<a name="l00490"></a>00490 <span class="comment">             * Private constructor to construt infinities.</span>
<a name="l00491"></a>00491 <span class="comment">             */</span>
<a name="l00492"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#abdaddd8c6b8cbd64f45bcb224bb9121f">00492</a>             <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#abdaddd8c6b8cbd64f45bcb224bb9121f">EpsRational</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74">RationalType</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>) : type(type) {}
<a name="l00493"></a>00493 
<a name="l00494"></a>00494           <span class="keyword">public</span>:
<a name="l00495"></a>00495 <span class="comment"></span>
<a name="l00496"></a>00496 <span class="comment">            /**</span>
<a name="l00497"></a>00497 <span class="comment">             * Returns if the numbe is finite.</span>
<a name="l00498"></a>00498 <span class="comment">             */</span>
<a name="l00499"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a2ea79c3dbd9dea07a508a86fbc9765eb">00499</a>             <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a2ea79c3dbd9dea07a508a86fbc9765eb">isFinite</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>; }
<a name="l00500"></a>00500 <span class="comment"></span>
<a name="l00501"></a>00501 <span class="comment">            /**</span>
<a name="l00502"></a>00502 <span class="comment">             * Returns if the number is a plain rational.</span>
<a name="l00503"></a>00503 <span class="comment">             *</span>
<a name="l00504"></a>00504 <span class="comment">             * @return true if rational, false otherwise</span>
<a name="l00505"></a>00505 <span class="comment">             */</span>
<a name="l00506"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a71939f44b6d1eb7d222e156247d03960">00506</a>             <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a71939f44b6d1eb7d222e156247d03960">isRational</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> == 0; }
<a name="l00507"></a>00507 <span class="comment"></span>
<a name="l00508"></a>00508 <span class="comment">            /**</span>
<a name="l00509"></a>00509 <span class="comment">             * Returns if the number is a plain integer.</span>
<a name="l00510"></a>00510 <span class="comment">             *</span>
<a name="l00511"></a>00511 <span class="comment">             * @return true if rational, false otherwise</span>
<a name="l00512"></a>00512 <span class="comment">             */</span>
<a name="l00513"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aec7b157edba8fe5e836612a6ad8e172c">00513</a>             <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aec7b157edba8fe5e836612a6ad8e172c">isInteger</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> == 0 &amp;&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>.<a class="code" href="classCVC3_1_1Rational.html#a1366320f4de558bb964c67f8aecedb36">isInteger</a>(); }
<a name="l00514"></a>00514 <span class="comment"></span>
<a name="l00515"></a>00515 <span class="comment">            /**</span>
<a name="l00516"></a>00516 <span class="comment">             * Returns the floor of the number \f$x = q + k \epsilon\f$ using the following fomula</span>
<a name="l00517"></a>00517 <span class="comment">             * \f[</span>
<a name="l00518"></a>00518 <span class="comment">             * \lfloor \beta(x) \rfloor =</span>
<a name="l00519"></a>00519 <span class="comment">             * \begin{cases}</span>
<a name="l00520"></a>00520 <span class="comment">             * \lfloor q \rfloor &amp; \text{ if } q \notin Z\\</span>
<a name="l00521"></a>00521 <span class="comment">             * q &amp; \text{ if } q \in Z \text{ and } k \geq 0\\</span>
<a name="l00522"></a>00522 <span class="comment">             * q - 1 &amp; \text{ if } q \in Z \text{ and } k &lt; 0</span>
<a name="l00523"></a>00523 <span class="comment">             * \end{cases}</span>
<a name="l00524"></a>00524 <span class="comment">             * \f]</span>
<a name="l00525"></a>00525 <span class="comment">             */</span>
<a name="l00526"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a55f41fc5860343b40b281cd09eac04fd">00526</a>             <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a55f41fc5860343b40b281cd09eac04fd">getFloor</a>()<span class="keyword"> const </span>{
<a name="l00527"></a>00527               <span class="keywordflow">if</span> (<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>.<a class="code" href="classCVC3_1_1Rational.html#a1366320f4de558bb964c67f8aecedb36">isInteger</a>()) {
<a name="l00528"></a>00528                 <span class="keywordflow">if</span> (<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> &gt;= 0) <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>;
<a name="l00529"></a>00529                 <span class="keywordflow">else</span> <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> - 1;
<a name="l00530"></a>00530               } <span class="keywordflow">else</span>
<a name="l00531"></a>00531                 <span class="comment">// If not an integer, just floor it</span>
<a name="l00532"></a>00532                 <span class="keywordflow">return</span> floor(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>);
<a name="l00533"></a>00533             }
<a name="l00534"></a>00534 
<a name="l00535"></a>00535 <span class="comment"></span>
<a name="l00536"></a>00536 <span class="comment">          /**</span>
<a name="l00537"></a>00537 <span class="comment">           * Returns the rational part of the number</span>
<a name="l00538"></a>00538 <span class="comment">           *</span>
<a name="l00539"></a>00539 <span class="comment">           * @return the rational</span>
<a name="l00540"></a>00540 <span class="comment">           */</span>
<a name="l00541"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a2671721c731f2cb89597309d8f29c126">00541</a>           <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a2671721c731f2cb89597309d8f29c126">getRational</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>; }
<a name="l00542"></a>00542 <span class="comment"></span>
<a name="l00543"></a>00543 <span class="comment">          /**</span>
<a name="l00544"></a>00544 <span class="comment">           * Returns the epsilon part of the number</span>
<a name="l00545"></a>00545 <span class="comment">           *</span>
<a name="l00546"></a>00546 <span class="comment">           * @return the epsilon</span>
<a name="l00547"></a>00547 <span class="comment">           */</span>
<a name="l00548"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab55123f8c208dfa60371d03214b49f5b">00548</a>           <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab55123f8c208dfa60371d03214b49f5b">getEpsilon</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>; }
<a name="l00549"></a>00549 <span class="comment"></span>
<a name="l00550"></a>00550 <span class="comment">          /** The infinity constant */</span>
<a name="l00551"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a3d192df722ff4601388f73a86d6e5688">00551</a>           <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a3d192df722ff4601388f73a86d6e5688">PlusInfinity</a>;<span class="comment"></span>
<a name="l00552"></a>00552 <span class="comment">          /** The negative infinity constant */</span>
<a name="l00553"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ac14d641b6833b74bbfe14590b596b713">00553</a>           <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ac14d641b6833b74bbfe14590b596b713">MinusInfinity</a>;<span class="comment"></span>
<a name="l00554"></a>00554 <span class="comment">          /** The zero constant */</span>
<a name="l00555"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ae1ce8777ef94c7efa4d2b5962ccb2743">00555</a>           <span class="keyword">static</span> <span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ae1ce8777ef94c7efa4d2b5962ccb2743">Zero</a>;
<a name="l00556"></a>00556 
<a name="l00557"></a>00557 <span class="comment"></span>
<a name="l00558"></a>00558 <span class="comment">          /** The blank constructor */</span>
<a name="l00559"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab8f5740e7c716878bdaa24431fbda7f0">00559</a>           <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab8f5740e7c716878bdaa24431fbda7f0">EpsRational</a>() : <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>), <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>(0), <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>(0) {}
<a name="l00560"></a>00560 <span class="comment"></span>
<a name="l00561"></a>00561 <span class="comment">          /** Copy constructor */</span>
<a name="l00562"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ad0858791e56bb14856166b4411e14e74">00562</a>           <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ad0858791e56bb14856166b4411e14e74">EpsRational</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; r) : <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>(r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>), <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>(r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>), <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>(r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>) {}
<a name="l00563"></a>00563 <span class="comment"></span>
<a name="l00564"></a>00564 <span class="comment">            /**</span>
<a name="l00565"></a>00565 <span class="comment">             * Constructor from a rational, constructs a new pair (q, 0).</span>
<a name="l00566"></a>00566 <span class="comment">             *</span>
<a name="l00567"></a>00567 <span class="comment">             * @param q the rational</span>
<a name="l00568"></a>00568 <span class="comment">             */</span>
<a name="l00569"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a9921b126c93470b0b18d1ffcd0acb33b">00569</a>           <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a9921b126c93470b0b18d1ffcd0acb33b">EpsRational</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>) : <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>), q(q), <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>(0) {}
<a name="l00570"></a>00570 <span class="comment"></span>
<a name="l00571"></a>00571 <span class="comment">            /**</span>
<a name="l00572"></a>00572 <span class="comment">             * Constructor from a rational and a given epsilon multiplier, constructs a</span>
<a name="l00573"></a>00573 <span class="comment">             * new pair (q, k).</span>
<a name="l00574"></a>00574 <span class="comment">             *</span>
<a name="l00575"></a>00575 <span class="comment">             * @param q the rational</span>
<a name="l00576"></a>00576 <span class="comment">             * @param k the epsilon multiplier</span>
<a name="l00577"></a>00577 <span class="comment">             */</span>
<a name="l00578"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa83e886379c54a2863424e12a43af2d3">00578</a>           <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa83e886379c54a2863424e12a43af2d3">EpsRational</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>) : <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>), q(q), k(k) {}
<a name="l00579"></a>00579 <span class="comment"></span>
<a name="l00580"></a>00580 <span class="comment">            /**</span>
<a name="l00581"></a>00581 <span class="comment">             * Addition operator for two EpsRational numbers.</span>
<a name="l00582"></a>00582 <span class="comment">             *</span>
<a name="l00583"></a>00583 <span class="comment">             * @param r the number to be added</span>
<a name="l00584"></a>00584 <span class="comment">             * @return the sum as defined in the class</span>
<a name="l00585"></a>00585 <span class="comment">             */</span>
<a name="l00586"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#af53abe1350e18dbcecc8e3c229e446af">00586</a>             <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#af53abe1350e18dbcecc8e3c229e446af">operator + </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; r)<span class="keyword"> const </span>{
<a name="l00587"></a>00587               <a class="code" href="debug_8h.html#a40dac3bdb2166ffc852ee8b1489d2b56">DebugAssert</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <span class="stringliteral">&quot;EpsRational::operator +, adding to infinite number&quot;</span>);
<a name="l00588"></a>00588               <a class="code" href="debug_8h.html#a40dac3bdb2166ffc852ee8b1489d2b56">DebugAssert</a>(r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <span class="stringliteral">&quot;EpsRational::operator +, adding an infinite number&quot;</span>);
<a name="l00589"></a>00589               <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab8f5740e7c716878bdaa24431fbda7f0">EpsRational</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> + r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>, <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> + r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>);
<a name="l00590"></a>00590             }
<a name="l00591"></a>00591 <span class="comment"></span>
<a name="l00592"></a>00592 <span class="comment">            /**</span>
<a name="l00593"></a>00593 <span class="comment">             * Addition operator for two EpsRational numbers.</span>
<a name="l00594"></a>00594 <span class="comment">             *</span>
<a name="l00595"></a>00595 <span class="comment">             * @param r the number to be added</span>
<a name="l00596"></a>00596 <span class="comment">             * @return the sum as defined in the class</span>
<a name="l00597"></a>00597 <span class="comment">             */</span>
<a name="l00598"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a92b8fab3da6185c869f2855ae7cbbe22">00598</a>             <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a92b8fab3da6185c869f2855ae7cbbe22">operator += </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; r) {
<a name="l00599"></a>00599               <a class="code" href="debug_8h.html#a40dac3bdb2166ffc852ee8b1489d2b56">DebugAssert</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <span class="stringliteral">&quot;EpsRational::operator +, adding to infinite number&quot;</span>);
<a name="l00600"></a>00600               <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> = <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> + r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>;
<a name="l00601"></a>00601               <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> = <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> + r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>;
<a name="l00602"></a>00602               <span class="keywordflow">return</span> *<span class="keyword">this</span>;
<a name="l00603"></a>00603             }
<a name="l00604"></a>00604 <span class="comment"></span>
<a name="l00605"></a>00605 <span class="comment">            /**</span>
<a name="l00606"></a>00606 <span class="comment">             * Subtraction operator for two EpsRational numbers.</span>
<a name="l00607"></a>00607 <span class="comment">             *</span>
<a name="l00608"></a>00608 <span class="comment">             * @param r the number to be added</span>
<a name="l00609"></a>00609 <span class="comment">             * @return the sum as defined in the class</span>
<a name="l00610"></a>00610 <span class="comment">             */</span>
<a name="l00611"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#abee1a63a51553904910401f29e1f0191">00611</a>             <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aeb1573d79d6de3ed029d1f0c14e029d6">operator - </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; r)<span class="keyword"> const </span>{
<a name="l00612"></a>00612             <a class="code" href="debug_8h.html#a40dac3bdb2166ffc852ee8b1489d2b56">DebugAssert</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <span class="stringliteral">&quot;EpsRational::operator -, subtracting from infinite number&quot;</span>);
<a name="l00613"></a>00613               <a class="code" href="debug_8h.html#a40dac3bdb2166ffc852ee8b1489d2b56">DebugAssert</a>(r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <span class="stringliteral">&quot;EpsRational::operator -, subtracting an infinite number&quot;</span>);
<a name="l00614"></a>00614               <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab8f5740e7c716878bdaa24431fbda7f0">EpsRational</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> - r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>, <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> - r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>);
<a name="l00615"></a>00615             }
<a name="l00616"></a>00616 <span class="comment"></span>
<a name="l00617"></a>00617 <span class="comment">            /**</span>
<a name="l00618"></a>00618 <span class="comment">             * Unary minus operator</span>
<a name="l00619"></a>00619 <span class="comment">             */</span>
<a name="l00620"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aeb1573d79d6de3ed029d1f0c14e029d6">00620</a>             <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aeb1573d79d6de3ed029d1f0c14e029d6">operator - </a>() {
<a name="l00621"></a>00621             <a class="code" href="debug_8h.html#a40dac3bdb2166ffc852ee8b1489d2b56">DebugAssert</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <span class="stringliteral">&quot;EpsRational::operator -, subtracting from infinite number&quot;</span>);
<a name="l00622"></a>00622               <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> = -<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>;
<a name="l00623"></a>00623               <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> = -<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>;
<a name="l00624"></a>00624             <span class="keywordflow">return</span> *<span class="keyword">this</span>;
<a name="l00625"></a>00625             }
<a name="l00626"></a>00626 
<a name="l00627"></a>00627 <span class="comment"></span>
<a name="l00628"></a>00628 <span class="comment">            /**</span>
<a name="l00629"></a>00629 <span class="comment">             * Multiplication operator EpsRational number and a rational number.</span>
<a name="l00630"></a>00630 <span class="comment">             *</span>
<a name="l00631"></a>00631 <span class="comment">             * @param a the number to be multiplied</span>
<a name="l00632"></a>00632 <span class="comment">             * @return the product as defined in the class</span>
<a name="l00633"></a>00633 <span class="comment">             */</span>
<a name="l00634"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab15673fa29db64d9f1c65183d4aacf25">00634</a>             <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab15673fa29db64d9f1c65183d4aacf25">operator * </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; a)<span class="keyword"> const </span>{
<a name="l00635"></a>00635             <a class="code" href="debug_8h.html#a40dac3bdb2166ffc852ee8b1489d2b56">DebugAssert</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <span class="stringliteral">&quot;EpsRational::operator *, multiplying an infinite number&quot;</span>);
<a name="l00636"></a>00636               <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab8f5740e7c716878bdaa24431fbda7f0">EpsRational</a>(a * <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>, a * <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>);
<a name="l00637"></a>00637             }
<a name="l00638"></a>00638 <span class="comment"></span>
<a name="l00639"></a>00639 <span class="comment">            /**</span>
<a name="l00640"></a>00640 <span class="comment">             * Division operator EpsRational number and a rational number.</span>
<a name="l00641"></a>00641 <span class="comment">             *</span>
<a name="l00642"></a>00642 <span class="comment">             * @param a the number to be multiplied</span>
<a name="l00643"></a>00643 <span class="comment">             * @return the product as defined in the class</span>
<a name="l00644"></a>00644 <span class="comment">             */</span>
<a name="l00645"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#abe61a27081bbd13e06137ec89a5ef6a0">00645</a>             <span class="keyword">inline</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#abe61a27081bbd13e06137ec89a5ef6a0">operator / </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; a)<span class="keyword"> const </span>{
<a name="l00646"></a>00646             <a class="code" href="debug_8h.html#a40dac3bdb2166ffc852ee8b1489d2b56">DebugAssert</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>, <span class="stringliteral">&quot;EpsRational::operator *, dividing an infinite number&quot;</span>);
<a name="l00647"></a>00647               <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab8f5740e7c716878bdaa24431fbda7f0">EpsRational</a>(<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> / a, <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> / a);
<a name="l00648"></a>00648             }
<a name="l00649"></a>00649 <span class="comment"></span>
<a name="l00650"></a>00650 <span class="comment">            /**</span>
<a name="l00651"></a>00651 <span class="comment">             * Equality comparison operator.</span>
<a name="l00652"></a>00652 <span class="comment">             */</span>
<a name="l00653"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa98afb0b7a7b93880ddcba67d27d6d25">00653</a>             <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa98afb0b7a7b93880ddcba67d27d6d25">operator == </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; r)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> (<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> == r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> &amp;&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> == r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>); }
<a name="l00654"></a>00654 <span class="comment"></span>
<a name="l00655"></a>00655 <span class="comment">            /**</span>
<a name="l00656"></a>00656 <span class="comment">             * Less than or equal comparison operator.</span>
<a name="l00657"></a>00657 <span class="comment">             */</span>
<a name="l00658"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab640ed0967cd2f77be917eaeb956397c">00658</a>             <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#ab640ed0967cd2f77be917eaeb956397c">operator &lt;= </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; r)<span class="keyword"> const </span>{
<a name="l00659"></a>00659               <span class="keywordflow">switch</span> (r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>) {
<a name="l00660"></a>00660                 <span class="keywordflow">case</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>:
<a name="l00661"></a>00661                   <span class="keywordflow">if</span> (<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>)
<a name="l00662"></a>00662                     <span class="comment">// Normal comparison</span>
<a name="l00663"></a>00663                     <span class="keywordflow">return</span> (<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> &lt; r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> || (<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> == r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a> &amp;&amp; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a> &lt;= r.<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>));
<a name="l00664"></a>00664                   <span class="keywordflow">else</span>
<a name="l00665"></a>00665                     <span class="comment">// Finite number is bigger only of the negative infinity</span>
<a name="l00666"></a>00666                     <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74a4eacb58629f24f0d9fff053b4e59b157">MINUS_INFINITY</a>;
<a name="l00667"></a>00667                 <span class="keywordflow">case</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74a5635f96de4ed27208b064451e41de217">PLUS_INFINITY</a>:
<a name="l00668"></a>00668                   <span class="comment">// Everything is less then or equal than +inf</span>
<a name="l00669"></a>00669                   <span class="keywordflow">return</span> <span class="keyword">true</span>;
<a name="l00670"></a>00670                 <span class="keywordflow">case</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74a4eacb58629f24f0d9fff053b4e59b157">MINUS_INFINITY</a>:
<a name="l00671"></a>00671                   <span class="comment">// Only -inf is less then or equal than -inf</span>
<a name="l00672"></a>00672                   <span class="keywordflow">return</span> (<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a> == <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74a4eacb58629f24f0d9fff053b4e59b157">MINUS_INFINITY</a>);
<a name="l00673"></a>00673                 <span class="keywordflow">default</span>:
<a name="l00674"></a>00674                   <span class="comment">// Ohohohohohoooooo, whats up</span>
<a name="l00675"></a>00675                   <a class="code" href="debug_8h.html#a2637b2fffa22e3c9fad40cda8fcc3bce" title="If something goes horribly wrong, print a message and abort immediately with exit(1).">FatalAssert</a>(<span class="keyword">false</span>, <span class="stringliteral">&quot;EpsRational::operator &lt;=, what kind of number is this????&quot;</span>);
<a name="l00676"></a>00676               }
<a name="l00677"></a>00677               <span class="keywordflow">return</span> <span class="keyword">false</span>;
<a name="l00678"></a>00678             }
<a name="l00679"></a>00679 <span class="comment"></span>
<a name="l00680"></a>00680 <span class="comment">            /**</span>
<a name="l00681"></a>00681 <span class="comment">             * Less than comparison operator.</span>
<a name="l00682"></a>00682 <span class="comment">             */</span>
<a name="l00683"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a46d7f98e8e46cc830f0c203dc2a8203b">00683</a>             <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a46d7f98e8e46cc830f0c203dc2a8203b">operator &lt; </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; r)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> !(r &lt;= *<span class="keyword">this</span>); }
<a name="l00684"></a>00684 <span class="comment"></span>
<a name="l00685"></a>00685 <span class="comment">            /**</span>
<a name="l00686"></a>00686 <span class="comment">             * Greater than comparison operator.</span>
<a name="l00687"></a>00687 <span class="comment">             */</span>
<a name="l00688"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a2b5bb6577fc2666a1d86ae0b952f86b0">00688</a>             <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a2b5bb6577fc2666a1d86ae0b952f86b0">operator &gt; </a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a>&amp; r)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> !(*<span class="keyword">this</span> &lt;= r); }
<a name="l00689"></a>00689 <span class="comment"></span>
<a name="l00690"></a>00690 <span class="comment">            /**</span>
<a name="l00691"></a>00691 <span class="comment">             * Returns the string representation of the number.</span>
<a name="l00692"></a>00692 <span class="comment">             *</span>
<a name="l00693"></a>00693 <span class="comment">             * @return the string representation of the number</span>
<a name="l00694"></a>00694 <span class="comment">             */</span>
<a name="l00695"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a1110ac3ff3fb7eaf983fee4eaf55ca1a">00695</a>             std::string <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a1110ac3ff3fb7eaf983fee4eaf55ca1a">toString</a>()<span class="keyword"> const </span>{
<a name="l00696"></a>00696               <span class="keywordflow">switch</span> (<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a81035cdf522e4137f99009fba8cb83b7">type</a>) {
<a name="l00697"></a>00697                 <span class="keywordflow">case</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74abda7e127ed5d0e69e640cf2a0e8d5858">FINITE</a>:
<a name="l00698"></a>00698                   <span class="keywordflow">return</span> <span class="stringliteral">&quot;(&quot;</span> + <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a6715d83cae6edc671e535bfb3d077e02">q</a>.<a class="code" href="classCVC3_1_1Rational.html#a195c125a76cb9a6c5731369e244a2de3">toString</a>() + <span class="stringliteral">&quot;, &quot;</span> + <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#aa4a6bafa0b3918c2c2468b9ed504f377">k</a>.<a class="code" href="classCVC3_1_1Rational.html#a195c125a76cb9a6c5731369e244a2de3">toString</a>() + <span class="stringliteral">&quot;)&quot;</span>;
<a name="l00699"></a>00699                 <span class="keywordflow">case</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74a5635f96de4ed27208b064451e41de217">PLUS_INFINITY</a>:
<a name="l00700"></a>00700                   <span class="keywordflow">return</span> <span class="stringliteral">&quot;+inf&quot;</span>;
<a name="l00701"></a>00701                 <span class="keywordflow">case</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a7b4bb9732cc1238494e2c695d2604d74a4eacb58629f24f0d9fff053b4e59b157">MINUS_INFINITY</a>:
<a name="l00702"></a>00702                   <span class="keywordflow">return</span> <span class="stringliteral">&quot;-inf&quot;</span>;
<a name="l00703"></a>00703                 <span class="keywordflow">default</span>:
<a name="l00704"></a>00704                   <a class="code" href="debug_8h.html#a2637b2fffa22e3c9fad40cda8fcc3bce" title="If something goes horribly wrong, print a message and abort immediately with exit(1).">FatalAssert</a>(<span class="keyword">false</span>, <span class="stringliteral">&quot;EpsRational::toString, what kind of number is this????&quot;</span>);
<a name="l00705"></a>00705               }
<a name="l00706"></a>00706               <span class="keywordflow">return</span> <span class="stringliteral">&quot;hm, what am I?&quot;</span>;
<a name="l00707"></a>00707             }
<a name="l00708"></a>00708         };
<a name="l00709"></a>00709 
<a name="l00710"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html">00710</a>       <span class="keyword">struct </span><a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html">EdgeInfo</a> {<span class="comment"></span>
<a name="l00711"></a>00711 <span class="comment">        /** The length of this edge */</span>
<a name="l00712"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#aacfd7ef36363077df6b0d5faac531e0b">00712</a>         <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html">EpsRational</a> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#aacfd7ef36363077df6b0d5faac531e0b">length</a>;<span class="comment"></span>
<a name="l00713"></a>00713 <span class="comment">        /** The number of edges in this path */</span>
<a name="l00714"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a500b599007e1e83551547889ded5749d">00714</a>         <span class="keywordtype">int</span> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a500b599007e1e83551547889ded5749d">path_length_in_edges</a>;<span class="comment"></span>
<a name="l00715"></a>00715 <span class="comment">        /** If this is a summary edge, a vertex in the path */</span>
<a name="l00716"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a0909dd104ddc044ad9b30bcf0ca78b60">00716</a>         <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a0909dd104ddc044ad9b30bcf0ca78b60">in_path_vertex</a>;<span class="comment"></span>
<a name="l00717"></a>00717 <span class="comment">        /** If this is an original edge, the theorem that explains it */</span>
<a name="l00718"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a419e01286cfbb41d0b53d97325221e84">00718</a>         <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a419e01286cfbb41d0b53d97325221e84">explanation</a>;
<a name="l00719"></a>00719 <span class="comment"></span>
<a name="l00720"></a>00720 <span class="comment">        /** Returnes if the edge is well define (i.e. not +infinity) */</span>
<a name="l00721"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a132b032333ba966af300e49fc0824530">00721</a>         <span class="keywordtype">bool</span> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a132b032333ba966af300e49fc0824530">isDefined</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> <a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a500b599007e1e83551547889ded5749d">path_length_in_edges</a> != 0; }
<a name="l00722"></a>00722 
<a name="l00723"></a><a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#ad524363377728fb88304c6c7fa0f2223">00723</a>         <a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#ad524363377728fb88304c6c7fa0f2223">EdgeInfo</a>(): <a class="code" href="structCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EdgeInfo.html#a500b599007e1e83551547889ded5749d">path_length_in_edges</a>(0) {}
<a name="l00724"></a>00724       };
<a name="l00725"></a>00725 <span class="comment"></span>
<a name="l00726"></a>00726 <span class="comment">      /**</span>
<a name="l00727"></a>00727 <span class="comment">       * Given two vertices in the graph and an path edge, reconstruct all the theorems and put them</span>
<a name="l00728"></a>00728 <span class="comment">       * in the output vector</span>
<a name="l00729"></a>00729 <span class="comment">       */</span>
<a name="l00730"></a>00730       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a58d23191bab044554e42ba0dd7f110de">getEdgeTheorems</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; y, <span class="keyword">const</span> EdgeInfo&amp; edgeInfo, std::vector&lt;Theorem&gt;&amp; outputTheorems);
<a name="l00731"></a>00731 <span class="comment"></span>
<a name="l00732"></a>00732 <span class="comment">      /**</span>
<a name="l00733"></a>00733 <span class="comment">       * Returns the current weight of the edge.</span>
<a name="l00734"></a>00734 <span class="comment">       */</span>
<a name="l00735"></a>00735       EpsRational <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a70441880fa7ecde30265c3ec83f7e11d">getEdgeWeight</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; y);
<a name="l00736"></a>00736 <span class="comment"></span>
<a name="l00737"></a>00737 <span class="comment">      /**</span>
<a name="l00738"></a>00738 <span class="comment">       * Returns whether a vertex has incoming edges.</span>
<a name="l00739"></a>00739 <span class="comment">       */</span>
<a name="l00740"></a>00740       <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a33e10dce7990aaeedd588663c308c416">hasIncoming</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x);
<a name="l00741"></a>00741 <span class="comment"></span>
<a name="l00742"></a>00742 <span class="comment">      /**</span>
<a name="l00743"></a>00743 <span class="comment">       * Returns whether a vertex has outgoing edges.</span>
<a name="l00744"></a>00744 <span class="comment">       */</span>
<a name="l00745"></a>00745       <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a63b4374516dfa8f7c87de61b460dcf12">hasOutgoing</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x);
<a name="l00746"></a>00746 
<a name="l00747"></a>00747     <span class="keyword">protected</span>:
<a name="l00748"></a>00748 <span class="comment"></span>
<a name="l00749"></a>00749 <span class="comment">      /** Threshold on path length to process (ignore bigger than and set incomplete) */</span>
<a name="l00750"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae4ed3f0c509c959d36e6637371bf6e05">00750</a>       <span class="keyword">const</span> <span class="keywordtype">int</span>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae4ed3f0c509c959d36e6637371bf6e05">d_pathLenghtThres</a>;
<a name="l00751"></a>00751 <span class="comment"></span>
<a name="l00752"></a>00752 <span class="comment">      /** The arithmetic that&#39;s using this graph */</span>
<a name="l00753"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae172261f15e4d9903b4147b6ee1f4523">00753</a>       <a class="code" href="classCVC3_1_1TheoryArithOld.html">TheoryArithOld</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae172261f15e4d9903b4147b6ee1f4523">arith</a>;
<a name="l00754"></a>00754 <span class="comment"></span>
<a name="l00755"></a>00755 <span class="comment">      /** The core theory */</span>
<a name="l00756"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a6bf38051f1bc2b0703e6ba8ca3b765ae">00756</a>       <a class="code" href="classCVC3_1_1TheoryCore.html" title="This theory handles the built-in logical connectives plus equality. It also handles the registration ...">TheoryCore</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a6bf38051f1bc2b0703e6ba8ca3b765ae">core</a>;
<a name="l00757"></a>00757 <span class="comment"></span>
<a name="l00758"></a>00758 <span class="comment">      /** The arithmetic that is using u us */</span>
<a name="l00759"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#acbbd4a2fbba125d1069f124e5c271826">00759</a>       <a class="code" href="classCVC3_1_1ArithProofRules.html">ArithProofRules</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#acbbd4a2fbba125d1069f124e5c271826">rules</a>;
<a name="l00760"></a>00760 <span class="comment"></span>
<a name="l00761"></a>00761 <span class="comment">      /** The unsat theorem if available */</span>
<a name="l00762"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a627796132ea73d35fbcf828d68425a3b">00762</a>       <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;Theorem&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a627796132ea73d35fbcf828d68425a3b">unsat_theorem</a>;
<a name="l00763"></a>00763 <span class="comment"></span>
<a name="l00764"></a>00764 <span class="comment">      /** The biggest epsilon from EpsRational we used in paths */</span>
<a name="l00765"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae4d498b950e7b37b5b48c936139cfc70">00765</a>       <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;Rational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae4d498b950e7b37b5b48c936139cfc70">biggestEpsilon</a>;
<a name="l00766"></a>00766 <span class="comment"></span>
<a name="l00767"></a>00767 <span class="comment">      /** The smallest rational difference we used in path relaxation */</span>
<a name="l00768"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a2519a13732d48786f8fe83351a7150c8">00768</a>       <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;Rational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a2519a13732d48786f8fe83351a7150c8">smallestPathDifference</a>;
<a name="l00769"></a>00769 <span class="comment"></span>
<a name="l00770"></a>00770 <span class="comment">      /** The graph itself, maps expressions (x-y) to the edge information */</span>
<a name="l00771"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#abed3971d17b5d311101715558f879558">00771</a>       <span class="keyword">typedef</span> <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, EdgeInfo&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#abed3971d17b5d311101715558f879558">Graph</a>;
<a name="l00772"></a>00772 <span class="comment"></span>
<a name="l00773"></a>00773 <span class="comment">      /** Graph of &lt;= paths */</span>
<a name="l00774"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a47342aafbf5caa7aca2fbd5e9511cef1">00774</a>       <a class="code" href="classCVC3_1_1CDMap.html">Graph</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a47342aafbf5caa7aca2fbd5e9511cef1">leGraph</a>;
<a name="l00775"></a>00775 
<a name="l00776"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a0ceb7ab88e1c7ec4b29ddd7c8214e1c9">00776</a>       <span class="keyword">typedef</span> <a class="code" href="classCVC3_1_1ExprMap.html">ExprMap&lt;CDList&lt;Expr&gt;</a>*&gt; <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a0ceb7ab88e1c7ec4b29ddd7c8214e1c9">EdgesList</a>;
<a name="l00777"></a>00777 <span class="comment"></span>
<a name="l00778"></a>00778 <span class="comment">      /** List of vertices adjacent backwards to a vertex */</span>
<a name="l00779"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a6a605397e227cc5b9c287984ead0902b">00779</a>       <a class="code" href="classCVC3_1_1ExprMap.html">EdgesList</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a6a605397e227cc5b9c287984ead0902b">incomingEdges</a>;<span class="comment"></span>
<a name="l00780"></a>00780 <span class="comment">      /** List of vertices adjacent forward to a vertex */</span>
<a name="l00781"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ac0fa1b22e8ed0d8d0580599998b36bf2">00781</a>       <a class="code" href="classCVC3_1_1ExprMap.html">EdgesList</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ac0fa1b22e8ed0d8d0580599998b36bf2">outgoingEdges</a>;
<a name="l00782"></a>00782 <span class="comment"></span>
<a name="l00783"></a>00783 <span class="comment">      /**</span>
<a name="l00784"></a>00784 <span class="comment">       * Returns the edge (path) info for the given kind</span>
<a name="l00785"></a>00785 <span class="comment">       *</span>
<a name="l00786"></a>00786 <span class="comment">       * @param x the starting vertex</span>
<a name="l00787"></a>00787 <span class="comment">       * @param y the ending vertex</span>
<a name="l00788"></a>00788 <span class="comment">       * @return the edge information</span>
<a name="l00789"></a>00789 <span class="comment">       */</span>
<a name="l00790"></a>00790       <a class="code" href="classCVC3_1_1CDOmap.html">Graph::ElementReference</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a16b2a3042303dce733abadbec2a86ee1">getEdge</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; y);
<a name="l00791"></a>00791 <span class="comment"></span>
<a name="l00792"></a>00792 <span class="comment">      /**</span>
<a name="l00793"></a>00793 <span class="comment">       * Try to update the shortest path from x to z using y.</span>
<a name="l00794"></a>00794 <span class="comment">       */</span>
<a name="l00795"></a>00795       <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a62c681d767c2100a822db1f86ebabaf2">tryUpdate</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; y, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; z);
<a name="l00796"></a>00796 
<a name="l00797"></a>00797     <span class="keyword">public</span>:
<a name="l00798"></a>00798 
<a name="l00799"></a>00799       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae9325d9bce63e5a62cce23d4aac2db32">writeGraph</a>(std::ostream&amp; out);
<a name="l00800"></a>00800 <span class="comment"></span>
<a name="l00801"></a>00801 <span class="comment">      /**</span>
<a name="l00802"></a>00802 <span class="comment">       * Fills the vector with all the variables (vertices) in the graph</span>
<a name="l00803"></a>00803 <span class="comment">       */</span>
<a name="l00804"></a>00804       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a4266a410f71d5536394188cd74034b18">getVariables</a>(std::vector&lt;Expr&gt;&amp; variables);
<a name="l00805"></a>00805 
<a name="l00806"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ac13ef29f1852dd0d157b52bdfc050737">00806</a>       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ac13ef29f1852dd0d157b52bdfc050737">setRules</a>(<a class="code" href="classCVC3_1_1ArithProofRules.html">ArithProofRules</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#acbbd4a2fbba125d1069f124e5c271826">rules</a>) {
<a name="l00807"></a>00807         this-&gt;rules = <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#acbbd4a2fbba125d1069f124e5c271826">rules</a>;
<a name="l00808"></a>00808       }
<a name="l00809"></a>00809 
<a name="l00810"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a5b2e50e6e3c75743ace5bb2fae432449">00810</a>       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a5b2e50e6e3c75743ace5bb2fae432449">setArith</a>(<a class="code" href="classCVC3_1_1TheoryArithOld.html">TheoryArithOld</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae172261f15e4d9903b4147b6ee1f4523">arith</a>) {
<a name="l00811"></a>00811         this-&gt;arith = <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae172261f15e4d9903b4147b6ee1f4523">arith</a>;
<a name="l00812"></a>00812       }
<a name="l00813"></a>00813 <span class="comment"></span>
<a name="l00814"></a>00814 <span class="comment">      /**</span>
<a name="l00815"></a>00815 <span class="comment">       * Class constructor.</span>
<a name="l00816"></a>00816 <span class="comment">       */</span>
<a name="l00817"></a>00817       <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a0014118b800ec0cce12b84a3b8c921d1">DifferenceLogicGraph</a>(<a class="code" href="classCVC3_1_1TheoryArithOld.html">TheoryArithOld</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae172261f15e4d9903b4147b6ee1f4523">arith</a>, <a class="code" href="classCVC3_1_1TheoryCore.html" title="This theory handles the built-in logical connectives plus equality. It also handles the registration ...">TheoryCore</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a6bf38051f1bc2b0703e6ba8ca3b765ae">core</a>, <a class="code" href="classCVC3_1_1ArithProofRules.html">ArithProofRules</a>* <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#acbbd4a2fbba125d1069f124e5c271826">rules</a>, <a class="code" href="classCVC3_1_1Context.html">Context</a>* context);
<a name="l00818"></a>00818 <span class="comment"></span>
<a name="l00819"></a>00819 <span class="comment">      /**</span>
<a name="l00820"></a>00820 <span class="comment">       * Destructor</span>
<a name="l00821"></a>00821 <span class="comment">       */</span>
<a name="l00822"></a>00822       <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a9ff61777e5df7bc75f9879a6a9f75419">~DifferenceLogicGraph</a>();
<a name="l00823"></a>00823 <span class="comment"></span>
<a name="l00824"></a>00824 <span class="comment">      /**</span>
<a name="l00825"></a>00825 <span class="comment">       * Returns the reference to the unsat theorem if there is a negative</span>
<a name="l00826"></a>00826 <span class="comment">       * cycle in the graph.</span>
<a name="l00827"></a>00827 <span class="comment">       *</span>
<a name="l00828"></a>00828 <span class="comment">       * @return the unsat theorem</span>
<a name="l00829"></a>00829 <span class="comment">       */</span>
<a name="l00830"></a>00830 
<a name="l00831"></a>00831       <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a216bfac9dcbcc62b7097d51fd91e8ac8">getUnsatTheorem</a>();
<a name="l00832"></a>00832 <span class="comment"></span>
<a name="l00833"></a>00833 <span class="comment">      /**</span>
<a name="l00834"></a>00834 <span class="comment">       * Returns true if there is a negative cycle in the graph.</span>
<a name="l00835"></a>00835 <span class="comment">       */</span>
<a name="l00836"></a>00836       <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a828bb2ad8fc3c36506f6a8f3ca38579c">isUnsat</a>();
<a name="l00837"></a>00837 
<a name="l00838"></a>00838       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ae7f9ea562c26f55a0536a5cd85cf07b0">computeModel</a>();
<a name="l00839"></a>00839 
<a name="l00840"></a>00840       <a class="code" href="classCVC3_1_1Rational.html">Rational</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a22cd1525ea447a3bc839fc737240eb4f">getValuation</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x);
<a name="l00841"></a>00841 
<a name="l00842"></a>00842 <span class="comment"></span>
<a name="l00843"></a>00843 <span class="comment">      /**</span>
<a name="l00844"></a>00844 <span class="comment">       * Adds an edge corresponding to the constraint x - y &lt;= c.</span>
<a name="l00845"></a>00845 <span class="comment">       *</span>
<a name="l00846"></a>00846 <span class="comment">       * @param x variable x::Difference</span>
<a name="l00847"></a>00847 <span class="comment">       * @param y variable y</span>
<a name="l00848"></a>00848 <span class="comment">       * @param c rational c</span>
<a name="l00849"></a>00849 <span class="comment">       * @param edge_thm the theorem for this edge</span>
<a name="l00850"></a>00850 <span class="comment">       */</span>
<a name="l00851"></a>00851       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#acdd072f244d1d30d5b954bf7b0debe04">addEdge</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; y, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; c, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; edge_thm);
<a name="l00852"></a>00852 <span class="comment"></span>
<a name="l00853"></a>00853 <span class="comment">      /**</span>
<a name="l00854"></a>00854 <span class="comment">       * Check if there is an edge from x to y</span>
<a name="l00855"></a>00855 <span class="comment">       */</span>
<a name="l00856"></a>00856       <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a2213f2040667750f9878aa0ce3ba3f17">existsEdge</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; y);
<a name="l00857"></a>00857 <span class="comment"></span>
<a name="l00858"></a>00858 <span class="comment">      /**</span>
<a name="l00859"></a>00859 <span class="comment">       * Check if x is in a cycle</span>
<a name="l00860"></a>00860 <span class="comment">       */</span>
<a name="l00861"></a>00861       <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a75eceef3b27aa29d23d26ac2a624d095">inCycle</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x);
<a name="l00862"></a>00862 <span class="comment"></span>
<a name="l00863"></a>00863 <span class="comment">      /**</span>
<a name="l00864"></a>00864 <span class="comment">       * Given a shared integer term expand it into the gray shadow on the bounds (if bounded from both sides).</span>
<a name="l00865"></a>00865 <span class="comment">       */</span>
<a name="l00866"></a>00866       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a247245c8102db8596b73c76cf015fc5d">expandSharedTerm</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x);
<a name="l00867"></a>00867 
<a name="l00868"></a>00868     <span class="keyword">protected</span>:
<a name="l00869"></a>00869 <span class="comment"></span>
<a name="l00870"></a>00870 <span class="comment">      /** Whether the variable is in a cycle */</span>
<a name="l00871"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a478a837c6562772e151cbfef55e607ee">00871</a>       <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a478a837c6562772e151cbfef55e607ee">varInCycle</a>;
<a name="l00872"></a>00872 
<a name="l00873"></a><a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a7b0dd9d1e47d917391c0ed987608bb57">00873</a>       <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#a7b0dd9d1e47d917391c0ed987608bb57">sourceVertex</a>;
<a name="l00874"></a>00874 <span class="comment"></span>
<a name="l00875"></a>00875 <span class="comment">      /**</span>
<a name="l00876"></a>00876 <span class="comment">       * Produced the unsat theorem from a cycle x --&gt; x of negative length</span>
<a name="l00877"></a>00877 <span class="comment">       *</span>
<a name="l00878"></a>00878 <span class="comment">       * @param x the variable to use for the conflict</span>
<a name="l00879"></a>00879 <span class="comment">       * @param kind the kind of edges to consider</span>
<a name="l00880"></a>00880 <span class="comment">       */</span>
<a name="l00881"></a>00881       <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html#ad101bbc763a37fb902e4df4a654351de">analyseConflict</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x, <span class="keywordtype">int</span> kind);
<a name="l00882"></a>00882   };
<a name="l00883"></a>00883 <span class="comment"></span>
<a name="l00884"></a>00884 <span class="comment">  /** The graph for difference logic */</span>
<a name="l00885"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a1dda0fccac36ffbebc06beb58e404619">00885</a>   <a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph.html">DifferenceLogicGraph</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1dda0fccac36ffbebc06beb58e404619">diffLogicGraph</a>;
<a name="l00886"></a>00886 
<a name="l00887"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a5aef4b094054e928a145c5b9ee5703d1">00887</a>   <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a5aef4b094054e928a145c5b9ee5703d1">zero</a>;
<a name="l00888"></a>00888 <span class="comment"></span>
<a name="l00889"></a>00889 <span class="comment">  /** Index for expanding on shared term equalities */</span>
<a name="l00890"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#adecf2614be23bfd1347e1992081e7848">00890</a>   <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;unsigned&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#adecf2614be23bfd1347e1992081e7848">shared_index_1</a>;<span class="comment"></span>
<a name="l00891"></a>00891 <span class="comment">  /** Index for expanding on shared term equalities */</span>
<a name="l00892"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a4a63d7abe48efcd5262bdec8d2a48ebf">00892</a>   <a class="code" href="classCVC3_1_1CDO.html">CDO&lt;unsigned&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a4a63d7abe48efcd5262bdec8d2a48ebf">shared_index_2</a>;
<a name="l00893"></a>00893 
<a name="l00894"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#ab9e74bfc121f8d683449540b3f47648d">00894</a>   std::vector&lt;Theorem&gt; <a class="code" href="classCVC3_1_1TheoryArithOld.html#ab9e74bfc121f8d683449540b3f47648d">multiplicativeSignSplits</a>;
<a name="l00895"></a>00895 
<a name="l00896"></a>00896   <span class="keywordtype">int</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a878f9a4ecf6d87a79f37e9e916750d4c">termDegree</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00897"></a>00897 
<a name="l00898"></a>00898   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aaa7f3188301a696b421577f2c8059a46">canPickEqMonomial</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; <a class="code" href="namespaceMiniSat.html#a82558b7a36c52f5d3211d5d14bed99d4">right</a>);
<a name="l00899"></a>00899 
<a name="l00900"></a>00900 <span class="keyword">private</span>:
<a name="l00901"></a>00901 
<a name="l00902"></a>00902   <span class="comment">// Keeps all expressions that are bounded for disequality splitting and shared term comparisons</span>
<a name="l00903"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#ae3f7689542dd29298e68dcc16e5976e6">00903</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, DifferenceLogicGraph::EpsRational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ae3f7689542dd29298e68dcc16e5976e6">termUpperBounded</a>;
<a name="l00904"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#aa3cbd03caf1f931c74829f2502d75553">00904</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, DifferenceLogicGraph::EpsRational&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aa3cbd03caf1f931c74829f2502d75553">termLowerBounded</a>;
<a name="l00905"></a>00905 
<a name="l00906"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a1dbba6d20d053083679893b4f79998a8">00906</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1dbba6d20d053083679893b4f79998a8">d_varConstrainedPlus</a>;
<a name="l00907"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#acb4e673f7c27347289317a35a376f82d">00907</a>         <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#acb4e673f7c27347289317a35a376f82d">d_varConstrainedMinus</a>;
<a name="l00908"></a>00908 
<a name="l00909"></a>00909   <span class="comment">// Keeps all expressions that are constrained</span>
<a name="l00910"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#afd5889bc69bdde0f39137619db945c80">00910</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#afd5889bc69bdde0f39137619db945c80">termConstrainedBelow</a>;
<a name="l00911"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a8c0a52d514303b34e73fc36803331419">00911</a>   <a class="code" href="classCVC3_1_1CDMap.html">CDMap&lt;Expr, bool&gt;</a> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a8c0a52d514303b34e73fc36803331419">termConstrainedAbove</a>;
<a name="l00912"></a>00912 
<a name="l00913"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">00913</a>   <span class="keyword">enum</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> {<span class="comment"></span>
<a name="l00914"></a>00914 <span class="comment">    /** Query the bounds/constrained using cache for leaves */</span>
<a name="l00915"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">00915</a>     <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>,<span class="comment"></span>
<a name="l00916"></a>00916 <span class="comment">    /** Query the bounds/constrained using cashe for leaves, but also see if the value is constrained */</span>
<a name="l00917"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811a24a2b363efc7f74b482ce52d1957b3bf">00917</a>     <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811a24a2b363efc7f74b482ce52d1957b3bf">QueryWithCacheLeavesAndConstrainedComputation</a>,<span class="comment"></span>
<a name="l00918"></a>00918 <span class="comment">    /** Query the bounds/constrained by only querying the cache, don&#39;t try to figure it out */</span>
<a name="l00919"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811a3a2069125b24eeea4fcd590525d935bc">00919</a>     <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811a3a2069125b24eeea4fcd590525d935bc">QueryWithCacheAll</a>
<a name="l00920"></a>00920   };
<a name="l00921"></a>00921 <span class="comment"></span>
<a name="l00922"></a>00922 <span class="comment">  /**</span>
<a name="l00923"></a>00923 <span class="comment">   * Check if the term is bounded. If the term is non-linear, just returns false.</span>
<a name="l00924"></a>00924 <span class="comment">   */</span>
<a name="l00925"></a>00925   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ad2133967c6b85ec7b144f023b7428afd">isBounded</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> queryType = <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>);
<a name="l00926"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#aa3b6cea5b43872330fab4c92d55a71d0">00926</a>   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aa3b6cea5b43872330fab4c92d55a71d0">hasLowerBound</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> queryType = <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>) { <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1582b7d8a6cfa35a2eb1372408e1d9d1">getLowerBound</a>(t, queryType).<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a2ea79c3dbd9dea07a508a86fbc9765eb">isFinite</a>(); }
<a name="l00927"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a7ec3bcab775ad3248c29c09c4a109a11">00927</a>   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a7ec3bcab775ad3248c29c09c4a109a11">hasUpperBound</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> queryType = <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>) { <span class="keywordflow">return</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a92ebe6beaf47d0b9567b4552e9aabf94">getUpperBound</a>(t, queryType).<a class="code" href="classCVC3_1_1TheoryArithOld_1_1DifferenceLogicGraph_1_1EpsRational.html#a2ea79c3dbd9dea07a508a86fbc9765eb">isFinite</a>(); }
<a name="l00928"></a>00928 
<a name="l00929"></a>00929   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a39d64f6ffb9232db82c4fea6ad6407b3">isConstrained</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <span class="keywordtype">bool</span> intOnly = <span class="keyword">true</span>, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> queryType = <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>);
<a name="l00930"></a>00930   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a31e4ddb10498727798fb49d7dae42312">isConstrainedAbove</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> queryType = <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>);
<a name="l00931"></a>00931   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a9c85d0cd35937c0ae9d343490b470e22">isConstrainedBelow</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> queryType = <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>);
<a name="l00932"></a>00932 <span class="comment"></span>
<a name="l00933"></a>00933 <span class="comment">  /**</span>
<a name="l00934"></a>00934 <span class="comment">   * Check if the term is bounded from above. If the term is non-linear, just returns false.</span>
<a name="l00935"></a>00935 <span class="comment">   */</span>
<a name="l00936"></a>00936   DifferenceLogicGraph::EpsRational <a class="code" href="classCVC3_1_1TheoryArithOld.html#a92ebe6beaf47d0b9567b4552e9aabf94">getUpperBound</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> queryType = <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>);
<a name="l00937"></a>00937 <span class="comment"></span>
<a name="l00938"></a>00938 <span class="comment">  /**</span>
<a name="l00939"></a>00939 <span class="comment">   * Check if the term is bouned from below. If the term is non-linear, just return false.</span>
<a name="l00940"></a>00940 <span class="comment">   */</span>
<a name="l00941"></a>00941   DifferenceLogicGraph::EpsRational <a class="code" href="classCVC3_1_1TheoryArithOld.html#a1582b7d8a6cfa35a2eb1372408e1d9d1">getLowerBound</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t, <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811">BoundsQueryType</a> queryType = <a class="code" href="classCVC3_1_1TheoryArithOld.html#a26c172f0fb2468ba2255c3d5a2c46811acaf2c948bff23c8f1d04da41f12fe574">QueryWithCacheLeaves</a>);
<a name="l00942"></a>00942 <span class="comment"></span>
<a name="l00943"></a>00943 <span class="comment">  /**</span>
<a name="l00944"></a>00944 <span class="comment">   * See whether and which terms are bounded.</span>
<a name="l00945"></a>00945 <span class="comment">   */</span>
<a name="l00946"></a>00946   <span class="keywordtype">int</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a0a9d00e2c2f734aec6d76a52cf301bc4">computeTermBounds</a>();
<a name="l00947"></a>00947 
<a name="l00948"></a>00948 <span class="keyword">public</span>:
<a name="l00949"></a>00949 
<a name="l00950"></a>00950   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#abc26aaf78f6b9a25b3c5f3923719ddb7">updateConstrained</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t);
<a name="l00951"></a>00951   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a820f1ace7a5dd9e962b2453ceb1bcaf1">isUnconstrained</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; t);
<a name="l00952"></a>00952 
<a name="l00953"></a>00953   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#af26f1b31629fe94f3678e4d051b17afa">tryPropagate</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; x, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; y, <span class="keyword">const</span> DifferenceLogicGraph::EdgeInfo&amp; x_y_edge, <span class="keywordtype">int</span> kind);
<a name="l00954"></a>00954 
<a name="l00955"></a>00955   <span class="keywordtype">void</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a0f6143643b36835a5383acfa65252f3e">addMultiplicativeSignSplit</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Theorem.html">Theorem</a>&amp; case_split_thm);
<a name="l00956"></a>00956 
<a name="l00957"></a>00957   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a7cc81a1017de4d7e2c7278dfc01a4e60">addPairToArithOrder</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; smaller, <span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; bigger);
<a name="l00958"></a>00958 
<a name="l00959"></a><a class="code" href="classCVC3_1_1TheoryArithOld.html#a372a7ff635b9de24607daa04d3a63d02">00959</a>   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a372a7ff635b9de24607daa04d3a63d02">nonlinearSignSplit</a>()<span class="keyword"> const </span>{ <span class="keywordflow">return</span> *<a class="code" href="classCVC3_1_1TheoryArithOld.html#a7cee71daa7f8f8bbd33d0b6a333f61aa">d_splitSign</a>; }
<a name="l00960"></a>00960 <span class="comment"></span>
<a name="l00961"></a>00961 <span class="comment">  /**</span>
<a name="l00962"></a>00962 <span class="comment">   * Check if equation is nonlinear. An equation is nonlinear if there is at least one nonlinear term in the sum</span>
<a name="l00963"></a>00963 <span class="comment">   * on either side of the equation.</span>
<a name="l00964"></a>00964 <span class="comment">   */</span>
<a name="l00965"></a>00965   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#ab8686f11885fd196e2d0e592f767ba76">isNonlinearEq</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; e);
<a name="l00966"></a>00966 <span class="comment"></span>
<a name="l00967"></a>00967 <span class="comment">  /**</span>
<a name="l00968"></a>00968 <span class="comment">   * Check if a sum term is nonlinear</span>
<a name="l00969"></a>00969 <span class="comment">   */</span>
<a name="l00970"></a>00970   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#aadfdf8251af6c3a07baa5e8ee0828146">isNonlinearSumTerm</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; term);
<a name="l00971"></a>00971 <span class="comment"></span>
<a name="l00972"></a>00972 <span class="comment">  /**</span>
<a name="l00973"></a>00973 <span class="comment">   * Check if the equality is of the form c + power1^n - power2^n = 0;</span>
<a name="l00974"></a>00974 <span class="comment">   */</span>
<a name="l00975"></a>00975   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#a3eebb5aa899590483a0e9f8223599051">isPowersEquality</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; nonlinearEq, <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; power1, <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; power2);
<a name="l00976"></a>00976 <span class="comment"></span>
<a name="l00977"></a>00977 <span class="comment">  /**</span>
<a name="l00978"></a>00978 <span class="comment">   * Check if the equality is of the form c - x^n = 0</span>
<a name="l00979"></a>00979 <span class="comment">   */</span>
<a name="l00980"></a>00980   <span class="keywordtype">bool</span> <a class="code" href="classCVC3_1_1TheoryArithOld.html#af99992fce594e9940305e0121eb0b45c">isPowerEquality</a>(<span class="keyword">const</span> <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; nonlinearEq, <a class="code" href="classCVC3_1_1Rational.html">Rational</a>&amp; constant, <a class="code" href="classCVC3_1_1Expr.html" title="Data structure of expressions in CVC3.">Expr</a>&amp; power1);
<a name="l00981"></a>00981 
<a name="l00982"></a>00982 };
<a name="l00983"></a>00983 
<a name="l00984"></a>00984 }
<a name="l00985"></a>00985 
<a name="l00986"></a>00986 <span class="preprocessor">#endif</span>
</pre></div></div>
</div>
<hr class="footer"/><address class="footer"><small>Generated on Wed Sep 7 2011 for CVC3 by&#160;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.4 </small></address>
</body>
</html>