Any body ever fully diagonalize a 200,000 hermitian matrix?

  • Context: Graduate 
  • Thread starter Thread starter wdlang
  • Start date Start date
  • Tags Tags
    Body Hermitian Matrix
Click For Summary

Discussion Overview

The discussion revolves around the feasibility and methods of diagonalizing a 200,000-dimensional Hermitian matrix. Participants explore the practicality of such a task, the necessity of diagonalization, and the computational challenges involved, including considerations for sparse matrices and numerical algorithms.

Discussion Character

  • Debate/contested
  • Technical explanation
  • Mathematical reasoning

Main Points Raised

  • Some participants question the necessity of diagonalizing a 200,000-dimensional matrix, suggesting that iterative methods may be more efficient for large systems.
  • Others argue that there are valid reasons to diagonalize such matrices, even if they are sparse.
  • A participant mentions a specific example involving a text-document matrix with 200,000 documents, indicating that singular value decomposition might be used for clustering.
  • One participant shares a computational example involving Gauss-Laguerre quadrature nodes and notes the time taken for diagonalization on a modern PC.
  • Concerns are raised about the hardware limitations, specifically RAM requirements for handling such large matrices.
  • Some participants discuss the possibility of optimizing diagonalization calculations based on the matrix's properties and suggest that specialized algorithms may be necessary.
  • There is a claim that most matrices can be diagonalized, countering the assertion that many cannot, although this remains a point of contention.
  • A participant expresses interest in diagonalizing a 10,000x10,000 matrix on their laptop and considers using parallel algorithms for larger matrices.
  • Questions are posed regarding the availability of numerical routines optimized for diagonalizing large sparse matrices.

Areas of Agreement / Disagreement

Participants express differing views on the necessity and feasibility of diagonalizing such large matrices, with no consensus reached on the best approach or the practicality of the task.

Contextual Notes

Limitations include potential hardware constraints, the complexity of algorithms required for optimization, and the varying definitions of what constitutes a "sparse" matrix.

wdlang
Messages
306
Reaction score
0
is it possible on a station?

how long?
 
Physics news on Phys.org
I doubt that there would be any reason to diagonalize such a matrix. About 10 to 20 years ago, the United States Coast and Geodetic Survey went through a large linear algebra calculation "justifying" the boundaries of "townships" and "sections" on its map (areas surveyed by different teams at different times typically didn't match up exactly). That required several hundred thousand equations in as many unknowns but it was not ever stored as a single matrix (Since positions of points would only affect the positions of point nearby, it would, necessarily, be a "sparse" matrix (almost all entries 0) and there are ways of working with such matrices that do not require storing all of the zero entries). Also, since their object was to "solve" the equations (actually a "least squares" approximation) I believe they used iterative approximation methods rather than diagonalizing.
 
  • Like
Likes   Reactions: DifferentialGalois
HallsofIvy said:
I doubt that there would be any reason to diagonalize such a matrix. About 10 to 20 years ago, the United States Coast and Geodetic Survey went through a large linear algebra calculation "justifying" the boundaries of "townships" and "sections" on its map (areas surveyed by different teams at different times typically didn't match up exactly). That required several hundred thousand equations in as many unknowns but it was not ever stored as a single matrix (Since positions of points would only affect the positions of point nearby, it would, necessarily, be a "sparse" matrix (almost all entries 0) and there are ways of working with such matrices that do not require storing all of the zero entries). Also, since their object was to "solve" the equations (actually a "least squares" approximation) I believe they used iterative approximation methods rather than diagonalizing.

there are surely reasons to diagonalize such a matrix

even for sparse matrices, sometimes we need to fully diagonalize it.
 
there are surely reasons to diagonalize such a matrix

Like what? First you need a matrix of that size, then you need a reason to diagonalize it. Most matrices don't need to be diagonalized.

I do know there's a text-document matrix of a ton of wikipedia articles. It contains about 200,000 documents and 200,000 words (including names of every person etc., not just english words). The objective is to use it for clustering, so presumably they wanted to do singular value decomposition or something
 
wdlang said:
there are surely reasons to diagonalize such a matrix

even for sparse matrices, sometimes we need to fully diagonalize it.

Just for fun, the Gauss-Laguerre quadrature nodes of order 200k (~15 min on newish PC):
Code:
n=2e5;
x=eig(spdiags([-(n-1):0; 2*(n:-1:1)-1; -n:-1]',-1:1,n,n));
 
bpet said:
Just for fun, the Gauss-Laguerre quadrature nodes of order 200k (~15 min on newish PC):
Code:
n=2e5;
x=eig(spdiags([-(n-1):0; 2*(n:-1:1)-1; -n:-1]',-1:1,n,n));

but i also need the eigenvectors
 
wdlang said:
but i also need the eigenvectors

sorry, my computer doesn't have 320GB of ram.
 
I can diagonalize the identity matrix and get all the eigenvectors for you
 
wdlang said:
there are surely reasons to diagonalize such a matrix

even for sparse matrices, sometimes we need to fully diagonalize it.
Can you give an example? Anything that can be done by diagonalizing a matrix can also be done by iterative methods and for very large matrices iterative methods will be much faster.

(And, of course, most matrices can't be diagonalized.)
 
  • #10
HallsofIvy said:
(And, of course, most matrices can't be diagonalized.)
That's not really true. It's straight forward to prove that as a subset of \mathbf{R}^{n^2}, the matrices in \mathrm{Mat}_n(\mathbf{R}) that are not diagonalisable form a set of Lebesgue measure zero. So in this sense, most matrices can be diagonalised.
 
  • #11
bah -- deleting comment -- I don't have a good answer.
 
Last edited:
  • #12
wdlang said:
is it possible on a station?

how long?

For a generic diagonalizable 200.000x200.000 matrix, a naive implementation is quit impossible ('how long' isn't an issues, since your RAM will give up very quickly).

Depending on what you need to do with the eigenvectors and eigenvalues, and the form of your Hermitian matrix, it is usually possible to optimize the calculation very much! This, of course, usually involves specialized and sophisticated algorithms (=much more work than just writing "diagonalize(H)").
 
  • #13
element4 said:
For a generic diagonalizable 200.000x200.000 matrix, a naive implementation is quit impossible ('how long' isn't an issues, since your RAM will give up very quickly).

Depending on what you need to do with the eigenvectors and eigenvalues, and the form of your Hermitian matrix, it is usually possible to optimize the calculation very much! This, of course, usually involves specialized and sophisticated algorithms (=much more work than just writing "diagonalize(H)").

i can do diagonalization of 10000*10000 matrix on my laptop (2.5 RAM)

possibly i will try to do it on a station with parallel algorithm using scalapck
 
  • #14
Are you trying to diagonalize an ordinary matrix or a sparse matrix? Do you know any numerical routines which are optimized for diagonalizing huge sparse matrices? I tried NAG library and Mathematica, but neither seems to have this functionality.
 

Similar threads

Replies
9
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 6 ·
Replies
6
Views
4K
  • · Replies 13 ·
Replies
13
Views
4K
  • · Replies 15 ·
Replies
15
Views
2K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K