How to configure the matlab to use all core and processor of my system ?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Arvind Kumar Pathak
am 11 Aug. 2017
Bearbeitet: John D'Errico
am 11 Aug. 2017
Please tell me, how to use all core and processor of my system.
Is there any option in GUI of MATLAB or some type of code i have to write ?
1 Kommentar
José-Luis
am 11 Aug. 2017
It will do so automatically for the functions that support it. As far as I understand it, there are no options to set.
Akzeptierte Antwort
John D'Errico
am 11 Aug. 2017
Bearbeitet: John D'Errico
am 11 Aug. 2017
On small problems, there is no gain by wanting to use multiple cores. So if you have code that has many tests, branches, and lots of scalar operations, trying to use multiple cores would be a waste of time, slowing your code down.
MATLAB automatically multi-threads large computations on many operations, where is it seen that would be a throughput gain. So multiply two seriously large matrices, and you will see multiple cores popping up to solve the problem. (If you use a monitor to watch that.) There were times when I have had all the cores running on my machine. The fan kicks on fast then. You need do nothing special, just solve big problems.
Of course, if you have the cash, then you can buy the parallel processing toolbox. That allows you to specify how many cores will be used, but on processes that are inherently parallelizable. So if you can write your problem as lots of identical sub-problems, then you can gain.
Without the parallel TB, the only overt control you have is the function maxNumCompThreads, which will set (or tell you) the maximum number of threads that will be generated automatically.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Entering Commands finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!