How to use the three points A1, A2, and B0 to calculate ∠A1B0A2?

조회 수: 1 (최근 30일)
Wesley
Wesley 2020년 12월 15일
댓글: James Tursa 2020년 12월 17일

채택된 답변

KSSV
KSSV 2020년 12월 15일
A1 = [171 422] ;
A2 = [415 413] ;
B0 = [277 386] ;
d1 = A1-B0 ;
d2 = A2-B0 ;
theta = atan((d2(2)-d1(2))/(d2(1)-d1(1)))
  댓글 수: 4
Wesley
Wesley 2020년 12월 17일
I'm very sorry. It was my mistake, your procedure is correct.
James Tursa
James Tursa 2020년 12월 17일
@KSSV: Your solution produces the angle that the A2-A1 vector makes with the x-axis. It does not involve B0 at all. This does not seem to answer the question.

댓글을 달려면 로그인하십시오.

추가 답변 (1개)

James Tursa
James Tursa 2020년 12월 17일
편집: James Tursa 2020년 12월 17일
A1 = [171 422] ;
A2 = [415 413] ;
B0 = [277 386] ;
d1 = A1-B0 ;
d2 = A2-B0 ;
theta = atan2( norm(cross([d1 0],[d2 0])), dot(d1,d2) );
See this link:

카테고리

Help CenterFile Exchange에서 Elementary Math에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by