-
Notifications
You must be signed in to change notification settings - Fork 106
/
plegendrea_d1.1
81 lines (81 loc) · 3.1 KB
/
plegendrea_d1.1
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
.\" Automatically generated by Pandoc 2.0.3
.\"
.TH "plegendrea_d1" "1" "2016\-12\-15" "Fortran 95" "SHTOOLS 4.1"
.hy
.SH PLegendreA_d1
.PP
Compute all the unnormalized associated Legendre functions and first
derivatives.
.SH Usage
.PP
call PLegendreA_d1 (\f[C]p\f[], \f[C]dp\f[], \f[C]lmax\f[], \f[C]z\f[],
\f[C]csphase\f[], \f[C]exitstatus\f[])
.SH Parameters
.TP
.B \f[C]p\f[] : output, real*8, dimension ((\f[C]lmax\f[]+1)*(\f[C]lmax\f[]+2)/2)
An array of unnormalized associated Legendre functions up to degree
\f[C]lmax\f[].
The index corresponds to \f[C]l*(l+1)/2+m+1\f[], which can be calculated
by a call to \f[C]PlmIndex\f[].
.RS
.RE
.TP
.B \f[C]dp\f[] : output, real*8, dimension ((\f[C]lmax\f[]+1)*(\f[C]lmax\f[]+2)/2)
An array of the first derivatives of the unnormalized associated
Legendre functions up to degree \f[C]lmax\f[].
The index corresponds to \f[C]l*(l+1)/2+m+1\f[], which can be calculated
by a call to \f[C]PlmIndex\f[].
.RS
.RE
.TP
.B \f[C]lmax\f[] : input, integer
The maximum degree of the associated Legendre functions to be computed.
.RS
.RE
.TP
.B \f[C]z\f[] : input, real*8
The argument of the associated Legendre functions.
.RS
.RE
.TP
.B \f[C]csphase\f[] : input, optional, integer, default = 1
If 1 (default), the Condon\-Shortley phase will be excluded.
If \-1, the Condon\-Shortley phase of (\-1)^m will be appended to the
associated Legendre functions.
.RS
.RE
.TP
.B \f[C]exitstatus\f[] : output, optional, integer
If present, instead of executing a STOP when an error is encountered,
the variable exitstatus will be returned describing the error.
0 = No errors; 1 = Improper dimensions of input array; 2 = Improper
bounds for input variable; 3 = Error allocating memory; 4 = File IO
error.
.RS
.RE
.SH Description
.PP
\f[C]PLegendreA_d1\f[] will calculate all of the unnormalized associated
Legendre functions and first derivatives up to degree \f[C]lmax\f[] for
a given argument.
These are calculated using a standard three\-term recursion formula and
hence will overflow for moderate values of \f[C]l\f[] and \f[C]m\f[].
The index of the array corresponding to a given degree \f[C]l\f[] and
angular order \f[C]m\f[] corresponds to \f[C]l*(l+1)/2+m+1\f[], which
can be calculated by a call to \f[C]PlmIndex\f[].
The integral of the associated Legendre functions over the interval
[\-1, 1] is \f[C]2*(l+m)!/(l\-m)!/(2l+1)\f[].
The default is to exclude the Condon\-Shortley phase, but this can be
modified by setting the optional argument \f[C]csphase\f[] to \-1.
Note that the derivative of the Legendre polynomials is calculated with
respect to its arguement \f[C]z\f[], and not latitude or colatitude.
If \f[C]z=cos(theta)\f[], where \f[C]theta\f[] is the colatitude, then
it is only necessary to multiply \f[C]dp\f[] by \f[C]\-sin(theta)\f[] to
obtain the derivative with respect to \f[C]theta\f[].
.SH See also
.PP
\f[C]plbar\f[], \f[C]plbar_d1\f[], \f[C]plmbar\f[], \f[C]plmbar_d1\f[],
\f[C]plon\f[], \f[C]plon_d1\f[], \f[C]plmon\f[], \f[C]plmon_d1\f[],
\f[C]plschmidt\f[], \f[C]plschmidt_d1\f[], \f[C]plmschmidt\f[],
\f[C]plmschmidt_d1\f[], \f[C]plegendre\f[], \f[C]plegendre_d1\f[],
\f[C]plegendrea\f[], \f[C]plmindex\f[]