10.014 CTD
  • Overview
  • Schedule
  • Administrative
    • Accessing Rhino remotely
    • Rhino for Mac
  • ASSIGNMENTS
    • Dates and rubrics
    • Generative design
      • Generative design
    • Parametric design
      • Parametric design
    • Simulated design
      • Simulated design
      • Simulated design
  • SESSION 1B
    • Computer Aided Design
    • Ranges and expressions 1
      • Ranges and expressions 2
      • Ranges and expressions 3
      • Ranges and expressions 4
      • Ranges and expressions 5
      • Ranges and expressions 6
  • SESSION 2A
    • Visual programming 1
      • Visual programming 2
      • Visual programming 3
      • Visual programming 4
    • Associative modelling 1
      • Associative modelling 2
      • Associative modelling 3
  • SESSION 2B
    • Logical Patterns 1
      • Logical patterns 2
      • Logical patterns 3
  • SESSION 3A
    • Spatial geometry 1
      • Spatial geometry 2
      • Spatial geometry 3
      • Spatial geometry 4
      • Spatial geometry 5
      • Spatial geometry 6
      • Spatial geometry 7
    • Curve geometry 1
      • Curve geometry 2
      • Curve geometry 3
      • Curve geometry 4
  • SESSION 3B
    • Surface geometry
    • Parametric modelling 1
      • Parametric modelling 2
      • Parametric modelling 3
      • Parametric modelling 4
  • SESSION 4A
    • Information nesting 1
      • Information nesting 2
      • Information nesting 3
    • Data landscapes 1
      • Data landscapes 2
      • Data Landscapes 3
      • Data landscapes 4
  • SESSION 4B
    • Mesh geometry 1
      • Mesh geometry 2
      • Mesh geometry 3
  • SESSION 5A
    • Space and time 1
      • Space and time 2
    • Modelling entities 1
      • Modelling entities 2
      • Modelling entities 3
  • SESSION 5B
    • Multibody dynamics 1
      • Multibody dynamics 2
    • Material elasticity 1
      • Material elasticity 2
      • Material elasticity 3
  • SESSION 6A
    • Form-finding 1
      • Form-finding 2
      • Form-finding 3
      • Form-finding 4
  • SESSION 6B
    • AI Image generation 1
      • AI Image generation 2
      • AI Image generation 3
  • APPENDIX
    • Spirograph 1
      • Spirograph 2
    • Curves
    • Swarm Intelligence 1
      • Swarm Intelligence 2
    • Hybrid programming 1
      • Hybrid programming 2
Powered by GitBook
On this page
  1. SESSION 3A
  2. Spatial geometry 1

Spatial geometry 6

PreviousSpatial geometry 5NextSpatial geometry 7

Last updated 8 months ago

Basis

A plane is sometimes defined using only an origin point “O” and a normal vector n^\hat{n}n^ i.e. perpendicular direction to the plane. So how do we go about constructing a full basis [u^,v^,n^][\hat{u}, \hat{v}, \hat{n}][u^,v^,n^]i.e. two additional vectors square to the normal within the plane, given that we have only one vector to work with and the cross product requires two?

One way is to first choose a vector rrr at random. As long as it is not parallel to the normal we can repeat the double application of the cross product seen earlier and complete the basis. An alternative is to exchange the components of the normal and then perform the double cross product orthonormalization as seen below.

Practice

  • Use the “plane from normal” and the “deconstruct plane” components and observe how this process is performed by the CAD application.

  • Given two points of a line segment, construct a normal plane i.e. a plane whose normal is the direction of the line, situated at its mid-point.

Closest Point to Plane

Given a plane defined by three points “A”, “B", and “C”, we aim to determine the point of projection “Q” from an external to the plane point “P”. To approach this we need to use both the dot and cross products.

First we define the vectors u=A−Bu = A - Bu=A−B and v=C−Bv = C - Bv=C−B from the points of the triangle. We compute the plane’s normal n=u×vn = u \times vn=u×v using the cross product and normalize it. To find the point of projection from “P” onto the plane, we need to follow the normal direction n^\hat{n}n^. The question is by how much?

By projecting the auxiliary vector w=P−Bw = P - Bw=P−B onto the unit normal we have computed exactly this missing distance . Therefore all we need to do is to move back from the point “P” i.e. against the normal as much as “d”. Thus q=P−n^∗dq = P - \hat{n} * dq=P−n^∗d or by expanding q=P−n^∗(w⋅n^)q = P - \hat{n} * (w \cdot \hat{n})q=P−n^∗(w⋅n^) which reveals the projection “sandwich” product.

The approach is exactly the same as the one used earlier to project a point on a line. Here we just consider this line following the normal direction from one point on the plane! It was just a matter of looking at the plane from its side view.

Implicit Plane Equation

The term we used to compute the projection distance d=w⋅n^d = w · n̂d=w⋅n^ is very interesting if we expand it to d=(P−B)⋅n^d = ( P - B)\cdot \hat{n}d=(P−B)⋅n^. Now let’s substitute point “B” with “O” to signify the origin of the plane (P−O)⋅n^=d( P- O)\cdot \hat{n} = d(P−O)⋅n^=d. In fact it did not matter where point “B” was as long it was on the plane i.e. we could have used either “A”, “B” or “C”.

If the projected distance “d” is zero, i.e. (P−O)⋅n^=0( P - O)\cdot \hat{n} = 0(P−O)⋅n^=0 then the point “P” will be by definition on the plane. We have thus constructed an expression which captures all points on the plane or in other words the implicit form of a plane’s equation. This is quite elegant as opposed to the parametric form O+u∗s+v∗tO + u * s + v * tO+u∗s+v∗t we looked at earlier, but it does not tell us how to construct such points; only how to test if they are on the plane.

Half Spaces

In the same sense the sign of the computation d=w⋅n^d = w \cdot \hat{n}d=w⋅n^ tells us something about the directionality of the point in relation to the plane. If the sign is positive the point is in front of the plane, while negative values imply that the point is behind the plane. Forward by convention is assumed the direction pointed by the normal. In this sense a plane split space in two sub-spaces or half-spaces. This property is so useful that it is used from solving complex mathematical problems to rendering video game 3D graphics, because we don’t have to process anything behind the camera plane.

26KB
3A_4_ClosestPtplane.gh