FACT++  1.0
void eraIcrs2g ( double  dr,
double  dd,
double *  dl,
double *  db 
)

Definition at line 3 of file icrs2g.c.

References eraAnp(), eraAnpm(), eraC2s(), eraRxp(), and eraS2c().

Referenced by t_icrs2g().

67 {
68  double v1[3], v2[3];
69 
70 /*
71 ** L2,B2 system of galactic coordinates in the form presented in the
72 ** Hipparcos Catalogue. In degrees:
73 **
74 ** P = 192.85948 right ascension of the Galactic north pole in ICRS
75 ** Q = 27.12825 declination of the Galactic north pole in ICRS
76 ** R = 32.93192 longitude of the ascending node of the Galactic
77 ** plane on the ICRS equator
78 **
79 ** ICRS to galactic rotation matrix, obtained by computing
80 ** R_3(-R) R_1(pi/2-Q) R_3(pi/2+P) to the full precision shown:
81 */
82  double r[3][3] = { { -0.054875560416215368492398900454,
83  -0.873437090234885048760383168409,
84  -0.483835015548713226831774175116 },
85  { +0.494109427875583673525222371358,
86  -0.444829629960011178146614061616,
87  +0.746982244497218890527388004556 },
88  { -0.867666149019004701181616534570,
89  -0.198076373431201528180486091412,
90  +0.455983776175066922272100478348 } };
91 
92 
93 /* Spherical to Cartesian. */
94  eraS2c(dr, dd, v1);
95 
96 /* ICRS to Galactic. */
97  eraRxp(r, v1, v2);
98 
99 /* Cartesian to spherical. */
100  eraC2s(v2, dl, db);
101 
102 /* Express in conventional ranges. */
103  *dl = eraAnp(*dl);
104  *db = eraAnpm(*db);
105 
106 /* Finished. */
107 
108 }
void eraS2c(double theta, double phi, double c[3])
Definition: s2c.c:3
void eraC2s(double p[3], double *theta, double *phi)
Definition: c2s.c:3
void eraRxp(double r[3][3], double p[3], double rp[3])
Definition: rxp.c:3
double eraAnpm(double a)
Definition: anpm.c:3
double eraAnp(double a)
Definition: anp.c:3

+ Here is the call graph for this function:

+ Here is the caller graph for this function: