Testing Waters
  • Scrapbook
  • Projects
    • Bamiyan Cultural Center
    • Bauhaus Museum
    • Better Hebbal
    • Bicycle Station
    • Cross Laminated Timber
    • Facade
    • Flowing Fabrication
    • Form from Images
    • Guggenheim Helsinki
    • National War Museum
    • National War Memorial
    • Indflorescence
    • Rectangular Compartments
    • Retail Space Layout
    • Noise Barrier : Swedevia Airport
    • Walden
    • Wilson Garden
  • Patterns
    • Area Graph
    • Array along Curve
    • Fibbonacci and Factorial
    • Gyroid
    • Hexagonal Pattern From Image
    • Hexagonal Grid
    • Koch Star
    • Mandelbrot Set
    • Pattern
    • Pattern
    • Pattern
    • Phyllotaxis
    • Random Strip Widths
    • Skewed Surface
    • Staggered Checkerboard
    • Triangle subdivision
    • Vector Field
    • Voronoi
    • Waves
    • Weave
  • Geometry
    • Boundary Curve
    • Bridging parallel curves
    • British Museum Great Court
    • Catenary
    • Delete Adjacent
    • Geodesic Sphere
    • Group Branching Curves
    • Group Circles
    • Group curves
    • K Mean
    • Nurbs Surface Irregular
    • Overlapping Petals
    • Pair Nearest
    • Parametric Shapes
    • Platonic Solids
    • Polyline to PolyArc
    • Roman Surface
    • Sagrada Familia Schools Roof
    • Sine Curve
    • Sine Ribbon
    • Spherical Transformations
    • Split Rectangle
    • Tangential Circle through Point
    • Travelling Salesman Problem
    • Unaligned Bounding Box
  • Lists
    • Alter by Boolean Sequence
    • Color by distance
    • Consecutive Points
    • Distancing
    • Divide Equally
    • Geometry from Image
    • Image based Point Density
    • Isovists
    • Reduce Color Palette
    • Replace Consecutive
    • Replace Multiple
    • Replace Recurring
    • Shadow Area
    • Shortest Path
    • Solar Analysis
    • Topography Analysis
  • Motion
    • Adjacency
    • Animate Sphere
    • Cellular Automation
    • Cloth
    • Hypotrochoid
    • Manakin
    • Rolling Spiral
    • Tan Curve
    • Trammel of Archemedes
    • Image to Integer
  • Articles
    • A Conceptual Approach to Integrating Computational Methods in Early Stage Design
    • Design Script's ambiguous and versatile Replication Guides <1>
    • Design Script's ambiguous and versatile Replication Guides <2>
Powered by GitBook
On this page
  1. Lists

Solar Analysis

PreviousShortest PathNextTopography Analysis

Last updated 4 years ago

cp=Point.Origin();
rd=3;
a1=Line.ByStartPointDirectionLength(Point.ByCoordinates(rd,0,0),Vector.ZAxis(),rd);
a2=Arc.ByCenterPointStartPointEndPoint(cp,Point.ByCoordinates(0,0,rd),Point.ByCoordinates(rd,0,0));
asrf=Surface.ByRevolve(a2,cp,Vector.ZAxis(),0,360);

//Solar Study
solarstudy=SolarAnalysis.Analyze(Weather.ByLatitudeLongitude
(12.9716,77.5946),asrf,[],
TimeStudy.FromStartTimeToEndTime(DSCore.DateTime.
FromString("April 30, 2016 9:00 AM"),DSCore.DateTime.
FromString("April 29, 2017 6:00 PM"),false),0.125,0);
cumulative=List.Flatten(solarstudy["Cumulative"],1);
average=List.Flatten(solarstudy["Average"],1);
peak=List.Flatten(solarstudy["Peak"],1);
calculationpoints=List.Flatten(solarstudy["Calculation Points"],1);

cumPt=List.SortByKey(Flatten(calculationpoints),Flatten(cumulative))["sorted list"];
avgPt=List.SortByKey(Flatten(calculationpoints),Flatten(average))["sorted list"];
pekPt=List.SortByKey(Flatten(calculationpoints),Flatten(peak))["sorted list"];

//Colors
Color.ByARGB(255,[0,0,255],[0,255,0],[255,0,0]);
0..2;
0..1..#List.Count(cumPt);

//Angles
cumPhi=(Vector.XAxis()).AngleWithVector(((List.LastItem(cumPt)).Project(Plane.XZ(),Vector.YAxis())).AsVector());
cumThe=(Vector.XAxis()).AngleWithVector(((List.LastItem(cumPt)).Project(Plane.XY(),Vector.ByCoordinates(0,0,-1))).AsVector());

avgPhi=(Vector.XAxis()).AngleWithVector(((List.LastItem(avgPt)).Project(Plane.XZ(),Vector.YAxis())).AsVector());
avgThe=(Vector.XAxis()).AngleWithVector(((List.LastItem(avgPt)).Project(Plane.XY(),Vector.ByCoordinates(0,0,-1))).AsVector());

pekPhi=(Vector.XAxis()).AngleWithVector(((List.LastItem(pekPt)).Project(Plane.XZ(),Vector.YAxis())).AsVector());
pekThe=(Vector.XAxis()).AngleWithVector(((List.LastItem(pekPt)).Project(Plane.XY(),Vector.ByCoordinates(0,0,-1))).AsVector());