A Python program for analyzing and visualizing points on a coordinate plane, defining its position and angle
- ✅ Determine which quadrant a point belongs to
- ✅ Calculate distance from origin
- ✅ Calculate angle with X-axis
- ✅ Interactive coordinate input
- ✅ Automatic graph scaling
- ✅ Color-coded quadrants
- Python 3.10 or higher
- pip3
- Clone the repository:
git clone https://github.com/Sarmatae685/coordinate-analyzer.git
cd coordinate-analyzer- Create and activate virtual environment (recommended):
python3 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate- Install dependencies:
pip install -r requirements.txt- Run the program:
python3 coordinate_analyzer.pyTip
To disable venv:
deactivate==================================================
COORDINATE POINTS ANALYSIS
==================================================
Enter the coordinates of the points.
To complete the entry, leave the field blank and press Enter.
--- Point 1 ---
Enter X coordinate: 1
Enter Y coordinate: 1
✓ Added point: (1, 1)
--- Point 2 ---
Enter X coordinate: -1
Enter Y coordinate: -1
✓ Added point: (-1, -1)
--- Point 3 ---
Enter X coordinate: [Enter to finish]
...
==================================================
ANALYSIS RESULTS
==================================================
Point (1.0, 1.0) in I quadrant
Distance from the origin to the point: 1.41
The angle between the X-axis: 45.00°
--------------------------------------------------
Point (-1.0, -1.0) in III quadrant
Distance from the origin to the point: 1.41
The angle between the X-axis: -135.00°
--------------------------------------------------
...
Python 3.10+(uses pattern matching with match-case)matplotlib— for graph visualizationmath— for trigonometric calculations
MIT License - see LICENSE file for details
⭐ If you found this helpful, please star the repo!
