source: trunk/FACT++/pal/palFk54z.c@ 18812

Last change on this file since 18812 was 18347, checked in by tbretz, 9 years ago
File size: 3.7 KB
Line 
1/*
2*+
3* Name:
4* palFk54z
5
6* Purpose:
7* Convert a J2000.0 FK5 star position to B1950.0 FK4 assuming
8* zero proper motion and parallax.
9
10* Language:
11* Starlink ANSI C
12
13* Type of Module:
14* Library routine
15
16* Invocation:
17* palFk54z( double r2000, double d2000, double bepoch, double *r1950,
18* double *d1950, double *dr1950, double *dd1950 )
19
20* Arguments:
21* r2000 = double (Given)
22* J2000.0 FK5 RA (radians).
23* d2000 = double (Given)
24* J2000.0 FK5 Dec (radians).
25* bepoch = double (Given)
26* Besselian epoch (e.g. 1950.0).
27* r1950 = double * (Returned)
28* B1950 FK4 RA (radians) at epoch "bepoch".
29* d1950 = double * (Returned)
30* B1950 FK4 Dec (radians) at epoch "bepoch".
31* dr1950 = double * (Returned)
32* B1950 FK4 proper motion (RA) (radians/trop.yr)).
33* dr1950 = double * (Returned)
34* B1950 FK4 proper motion (Dec) (radians/trop.yr)).
35
36* Description:
37* This function converts star positions from the IAU 1976,
38* FK5, Fricke system to the Bessel-Newcomb, FK4 system.
39
40* Notes:
41* - The proper motion in RA is dRA/dt rather than cos(Dec)*dRA/dt.
42* - Conversion from Julian epoch 2000.0 to Besselian epoch 1950.0
43* only is provided for. Conversions involving other epochs will
44* require use of the appropriate precession functions before and
45* after this function is called.
46* - The FK5 proper motions, the parallax and the radial velocity
47* are presumed zero.
48* - It is the intention that FK5 should be a close approximation
49* to an inertial frame, so that distant objects have zero proper
50* motion; such objects have (in general) non-zero proper motion
51* in FK4, and this function returns those fictitious proper
52* motions.
53* - The position returned by this function is in the B1950
54* reference frame but at Besselian epoch BEPOCH. For comparison
55* with catalogues the "bepoch" argument will frequently be 1950.0.
56
57* Authors:
58* PTW: Pat Wallace (STFC)
59* DSB: David Berry (JAC, Hawaii)
60* {enter_new_authors_here}
61
62* History:
63* 2012-02-13 (DSB):
64* Initial version with documentation taken from Fortran SLA
65* Adapted with permission from the Fortran SLALIB library.
66* {enter_further_changes_here}
67
68* Copyright:
69* Copyright (C) 1995 Rutherford Appleton Laboratory
70* Copyright (C) 2012 Science and Technology Facilities Council.
71* All Rights Reserved.
72
73* Licence:
74* This program is free software: you can redistribute it and/or
75* modify it under the terms of the GNU Lesser General Public
76* License as published by the Free Software Foundation, either
77* version 3 of the License, or (at your option) any later
78* version.
79*
80* This program is distributed in the hope that it will be useful,
81* but WITHOUT ANY WARRANTY; without even the implied warranty of
82* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
83* GNU Lesser General Public License for more details.
84*
85* You should have received a copy of the GNU Lesser General
86* License along with this program. If not, see
87* <http://www.gnu.org/licenses/>.
88
89* Bugs:
90* {note_any_bugs_here}
91*-
92*/
93
94#include "pal.h"
95#include "pal1sofa.h"
96
97void palFk54z( double r2000, double d2000, double bepoch, double *r1950,
98 double *d1950, double *dr1950, double *dd1950 ){
99
100/* Local Variables: */
101 double r, d, px, rv, y;
102
103/* FK5 equinox J2000 (any epoch) to FK4 equinox B1950 epoch B1950. */
104 palFk524( r2000, d2000, 0.0, 0.0, 0.0, 0.0, &r, &d, dr1950, dd1950,
105 &px, &rv );
106
107/* Fictitious proper motion to epoch "bepoch". */
108 y = bepoch - 1950.0;
109 *r1950 = r + *dr1950*y;
110 *d1950 = d + *dd1950*y;
111
112}
113
Note: See TracBrowser for help on using the repository browser.