Class for representing modified Julian dates with high precision. More...

#include <MJD.h>

Inherited by FITSUTC.

Public Member Functions

 MJD (double dd)
 
 MJD (int intday, double fracday)
 
 MJD (double dd, double ss, double fs)
 
 MJD (int dd, int ss, double fs)
 
 MJD (const char *mjdstring)
 
 MJD (time_t time)
 
 MJD (const struct tm &greg)
 
 MJD (const struct timeval &tp)
 
 MJD (const utc_t &utc)
 
 MJD (const std::string &mjd)
 
int Construct (const char *mjdstr)
 
int Construct (time_t time)
 
int Construct (const struct tm &greg)
 
int Construct (const struct timeval &tp)
 
int Construct (const utc_t &utc)
 
int Construct (uint64_t bat)
 
double in_seconds () const
 
double in_days () const
 
double in_minutes () const
 
int UTC (utc_t *utc, double *fsec=NULL) const
 
int gregorian (struct tm *gregdate, double *fsec=NULL) const
 
MJDoperator= (const MJD &)
 
MJDoperator+= (const MJD &)
 
MJDoperator-= (const MJD &)
 
MJDoperator+= (const double &)
 
MJDoperator-= (const double &)
 
MJDoperator*= (const double &)
 
MJDoperator/= (const double &)
 
float plotval () const
 
int intday () const
 
double fracday () const
 
int get_secs () const
 
double get_fracsec () const
 
double LST (double longitude) const
 
double GMST () const
 
std::string printdays (unsigned precision) const
 
int print (FILE *stream)
 
int println (FILE *stream)
 
std::string printall () const
 
std::string printdays () const
 
std::string printhhmmss () const
 
std::string printfs () const
 
std::string strtempo () const
 
char * datestr (char *dstr, int len, const char *format) const
 
std::string datestr (const char *format, unsigned fractional_second_digits=0) const
 

Static Public Attributes

static const MJD zero
 
static double precision = 2.0e-12
 
static unsigned ostream_precision = 15
 
static int verbose = 0
 

Friends

const friend MJD operator+ (const MJD &, const MJD &)
 
const friend MJD operator- (const MJD &, const MJD &)
 
const friend MJD operator+ (const MJD &, double)
 
const friend MJD operator- (const MJD &, double)
 
const friend MJD operator* (const MJD &, double)
 
const friend MJD operator* (double a, const MJD &m)
 
const friend MJD operator/ (const MJD &, double)
 
const friend MJD operator- (MJD m)
 
int operator> (const MJD &, const MJD &)
 
int operator< (const MJD &, const MJD &)
 
int operator>= (const MJD &, const MJD &)
 
int operator<= (const MJD &, const MJD &)
 
int operator== (const MJD &, const MJD &)
 
int operator!= (const MJD &, const MJD &)
 
bool equal (const MJD &m1, const MJD &m2)
 

Detailed Description

Class for representing modified Julian dates with high precision.


The documentation for this class was generated from the following files:

Generated using doxygen 1.8.17