10#ifndef EIGEN_BLAS_COMMON_H
11#define EIGEN_BLAS_COMMON_H
17# define EIGEN_PERMANENTLY_DISABLE_STUPID_WARNINGS
21#include "../Eigen/Core"
22#include "../Eigen/Jacobi"
27#error the token SCALAR must be defined to compile this file
30#include "../Eigen/src/misc/blas.h"
47#define OP(X) ( ((X)=='N' || (X)=='n') ? NOTR \
48 : ((X)=='T' || (X)=='t') ? TR \
49 : ((X)=='C' || (X)=='c') ? ADJ \
52#define SIDE(X) ( ((X)=='L' || (X)=='l') ? LEFT \
53 : ((X)=='R' || (X)=='r') ? RIGHT \
56#define UPLO(X) ( ((X)=='U' || (X)=='u') ? UP \
57 : ((X)=='L' || (X)=='l') ? LO \
60#define DIAG(X) ( ((X)=='N' || (X)=='n') ? NUNIT \
61 : ((X)=='U' || (X)=='u') ? UNIT \
65inline bool check_op(
const char* op)
70inline bool check_side(
const char* side)
72 return SIDE(*side)!=0xff;
75inline bool check_uplo(
const char* uplo)
77 return UPLO(*uplo)!=0xff;
82#include "BandTriangularSolver.h"
83#include "GeneralRank1Update.h"
84#include "PackedSelfadjointProduct.h"
85#include "PackedTriangularMatrixVector.h"
86#include "PackedTriangularSolverVector.h"
87#include "Rank2Update.h"
94typedef std::complex<RealScalar> Complex;
110matrix(T* data,
int rows,
int cols,
int stride)
117matrix(
const T* data,
int rows,
int cols,
int stride)
147T* get_compact_vector(T* x,
int n,
int incx)
152 typename Eigen::internal::remove_const<T>::type* ret =
new Scalar[n];
153 if(incx<0) make_vector(ret,n) = make_vector(x,n,-incx).reverse();
154 else make_vector(ret,n) = make_vector(x,n, incx);
159T* copy_back(T* x_cpy, T* x,
int n,
int incx)
164 if(incx<0) make_vector(x,n,-incx).reverse() = make_vector(x_cpy,n);
165 else make_vector(x,n, incx) = make_vector(x_cpy,n);
169#ifndef EIGEN_BLAS_FUNC_SUFFIX
170#define EIGEN_BLAS_FUNC_SUFFIX _
173#define EIGEN_BLAS_FUNC(X) EIGEN_CAT(SCALAR_SUFFIX, EIGEN_CAT(X, EIGEN_BLAS_FUNC_SUFFIX))
Convenience specialization of Stride to specify only an inner stride See class Map for some examples.
Definition Stride.h:100
A matrix or vector expression mapping an existing array of data.
Definition Map.h:96
The matrix class, also used for vectors and row-vectors.
Definition Matrix.h:180
Namespace containing all symbols from the Eigen library.
Definition common.h:81
Holds information about the various numeric (i.e. scalar) types allowed by Eigen.
Definition NumTraits.h:233