Linear Equations Solver  1.0
Using Gaussian elimination
Loading...
Searching...
No Matches
methods.h
Go to the documentation of this file.
1
12#ifndef METHODS_H
13#define METHODS_H
14
15#include <vector>
16#include <string>
17
26int GaussianElimination(std::vector<std::vector<double>> &m, int rows, int cols);
27
36int DetermineRank(const std::vector<std::vector<double>> &m, int rows, int cols);
37
48bool BackSubstitution(const std::vector<std::vector<double>> &m, int rows, int cols, std::vector<double> &solution);
49
58void ShowGeneralSolution(const std::vector<std::vector<double>> &m, int rows, int cols, int rank);
59
68std::vector<int> IdentifyPivots(const std::vector<std::vector<double>> &m, int rows, int cols);
69
70#endif // METHODS_H
std::vector< int > IdentifyPivots(const std::vector< std::vector< double > > &m, int rows, int cols)
Identifies the pivot columns in the matrix.
void ShowGeneralSolution(const std::vector< std::vector< double > > &m, int rows, int cols, int rank)
Displays the general solution for systems with infinitely many solutions.
bool BackSubstitution(const std::vector< std::vector< double > > &m, int rows, int cols, std::vector< double > &solution)
Performs back-substitution to find the solution vector.
int GaussianElimination(std::vector< std::vector< double > > &m, int rows, int cols)
Performs Gaussian elimination on the augmented matrix with partial pivoting.
int DetermineRank(const std::vector< std::vector< double > > &m, int rows, int cols)
Determines the rank of the coefficient matrix A (excluding augmented column).