|
Matlab provides its own routine for benchmarking, called
"bench".
Matlab
6.x
the syntax is >> bench (n), where n is the number
of times benchmarking will be repeated. If the result is placed in an array
i.e. T=bench(5),
then T will store the results from all 5 repetitions.
Matlab 5.x
the syntax is >> bench, there is no argument to
"bench" in matlab 5.x for automatically repeating the process.
So you have to put it inside a loop:
>>for I=1:5
T(I,:) = bench;
end
For both Matlab 5.x and 6.x, to keep the results you
need to save the contents of the array (T) containing the test data:
>>save testdata.txt
T -ASCII (writes the contents of T to an ASCII
file called "testdata.txt")
The results displayed are the times taken to complete
each of the steps during benchmarking, which are a collection of mathematical
processes and 2/3D graph plotting and manipulation. Between matlab versions
5.x and 6.x an additional benchmarking step was added, thus results are
presented seperately.
|