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(); }
public static List <IDFFile.BuildingOperation> GenerateRandomBuildingParameters(IDFFile.ProbabilisticBuildingOperation pOP, int numsamples, Random r) { List <IDFFile.BuildingOperation> bParameters = new List <IDFFile.BuildingOperation>(); for (int i = 0; i < numsamples; i++) { bParameters.Add(new IDFFile.BuildingOperation() { internalHeatGain = GetRandom(pOP.internalHeatGain, r), operatingHours = GetRandom(pOP.operatingHours, r), boilerEfficiency = GetRandom(pOP.boilerEfficiency, r), chillerCOP = GetRandom(pOP.chillerCOP, r) }); } return(bParameters); }