Contents Previous Next Subchapters

Elapsed Time Corresponding to Clock Values (Mlmode)
Syntax etime(c2c1)
See Also mlmode_clock , tictoc , time

Returns a double-precision scalar containing the number of elapsed seconds corresponding to starting at the clock value c1 and ending at the clock value c2. Here a clock value is a six element row vector containing the year, month, day, hour, minute and second in that order.

If in Mlmode you enter
     c1 = clock;
     c2 = clock;
     etime(c2, c1)
O-Matrix will print a number close to 3.

If the year or the month specified by c1 do not equal the corresponding values in c2, an error will result and the program will halt.