-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add 2025 coefficients for Huld model #2486
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
Changes from 9 commits
4b66810
928207e
1833dc1
98846e6
241c272
79f490f
a5a5ae8
aa7d3ee
91da25c
140b55b
752ef05
0703ac1
889805b
57edf70
92b5cde
8b41911
89727f3
5052843
607938d
cafd131
d078e74
a23f5cd
c74a279
a1ea251
4d56803
a72d557
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,7 +37,7 @@ def pvefficiency_adr(effective_irradiance, temp_cell, | |
the reference conditions. [unitless] | ||
|
||
k_d : numeric, negative | ||
“Dark irradiance” or diode coefficient which influences the voltage | ||
"Dark irradiance" or diode coefficient which influences the voltage | ||
increase with irradiance. [unitless] | ||
|
||
tc_d : numeric | ||
|
@@ -225,24 +225,54 @@ def adr_wrapper(xdata, *params): | |
return popt | ||
|
||
|
||
def _infer_k_huld(cell_type, pdc0): | ||
def _infer_k_huld(cell_type, pdc0, k_version): | ||
r""" | ||
Get the EU JRC updated coefficients for the Huld model. | ||
|
||
Parameters | ||
---------- | ||
cell_type : str | ||
Must be one of 'csi', 'cis', or 'cdte' | ||
pdc0 : numeric | ||
Power of the modules at reference conditions [W] | ||
k_version : str | ||
Either '2011' or '2025'. | ||
|
||
Returns | ||
------- | ||
tuple | ||
The six coefficients (k1-k6) for the Huld model, scaled by pdc0 | ||
""" | ||
# from PVGIS documentation, "PVGIS data sources & calculation methods", | ||
# Section 5.2.3, accessed 12/22/2023 | ||
# The parameters in PVGIS' documentation are for a version of Huld's | ||
# equation that has factored Pdc0 out of the polynomial: | ||
# P = G/1000 * Pdc0 * (1 + k1 log(Geff) + ...) so these parameters are | ||
# multiplied by pdc0 | ||
huld_params = {'csi': (-0.017237, -0.040465, -0.004702, 0.000149, | ||
0.000170, 0.000005), | ||
'cis': (-0.005554, -0.038724, -0.003723, -0.000905, | ||
-0.001256, 0.000001), | ||
'cdte': (-0.046689, -0.072844, -0.002262, 0.000276, | ||
0.000159, -0.000006)} | ||
if k_version == '2011': | ||
|
||
huld_params = {'csi': (-0.017237, -0.040465, -0.004702, 0.000149, | ||
0.000170, 0.000005), | ||
'cis': (-0.005554, -0.038724, -0.003723, -0.000905, | ||
-0.001256, 0.000001), | ||
'cdte': (-0.046689, -0.072844, -0.002262, 0.000276, | ||
0.000159, -0.000006)} | ||
elif k_version == '2025': | ||
# Updated coefficients from EU JRC paper | ||
huld_params = {'csi': (-0.017162, -0.040289, -0.004681, 0.000148, | ||
0.000169, 0.000005), | ||
'cis': (-0.005521, -0.038576, -0.003711, -0.000901, | ||
-0.001251, 0.000001), | ||
'cdte': (-0.046477, -0.072509, -0.002252, 0.000275, | ||
0.000158, -0.000006)} | ||
kandersolar marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
else: | ||
raise ValueError(f'Invalid k_version={k_version}: must be either ' | ||
'"2011" or "2025" as a string') | ||
k = tuple([x*pdc0 for x in huld_params[cell_type.lower()]]) | ||
return k | ||
|
||
|
||
def huld(effective_irradiance, temp_mod, pdc0, k=None, cell_type=None): | ||
def huld(effective_irradiance, temp_mod, pdc0, k=None, cell_type=None, | ||
k_version=None): | ||
cwhanse marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
r""" | ||
Power (DC) using the Huld model. | ||
|
||
|
@@ -274,6 +304,10 @@ def huld(effective_irradiance, temp_mod, pdc0, k=None, cell_type=None): | |
cell_type : str, optional | ||
If provided, must be one of ``'cSi'``, ``'CIS'``, or ``'CdTe'``. | ||
Used to look up default values for ``k`` if ``k`` is not specified. | ||
k_version : str, optional | ||
Either `'2011'` (default) or `'2025'`. Used to select default values | ||
for ``k`` if ``k`` is not specified. If `'2011'`, values from [1]_ | ||
are used; if `'2025'` values are from [2]_. | ||
cwhanse marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
||
Returns | ||
------- | ||
|
@@ -328,14 +362,21 @@ def huld(effective_irradiance, temp_mod, pdc0, k=None, cell_type=None): | |
|
||
References | ||
---------- | ||
.. [1] T. Huld, G. Friesen, A. Skoczek, R. Kenny, T. Sample, M. Field, | ||
E. Dunlop. A power-rating model for crystalline silicon PV modules. | ||
Solar Energy Materials and Solar Cells 95, (2011), pp. 3359-3369. | ||
:doi:`10.1016/j.solmat.2011.07.026`. | ||
.. [1] T. Huld, G. Friesen, A. Skoczek, R. Kenny, T. Sample, M. Field, and | ||
E. Dunlop, "A power-rating model for crystalline silicon PV | ||
modules," Solar Energy Materials and Solar Cells 95, (2011), | ||
pp. 3359-3369. :doi:`10.1016/j.solmat.2011.07.026`. | ||
.. [2] A. Chatzipanagi, N. Taylor, I. Suarez, A. Martinez, T. Lyubenova, | ||
and E. Dunlop, "An Updated Simplified Energy Yield Model for Recent | ||
Photovoltaic Module Technologies," | ||
Progress in Photovoltaics: Research and Applications 33, | ||
no. 8 (2025): 905–917, :doi:`10.1002/pip.3926`. | ||
""" | ||
if k is None: | ||
if cell_type is not None: | ||
k = _infer_k_huld(cell_type, pdc0) | ||
if k_version is None: | ||
k_version = '2011' | ||
k = _infer_k_huld(cell_type, pdc0, k_version) | ||
cwhanse marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
else: | ||
raise ValueError('Either k or cell_type must be specified') | ||
|
||
|
@@ -346,7 +387,10 @@ def huld(effective_irradiance, temp_mod, pdc0, k=None, cell_type=None): | |
logGprime = np.log(gprime, out=np.zeros_like(gprime), | ||
where=np.array(gprime > 0)) | ||
# Eq. 1 in [1] | ||
pdc = gprime * (pdc0 + k[0] * logGprime + k[1] * logGprime**2 + | ||
k[2] * tprime + k[3] * tprime * logGprime + | ||
k[4] * tprime * logGprime**2 + k[5] * tprime**2) | ||
pdc = gprime * ( | ||
pdc0 + k[0] * logGprime + k[1] * logGprime**2 + | ||
k[2] * tprime + k[3] * tprime * logGprime + | ||
k[4] * tprime * logGprime**2 + | ||
k[5] * tprime**2 | ||
) | ||
return pdc |
Uh oh!
There was an error while loading. Please reload this page.