Skip to content

Latest commit

 

History

History
85 lines (67 loc) · 2.72 KB

File metadata and controls

85 lines (67 loc) · 2.72 KB

Catalog ICRS to observed

In this example, we want to find the observed coordinates of a star called Gliese 555. The Hipparcos identifier of this star is 71253 and it's SIMBAD main_id is "BD-11 3759". It's basic catalog data from SIMBAD is:

ra             218.57004859310788
dec           -12.519559582093887
pmra                     -355.138
pmdec                      593.04
plx_value                159.9225
rvz_radvel                  -1.28

We need to convert some units befor using FAWS functions. Some useful constants for unit conversions are:

DR2D: Radians to degrees
DD2R: Degrees to radians
DAS2R: Arcseconds to radians
DMAS2R: Milliarcseconds to radians

We have choosen the observation site in Strasbourg, France and the UTC date and time is 10th Feb 2024 at 22:32:37. The Earth Orientation Parameters have been obtained from IERS website.

import FAWS

let faws = Faws()

// Star data
let rc = 218.57004859310788 * faws.DD2R
let dc = -12.519559582093887 * faws.DD2R
let pr = -355.138 * faws.DMAS2R
let pd = 593.04 * faws.DMAS2R
let px = 159.9225 * 0.001
let rv = -1.28

// Time of observation
let (utc1, utc2) = faws.dtf2d("UTC", 2024, 2, 10, 22, 32, 37.0)
//let (tai1, tai2) = faws.utctai(utc1, utc2)
//let (tt1, tt2) = faws.taitt(tai1, tai2)

// Earth Orientation Parameters
let dut1 = 0.00261476
let xp = 0.0473476 * faws.DAS2R
let yp = 0.2368623 * faws.DAS2R

// Observation site (coordinates and conditions)
let elong = 7.744083817548831 * faws.DD2R //longitude (radians)
let phi = 48.58313582900411 * faws.DD2R   //latitude (radians)
let hm = 140.0                       //height (m)
let phpa = 987.0 //Ambient pressure (HPa)
let tc = 15.0    //Temperature (C)
let rh = 0.92    //Relative humidity (frac)
let wl = 0.55    //Effective color (microns)

let (aob, zob, hob, dob, rob, eo) = faws.atco13(
        rc, dc, pr, pd, px, rv,
        utc1, utc2, dut1,
        elong, phi, hm,
        xp, yp,
        phpa, tc, rh, wl
        )
        
    
print("Azimuth                 : \(aob * faws.DR2D)")
print("Zenith Distance         : \(zob * faws.DR2D)")
print("Hour Angle              : \(hob * faws.DR2D)")
print("Declination             : \(dob * faws.DR2D)")
print("Right Ascension         : \(rob * faws.DR2D)")
print("equation of the origins : \(eo  * faws.DR2D)")

The output (all in degrees):

Azimuth                 : 96.59548514831307
Zenith Distance         : 100.89938985767792
Hour Angle              : -92.37778736685267
Declination             : -12.498270592129632
Right Ascension         : 218.47147240846533
equation of the origins : -0.3079588055596707