add stuff
Some checks failed
Linux arm64 / Build (push) Failing after 14m40s

This commit is contained in:
2024-02-13 11:38:52 +01:00
parent 820308b6c7
commit 23de24e9a1
5 changed files with 81 additions and 8 deletions

View File

@@ -1,5 +1,7 @@
#pragma once
#include <cmath>
#include <cstddef>
#include <string>
#include <vector>
@@ -15,6 +17,9 @@ class Matrix {
Matrix(std::size_t lignes, std::size_t colonnes, std::initializer_list<long double>&& initList);
~Matrix();
std::size_t GetRawCount() const;
std::size_t GetColumnCount() const;
Matrix operator*(const Matrix& other) const;
void GaussNonJordan(bool reduite);
@@ -31,12 +36,14 @@ class Matrix {
void Load(const std::string& filename);
void Transpose();
Matrix Transpose() const;
void Identity();
bool IsInversed() const;
Matrix SubMatrix(std::size_t origine_ligne, std::size_t origine_colonne, std::size_t ligne, std::size_t colonne) const;
bool operator==(const Matrix& other) const;
long double& operator[](std::size_t indice);
@@ -46,4 +53,7 @@ class Matrix {
long double at(std::size_t ligne, std::size_t colonne) const;
};
static bool IsEqualZero(long double var);
template <typename T>
bool IsEqualZero(T var) {
return std::abs(var) < std::pow(10, -5);
}