MicroMatrix
This is an old unfinished project which I plan to work on soon.
MicroMatrix is a lightweight Python module which adds a generalized Matrix class, supporting many matrix operations with no external dependencies.
MicroMatrix Supports:
- Matrices of any size
- Complex Numbers
- Addition & Subtraction
- Multiplication & Division
- Integer Exponentiation
- Transposition
- Inverse & Determinant
- Assignment Operators
- And more!
Usage
Installation
Flask Sitemapper requires Python 3.10 or newer. The latest version can be installed from PyPi with pip as shown below.
pip install micromatrix
Now you can import the Matrix class to use in your code.
from micromatrix import Matrix
# Creating a 3x2 matrix
my_matrix = Matrix([1, 2, 3], [4, 5, 6])
Supported Operations
MicroMatrix supports many operations, including the standard Python mathematical operators and common matrix operations. These operations can be combined and used for complex calculations.
Keep in mind that some operations may not be possible depending on the dimension and elements of your matrices. In that case, you will see a ValueError with a description such as:
ValueError: Operation requires a square matrix
Reversible Operations
Matrix + int | float | complex | Matrix -> MatrixMatrix - int | float | complex | Matrix -> MatrixMatrix * int | float | complex | Matrix -> MatrixMatrix / int | float | complex | Matrix -> MatrixMatrix == Any -> bool
Non-Reversible Operations
Matrix ** int -> Matrix+ Matrix -> Matrix- Matrix -> Matrix~ Matrix -> Matrixabs(Matrix) -> Matrixlen(Matrix) -> intstr(Matrix) -> str
Properties
Matrix.identity -> MatrixMatrix.transpose -> MatrixMatrix.determinant -> int | float | complexMatrix.invert -> Matrix
Methods
Matrix.administer(func) -> Matrixapplies func to each value in Matrix
Metadata
Release files for micromatrix 1.0.0
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 | |
|---|---|---|---|---|
| micromatrix-1.0.0.tar.gz | 4.1 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| micromatrix-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 8.7 kB
Release files / micromatrix-1.0.0.tar.gz
| Download URL | micromatrix-1.0.0.tar.gz |
|---|---|
| Size | 4.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2316f8530be314aa8fb496ced5cee0a1a7a3c90b6bde8a5c454a92a47ebf9700
|
|
BLAKE2b-256 checksum How to use checksums |
7786fe46c4d8c9e84c5418623461c129980f2f6af60b5f542e8a4740e74ecc1f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.18
|
Release files / micromatrix-1.0.0-py3-none-any.whl
| Download URL | micromatrix-1.0.0-py3-none-any.whl |
|---|---|
| Size | 4.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7e2b9a44cac077e16df994f697f17a9ca32b41fb34eae952ffb707a60eb7b5ce
|
|
BLAKE2b-256 checksum How to use checksums |
c7e2b288cbfe9b352f5c23d582e650b4ae2af2086a628863c2f4ed91e2fd56b5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.9.18
|
Security for micromatrix 1.0.0
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.