planets/planets.c
/*
 * Calculate the 'Transit coordinates' for a solar system object.
 * This is the location on Earth at which the object is at local zenith.
 */
Calculate the 'Transit coordinates' for a solar system object.
This is the location on Earth at which the object is at local zenith.
Calculate the ' Transit coordinates ' for a solar system object . This is the location on Earth at which the object is at local zenith .
short int transit_coord(time_parameters_t *tp, object *obj,
        double x_pole, double y_pole,
        short int accuracy,
        double *lat, double *lon)
{
    observer geo_ctr;
    sky_pos t_place;
    double pose[3];
    double pos[3];
    make_observer_at_geocenter(&geo_ctr);
    short int error = place(tp->jd_tt, obj, &geo_ctr, tp->delta_t, coord_equ, accuracy, &t_place);
    if (error != 0) {
        printf_if(3, "ERRCODE %d from place.", error);
        goto out;
    }
    radec2vector(t_place.ra, t_place.dec, t_place.dis, pose);
    error = cel2ter(tp->jd_ut1, 0.0, tp->delta_t, coord_equ, accuracy,
                    coord_equ, x_pole, y_pole, pose, pos);
    if (error != 0) {
        printf_if(3, "ERRCODE %d from cel2ter.", error);
        goto out;
    }
    vector2radec(pos, lon, lat);
    *lon *= 15.0;
    if (*lon > 180.0) {
        *lon -= 360.0;
    }
out:
    return error;
}
short int transit_coord ( time_parameters_t * tp , object * obj , double x_pole , double y_pole , short int accuracy , double * lat , double * lon ) { observer geo_ctr ; sky_pos t_place ; double pose [ 3 ] ; double pos [ 3 ] ; make_observer_at_geocenter ( & geo_ctr ) ; short int error = place ( tp -> jd_tt , obj , & geo_ctr , tp -> delta_t , coord_equ , accuracy , & t_place ) ; if ( error != 0 ) { printf_if ( 3 , " " , error ) ; goto out ; } radec2vector ( t_place . ra , t_place . dec , t_place . dis , pose ) ; error = cel2ter ( tp -> jd_ut1 , 0.0 , tp -> delta_t , coord_equ , accuracy , coord_equ , x_pole , y_pole , pose , pos ) ; if ( error != 0 ) { printf_if ( 3 , " " , error ) ; goto out ; } vector2radec ( pos , lon , lat ) ; * lon *= 15.0 ; if ( * lon > 180.0 ) { * lon -= 360.0 ; } out : return error ; }
Calculate the 'Transit coordinates' for a solar system object.
Calculate the ' Transit coordinates ' for a solar system object .