필터 지우기
필터 지우기

Inverse of atan2d

조회 수: 2 (최근 30일)
Kash Costello
Kash Costello 2019년 1월 9일
댓글: Star Strider 2019년 1월 9일
Hi,
Does anyone know how to do the "inverse" of this matlab command atan2d?
answer = atan2d(y,x);
I have the "answer" but I need to know what y and x are.
I am not sure what to do :(
Thanks a lot!
  댓글 수: 3
John D'Errico
John D'Errico 2019년 1월 9일
Sadly, I can't add a +1 to a comment. :)
You need to recognize that you can multiply x and y by any constant value, and the same answer will result. So both of these computations will produce the same value for Answer.
answer = atan2d(y,x);
answer = atan2d(2*y,2*x);
The same applies for any other constant multiplier. The conclusion is you cannot ever uniquely recover the original x and y. The best you can do is recover arbitrarily one of the many values for x and y that all lie at the same "angle".
Star showed you one way to do that.
Kash Costello
Kash Costello 2019년 1월 9일
Thank you so much for this. I really appreciate it!

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

채택된 답변

Star Strider
Star Strider 2019년 1월 9일
Try this:
y = 2;
x = 3;
answer = atan2d(y,x)
xa = cosd(answer)
ya = sind(answer)
test = atan2d(ya,xa)
  댓글 수: 2
Kash Costello
Kash Costello 2019년 1월 9일
Thank you so much!!!!!!! I appreciate it so much!!!!
Star Strider
Star Strider 2019년 1월 9일
As always, my pleasure!

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

추가 답변 (0개)

카테고리

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

태그

Community Treasure Hunt

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

Start Hunting!

Translated by