This repository was archived by the owner on Apr 12, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathProbabilisticBuildingGeometry.cs
More file actions
50 lines (47 loc) · 1.97 KB
/
ProbabilisticBuildingGeometry.cs
File metadata and controls
50 lines (47 loc) · 1.97 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
using System;
namespace IDFObjects
{
[Serializable]
public class ProbabilisticBuildingGeometry
{
public ProbabilityDistributionFunction
Length = new ProbabilityDistributionFunction("Length", "metres"),
Width = new ProbabilityDistributionFunction("Width", "metres"),
Height = new ProbabilityDistributionFunction("Height", "metres"),
rLenA = new ProbabilityDistributionFunction("rLenA",""),
rWidA = new ProbabilityDistributionFunction("rWidA",""),
BasementDepth = new ProbabilityDistributionFunction("Basement Depth", "metres"),
Orientation = new ProbabilityDistributionFunction("Orientation","degrees"),
FloorArea = new ProbabilityDistributionFunction("Floor Area", "sq. metres"),
ARatio = new ProbabilityDistributionFunction("Aspect Ratio",""),
Shape = new ProbabilityDistributionFunction("Shape",""),
NFloors = new ProbabilityDistributionFunction("Number of Floors","");
public ProbabilisticBuildingGeometry() { }
public BuildingGeometry GetAverage()
{
return new BuildingGeometry()
{
Length = Length.Mean,
Width = Width.Mean,
Height = Height.Mean,
rLenA = rLenA.Mean,
rWidA = rWidA.Mean,
BasementDepth = BasementDepth.Mean,
Orientation = (int)Orientation.Mean,
FloorArea = FloorArea.Mean,
ARatio = ARatio.Mean,
Shape = (int)Shape.Mean,
NFloors = (int)NFloors.Mean
};
}
public string Header(string sep)
{
return GetAverage().Header(sep);
}
public string ToString(string sep)
{
return string.Join(sep, Length, Width, Height, rLenA, rWidA, BasementDepth,
Orientation, FloorArea, ARatio, Shape, NFloors);
}
}
}