34 bool units_init(
const char* sProgName);
38 extern const char* UNIT_US2000;
39 extern const char* UNIT_MJ1958;
40 extern const char* UNIT_T2000;
41 extern const char* UNIT_T1970;
42 extern const char* UNIT_NS1970;
43 extern const char* UNIT_UTC;
46 extern const char* UNIT_SECONDS;
47 extern const char* UNIT_HOURS;
48 extern const char* UNIT_DAYS;
49 extern const char* UNIT_MILLISECONDS;
50 extern const char* UNIT_MICROSECONDS;
51 extern const char* UNIT_NANOSECONDS;
53 extern const char* UNIT_HERTZ;
54 extern const char* UNIT_KILO_HERTZ;
55 extern const char* UNIT_MEGA_HERTZ;
56 extern const char* UNIT_E_SPECDENS;
57 extern const char* UNIT_B_SPECDENS;
58 extern const char* UNIT_NT;
60 extern const char* UNIT_NUMBER_DENS;
62 extern const char* UNIT_DB;
64 extern const char* UNIT_KM;
66 extern const char* UNIT_DEGREES;
67 extern const char* UNIT_DIMENSIONLESS;
269 das_units
Units_root(das_units unit,
int root );
309 das_units
Units_reduce(das_units orig,
double* pFactor);
336 double Units_convertTo( das_units toUnits,
double rVal, das_units fromUnits );
388 int Units_getJulianDay(
double timeDouble, das_units epoch_units );
das_units Units_invert(das_units unit)
Invert the units, most commonly used for Fourier transform results.
bool Units_haveCalRep(das_units unit)
Determine if the units in question can be converted to date-times.
char * Units_toLabel(das_units unit, char *sBuf, int nLen)
Get label string representation das_units.
void Units_convertToDt(das_time *pDt, double value, das_units epoch_units)
Convert a value in time offset units to a calendar representation.
das_units Units_root(das_units unit, int root)
Reduce units to a root.
double Units_convertTo(das_units toUnits, double rVal, das_units fromUnits)
Generic unit conversion utility.
const char * Units_toStr(das_units unit)
Get the canonical string representation of a das_unit Even though das_unit is a const char*...
das_units Units_interval(das_units unit)
Get the unit type for intervals between data points of a given unit type.
das_units Units_multiply(das_units ut1, das_units ut2)
Combine units via multiplication.
das_units Units_fromStr(const char *string)
Basic constructor for das_unit's.
double Units_secondsSinceMidnight(double rVal, das_units epoch_units)
Get seconds since midnight for some value of an epoch time unit.
das_units Units_divide(das_units a, das_units b)
Combine units via division.
das_units Units_reduce(das_units orig, double *pFactor)
Reduce arbitrary units to the most basic know representation.
bool Units_canConvert(das_units fromUnits, das_units toUnits)
Determine if given units are interchangeable Though not as good a solution as using UDUNITS2 works fo...
bool Units_canMerge(das_units left, int op, das_units right)
Determine if the units of values in a binary expression are compatable.
das_units Units_power(das_units unit, int power)
Raise units to a power.
double Units_convertFromDt(das_units epoch_units, const das_time *pDt)
Convert a calendar representation of a time to value in time offset units.
Basic date-time structure used throughout the Das1 & Das2 utilities.
Definition: time.h:47
const char * das_units
Enumeration of unit types, that correspond to physical unit types.
Definition: units.h:135