linalg
Installation
Installation can be done through pip. You must have python version >= 3.6.
pip install linalg
Docs
Docs can be found at the readthedocs page
What is this?
NOT intended to be the best or fastest.
NOT intended to be production-grade (yet).
IS intended to be fully vanilla python3.
IS meant as an educational tool.
Technical details
This package uses black for formatting and semver for versioning.
Usage
This package provides the Matrix class and utility functions.
import linalg
from linalg import * # import the Matrix class and utility functions top-level
from linalg import Matrix # import the Matrix class
To create a matrix object, initialize it with a 2D list or use Matrix.zeroes() or Matrix.identity(). You can also use random_matrix().
mat = linalg.Matrix([[3, 4, 5], [2, 5, -1], [0, 2, 1]]) # 3x3 matrix
mat = linalg.as_matrix([[3, 4, 5], [2, 5, -1], [0, 2, 1]]) # 3x3 matrix, alternative notation
mat = linalg.zeroes(4, 2) # 4x2 zero matrix
mat = linalg.identity(4) # 4x4 identity matrix
mat = linalg.random_matrix((2, 3), (-10, 10)) # 2x3 matrix with elements within (-10, 10)
This package implements matrix multiplication with the python matrix multiplication operator @ (__matmul__). The matrix multiplication of two linalg.Matrix A, B is C = A @ B.
After that, you can use multiple functions to perform linear algebraic operations as explained in the above linked docs.
Todo
- Add other linear algebraic operations
- Implement vectors
- Add documentation
Metadata
Release files for linalg 1.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| linalg-1.0.4.tar.gz | 4.7 kB | Without provenance | Details for linalg-1.0.4.tar.gz |
Release files / linalg-1.0.4.tar.gz
| Download URL | linalg-1.0.4.tar.gz |
|---|---|
| Size | 4.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9a7c7e477e146b3d1d4651171346e4eda6f359b10a36ab1e176fa5aa9967305f
|
|
BLAKE2b-256 checksum How to use checksums |
1568842a0b2821c347941611ec6bdac84656d9ee8118509b27b9779c50500880
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.19.1 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.26.0 CPython/3.7.3
|
Security for linalg 1.0.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.