/home/coin/SVN-release/OS-2.3.2/OS/src/OSCommonInterfaces/OSExpressionTree.h

Go to the documentation of this file.
00001 /* $Id: OSExpressionTree.h 3815 2010-11-03 23:46:16Z Gassmann $ */
00018 #ifndef EXPRESSIONTREE_H
00019 #define EXPRESSIONTREE_H 
00020 
00021 #include "OSnLNode.h"
00022 #include <vector>
00023 #include <map>
00024 
00025 
00035 class OSExpressionTree{  
00036 
00037 public: 
00038         
00042         OSnLNode *m_treeRoot;
00043         
00047         OSExpressionTree();
00048 
00052         ~OSExpressionTree();
00053 
00057         bool IsEqual(OSExpressionTree *that);
00058         
00071         double calculateFunction( double *x, bool new_x);
00072         
00073 
00082         std::vector<OSnLNode*> getPrefixFromExpressionTree();
00083         
00092         std::vector<OSnLNode*> getPostfixFromExpressionTree();
00093         
00094 
00095         
00102         std::map<int, int> *mapVarIdx;
00103         
00112         std::map<int, int> *getVariableIndiciesMap();
00116         bool  m_bIndexMapGenerated;
00117         
00122         bool bADMustReTape;
00123         
00127         bool bDestroyNlNodes;
00128 
00129         
00130 private:
00131         
00132         
00136         double m_dTreeRootValue;
00137         
00138 
00139         
00140 };//end OSExpressionTree
00141 
00142 
00143 
00144 
00145 #endif
00146 

Generated on Fri Jan 7 03:24:38 2011 by  doxygen 1.4.7