Skip to content

Photosynthetically active radiation decomposition model #2047

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

Closed
echedey-ls opened this issue May 12, 2024 · 9 comments · Fixed by #2048
Closed

Photosynthetically active radiation decomposition model #2047

echedey-ls opened this issue May 12, 2024 · 9 comments · Fixed by #2048
Labels
enhancement GSoC Contributions related to Google Summer of Code.
Milestone

Comments

@echedey-ls
Copy link
Contributor

Following my GSoC proposal, there are two models I plan to contribute regarding Photosynthetically Active Radiation, PAR. This is of great importance in the design of AgriVoltaic systems, since PAR is one of the metrics used for the simulation of crops productivity.

I pretend this is the first one due to simplicity. The model takes an input of the global irradiance diffuse fraction and the solar elevation, and outputs the fraction of diffuse PAR. See Eq. (1) in [2]. It is a derivation of equations (9) & (10) in [1]. This is known as the Spitters relationship in [2].

  • [1] C. J. T. Spitters, H. A. J. M. Toussaint, and J. Goudriaan,
    'Separating the diffuse and direct component of global radiation and its
    implications for modeling canopy photosynthesis Part I. Components of
    incoming radiation', Agricultural and Forest Meteorology, vol. 38,
    no. 1, pp. 217-229, Oct. 1986, :doi:10.1016/0168-1923(86)90060-2.
  • [2] S. Ma Lu et al., 'Photosynthetically active radiation decomposition
    models for agrivoltaic systems applications', Solar Energy, vol. 244,
    pp. 536-549, Sep. 2022, :doi:10.1016/j.solener.2022.05.046.

Describe the solution you'd like
A function in a new module, presumably pvlib.par, that has the function spitters_relationship with the described inputs and output.

Describe alternatives you've considered
Other names for the module pvlib.agrivoltaic[s] or trying to fit it into current structure until new things can be included and then arranged in the future. Take into account moving things requires deprecations.
Other names for the function, may be par_diffuse_fraction_from_global or so. However, I think an author-named model is better in this case. There may be more models about that, like the modified by Gu et al., Eq. (3) in [2].

As always, I'm open to other alternatives.

Additional context
I will open a PR in short as an initial proposal.

Ask, discuss and suggest freely.

@kandersolar
Copy link
Member

I am a complete non-expert in agriPV, but my initial reaction is that PAR is too narrow a modeling scope to warrant its own pvlib.par module. I could potentially be convinced that a broader pvlib.agrivoltaics module is a good idea, but it seems to me that many models relevant to agriPV will fit naturally into existing modules. For example, PAR models could go in pvlib.spectrum (PAR is basically just spectral mismatch for plants, right?) or pvlib.irradiance, and several relevant view factor calculations are already available in pvlib.bifacial.utils.

@AdamRJensen
Copy link
Member

For example, PAR models could go in pvlib.spectrum (PAR is basically just spectral mismatch for plants, right?) or pvlib.irradiance, and several relevant view factor calculations are already available in pvlib.bifacial.utils.

I agree that it seems to make sense to put PAR functions in pvlib.spectrum.

@AdamRJensen AdamRJensen added the GSoC Contributions related to Google Summer of Code. label May 24, 2024
@echedey-ls
Copy link
Contributor Author

I've kept the documentation API section on agrivoltaics. Should I remove it too?

Just a minor organization idea, the function can be under pvlib.spectrum namespace but in another file, currently I've put it inside mismatch.py.

@AdamRJensen
Copy link
Member

I've kept the documentation API section on agrivoltaics. Should I remove it too?

Hmm I'd lean towards keeping it with it's module.

Just a minor organization idea, the function can be under pvlib.spectrum namespace but in another file, currently I've put it inside mismatch.py.

What would the argument be for thar?

@echedey-ls
Copy link
Contributor Author

Hmm I'd lean towards keeping it with it's module.

Okay, I don't have a strong opinion on that either.

What would the argument be for thar?

I kinda dislike having too many functions of different topics in the same file. Not a problem to have it there for me; in fact, isolating one function in a file is kinda weird too, so I'm happy with it in mismatch.py. It is just another idea to take into account in case of a big-reorg.

@cwhanse
Copy link
Member

cwhanse commented May 24, 2024

@echedey-ls @AdamRJensen I commented on echedey's GSoC issue. I think the PAR function should live in pvlib.irradiance.

@wholmgren
Copy link
Member

Just a minor organization idea, the function can be under pvlib.spectrum namespace but in another file

This is my preference if we anticipate additional spectral models for agrivoltaics. I don't know much about it but anticipate that there may be interest in, say, integration of quantum efficiency curves and that naturally should be near the similar code for traditional PV.

I'm not too enthusiastic about irradiance.py... this function only appears to potentially fit there because that module is already so broad in scope. (Recall previous discussion of breaking it up into transposition.py and other modules)

@cwhanse
Copy link
Member

cwhanse commented May 25, 2024

But the new function in #2048 isn't a spectral model in the scope of pvlib.spectrums code module description. It's just translating broadband DHI fraction from diffuse fraction for a restricted range of wavelength. I think it is another version of an irradiance separation model.

@cwhanse
Copy link
Member

cwhanse commented May 25, 2024

We have three comment threads on this naming/organization: here, #2064 and #2048.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement GSoC Contributions related to Google Summer of Code.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants