What is fractional second?

I'm trying to understand what a fractional second is. I found a fractional second, here :

double uhd::time_spec_t::get_frac_secs ( void ) const Get the fractional part of the time in seconds. Returns: the fractional seconds 

What is a fractional second represented as double? Can someone give me an approximate value and how does this translate to seconds?

+4
source share
2 answers

A fractional second is a fraction of the time that is not an integer. Therefore, if you have a time like 12345678.9 , fractional second 0.9

+12
source

The example here can help you understand what fractional seconds are:

TSHESTAMR {(fractional-seconds)}

An optional parameter indicates the number of fractional seconds. If the parameter is not specified, the default number of fractional seconds is 6.

The following example shows several timestamps with different numbers of fractional seconds.

 DCL-S TS0 TIMESTAMP(0); // YYYY-MM-DD-hh-mm-ss DCL-S TS1 TIMESTAMP(1); // YYYY-MM-DD-hh-mm-ss.f DCL-S TS6A TIMESTAMP; // YYYY-MM-DD-hh-mm-ss.ffffff DCL-S TS6B TIMESTAMP(6); // YYYY-MM-DD-hh-mm-ss.ffffff DCL-S TS12 TIMESTAMP(12); // YYYY-MM-DD-hh-mm-ss.ffffffffffff 

through the IBM Knowledge Center - TIMESTAMP {(fractional seconds)}

0
source

Source: https://habr.com/ru/post/1391985/


All Articles