source: trunk/FACT++/pal/palRvlsrk.c@ 19672

Last change on this file since 19672 was 18347, checked in by tbretz, 9 years ago
File size: 3.5 KB
Line 
1/*
2*+
3* Name:
4* palRvlsrk
5
6* Purpose:
7* Velocity component in a given direction due to the Sun's motion
8* with respect to an adopted kinematic Local Standard of Rest.
9
10* Language:
11* Starlink ANSI C
12
13* Type of Module:
14* Library routine
15
16* Invocation:
17* double palRvlsrk( double r2000, double d2000 )
18
19* Arguments:
20* r2000 = double (Given)
21* J2000.0 mean RA (radians)
22* d2000 = double (Given)
23* J2000.0 mean Dec (radians)
24
25* Returned Value:
26* Component of "standard" solar motion in direction R2000,D2000 (km/s).
27
28* Description:
29* This function returns the velocity component in a given direction
30* due to the Sun's motion with respect to an adopted kinematic
31* Local Standard of Rest. The result is +ve when the Sun is receding
32* from the given point on the sky.
33
34* Notes:
35* - The Local Standard of Rest used here is one of several
36* "kinematical" LSRs in common use. A kinematical LSR is the mean
37* standard of rest of specified star catalogues or stellar
38* populations. The Sun's motion with respect to a kinematical LSR
39* is known as the "standard" solar motion.
40* - There is another sort of LSR, the "dynamical" LSR, which is a
41* point in the vicinity of the Sun which is in a circular orbit
42* around the Galactic centre. The Sun's motion with respect to
43* the dynamical LSR is called the "peculiar" solar motion. To
44* obtain a radial velocity correction with respect to the
45* dynamical LSR use the routine palRvlsrd.
46
47* Reference:
48* - Delhaye (1965), in "Stars and Stellar Systems", vol 5, p73.
49
50* Authors:
51* PTW: Pat Wallace (STFC)
52* DSB: David Berry (JAC, Hawaii)
53* {enter_new_authors_here}
54
55* History:
56* 2012-02-16 (DSB):
57* Initial version.
58* Adapted with permission from the Fortran SLALIB library.
59* {enter_further_changes_here}
60
61* Copyright:
62* Copyright (C) 1995 Rutherford Appleton Laboratory
63* Copyright (C) 2012 Science and Technology Facilities Council.
64* All Rights Reserved.
65
66* Licence:
67* This program is free software: you can redistribute it and/or
68* modify it under the terms of the GNU Lesser General Public
69* License as published by the Free Software Foundation, either
70* version 3 of the License, or (at your option) any later
71* version.
72*
73* This program is distributed in the hope that it will be useful,
74* but WITHOUT ANY WARRANTY; without even the implied warranty of
75* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
76* GNU Lesser General Public License for more details.
77*
78* You should have received a copy of the GNU Lesser General
79* License along with this program. If not, see
80* <http://www.gnu.org/licenses/>.
81
82* Bugs:
83* {note_any_bugs_here}
84*-
85*/
86
87#include "pal.h"
88#include "pal1sofa.h"
89
90double palRvlsrk( double r2000, double d2000 ){
91
92/* Local Variables: */
93 double vb[ 3 ];
94
95/*
96* Standard solar motion (from Methods of Experimental Physics, ed Meeks,
97* vol 12, part C, sec 6.1.5.2, p281):
98*
99* 20 km/s towards RA 18h Dec +30d (1900).
100*
101* The solar motion is expressed here in the form of a J2000.0
102* equatorial Cartesian vector:
103*
104* VA(1) = X = -SPEED*COS(RA)*COS(DEC)
105* VA(2) = Y = -SPEED*SIN(RA)*COS(DEC)
106* VA(3) = Z = -SPEED*SIN(DEC)
107*/
108
109 double va[ 3 ] = { -0.29000, +17.31726, -10.00141 };
110
111/* Convert given J2000 RA,Dec to x,y,z. */
112 eraS2c( r2000, d2000, vb );
113
114/* Compute dot product with Solar motion vector. */
115 return eraPdp( va, vb );
116}
Note: See TracBrowser for help on using the repository browser.