33 int day, hour, min, mon, sec, year;
37 ERRMSG(
"Give parameters: <jsec>");
40 double jsec = atof(argv[1]);
43 jsec2time(jsec, &year, &mon, &day, &hour, &min, &sec, &remain);
44 printf(
"%d %d %d %d %d %d %g\n", year, mon, day, hour, min, sec, remain);
int main(int argc, char *argv[])
void jsec2time(const double jsec, int *year, int *mon, int *day, int *hour, int *min, int *sec, double *remain)
Converts Julian seconds to calendar date and time components.
MPTRAC library declarations.
#define ERRMSG(...)
Print an error message with contextual information and terminate the program.