Hacker News new | ask | show | jobs
by sed3 740 days ago
Dealing with leap seconds is very expensive. What happens if countries like China, Russia or Iran just decide to ignore leap seconds? We will have a clusterfuck of time zones divergent by a few seconds!

I am really into astronomy. But dealing with this, just so stars pass local meridian exactly at 00:00:00.000 is simply not worth it!

And one funny note, astronomers still use use Julian calendar (one made by Ceasar without Gregorian corrections in 16th century) to avoid similar issues. They avoid their own inventions!

8 comments

I think the terminology is pretty confusing, but as I understand it, astronomers use Julian Day numbers [1], which is not really using the Julian calendar - it's really no calendar at all, just a continuous count of days, so you don't need to think at all about the definition of leap days or leap years (until you want to convert back to a human-understandable form). "Julian" coming from how they choose the reference point in the Julian Calendar.

[1] https://en.wikipedia.org/wiki/Julian_day

There are also variants, for some science cases it is preferrable to get out of the Earth referential and move to e.g the barycentric reference frame and use the Barycentric Julian Date [1], which can itself be expressed in different standards (UTC, TAI (atomic time), TDB etc ...)

[1] https://en.wikipedia.org/wiki/Barycentric_Julian_Date

There’s an easy solution nobody seems to be considering. We put rockets on the moon to continually adjust its orbit in order to preserve perfect adherence to a 24-hour solar day.

Hell, once we’ve perfected this technique we could even use it to gradually pull us into a perfect 365-day year! Or better, 364 days, which is evenly divisible by 12 (edit: oops, 13) months.

I'm glad to see someone tackling the problem head-on instead of just coming up with workarounds.
> Or better, 364 days, which is evenly divisible by 12 months.

   364/12 = 30⅓
I wouldn’t call that much better. :-)
Whoops, I meant 13!
Leap seconds are in the process of being abolished. The ITU-R confirmed their part of the agreement at the world radiocommunication conference last year (the ITU-R’s triennial treaty update); the next stage is the CGPM in 2026 (the BIPM’s triennial treaty update).
Will there be another solution for the desynchronization of SI days and solar days? It looks like there’s been about 25 seconds difference in the past 30 years or so.
An option if it gets way off would be to just express it as TZ shift. Current rate seems to be about a second every two years, so we have some hundreds of years before we need to even shift by 15 minutes. An amount of divergence that I suspect would not really be even noticeable, especially as it develops over hundreds of years. The TZ code is used widely and regularly and systems tend to know how to handle it. Leap seconds are always a bit of an adventure from what I understand. (I'm not a sysadmin, so I don't know the details.)

Like -- I don't know, but is it actually important that the solar day is tied to "wall clock day" so snugly? So what if it's a couple minutes off...?

> Like -- I don't know, but is it actually important that the solar day is tied to "wall clock day" so snugly? So what if it's a couple minutes off...?

Even when you're assigned a correct hour-aligned time zone, you'll be off by an average of 15 minutes! Wall clock time just fundamentally has never been precise enough for leap seconds to solve a problem, by two orders of magnitude.

A 15 minute shift once every hundred years would wreak havoc on all of the software built when the shift was too far away to worry about.

Better to design in the requirement for all software to support these shifts, like a random 10 minute shift every day. That way nobody will write software that doesn’t support the shift.

Timezone aware code already has to process 15 minute timezones, IIRC; India is on a 30 minute timezone.

Some timezone changes are well published before the change and others are published after, and software has to pick up the pieces.

I'd imagine a 15 minute jump to recenter zones would be published with at least as much notice as changes to DST rules.

AFAICT from looking at the source for the tz database [0], it's capable of handling UTC offsets at least to a second level, if not fractional seconds.

[0] https://github.com/eggert/tz

UT1 is available from the IERS if you need it.
We can move timezone after 3000 years, when difference will be 1 hour and noticeable.
Yep. Timezone definitions already change regularly due to governments messing around with time; so software is already set up to handle this case.

Though I wonder what happens with the international dateline -- would it shift around the world, or would the UTC offsets get larger and larger? I imagine the latter would eventually also result in software issues when the UTC offset starts exceeding 24h.

There are moves to abolish DST and I suspect that after that happens timezones will ossify, which will make it difficult to use them to compensate for a large DUT1. And after 1000 years of gradually shifting daylight, people will probably be used to noon being a bit late and may well prefer it.
In a thousand years it is quiet possible there will be sizable enough population off of earth that trying to align time with the variable rotation of the earth will be seen as pointless Terracentrism
Maybe 1500 years and 30 min.
I've created a ticket in the backlog for this!
Maybe 750 years and 15 min.
Which leads to another interesting question: are we going to sync up UTC and TAI, or do we just have to live with a completely arbitrary several-second offset for all eternity?
Astronomers use "Julian Days" and "Julian Dates", but they are not at all based on the Julian calendar. They are just a linear count of days which is easier to plug in to algorithms. It is quite similar to the Unix Timestamp, and it is quite easy to convert between the two: jd =(unixT / 86400) + 2440587.5; [1].

But astronomers have to deal with the non-uniform, unpredictable rotation of the Earth in some way. Leap seconds only help a little, and predictions can only be made a few months into the future, so it is necessary to download the latest Earth Orientation data from the International Earth Rotation Service [2].

E.g. For the Apr 8 2024 solar eclipse, some popular camera control software packages had old predicted values for the Earth's rotation. Some due to the authors not updating them, some due to old installations that didn't update the data automatically. That caused people who didn't notice the discrepancy to miss their shots.

[1] https://celestialprogramming.com/julian.html

[2] https://www.iers.org/IERS/EN/Publications/Bulletins/bulletin...

> I am really into astronomy. But dealing with this, just so stars pass local meridian exactly at 00:00:00.000 is simply not worth it!

And of course it still doesn't actually happen, because almost all locations (i.e. with measure 1!) are not aligned to their time zones.

Doesn’t astronomy already use TAI, which has no leap seconds?
Astronomy is a big field. In my field it is either UTC or TDB.
AFAIK, astronomers use Julian DATES. It's related but not the same as the Julian calendar.
I honestly don’t understand the examples of why Russia, Iran, or China?

Is leapseconds going to be a US-friendly vs not thing?

At least in the case of Russia they voted against the removal of leap seconds.

https://arstechnica.com/science/2022/11/network-crashing-lea...

There was never a negative leap second, so most systems are not ready for it. It is not just a question of time metadata.

And cooperation could be a problem. I can not imagine Microsoft providing updates for illegal Windows 7 in North Korea, and NK government just taking them.

I don't understand why we should care if NK's systems are on time or not.
We should probably care that at least some of their systems share our definition of time.

International agreements have start times (and a couple of seconds could matter).

Physical things (any future international power supply for example) might depend on it too.

For better or worse, we have to be more charitable with NK than they are with us.

> International agreements have start times (and a couple of seconds could matter).

International agreement get violated all the time. good faithfulness is more important than those couple of seconds.

Electricity exchange grid needs to be phased within 60Hz, that is a delay of a few milliseconds. Baltic states hate Russia, but they are still connected this way for example.

Maybe you do not care, but this stuff is extremely important. Airplanes could crash over a few seconds difference!