https://github.com/xtuc/matrixcpp
Basic Matrix Arithmetic in C++
https://github.com/xtuc/matrixcpp
Last synced: over 1 year ago
JSON representation
Basic Matrix Arithmetic in C++
- Host: GitHub
- URL: https://github.com/xtuc/matrixcpp
- Owner: xtuc
- Created: 2018-03-17T14:36:49.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-03-17T14:39:14.000Z (over 8 years ago)
- Last Synced: 2025-03-17T11:52:46.876Z (over 1 year ago)
- Language: C++
- Size: 1000 Bytes
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.cpp
Awesome Lists containing this project
README
#include
#include "./square-matrix.cpp"
int main() {
SquareMatric a {
{1,2,3},
{4,5,6},
};
SquareMatric b {
{1,2,3},
{4,5,6},
};
std::cout << a.toString() << std::endl;
std::cout << b.toString() << std::endl;
std::cout << "+" << std::endl;
std::cout << a.add(b).toString() << std::endl;
std::cout << a.toString() << std::endl;
std::cout << "* 5" << std::endl;
std::cout << a.scalarMul(5).toString() << std::endl;
return 0;
}