Metadata-Version: 2.1
Name: right-triangle
Version: 0.1.0
Summary: Simple Python package that can be used to do calculations with right-angled triangles
Home-page: https://github.com/lautnerb/right-triangle
Author: Balazs Lautner
Author-email: lautner.balazs@gmail.com
License: MIT
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Topic :: Scientific/Engineering :: Mathematics
Classifier: Typing :: Typed
Requires-Python: ~=3.7
Description-Content-Type: text/markdown

# Right Triangle

Simple Python package that can be used to do calculations with
right-angled triangles

## Installation

Use pip to install right-triangle.

```shell script
pip install right-triangle
```

## Usage

### The RightTriangle instance

A RightTriangle instance has 5 attributes:

1. a - the length of the first leg of the triangle
1. b - the length of the second leg of the triangle
1. c - the length of the hypotenuse of the triangle
1. a_angle - the angle opposed to leg _a_, measured in degrees
1. b_angle - the angle opposed to leg _b_, measured in degrees

You can instantiate a RightTriangle with the following information:

- The lengths of any two sides of the triangle
- One angle and the length of one side of the triangle

During the instantiation the other attributes are calculated and become
accessible.

### Example
```python
from right_triangle import RightTriangle

# Instantiate a RightTriangle with some of the attributes
rt = RightTriangle(a=3, b=4)

# The other attributes are accessible
print(rt.c)
print(rt.a_angle)
print(rt.b_angle)

# Instantiation with other attributes
rt2 = RightTriangle(c=10, a_angle=rt.a_angle)
print(rt2.a)
```


