关于Swiss Ephemeris中的坐标

关于Swiss Ephemeris中的坐标

2.4.4. Coordinate systems, degrees and radians

SEFLG_EQUATORIAL              returns equatorial positions: rectascension and declination.
SEFLG_XYZ                             returns x, y, z coordinates instead of longitude, latitude, and distance.
SEFLG_RADIANS                    returns position in radians, not degrees.
 
E.g. to compute rectascension and declination, write:
iflag = SEFLG_SWIEPH | SEFLG_SPEED | SEFLG_EQUATORIAL;

2.4.4  坐标系统,角度与弧度

使用SEFLG_EQUATORIAL时,返回的是赤道上的位置,返回值是赤经(rectascension)与赤纬(declination),赤经与时角是不同的,时角由天子午圈向西量,而赤经是由春分点向东量,两者方向相反。赤经的值是天球赤道自西向东由0小时至24小时来表达,返回值是一个double型的数字,它每15角分代表一时分,每15角秒代表一个时秒。

使用SEFLG_XYZ时,返回的是笛卡尔坐标系,其中包括X,Y,Z三个值,代表了经度(longitude),纬度(latitude)及距离。

使用SEFLG_RADIANS 时,返回的是弧度而不是角度。

6.12. swe_azalt(), horizontal coordinates, azimuth, altitude
swe_azalt()computes the horizontal coordinates (azimuth and altitude) of a planet or a star from either ecliptical or equatorial coordinates.

这个函数通过黄道或赤道坐标,计算出星体的水平座标,包括高度角及方位角。

void swe_azalt(
      double tjd_ut,     // UT
      int32 calc_flag,    // SE_ECL2HOR or SE_EQU2HOR
      double *geopos,// array of 3 doubles: geograph. long., lat., height
      double atpress,  // atmospheric pressure in mbar (hPa) 大气压力
      double attemp,   // atmospheric temperature in degrees Celsius 大气温度
      double *xin,        // array of 3 doubles: position of body in either  ecliptical or equatorial coordinates, 
                                 // depending on calc_flag 参数由计算标志所确定
      double *xaz);     // return array of 3 doubles, containing azimuth, true altitude, apparent altitude 返回值包括方位角,高度角及可视高度角
 
If calc_flag=SE_ECL2HOR, set xin[0]= ecl. long., xin[1]= ecl. lat., (xin[2]=distance (not required));
else
if calc_flag= SE_EQU2HOR, set xin[0]=rectascension, xin[1]=declination, (xin[2]= distance (not required));
 
#define SE_ECL2HOR    0  黄道座标系,要求提供经度,纬度,距离(其实不需要)
#define SE_EQU2HOR   1  赤道座标系,要求提供赤经,赤纬,距离(其实不需要)
 
The return values are:
xaz[0] = azimuth, i.e. position degree, measured from the south point to west. 第0个数组返回的是地平经度,即方位角(azimuth),它代表的是是从某点的指北方向线起,依顺时针方向到目标方向线之间的水平夹角。即以北面为0度,然后绕圆周一圈所得到的值。
xaz[1] = true altitude above horizon in degrees. 第1个数组代表的是自地平线算起的高度。
xaz[2] = apparent (refracted) altitude above horizon in degrees. 第2个是指的从地平线往上的可见高度
 
The apparent altitude of a body depends on the atmospheric pressure and temperature. If only the true altitude is required, these parameters can be neglected.

可见高度与大气压力有关,不过如果只是想得到一个真实高度的话,这个是可以忽略掉的。


If atpress is given the value 0, the function estimates the pressure from the geographical altitude given in geopos[2] and attemp. If geopos[2] is 0, atpress will be estimated for sea level.

如果大气压力是0值,那么会自动根据参数中给出的海拔高度来计算出一个大气压强。

三符风云涌

发表评论