Mathematica 9 is now available

Documentation / Mathematica / Built-in Functions / System Interface / Time and Date /

Timing

FilledSmallSquare Timing[expr] evaluates expr, and returns a list of time used, together with the result obtained.

FilledSmallSquare Timing gives the CPU time in seconds, multiplied by the symbol Second.

FilledSmallSquare Timing has attribute HoldAll.

FilledSmallSquare Timing[expr;] will give timing, Null.

FilledSmallSquare First[Timing[expr;]] /. Second->1 yields just the number of seconds required for the evaluation of expr.

FilledSmallSquare Timing is accurate only down to a granularity of at least $TimeUnit seconds.

FilledSmallSquare Timing includes only CPU time spent in the Mathematica kernel. It does not include time spent in external processes connected via MathLink or otherwise. Nor does it include time spent in the Mathematica front end.

FilledSmallSquare Timing[expr] includes only time spent in the evaluation of expr, and not, for example, in the formatting or printing of the result.

FilledSmallSquare Timing should give accurate results on all operating systems where the running of processes is specifically scheduled by the operating system.

FilledSmallSquare On early versions of Microsoft Windows and Mac OS where Mathematica must explicitly yield in order for other processes to run, Timing may substantially overestimate the time used within Mathematica.

FilledSmallSquare See Section 2.14.3.

FilledSmallSquare See also: AbsoluteTiming, TimeUsed, TimeConstrained, SessionTime, AbsoluteTime.

FilledSmallSquare New in Version 1.

Further Examples



Any questions about topics on this page? Click here to get an individual response.Buy NowMore Information
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.