tai(3) tai(3) NNAAMMEE tai - manipulate times with 1-second precision SSYYNNTTAAXX ##iinncclluuddee <> double ttaaii__aapppprrooxx(&_t); int ttaaii__lleessss(&_a,&_b); void ttaaii__aadddd(&_t,&_a,&_b); void ttaaii__ssuubb(&_t,&_a,&_b); struct tai _t; struct tai _a; struct tai _b; DDEESSCCRRIIPPTTIIOONN A ssttrruucctt ttaaii stores an integer between 0 inclusive and 2^64 exclusive. The format of ssttrruucctt ttaaii is designed to speed up common operations; applications should not look inside ssttrruucctt ttaaii. A ssttrruucctt ttaaii variable is commonly used to store a TAI64 label. Each TAI64 label refers to one second of real time. TAI64 labels span a period of hundreds of billions of years. See hhttttpp::////ppoobbooxx..ccoomm//~~ddjjbb//pprroottoo//ttaaii6644..ttxxtt for more information. A ssttrruucctt ttaaii variable may also be used to store the numerical differ- ence between two TAI64 labels. AARRIITTHHMMEETTIICC ttaaii__aapppprrooxx returns a double-precision approximation to _t. The result of ttaaii__aapppprrooxx is always nonnegative. ttaaii__lleessss returns 1 if _a is smaller than _b, 0 otherwise. ttaaii__aadddd adds _a and _b modulo 2^64 and puts the result into _t. The inputs and outputs may overlap. ttaaii__ssuubb subtracts _b from _a modulo 2^64 and puts the result into _t. The inputs and outputs may overlap. SSEEEE AALLSSOO tai_now(3), tai_pack(3), taia(3), utc(3) tai(3)