Skip to main content

Module constants

Module constants 

Source
Expand description

Core constants for the BrightDate system.

§Epoch

The BrightDate epoch is J2000.0 — defined by the IAU as 2000-01-01T12:00:00.000 TT (Terrestrial Time). This same instant is:

TimescaleWall-clock label
TT2000-01-01T12:00:00.000
TAI2000-01-01T11:59:27.816
UTC2000-01-01T11:58:55.816
JulianJD 2451545.0
ModifiedMJD 51544.5

BrightDate 0.0 ≡ J2000.0, exactly. Bright days are SI days (86400 SI seconds), so the BrightDate timeline ticks uniformly (TAI-coherent) and has no leap-second discontinuities. Leap seconds only intervene when converting to/from UTC labels (Unix ms, ISO strings).

Constants§

CURRENT_TAI_UTC_OFFSET
Current TAI − UTC offset (37 s since 2017-01-01; no new leap seconds as of 2026).
DEFAULT_PRECISION
Default display precision (5 decimal places ≈ 0.864 s resolution).
J2000_JD
J2000.0 as a Julian Date — exact by definition of the J2000.0 epoch.
J2000_MJD
J2000.0 as a Modified Julian Date — exact by definition.
J2000_TAI_UNIX_S
J2000.0 in “TAI Unix seconds” — Unix-style elapsed seconds counted on the TAI timescale. Equals 946_727_967.816. Used internally as the origin against which BrightDate values are measured.
J2000_TT_UNIX_S
J2000.0 in “TT Unix seconds” (TT label expressed as Unix-style elapsed seconds on the TT timescale). Equals 946_728_000.000. This is the number the old library wrongly used as J2000_UNIX_MS_UTC.
J2000_UNIX_MS_UTCDeprecated
Backwards-compatible alias. Deprecated. Use J2000_UTC_UNIX_MS.
J2000_UTC_UNIX_MS
J2000.0 expressed in Unix milliseconds (a UTC-labelled timestamp).
LEAP_SECOND_TABLE
Leap-second table: (utc_unix_seconds, cumulative_tai_utc_offset).
LEAP_SECOND_TABLE_REVIEWED_AT
When the table was last reviewed (ISO date string).
LEAP_SECOND_TABLE_SOURCE
Source of the leap-second table.
LEAP_SECOND_TABLE_VALID_UNTIL_UNIX_S
The Unix-seconds timestamp after which the table should be re-checked. 2028-06-28T00:00:00Z
MAX_PRECISION
Maximum supported precision (12 decimal places ≈ 86.4 ps).
METRIC_UNITS
Metric unit descriptors: (name, days_per_unit).
MS_PER_DAY
Milliseconds per (SI) day.
SECONDS_PER_DAY
Seconds per (SI) day.
TAI_UTC_OFFSET_AT_J2000
TAI − UTC offset at J2000.0 (32 leap seconds had been inserted by then).
TT_TAI_OFFSET_SECONDS
TT − TAI offset (constant, defined by convention). TT = TAI + 32.184 s.