Find true rank of a Matrix?

4 ビュー (過去 30 日間)
Mikhail  Kandel
Mikhail Kandel 2011 年 7 月 8 日
I am comparing some Matlab code with c++ code. It appears as though the Matlab code is inverting a matrix which is rank deficient: at least to the c++ code. Additionally, Wolfram's CAS, reports the matrix as slightly rank deficient: although it still happily inverts it. For example, rank 5 instead of 6.
Doing some research it appears that the Matlab code does an svd style analysis. I was interest in 3 things:
1. Is there a different routine for rank calculation.
2. How do I get Matlab to spit out the same error that I get in c++ when inverting matrixes. This is pivotal - no pun intended - for verifying that my c++ code works. Is there a precision modifier?
3. Why is SVD considered "the most reliable". How much of the SVD does it do? Any musings on using SVD for rank analysis are welcome - I am just starting out in the numerical simulation field.
  1 件のコメント
the cyclist
the cyclist 2011 年 7 月 25 日
It would be very handy if you could post a specific matrix that exhibit the behavior you are interested in, to anchor the discussion.

サインインしてコメントする。

採用された回答

the cyclist
the cyclist 2011 年 7 月 25 日
I am not an expert in this, but from scanning the documentation it looks like you might be able to use pinv() or svds(), and set the tolerance to a specific value. The rank() command might also be handy.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLinear Algebra についてさらに検索

タグ

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by