j00ey Posted May 1, 2017 Share Posted May 1, 2017 I'm having a little difficulty with some matrix maths. I have 3 points P0, P1 and P2 [as in the attached drawing] and I need to find the point on the line between p0 and p1, such that the line from it to P2 is perpendicular to it. The way I tried is to first find the angle between P0-->P1 and P0-->P2 [acos of the dot product], then from there find the lengths a, o and a using trig, from there it's simple to find the correct position but somewhere or other I'm going wrong. I'll persevere but I wondered if there is some standard function to find that position, I imagine it must be a common thing to want to do... Thanks in advance Quote Link to comment Share on other sites More sharing options...
j00ey Posted May 1, 2017 Author Share Posted May 1, 2017 I figured it out, I had a plus instead of a minus... Quote Link to comment Share on other sites More sharing options...
Varishtraheja Posted July 28, 2017 Share Posted July 28, 2017 Hey is it possible for you to attach your hip file for me too see how you did it? Thank you. Regards Varisht Quote Link to comment Share on other sites More sharing options...
j00ey Posted July 31, 2017 Author Share Posted July 31, 2017 (edited) I don't have that particular file to hand any more but I made you a file to demonstrate an easier method. If you take the dot product of the normalized vector P0->P1 in the drawing above, and the UNnormalized vector P0->P2 that will give you the magnitude of the vector in the (normalized) direction P0->P1 that the perpendicular projection point is. That's probably a bit garbled but if you look at the file I hope it will make sense... projection.hip Edited July 31, 2017 by j00ey Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.