Fix DLL builds and c++ lapack declarations.

This commit is contained in:
Antonio Sánchez
2025-10-13 16:25:08 +00:00
committed by Rasmus Munk Larsen
parent 3abaabb999
commit e1f1a608be
14 changed files with 725 additions and 123 deletions

View File

@@ -12,7 +12,8 @@
// computes eigen values and vectors of a general N-by-N matrix A
EIGEN_LAPACK_FUNC(syev)
(char* jobz, char* uplo, int* n, Scalar* a, int* lda, Scalar* w, Scalar* /*work*/, int* lwork, int* info) {
(const char* jobz, const char* uplo, int* n, RealScalar* ra, int* lda, RealScalar* rw, RealScalar* /*work*/, int* lwork,
int* info) {
// TODO exploit the work buffer
bool query_size = *lwork == -1;
@@ -40,6 +41,9 @@ EIGEN_LAPACK_FUNC(syev)
if (*n == 0) return;
Scalar* a = reinterpret_cast<Scalar*>(ra);
Scalar* w = reinterpret_cast<Scalar*>(rw);
PlainMatrixType mat(*n, *n);
if (UPLO(*uplo) == UP)
mat = matrix(a, *n, *n, *lda).adjoint();