vectors and points by Charawi Detphumi
Project description
cos202finalbycharawi is a Python library for dealing with points and vectors.
Installation
Use the package manager pip to install cos202finalbycharawi.
pip install cos202finalbycharawi
Usage
from cos202finalbycharawi import Vector
v1 = Vector(1,2)
v2 = Vector(3,4)
print(v1)
print(v2)
v1.euclideandistance(v2)
print(v1.lenght())
print(v1.unit())
print(v1.dotproduct(v2))
#print(v1.crossproduct(v2))
print(v1+v2)
print(v1-v2)
print(v1*v2)
print(v1/v2)
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file cos202finalbycharawi-0.0.3.tar.gz
.
File metadata
- Download URL: cos202finalbycharawi-0.0.3.tar.gz
- Upload date:
- Size: 3.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fd2673b7ebaf0b436861579a9d131c12a260fd61d2d64a70196f0a77e123e89d |
|
MD5 | d1cfecc6cc38db58aac36bb582cb82d3 |
|
BLAKE2b-256 | 242a16f76e0c7b8a331d0c145737000fbb287f3a4b907ab5b0d4ea1fffdd5393 |