3.5. Curves and Surfaces
Curves and Surfaces in Grasshopper
Curves
NURBS (Non-Uniform Rational B-Splines) are mathematical representations that can accurately model any shape from a simple 2D Line
, Circle
, Arc
, or Box
to the most complex 3D free-form organic surface or solid.
Primitives
(Curve>Primitive)
Some primitive curves are: Circle, Ellipse, Arc or Line.
Curves have a number of basic properties that help us to define them, such as control points, start and end points or curve degree.
Splines
(Curve>Spline)
Spline are more sophisticated curves such as NURBS Curve, Interpolate Curve, Kinky Curve, PolyLine, PolyArc…
Nurbs curve
Are defined by a number to control points that influences the shape of the curve. Nurbs curves are defined with a degree which is an integer number in between 1 and 11.
You can make the curve periodic by changing the Boolean value from False to True.
Interpolate curve
Different than NURBS curves since the curve pass through each one of the control points. Here is also possible to define the tangent vector at start and end points of the curve by specifying a vector with a certain directionality.
Kinky curve
Similar to Interpolate curve. The difference is the angle threshold. If the angle in between one point to the next one is above the angle threshold, the curve will be drawnn with a kink.
PolyLine
Connects the points with straight lines.
Analyzing Curves
Grasshopper Tab: Curve > Analysis
Evaluate Curve
We can get specific properties of a curve as a given point.
NURBS curves have a local domain that goes from 0 to 1 (when the curve is reparameterize) or something else (when is not reparameterize).
Parameter t Determines the point on the curve to evaluate.
Curvature
Evaluates the curvature of a curve at a specified parameter.
Curvature Graph
Draws Rhino curvature graph. Variations on curvature over the domain of a curve.
Surfaces
NURBS Surfaces are very similar to NURBS Curves. The same algorithms are used to calculate Shape, Normals, Tangents, Curvatures and other properties, but there are some distinct differences.
In the case of NURBS surfaces, there are two directions implied in the geometry:
A rectangular grid of U
and V
curves.
Primitives
Grasshopper Tab: Surface>Primitive
Some primitive surfaces are: Cone, Cylinder, Sphere, Box, and Plane Surface
Freeform
Grasshopper Tab: Surface > Freeform
Some Freeform operation are: Loft, Extrude, Edge Surface and Sweep
Analyzing Surfaces
Analysis
Grasshopper Tab: Surface > Analysis
Tangent Plane
The Tangent Plane to a surface at a given point is the plane that touches the surface at that point.
Normal Vectors
The Z-direction of the tangent plane represents the Normal Direction of the surface at that point.
Evaluate Surface
Surface > Analysis > Evaluate Surface
Evaluating a surface at a parameter that is within the surface domain results in a point that is on the surface.
(see Surface Domain)
Surface Domain
A surface domain is defined as the range of (u,v)
parameters that evaluate (intersect) into a 3D Point on that surface.
Reparameterize
Reparameterize NURBS surfaces is often useful, so that the u
and v
domains both range from 0 to 1.
i.e. Reparameterization
On a curve:
On a surface: