How to define nuclear norm in matlab?

조회 수: 13 (최근 30일)
GHUFRAN AHMAD KHAN
GHUFRAN AHMAD KHAN 2019년 5월 9일
편집: John D'Errico 2019년 5월 9일
I am trying to write nuclear norm in programmin but difficult to define.Can suggest some solution?

채택된 답변

John D'Errico
John D'Errico 2019년 5월 9일
편집: John D'Errico 2019년 5월 9일
What is difficult to program? A quick search online suggests it is the L-1 norm of either the vector of singular values, or of the vector of eigenvalues. It depends if your matrix is square or not.
This is simple to write however. Use eig (or svd) as you wish. Then call norm (with the correct norm) and you are done. WTP? Thus it can be written in one line. A short one, in fact.
nucnorm = norm(svd(A),1);
Or
nucnorm = norm(eig(A),1);
On a given square matrix, the two solutions will return different numbers, but will still be valid, in context of the apparent common use for this norm, that of finding a low rank matrix. (I won't bother to make the arument that this tends to induce a low rank matrix, since that is your choice to make anyway, and I don't even know if this is why you wish to compute this matrix norm.)
On a square matrix, it would appear that you might decide whether to use eig or svd in that call. Again, either seems appropriate, though svd seems generally to be faster. And since svd is neccesary for a non-square matrix, it makes sense that svd is the better choice.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Linear Algebra에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by