Solving linear equations with large times
이전 댓글 표시
I am new to using matlab. I have a simple linear equation of Ax=B in loops;
where A is a complex matrix (1000x1000), and A will be changed with the parameters f, delta_p and delta_dopp in my code, i.e. A=A(f, delta_p, delta_dopp); B is a simple invariant column matrix (1000x1).
Cause I need to solve the linear equation almost about ~10^6 times. And matirx A is changing inside the loops (f, delta_p, delta_dopp are cycle indicators). When I using x=A\B solving the eqution, it should take me a lot of time. For example, it takes me one hour running 5e4 times.
I hope that someone can suggest a faster and better method? (Especially for the x=A\B method).
This is distribution of matrix A:

Thanks a lot!
댓글 수: 6
KSSV
2022년 2월 18일
Have you checked the time taken by one step?
KSSV
2022년 2월 18일
If you have GPU, you may try running on that. Read about gpuArray.
KSSV
2022년 2월 18일
Yes it should be supported. You may check it here: https://in.mathworks.com/help/matlab/referencelist.html?type=function&capability=gpuarrays
剑豪 戴
2022년 2월 18일
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Linear Algebra에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
