public static List <IDFFile.WWR> GenerateRandomWWR(IDFFile.ProbabilisticWWR pWWR, int numsamples, Random r) { List <IDFFile.WWR> WWRs = new List <IDFFile.WWR>(); for (int i = 0; i < numsamples; i++) { WWRs.Add(new IDFFile.WWR() { east = GetRandom(pWWR.east, r), south = GetRandom(pWWR.south, r), north = GetRandom(pWWR.north, r), west = GetRandom(pWWR.west, r) }); } return(WWRs); }
private void button1_Click(object sender, EventArgs e) { epLoc = EPLoc.Text; weatherLoc = weLoc.Text; numFloors = (int)number.Value; numSamples = (int)sampleCount.Value; pWindowConstruction = new IDFFile.ProbabilisticWWR() { north = GetMinMax(wWR1_mean, wWR1_var), east = GetMinMax(wWR2_mean, wWR2_var), south = GetMinMax(wWR3_mean, wWR3_var), west = GetMinMax(wWR4_mean, wWR4_var) }; pBuildingConstruction = new IDFFile.ProbabilisticBuildingConstruction { uWall = GetMinMax(uWall_mean, uWall_var), uGFloor = GetMinMax(uGFloor_mean, uGFloor_var), uRoof = GetMinMax(uRoof_mean, uRoof_var), uIFloor = GetMinMax(uIFloor_Mean, uIFloor_var), uIWall = GetMinMax(uWall_mean, uWall_var), uWindow = GetMinMax(uWindow_mean, uWindow_var), gWindow = GetMinMax(gWindow_mean, gWindow_var), hcSlab = GetMinMax(HCFloor_mean, HCFloor_var), infiltration = GetMinMax(vent_mean, vent_var) }; pBuildingOperation = new IDFFile.ProbabilisticBuildingOperation() { boilerEfficiency = GetMinMax(bEffMean, bEffVar), chillerCOP = GetMinMax(CCOPMean, CCOPVar), operatingHours = GetMinMax(oPH_mean, oPH_var), internalHeatGain = GetMinMax(iHG_mean, iHG_var) }; this.Close(); }