MathGroup Archive 1992

[Date Index] [Thread Index] [Author Index]

Search the Archive

Timing[ ]

  • To: mathgroup at
  • Subject: Timing[ ]
  • From: keiper
  • Date: Thu, 15 Oct 92 08:24:15 CDT

	> Timing[10000!]
	> on my Mac IIci and got about 124 sec which seemed in
	> good agreement with the other reported times for this
	> configuration. Running it a second time however gave a
	> time of about 1.67 sec.

Yes, many standard calculations are cached so that they do not have to
be calculated each time.  A sparse table of factorials is saved,
Bernoulli numbers are saved, numerical approximations to the various
mathematical constants (Pi, E, EulerGamma, etc) are saved, weights
and abscissae for Gauss-Kronrod quadrature are saved, as well as
several other things that don't immediately spring to mind.  Any
calculation involving anything that gets cached will generally be
faster the second time around.  For the most part, a third attempt
will take about as long as the second attempt, but subtlties can
arise even here.

Jerry B. Keiper
keiper at

  • Prev by Date: Tokyo Mathematica Conference
  • Next by Date: Re: Timing
  • Previous by thread: Tokyo Mathematica Conference
  • Next by thread: Re: Timing