I tried making a very simple algorithm for testing the computers speed, like this
tic;for r = 1:2000; for c = 1:2000; A(r,c) = r^2+sqrt(c); endendtoc
And it's obviously on purpose that I didn't preallocate A, since I want to stress the processor a bit. Anyway, i ran it on three different computers with follow results:
University desktop, with Ubuntu and Matlab 2010b. Time ~18 sek
Home desktop, with Windows and Matlab 2011 (i think). Time ~7 sek
Home laptop, with Ubuntu and Matlab 2011 or 2012 (dont remember) Time ~4 sek
The thing that confuses me a bit, is that my Laptop is that much faster than my home desktop, since both processor, graphics card and ram should be superior on the home desktop. Can anyone help me solve this mystery?
Best Answer