-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Floating PV gallery example #2110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
kandersolar
merged 59 commits into
pvlib:main
from
IoannisSifnaios:gallery_example_floating_pv
Jul 8, 2024
Merged
Changes from 11 commits
Commits
Show all changes
59 commits
Select commit
Hold shift + click to select a range
e1a1eac
floating PV gallery example
IoannisSifnaios 68bd293
fixed linter
IoannisSifnaios 7a78f09
fixed toc
IoannisSifnaios af420f1
formatting
IoannisSifnaios cec58e9
formatting vol.2
IoannisSifnaios 8f533c5
formatting vol.3
IoannisSifnaios e701066
formatting vol.4
IoannisSifnaios 9e152e5
fixed linter
IoannisSifnaios 5d0aef4
formatting vol.5
IoannisSifnaios d3c9567
formatting vol.6
IoannisSifnaios f5cdf17
fixed linter
IoannisSifnaios 7446857
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 84ea4a5
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios b393dc8
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios c68c899
Cliff's suggestions
IoannisSifnaios 7ca85cf
plot all sets of coefficients in a figure
IoannisSifnaios 379037d
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios aca26d9
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 730a090
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 811c7ec
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 2906551
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 7993bbf
Added watsnew
IoannisSifnaios ccdc288
Cliff's review vol.2
IoannisSifnaios 11cb899
Update table and plot with extra coeffs
IoannisSifnaios f4a7fee
Formatting
IoannisSifnaios 22f005e
add math mode to Tamb
IoannisSifnaios c8f3a1e
typo fix
IoannisSifnaios e233e06
leo's suggestion vol.2
IoannisSifnaios bb738af
Merge branch 'main' into gallery_example_floating_pv
IoannisSifnaios b27e950
update whatsnew
IoannisSifnaios 13a5e6f
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 9e4f800
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios aa9639b
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 5ae1d09
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios dfbb43d
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios c889be7
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 17e0ceb
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 11c6504
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 44e26bd
fixed linter and removed last sentence
IoannisSifnaios f0b4958
minor edit
IoannisSifnaios 4f2621c
text edits
IoannisSifnaios 3fa67fa
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios dbd5232
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 0ffd7bc
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 5380561
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 7a16416
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios b42666e
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 25e8302
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios a3c024f
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 7bd40bd
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios a358d12
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios ed2a942
Update docs/sphinx/source/whatsnew/v0.11.1.rst
IoannisSifnaios f51fe3f
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios fe09404
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 6d5e440
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios d3804b7
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios e878f2d
Update docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
IoannisSifnaios 17ff830
Update plot_floating_pv_cell_temperature.py
IoannisSifnaios 0f0124f
update text
IoannisSifnaios File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Floating PV Systems Modelling | ||
----------------------------- |
229 changes: 229 additions & 0 deletions
229
docs/examples/floating-pv/plot_floating_pv_cell_temperature.py
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,229 @@ | ||
r""" | ||
Calculating the cell temperature for floating PV | ||
================================================ | ||
|
||
This example demonstrates how to calculate the cell temperature for | ||
floating PV systems using the PVSyst temperature model. | ||
|
||
One of the primary benefits attributed to floating photovoltaic (FPV) systems | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
is their lower operating temperatures, which are expected to increase the | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
operating efficiency. In general, the temperature at which a photovoltaic | ||
module operates is influenced by various factors including solar radiation, | ||
ambient temperature, wind speed and direction, and the characteristics of the | ||
cell and module materials, as well as the mounting structure. Both radiative | ||
and convective heat transfers play roles in determining the module's | ||
temperature. | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
One of the most common models for calculating the PV cell temperature is the | ||
empirical heat loss factor model suggested by Faiman and implemented in | ||
PVSyst (:py:func:`~pvlib.temperature.pvsyst_cell`). The PVSyst model for cell | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
temperature :math:`T_{C}` is given by | ||
|
||
.. math:: | ||
:label: pvsyst | ||
|
||
T_{C} = T_{a} + \frac{\alpha \cdot E \cdot (1 - \eta_{m})}{U_{c} + U_{v} \cdot WS} | ||
|
||
Where :math:`E` is the plane-of-array irradiance, :math:`T_{a}` is the | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
ambient air temperature, :math:`WS` is the wind speed, :math:`\alpha` is the | ||
absorbed fraction of the incident irradiance, :math:`\eta_{m}` is the | ||
electrical efficiency of the module, :math:`U_{c}` is the wind-idependent heat | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
loss coefficient, and :math:`U_{v}` is the wind-dependent heat loss coefficient. | ||
|
||
However, the default heat loss coefficient values of this model were | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
specified for land-based PV systems and are not necessarily representative | ||
for FPV systems. | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
In FPV systems, variations in heat loss coefficients are considerable, not | ||
only due to differences in design but also because of geographic factors. | ||
Systems with extensive water surfaces, closely packed modules, and restricted | ||
airflow behind the modules generally exhibit lower heat loss coefficients | ||
compared to those with smaller water surfaces and better airflow behind the | ||
modules. | ||
|
||
For FPV systems installed over water without direct contact, the module's | ||
operating temperature, much like in land-based systems, is mainly influenced | ||
by the mounting structure (which significantly affects the U-value), wind, | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
and air temperature. Thus, factors that help reduce operating temperatures in | ||
such systems include lower air temperatures and changes in air flow beneath | ||
the modules (wind/convection). In some designs where the modules are in | ||
direct thermal contact with water, cooling effectiveness is largely dictated | ||
by the water temperature. | ||
|
||
The table below gives heat loss coefficients derrived for different systems | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
and locations as found in the literature. In this example, the FPV cell | ||
temperature will be calculated using some of the coefficients below. | ||
|
||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
| System | Location |:math:`U_{c}` | :math:`U_{v}` | Reference | | ||
| | |:math:`[\frac{W}{m^2 \cdot K}]` | :math:`[\frac{W}{m^3 \cdot K \cdot s}]`| | | ||
+=========================+=============+================================+========================================+===========+ | ||
| Monofacial module, | Netherlands | 24.4 | 6.5 | [1]_ | | ||
| open structure, | | | | | | ||
| two-axis tracking, | | | | | | ||
| small water footprint | | | | | | ||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
| Monofacial module, | Netherlands | 25.2 | 3.7 | [1]_ | | ||
| closed structure, | | | | | | ||
| large water footprint | | | | | | ||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
| Monofacial module, | Singapore | 34.8 | 0.8 | [1]_ | | ||
| closed structure, | | | | | | ||
| large water footprint | | | | | | ||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
| Monofacial module, | Singapore | 18.9 | 8.9 | [1]_ | | ||
| closed stucuture, | | | | | | ||
| medium water footprint | | | | | | ||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
| Monofacial module, | Singapore | 35.3 | 8.9 | [1]_ | | ||
| open strucuture, | | | | | | ||
| free-standing | | | | | | ||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
| Monofacial module, | Norway | 86.5 | 0 | [2]_ | | ||
| in contact with | | | | | | ||
| water | | | | | | ||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
| Monofacial module, | South Italy | 31.9 | 1.5 | [3]_ | | ||
| open structure, | | | | | | ||
| free-standing | | | | | | ||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
| Bifacial module, | South Italy | 35.2 | 1.5 | [3]_ | | ||
| open structure, | | | | | | ||
| free-standing | | | | | | ||
+-------------------------+-------------+--------------------------------+----------------------------------------+-----------+ | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
References | ||
---------- | ||
.. [1] Dörenkämper M., Wahed A., Kumar A., de Jong M., Kroon J., Reindl T. | ||
(2021), 'The cooling effect of floating PV in two different climate zones: | ||
A comparison of field test data from the Netherlands and Singapore' | ||
Solar Energy, vol. 214, pp. 239-247, :doi:`10.1016/j.solener.2020.11.029`. | ||
|
||
.. [2] Kjeldstad T., Lindholm D., Marstein E., Selj J. (2021), 'Cooling of | ||
floating photovoltaics and the importance of water temperature', Solar | ||
Energy, vol. 218, pp. 544-551, :doi:`10.1016/j.solener.2021.03.022`. | ||
|
||
.. [3] Tina G.M., Scavo F.B., Merlo L., Bizzarri F. (2021), 'Comparative | ||
analysis of monofacial and bifacial photovoltaic modules for floating | ||
power plants', Applied Energy, vol 281, pp. 116084, | ||
:doi:`10.1016/j.apenergy.2020.116084`. | ||
""" # noqa: E501 | ||
|
||
# %% | ||
# Read example weather data | ||
# ^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
# Read weather data from a TMY3 file and calculate the solar position and | ||
# the plane-of-array irradiance. | ||
|
||
import pvlib | ||
import matplotlib.pyplot as plt | ||
from pathlib import Path | ||
|
||
# Assume a FPV system on a lake with the following specifications | ||
tilt = 30 # degrees | ||
azimuth = 180 # south-facing | ||
|
||
# Datafile found in the pvlib distribution | ||
data_file = Path(pvlib.__path__[0]).joinpath('data', '723170TYA.CSV') | ||
|
||
tmy, metadata = pvlib.iotools.read_tmy3( | ||
data_file, coerce_year=2002, map_variables=True | ||
) | ||
tmy = tmy.filter( | ||
['ghi', 'dni', 'dni_extra', 'dhi', 'temp_air', 'wind_speed', 'pressure'] | ||
) # remaining columns are not needed | ||
tmy = tmy['2002-06-06 00:00':'2002-06-06 23:59'] # select period | ||
|
||
solar_position = pvlib.solarposition.get_solarposition( | ||
# TMY timestamp is at end of hour, so shift to center of interval | ||
tmy.index.shift(freq='-30T'), | ||
latitude=metadata['latitude'], | ||
longitude=metadata['longitude'], | ||
altitude=metadata['altitude'], | ||
pressure=tmy['pressure'] * 100, # convert from millibar to Pa | ||
temperature=tmy['temp_air'], | ||
) | ||
solar_position.index = tmy.index # reset index to end of the hour | ||
|
||
# Albedo calculation for inland water bodies | ||
albedo = pvlib.albedo.inland_water_dvoracek( | ||
solar_elevation=solar_position['elevation'], | ||
surface_condition='clear_water_no_waves' | ||
) | ||
|
||
# Use transposition model to find plane-of-array irradiance | ||
irradiance = pvlib.irradiance.get_total_irradiance( | ||
surface_tilt=tilt, | ||
surface_azimuth=azimuth, | ||
solar_zenith=solar_position['apparent_zenith'], | ||
solar_azimuth=solar_position['azimuth'], | ||
dni=tmy['dni'], | ||
dni_extra=tmy['dni_extra'], | ||
ghi=tmy['ghi'], | ||
dhi=tmy['dhi'], | ||
albedo=albedo, | ||
model='haydavies' | ||
) | ||
|
||
# %% | ||
# Calculate cell temperature | ||
# ^^^^^^^^^^^^^^^^^^^^^^^^^^ | ||
# The temperature of the PV cell is calculated for a floating PV system located | ||
# on a lake: | ||
|
||
# Monnofacial floating module open strucuture | ||
T_cell_floating = pvlib.temperature.pvsyst_cell( | ||
poa_global=irradiance['poa_global'], | ||
temp_air=tmy['temp_air'], | ||
wind_speed=tmy['wind_speed'], | ||
u_c=35.3, | ||
u_v=8.9 | ||
) | ||
|
||
# In order to idetify the effect of the heat loss coefficinets on the cell | ||
# temperature, the PV cell temperature for the same system is calculated | ||
# using the default coefficients of the equation. It should be noted that the | ||
# default coefficeints were derrived for land-based systems. | ||
T_cell_land = pvlib.temperature.pvsyst_cell( | ||
poa_global=irradiance['poa_global'], | ||
temp_air=tmy['temp_air'], | ||
wind_speed=tmy['wind_speed'] | ||
) | ||
|
||
# %% | ||
# Plot the results | ||
# ^^^^^^^^^^^^^^^^ | ||
|
||
# Convert Dataframe Indexes to Hour format to make plotting easier | ||
T_cell_floating.index = T_cell_floating.index.strftime("%H") | ||
T_cell_land.index = T_cell_land.index.strftime("%H") | ||
|
||
fig, axes = plt.subplots() | ||
axes.set( | ||
xlabel="Hour", | ||
ylabel="Temperature $[°C]$", | ||
title="PV cell temperature for floating and land-based system" | ||
) | ||
|
||
axes.plot( | ||
T_cell_floating, | ||
label='Floating PV coeff.' | ||
) | ||
|
||
axes.plot( | ||
T_cell_land, | ||
label='Land-based PV coeff.' | ||
) | ||
|
||
axes.set_ylim(20, 45) | ||
axes.set_xlim('06', '20') | ||
axes.grid() | ||
axes.legend(loc="upper left") | ||
plt.tight_layout() | ||
plt.show() | ||
|
||
# %% | ||
# The above figure illustrates the necessity of choosing appropriate heat loss | ||
IoannisSifnaios marked this conversation as resolved.
Show resolved
Hide resolved
|
||
# coefficients when using the PVSyst model for calculating the cell temperature | ||
# for floating PV systems. A difference of up to 10 °C was obtained for the two | ||
# sets of coefficients. |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.