I have the following information about the problem

  • Start point
  • Size (angle between 0 and 360)
  • End point (start point + size)
  • Tarjet angle.

The questions is how can determine if a tarjet angle is between start and end point


\begin{bmatrix} case&start&end&size\\ a&350&6&16\\ b&0&90&90\\ c&350&100&55\\ d&0&0&0\\ e&0&0&360\\ \end{bmatrix}

Case A

  • 270 outside
  • 351 inside

Case B

  • 360 outside
  • 45 inside

Case C

  • 102 outside
  • 1 inside

Case D

  • All are outside

Case D

  • All are inside



Compute the difference: "tarjet" angle $-$ start angle. If negative, repeatedly add 360° until the result is positive. Check if result is less than size: if so, it's inside.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.