how to do matrix addition of different sizes
1 回表示 (過去 30 日間)
古いコメントを表示
E = diag([12:4:56])
B=rand(12,3)
C=A+B
0 件のコメント
採用された回答
Azzi Abdelmalek
2013 年 6 月 13 日
C=A
C(:,1:3)=A(:,1:3)+B(:,1:3)
3 件のコメント
Azzi Abdelmalek
2013 年 6 月 13 日
E1=diag(a+(h.*d))
E2=lambda+B;
E=E1
E(:,1:3)=E1(:,1:3)./E2(:,1:3)
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Operating on Diagonal Matrices についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!