Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@jurand71
Created October 31, 2022 12:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jurand71/f0192e4e122b9b560d437e810aa99856 to your computer and use it in GitHub Desktop.
Save jurand71/f0192e4e122b9b560d437e810aa99856 to your computer and use it in GitHub Desktop.
#
# wczytanie bibliotek
#
import numpy as np
import pandas as pd
import pvlib
from pvlib.pvsystem import PVSystem
from pvlib.location import Location
from pvlib.modelchain import ModelChain
from pvlib.temperature import TEMPERATURE_MODEL_PARAMETERS as PARAMS
import warnings
warnings.filterwarnings(action='ignore')
#
# Określenie lokalizacji instalacji
#
latitute, longitute = 50.84093845231934, 18.908785660900786
tz = 'Europe/Warsaw'
altitude = 315
# utworzenie instancji obiektu lokalizacji instalacji
location = Location(latitute, longitute, tz, altitude)
#
# Budowa instalacji fotowoltaicznej
#
# wybór bazy urządzeń, a nastepnie inwertera i modułu z bazy danych
cec_inverters = pvlib.pvsystem.retrieve_sam('CECInverter')
sandia_modules = pvlib.pvsystem.retrieve_sam('SandiaMod')
inverter_parameters = cec_inverters['ABB__MICRO_0_25_I_OUTD_US_208__208V_']
module_parameters = sandia_modules['Canadian_Solar_CS5P_220M___2009_']
#model temperaturowy modułu
temp_model_parameters = PARAMS['sapm']['open_rack_glass_polymer']
#konfiguracja instalacji
PV_system = PVSystem(surface_tilt=35, surface_azimuth=180,
module_parameters=module_parameters,
inverter_parameters = inverter_parameters,
temperature_model_parameters = temp_model_parameters
)
#
# utworzenie instancji obiektu ModelChain
#
mc = ModelChain(PV_system, location)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment