Constants.h
Go to the documentation of this file.
1 // This file is part of Eigen, a lightweight C++ template library
2 // for linear algebra.
3 //
4 // Copyright (C) 2008-2009 Gael Guennebaud <gael.guennebaud@inria.fr>
5 // Copyright (C) 2007-2009 Benoit Jacob <jacob.benoit.1@gmail.com>
6 //
7 // Eigen is free software; you can redistribute it and/or
8 // modify it under the terms of the GNU Lesser General Public
9 // License as published by the Free Software Foundation; either
10 // version 3 of the License, or (at your option) any later version.
11 //
12 // Alternatively, you can redistribute it and/or
13 // modify it under the terms of the GNU General Public License as
14 // published by the Free Software Foundation; either version 2 of
15 // the License, or (at your option) any later version.
16 //
17 // Eigen is distributed in the hope that it will be useful, but WITHOUT ANY
18 // WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
19 // FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License or the
20 // GNU General Public License for more details.
21 //
22 // You should have received a copy of the GNU Lesser General Public
23 // License and a copy of the GNU General Public License along with
24 // Eigen. If not, see <http://www.gnu.org/licenses/>.
25 
26 #ifndef EIGEN_CONSTANTS_H
27 #define EIGEN_CONSTANTS_H
28 
29 namespace Eigen {
30 
36 const int Dynamic = -1;
37 
41 const int Infinity = -1;
42 
63 const unsigned int RowMajorBit = 0x1;
64 
68 const unsigned int EvalBeforeNestingBit = 0x2;
69 
73 const unsigned int EvalBeforeAssigningBit = 0x4;
74 
91 const unsigned int PacketAccessBit = 0x8;
92 
93 #ifdef EIGEN_VECTORIZE
94 
103 #else
104 const unsigned int ActualPacketAccessBit = 0x0;
105 #endif
106 
127 const unsigned int LinearAccessBit = 0x10;
128 
141 const unsigned int LvalueBit = 0x20;
142 
152 const unsigned int DirectAccessBit = 0x40;
153 
157 const unsigned int AlignedBit = 0x80;
158 
159 const unsigned int NestByRefBit = 0x100;
160 
161 // list of flags that are inherited by default
162 const unsigned int HereditaryBits = RowMajorBit
165 
175 enum {
177  Lower=0x1,
179  Upper=0x2,
181  UnitDiag=0x4,
183  ZeroDiag=0x8,
196 };
197 
200 enum {
205 };
206 
209 // FIXME after the corner() API change, this was not needed anymore, except by AlignedBox
210 // TODO: find out what to do with that. Adapt the AlignedBox API ?
212 
226 };
227 
230 enum {
246 };
247 
250 enum {
258 };
259 
262 enum {
265 };
266 
270 enum {
272  ColMajor = 0,
274  RowMajor = 0x1, // it is only a coincidence that this is equal to RowMajorBit -- don't rely on that
276  AutoAlign = 0, // FIXME --- clarify the situation
278  DontAlign = 0x2
279 };
280 
283 enum {
285  OnTheLeft = 1,
288 };
289 
290 /* the following used to be written as:
291  *
292  * struct NoChange_t {};
293  * namespace {
294  * EIGEN_UNUSED NoChange_t NoChange;
295  * }
296  *
297  * on the ground that it feels dangerous to disambiguate overloaded functions on enum/integer types.
298  * However, this leads to "variable declared but never referenced" warnings on Intel Composer XE,
299  * and we do not know how to get rid of them (bug 450).
300  */
301 
305 
308 enum {
309  IsDense = 0,
311 };
312 
325 };
326 
331  Pivoting = 0x01,
333  NoPivoting = 0x02,
335  ComputeFullU = 0x04,
337  ComputeThinU = 0x08,
339  ComputeFullV = 0x10,
341  ComputeThinV = 0x20,
352  Ax_lBx = 0x100,
355  ABx_lx = 0x200,
358  BAx_lx = 0x400,
361 };
362 
374 };
375 
376 #ifdef Success
377 #error The preprocessor symbol 'Success' is defined, possibly by the X11 header file X.h
378 #endif
379 
384  Success = 0,
392 };
393 
399  Isometry = 0x1,
402  Affine = 0x2,
406  Projective = 0x20
407 };
408 
411 namespace Architecture
412 {
413  enum Type {
414  Generic = 0x0,
415  SSE = 0x1,
416  AltiVec = 0x2,
417 #if defined EIGEN_VECTORIZE_SSE
418  Target = SSE
419 #elif defined EIGEN_VECTORIZE_ALTIVEC
420  Target = AltiVec
421 #else
422  Target = Generic
423 #endif
424  };
425 }
426 
430 
434 
436 struct Dense {};
437 
439 struct MatrixXpr {};
440 
442 struct ArrayXpr {};
443 
444 } // end namespace Eigen
445 
446 #endif // EIGEN_CONSTANTS_H