pygeodesy 24.10.24__py2.py3-none-any.whl → 24.11.11__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {PyGeodesy-24.10.24.dist-info → PyGeodesy-24.11.11.dist-info}/METADATA +4 -4
- {PyGeodesy-24.10.24.dist-info → PyGeodesy-24.11.11.dist-info}/RECORD +54 -54
- {PyGeodesy-24.10.24.dist-info → PyGeodesy-24.11.11.dist-info}/WHEEL +1 -1
- pygeodesy/__init__.py +2 -2
- pygeodesy/azimuthal.py +51 -61
- pygeodesy/basics.py +34 -33
- pygeodesy/booleans.py +36 -36
- pygeodesy/cartesianBase.py +5 -5
- pygeodesy/constants.py +4 -4
- pygeodesy/css.py +7 -8
- pygeodesy/deprecated/__init__.py +1 -1
- pygeodesy/deprecated/classes.py +9 -9
- pygeodesy/deprecated/functions.py +6 -6
- pygeodesy/ecef.py +11 -14
- pygeodesy/ellipsoidalBase.py +105 -120
- pygeodesy/ellipsoidalBaseDI.py +114 -118
- pygeodesy/ellipsoidalExact.py +35 -37
- pygeodesy/ellipsoids.py +3 -3
- pygeodesy/errors.py +24 -24
- pygeodesy/etm.py +80 -72
- pygeodesy/fmath.py +39 -37
- pygeodesy/formy.py +3 -2
- pygeodesy/fsums.py +51 -40
- pygeodesy/geodesicw.py +15 -14
- pygeodesy/geodesicx/__init__.py +2 -2
- pygeodesy/geodsolve.py +7 -16
- pygeodesy/geoids.py +5 -5
- pygeodesy/heights.py +2 -2
- pygeodesy/internals.py +63 -79
- pygeodesy/karney.py +2 -2
- pygeodesy/ktm.py +11 -13
- pygeodesy/latlonBase.py +6 -6
- pygeodesy/lazily.py +5 -5
- pygeodesy/lcc.py +4 -4
- pygeodesy/ltp.py +10 -10
- pygeodesy/ltpTuples.py +74 -75
- pygeodesy/mgrs.py +9 -10
- pygeodesy/named.py +4 -0
- pygeodesy/osgr.py +9 -12
- pygeodesy/props.py +2 -2
- pygeodesy/resections.py +9 -10
- pygeodesy/rhumb/__init__.py +1 -1
- pygeodesy/rhumb/solve.py +3 -3
- pygeodesy/simplify.py +5 -5
- pygeodesy/sphericalNvector.py +80 -123
- pygeodesy/sphericalTrigonometry.py +60 -66
- pygeodesy/units.py +2 -2
- pygeodesy/utm.py +6 -6
- pygeodesy/vector2d.py +13 -13
- pygeodesy/vector3d.py +19 -21
- pygeodesy/vector3dBase.py +18 -15
- pygeodesy/webmercator.py +4 -4
- pygeodesy/wgrs.py +4 -4
- {PyGeodesy-24.10.24.dist-info → PyGeodesy-24.11.11.dist-info}/top_level.txt +0 -0
pygeodesy/units.py
CHANGED
|
@@ -27,7 +27,7 @@ from pygeodesy.unitsBase import Float, Int, _NamedUnit, Radius, Str, Fmt, fstr
|
|
|
27
27
|
from math import degrees, isnan, radians
|
|
28
28
|
|
|
29
29
|
__all__ = _ALL_LAZY.units
|
|
30
|
-
__version__ = '24.
|
|
30
|
+
__version__ = '24.11.06'
|
|
31
31
|
|
|
32
32
|
|
|
33
33
|
class Float_(Float):
|
|
@@ -527,7 +527,7 @@ class FIx(Float_):
|
|
|
527
527
|
(C{bool}) or C{None} for backward compatible L{LatLon2Tuple} or
|
|
528
528
|
B{C{LatLon}} with I{averaged} lat- and longitudes.
|
|
529
529
|
@kwarg LatLon_or_Vector_and_kwds: Optional C{B{LatLon}=None} I{or} C{B{Vector}=None}
|
|
530
|
-
to return the I{intermediate}, I{fractional} point and
|
|
530
|
+
to return the I{intermediate}, I{fractional} point and optionally,
|
|
531
531
|
additional B{C{LatLon}} I{or} B{C{Vector}} keyword arguments, see
|
|
532
532
|
function L{fractional<pygeodesy.points.fractional>}.
|
|
533
533
|
|
pygeodesy/utm.py
CHANGED
|
@@ -39,7 +39,7 @@ from pygeodesy.datums import _ellipsoidal_datum, _WGS84, _under
|
|
|
39
39
|
from pygeodesy.dms import degDMS, parseDMS2
|
|
40
40
|
from pygeodesy.errors import MGRSError, RangeError, _ValueError, \
|
|
41
41
|
_xkwds_get, _xkwds_pop2
|
|
42
|
-
from pygeodesy.fmath import fdot3, hypot, hypot1, _operator
|
|
42
|
+
from pygeodesy.fmath import fdot_, fdot3, hypot, hypot1, _operator
|
|
43
43
|
# from pygeodesy.internals import _under # from .datums
|
|
44
44
|
from pygeodesy.interns import MISSING, NN, _by_, _COMMASPACE_, _N_, \
|
|
45
45
|
_NS_, _outside_, _range_, _S_, _scale0_, \
|
|
@@ -63,7 +63,7 @@ from math import asinh, atanh, atan2, cos, cosh, degrees, fabs, \
|
|
|
63
63
|
# import operator as _operator # from .fmath
|
|
64
64
|
|
|
65
65
|
__all__ = _ALL_LAZY.utm
|
|
66
|
-
__version__ = '24.
|
|
66
|
+
__version__ = '24.11.07'
|
|
67
67
|
|
|
68
68
|
_Bands = 'CDEFGHJKLMNPQRSTUVWXX' # UTM latitude bands C..X (no
|
|
69
69
|
# I|O) 8° each, covering 80°S to 84°N and X repeated for 80-84°N
|
|
@@ -566,12 +566,12 @@ def toUtm8(latlon, lon=None, datum=None, Utm=Utm, falsed=True,
|
|
|
566
566
|
# easting, northing: Karney 2011 Eq 7-14, 29, 35
|
|
567
567
|
sb, cb = sincos2(b)
|
|
568
568
|
|
|
569
|
-
T
|
|
569
|
+
T = tan(a)
|
|
570
570
|
T12 = hypot1(T)
|
|
571
|
-
S
|
|
571
|
+
S = sinh(E.e * atanh(E.e * T / T12))
|
|
572
572
|
|
|
573
|
-
T_ = T
|
|
574
|
-
H
|
|
573
|
+
T_ = fdot_(T, hypot1(S), -S, T12)
|
|
574
|
+
H = hypot(T_, cb)
|
|
575
575
|
|
|
576
576
|
y = atan2(T_, cb) # ξ' ksi
|
|
577
577
|
x = asinh(sb / H) # η' eta
|
pygeodesy/vector2d.py
CHANGED
|
@@ -12,7 +12,7 @@ from pygeodesy.constants import EPS, EPS0, EPS02, EPS4, INF, INT0, \
|
|
|
12
12
|
_1_0, _1_0_1T, _N_1_0, _2_0, _N_2_0, _4_0
|
|
13
13
|
from pygeodesy.errors import _and, _AssertionError, IntersectionError, NumPyError, \
|
|
14
14
|
PointsError, TriangleError, _xError, _xkwds
|
|
15
|
-
from pygeodesy.fmath import fabs, fdot, hypot, hypot2_, sqrt
|
|
15
|
+
from pygeodesy.fmath import fabs, fdot, fdot_, hypot, hypot2_, sqrt
|
|
16
16
|
from pygeodesy.fsums import _Fsumf_, fsumf_, fsum1f_
|
|
17
17
|
from pygeodesy.interns import NN, _a_, _and_, _b_, _c_, _center_, _coincident_, \
|
|
18
18
|
_colinear_, _COMMASPACE_, _concentric_, _few_, \
|
|
@@ -31,7 +31,7 @@ from contextlib import contextmanager
|
|
|
31
31
|
# from math import fabs, sqrt # from .fmath
|
|
32
32
|
|
|
33
33
|
__all__ = _ALL_LAZY.vector2d
|
|
34
|
-
__version__ = '24.
|
|
34
|
+
__version__ = '24.11.10'
|
|
35
35
|
|
|
36
36
|
_cA_ = 'cA'
|
|
37
37
|
_cB_ = 'cB'
|
|
@@ -175,7 +175,7 @@ def _circin6(point1, point2, point3, eps=EPS4, useZ=True, dLL3=False, **Vector_k
|
|
|
175
175
|
C = V(c.x, c.y, c.z, **V_kwds)
|
|
176
176
|
return c, C
|
|
177
177
|
|
|
178
|
-
t, p1, p2, p3 =
|
|
178
|
+
t, p1, p2, p3 = _radii11ABC4(point1, point2, point3, useZ=useZ)
|
|
179
179
|
V, r1, r2, r3 = point1.classof, t.rA, t.rB, t.rC
|
|
180
180
|
|
|
181
181
|
c1, cA = _contact2(t.a, p2, r2, p3, r3, V, _xkwds(Vector_kwds, name=_cA_))
|
|
@@ -251,8 +251,8 @@ def circum4(points, useZ=True, **Vector_and_kwds):
|
|
|
251
251
|
@kwarg useZ: If C{True}, use the points' Z component, otherwise force C{z=INT0}
|
|
252
252
|
(C{bool}).
|
|
253
253
|
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return the center point
|
|
254
|
-
and
|
|
255
|
-
the
|
|
254
|
+
and optionally, additional B{C{Vector}} keyword arguments, otherwise
|
|
255
|
+
the B{C{points}}' (sub-)class.
|
|
256
256
|
|
|
257
257
|
@return: L{Circum4Tuple}C{(radius, center, rank, residuals)} with C{center} an
|
|
258
258
|
instance of C{B{points}[0]}' (sub-)class or B{C{Vector}} if specified.
|
|
@@ -509,12 +509,12 @@ def radii11(point1, point2, point3, useZ=True):
|
|
|
509
509
|
U{Tangent Circles<https://MathWorld.Wolfram.com/TangentCircles.html>}.
|
|
510
510
|
'''
|
|
511
511
|
try:
|
|
512
|
-
return
|
|
512
|
+
return _radii11ABC4(point1, point2, point3, useZ=useZ)[0]
|
|
513
513
|
except (TypeError, ValueError) as x:
|
|
514
514
|
raise _xError(x, point1=point1, point2=point2, point3=point3)
|
|
515
515
|
|
|
516
516
|
|
|
517
|
-
def
|
|
517
|
+
def _radii11ABC4(point1, point2, point3, useZ=True):
|
|
518
518
|
# (INTERNAL) Tangent, Circum, Incircle, Soddy radii, sides and semi-perimeter
|
|
519
519
|
A = _otherV3d(useZ=useZ, point1=point1, NN_OK=False)
|
|
520
520
|
B = _otherV3d(useZ=useZ, point2=point2, NN_OK=False)
|
|
@@ -589,7 +589,7 @@ def soddy4(point1, point2, point3, eps=EPS4, useZ=True):
|
|
|
589
589
|
@see: Functions L{radii11} and L{circum3} and U{Soddy Circles
|
|
590
590
|
<https://MathWorld.Wolfram.com/SoddyCircles.html>}.
|
|
591
591
|
'''
|
|
592
|
-
t, p1, p2, p3 =
|
|
592
|
+
t, p1, p2, p3 = _radii11ABC4(point1, point2, point3, useZ=useZ)
|
|
593
593
|
|
|
594
594
|
r = t.riS
|
|
595
595
|
c, d = _tricenter3d2(p1, t.rA + r,
|
|
@@ -685,8 +685,8 @@ def trilaterate2d2(x1, y1, radius1, x2, y2, radius2, x3, y3, radius3,
|
|
|
685
685
|
@kwarg eps: Tolerance to check the trilaterated point I{delta} on
|
|
686
686
|
all 3 circles (C{scalar}) or C{None} for no checking.
|
|
687
687
|
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return
|
|
688
|
-
|
|
689
|
-
|
|
688
|
+
the trilateration and optionally, additional B{C{Vector}}
|
|
689
|
+
keyword arguments).
|
|
690
690
|
|
|
691
691
|
@return: Trilaterated point as C{B{Vector}(x, y, **B{Vector_kwds})}
|
|
692
692
|
or L{Vector2Tuple}C{(x, y)} if C{B{Vector} is None}.
|
|
@@ -742,14 +742,14 @@ def _trilaterate2d2(x1, y1, radius1, x2, y2, radius2, x3, y3, radius3,
|
|
|
742
742
|
raise IntersectionError(_and(_astr(x3=x3, y3=y3, radius3=r3),
|
|
743
743
|
_astr(x1=x1, y1=y1, radius1=r1)), txt=t)
|
|
744
744
|
|
|
745
|
-
q = (a
|
|
745
|
+
q = fdot_(a, e, -b, d) * _2_0
|
|
746
746
|
if isnear0(q):
|
|
747
747
|
t = _no_(_intersection_)
|
|
748
748
|
raise IntersectionError(_and(_astr(x1=x1, y1=y1, radius1=r1),
|
|
749
749
|
_astr(x2=x2, y2=y2, radius2=r2),
|
|
750
750
|
_astr(x3=x3, y3=y3, radius3=r3)), txt=t)
|
|
751
|
-
t = Vector2Tuple((c
|
|
752
|
-
(a
|
|
751
|
+
t = Vector2Tuple(fdot_(c, e, -b, f) / q,
|
|
752
|
+
fdot_(a, f, -c, d) / q, name=trilaterate2d2.__name__)
|
|
753
753
|
|
|
754
754
|
if eps and eps > 0: # check distances to center vs radius
|
|
755
755
|
for x, y, r in ((x1, y1, r1), (x2, y2, r2), (x3, y3, r3)):
|
pygeodesy/vector3d.py
CHANGED
|
@@ -31,7 +31,7 @@ from pygeodesy.vector3dBase import Vector3dBase
|
|
|
31
31
|
# from math import fabs, sqrt # from .fmath
|
|
32
32
|
|
|
33
33
|
__all__ = _ALL_LAZY.vector3d
|
|
34
|
-
__version__ = '24.
|
|
34
|
+
__version__ = '24.11.11'
|
|
35
35
|
|
|
36
36
|
_vector2d = _MODS.into(vector2d=__name__)
|
|
37
37
|
|
|
@@ -272,7 +272,7 @@ class Vector3d(Vector3dBase):
|
|
|
272
272
|
Circles<https://MathWorld.Wolfram.com/TangentCircles.html>}.
|
|
273
273
|
'''
|
|
274
274
|
try:
|
|
275
|
-
return _vector2d.
|
|
275
|
+
return _vector2d._radii11ABC4(self, point2, point3, useZ=True)[0]
|
|
276
276
|
except (TypeError, ValueError) as x:
|
|
277
277
|
raise _xError(x, point=self, point2=point2, point3=point3)
|
|
278
278
|
|
|
@@ -497,17 +497,16 @@ def intersection3d3(start1, end1, start2, end2, eps=EPS, useZ=True,
|
|
|
497
497
|
B{C{start2}} (Ccompass C{degrees}).
|
|
498
498
|
@kwarg eps: Tolerance for skew line distance and length (C{EPS}).
|
|
499
499
|
@kwarg useZ: If C{True}, use the Z components, otherwise force C{z=INT0} (C{bool}).
|
|
500
|
-
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return the
|
|
501
|
-
|
|
502
|
-
|
|
500
|
+
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return the intersection
|
|
501
|
+
points and optional, additional B{C{Vector}} keyword arguments,
|
|
502
|
+
otherwise B{C{start1}}'s (sub-)class.
|
|
503
503
|
|
|
504
|
-
@return: An L{Intersection3Tuple}C{(point, outside1, outside2)} with
|
|
505
|
-
|
|
504
|
+
@return: An L{Intersection3Tuple}C{(point, outside1, outside2)} with C{point}
|
|
505
|
+
an instance of B{C{Vector}} or B{C{start1}}'s (sub-)class.
|
|
506
506
|
|
|
507
507
|
@note: The C{outside} values is C{0} for lines specified by point and bearing.
|
|
508
508
|
|
|
509
|
-
@raise IntersectionError: Invalid, skew, non-co-planar or otherwise
|
|
510
|
-
non-intersecting lines.
|
|
509
|
+
@raise IntersectionError: Invalid, skew, non-co-planar or otherwise non-intersecting lines.
|
|
511
510
|
|
|
512
511
|
@see: U{Line-line intersection<https://MathWorld.Wolfram.com/Line-LineIntersection.html>}
|
|
513
512
|
and U{line-line distance<https://MathWorld.Wolfram.com/Line-LineDistance.html>},
|
|
@@ -538,9 +537,9 @@ def intersections2(center1, radius1, center2, radius2, sphere=True, **Vector_and
|
|
|
538
537
|
@kwarg sphere: If C{True}, compute the center and radius of the intersection of
|
|
539
538
|
two spheres. If C{False}, ignore the C{z}-component and compute
|
|
540
539
|
the intersection of two circles (C{bool}).
|
|
541
|
-
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return the
|
|
542
|
-
|
|
543
|
-
|
|
540
|
+
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return the intersection
|
|
541
|
+
points and optionally, additional B{C{Vector}} keyword arguments,
|
|
542
|
+
otherwise B{C{center1}}'s (sub-)class.
|
|
544
543
|
|
|
545
544
|
@return: If C{B{sphere} is True}, a 2-tuple of the C{center} and C{radius} of the
|
|
546
545
|
intersection of the I{spheres}. For abutting circles, C{radius} is C{0.0}
|
|
@@ -725,12 +724,12 @@ def nearestOn6(point, points, closed=False, useZ=True, **Vector_and_kwds): # ep
|
|
|
725
724
|
@kwarg closed: Optionally, close the path or polygon (C{bool}).
|
|
726
725
|
@kwarg useZ: If C{True}, use the Z components, otherwise force C{z=INT0} (C{bool}).
|
|
727
726
|
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return the closest
|
|
728
|
-
|
|
729
|
-
|
|
727
|
+
point and optionally, additional B{C{Vector}} keyword arguments,
|
|
728
|
+
otherwise B{C{point}}'s (sub-)class.
|
|
730
729
|
|
|
731
730
|
@return: A L{NearestOn6Tuple}C{(closest, distance, fi, j, start, end)} with the
|
|
732
731
|
C{closest}, the C{start} and the C{end} point each an instance of the
|
|
733
|
-
B{C{Vector}} keyword argument
|
|
732
|
+
B{C{Vector}} keyword argument or if {B{Vector}=None} or not specified,
|
|
734
733
|
an instance of the reference B{C{point}}'s (sub-)class.
|
|
735
734
|
|
|
736
735
|
@raise PointsError: Insufficient number of B{C{points}}
|
|
@@ -854,17 +853,16 @@ def trilaterate3d2(center1, radius1, center2, radius2, center3, radius3,
|
|
|
854
853
|
and C{z}).
|
|
855
854
|
@kwarg eps: Pertubation tolerance (C{scalar}), same units as C{x},
|
|
856
855
|
C{y} and C{z} or C{None} for no pertubations.
|
|
857
|
-
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
the B{C{center1}}'s (sub-)class.
|
|
856
|
+
@kwarg Vector_and_kwds: Optional class C{B{Vector}=None} to return the
|
|
857
|
+
trilateration and optionally, additional B{C{Vector}}
|
|
858
|
+
keyword arguments, otherwise B{C{center1}}'s (sub-)class.
|
|
861
859
|
|
|
862
860
|
@return: 2-Tuple with two trilaterated points, each a B{C{Vector}}
|
|
863
861
|
instance. Both points are the same instance if all three
|
|
864
862
|
spheres abut/intersect in a single point.
|
|
865
863
|
|
|
866
|
-
@raise ImportError: Package C{numpy} not found, not installed or
|
|
867
|
-
|
|
864
|
+
@raise ImportError: Package C{numpy} not found, not installed or older
|
|
865
|
+
than version 1.10.
|
|
868
866
|
|
|
869
867
|
@raise IntersectionError: Near-concentric, -colinear, too distant or
|
|
870
868
|
non-intersecting spheres.
|
pygeodesy/vector3dBase.py
CHANGED
|
@@ -14,7 +14,7 @@ from pygeodesy.constants import EPS, EPS0, INT0, PI, PI2, _copysignINF, \
|
|
|
14
14
|
_float0, isnear0, isnear1, isneg0, \
|
|
15
15
|
_pos_self, _1_0
|
|
16
16
|
from pygeodesy.errors import CrossError, VectorError, _xcallable, _xError
|
|
17
|
-
from pygeodesy.fmath import euclid_, fdot, hypot_, hypot2_
|
|
17
|
+
from pygeodesy.fmath import euclid_, fdot, fdot_, hypot_, hypot2_ # _MODS.fmath.fma
|
|
18
18
|
from pygeodesy.interns import _coincident_, _colinear_, _COMMASPACE_, _xyz_
|
|
19
19
|
from pygeodesy.lazily import _ALL_LAZY, _ALL_DOCS, _ALL_MODS as _MODS
|
|
20
20
|
from pygeodesy.named import _NamedBase, _NotImplemented, _xother3
|
|
@@ -28,7 +28,7 @@ from pygeodesy.utily import sincos2, atan2, fabs
|
|
|
28
28
|
from math import ceil as _ceil, floor as _floor, trunc as _trunc
|
|
29
29
|
|
|
30
30
|
__all__ = _ALL_LAZY.vector3dBase
|
|
31
|
-
__version__ = '24.10
|
|
31
|
+
__version__ = '24.11.10'
|
|
32
32
|
|
|
33
33
|
|
|
34
34
|
class Vector3dBase(_NamedBase): # sync __methods__ with .fsums.Fsum
|
|
@@ -141,10 +141,6 @@ class Vector3dBase(_NamedBase): # sync __methods__ with .fsums.Fsum
|
|
|
141
141
|
'''Not implemented.'''
|
|
142
142
|
return _NotImplemented(self, other)
|
|
143
143
|
|
|
144
|
-
def __format__(self, *other): # PYCHOK no cover
|
|
145
|
-
'''Not implemented.'''
|
|
146
|
-
return _NotImplemented(self, *other)
|
|
147
|
-
|
|
148
144
|
def __ge__(self, other):
|
|
149
145
|
'''Is this vector longer than or equal to an other vector?
|
|
150
146
|
|
|
@@ -504,9 +500,9 @@ class Vector3dBase(_NamedBase): # sync __methods__ with .fsums.Fsum
|
|
|
504
500
|
'''
|
|
505
501
|
X, Y, Z = self.others(other).xyz3
|
|
506
502
|
x, y, z = self.xyz3
|
|
507
|
-
xyz = ((y
|
|
508
|
-
(z
|
|
509
|
-
(x
|
|
503
|
+
xyz = (fdot_(y, Z, -z, Y),
|
|
504
|
+
fdot_(z, X, -x, Z),
|
|
505
|
+
fdot_(x, Y, -y, X))
|
|
510
506
|
|
|
511
507
|
if raiser and self.crosserrors and eps0 > 0 \
|
|
512
508
|
and max(map(fabs, xyz)) < eps0:
|
|
@@ -823,11 +819,12 @@ class Vector3dBase(_NamedBase): # sync __methods__ with .fsums.Fsum
|
|
|
823
819
|
'''
|
|
824
820
|
return self._plus(*_xyz3(self.plus_, other_x, *y_z))
|
|
825
821
|
|
|
826
|
-
def rotate(self, axis, theta):
|
|
822
|
+
def rotate(self, axis, theta, fma=False):
|
|
827
823
|
'''Rotate this vector around an axis by a specified angle.
|
|
828
824
|
|
|
829
825
|
@arg axis: The axis being rotated around (L{Vector3d}).
|
|
830
826
|
@arg theta: The angle of rotation (C{radians}).
|
|
827
|
+
@kwarg fma: If C{True}, use fused-multiply-add (C{bool}).
|
|
831
828
|
|
|
832
829
|
@return: New, rotated vector (L{Vector3d}).
|
|
833
830
|
|
|
@@ -846,17 +843,23 @@ class Vector3dBase(_NamedBase): # sync __methods__ with .fsums.Fsum
|
|
|
846
843
|
bx, by, bz = r.times(d).xyz3
|
|
847
844
|
sx, sy, sz = r.times(s).xyz3
|
|
848
845
|
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
846
|
+
if fma:
|
|
847
|
+
_fma = _MODS.fmath.fma
|
|
848
|
+
else:
|
|
849
|
+
def _fma(a, b, c):
|
|
850
|
+
return a * b + c
|
|
851
|
+
|
|
852
|
+
x = fdot(p, _fma(ax, bx, c), _fma(ax, by, -sz), _fma(ax, bz, sy))
|
|
853
|
+
y = fdot(p, _fma(ay, bx, sz), _fma(ay, by, c), _fma(ay, bz, -sx))
|
|
854
|
+
z = fdot(p, _fma(az, bx, -sy), _fma(az, by, sx), _fma(az, bz, c))
|
|
852
855
|
else: # unrotated
|
|
853
856
|
x, y, z = self.xyz3
|
|
854
857
|
return self.classof(x, y, z)
|
|
855
858
|
|
|
856
859
|
@deprecated_method
|
|
857
|
-
def rotateAround(self, axis, theta):
|
|
860
|
+
def rotateAround(self, axis, theta):
|
|
858
861
|
'''DEPRECATED, use method C{rotate}.'''
|
|
859
|
-
return self.rotate(axis, theta)
|
|
862
|
+
return self.rotate(axis, theta) # PYCHOK no cover
|
|
860
863
|
|
|
861
864
|
def times(self, factor):
|
|
862
865
|
'''Multiply this vector by a scalar.
|
pygeodesy/webmercator.py
CHANGED
|
@@ -36,7 +36,7 @@ from pygeodesy.utily import degrees90, degrees180
|
|
|
36
36
|
from math import atan, atanh, exp, radians, sin, tanh
|
|
37
37
|
|
|
38
38
|
__all__ = _ALL_LAZY.webmercator
|
|
39
|
-
__version__ = '24.
|
|
39
|
+
__version__ = '24.11.06'
|
|
40
40
|
|
|
41
41
|
# _FalseEasting = 0 # false Easting (C{meter})
|
|
42
42
|
# _FalseNorthing = 0 # false Northing (C{meter})
|
|
@@ -314,10 +314,10 @@ def toWm(latlon, lon=None, earth=R_MA, Wm=Wm, **name_Wm_kwds_radius):
|
|
|
314
314
|
L{a_f2Tuple}, L{Ellipsoid} or L{Ellipsoid2}), overridden
|
|
315
315
|
by B{C{latlon}}'s datum if present.
|
|
316
316
|
@kwarg Wm: Optional class to return the WM coordinate (L{Wm}) or C{None}.
|
|
317
|
-
@kwarg name_Wm_kwds_radius: Optional C{B{name}=NN} (C{str}),
|
|
317
|
+
@kwarg name_Wm_kwds_radius: Optional C{B{name}=NN} (C{str}), optionally,
|
|
318
318
|
additional B{C{Wm}} keyword arguments, ignored if C{B{Wm} is
|
|
319
|
-
None} and DEPRECATED keyword argument C{B{radius}=earth},
|
|
320
|
-
|
|
319
|
+
None} and DEPRECATED keyword argument C{B{radius}=earth}, use
|
|
320
|
+
B{C{earth}}.
|
|
321
321
|
|
|
322
322
|
@return: The WM coordinate (B{C{Wm}}) or if C{B{Wm} is None}, an
|
|
323
323
|
L{EasNorRadius3Tuple}C{(easting, northing, radius)}.
|
pygeodesy/wgrs.py
CHANGED
|
@@ -32,7 +32,7 @@ from pygeodesy.utily import ft2m, m2ft, m2NM
|
|
|
32
32
|
from math import floor
|
|
33
33
|
|
|
34
34
|
__all__ = _ALL_LAZY.wgrs
|
|
35
|
-
__version__ = '24.
|
|
35
|
+
__version__ = '24.11.06'
|
|
36
36
|
|
|
37
37
|
_Base = 10
|
|
38
38
|
_BaseLen = 4
|
|
@@ -212,9 +212,9 @@ class Georef(Str):
|
|
|
212
212
|
|
|
213
213
|
@kwarg LatLon: Class to use (C{LatLon}) or C{None}.
|
|
214
214
|
@kwarg height: Optional height (C{meter}), overriding this height.
|
|
215
|
-
@kwarg name_LatLon_kwds: Optional C{B{name}=NN} (C{str}) and
|
|
216
|
-
additional B{C{LatLon}} keyword arguments, ignored if
|
|
217
|
-
|
|
215
|
+
@kwarg name_LatLon_kwds: Optional C{B{name}=NN} (C{str}) and optionally,
|
|
216
|
+
additional B{C{LatLon}} keyword arguments, ignored if C{B{LatLon}
|
|
217
|
+
is None}.
|
|
218
218
|
|
|
219
219
|
@return: This georef location (B{C{LatLon}}) or if C{B{LatLon} is None},
|
|
220
220
|
a L{LatLon3Tuple}C{(lat, lon, height)}.
|
|
File without changes
|