How can i save the time for calculating a combination (nchossek(1:10000,2)) ?thank you
Ältere Kommentare anzeigen
How can i save the time for calculating a combination (nchoosek(1:10000,2)) ?thank you
6 Kommentare
Guillaume
am 6 Okt. 2014
That's around 5e9 (5000 million!) different combinations! No matter what you do, it's going to take a while to compute.
Matt J
am 6 Okt. 2014
And will require 40GB to store, assuming single floating point.
pengcheng
am 6 Okt. 2014
Guillaume
am 6 Okt. 2014
It's still 49e6 (49 million) combinations. You may want to rethink what you are doing (or be prepared to wait).
Note to check how many combinations that is:
nchoosek(10000, 2) %this value on the other is very fast to calculate
Antworten (0)
Kategorien
Mehr zu Matrices and Arrays 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!