This program is Copyright © 2006 by Jean-Marc Baillard and is used here by permission.
This program is supplied without representation or warranty of any kind. Jean-Marc Baillard and The Museum of HP Calculators therefore assume no responsibility and shall have no liability, consequential or otherwise, of any kind arising from the use of this program material or any part thereof.
Overview
1°) Regular Coulomb Wave Function
2°) Irregular Coulomb Wave Function
-The regular Coulomb wave function FL(n;r) and
the irregular Coulomb wave function GL(n;r) are 2 independant
solutions
of the differential equation: d2y/dr2
+ (1-2n/r-L(L+1)/r2).y = 0
a) Regular Coulomb
Wave Function
Formulae: FL(n;r) = CL(n) r L+1 Sum k>L AkL (n) r k-L-1
with CL(n) = (1/Gam(2L+2))
2L e -pi.n/2 | Gam(L+1+i.n) |
and AL+1L
= 1 ; AL+2L = n/(L+1) ; (k+L)(k-L-1)
AkL = 2n Ak-1L - Ak-2L
( k > L+2 )
Data Registers: R00 thru R05: temp
R06 = r ; R07 = n ; R08 = L ; R09 =
CL(n)
Flags: /
Subroutine: "GAMZ" ( Gamma Function
in the complex plane )
01 LBL "RCWF"
02 STO 06
03 RDN
04 STO 07
05 X<>Y
06 STO 08
07 1
08 +
09 XEQ "GAMZ"
10 LASTX
11 RCL 07
12 PI
13 *
14 2
15 /
16 E^X
17 /
18 2
19 RCL 08
20 Y^X
21 *
22 RCL 08
23 ST+ X
24 1
25 +
26 FACT
27 /
28 STO 09
29 CLX
30 STO 01
31 SIGN
32 STO 02
33 STO 03
34 LBL 01
35 2
36 STO 04
37 X<>Y
38 LBL 02
39 RCL 07
40 ST+ X
41 RCL 02
42 ST* Y
43 X<> 01
44 RCL 06
45 *
46 -
47 RCL 06
48 *
49 RCL 03
50 ST/ Y
51 RCL 08
52 ST+ X
53 +
54 1
55 ST+ 03
56 +
57 /
58 STO 02
59 +
60 X#Y?
61 GTO 01
62 DSE 04
63 GTO 02
64 RCL 09
65 *
66 RCL 06
67 ST* Y
68 RCL 08
69 Y^X
70 *
71 END
( 96 bytes / SIZE 010 )
STACK | INPUTS | OUTPUTS |
Z | L | / |
Y | n | / |
X | r | FL(n;r) |
where L is a non-negative integer,
n is real,
and r is positive.
Example:
2 ENTER^
0.7 ENTER^
1.8 XEQ "RCWF" >>>> F2(
0.7 ; 1.8 ) = 0.141767744 ( in 34 seconds
)
b) Irregular (
Logarithmic ) Coulomb Wave Function
Formulae: GL(n;r) = (1/Pi).(exp(2.Pi.n) - 1) FL(n;r) [ Ln(2r) + qL(n)/pL(n) ] + (1/CL(n)/rL/(2L+1)) Sum k>-L-1 akL (n) r k+L
with a -L-1L = 0 ; a -LL = 1 ; (k+L)(k-L-1) akL = 2n ak-1L - ak-2L - (2k-1).pL(n).AkL and a L+1L = 0
pL(n) = 2n ( 1+n2 )( 4+n2 ) ........... ( L2+n2 ) 22L / ( 2L+1) / [(2L)!]2
qL(n)/pL(n) = Sum s=1,...,L s/(s2+n2) - 1/1 - 1/2 - 1/3 - ...... - 1/(2L+1) + Ré ( Psi(1+i.n) ) + 2.gamma + rL(n)/pL(n) ( gamma = Euler's Constant )
where rL(n) = ( (-1)L+1
/ (2L)! ) Im [ 1/(2L+1) + 2(i.n-L)/1!/(2L) + 22(i.n-L)(i.n-L+1)/2!/(2L-1)
+ ...................................... + 22L(i.n-L)(i.n-L+1)
....... (i.n+L-1)/(2L)! ]
Data Registers: R00 thru R05 &
R11 thru R15: temp
R06 = r ; R07 = n ; R08 = L ; R09 =
CL(n) ; R10 = FL(n;r)
Flags: /
Subroutines: "RCWF" ( regular Coulomb
wave function )
"PSIZ" ( Digamma function in the complex plane )
01 LBL "ICWF"
02 XEQ "RCWF"
03 STO 10
04 RCL 07
05 ST+ X
06 STO 15
07 PI
08 *
09 E^X-1
10 *
11 PI
12 /
13 STO 11
14 RCL 07
15 1
16 XEQ "PSIZ"
17 STO 12
18 RCL 08
19 ST+ X
20 STO 03
21 1
22 +
23 LBL 01
24 1/X
25 ST- 12
26 LASTX
27 DSE X
28 GTO 01
29 STO 02
30 STO 04
31 RCL 15
32 4
33 RCL 08
34 Y^X
35 *
36 1
37 STO 13
38 RCL 03
39 ST+ Y
40 FACT
41 STO 05
42 X^2
43 *
44 /
45 STO 00
46 RCL 08
47 STO 01
48 X=0?
49 GTO 00
50 LBL 02
51 RCL 01
52 ENTER^
53 X^2
54 RCL 07
55 X^2
56 +
57 ST* 00
58 /
59 ST+ 12
60 DSE 01
61 GTO 02
62 LBL 03
63 RCL 07
64 RCL 08
65 RCL 03
66 -
67 R-P
68 X<>Y
69 RCL 02
70 +
71 STO 02
72 X<>Y
73 RCL 13
74 *
75 ST+ X
76 RCL 08
77 ST+ X
78 RCL 03
79 -
80 1
81 +
82 /
83 STO 13
84 P-R
85 CLX
86 RCL 03
87 /
88 ST+ 04
89 DSE 03
90 GTO 03
91 LBL 00
92 RCL 12
93 1
94 CHS
95 RCL 08
96 Y^X
97 RCL 04
98 *
99 RCL 05
100 /
101 RCL 00
102 X=0?
103 SIGN
104 /
105 -
106 1.15443133 2*Euler's
Constant
107 +
108 RCL 06
109 ST+ X
110 LN
111 +
112 ST* 11
113 CLX
114 STO 02
115 STO 03
116 SIGN
117 STO 04
118 STO 05
119 STO 13
120 LBL 04
121 2
122 STO 14
123 LBL 05
124 RCL 15
125 RCL 04
126 ST* Y
127 X<> 03
128 RCL 06
129 *
130 -
131 RCL 06
132 *
133 RCL 15
134 RCL 02
135 ST* Y
136 X<> 01
137 RCL 06
138 *
139 -
140 RCL 06
141 *
142 RCL 05
143 ST/ Y
144 RCL 08
145 ST+ X
146 -
147 1
148 -
149 STO 12
150 X#0?
151 GTO 00
152 RDN
153 CLX
154 RCL 06
155 RCL 05
156 Y^X
157 1
158 LBL 00
159 /
160 STO 02
161 RCL 00
162 *
163 RCL 05
164 RCL 08
165 -
166 ST+ X
167 1
168 -
169 *
170 -
171 RCL 05
172 /
173 RCL 12
174 X#0?
175 /
176 STO 04
177 ISG 05
178 ""
( TEXT 0 or another NOP instruction like STO X )
179 RCL 13
180 +
181 STO 13
182 LASTX
183 X#Y?
184 GTO 04
185 DSE 14
186 GTO 05
187 RCL 06
188 RCL 08
189 Y^X
190 RCL 09
191 *
192 RCL08
193 ST+ X
194 1
195 +
196 *
197 /
198 RCL 11
199 +
200 END
( 259 bytes / SIZE 016 )
STACK | INPUTS | OUTPUTS |
Z | L | / |
Y | n | / |
X | r | GL(n;r) |
where L is a non-negative integer,
n is real,
and r is positive.
FL(n;r) is stored in R10
Example:
3
ENTER^
-0.4
ENTER^
1.2
XEQ "ICWF" >>>> G3( -0.4 ; 1.2 ) =
6.563265438 ( in 102 seconds
)
and we have F3( -0.4 ; 1.2 ) = 0.029547268
in register R10.
-Unfortunately, several significant digits are sometimes cancelled when
the last operation ( line 199 ) is performed.
( Check the value in LASTX or in R11 )
Reference:
Abramowitz and Stegun , "Handbook of Mathematical Functions" - Dover
Publications - ISBN 0-486-61272-4
Go back to the HP-41 software library
Go back to the general software library
Go
back to the main exhibit hall