https://github.com/brianferri/fmm-c--
collection of fast multiplication algorithms and matrix operations. It is written in C++ and is header only. It is designed to be used in other projects and rewritten to fit the needs of the project
https://github.com/brianferri/fmm-c--
algorithms calculus cpp data-structures fast-multiplication library math mathematics matrix-calculations matrix-multiplication matrix-operations
Last synced: 3 months ago
JSON representation
collection of fast multiplication algorithms and matrix operations. It is written in C++ and is header only. It is designed to be used in other projects and rewritten to fit the needs of the project
- Host: GitHub
- URL: https://github.com/brianferri/fmm-c--
- Owner: brianferri
- Created: 2023-01-17T15:13:05.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2024-04-28T14:55:02.000Z (over 1 year ago)
- Last Synced: 2024-10-28T14:48:29.741Z (12 months ago)
- Topics: algorithms, calculus, cpp, data-structures, fast-multiplication, library, math, mathematics, matrix-calculations, matrix-multiplication, matrix-operations
- Language: C++
- Homepage:
- Size: 40 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# FMM Library
Fast multiplication and matrix library
## Info
This library is a collection of fast multiplication algorithms and matrix operations.
It is written in C++ and is header only. It is designed to be used in other projects
and rewritten to fit the needs of the project.The library is mostly written for educational purposes rather
than anything else. I highly recommend not using it in any production code.A test program is included. It can be compiled and executed using the provided makefile.
The test program is not meant to be used as a benchmark, but rather as a proof of concept.### Important Notes
The library only supports square matrices (for now).
Matrices are stored in a 1D array, which is then mapped to 2D indices using the given () operator.
(See the Matrix class for more information) Obviously, this can be changed to best fit your needs.There might (will) be bugs in the code and a lot of space for optimisation.
## Algorithms (fmm)
- Naive multiplication
- Strassen's multiplication
- Schonhage Laser Method multiplication (TODO)## Matrix Operations (SquareMatrix)
- Addition/Subtraction
- Multiplication by a scalar
- Transposition
- Determinant
- Gaussian Elimination (Row Echelon Form)
- Adjunct
- Rank
- split (Creates 4 submatrices from any square matrix)
- merge (Merges 4 submatrices into a single matrix)
- Reduction (remove \[i]\[j] row and column)
- Identity (n-th order)
- Inverse
- Kronecker Product
- Hadamard Product
- Some other stuff... (read the code)