This is the mail archive of the gsl-discuss@sources.redhat.com mailing list for the GSL project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Root function


help-gsl seems to have problems, so I am (re)sending this to gsl-discuss.

ato

Date: Wed, 3 Dec 2003 11:13:04 -0600
From: M Atakan Gurkan <ato@northwestern.edu>
To: "lauradiara@libero.it" <lauradiara@libero.it>
Cc: GSL Help <help-gsl@gnu.org>
Subject: Re: Root function
User-Agent: Mutt/1.2.5.1i
In-Reply-To: <HPBPEL$632688B6CD5BDB7346FF8AD27B1CD0FB@libero.it>; from lauradiara@libero.it on Wed, Dec 03, 2003 at 03:25:33PM +0100

On Wed, Dec 03, 2003 at 03:25:33PM +0100, lauradiara@libero.it wrote:
> Hi,
> 
> I'd like to write a function which finds all the roots of a funcion y=f(x)
> provided by the user.
> 
> I have read the chapter one dimensional root finding: I have some questions.
> 
> The concept expressed is that you use root bracketing or root polishing: with
> the first you have to provide an initial intervalwitha root inside, while with
> the second you have to provide a guess root.
> 
> The first question is: both metods find only a root: if the function has more
> roots what happen?
> 
> The second question is that the initial condition (guess or interval with a
> root) is not simple, it's difficult to provide a good value.
> 
> All the examples are quite simple with a function provided athe start and not
> inserted by the user: so the guess or the interval is simple. But in the real
> applications, what can you do?
> 
> I think there is a solution, otherwise the functions in gsl_roots,h are not
> usable in real situations.
> 
> 
> Can you give me some advice?
Hi,
In real life applications you start with plotting your function and guess 
the roots, at least for a given interval. If you have a family of functions
then you try to parametrize the roots. This latter can be very hard. I 
recently spent a week on a parametrization problem.
There is no single method that will work for all functions. "Numerical
Methods That Work" is nice book on numerical techniques with a special emphasis
on what you should expect and how you can select a method based on the
problems at hand. I suggest you take a look at it.

Good luck,

ato


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]