Registered Member
|
I use the SelfAdjointEigenSolver for rather large dynamic-size matrices. The documentation states that in this case the constructor SelfAdjointEigenSolver ( Index size ) is useful. However, this is the point, where the documentation becomes confusing, since "size" is called a positive integer being the size of the matrix.
Intuitively, I assumed that size = N*N, where N is the number of rows and cols, respectively. This assumption is, in my opinion, also supported by the definition of the size() member function of the matrix class, which returns the product of the number of rows and columns: rows()*cols(). However, looking at the code, it rather seems that size should be the number of rows (or columns): size = N. In my case, this missunderstanding caused a "std::bad_alloc", because I ran out of memory while allocating. In order to prevent other users from this error, maybe the documentation could be made more specific on how "size" has to be understood in this case. Thank you |
Moderator
|
thanks for the feedback, we'll try to clarify this in the doc.
|
Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]