1 COMPUTATIONAL ARCHITECTURE Lorenzo Greco Relatori: Ing. Marco Giorgio Bevilacqua Prof. Ing. Pietro Croce Eng. Arthur Lebée Ing. Benedetta Biondi Computational architecture: development, optimization and design Case study of a glass and steel roof for the Scuola Normale Superiore’s courtyard
Transcript
1
2
3
4
5
6
7
8
9
10
11
private void RunScript(List x, double y, ref object output) {
List list = new List(); list = x; double diff = new double();
DataTree tree = new DataTree(); if (y.Equals(null) || y.Equals(0))
{ y = 0.05; } y = Math.Abs(y); int i = 0; while (list.Count > 1)
{ diff = list[0] - list[0] * y; GH_Path path = new GH_Path(i);
while (list[0] > diff) { tree.Add(list[0], path); if (list.Count
> 1) { list.RemoveAt(0); } else { list[0] = 0; } } i = i + 1; }
output = tree; } 12