help-gsl
[Top][All Lists]
Advanced

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

Re: [Help-gsl] Re: Numerical Gradient Function


From: Andrew W. Steiner
Subject: Re: [Help-gsl] Re: Numerical Gradient Function
Date: Fri, 14 Mar 2008 14:52:26 -0400

Hi. O2scl provides a C++ish version of many of the GSL routines
(though it's more than a wrapper).
Since I see David's working in C++, O2scl may be helpful for you. It
will also automatically compute
gradients for you (see the simple_grad class).

Since earlier threads on this topic mentioned using gsl_diff_central,
I should point out that
using gsl_diff_central may be overkill for numerical gradients inside
a minimizer because
only estimates of the derivatives, not precise derivatives are required. This
is the same reason the GSL hybrids solver only uses naive finite
differencing for the
Jacobian.

I'm not convinced C-style double arrays are a good solution for you either, as
I don't really expect std::vector<double> to be much slower than
gsl_vector since
the latter has the extra overhead of a finite stride. In any case the
range-checking
is extremely helpful.

While the O2scl support for the simplex minimizer is well developed, the other
minimizers do not yet allow generic vector and matrix types (so you'd
have to use
ovector or gsl_vector and omatrix or gsl_matrix). They'll automatically compute
the gradient for you though.

I've also started working on implementing OOL as classes in O2scl. The gencan
minimizer isn't done yet but the other two are well on their way...

Hope this helps,
Andrew

On Fri, Mar 14, 2008 at 2:25 PM, Rodney Sparapani <address@hidden> wrote:
> David Doria wrote:
>  >
>  > Also, I just found OOL which has this function as well as a numerical
>  > hessian function as well as a constrained minimization function set!  The
>  > GSL guys should definitely include OOL in the next release (or at least
>  > mention it somewhere haha)!
>  >
>  > Thanks,
>  > Dave
>  >
>
>  Hi Dave:
>
>  Hey, great!  http://ool.sourceforge.net/
>
>  And, even better AFAIAC, I accidentally found O2scl searching for OOL.
>  It's a C++ wrapper for GSL?!?  I've spent many hours doing the same.
>  http://o2scl.sourceforge.net/o2scl/html/
>
>  Rodney
>
>
>
>
>
>  _______________________________________________
>  Help-gsl mailing list
>  address@hidden
>  http://lists.gnu.org/mailman/listinfo/help-gsl
>




reply via email to

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