Questions tagged [eigenvalue]

The eigenvalue is the factor by which the eigenvector is scaled when multiplied by the matrix.

The eigenvectors of a square matrix are the non-zero vectors that, after being multiplied by the matrix, remain parallel to the original vector. For each eigenvector, the corresponding eigenvalue is the factor by which the eigenvector is scaled when multiplied by the matrix. The prefix eigen- is adopted from the German word "eigen" for "own"[1] in the sense of a characteristic description. The eigenvectors are sometimes also called characteristic vectors. Similarly, the eigenvalues are also known as characteristic values.

Find more on this topic on Wikipedia

747 questions
5
votes
1 answer

How to make the eigenvalues and eigenvectors stay real instead of complex?

I try to diagonalize a n*100*100 3d matrix K by numpy.linalg.eig and get the eigenvalues w and eigenvectors v. The matrix is 100*100, but I wanna do it with broadcasting, and that's the number n I set up. And the matrix is not…
kinder chen
  • 1,371
  • 5
  • 15
  • 25
5
votes
1 answer

Sparse eigenvalues : scipy.sparse.linalg.eigs is slower than scipy.linalg.eigvals

I have a peculiar phenomenon, though scipy.sparse.linalg.eigs should be faster for sparse matrices, I get that it runs slower than the normal eigvals method of scipy: In [4]: %timeit m.calc_pde_numerical_jacobian(m.initial_state) 10 loops, best of…
Ohm
  • 2,312
  • 4
  • 36
  • 75
5
votes
1 answer

Julia : eigs() function returning different values after every evaluation

I noticed that after running eigs() function multiple times, every time it gives different but approximate result. Is there way to return it every time the same result ? Output is sometimes with "+" sign or "-" sign. Content of M : [2, 1] = …
M.Puk
  • 762
  • 9
  • 25
5
votes
2 answers

low RAM consuming c++ eigen solver

I'm newbie in C++ programming, but I have a task to compute eigenvalues and eigenvectors (standard eigenproblem Ax=lx) for symmetric matrices (and hermitian)) for very large matrix of size: binomial(L,L/2) where L is about 18-22. Now I'm testing it…
andywiecko
  • 306
  • 3
  • 16
5
votes
2 answers

Sparse eigenvalues using eigen3/sparse

Is there an distinct and effective way of finding eigenvalues and eigenvectors of a real, symmetrical, very large, let's say 10000x10000, sparse matrix in Eigen3? There is an eigenvalue solver for dense matrices but that doesn't make use of the…
Philipp
  • 159
  • 1
  • 9
5
votes
2 answers

Error when computing eigenvalues of a scipy LinearOperator: "gmres did not converge"

I'm trying to solve a large eigenvalue problem with Scipy where the matrix A is dense but I can compute its action on a vector without having to assemble A explicitly. So in order to avoid memory issues when the matrix A gets big I'd like to use the…
cilix
  • 1,262
  • 1
  • 14
  • 14
5
votes
3 answers

Eigenvalues in octave with eig()

Consider the real, symmetric matrix S = (2, 1; 1, 2) From the characteristic equation |S - λ I|, we have the quadratic (2-λ)^2 - 1 = 0, whose solutions yield the eigenvalues 3 and 1. The corresponding eigenvectors are (1;-1) and (1;1). octave:4>…
boraas
  • 929
  • 1
  • 10
  • 24
5
votes
1 answer

Incorrect EigenValues/Vectors with Numpy

I am trying to find the eigenvalues/vectors for the following matrix: A = np.array([[1, 0, 0], [0, 1, 0], [1, 1, 0]]) using the code: from numpy import linalg as LA e_vals, e_vecs = LA.eig(A) I'm getting this as the…
user2268507
5
votes
2 answers

The fastest way to calculate eigenvalues of large matrices

Until now I used numpy.linalg.eigvals to calculate the eigenvalues of quadratic matrices with at least 1000 rows/columns and, for most cases, about a fifth of its entries non-zero (I don't know if that should be considered a sparse matrix). I found…
alice
  • 254
  • 2
  • 4
  • 9
5
votes
2 answers

erratic results for numpy/scipy eigendecompositions

I am finding that scipy.linalg.eig sometimes gives inconsistent results. But not every time. >>> import numpy as np >>> import scipy.linalg as lin >>> modmat=np.random.random((150,150)) >>> modmat=modmat+modmat.T # the data i am interested in is…
aestrivex
  • 5,170
  • 2
  • 27
  • 44
5
votes
2 answers

Eigenvalues calculations in C-within-R codes

I am writing R code which uses compiled C code. From "Writing R Extensions" document, I learned there are many R executable/DLL that can be called from C code. The header file ‘Rmath.h’ lists many functions that are available and its source codes…
FairyOnIce
  • 2,526
  • 7
  • 27
  • 48
5
votes
4 answers

Could we get different solutions for eigenVectors from a matrix?

My purpose is to find a eigenvectors of a matrix. In Matlab, there is a [V,D] = eig(M) to get the eigenvectors of matrix by using: [V,D] = eig(M). Alternatively I used the website WolframAlpha to double check my results. We have a 10X10 matrix…
5
votes
1 answer

Matlab VS Python - eig(A,B) VS sc.linalg.eig(A,B)

I have the following matrices sigma and sigmad: sigma: 1.9958 0.7250 0.7250 1.3167 sigmad: 4.8889 1.1944 1.1944 4.2361 If I try to solve the generalized eigenvalue problem in python I obtain: d,V =…
JEquihua
  • 1,217
  • 3
  • 20
  • 40
5
votes
1 answer

How to compute k largest eigen values on GPU?

I'm working on parallel algorithm for spectral clustering for which I need to calculate K largest eigen values.I'm using Jacket plugin for Matlab but sadly it doesn't support EIGS function in matlab(It is not able to calculate K eigen values in…
username_4567
  • 4,737
  • 12
  • 56
  • 92
4
votes
1 answer

How to get linearly independent eigenvectors using `numpy.linalg.eig`

From linear algebra we know that the eigenvectors of any symmetric matrix (let's call it A) are orthonormal, meaning if M is the matrix of all eigenvectors, we should obtain |det(M)| = 1. I had hoped to see this in numpy.linalg.eig, but got the…
sams-studio
  • 631
  • 3
  • 10