Reduce the size of Matrix from 100x100 to 35x11
23 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Raghu Vamsi Kodaboina
il 26 Nov 2024 alle 13:34
Modificato: John D'Errico
il 26 Nov 2024 alle 14:48
Hi,
I have a matrix which is 100x100, let say for example x1 = randi([1, 100], [100,100]). Where x1 is the Z in a Map data and X and Y represent Speed and Torque.
Now the size of Speed and Torque in this case is 1x100 and 100x1 respectively.
Now it was easy to reduce the size of Speed and Torque to 1x11 and 35x1 defining a new variable.
Given the new speed and torque of different size, how can convert my Z (=x1) data into a matrix of 35x11 from 100x100.
I have attached my code, where New Speed and Torque values are generated as mentioned as a new variable as I know the start and end values, now I want to reduce actual matrix of BMEP which is 100x100 to 35x11, matching the speed and Torque values.
I tried to explain the issue and if there are further queires please let me know and I will try to be more precise with what I need.
Thank you
With Regards
Raghu
2 Commenti
John D'Errico
il 26 Nov 2024 alle 14:39
Modificato: John D'Errico
il 26 Nov 2024 alle 14:48
Your question is impossible to answer. @Torsten gave you one, and you did not like it. But you don't say what you want, even though you claim to have edited your answer.
For example, you might choose from the original data, by simply choossing random rows and columns. you might decide to use interplation (infinitely many ways to do so, the simplest being what @Stephen23 suggested, interp2. But even interp2 has various methods in it, all of which are equally valid.). You might decide to resample by avaraging your data. (Infinitely many ways to do so. in blocks, for example, or even by the use of conv2.)
So if you want good help, then make it possible to get good help.
Risposte (1)
Vedere anche
Categorie
Scopri di più su Logical in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!