how to find visual angle

조회 수: 9 (최근 30일)
smriti marathe
smriti marathe 2016년 5월 10일
편집: Roger Stafford 2016년 5월 10일
I have these three points(red dots) ,and I have to find angle, I am using polyfit function to calculate angle(finding slope first).
Now angle I am getting is near to 87 degrees, which is correct . But the thing is, I want to find the visual angle, which in this case will be near to 30 degrees. Any idea how to proceed with this? Thanks
  댓글 수: 3
smriti marathe
smriti marathe 2016년 5월 10일
I used polyfit function for a-b and b-c, results is, two slopes, from which I can find angle. (For polyfit function I used all the points between a-b and b-c).After getting slops, i used slope formula to find angle. Which gave 87. visual angle is angle which will be seen after plotting an image (meaning, in this image angle is seen near to 30 but when we do actual calculations using data points, it is near to 87, I think I will have to rescale the plot according to screen resolution, but have no idea how to proceed with it)
Walter Roberson
Walter Roberson 2016년 5월 10일
Which angle are you calculating as 87? (a-b) to (b-c) ? There is nothing that to me looks almost 90 degrees. But dot a- dot c- dot b might be maybe 115 degrees or so ?

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

답변 (1개)

Roger Stafford
Roger Stafford 2016년 5월 10일
편집: Roger Stafford 2016년 5월 10일
The true angle between ba and bc would be:
ang = atan2( abs((xa-xb)*(yc-yb)-(ya-yb)*(xc-xb)) , ...
(xa-xb)*(xc-xb)+(ya-yb)*(yc-yb) );
Your plot without an 'axis equal' restriction will distort these angles.

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by