1 @cindex Mathieu functions
3 The routines described in this section compute the angular and radial
4 Mathieu functions, and their characteristic values. Mathieu
5 functions are the solutions of the following two differential
11 {{d^2 y}\over{d v^2}}& + (a - 2q\cos 2v)y = 0, \cr
12 {{d^2 f}\over{d u^2}}& - (a - 2q\cosh 2u)f = 0.
20 d^2y/dv^2 + (a - 2q\cos 2v)y = 0
21 d^2f/du^2 - (a - 2q\cosh 2u)f = 0
26 The angular Mathieu functions @math{ce_r(x,q)}, @math{se_r(x,q)} are
27 the even and odd periodic solutions of the first equation, which is known as Mathieu's equation. These exist
28 only for the discrete sequence of characteristic values @math{a=a_r(q)}
29 (even-periodic) and @math{a=b_r(q)} (odd-periodic).
31 The radial Mathieu functions @c{$Mc^{(j)}_{r}(z,q)$}
32 @math{Mc^@{(j)@}_@{r@}(z,q)}, @c{$Ms^{(j)}_@{r@}(z,q)$}
33 @math{Ms^@{(j)@}_@{r@}(z,q)} are the solutions of the second equation,
34 which is referred to as Mathieu's modified equation. The
35 radial Mathieu functions of the first, second, third and fourth kind
36 are denoted by the parameter @math{j}, which takes the value 1, 2, 3
39 @comment The angular Mathieu functions can be divided into four types as
41 @comment \beforedisplay
44 @comment x & = \sum_{m=0}^\infty A_{2m+p} \cos(2m+p)\phi, \quad p = 0, 1, \cr
45 @comment x & = \sum_{m=0}^\infty B_{2m+p} \sin(2m+p)\phi, \quad p = 0, 1.
48 @comment \afterdisplay
53 @comment x = \sum_(m=0)^\infty A_(2m+p) \cos(2m+p)\phi, p = 0, 1,
54 @comment x = \sum_(m=0)^\infty B_(2m+p) \sin(2m+p)\phi, p = 0, 1.
59 @comment The nomenclature used for the angular Mathieu functions is @math{ce_n}
60 @comment for the first solution and @math{se_n} for the second.
62 @comment Similar solutions exist for the radial Mathieu functions by replacing
63 @comment the trigonometric functions with their corresponding hyperbolic
64 @comment functions as shown below.
66 @comment \beforedisplay
69 @comment x & = \sum_{m=0}^\infty A_{2m+p} \cosh(2m+p)u, \quad p = 0, 1, \cr
70 @comment x & = \sum_{m=0}^\infty B_{2m+p} \sinh(2m+p)u, \quad p = 0, 1.
73 @comment \afterdisplay
78 @comment x = \sum_(m=0)^\infty A_(2m+p) \cosh(2m+p)u, p = 0, 1,
79 @comment x = \sum_(m=0)^\infty B_(2m+p) \sinh(2m+p)u, p = 0, 1.
84 @comment The nomenclature used for the radial Mathieu functions is @math{Mc_n}
85 @comment for the first solution and @math{Ms_n} for the second. The hyperbolic
86 @comment series do not always converge at an acceptable rate. Therefore most
87 @comment texts on the subject suggest using the following equivalent equations
88 @comment that are expanded in series of Bessel and Hankel functions.
90 @comment \beforedisplay
93 @comment Mc_{2n}^{(j)}(x,q) & = \sum_{m=0}^\infty (-1)^{r+k}
94 @comment A_{2m}^{2n}(q)\left[J_m(u_1)Z_m^{(j)}(u_2) +
95 @comment J_m(u_1)Z_m^{(j)}(u_2)\right]/A_2^{2n} \cr
96 @comment Mc_{2n+1}^{(j)}(x,q) & = \sum_{m=0}^\infty (-1)^{r+k}
97 @comment A_{2m+1}^{2n+1}(q)\left[J_m(u_1)Z_{m+1}^{(j)}(u_2) +
98 @comment J_{m+1}(u_1)Z_m^{(j)}(u_2)\right]/A_1^{2n+1} \cr
99 @comment Ms_{2n}^{(j)}(x,q) & = \sum_{m=1}^\infty (-1)^{r+k}
100 @comment B_{2m}^{2n}(q)\left[J_{m-1}(u_1)Z_{m+1}^{(j)}(u_2) +
101 @comment J_{m+1}(u_1)Z_{m-1}^{(j)}(u_2)\right]/B_2^{2n} \cr
102 @comment Ms_{2n+1}^{(j)}(x,q) & = \sum_{m=0}^\infty (-1)^{r+k}
103 @comment B_{2m+1}^{2n+1}(q)\left[J_m(u_1)Z_{m+1}^{(j)}(u_2) +
104 @comment J_{m+1}(u_1)Z_m^{(j)}(u_2)\right]/B_1^{2n+1}
107 @comment \afterdisplay
112 @comment Mc_(2n)^(j)(x,q) = \sum_(m=0)^\infty (-1)^(r+k) A_(2m)^(2n)(q)
113 @comment [J_m(u_1)Z_m^(j)(u_2) + J_m(u_1)Z_m^(j)(u_2)]/A_2^(2n)
114 @comment Mc_(2n+1)^(j)(x,q) = \sum_(m=0)^\infty (-1)^(r+k) A_(2m+1)^(2n+1)(q)
115 @comment [J_m(u_1)Z_(m+1)^(j)(u_2) + J_(m+1)(u_1)Z_m^(j)(u_2)]/A_1^(2n+1)
116 @comment Ms_(2n)^(j)(x,q) = \sum_(m=1)^\infty (-1)^(r+k) B_(2m)^(2n)(q)
117 @comment [J_(m-1)(u_1)Z_(m+1)^(j)(u_2) + J_(m+1)(u_1)Z_(m-1)^(j)(u_2)]/B_2^(2n)
118 @comment Ms_(2n+1)^(j)(x,q) = \sum_(m=0)^\infty (-1)^(r+k) B_(2m+1)^(2n+1)(q)
119 @comment [J_m(u_1)Z_(m+1)^(j)(u_2) + J_(m+1)(u_1)Z_m^(j)(u_2)]/B_1^(2n+1)
120 @comment @end example
124 @comment where @c{$u_1 = \sqrt{q} \exp(-x)$}
125 @comment @math{u_1 = \sqrt@{q@} \exp(-x)} and @c{$u_2 = \sqrt@{q@} \exp(x)$}
126 @comment @math{u_2 = \sqrt@{q@} \exp(x)} and
128 @comment \beforedisplay
131 @comment Z_m^{(1)}(u) & = J_m(u) \cr
132 @comment Z_m^{(2)}(u) & = Y_m(u) \cr
133 @comment Z_m^{(3)}(u) & = H_m^{(1)}(u) \cr
134 @comment Z_m^{(4)}(u) & = H_m^{(2)}(u)
137 @comment \afterdisplay
142 @comment Z_m^(1)(u) = J_m(u)
143 @comment Z_m^(2)(u) = Y_m(u)
144 @comment Z_m^(3)(u) = H_m^(1)(u)
145 @comment Z_m^(4)(u) = H_m^(2)(u)
146 @comment @end example
150 @comment where @math{J_m(u)}, @math{Y_m(u)}, @math{H_m^{(1)}(u)}, and
151 @comment @math{H_m^{(2)}(u)} are the regular and irregular Bessel functions and
152 @comment the Hankel functions, respectively.
154 For more information on the Mathieu functions, see Abramowitz and
155 Stegun, Chapter 20. These functions are defined in the header file
156 @file{gsl_sf_mathieu.h}.
159 * Mathieu Function Workspace::
160 * Mathieu Function Characteristic Values::
161 * Angular Mathieu Functions::
162 * Radial Mathieu Functions::
165 @node Mathieu Function Workspace
166 @subsection Mathieu Function Workspace
168 The Mathieu functions can be computed for a single order or
169 for multiple orders, using array-based routines. The array-based
170 routines require a preallocated workspace.
172 @deftypefun {gsl_sf_mathieu_workspace *} gsl_sf_mathieu_alloc (size_t @var{n}, double @var{qmax})
173 This function returns a workspace for the array versions of the
174 Mathieu routines. The arguments @var{n} and @var{qmax} specify the
175 maximum order and @math{q}-value of Mathieu functions which can be
176 computed with this workspace.
178 @comment This is required in order to properly
179 @comment terminate the infinite eigenvalue matrix for high precision solutions.
180 @comment The characteristic values for all orders @math{0 \to n} are stored in
181 @comment the work structure array element @kbd{work->char_value}.
184 @deftypefun void gsl_sf_mathieu_free (gsl_sf_mathieu_workspace @var{*work})
185 This function frees the workspace @var{work}.
188 @node Mathieu Function Characteristic Values
189 @subsection Mathieu Function Characteristic Values
190 @cindex Mathieu Function Characteristic Values
192 @deftypefun int gsl_sf_mathieu_a (int @var{n}, double @var{q}, gsl_sf_result @var{*result})
193 @deftypefunx int gsl_sf_mathieu_b (int @var{n}, double @var{q}, gsl_sf_result @var{*result})
194 These routines compute the characteristic values @math{a_n(q)},
195 @math{b_n(q)} of the Mathieu functions @math{ce_n(q,x)} and
196 @math{se_n(q,x)}, respectively.
199 @deftypefun int gsl_sf_mathieu_a_array (int @var{order_min}, int @var{order_max}, double @var{q}, gsl_sf_mathieu_workspace @var{*work}, double @var{result_array}[])
200 @deftypefunx int gsl_sf_mathieu_b_array (int @var{order_min}, int @var{order_max}, double @var{q}, gsl_sf_mathieu_workspace @var{*work}, double @var{result_array}[])
201 These routines compute a series of Mathieu characteristic values
202 @math{a_n(q)}, @math{b_n(q)} for @math{n} from @var{order_min} to
203 @var{order_max} inclusive, storing the results in the array @var{result_array}.
206 @node Angular Mathieu Functions
207 @subsection Angular Mathieu Functions
208 @cindex Angular Mathieu Functions
209 @cindex @math{ce(q,x)}, Mathieu function
210 @cindex @math{se(q,x)}, Mathieu function
212 @deftypefun int gsl_sf_mathieu_ce (int @var{n}, double @var{q}, double @var{x}, gsl_sf_result @var{*result})
213 @deftypefunx int gsl_sf_mathieu_se (int @var{n}, double @var{q}, double @var{x}, gsl_sf_result @var{*result})
214 These routines compute the angular Mathieu functions @math{ce_n(q,x)}
215 and @math{se_n(q,x)}, respectively.
218 @deftypefun int gsl_sf_mathieu_ce_array (int @var{nmin}, int @var{nmax}, double @var{q}, double @var{x}, gsl_sf_mathieu_workspace @var{*work}, double @var{result_array}[])
219 @deftypefunx int gsl_sf_mathieu_se_array (int @var{nmin}, int @var{nmax}, double @var{q}, double @var{x}, gsl_sf_mathieu_workspace @var{*work}, double @var{result_array}[])
220 These routines compute a series of the angular Mathieu functions
221 @math{ce_n(q,x)} and @math{se_n(q,x)} of order @math{n} from
222 @var{nmin} to @var{nmax} inclusive, storing the results in the array
226 @node Radial Mathieu Functions
227 @subsection Radial Mathieu Functions
228 @cindex Radial Mathieu Functions
230 @deftypefun int gsl_sf_mathieu_Mc (int @var{j}, int @var{n}, double @var{q}, double @var{x}, gsl_sf_result @var{*result})
231 @deftypefunx int gsl_sf_mathieu_Ms (int @var{j}, int @var{n}, double @var{q}, double @var{x}, gsl_sf_result @var{*result})
232 These routines compute the radial @var{j}-th kind Mathieu functions
233 @c{$Mc_n^{(j)}(q,x)$}
234 @math{Mc_n^@{(j)@}(q,x)} and
235 @c{$Ms_n^{(j)}(q,x)$}
236 @math{Ms_n^@{(j)@}(q,x)} of order @var{n}.
238 The allowed values of @var{j} are 1 and 2.
239 The functions for @math{j = 3,4} can be computed as
240 @c{$M_n^{(3)} = M_n^{(1)} + iM_n^{(2)}$}
241 @math{M_n^@{(3)@} = M_n^@{(1)@} + iM_n^@{(2)@}} and
242 @c{$M_n^{(4)} = M_n^{(1)} - iM_n^{(2)}$}
243 @math{M_n^@{(4)@} = M_n^@{(1)@} - iM_n^@{(2)@}},
245 @c{$M_n^{(j)} = Mc_n^{(j)}$}
246 @math{M_n^@{(j)@} = Mc_n^@{(j)@}} or
251 @deftypefun int gsl_sf_mathieu_Mc_array (int @var{j}, int @var{nmin}, int @var{nmax}, double @var{q}, double @var{x}, gsl_sf_mathieu_workspace @var{*work}, double @var{result_array}[])
252 @deftypefunx int gsl_sf_mathieu_Ms_array (int @var{j}, int @var{nmin}, int @var{nmax}, double @var{q}, double @var{x}, gsl_sf_mathieu_workspace @var{*work}, double @var{result_array}[])
253 These routines compute a series of the radial Mathieu functions of
254 kind @var{j}, with order from @var{nmin} to @var{nmax} inclusive, storing the
255 results in the array @var{result_array}.