Speeding up matrix operations
7 ビュー (過去 30 日間)
古いコメントを表示
Hi all,
say A and B are big matrices and u,s,v are the svd decomposition of another big matrix. Now, is there a way to speed up the following operation?
mat=(A-u*s*v').*B
I have read that MATLAB has a tool called BLAS but have not understood how to use it and if it is useful in this case.
Thank you
2 件のコメント
回答 (1 件)
Jan
2022 年 12 月 2 日
Matlab calls optimized libraries to solve linear algebra operations. These libraries are based on BLAS and LAPACK, but modern versions as ATLAS and MKL are tune automatically to improve the performance.
These functions are called automatically if you apply a matrix multiplication or SVD, and inversion or LU or QR decomposition. You do not have to call these functions manually. This was the purpose of designing Matlab.
If u,s,v is the SVD decomposition of another matrix C, wouldn't it be more efficient to use
(A - C) .* B
instead of:
(A - u*s*v') .* B
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Matrix Decomposition についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!