Mathematica 9 is now available
Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2008

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

Search the Archive

Re: DiffMaps package

  • To: mathgroup at smc.vnet.net
  • Subject: [mg89646] Re: DiffMaps package
  • From: dh <dh at metrohm.ch>
  • Date: Mon, 16 Jun 2008 06:40:05 -0400 (EDT)
  • References: <g3036s$mdc$1@smc.vnet.net>


Hi,

Interpolation does a piewise polynomial interpolation. From the manual:

points = {{0,0},{1,1},{2,3},{3,4},{4,3},{5,0}};

ifun = Interpolation[points]

pf[x_] = Piecewise[{

{InterpolatingPolynomial[{{0,0},{1,1},{2,3},{3,4}}, x], x < 2},

{InterpolatingPolynomial[{{1,1},{2,3},{3,4},{4,3}}, x], 2 <= x < 3},

{InterpolatingPolynomial[{{2,3},{3,4},{4,3},{5,0}}, x], x >=  3}

}]

Plot[pf[x] - ifun[x], {x,0,5}, PlotRange->All]

Therefore, the derivative need not be continuous. E.g.:

d=Table[{x,RandomReal[]},{x,0,1,.1}];

f=Interpolation[d];

Plot[f'[x],{x,0,1}]

hope this helps, Daniel





Modeler wrote:

> Thanks, actually I need to automate the procedure below to compute the minima and saddle points for an array of functions f[x,y]. I guess at some point I'll need to doublecheck manually that the procedure you describe below yields the correct critical points. 

> 

> The above functions are actually outputs of the mathematica interpolation procedure, I am slightly worried they might be nondifferentiable at certain points even if I take a high interpolation order. Do you know where to get further documentation on InterpolatingFunction? It is for me quite a black box. Do you know of any other smoother interpolation procedures like, say, 2d splines in mathematica?

> 





-- 



Daniel Huber

Metrohm Ltd.

Oberdorfstr. 68

CH-9100 Herisau

Tel. +41 71 353 8585, Fax +41 71 353 8907

E-Mail:<mailto:dh at metrohm.com>

Internet:<http://www.metrohm.com>




  • Prev by Date: Re: Nested Grids
  • Next by Date: Re: a mathlink question
  • Previous by thread: Re: DiffMaps package
  • Next by thread: Re: Transform list of numbers into pure functions using