multiplication of matrix with long data
Ältere Kommentare anzeigen
Hi,
I have a long data (200K+ samples) from which a location vector L (3x1) and a matrix T (euler matrix 3x3) is generated and multiplied l = TL.
On the results of l (3x1) there are operations of sin and atan (to get the required results).
So far, I'm doing a for loop, which is not a Matlab way.
I'd like to speedup the performance of the code.
How can I do it?
4 Kommentare
Walter Roberson
am 14 Jul. 2022
What are you looping? The only part that you describe that involves the large data is the creation of L and T, and you do not describe the math involved in that.
Are you looping taking a subset of the data, doing the calculations, moving on to the next subset of data?
Thank you for taking the time to fill in that you are using R14SP2, that will help us not waste time suggesting some of the functions added recently.
michael
am 14 Jul. 2022
Bruno Luong
am 14 Jul. 2022
"So far, I'm doing a for loop, which is not a Matlab way. "
Anything allowed by MATLAB IS MATLAB way.
Steven Lord
am 28 Feb. 2023
Is there a specific reason you're still using release R14SP2 which is pretty close to twenty years old at this point?
There have been a lot of improvements in MATLAB in the past twenty years, which likely would improve performance of your code.
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Matrix Indexing finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!