algorithmic modeling for Rhino
Hi geniuses,
I'm trying to bisect angles of a polyline , but i encountered a problem shown below.
the yellow arrow rotations are good since they are < 180 degree, but the red arrow rotations are not what i want.
i'm successful at retrieving angles and rotating them to bisect, the problem is the "angle" component only give me the smaller angle (135 degree clockwise gonna be 45 degree anticlockwise) , and I actually want to use the greater angle to compute my rotations, since they are all clockwise. What can I do?
Tags:
Hi David, thank you very much for your reply!
I was trying to figure out how did your script work lol. Your script is so simple and more elegant compared to a script I made that does the same thing (in attachment). But I don't get how by averaging 2 vectors of different length you can create a new vector that bisects the angle of the old 2.
I measured every angle of the resulting vectors from your script and they really do bisect angles.
however shouldn't the graph above be what's happening when we average vectors? Am I missing something?
The vectors don't use amplitude, or rather have an amplitude of 1, so using the average will always yield equal angles. In your drawing you are giving the vectors a direction AND different amplitudes/lengths. If the length of a and b are the same, the angle is always halfed by the diagonal.
The amplitude is only later added for visualization purposes.
Hi Armin, yes that's what I was thinking too... Thanks for clarifying for me. David used a vector component directly linked to curves (lines), so if this is the case the lines' length are ignored?
btw this method is so clever.
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson. Powered by