Hi all,
I have a .cpp code which reads a matrix from a .dat file and compute their eigenvalues. But I would like to read more matrices from the file not only one, and get the eigenvalues in the similar way.
Please help to solve this, I stuck at this point (i.e. how to read more than one matrix from the file).
The meaning of the content of the matrix.dat file is the following:
2 <-- this is the size of the NxN matrix, N=2
1 0 0 0 <-- (1 0) means the real and imaginary part of a matrix element 1,1;
(0 0) means the real and imaginary part of a matrix element 1,2;
0 0 1 0 <-- (0 0) means the real and imaginary part of a matrix element 2,1;
(1 0) means the real and imaginary part of a matrix element 2,2;