File indexing completed on 2025-01-19 09:56:39
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020 #ifndef __GSL_BLOCK_DOUBLE_H__
0021 #define __GSL_BLOCK_DOUBLE_H__
0022
0023 #include <stdlib.h>
0024 #include <gsl/gsl_errno.h>
0025
0026 #undef __BEGIN_DECLS
0027 #undef __END_DECLS
0028 #ifdef __cplusplus
0029 # define __BEGIN_DECLS extern "C" {
0030 # define __END_DECLS }
0031 #else
0032 # define __BEGIN_DECLS
0033 # define __END_DECLS
0034 #endif
0035
0036 __BEGIN_DECLS
0037
0038 struct gsl_block_struct
0039 {
0040 size_t size;
0041 double *data;
0042 };
0043
0044 typedef struct gsl_block_struct gsl_block;
0045
0046 gsl_block *gsl_block_alloc (const size_t n);
0047 gsl_block *gsl_block_calloc (const size_t n);
0048 void gsl_block_free (gsl_block * b);
0049
0050 int gsl_block_fread (FILE * stream, gsl_block * b);
0051 int gsl_block_fwrite (FILE * stream, const gsl_block * b);
0052 int gsl_block_fscanf (FILE * stream, gsl_block * b);
0053 int gsl_block_fprintf (FILE * stream, const gsl_block * b, const char *format);
0054
0055 int gsl_block_raw_fread (FILE * stream, double * b, const size_t n, const size_t stride);
0056 int gsl_block_raw_fwrite (FILE * stream, const double * b, const size_t n, const size_t stride);
0057 int gsl_block_raw_fscanf (FILE * stream, double * b, const size_t n, const size_t stride);
0058 int gsl_block_raw_fprintf (FILE * stream, const double * b, const size_t n, const size_t stride, const char *format);
0059
0060 size_t gsl_block_size (const gsl_block * b);
0061 double * gsl_block_data (const gsl_block * b);
0062
0063 __END_DECLS
0064
0065 #endif