フィルターのクリア

How to get the vector from a Point orthogonal to a Vector

2 ビュー (過去 30 日間)
Oliver Kumar
Oliver Kumar 2016 年 3 月 2 日
コメント済み: Oliver Kumar 2016 年 3 月 2 日
I have three points A, B, C Now I have built the vector A-B. What I need now, is a vector from C which is orthogonal to the vector A-B. The Vector (vecX) has to point to from C to the vector A-B. What I did this:
%vecX = abs(cross(A - B, C - A))./(A - B);
But I thiks this givs me onle the disctence from C to A-B and not the direction. Do you have any ideas how I can solve the problem? Thank you!

採用された回答

Torsten
Torsten 2016 年 3 月 2 日
x=(A-C)-dot(A-C,A-B)/dot(A-B,A-B)*(A-B)
Best wishes
Torsten.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLinear Algebra についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by