Esempio n. 1
0
        private double extraterrestrialHorizRad(DateTime currentHr)
        {
            double lat    = this.synthYear.info.latitude;
            double lon    = this.synthYear.info.longitude;
            int    doy    = currentHr.DayOfYear;
            double etHrad = SolarRadiation.etRadHourly(doy, lat, lon, currentHr.ToLocalTime().Hour);

            return(Math.Round(etHrad, 2));
        }
Esempio n. 2
0
        private double directRadiation(DateTime currentHr)
        {
            double diffuse = diffuseRadiation(currentHr);
            double global  = Convert.ToDouble(getValue("RS", currentHr));
            double direct  = 0.0;

            if (global == 9999 || diffuse == 9999)
            {
                direct = 9999;
            }
            else
            {
                direct = SolarRadiation.getDirect(global, diffuse);
            }
            return(Math.Round(direct, 2));
        }
Esempio n. 3
0
        private double diffuseRadiation(DateTime currentHr)
        {
            double lat     = this.synthYear.info.latitude;
            double lon     = this.synthYear.info.longitude;
            int    doy     = currentHr.DayOfYear;
            double global  = Convert.ToDouble(getValue("RS", currentHr));
            double diffRad = 0.0;

            if (global == 9999)
            {
                diffRad = 9999;
            }
            else
            {
                diffRad = SolarRadiation.getDiffuse(global, doy, lat, lon, currentHr.ToLocalTime().Hour);
            }

            return(Math.Round(diffRad, 2));
        }