help-gsl
[Top][All Lists]
Advanced

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

Re: [Help-gsl] Keeping fixed memory allocation for an interpolating obje


From: Sam Mason
Subject: Re: [Help-gsl] Keeping fixed memory allocation for an interpolating object
Date: Mon, 14 Oct 2013 14:13:54 +0100

On 14 October 2013 10:52, Ruben Farinelli <address@hidden> wrote:
> However allocating at each call in the function the dimension of the object
> and then freeing it via the commands
>
> spline=gsl_spline_alloc(gsl_interp_cspline, BIN);
> gsl_spline_init(spline, array_x, array_y, BIN);
>
> /* commands */
>
> gsl_spline_free(spline);
>
> is very time consuming.

If you could post the whole of your loop it would help, i.e. what are
you doing in "commands"?  Why don't you do something like the manual
example?

  
http://www.gnu.org/software/gsl/manual/html_node/Interpolation-Example-programs.html

Hope that helps!

  Sam



reply via email to

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