1 /* -*- C -*- */
2 %apply gsl_vector_char *INOUT {gsl_vector_char *v};
3 %apply gsl_vector_char *INOUT {gsl_vector_char *w};
4 %apply gsl_matrix_char *INOUT {gsl_matrix_char *v};
5 %apply gsl_matrix_char *INOUT {gsl_matrix_char *w};
6 /* -------------------------------------------------------------------------
7    -------------------------------------------------------------------------
8                      Vector functions
9    -------------------------------------------------------------------------
10    ------------------------------------------------------------------------- */
11 /*
12  * The following should mimic the Numeric.ones functions ....
13  */
14 void gsl_vector_char_set_zero (gsl_vector_char  * IN_SIZE_OUT);
15 void gsl_vector_char_set_all (gsl_vector_char * IN_SIZE_OUT, char IN);
16 int gsl_vector_char_set_basis (gsl_vector_char * IN_SIZE_OUT, size_t i);
17 
18 
19 int gsl_vector_char_fread (FILE * stream, gsl_vector_char * IN_SIZE_OUT);
20 int gsl_vector_char_fwrite (FILE * stream, const gsl_vector_char * IN);
21 int gsl_vector_char_fscanf (FILE * stream, gsl_vector_char * IN_SIZE_OUT);
22 int gsl_vector_char_fprintf (FILE * stream, const gsl_vector_char * IN,
23 			const char *format);
24 
25 /*
26  * Copy module provides the same
27  * int gsl_vector_char_memcpy (gsl_vector * INOUT, const gsl_vector * IN);
28  */
29 
30 int gsl_vector_char_reverse (gsl_vector_char * INOUT);
31 
32 int gsl_vector_char_swap (gsl_vector_char * v, gsl_vector_char * w);
33 
34 
35 int gsl_vector_char_swap_elements (gsl_vector_char * INOUT, const size_t i,
36 			      const size_t j);
37 
38 #if !defined(_GSL_BLOCK_COMPLEX_FUNCTIONS)
39 double gsl_vector_char_max (const gsl_vector_char * IN);
40 double gsl_vector_char_min (const gsl_vector_char * IN);
41 void gsl_vector_char_minmax (const gsl_vector_char * IN, char * OUTPUT,
42 			char * OUTPUT);
43 
44 size_t gsl_vector_char_max_index (const gsl_vector_char * IN);
45 size_t gsl_vector_char_min_index (const gsl_vector_char * IN);
46 void gsl_vector_char_minmax_index (const gsl_vector_char * IN, size_t * OUTPUT,
47 			size_t * OUTPUT);
48 
49 #endif
50 int gsl_vector_char_isnull(const gsl_vector_char *IN);
51 /* -------------------------------------------------------------------------
52    -------------------------------------------------------------------------
53                      Matrix functions
54    -------------------------------------------------------------------------
55    ------------------------------------------------------------------------- */
56 
57 /*
58  * The following should mimic the Numeric.ones functions ....
59  */
60 
61 void gsl_matrix_char_set_zero (gsl_matrix_char  * IN_SIZE_OUT);
62 void gsl_matrix_char_set_all (gsl_matrix_char * IN_SIZE_OUT, char IN);
63 void gsl_matrix_char_set_identity (gsl_matrix_char * IN_SIZE_OUT);
64 
65 
66 int gsl_matrix_char_fread (FILE * stream, gsl_matrix_char * IN_SIZE_OUT);
67 int gsl_matrix_char_fwrite (FILE * stream, const gsl_matrix_char * IN);
68 int gsl_matrix_char_fscanf (FILE * stream, gsl_matrix_char * IN_SIZE_OUT);
69 int gsl_matrix_char_fprintf (FILE * stream, const gsl_matrix_char * IN,
70 			const char *format);
71 
72 /*
73  * int gsl_matrix_memcpy(gsl_matrix * dest, const gsl_matrix * src);
74  */
75 int gsl_matrix_char_swap(gsl_matrix_char * v, gsl_matrix_char * w);
76 
77 int gsl_matrix_char_swap_rows(gsl_matrix_char * INOUT, const size_t i, const size_t j);
78 int gsl_matrix_char_swap_columns(gsl_matrix_char * INOUT, const size_t i,
79 			    const size_t j);
80 int gsl_matrix_char_swap_rowcol(gsl_matrix_char * INOUT, const size_t i, const size_t j);
81 int gsl_matrix_char_transpose (gsl_matrix_char * INOUT);
82 
83 /*
84  * Need a proper typemap for that
85  * int gsl_matrix_char_transpose_memcpy (gsl_matrix_char * OUT, const gsl_matrix_char * src);
86  */
87 #if !defined(_GSL_BLOCK_COMPLEX_FUNCTIONS)
88 double gsl_matrix_char_max (const gsl_matrix_char * IN);
89 double gsl_matrix_char_min (const gsl_matrix_char * IN);
90 void gsl_matrix_char_minmax (const gsl_matrix_char * IN, char * OUTPUT, char * OUTPUT);
91 
92 void gsl_matrix_char_max_index (const gsl_matrix_char * IN, size_t * OUTPUT, size_t *OUTPUT);
93 void gsl_matrix_char_min_index (const gsl_matrix_char * IN, size_t * OUTPUT, size_t *OUTPUT);
94 void gsl_matrix_char_minmax_index (const gsl_matrix_char * IN, size_t * OUTPUT,
95 			      size_t * OUTPUT,size_t * OUTPUT, size_t * OUTPUT);
96 #endif
97 int gsl_matrix_char_isnull (const gsl_matrix_char * IN);
98 
99 
100 gsl_vector_char_view gsl_matrix_char_diagonal(gsl_matrix_char *IN);
101 gsl_vector_char_view gsl_matrix_char_subdiagonal(gsl_matrix_char *IN, size_t k);
102 gsl_vector_char_view gsl_matrix_char_superdiagonal(gsl_matrix_char *IN, size_t k);
103