34#ifndef ROOT_Math_GSLMultiMinFunctionAdapter
35#define ROOT_Math_GSLMultiMinFunctionAdapter
37#include "gsl/gsl_vector.h"
65 template<
class UserFunc>
68 static double F(
const gsl_vector *
x,
void *
p) {
70 UserFunc * function =
reinterpret_cast< UserFunc *
> (
p);
72 return (*function)(
x->data );
76 static void Df(
const gsl_vector *
x,
void *
p, gsl_vector *
g) {
78 UserFunc * function =
reinterpret_cast< UserFunc *
> (
p);
79 (*function).Gradient(
x->data,
g->data );
83 static void Fdf(
const gsl_vector *
x,
void *
p,
double *
f, gsl_vector *
g ) {
85 UserFunc * function =
reinterpret_cast< UserFunc *
> (
p);
89 (*function).FdF(
x->data, *
f,
g->data);
winID h TVirtualViewer3D TVirtualGLPainter p
Namespace for new Math classes and functions.
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
Class for adapting any multi-dimension C++ functor class to C function pointers used by GSL MultiMin ...
static double F(const gsl_vector *x, void *p)
static void Df(const gsl_vector *x, void *p, gsl_vector *g)
static void Fdf(const gsl_vector *x, void *p, double *f, gsl_vector *g)