Skip to content

Commit f9606dc

Browse files
committed
initial additions
1 parent 4089dd9 commit f9606dc

1 file changed

Lines changed: 111 additions & 4 deletions

File tree

docs/sphinx/source/user_guide/modeling_topics/singlediode.rst

Lines changed: 111 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,114 @@
11
.. _singlediode:
22

3-
Single Diode Equation
4-
=====================
3+
Single diode models
4+
===================
5+
6+
Single-diode models are a popular means of simulating the electrical output
7+
of a PV module under any given irradiance and temperature conditions.
8+
A single-diode model (SDM) pairs the single-diode equation (SDE) with a set of
9+
auxiliary equations that predict the SDE parameters at any given irradiance
10+
and temperature. All SDMs use the SDE, but their auxiliary equations differ.
11+
For more background on SDMs, see the `PVPMC website
12+
<https://pvpmc.sandia.gov/modeling-guide/2-dc-module-iv/single-diode-equivalent-circuit-models/>`_.
13+
14+
Three SDMs are currently available in pvlib: the CEC SDM, the PVsyst SDM,
15+
and the De Soto SDM. pvlib splits these models into two steps. The first
16+
is to compute the auxiliary equations using one of the following functions:
17+
18+
* CEC SDM: :py:func:`~pvlib.pvsystem.calcparams_cec`
19+
* PVsyst SDM: :py:func:`~pvlib.pvsystem.calcparams_pvsyst`
20+
* De Soto SDM: :py:func:`~pvlib.pvsystem.calcparams_desoto`
21+
22+
The second step is to use the output of these functions to compute points on
23+
the SDE's I-V curve, as described in the following sections.
24+
25+
Computing key SDE I-V points
26+
----------------------------
27+
Three points on the SDE I-V curve are typically of special interest for PV modeling:
28+
the maximum power (MP), open circuit (OC) and short circuit (SC) points. However,
29+
because the SDE is an implicit transcendental equation, it is not possible
30+
to directly calculate these points. Instead, pvlib provides several algorithms
31+
for computing these points.
32+
33+
The most accurate and convenient function is :py:func:`pvlib.pvsystem.singlediode`.
34+
It provides several methods of computing these points:
35+
36+
+------------------+------------+-----------+-------------------------+
37+
| Method | Type | Speed | Guaranteed convergence? |
38+
+==================+============+===========+=========================+
39+
| ``newton`` | iterative | fast | no |
40+
+------------------+------------+-----------+-------------------------+
41+
| ``brentq`` | iterative | slow | yes |
42+
+------------------+------------+-----------+-------------------------+
43+
| ``chandrupatla`` | iterative | fast | yes |
44+
+------------------+------------+-----------+-------------------------+
45+
| ``lambertw`` | explicit | medium | yes |
46+
+------------------+------------+-----------+-------------------------+
47+
48+
If lower accuracy (within ~1%) is allowable, these points can be estimated
49+
much more quickly using :py:func:`pvlib.singlediode.batzelis_keypoints`.
50+
51+
52+
Computing full I-V curves
53+
-------------------------
54+
55+
Full I-V curves with an arbitrary number of points can be computed using
56+
:py:func:`pvlib.pvsystem.i_from_v` and :py:func:`pvlib.pvsystem.v_from_i`, which
57+
calculate either current or voltage from the other. It is often useful to
58+
first compute the key points using :py:func:`pvlib.pvsystem.singlediode` to
59+
determine the open-circuit or short-circuit values, and then compute a range
60+
of voltages/currents from zero to those extreme points. This range can then
61+
be used with the above functions to compute the I-V curve.
62+
63+
64+
Special thin film parameters
65+
----------------------------
66+
67+
The PVsyst SDM has two additional, optional parameters to better represent
68+
the behavior of CdTe and a-Si modules. As these parameters are not included
69+
in the standard SDE, special methods are needed to account for them.
70+
The functions :py:func:`pvlib.pvsystem.max_power_point`,
71+
:py:func:`pvlib.singlediode.bishop88_i_from_v`,
72+
and :py:func:`pvlib.singlediode.bishop88_v_from_i`
73+
can compute the key points and full I-V curves using these parameters.
74+
75+
76+
Reverse bias breakdown
77+
----------------------
78+
79+
Although the standard SDE does not account for reverse bias breakdown, the
80+
following functions can optionally include an extra term for modeling it:
81+
:py:func:`pvlib.pvsystem.max_power_point`,
82+
:py:func:`pvlib.singlediode.bishop88_i_from_v`,
83+
and :py:func:`pvlib.singlediode.bishop88_v_from_i`.
84+
85+
86+
Model parameter values
87+
----------------------
88+
89+
Despite some models having parameters with similar names, parameter values are
90+
specific to the model and thus must be produced with the intended model in mind.
91+
Sometimes sets of parameter values can be read in from external sources, for example:
92+
93+
* CEC SDM parameter database available from :py:func:`~pvlib.pvsystem.retrieve_sam`
94+
* PAN files, which can be read using :py:func:`~pvlib.iotools.read_panond`
95+
96+
pvlib also provides a set of functions that can estimate SDM parameter values
97+
from various datasources:
98+
99+
+---------------------------------------------------------------+---------+--------------------+
100+
| Function | SDM | Inputs |
101+
+===============================================================+=========+====================+
102+
| :py:func:`~pvlib.ivtools.sdm.fit_cec_sam` | CEC | datasheet |
103+
| :py:func:`~pvlib.ivtools.sdm.fit_desoto` | De Soto | datasheet |
104+
| :py:func:`~pvlib.ivtools.sdm.fit_desoto_sandia` | De Soto | I-V curves |
105+
| :py:func:`~pvlib.ivtools.sdm.fit_pvsyst_sandia` | PVsyst | I-V curves |
106+
| :py:func:`~pvlib.ivtools.sdm.fit_pvsyst_iec61853_sandia_2025` | PVsyst | IEC 61853-1 matrix |
107+
+---------------------------------------------------------------+---------+--------------------+
108+
109+
110+
Single-diode equation
111+
---------------------
5112

6113
This section reviews the solutions to the single diode equation used in
7114
pvlib-python to generate an IV curve of a PV module.
@@ -15,7 +122,7 @@ The :func:`pvlib.pvsystem.singlediode` function allows the user to choose the
15122
method using the ``method`` keyword.
16123

17124
Lambert W-Function
18-
------------------
125+
******************
19126
When ``method='lambertw'``, the Lambert W-function is used as previously shown
20127
by Jain, Kapoor [1, 2] and Hansen [3]. The following algorithm can be found on
21128
`Wikipedia: Theory of Solar Cells
@@ -50,7 +157,7 @@ Then the module current can be solved using the Lambert W-function,
50157
51158
52159
Bishop's Algorithm
53-
------------------
160+
******************
54161
The function :func:`pvlib.singlediode.bishop88` uses an explicit solution [4]
55162
that finds points on the IV curve by first solving for pairs :math:`(V_d, I)`
56163
where :math:`V_d` is the diode voltage :math:`V_d = V + I*Rs`. Then the voltage

0 commit comments

Comments
 (0)