r'''
The ``etrsitrs`` Python module converts ITRS coordinates in various
reference frames to ETRS89 coordinates in the ETRF2000 reference frame
and vice versa. The conversions are described by 14 parameter
transforms, consisting of seven parameters and their associated rates
of change per year.
The transform and the coefficients are defined in the EUREF memo
/Specifications for reference frame fixing in the analysis of a EUREF
GPS campaign/ by Claude Boucher and Zuheir Altamimi. This module
uses version 8 bis of this memo, published on 2011-May-18.
The seven parameter transform of coordinates from frame A to frame B is
defined as
.. math::
\left(\begin{array}{c} x_B \\ y_B \\ z_B\end{array}\right) =
\left(\begin{array}{c} x_A \\ y_A \\ z_A\end{array}\right) +
\left(\begin{array}{c} T1 \\ T2 \\ T3\end{array}\right) +
\left(\begin{array}{ccc}
D & -R3 & R2 \\
R3 & D & -R1 \\
-R2 & R1 & D
\end{array}\right)
\left(\begin{array}{c} x_A \\ y_A \\ z_A\end{array}\right)
Table XX lists the parameters to transform from ITRFyyyy to ETRF2000.
The inverse transform, given the same parameters, is
.. math::
\left(\begin{array}{c} x_A \\ y_A \\ z_A\end{array}\right) =
\left(\begin{array}{c} x_B \\ y_B \\ z_B\end{array}\right) -
\left(\begin{array}{c} T1 \\ T2 \\ T3\end{array}\right) -
\left(\begin{array}{ccc}
D & -R3 & R2 \\
R3 & D & -R1 \\
-R2 & R1 & D
\end{array}\right)
\left[\left(\begin{array}{c} x_B \\ y_B \\ z_B\end{array}\right) -
\left(\begin{array}{c} T1 \\ T2 \\ T3\end{array}\right)\right].
Here, we used that the matrix :math:`I + M`, with :math:`I` the identity matrix,
and :math:`M` the matrix in the equations above, is a rotation
matrix. Rotation matrices are unitary, hence their inverse is equal to
their transpose.
The seven parameters :math:`Tn`, :math:`D`, and :math:`Rn` are time
dependent. To correctly perform the transformation, the parameter set
:math:`P` must first be propagated to the epoch at which the ITRF
coordinates were observed, or at which the ITRF coordinates are
desired, according to
.. math::
P(t) = P(t_0) + \dot{P}\times(t - t_0),
where :math:`t_0` is the epoch at which the parameters are valid
(2000.0 in this case), and :math:`t` is the epoch at which the ITRF
coordinates are observed or required. Both are in units of years.
'''
import numpy
[docs]class ParameterSet(object):
r'''
'''
def __init__(self, translate_m, term_d, rotate_rad):
pass
[docs]class ETRF2000(CoordinateTransform):
def __init__(self, from_frame, parameters, rates, epoch):
self.to_frame = 'ETRF2000'
self.from_frame = from_frame
# Coefficients from Boucher and Altamimi (2011)
# "Memo: specifications for reference frame fixing in the analysis of a EUREF GPS campaign"
# |'T1' |'T2' |'T3' |'D' |'R1' |'R2' |'R3' |
# |(mm) |(mm) |(mm) |x1e-9|(mas) |(mas) |(mas) |
PARAMETER_TABLE = [
ETRF2000('ITRF2008' ,
[52.1, 49.3, -58.5, 1.34, 0.891, 5.390, -8.712],
[ 0.1, 0.1, -1.8, 0.08, 0.081, 0.490, -0.792],
2000.0),
ETRF2000('ITRF2005' ,
[54.1, 50.2, -53.8, 0.40, 0.891, 5.390, -8.712],
[-0.2, 0.1, -1.8, 0.08, 0.081, 0.490, -0.792],
2000.0),
ETRF2000('ITRF2000' ,
[54.0, 51.0, -48.0, 0.00, 0.891, 5.390, -8.712],
[ 0.0, 0.0, 0.0, 0.00, 0.081, 0.490, -0.792],
2000.0)]