MATLAB: In which quadrant is a point

point allocationquadrant

Hi
I have a 'circle' with irregular perimeter. Somewhere within that circle is a point. The circle is divided into 4 quadrants by 2 lines 45 and 135 degrees to x- axis.I know the coordinates of the point. How can I find exactly in which quadrant it lies?
Thank you

Best Answer

The four quadrants are characterized by the following conditions (if the center of the circle is at (0,0)):
I quadrant: y<=x, y>=-x
II quadrant: y>=x y>=-x
III quadrant: y<=x, y>=-x
IV quadrant: y<=x, y<=-x
Use an if-statement to determine which quadrant the point under consideration is in.
Best wishes
Torsten.