Esempio n. 1
0
        //---------------------------------------------------------------------------
        void calcDirectRadns()
        {
            List <double> dirs = new List <double>();
            List <double> time = new List <double>();

            for (int i = 0; i < 24; i++)
            {
                time.Add(i);
                dirs.Add(Ios.value(i) - Idiffs.value(i));
            }
            Idirs = new TableFunction(time.ToArray(), dirs.ToArray(), false);
        }
Esempio n. 2
0
        //---------------------------------------------------------------------------
        private void convertRadiationsToPAR()
        {
            List <double> io_par    = new List <double>();
            List <double> idiff_par = new List <double>();
            List <double> idir_par  = new List <double>();
            List <double> time      = new List <double>();

            for (int i = 0; i < 24; i++)
            {
                time.Add(i);

                idiff_par.Add(Idiffs.value(i) * 0.5 * 4.25 * 1E6);
                idir_par.Add(Idirs.value(i) * 0.5 * 4.56 * 1E6);

                io_par.Add(idiff_par[i] + idir_par[i]);
            }
            Ios_PAR    = new TableFunction(time.ToArray(), io_par.ToArray(), false);
            Idiffs_PAR = new TableFunction(time.ToArray(), idiff_par.ToArray(), false);
            Idirs_PAR  = new TableFunction(time.ToArray(), idir_par.ToArray(), false);
        }