summaryrefslogtreecommitdiff
path: root/gsl-1.9/doc/specfunc-ellint.texi
blob: 601f9defb2a1caccca27371f02dca318a941d0a0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
@cindex elliptic integrals

The functions described in this section are declared in the header
file @file{gsl_sf_ellint.h}.  Further information about the elliptic
integrals can be found in Abramowitz & Stegun, Chapter 17.

@menu
* Definition of Legendre Forms::  
* Definition of Carlson Forms::  
* Legendre Form of Complete Elliptic Integrals::  
* Legendre Form of Incomplete Elliptic Integrals::  
* Carlson Forms::               
@end menu

@node Definition of Legendre Forms
@subsection Definition of Legendre Forms
@cindex Legendre forms of elliptic integrals
The Legendre forms of elliptic integrals @math{F(\phi,k)},
@math{E(\phi,k)} and @math{\Pi(\phi,k,n)} are defined by,
@tex
\beforedisplay
$$
\eqalign{
F(\phi,k)   &= \int_0^\phi dt {1 \over \sqrt{(1 - k^2 \sin^2(t))}}\cr
E(\phi,k)   &= \int_0^\phi dt   \sqrt{(1 - k^2 \sin^2(t))}\cr
\Pi(\phi,k,n) &= \int_0^\phi dt {1 \over (1 + n \sin^2(t)) \sqrt{1 - k^2 \sin^2(t)}}
}
$$
\afterdisplay
@end tex
@ifinfo

@example
  F(\phi,k) = \int_0^\phi dt 1/\sqrt((1 - k^2 \sin^2(t)))

  E(\phi,k) = \int_0^\phi dt   \sqrt((1 - k^2 \sin^2(t)))

Pi(\phi,k,n) = \int_0^\phi dt 1/((1 + n \sin^2(t))\sqrt(1 - k^2 \sin^2(t)))
@end example

@end ifinfo
@noindent
The complete Legendre forms are denoted by @math{K(k) = F(\pi/2, k)} and
@math{E(k) = E(\pi/2, k)}.  

The notation used here is based on Carlson, @cite{Numerische
Mathematik} 33 (1979) 1 and differs slightly from that used by
Abramowitz & Stegun, where the functions are given in terms of the
parameter @math{m = k^2} and @math{n} is replaced by @math{-n}.

@node Definition of Carlson Forms
@subsection Definition of Carlson Forms
@cindex Carlson forms of Elliptic integrals
The Carlson symmetric forms of elliptical integrals @math{RC(x,y)},
@math{RD(x,y,z)}, @math{RF(x,y,z)} and @math{RJ(x,y,z,p)} are defined
by,
@tex
\beforedisplay
$$
\eqalign{
RC(x,y)   &= 1/2 \int_0^\infty dt (t+x)^{-1/2} (t+y)^{-1}\cr
RD(x,y,z) &= 3/2 \int_0^\infty dt (t+x)^{-1/2} (t+y)^{-1/2} (t+z)^{-3/2}\cr
RF(x,y,z) &= 1/2 \int_0^\infty dt (t+x)^{-1/2} (t+y)^{-1/2} (t+z)^{-1/2}\cr
RJ(x,y,z,p) &= 3/2 \int_0^\infty dt (t+x)^{-1/2} (t+y)^{-1/2} (t+z)^{-1/2} (t+p)^{-1}
}
$$
\afterdisplay
@end tex
@ifinfo

@example
    RC(x,y) = 1/2 \int_0^\infty dt (t+x)^(-1/2) (t+y)^(-1)

  RD(x,y,z) = 3/2 \int_0^\infty dt (t+x)^(-1/2) (t+y)^(-1/2) (t+z)^(-3/2)

  RF(x,y,z) = 1/2 \int_0^\infty dt (t+x)^(-1/2) (t+y)^(-1/2) (t+z)^(-1/2)

RJ(x,y,z,p) = 3/2 \int_0^\infty dt 
                 (t+x)^(-1/2) (t+y)^(-1/2) (t+z)^(-1/2) (t+p)^(-1)
@end example
@end ifinfo

@node Legendre Form of Complete Elliptic Integrals
@subsection Legendre Form of Complete Elliptic Integrals

@deftypefun double gsl_sf_ellint_Kcomp (double @var{k}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_Kcomp_e (double @var{k}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the complete elliptic integral @math{K(k)} to
the accuracy specified by the mode variable @var{mode}.  
Note that Abramowitz & Stegun define this function in terms of the
parameter @math{m = k^2}.
@comment Exceptional Return Values:  GSL_EDOM
@end deftypefun

@deftypefun double gsl_sf_ellint_Ecomp (double @var{k}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_Ecomp_e (double @var{k}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the complete elliptic integral @math{E(k)} to the
accuracy specified by the mode variable @var{mode}.
Note that Abramowitz & Stegun define this function in terms of the
parameter @math{m = k^2}.
@comment Exceptional Return Values:  GSL_EDOM
@end deftypefun

@deftypefun double gsl_sf_ellint_Pcomp (double @var{k}, double @var{n}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_Pcomp_e (double @var{k}, double @var{n},  gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the complete elliptic integral @math{\Pi(k,n)} to the
accuracy specified by the mode variable @var{mode}.
Note that Abramowitz & Stegun define this function in terms of the
parameters @math{m = k^2} and @math{\sin^2(\alpha) = k^2}, with the
change of sign @math{n \to -n}.
@comment Exceptional Return Values:  GSL_EDOM
@end deftypefun

@node Legendre Form of Incomplete Elliptic Integrals
@subsection Legendre Form of Incomplete Elliptic Integrals

@deftypefun double gsl_sf_ellint_F (double @var{phi}, double @var{k}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_F_e (double @var{phi}, double @var{k}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the incomplete elliptic integral @math{F(\phi,k)}
to the accuracy specified by the mode variable @var{mode}.
Note that Abramowitz & Stegun define this function in terms of the
parameter @math{m = k^2}.
@comment Exceptional Return Values: GSL_EDOM
@end deftypefun

@deftypefun double gsl_sf_ellint_E (double @var{phi}, double @var{k}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_E_e (double @var{phi}, double @var{k}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the incomplete elliptic integral @math{E(\phi,k)}
to the accuracy specified by the mode variable @var{mode}.
Note that Abramowitz & Stegun define this function in terms of the
parameter @math{m = k^2}.
@comment Exceptional Return Values: GSL_EDOM
@end deftypefun

@deftypefun double gsl_sf_ellint_P (double @var{phi}, double @var{k}, double @var{n}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_P_e (double @var{phi}, double @var{k}, double @var{n}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the incomplete elliptic integral @math{\Pi(\phi,k,n)}
to the accuracy specified by the mode variable @var{mode}.
Note that Abramowitz & Stegun define this function in terms of the
parameters @math{m = k^2} and @math{\sin^2(\alpha) = k^2}, with the
change of sign @math{n \to -n}.
@comment Exceptional Return Values: GSL_EDOM
@end deftypefun

@deftypefun double gsl_sf_ellint_D (double @var{phi}, double @var{k}, double @var{n}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_D_e (double @var{phi}, double @var{k}, double @var{n}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These functions compute the incomplete elliptic integral
@math{D(\phi,k)} which is defined through the Carlson form @math{RD(x,y,z)}
by the following relation, 
@tex
\beforedisplay
$$
D(\phi,k,n) = {1 \over 3} (\sin \phi)^3 RD (1-\sin^2(\phi), 1-k^2 \sin^2(\phi), 1).
$$
\afterdisplay
@end tex
@ifinfo

@example
D(\phi,k,n) = (1/3)(\sin(\phi))^3 RD (1-\sin^2(\phi), 1-k^2 \sin^2(\phi), 1).
@end example
@end ifinfo
The argument @var{n} is not used and will be removed in a future release.

@comment Exceptional Return Values: GSL_EDOM
@end deftypefun


@node Carlson Forms
@subsection Carlson Forms

@deftypefun double gsl_sf_ellint_RC (double @var{x}, double @var{y}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_RC_e (double @var{x}, double @var{y}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the incomplete elliptic integral @math{RC(x,y)}
to the accuracy specified by the mode variable @var{mode}.
@comment Exceptional Return Values: GSL_EDOM
@end deftypefun

@deftypefun double gsl_sf_ellint_RD (double @var{x}, double @var{y}, double @var{z}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_RD_e (double @var{x}, double @var{y}, double @var{z}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the incomplete elliptic integral @math{RD(x,y,z)}
to the accuracy specified by the mode variable @var{mode}.
@comment Exceptional Return Values: GSL_EDOM
@end deftypefun

@deftypefun double gsl_sf_ellint_RF (double @var{x}, double @var{y}, double @var{z}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_RF_e (double @var{x}, double @var{y}, double @var{z}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the incomplete elliptic integral @math{RF(x,y,z)}
to the accuracy specified by the mode variable @var{mode}.
@comment Exceptional Return Values: GSL_EDOM
@end deftypefun

@deftypefun double gsl_sf_ellint_RJ (double @var{x}, double @var{y}, double @var{z}, double @var{p}, gsl_mode_t @var{mode})
@deftypefunx int gsl_sf_ellint_RJ_e (double @var{x}, double @var{y}, double @var{z}, double @var{p}, gsl_mode_t @var{mode}, gsl_sf_result * @var{result})
These routines compute the incomplete elliptic integral @math{RJ(x,y,z,p)}
to the accuracy specified by the mode variable @var{mode}.
@comment Exceptional Return Values: GSL_EDOM
@end deftypefun