#pragma once #include "Matrix.h" // espace vectoriel class Vect { private: Matrix m_Data; public: /** * \brief Construit une base d'un espace vectoriel à partir des colonnes d'une matrice. * Ne prend pas en compte les colonnes de 0 * \param mat Une matrice échelonnée. */ Vect(const Matrix& mat); /** * \brief Affiche la base de l'espace vectoriel dans la console */ void Print() const; std::size_t GetDimension() const; std::size_t GetCardinal() const; Matrix GetLinearSystem() const; /** * \brief Concatène la base actuelle avec un nouveau vecteur * \param mat Une matrice colonne de taille GetDimension() */ void AddVector(const Matrix& mat); bool operator==(const Vect& other) const; bool operator!=(const Vect& other) const; private: void Simplify(); }; class VectAffine { private: Vect m_Base; Matrix m_Origin; public: VectAffine(const Vect& base, const Matrix& origin); void Print() const; const Vect& GetBase() const { return m_Base; } const Matrix& GetOrigin() const { return m_Origin; } };