Commit 7ca8da14 authored by Arťom Ňorba's avatar Arťom Ňorba
Browse files

beauty update

parent 399ef829
......@@ -14,10 +14,6 @@ int Matrix::getColumns() const {
return this->columns;
}
vector<vector<long double> > Matrix::getValues() {
return this->values;
}
void Matrix::setValuesBegin(vector<vector<long double> > put) {
this->values = put;
}
......@@ -67,12 +63,19 @@ void Matrix::addResult(int pos, long double res) {
void Matrix::printResults() {
for(int i=0; i < results.size();i++){
cout<< "x" << i+1 << " = " << results[i]<<"\n";
}
}
if (i == results.size()-1){
cout<< " x" << i+1 << " = " << results[i]<<" ";
}
else if (i == 0){
cout<< "| x" << i+1 << " = " << results[i]<<" |";
}
else {
cout<< " x" << i+1 << " = " << results[i]<<" |";
}
void Matrix::setResults(vector<long double> res) {
this->results = res;
}
cout << endl;
}
void Matrix::setResultArray() {
......
......@@ -24,12 +24,10 @@ public:
int getRows() const;
int getColumns() const;
vector<vector<long double> > getValues();
void setValuesBegin(vector<vector<long double> > put);
void changeValue(int row, int column, long double value);
void printMatrix();
vector<long double> getResultsArray();
void setResults(vector<long double> res);
void addResult(int pos, long double res);
void printResults();
void setResultArray();
......
......@@ -6,3 +6,15 @@
2 1558 1642120995506032530 CMakeFiles/semestralka_pjc.dir/main.cpp.o a8f001d087801410
0 177 1642121284384660820 build.ninja 5b41b40d76b7bfac
7 1534 1642118203295511455 CMakeFiles/semestralka_pjc.dir/Matrix.cpp.o f9806aba2a6f6dfd
5 1187 1642123223982171297 CMakeFiles/semestralka_pjc.dir/MatrixHelper.cpp.o d6e62ab562d627c0
5 1223 1642123224020652093 CMakeFiles/semestralka_pjc.dir/Matrix.cpp.o f9806aba2a6f6dfd
2 1502 1642123224302802709 CMakeFiles/semestralka_pjc.dir/main.cpp.o a8f001d087801410
1502 1619 1642123224425478846 semestralka_pjc e23c61409220f109
2 636 1642123281968856596 CMakeFiles/semestralka_pjc.dir/Matrix.cpp.o f9806aba2a6f6dfd
636 700 1642123282035430938 semestralka_pjc e23c61409220f109
1 593 1642123321085799367 CMakeFiles/semestralka_pjc.dir/Matrix.cpp.o f9806aba2a6f6dfd
593 650 1642123321147700342 semestralka_pjc e23c61409220f109
2 742 1642123440553772019 CMakeFiles/semestralka_pjc.dir/Matrix.cpp.o f9806aba2a6f6dfd
742 808 1642123440623660807 semestralka_pjc e23c61409220f109
2 613 1642123462787564438 CMakeFiles/semestralka_pjc.dir/Matrix.cpp.o f9806aba2a6f6dfd
614 663 1642123462839553160 semestralka_pjc e23c61409220f109
Start testing: Jan 14 01:48 CET
Start testing: Jan 14 02:25 CET
----------------------------------------------------------
End testing: Jan 14 01:48 CET
End testing: Jan 14 02:25 CET
......@@ -30,7 +30,6 @@ int main(int argc, char *argv[]){
bool solveFromFile = false;
//argument reader
if (argc > 1){
if (strcmp(argv[1],"--help") == 0){
cout << "\nThis app solves system of linear equations \n"
......@@ -53,6 +52,7 @@ int main(int argc, char *argv[]){
"After GEM it prints Matrix in equation shape again \n"
"Then it just prints the results \n";
return 0;
}
else if (strcmp(argv[1], "--file") == 0){
......@@ -104,7 +104,6 @@ int main(int argc, char *argv[]){
}
}
//end of argument reader
else if (!solveFromFile){
cout << "\nYou started this app so you now know how to use it \n"
"If not - stop app and pass argument --help to show guide \n";
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment