Beispiel #1
0
 /// <summary>Computes all eigenvalues and, optionally, eigenvectors of a real symmetric matrix using the Relatively Robust Representations.
 /// </summary>
 /// <param name="symmetricEigenvalueProblems">The <see cref="LapackEigenvalues.ISymmetricEigenvalueProblems"/> object.</param>
 /// <param name="job">A value indicating what kind of job to do by the LAPACK function.</param>
 /// <param name="n">The order of the tridiagonal matrix.</param>
 /// <param name="a">The symmetric matrix, i.e. containing either upper or lower triangular part of the symmetric matrix, as specified by <paramref name="triangularMatrixType"/>. The length should be at least <paramref name="n"/>^2; overwritten on exit.</param>
 /// <param name="m">The total number of eigenvalues found (output).</param>
 /// <param name="w">The first <paramref name="m"/> values contain the selected eigenvalues in ascending order; this array should have a length of at least <paramref name="n"/> (output).</param>
 /// <param name="z">If <paramref name="job"/> indicates to compute eigenvectors, the first <paramref name="m"/> columns of matrix Z contain the orthonormal eigenvectors.</param>
 /// <param name="isuppz">The support of the eigenvectors in matrix Z, that is the indices indicating the nonzero elements in z (output).</param>
 /// <param name="work">A workspace array with at least 26 * <paramref name="n"/> elements.</param>
 /// <param name="iwork">A workspace array with at least 10 * <paramref name="n"/> elements.</param>
 /// <param name="triangularMatrixType">A value indicating whether the upper or lower triangular part of the symmetric input matrix is stored.</param>
 /// <param name="abstol">The absolute error tolerance for the eigenvalues.</param>
 public static void driver_dsyevr(this LapackEigenvalues.ISymmetricEigenvalueProblems symmetricEigenvalueProblems, LapackEigenvalues.SymmetricGeneralJob job, int n, double[] a, out int m, double[] w, double[] z, int[] isuppz, double[] work, int[] iwork, BLAS.TriangularMatrixType triangularMatrixType = BLAS.TriangularMatrixType.LowerTriangularMatrix, double abstol = MachineConsts.Epsilon)
 {
     symmetricEigenvalueProblems.driver_dsyevr(job, LapackEigenvalues.SymmetricEigenvaluesRange.All, n, a, 0, 0, 0, 0, out m, w, z, isuppz, work, iwork, triangularMatrixType, abstol);
 }