forum.alglib.net
http://forum.alglib.net/

spline1dbuildlinear question
http://forum.alglib.net/viewtopic.php?f=2&t=147
Page 1 of 1

Author:  abcda [ Mon Jan 03, 2011 9:01 pm ]
Post subject:  spline1dbuildlinear question

Hello!
Thank you for this great library. It appears to be very useful for my purpose. Unfortunately, i didn't have enough time to make out how it operates inside, so my question may seem silly for you.

I use spline1dbuildlinear to get spline1dinterpolant which allows me(by means of spline1dcalc() method) to get Y values by passing the X ones. Now I'm looking for the opposite transformation( I need to get X values from Y using the same spline1dinterpolant). Could you please advice me the best way to do it using algLib?

PS see attached image for more details.

Attachments:
chart.PNG
chart.PNG [ 13.97 KiB | Viewed 4411 times ]

Author:  Sergey.Bochkanov [ Tue Jan 04, 2011 11:06 am ]
Post subject:  Re: spline1dbuildlinear question

There is no easy way to do so, i.e. there is no special function to solve such a problem. But you can unpack spline coefficients with spline1dunpack function and solve linear equations c0*x+c1 = y.

Author:  abcda [ Tue Jan 04, 2011 2:05 pm ]
Post subject:  Re: spline1dbuildlinear question

thanks, that's exectly what I needed.

Author:  abcda [ Tue Jan 04, 2011 4:32 pm ]
Post subject:  Re: spline1dbuildlinear question

Hello again.
I need to find local maximum of smooth function(result of experiment data approximation). I couldn't find any mentions of such functionality in ALGLIB Reference Manual. Probably, I used the wrong key words, because I'm not well familiar with mathematical analysis. Does ALGLIB offer functionality for this purpose?

Author:  Sergey.Bochkanov [ Wed Jan 05, 2011 10:29 am ]
Post subject:  Re: spline1dbuildlinear question

It is called "numerical optimization". Take a look at http://www.alglib.net/optimization/ It describes methods for minimization of smooth functions, but max(f) is the same as min(-f), so you can easily convert your problem to the minimization of a smooth function.

The only issue is that these methods were developed for N-dimensional minimization. They will work in 1-dimensional case too, but several times slower than specialized methods for 1-dimensional optimization.

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/