Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #6597
| From | David Bailey <dave@removedbailey.co.uk> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: Timing function |
| Date | 2011-11-21 09:38 +0000 |
| Organization | Steven M. Christensen and Associates, Inc and MathTensor, Inc. |
| Message-ID | <jad65o$ek8$1@smc.vnet.net> (permalink) |
| References | <ja84v7$ifg$1@smc.vnet.net> |
On 19/11/2011 11:46, Mark wrote:
> Hello community:
>
> When I run the following expression below, It returns the value of zero for the timing. If I press "shift enter" again, it then correctly returns the amount of time for the expression to run / plot.
>
> Also, I noticed that if I change the variable from x^3 to x^2 and press "shift enter" at that point, zero again is returned for the timing result. I am using Mathematica 8.01
>
> Timing[Plot[x^3, {x, -5, 5}]]
>
> Does anyone know the reason for this?
>
The clock granularity has already been mentioned, but I suspect perhaps
that if you are timing Plot commands, you are struggling with more
complex plots that are irritatingly slow! A complication is that Timing
only measures the time used by the kernel, and for some plots, most of
the time is consumed in the frontend. Even AbsoluteTime does not solve
this problem easily, because it returns its result before the FE starts
its work.
I gave a talk at the 2010 autumn conference in Champaign discussing a
variety of subtle timing issues including this problem. You will find a
link to this presentation here:
http://www.wolfram.com/events/techconf2010/speakers.html
David Bailey
http://www.dbaileyconsultancy.co.uk
Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Find similar | Unroll thread
Timing function Mark <big.dog1@att.net> - 2011-11-19 11:46 +0000 Re: Timing function "Oleksandr Rasputinov" <oleksandr_rasputinov@hmamail.com> - 2011-11-20 10:39 +0000 Re: Timing function David Bailey <dave@removedbailey.co.uk> - 2011-11-21 09:38 +0000
csiph-web