How to compute sunset and dawn times with python?

Mike C. Fletcher mcfletch at geocities.com
Mon Mar 11 03:40:41 EST 2002


Since it seems no-one has responded, I put together a quicky module
showing a way to do this.  The code is taken from a US Gov't (SRRB)
web-site, but it's billed as "low accuracy", so don't take it as gospel
(it's off by a minute in 2 of the 6 test dates I tried against the
online (accurate) one).

This web-site has a javascript implementation of certain of the
functions that are used in the online version someone who wanted could
translate those.

The Python module is available here:
	http://members.rogers.com/mcfletch/programming/
	(sunriseset.py)

SRRB Sunrise Calculator:
	http://www.srrb.noaa.gov/highlights/sunrise/sunrise.html

HTH,
Mike


Tist Verdonck wrote:
 > Does anyone know how to compute sunset and dawn times with python?
 >
 > thanx,
 > Tist
 >
_______________________________________
    Mike C. Fletcher
    http://members.rogers.com/mcfletch/







More information about the Python-list mailing list