41a890b11c34aa14c86cf13535d69bea5b824b7a
[ginac.git] / ginac / flags.h
1 /** @file flags.h
2  *
3  *  Collection of all flags used through the GiNaC framework. */
4
5 /*
6  *  GiNaC Copyright (C) 1999-2000 Johannes Gutenberg University Mainz, Germany
7  *
8  *  This program is free software; you can redistribute it and/or modify
9  *  it under the terms of the GNU General Public License as published by
10  *  the Free Software Foundation; either version 2 of the License, or
11  *  (at your option) any later version.
12  *
13  *  This program is distributed in the hope that it will be useful,
14  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16  *  GNU General Public License for more details.
17  *
18  *  You should have received a copy of the GNU General Public License
19  *  along with this program; if not, write to the Free Software
20  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
21  */
22
23 #ifndef __GINAC_FLAGS_H__
24 #define __GINAC_FLAGS_H__
25
26 #ifndef NO_NAMESPACE_GINAC
27 namespace GiNaC {
28 #endif // ndef NO_NAMESPACE_GINAC
29
30 class expand_options {
31 public:
32     enum { expand_trigonometric      = 0x0001
33          };
34 };
35
36 class series_options {
37 public:
38     enum { suppress_branchcut        = 0x0001
39          };
40 };
41
42 class determinant_algo {
43 public:
44     enum { automatic,
45            gauss,
46            laplace,
47            bareiss
48          };
49 };
50
51 class status_flags {
52 public:
53     enum { dynallocated              = 0x0001,
54            evaluated                 = 0x0002,
55            expanded                  = 0x0004,
56            hash_calculated           = 0x0008
57          };
58 };
59
60 /** Possible attributes an object can have. */
61 class info_flags {
62 public:
63     enum {
64            // answered by class numeric
65            numeric,
66            real,
67            rational,
68            integer,
69            crational,
70            cinteger,
71            positive,
72            negative,
73            nonnegative,
74            posint,
75            negint,
76            nonnegint,
77            even,
78            odd,
79            prime,
80            
81            // answered by class relation
82            relation,
83            relation_equal,
84            relation_not_equal,
85            relation_less,
86            relation_less_or_equal,
87            relation_greater,
88            relation_greater_or_equal,
89            
90            // answered by class symbol
91            symbol,
92            
93            // answered by class lst
94            list,
95            
96            // answered by class exprseq
97            exprseq,
98            
99            // answered by classes numeric, symbol, add, mul, power
100            polynomial,
101            integer_polynomial,
102            cinteger_polynomial,
103            rational_polynomial,
104            crational_polynomial,
105            rational_function,
106            algebraic,
107            
108            // answered by class indexed
109            indexed,      // class can carry indices
110            has_indices,  // object has at least one index
111            
112            // answered by class idx
113            idx,
114            
115            // answered by class coloridx
116            coloridx,
117            
118            // answered by class lorentzidx
119            lorentzidx
120     };
121 };
122
123 class return_types {
124 public:
125     enum { commutative, noncommutative, noncommutative_composite};
126 };
127
128 class csrc_types {
129 public:
130         enum {
131                 ctype_float,
132                 ctype_double,
133                 ctype_cl_N
134         };
135 };
136
137 class remember_strategies {
138 public:
139     enum { delete_never, // let table grow undefinitely, not recommmended, but currently default
140            delete_lru,   // least recently used
141            delete_lfu,   // least frequently used
142            delete_cyclic // first (oldest) one in list
143     };
144 };
145
146 #ifndef NO_NAMESPACE_GINAC
147 } // namespace GiNaC
148 #endif // ndef NO_NAMESPACE_GINAC
149
150 #endif // ndef __GINAC_FLAGS_H__