RMS error of matrices
7 ビュー (過去 30 日間)
古いコメントを表示
darksideofthemoon101
2011 年 4 月 6 日
コメント済み: Todd Pierce
2022 年 5 月 11 日
Hi,
I have 2 large matrixes (2048x2048), and have taken one away from the other to get a 'difference' matrix. I want to quantify this matrix by using an RMS error, however if I use a standard RMS error formula I get another 2048x2048 matrix.
Is there a way to get a single representative RMS value out?
Thanks,
Richard
1 件のコメント
Todd Pierce
2022 年 5 月 11 日
Hi there,
I am in a simlar position to yourself however, i want to maintain the matrix with all the rms values in, what initial line did you type in to get the rms for every value in the matrix whilst maintaining the shape.
採用された回答
その他の回答 (1 件)
darksideofthemoon101
2011 年 4 月 6 日
1 件のコメント
Walter Roberson
2011 年 4 月 6 日
When A and B are arrays then A-B is an array, and (A-B)^2 is
(A-B)*(A-B) which is a matrix multiplication which will produce an output the same size as A (in this case.) sqrt() of that would then be the same size.
Nothing in your code calculates the _mean_ portion of "RMS". Root MEAN square.
Possibly I should have suggested
sqrt(mean((A(:)-B(:)).^2))
but I am too tired to look up the definition at the moment.
参考
カテゴリ
Help Center および File Exchange で Shifting and Sorting Matrices についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!