3 * Copyright (C) 1996, 1997, 1998, 1999, 2000, 2007 Gerard Jungman, 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.
22 #define GSL_MAX(a,b) ((a) > (b) ? (a) : (b))
23 #define GSL_MIN(a,b) ((a) < (b) ? (a) : (b))
25 #ifndef HIDE_INLINE_STATIC
26 int GSL_MAX_INT (int a, int b);
27 int GSL_MIN_INT (int a, int b);
28 double GSL_MAX_DBL (double a, double b);
29 double GSL_MIN_DBL (double a, double b);
30 long double GSL_MAX_LDBL (long double a, long double b);
31 long double GSL_MIN_LDBL (long double a, long double b);
34 GSL_MAX_INT (int a, int b)
36 return GSL_MAX (a, b);
40 GSL_MIN_INT (int a, int b)
42 return GSL_MIN (a, b);
46 GSL_MAX_DBL (double a, double b)
48 return GSL_MAX (a, b);
52 GSL_MIN_DBL (double a, double b)
54 return GSL_MIN (a, b);
58 GSL_MAX_LDBL (long double a, long double b)
60 return GSL_MAX (a, b);
64 GSL_MIN_LDBL (long double a, long double b)
66 return GSL_MIN (a, b);
70 /* Define some static functions which are always available */
72 double gsl_max (double a, double b);
73 double gsl_min (double a, double b);
75 double gsl_max (double a, double b)
77 return GSL_MAX (a, b);
80 double gsl_min (double a, double b)
82 return GSL_MIN (a, b);