3 * Copyright (C) 1996, 1997, 1998, 1999, 2000, 2007 Brian Gough
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 3 of the License, or (at
8 * your option) any later version.
10 * This program is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
24 #include <gsl/gsl_types.h>
25 #include <gsl/gsl_math.h>
30 # define __BEGIN_DECLS extern "C" {
31 # define __END_DECLS }
33 # define __BEGIN_DECLS /* empty */
34 # define __END_DECLS /* empty */
43 int (*set) (void *state, gsl_function * f, double x_minimum, double f_minimum, double x_lower, double f_lower, double x_upper, double f_upper);
44 int (*iterate) (void *state, gsl_function * f, double * x_minimum, double * f_minimum, double * x_lower, double * f_lower, double * x_upper, double * f_upper);
46 gsl_min_fminimizer_type;
50 const gsl_min_fminimizer_type * type;
51 gsl_function * function ;
55 double f_minimum, f_lower, f_upper;
61 gsl_min_fminimizer_alloc (const gsl_min_fminimizer_type * T) ;
63 void gsl_min_fminimizer_free (gsl_min_fminimizer * s);
65 int gsl_min_fminimizer_set (gsl_min_fminimizer * s,
66 gsl_function * f, double x_minimum,
67 double x_lower, double x_upper);
69 int gsl_min_fminimizer_set_with_values (gsl_min_fminimizer * s,
71 double x_minimum, double f_minimum,
72 double x_lower, double f_lower,
73 double x_upper, double f_upper);
75 int gsl_min_fminimizer_iterate (gsl_min_fminimizer * s);
77 const char * gsl_min_fminimizer_name (const gsl_min_fminimizer * s);
79 double gsl_min_fminimizer_x_minimum (const gsl_min_fminimizer * s);
80 double gsl_min_fminimizer_x_lower (const gsl_min_fminimizer * s);
81 double gsl_min_fminimizer_x_upper (const gsl_min_fminimizer * s);
82 double gsl_min_fminimizer_f_minimum (const gsl_min_fminimizer * s);
83 double gsl_min_fminimizer_f_lower (const gsl_min_fminimizer * s);
84 double gsl_min_fminimizer_f_upper (const gsl_min_fminimizer * s);
86 /* Deprecated, use x_minimum instead */
87 double gsl_min_fminimizer_minimum (const gsl_min_fminimizer * s);
90 gsl_min_test_interval (double x_lower, double x_upper, double epsabs, double epsrel);
92 GSL_VAR const gsl_min_fminimizer_type * gsl_min_fminimizer_goldensection;
93 GSL_VAR const gsl_min_fminimizer_type * gsl_min_fminimizer_brent;
96 int (*gsl_min_bracketing_function)(gsl_function *f,
97 double *x_minimum,double * f_minimum,
98 double *x_lower, double * f_lower,
99 double *x_upper, double * f_upper,
103 gsl_min_find_bracket(gsl_function *f,double *x_minimum,double * f_minimum,
104 double *x_lower, double * f_lower,
105 double *x_upper, double * f_upper,
110 #endif /* __GSL_MIN_H__ */