Python wrapper for sun position algorithm written in c++ by Blanco-Muriel. Accuracy 1 degree for the time interval from 1999 to 2015.
Blanco-Muriel M., Alarcon-Padilla D.C., Lopez-Mratalla D., and Lara-Coira M., “Computing the Solar Vector”, Solar Energy Vol. 70, No. 5, pp. 431-441, 2001.
- To calculate sun position:
>>> import sunpos: >>> print sunpos.__doc__
Sunpos package provides three structueres:
- cTime:
whith fields:
- iYear:
year, integer
- iMonth:
month, integer
- iDay:
day, integer
- dHours:
double, UTC hours
- dMinutes:
double, minutes
- dSeconds:
double, seconds
- cLocation:
with fields:
- dLongitude:
double, longitude
- dLatitude:
double, latitude
- cSunCoordinates:
with fields:
- dZenithAngle:
double, zenith angle, degrees
- dAzimuth:
double, azimuth angle, degrees
>>> loc=sunpos.cLocation() >>> loc.dLatitude = 43.1 >>> loc.dLongitude = 131.9 >>> time=sunpos.cTime() >>> time.iYear = 2013 #imteger, year >>> time.iMonth = 10 #Integer, month >>> time.iDay = 13 #integer, day >>> time.dHours = 16 #double, hours UTC >>> time.dMinutes = 32 #double, minutes >>> time.dSeconds = 12 #double, seconds >>> #calculations >>> res = sunpos.sunposf(time, loc) >>> #or >>> res = sunpos.cSunCoordinates() >>> sunpos.sunpos(time, loc, res) >>> print res.dZenithAngle # sun's zenith angle >>> print res.dAzimuth # sun's azimuth angle: >>>
Metadata
Release files for sunpos 1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sunpos-1.1.zip | 34.5 kB | Without provenance | Details for sunpos-1.1.zip |
Release files / sunpos-1.1.zip
| Download URL | sunpos-1.1.zip |
|---|---|
| Size | 34.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ba7d0269b39119bfca9955afd48409bc209f9b77b66f36e1eb4ab1bdff0d8db0
|
|
BLAKE2b-256 checksum How to use checksums |
477ca8ce72febe64fb253f76ff8f184192edfd2a8d485ac25f4c0d0eed55b76d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for sunpos 1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.