Skip to main content

This is the simplest module for quick work with 2D vectors

Project description

Lines Methods Library

What is this?

The module allows you to work with vectors in 2D coordinates like [x1, y1, x2, y2].

Quick Guide

The module is based on the following structure:

vector = [1, 1, 5, 2]
length = get_length(coordinates=vector)

Using

Using the library is as simple and convenient as possible:

Let's import it first: First, import everything from the library (use the from ...import construct).

Examples of some operations:

Finding the intersection point of two vectors using the get_intersection() function:

intersection = get_intersection(line_a, line_b)

Finding the length of the vector using the get_length() function:

length = get_length(coordinates)

Finding the angle between two vectors using the get_angle_between_lines() function:

angle = get_angle_between_lines(line_a, line_b)

Stretch the line in both directions using the extend_line() function:

new_coordinates = extend_line(line, extend_length)    

Finding the midpoint using the get_medium_point_from_line() function:

medium_point = get_medium_point_from_line(line)

Developer

My github: Ugryumov_AV

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lines_methods-0.0.9.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lines_methods-0.0.9-py3-none-any.whl (4.0 kB view details)

Uploaded Python 3

File details

Details for the file lines_methods-0.0.9.tar.gz.

File metadata

  • Download URL: lines_methods-0.0.9.tar.gz
  • Upload date:
  • Size: 3.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.11.9

File hashes

Hashes for lines_methods-0.0.9.tar.gz
Algorithm Hash digest
SHA256 458a2e695cde7acb35a9ee244d79a59fec1de1c9db7f08f2afcb33fc6981ba2e
MD5 531e9c4b3b17a22fdf7796475b960d76
BLAKE2b-256 b32a46448010ac90abba72ac37d7e5bd33e5bfa0f1a9b055d60b2c174073bda7

See more details on using hashes here.

File details

Details for the file lines_methods-0.0.9-py3-none-any.whl.

File metadata

  • Download URL: lines_methods-0.0.9-py3-none-any.whl
  • Upload date:
  • Size: 4.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.11.9

File hashes

Hashes for lines_methods-0.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 5e079739c936809231b81196567f0a52d114dbc252ec4ae8f6b82ad4551a794c
MD5 800ca4de6db50180b65560298c960e87
BLAKE2b-256 fc00ef8b3e8793b4d539d08456ecfc5212f3ce256fad8f9723a3c4311ed6f132

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page