COPASI API  4.16.103
CNormalGeneralPower.h
Go to the documentation of this file.
1 // Begin CVS Header
2 // $Source: /Volumes/Home/Users/shoops/cvs/copasi_dev/copasi/compareExpressions/CNormalGeneralPower.h,v $
3 // $Revision: 1.6 $
4 // $Name: $
5 // $Author: gauges $
6 // $Date: 2008/07/07 18:26:49 $
7 // End CVS Header
8 
9 // Copyright (C) 2008 by Pedro Mendes, Virginia Tech Intellectual
10 // Properties, Inc., EML Research, gGmbH, University of Heidelberg,
11 // and The University of Manchester.
12 // All rights reserved.
13 
14 // Copyright (C) 2001 - 2007 by Pedro Mendes, Virginia Tech Intellectual
15 // Properties, Inc. and EML Research, gGmbH.
16 // All rights reserved.
17 
18 #ifndef COPASI_CNormalGeneralPower_H__
19 #define COPASI_CNormalGeneralPower_H__
20 
21 #include <iostream>
22 #include <string>
23 
25 
26 class CNormalFraction;
27 
29  {
30  public:
31  enum Type
32  {
33  POWER = 0,
36  };
37 
38  protected:
42 
43  static const char* SYMBOLS[];
44 
45  public:
48  virtual ~CNormalGeneralPower();
49 
51 
52  bool operator==(const CNormalGeneralPower& rhs) const;
53  bool operator<(const CNormalGeneralPower& rhs) const;
54 
55  virtual CNormalBase * copy() const;
56  virtual bool simplify();
57 
58  virtual std::string toString() const;
59 
61  const CNormalFraction& getLeft() const;
62  void setLeft(const CNormalFraction& left);
64  const CNormalFraction& getRight() const;
65  void setRight(const CNormalFraction& right);
66  Type getType() const;
67  void setType(Type type);
68  bool checkIsOne() const;
69  void multiply(const CNormalGeneralPower& generalPower);
70 
71  /**
72  * Returns a general power that is (1/1)^(1/1).
73  * It creates a new general power of type power and sets the left and right
74  * side to a unit fraction.
75  */
77  };
78 
79 std::ostream& operator<<(std::ostream& os, const CNormalGeneralPower& pow);
80 
81 #endif /* COPASI_CNormalGeneralPower_H__ */
static const char * SYMBOLS[]
CNormalFraction & getLeft()
bool operator==(const CNormalGeneralPower &rhs) const
static CNormalGeneralPower * createUnitGeneralPower()
void multiply(const CNormalGeneralPower &generalPower)
std::ostream & operator<<(std::ostream &os, const CNormalGeneralPower &pow)
CNormalFraction & getRight()
virtual CNormalBase * copy() const
void setRight(const CNormalFraction &right)
CNormalFraction * mpRight
void setLeft(const CNormalFraction &left)
virtual std::string toString() const
bool operator<(const CNormalGeneralPower &rhs) const
CNormalGeneralPower & operator=(const CNormalGeneralPower &src)
CNormalFraction * mpLeft