File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -150,3 +150,26 @@ function besselj1(x::Float32)
150
150
return p * s
151
151
end
152
152
end
153
+
154
+ function besselj_large_argument (v, x:: T ) where T
155
+ μ = 4 * v^ 2
156
+ s0 = 1
157
+ s1 = (1 - μ) / 8
158
+ s2 = (- μ^ 2 + 26 μ - 25 ) / 128
159
+ s3 = (- μ^ 3 + 115 μ^ 2 - 1187 μ + 1073 ) / 1024
160
+ s4 = (- 5 μ^ 4 + 1540 μ^ 3 - 56238 μ^ 2 + 430436 μ - 375733 ) / 32768
161
+ s5 = (- 7 μ^ 5 + 4515 μ^ 4 - 397190 μ^ 3 + 9716998 μ^ 2 - 64709091 μ + 55384775 ) / 262144
162
+ s6 = (- 21 μ^ 6 + 24486 μ^ 5 - 4238531 μ^ 4 + 235370036 μ^ 3 - 4733751627 μ^ 2 + 29215626566 μ - 24713030909 ) / 4194304
163
+ s7 = (- 33 μ^ 7 + 63063 μ^ 6 - 18939349 μ^ 5 + 1989535379 μ^ 4 - 87480924739 μ^ 3 + 1573356635461 μ^ 2 - 9268603618823 μ + 7780757249041 ) / 33554432
164
+ s8 = (- 429 μ^ 8 + 1252680 μ^ 7 - 598859404 μ^ 6 + 106122595896 μ^ 5 - 8593140373614 μ^ 4 + 329343318168440 μ^ 3 - 5517359285625804 μ^ 2 + 31505470994964360 μ - 26308967412122125 ) / 2147483648
165
+ s9 = (- 715 μ^ 9 + 3026595 μ^ 8 - 2163210764 μ^ 7 + 597489288988 μ^ 6 - 79979851361130 μ^ 5 + 5536596631240042 μ^ 4 - 194026764558396188 μ^ 3 + 3095397360215483916 μ^ 2 - 17285630127691126691 μ + 14378802319925055947 ) / 17179869184
166
+ s10 = (- 2431 μ^ 10 + 14318590 μ^ 9 - 14587179035 μ^ 8 + 5925778483368 μ^ 7 - 1216961874423502 μ^ 6 + 137164402798287604 μ^ 5 - 8556293060689145118 μ^ 4 + 281576004385356401192 μ^ 3 - 4334421752432088249971 μ^ 2 + 23801928703130666089534 μ - 19740662615375374580231 ) / 274877906944
167
+
168
+ αp = s0 + s1/ x^ 2 + s2/ x^ 4 + s3/ x^ 6 + s4/ x^ 8 + s5/ x^ 10 + s6/ x^ 12 + s7/ x^ 14 + s8/ x^ 16 + s9/ x^ 18 + s10/ x^ 20
169
+ α = s0* x - s1/ x - s2/ 3 x^ 3 - s3/ 5 x^ 5 - s4/ 7 x^ 7 - s5/ 9 x^ 9 - s6/ 11 x^ 11 - s7/ 13 x^ 13 - s8/ 15 x^ 15 - s9/ 17 x^ 17 - s10/ 19 x^ 19
170
+
171
+ α = α - T (pi )/ 4 - T (pi )/ 2 * v
172
+
173
+ b = sqrt (2 / T (pi )) / sqrt (αp * x)
174
+ return cos (α)* b
175
+ end
You can’t perform that action at this time.
0 commit comments