MathGroup Archive 2006

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

Search the Archive

Precision of arguments to FunctionInterpolation

  • To: mathgroup at smc.vnet.net
  • Subject: [mg68286] Precision of arguments to FunctionInterpolation
  • From: "Andrew Moylan" <andrew.j.moylan at gmail.com>
  • Date: Mon, 31 Jul 2006 03:45:55 -0400 (EDT)
  • Sender: owner-wri-mathgroup at wolfram.com

Hi,

Can someone help me understand an unexpected dependence of
FunctionInterpolation on the precision of its second argument?

Here is function that behaves like a low-precision version of Sin:

  lowPrecisionSin[x_?NumericQ] := SetPrecision[Sin[x], 5]

I can create an interpolation of this function thus:

  FunctionInterpolation[lowPrecisionSin[x], {x, 0, 1.}]

This quickly successfully returns: InterpolatingFunction[{{0., 1.}},
<>]

If I instead try to create an interpolation of this function thus:

  FunctionInterpolation[lowPrecisionSin[x], {x, 0, 1.`14}]

where the only difference is in the precision of the upper bound of the
range of interpolation, FunctionInterpolation fails to return quickly,
and it reports warnings like the following:

  FunctionInterpolation::ncvb: FunctionInterpolation failed to meet the
\
prescribed accuracy and precision goals after 6 recursive bisections
near x = \
0.015625`13.154901959985743. Continuing to refine elsewhere.

Note that this behaviour is unchanged if I add the options e.g.
"PrecisionGoal -> 5, InterpolationPrecision -> 14" to each call to
FunctionInterpolation. But the behaviour _does_ depend on the precision
of lowPrecisionSin: if I change "5" to "10" in the definition of
lowPrecisionSin, the problem disappears.

Can anyone explain this apparently strange behaviour?

Cheers,

Andrew


  • Prev by Date: numerical capabilities
  • Next by Date: Re: RE: Log Function
  • Previous by thread: Re: numerical capabilities
  • Next by thread: Eclipse plugin