Hacker News new | past | comments | ask | show | jobs | submit login

I don't think getting the position of the sun is an edge case, it's a fundamental capability for the product to work at all



You could probably make a lookup table that works "well enough" in like a few hours.


You could probably make it in a few minutes - the direction of the sun is, to a first approximation, 15 degrees times the number of hours it is after midnight. This leads to a trick for using an analog watch as a compass:

https://www.citizenwatch-global.com/support/exterior/directi...

https://www.watchaffinity.co.uk/blog/how-to-use-your-watch-a...

This is more prone to errors closer to the equator and in the summer (https://possiblywrong.wordpress.com/2012/01/25/using-a-watch...) but should be good enough for picking a side of the bus.

(This is all in the northern hemisphere; in the southern hemisphere the sun goes the other way, so change the sign on everything.)


The equation of time gets in there too if I recall correctly - https://en.wikipedia.org/wiki/Equation_of_time

> The equation of time describes the discrepancy between two kinds of solar time. The word equation is used in the medieval sense of "reconciliation of a difference". The two times that differ are the apparent solar time, which directly tracks the diurnal motion of the Sun, and mean solar time, which tracks a theoretical mean Sun with uniform motion along the celestial equator. Apparent solar time can be obtained by measurement of the current position (hour angle) of the Sun, as indicated (with limited accuracy) by a sundial. Mean solar time, for the same place, would be the time indicated by a steady clock set so that over the year its differences from apparent solar time would have a mean of zero.

And this gets into a neat part of the Clock of the Long Now and a cam needed to keep track of that over 10,000 years. https://longnow.org/ideas/the-equation-of-time-cam-keeping-g...


The equation of time would be in there! But the largest that gets is about 16 minutes, corresponding to a 4-degree error in position, and there are much bigger sources of error. But thanks for the link to the Clock of the Long Now!


I believe they meant edge cases when dealing with sun position calculations or maybe other things, not that the sun position is an edge case.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: