Skip to main content

A package for fundamental information of solar energy.

Project description

SolarEnergyPy

SolarEnergyPy

SolarEnergyPy is for education purpose where one can have fundamental information of solar energy.

Basic Information

  • Solar constant.

  • Solar position relative to a site on Earth in terms of lattitude, longitude and datetime.

  • Instant solar radiation on outer edge of atmosphere as well as beam and diffusion on Earth.

  • Spectral radiation map.

Requirements

  • Python 3

  • Matplotlib is installed.

Documentation

To be continued.

Installation

pip install SolarEnergyPy

Usage

from datetime import datetime



import pendulum



from SolarEnergyPy.solarPosition import solarPosition as sp



from SolarEnergyPy.solarRadiation import solarRadiation as sr







def solar_system_demo(longitude, latitude, dt):







    solar_position = sp(longitude, latitude)



    solar_radiation = sr()



    solar_position.clocktime = dt



    solar_radiation.clocktime = dt







    print(f"Solar Position:{sp.site}")



    print(f"Date-Time: {solar_position._datetime}")



    print(f"Latitude: {solar_position.latitude}")



    print(f"Longitude: {solar_position.longitude}")



    print(f"Declination: {solar_position.declination}")



    print(f"Solar Azimuth: {solar_position.solar_azimuth}")



    print(f"Solar Zenith: {solar_position.zenith}")







    print("\nSolar Radiation:")



    beam, diffuse = solar_radiation.solar_radiation_at()



    print(f"Beam Radiation: {beam} W/m^2")



    print(f"Diffuse Radiation: {diffuse} W/m^2")







if __name__ == '__main__':



    longitude = 112



    latitude = 31



    dt = pendulum.now('Asia/Shanghai')



    solar_system_demo(longitude, latitude, dt)

Update log

0.0.4 fix some bugs

0.0.3 Add some demos

0.0.2 Fix some bugs and and add case demos

0.0.1 SolarEnergyPy

License

This program is free software: you can redistribute it and/or modify

it under the terms of the GNU General Public License as published by

the Free Software Foundation, either version 3 of the License, or

(at your option) any later version.



This program is distributed in the hope that it will be useful,

but WITHOUT ANY WARRANTY; without even the implied warranty of

MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the

GNU General Public License for more details.



You should have received a copy of the GNU General Public License

along with this program.  If not, see <http://www.gnu.org/licenses/>.

Contact

heliqun@ustc.edu.cn

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

SolarEnergyPy-0.0.4.tar.gz (65.2 kB view details)

Uploaded Source

File details

Details for the file SolarEnergyPy-0.0.4.tar.gz.

File metadata

  • Download URL: SolarEnergyPy-0.0.4.tar.gz
  • Upload date:
  • Size: 65.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.10.10

File hashes

Hashes for SolarEnergyPy-0.0.4.tar.gz
Algorithm Hash digest
SHA256 24baa23c2be20a0dc8e8eb9ff17c93b593b671c4a57e5c3054ae39bd119ee9b7
MD5 f075100c79db6efed3d7b4653903f86b
BLAKE2b-256 9142ab59af51e6146c27821123f1d5c1a25568a920bcc40e492c17a2e577a836

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page