help-gsl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-gsl] monotone interpolation


From: Christian Krueger
Subject: Re: [Help-gsl] monotone interpolation
Date: Fri, 02 Mar 2012 21:43:35 +0000
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.27) Gecko/20120216 Thunderbird/3.1.19

Ok, the implementation was easier than expected; I adopted the code for the Akima-spline to large extent.

I just figured out, that GSL considers itself to be almost complete (which it is not IMHO), cf. http://www.gnu.org/software/gsl/design/gsl-design.html#SEC2

Therefore, a new feature should not come with any issues (bugs, code layout, naming convention, and so on). And this is the point where I might need your help, please. Either from you directly or you redirect me to someone one else. Furthermore, it would be the first time for me to contribute to such a huge project.

-------
For the actual problem, *monotone spline interpolation*, there are three different solutions known to me:

(a) M.Steffen, "A simple method for monotonic interpolation in one dimension", Astron. Astrophys. 239, 443-450 (1990).

(b) H.T.Huynh, "Accurate Monotone Cubic Interpolation", SIAM J. Numer. Anal. 30, 57-100 (1993).

(c) Fritsch, F. N.; Carlson, R. E., "Monotone Piecewise Cubic Interpolation", SIAM J. Numer. Anal. 17 (2), 238–246 (1980).

For solution (c), there is also an article available on wikipedia and as it was the first one known to me, this one is implemented at the moment.

I don't know which of those is the "best" or to prefer in a certain situation. However, I will implement (a) or (b) (or both) soon since I am not 100% satisfied with (c); it sometimes produces more wiggles than Akima's method. So, I hope one of the other two suits my problem better.

Apart from that, to be most comprehensive, all three methods could go to GSL, but it might be frowned upon flooding GSL with new stuff. Does anybody of you have experience with some of those methods?

Any comments are appreciated! Thank you!

/Christian


On 03/02/2012 02:52 PM, Rhys Ulerich wrote:
The other one in that graph *might* be close to the one on wiki?
http://en.wikipedia.org/wiki/Monotone_cubic_interpolation

However, I would prefer to have a GSL implementation.

I suspect a GSL implementation would look enough like
http://bzr.savannah.gnu.org/lh/gsl/trunk/annotate/head:/interpolation/cspline.c
that those data structures could be used as a fruitful starting point.

- Rhys



reply via email to

[Prev in Thread] Current Thread [Next in Thread]