source: trunk/FACT++/sofa/src/c2teqx.c@ 18355

Last change on this file since 18355 was 18346, checked in by tbretz, 11 years ago
File size: 6.5 KB
Line 
1#include "sofa.h"
2
3void iauC2teqx(double rbpn[3][3], double gst, double rpom[3][3],
4 double rc2t[3][3])
5/*
6** - - - - - - - - - -
7** i a u C 2 t e q x
8** - - - - - - - - - -
9**
10** Assemble the celestial to terrestrial matrix from equinox-based
11** components (the celestial-to-true matrix, the Greenwich Apparent
12** Sidereal Time and the polar motion matrix).
13**
14** This function is part of the International Astronomical Union's
15** SOFA (Standards Of Fundamental Astronomy) software collection.
16**
17** Status: support function.
18**
19** Given:
20** rbpn double[3][3] celestial-to-true matrix
21** gst double Greenwich (apparent) Sidereal Time (radians)
22** rpom double[3][3] polar-motion matrix
23**
24** Returned:
25** rc2t double[3][3] celestial-to-terrestrial matrix (Note 2)
26**
27** Notes:
28**
29** 1) This function constructs the rotation matrix that transforms
30** vectors in the celestial system into vectors in the terrestrial
31** system. It does so starting from precomputed components, namely
32** the matrix which rotates from celestial coordinates to the
33** true equator and equinox of date, the Greenwich Apparent Sidereal
34** Time and the polar motion matrix. One use of the present function
35** is when generating a series of celestial-to-terrestrial matrices
36** where only the Sidereal Time changes, avoiding the considerable
37** overhead of recomputing the precession-nutation more often than
38** necessary to achieve given accuracy objectives.
39**
40** 2) The relationship between the arguments is as follows:
41**
42** [TRS] = rpom * R_3(gst) * rbpn * [CRS]
43**
44** = rc2t * [CRS]
45**
46** where [CRS] is a vector in the Geocentric Celestial Reference
47** System and [TRS] is a vector in the International Terrestrial
48** Reference System (see IERS Conventions 2003).
49**
50** Called:
51** iauCr copy r-matrix
52** iauRz rotate around Z-axis
53** iauRxr product of two r-matrices
54**
55** Reference:
56**
57** McCarthy, D. D., Petit, G. (eds.), IERS Conventions (2003),
58** IERS Technical Note No. 32, BKG (2004)
59**
60** This revision: 2013 August 24
61**
62** SOFA release 2015-02-09
63**
64** Copyright (C) 2015 IAU SOFA Board. See notes at end.
65*/
66{
67 double r[3][3];
68
69/* Construct the matrix. */
70 iauCr(rbpn, r);
71 iauRz(gst, r);
72 iauRxr(rpom, r, rc2t);
73
74 return;
75
76/*----------------------------------------------------------------------
77**
78** Copyright (C) 2015
79** Standards Of Fundamental Astronomy Board
80** of the International Astronomical Union.
81**
82** =====================
83** SOFA Software License
84** =====================
85**
86** NOTICE TO USER:
87**
88** BY USING THIS SOFTWARE YOU ACCEPT THE FOLLOWING SIX TERMS AND
89** CONDITIONS WHICH APPLY TO ITS USE.
90**
91** 1. The Software is owned by the IAU SOFA Board ("SOFA").
92**
93** 2. Permission is granted to anyone to use the SOFA software for any
94** purpose, including commercial applications, free of charge and
95** without payment of royalties, subject to the conditions and
96** restrictions listed below.
97**
98** 3. You (the user) may copy and distribute SOFA source code to others,
99** and use and adapt its code and algorithms in your own software,
100** on a world-wide, royalty-free basis. That portion of your
101** distribution that does not consist of intact and unchanged copies
102** of SOFA source code files is a "derived work" that must comply
103** with the following requirements:
104**
105** a) Your work shall be marked or carry a statement that it
106** (i) uses routines and computations derived by you from
107** software provided by SOFA under license to you; and
108** (ii) does not itself constitute software provided by and/or
109** endorsed by SOFA.
110**
111** b) The source code of your derived work must contain descriptions
112** of how the derived work is based upon, contains and/or differs
113** from the original SOFA software.
114**
115** c) The names of all routines in your derived work shall not
116** include the prefix "iau" or "sofa" or trivial modifications
117** thereof such as changes of case.
118**
119** d) The origin of the SOFA components of your derived work must
120** not be misrepresented; you must not claim that you wrote the
121** original software, nor file a patent application for SOFA
122** software or algorithms embedded in the SOFA software.
123**
124** e) These requirements must be reproduced intact in any source
125** distribution and shall apply to anyone to whom you have
126** granted a further right to modify the source code of your
127** derived work.
128**
129** Note that, as originally distributed, the SOFA software is
130** intended to be a definitive implementation of the IAU standards,
131** and consequently third-party modifications are discouraged. All
132** variations, no matter how minor, must be explicitly marked as
133** such, as explained above.
134**
135** 4. You shall not cause the SOFA software to be brought into
136** disrepute, either by misuse, or use for inappropriate tasks, or
137** by inappropriate modification.
138**
139** 5. The SOFA software is provided "as is" and SOFA makes no warranty
140** as to its use or performance. SOFA does not and cannot warrant
141** the performance or results which the user may obtain by using the
142** SOFA software. SOFA makes no warranties, express or implied, as
143** to non-infringement of third party rights, merchantability, or
144** fitness for any particular purpose. In no event will SOFA be
145** liable to the user for any consequential, incidental, or special
146** damages, including any lost profits or lost savings, even if a
147** SOFA representative has been advised of such damages, or for any
148** claim by any third party.
149**
150** 6. The provision of any version of the SOFA software under the terms
151** and conditions specified herein does not imply that future
152** versions will also be made available under the same terms and
153** conditions.
154*
155** In any published work or commercial product which uses the SOFA
156** software directly, acknowledgement (see www.iausofa.org) is
157** appreciated.
158**
159** Correspondence concerning SOFA software should be addressed as
160** follows:
161**
162** By email: sofa@ukho.gov.uk
163** By post: IAU SOFA Center
164** HM Nautical Almanac Office
165** UK Hydrographic Office
166** Admiralty Way, Taunton
167** Somerset, TA1 2DN
168** United Kingdom
169**
170**--------------------------------------------------------------------*/
171}
Note: See TracBrowser for help on using the repository browser.