Changeset 2551 in Sophya for trunk/SophyaExt/XephemAstroLib/sphcart.c
- Timestamp:
- Jun 15, 2004, 6:54:12 PM (21 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaExt/XephemAstroLib/sphcart.c
r1719 r2551 1 1 #include <math.h> 2 #include "P_.h" 2 #include <stdio.h> 3 3 4 #include "astro.h" 4 5 5 6 /* transformation from spherical to cartesian coordinates */ 6 7 void 7 sphcart ( l, b, r, x, y, z)8 double l, b, r;/* source: spherical coordinates */9 double *x, *y, *z;/* result: rectangular coordinates */8 sphcart ( 9 double l, double b, double r, /* source: spherical coordinates */ 10 double *x, double *y, double *z) /* result: rectangular coordinates */ 10 11 { 11 12 double rcb = r * cos(b); … … 18 19 /* transformation from cartesian to spherical coordinates */ 19 20 void 20 cartsph ( x, y, z, l, b, r)21 double x, y, z;/* source: rectangular coordinates */22 double *l, *b, *r;/* result: spherical coordinates */21 cartsph ( 22 double x, double y, double z, /* source: rectangular coordinates */ 23 double *l, double *b, double *r) /* result: spherical coordinates */ 23 24 { 24 25 double rho = x*x + y*y; … … 40 41 41 42 /* For RCS Only -- Do Not Edit */ 42 static char *rcsid[2] = {(char *)rcsid, "@(#) $RCSfile: sphcart.c,v $ $Date: 200 1-10-22 12:08:28 $ $Revision: 1.2$ $Name: not supported by cvs2svn $"};43 static char *rcsid[2] = {(char *)rcsid, "@(#) $RCSfile: sphcart.c,v $ $Date: 2004-06-15 16:52:40 $ $Revision: 1.3 $ $Name: not supported by cvs2svn $"};
Note:
See TracChangeset
for help on using the changeset viewer.