Giter Club home page Giter Club logo

matlab_pv_lib's People

Contributors

cwhanse avatar danriley avatar joallen6 avatar mleefs avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

matlab_pv_lib's Issues

pvl_singleaxis error at low sun angles

Describe the bug:

Low sun angles with a tilted tracking axis cause an error in the backtracking calculation. Code attempts arcos() of a value outside [-1, 1]
pvlib-python #656

To Reproduce

SunZen=80;
SunAz=338;
Latitude=nan;
AxisTilt=30;
AxisAzimuth=180;
MaxAngle=60;
GCR=0.35;

Backtrack=0;
[~,~,mod_thetam, mod_azm]= pvl_singleaxis_v2(SunZen, SunAz, Latitude, AxisTilt, AxisAzimuth, MaxAngle, Backtrack, GCR)

Backtrack=1;
[~,~,mod_thetam, mod_azm]= pvl_singleaxis_v2(SunZen, SunAz, Latitude, AxisTilt, AxisAzimuth, MaxAngle, Backtrack, GCR)

Incorrect value for dEgdT in pvl_calcparams_CEC

In function “pvl_calcparams_CEC.m” the parameter dEgdT is set to 0.00002677 (i.e. 2.677e-5).
According to the documentation and the cited paper “[1] W. De Soto et al., "Improvement and validation of a model for photovoltaic array performance", Solar Energy, vol 80, pp. 78-88, 2006.”, the value should be one order of magnitude higher (2.677e-4). The Python version of the library also implements the larger value for dEgdT.

Thanks to Patrick for finding the bug.

Include a file hash for each PV_LIB file

In order for PV_LIB to used as a commercial verification tool (which may be up for debate) or a verification tool (may also be up for debate), there should be a method to verify that the files within PV_LIB are the same as those distributed officially. A hash listing for each file could accomplish this.

Improve convergence in v_from_i with large arguments

We currently use 3 iterations of a Newton method when the argument to the lambertw term is calculated in log-space. As the magnitude of the argument increases, the number of iterations should also increase to maintain the needed precision.

pvl_singlediode Isc calculation

pvl_singlediode returns a structure Result with the field Isc, and also can the field I containing a vector of current values. The first value of Result.I is not always equal to Result.Isc

Add function describing snow albedo change over time

Sandia National Laboratories is conducting research on the change of snow albedo over time and temperature since snowfall. If a model is developed that is successful in determining this relationship, include it in MATLAB_PV_LIB.

pvl_orgill_hollands.m mathematical mistake calculating diffuse fraction

There is a mistake in the calculation of the diffuse fraction in the Orgill Hollands function. There should be no jump discontinuities when plotting.

This should be changed from

if Kt(i)<=.35
    DF(i) = 1.0 - 0.249*Kt(i);
        
    % For Kt > 0.35 and Kt <= 0.75, set the diffuse fraction
elseif Kt(i)>.35 && Kt(i)<.75
    DF(i) = 1.577 - 1.84*Kt(i);
        
    % For Kt > 0.75, set the diffuse fraction
else
    DF(i) = 0.177;
end

billede

To this

if Kt(i)<=.35
    DF(i) = 1.0 - 0.249*Kt(i);
        
    % For Kt > 0.35 and Kt <= 0.75, set the diffuse fraction
elseif Kt(i)>.35 && Kt(i)<=.75
    DF(i) = 1.557 - 1.84*Kt(i);
        
    % For Kt > 0.75, set the diffuse fraction
else
    DF(i) = 0.177;
end

billede

To make it very clear DF(i) = 1.577 - 1.84*Kt(i); should be DF(i) = 1.557 - 1.84*Kt(i); and
elseif Kt(i)>.35 && Kt(i)<.75 should be elseif Kt(i)>.35 && Kt(i)<=.75

All according to Orgill, J. F. and Hollands K. G. T. "Correlation Equation for Hourly Diffuse Radiation on a Horizontal Surface" 1977.

Feature Request: soiling model

A soiling model was presented by Merissa Coello and Liza Boyle from Humboldt University at PVSC/WCPEC 2018. Requires time-series data of particulate matter (PM) concentrations for 10 micron and 2.5 micron particle diameters, and rainfall. Other parameters needed for variable deposition models. I have a copy of the model paper from Merissa and Liza, but can't find a reference to the proceedings. I have a model function developed and am putting final touches on the model. I'll PR when complete.

pvl_singleaxis produces NaN surface tilt angles near solar noon

pvl_singleaxis can produce NaN results for the surface tilt angle when the tilt is 0. Error stems from the following line:
SurfTilt = 90 - acosd(dividend./divisor);

When divisor is 0, the division by 0 produces NaN.

Possible fixes could be setting divisor to a very small number (eps) when it is 0, or simply setting SurfTilt to 0 any time that divisor is 0.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.