Grasshopper

algorithmic modeling for Rhino

Hello everyone,
How can I know if an angle is concave or convex regarding to the normals of the faces that form it?

Views: 6429

Attachments:

Replies to This Discussion

thanks taz for the reply and the info about sandbox. looks very usefull.

Actually I was looking before alot at your post here:

http://www.grasshopper3d.com/forum/topics/q-specific-pairings-from

and here:

http://www.grasshopper3d.com/forum/topics/finding-the-neighboring-c...

Your posts helped me a lot to get to the point where I'm now. But still I'm trying to fix the problem posted above. I need to know for every surface in a brep the angles to the adjecent surfaces. This works almost fine and the third vector w helped alot to decide which direction to measure. But due to the strange geometry of srf 1 the centerpoint lies very high and once the angle between uw and vw is >90° and on the other srf <90°. Therefore I got at this points both angles. 

I thought about to filter this points by measuring also the angles between u and v to a reverse vetor of w (lets call the reverse w'). If I got then two different values for uw and uw' I found the positions where the angles measuring is not correct.

Or is there a smarter way to do it?

Could I ask, if you could share your old grasshopper file you created here:

http://www.grasshopper3d.com/forum/topics/q-specific-pairings-from

Thanks!

Ok a very simple but very important question.
First.. Take the two normal vectors from the surface mesh whatever.
second... Make sure they have the length of 1. ( vector3d.unit).
third multiply the vectors.
if result is 1 threy are parralell and show in same direction. If they are -1 they are parrallel and show in oposite direction. If they are 0 they are orthogonal.

Hi Michael!

That's right! Pay attention on rounding errors e.g. for checking orthogonality use Abs(DotProduct) < Tolerance instead of DotProduct == 0.

For this problem we don't have to check vectors for parallelity. We use the scalar product to determine if an angle is sharp or obtuse (see Hannes' post). Instead of multiplying the normal vectors we have to multiply one normal vector with a vector that connects both faces.

Thats right.

RSS

About

Translate

Search

Photos

  • Add Photos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service