File indexing completed on 2025-02-21 10:03:54
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020 #ifndef __GSL_SPLINE_H__
0021 #define __GSL_SPLINE_H__
0022 #include <stdlib.h>
0023 #include <gsl/gsl_interp.h>
0024
0025 #undef __BEGIN_DECLS
0026 #undef __END_DECLS
0027 #ifdef __cplusplus
0028 # define __BEGIN_DECLS extern "C" {
0029 # define __END_DECLS }
0030 #else
0031 # define __BEGIN_DECLS
0032 # define __END_DECLS
0033 #endif
0034
0035 __BEGIN_DECLS
0036
0037
0038
0039 typedef struct {
0040 gsl_interp * interp;
0041 double * x;
0042 double * y;
0043 size_t size;
0044 } gsl_spline;
0045
0046 gsl_spline *
0047 gsl_spline_alloc(const gsl_interp_type * T, size_t size);
0048
0049 int
0050 gsl_spline_init(gsl_spline * spline, const double xa[], const double ya[], size_t size);
0051
0052 const char * gsl_spline_name(const gsl_spline * spline);
0053 unsigned int gsl_spline_min_size(const gsl_spline * spline);
0054
0055
0056 int
0057 gsl_spline_eval_e(const gsl_spline * spline, double x,
0058 gsl_interp_accel * a, double * y);
0059
0060 double
0061 gsl_spline_eval(const gsl_spline * spline, double x, gsl_interp_accel * a);
0062
0063 int
0064 gsl_spline_eval_deriv_e(const gsl_spline * spline,
0065 double x,
0066 gsl_interp_accel * a,
0067 double * y);
0068
0069 double
0070 gsl_spline_eval_deriv(const gsl_spline * spline,
0071 double x,
0072 gsl_interp_accel * a);
0073
0074 int
0075 gsl_spline_eval_deriv2_e(const gsl_spline * spline,
0076 double x,
0077 gsl_interp_accel * a,
0078 double * y);
0079
0080 double
0081 gsl_spline_eval_deriv2(const gsl_spline * spline,
0082 double x,
0083 gsl_interp_accel * a);
0084
0085 int
0086 gsl_spline_eval_integ_e(const gsl_spline * spline,
0087 double a, double b,
0088 gsl_interp_accel * acc,
0089 double * y);
0090
0091 double
0092 gsl_spline_eval_integ(const gsl_spline * spline,
0093 double a, double b,
0094 gsl_interp_accel * acc);
0095
0096 void
0097 gsl_spline_free(gsl_spline * spline);
0098
0099 __END_DECLS
0100
0101 #endif