Coverage for pygeodesy/auxilats/_CX_6.py: 100%

9 statements  

« prev     ^ index     » next       coverage.py v7.2.2, created at 2024-06-10 14:08 -0400

1 

2# -*- coding: utf-8 -*- 

3 

4u'''Coeficients for C{_AUXLATITUDE_ORDER} 6 from I{Karney}'s C++ class U{AuxLatitude 

5<https://GeographicLib.SourceForge.io/C++/doc/classGeographicLib_1_1AuxLatitude.html>} 

6trancoded to a double, uniquified Python C{dict[auxout][auxin]}. 

7 

8Copyright (C) Charles Karney (2022-2023) Karney@Alum.MIT.edu> and licensed under the 

9MIT/X11 License. For more information, see <https:#GeographicLib.SourceForge.io>. 

10''' 

11# make sure int/int division yields float quotient 

12from __future__ import division as _; del _ # PYCHOK semicolon 

13 

14from pygeodesy.auxilats.auxily import Aux, _Ufloats 

15from pygeodesy.constants import _0_0, _0_25, _0_5, _1_0, _N_1_0, _1_5, \ 

16 _2_0, _N_2_0, _4_0, _6_0, _8_0, _16_0 

17 

18__all__ = () 

19__version__ = '23.08.19' 

20 

21_f, _u = float, _Ufloats() 

22_coeffs_6 = _u._Coeffs(6, { # GEOGRAPHICLIB_AUXLATITUDE_ORDER == 6 

23 Aux.PHI: { 

24 # C[phi,phi] skipped 

25 Aux.BETA: _u( # C[phi,beta]; even coeffs only 

26 _0_0, _0_0, _1_0, 

27 _0_0, _0_0, _0_5, 

28 _0_0, 1 / _f(3), 

29 _0_0, _0_25, 

30 1 / _f(5), 

31 1 / _f(6),), 

32 Aux.THETA: _u( # C[phi,theta]; even coeffs only 

33 _2_0, _N_2_0, _2_0, 

34 _6_0, -_4_0, _2_0, 

35 -_8_0, 8 / _f(3), 

36 -_16_0, _4_0, 

37 32 / _f(5), 

38 32 / _f(3),), 

39 Aux.MU: _u( # C[phi,mu]; even coeffs only 

40 269 / _f(512), -27 / _f(32), _1_5, 

41 6759 / _f(4096), -55 / _f(32), 21 / _f(16), 

42 -417 / _f(128), 151 / _f(96), 

43 -15543 / _f(2560), 1097 / _f(512), 

44 8011 / _f(2560), 

45 293393 / _f(61440),), 

46 Aux.CHI: _u( # C[phi,chi] 

47 -2854 / _f(675), 26 / _f(45), 116 / _f(45), _N_2_0, -2 / _f(3), _2_0, 

48 2323 / _f(945), 2704 / _f(315), -227 / _f(45), -8 / _f(5), 7 / _f(3), 

49 73814 / _f(2835), -1262 / _f(105), -136 / _f(35), 56 / _f(15), 

50 -399572 / _f(14175), -332 / _f(35), 4279 / _f(630), 

51 -144838 / _f(6237), 4174 / _f(315), 

52 601676 / _f(22275),), 

53 Aux.XI: _u( # C[phi,xi] 

54 28112932 / _f(212837625), 60136 / _f(467775), -2582 / _f(14175), 

55 -16 / _f(35), 4 / _f(45), 4 / _f(3), 

56 251310128 / _f(638512875), -21016 / _f(51975), -11966 / _f(14175), 

57 152 / _f(945), 46 / _f(45), 

58 -8797648 / _f(10945935), -94388 / _f(66825), 3802 / _f(14175), 

59 3044 / _f(2835), 

60 -1472637812 / _f(638512875), 41072 / _f(93555), 6059 / _f(4725), 

61 455935736 / _f(638512875), 768272 / _f(467775), 

62 4210684958 / _f(1915538625),) 

63 }, 

64 Aux.BETA: { 

65 Aux.PHI: _u( # C[beta,phi]; even coeffs only 

66 _0_0, _0_0, _N_1_0, 

67 _0_0, _0_0, _0_5, 

68 _0_0, -1 / _f(3), 

69 _0_0, _0_25, 

70 -1 / _f(5), 

71 1 / _f(6),), 

72 # C[beta,beta] skipped 

73 Aux.THETA: _u( # C[beta,theta]; even coeffs only 

74 _0_0, _0_0, _1_0, 

75 _0_0, _0_0, _0_5, 

76 _0_0, 1 / _f(3), 

77 _0_0, _0_25, 

78 1 / _f(5), 

79 1 / _f(6),), 

80 Aux.MU: _u( # C[beta,mu]; even coeffs only 

81 205 / _f(1536), -9 / _f(32), _0_5, 

82 1335 / _f(4096), -37 / _f(96), 5 / _f(16), 

83 -75 / _f(128), 29 / _f(96), 

84 -2391 / _f(2560), 539 / _f(1536), 

85 3467 / _f(7680), 

86 38081 / _f(61440),), 

87 Aux.CHI: _u( # C[beta,chi] 

88 -3118 / _f(4725), -1 / _f(3), 38 / _f(45), -1 / _f(3), -2 / _f(3), _1_0, 

89 -247 / _f(270), 50 / _f(21), -7 / _f(9), -14 / _f(15), 5 / _f(6), 

90 17564 / _f(2835), -5 / _f(3), -34 / _f(21), 16 / _f(15), 

91 -49877 / _f(14175), -28 / _f(9), 2069 / _f(1260), 

92 -28244 / _f(4455), 883 / _f(315), 

93 797222 / _f(155925),), 

94 Aux.XI: _u( # C[beta,xi] 

95 7947332 / _f(212837625), 11824 / _f(467775), -1082 / _f(14175), 

96 -46 / _f(315), 4 / _f(45), 1 / _f(3), 

97 39946703 / _f(638512875), -16672 / _f(155925), -338 / _f(2025), 

98 68 / _f(945), 17 / _f(90), 

99 -255454 / _f(1563705), -101069 / _f(467775), 1102 / _f(14175), 

100 461 / _f(2835), 

101 -189032762 / _f(638512875), 1786 / _f(18711), 3161 / _f(18900), 

102 80274086 / _f(638512875), 88868 / _f(467775), 

103 880980241 / _f(3831077250),) 

104 }, 

105 Aux.THETA: { 

106 Aux.PHI: _u( # C[theta,phi]; even coeffs only 

107 _N_2_0, _2_0, _N_2_0, 

108 _6_0, -_4_0, _2_0, 

109 _8_0, -8 / _f(3), 

110 -_16_0, _4_0, 

111 -32 / _f(5), 

112 32 / _f(3),), 

113 Aux.BETA: _u( # C[theta,beta]; even coeffs only 

114 _0_0, _0_0, _N_1_0, 

115 _0_0, _0_0, _0_5, 

116 _0_0, -1 / _f(3), 

117 _0_0, _0_25, 

118 -1 / _f(5), 

119 1 / _f(6),), 

120 # C[theta,theta] skipped 

121 Aux.MU: _u( # C[theta,mu]; even coeffs only 

122 499 / _f(1536), -23 / _f(32), -1 / _f(2), 

123 6565 / _f(12288), -5 / _f(96), 5 / _f(16), 

124 -77 / _f(128), 1 / _f(32), 

125 -4037 / _f(7680), 283 / _f(1536), 

126 1301 / _f(7680), 

127 17089 / _f(61440),), 

128 Aux.CHI: _u( # C[theta,chi] 

129 -3658 / _f(4725), 2 / _f(9), 4 / _f(9), -2 / _f(3), -2 / _f(3), _0_0, 

130 61 / _f(135), 68 / _f(45), -23 / _f(45), -4 / _f(15), 1 / _f(3), 

131 9446 / _f(2835), -46 / _f(35), -24 / _f(35), 2 / _f(5), 

132 -34712 / _f(14175), -80 / _f(63), 83 / _f(126), 

133 -2362 / _f(891), 52 / _f(45), 

134 335882 / _f(155925),), 

135 Aux.XI: _u( # C[theta,xi] 

136 216932 / _f(2627625), 109042 / _f(467775), -2102 / _f(14175), 

137 -158 / _f(315), 4 / _f(45), -2 / _f(3), 

138 117952358 / _f(638512875), -7256 / _f(155925), 934 / _f(14175), 

139 -16 / _f(945), 16 / _f(45), 

140 -7391576 / _f(54729675), -25286 / _f(66825), 922 / _f(14175), 

141 -232 / _f(2835), 

142 -67048172 / _f(638512875), 268 / _f(18711), 719 / _f(4725), 

143 46774256 / _f(638512875), 14354 / _f(467775), 

144 253129538 / _f(1915538625),) 

145 }, 

146 Aux.MU: { 

147 Aux.PHI: _u( # C[mu,phi]; even coeffs only 

148 -3 / _f(32), 9 / _f(16), -3 / _f(2), 

149 135 / _f(2048), -15 / _f(32), 15 / _f(16), 

150 105 / _f(256), -35 / _f(48), 

151 -189 / _f(512), 315 / _f(512), 

152 -693 / _f(1280), 

153 1001 / _f(2048),), 

154 Aux.BETA: _u( # C[mu,beta]; even coeffs only 

155 -1 / _f(32), 3 / _f(16), -1 / _f(2), 

156 -9 / _f(2048), 1 / _f(32), -1 / _f(16), 

157 3 / _f(256), -1 / _f(48), 

158 3 / _f(512), -5 / _f(512), 

159 -7 / _f(1280), 

160 -7 / _f(2048),), 

161 Aux.THETA: _u( # C[mu,theta]; even coeffs only 

162 -15 / _f(32), 13 / _f(16), _0_5, 

163 -1673 / _f(2048), 33 / _f(32), -1 / _f(16), 

164 349 / _f(256), -5 / _f(16), 

165 963 / _f(512), -261 / _f(512), 

166 -921 / _f(1280), 

167 -6037 / _f(6144),), 

168 # C[mu,mu] skipped 

169 Aux.CHI: _u( # C[mu,chi] 

170 7891 / _f(37800), -127 / _f(288), 41 / _f(180), 5 / _f(16), -2 / _f(3), 

171 _0_5, 

172 -1983433 / _f(1935360), 281 / _f(630), 557 / _f(1440), -3 / _f(5), 

173 13 / _f(48), 

174 167603 / _f(181440), 15061 / _f(26880), -103 / _f(140), 61 / _f(240), 

175 6601661 / _f(7257600), -179 / _f(168), 49561 / _f(161280), 

176 -3418889 / _f(1995840), 34729 / _f(80640), 

177 212378941 / _f(319334400),), 

178 Aux.XI: _u( # C[mu,xi] 

179 12674323 / _f(851350500), -384229 / _f(14968800), -1609 / _f(28350), 

180 121 / _f(1680), 4 / _f(45), -1 / _f(6), 

181 -31621753811 / _f(1307674368000), -431 / _f(17325), 

182 16463 / _f(453600), 26 / _f(945), -29 / _f(720), 

183 -32844781 / _f(1751349600), 3746047 / _f(119750400), 449 / _f(28350), 

184 -1003 / _f(45360), 

185 10650637121 / _f(326918592000), 629 / _f(53460), 

186 -40457 / _f(2419200), 

187 205072597 / _f(20432412000), -1800439 / _f(119750400), 

188 -59109051671 / _f(3923023104000),) 

189 }, 

190 Aux.CHI: { 

191 Aux.PHI: _u( # C[chi,phi] 

192 4642 / _f(4725), 32 / _f(45), -82 / _f(45), 4 / _f(3), 2 / _f(3), _N_2_0, 

193 -1522 / _f(945), 904 / _f(315), -13 / _f(9), -16 / _f(15), 5 / _f(3), 

194 -12686 / _f(2835), 8 / _f(5), 34 / _f(21), -26 / _f(15), 

195 -24832 / _f(14175), -12 / _f(5), 1237 / _f(630), 

196 109598 / _f(31185), -734 / _f(315), 

197 444337 / _f(155925),), 

198 Aux.BETA: _u( # C[chi,beta] 

199 -998 / _f(4725), 2 / _f(5), -16 / _f(45), _0_0, 2 / _f(3), _N_1_0, 

200 -2 / _f(27), -22 / _f(105), 19 / _f(45), -2 / _f(5), 1 / _f(6), 

201 116 / _f(567), -22 / _f(105), 16 / _f(105), -1 / _f(15), 

202 2123 / _f(14175), -8 / _f(105), 17 / _f(1260), 

203 128 / _f(4455), -1 / _f(105), 

204 149 / _f(311850),), 

205 Aux.THETA: _u( # C[chi,theta] 

206 1042 / _f(4725), -14 / _f(45), -2 / _f(9), 2 / _f(3), 2 / _f(3), _0_0, 

207 -712 / _f(945), -4 / _f(45), 43 / _f(45), 4 / _f(15), -1 / _f(3), 

208 274 / _f(2835), 124 / _f(105), 2 / _f(105), -2 / _f(5), 

209 21068 / _f(14175), -16 / _f(105), -55 / _f(126), 

210 -9202 / _f(31185), -22 / _f(45), 

211 -90263 / _f(155925),), 

212 Aux.MU: _u( # C[chi,mu] 

213 -96199 / _f(604800), 81 / _f(512), 1 / _f(360), -37 / _f(96), 2 / _f(3), 

214 -1 / _f(2), 

215 1118711 / _f(3870720), -46 / _f(105), 437 / _f(1440), -1 / _f(15), 

216 -1 / _f(48), 

217 -5569 / _f(90720), 209 / _f(4480), 37 / _f(840), -17 / _f(480), 

218 830251 / _f(7257600), 11 / _f(504), -4397 / _f(161280), 

219 108847 / _f(3991680), -4583 / _f(161280), 

220 -20648693 / _f(638668800),), 

221 # C[chi,chi] skipped 

222 Aux.XI: _u( # C[chi,xi] 

223 -55271278 / _f(212837625), 27128 / _f(93555), -2312 / _f(14175), 

224 -88 / _f(315), 34 / _f(45), -2 / _f(3), 

225 106691108 / _f(638512875), -65864 / _f(155925), 6079 / _f(14175), 

226 -184 / _f(945), 1 / _f(45), 

227 5921152 / _f(54729675), -14246 / _f(467775), 772 / _f(14175), 

228 -106 / _f(2835), 

229 75594328 / _f(638512875), -5312 / _f(467775), -167 / _f(9450), 

230 2837636 / _f(638512875), -248 / _f(13365), 

231 -34761247 / _f(1915538625),) 

232 }, 

233 Aux.XI: { 

234 Aux.PHI: _u( # C[xi,phi] 

235 -44732 / _f(2837835), 20824 / _f(467775), 538 / _f(4725), 88 / _f(315), 

236 -4 / _f(45), -4 / _f(3), 

237 -12467764 / _f(212837625), -37192 / _f(467775), -2482 / _f(14175), 

238 8 / _f(105), 34 / _f(45), 

239 100320856 / _f(1915538625), 54968 / _f(467775), -898 / _f(14175), 

240 -1532 / _f(2835), 

241 -5884124 / _f(70945875), 24496 / _f(467775), 6007 / _f(14175), 

242 -839792 / _f(19348875), -23356 / _f(66825), 

243 570284222 / _f(1915538625),), 

244 Aux.BETA: _u( # C[xi,beta] 

245 -70496 / _f(8513505), 2476 / _f(467775), 34 / _f(675), 32 / _f(315), 

246 -4 / _f(45), -1 / _f(3), 

247 53836 / _f(212837625), 3992 / _f(467775), 74 / _f(2025), -4 / _f(315), 

248 -7 / _f(90), 

249 -661844 / _f(1915538625), 7052 / _f(467775), 2 / _f(14175), 

250 -83 / _f(2835), 

251 1425778 / _f(212837625), 934 / _f(467775), -797 / _f(56700), 

252 390088 / _f(212837625), -3673 / _f(467775), 

253 -18623681 / _f(3831077250),), 

254 Aux.THETA: _u( # C[xi,theta] 

255 -4286228 / _f(42567525), -193082 / _f(467775), 778 / _f(4725), 

256 62 / _f(105), -4 / _f(45), 2 / _f(3), 

257 -61623938 / _f(70945875), 92696 / _f(467775), 12338 / _f(14175), 

258 -32 / _f(315), 4 / _f(45), 

259 427003576 / _f(1915538625), 612536 / _f(467775), -1618 / _f(14175), 

260 -524 / _f(2835), 

261 427770788 / _f(212837625), -8324 / _f(66825), -5933 / _f(14175), 

262 -9153184 / _f(70945875), -320044 / _f(467775), 

263 -1978771378 / _f(1915538625),), 

264 Aux.MU: _u( # C[xi,mu] 

265 -9292991 / _f(302702400), 7764059 / _f(239500800), 1297 / _f(18900), 

266 -817 / _f(10080), -4 / _f(45), 1 / _f(6), 

267 36019108271 / _f(871782912000), 35474 / _f(467775), 

268 -29609 / _f(453600), -2 / _f(35), 49 / _f(720), 

269 3026004511 / _f(30648618000), -4306823 / _f(59875200), 

270 -2917 / _f(56700), 4463 / _f(90720), 

271 -368661577 / _f(4036032000), -102293 / _f(1871100), 

272 331799 / _f(7257600), 

273 -875457073 / _f(13621608000), 11744233 / _f(239500800), 

274 453002260127 / _f(7846046208000),), 

275 Aux.CHI: _u( # C[xi,chi] 

276 2706758 / _f(42567525), -55222 / _f(93555), 2458 / _f(4725), 

277 46 / _f(315), -34 / _f(45), 2 / _f(3), 

278 -340492279 / _f(212837625), 516944 / _f(467775), 3413 / _f(14175), 

279 -256 / _f(315), 19 / _f(45), 

280 4430783356 / _f(1915538625), 206834 / _f(467775), -15958 / _f(14175), 

281 248 / _f(567), 

282 62016436 / _f(70945875), -832976 / _f(467775), 16049 / _f(28350), 

283 -651151712 / _f(212837625), 15602 / _f(18711), 

284 2561772812 / _f(1915538625),) # PYCHOK exported 

285 # C[xi,xi] skipped 

286 } 

287}) 

288# _ptrs_6 = (0, 0, 12, 24, 36, 57, 78, 90, 90, 102, 114, 135, 

289# 156, 168, 180, 180, 192, 213, 234, 246, 258, 270, 270, 291, 

290# 312, 333, 354, 375, 396, 396, 417, 438, 459, 480, 501, 522, 

291# 522) # PYCHOK exported 

292del _f, _u 

293 

294# **) MIT License 

295# 

296# Copyright (C) 2023-2024 -- mrJean1 at Gmail -- All Rights Reserved. 

297# 

298# Permission is hereby granted, free of charge, to any person obtaining a 

299# copy of this software and associated documentation files (the "Software"), 

300# to deal in the Software without restriction, including without limitation 

301# the rights to use, copy, modify, merge, publish, distribute, sublicense, 

302# and/or sell copies of the Software, and to permit persons to whom the 

303# Software is furnished to do so, subject to the following conditions: 

304# 

305# The above copyright notice and this permission notice shall be included 

306# in all copies or substantial portions of the Software. 

307# 

308# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 

309# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 

310# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 

311# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR 

312# OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 

313# ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 

314# OTHER DEALINGS IN THE SOFTWARE.