This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
def daylength(dayOfYear, lat): | |
"""Computes the length of the day (the time between sunrise and | |
sunset) given the day of the year and latitude of the location. | |
Function uses the Brock model for the computations. | |
For more information see, for example, | |
Forsythe et al., "A model comparison for daylength as a | |
function of latitude and day of year", Ecological Modelling, | |
1995. |