geocat.comp.meteorology.max_daylight#
- geocat.comp.meteorology.max_daylight(jday, lat)#
Computes maximum number of daylight hours as described in the Food and Agriculture Organization (FAO) Irrigation and Drainage Paper 56 entitled:
Crop evapotranspiration - Guidelines for computing crop water requirement. Specifically, see equation 34 of Chapter 3.
Note for abs(lat) > 55 the eqns have limited validity.
- Parameters:
jday (
numpy.ndarray
,xarray.DataArray
,list
,float
) – Day of year. Must be 1Dlat (
numpy.ndarray
,xarray.DataArray
,list
,float
) – Latitude in degrees. Must be 1D
- Returns:
sunmax (
numpy.ndarray
,xarray.DataArray
,float
) – Calculated maximum sunlight in hours/day
Examples
>>> from geocat.comp import max_daylight >>> import numpy as np >>> jday = np.array([100, 123, 246]) >>> lat = np.array([10, 20]) >>> max_daylight(jday, lat) array([[12.18035083, 12.37238906], [12.37577081, 12.77668231], [12.16196585, 12.33440805]])
See also
Related NCL Functions: daylight_fao56