This commit is contained in:
@@ -14,6 +14,20 @@ static Matrix LoadMatrixFromStdVect(const std::vector<std::vector<int>>& data) {
|
||||
return result;
|
||||
}
|
||||
|
||||
static std::string PrintVect(const Vect& vect) {
|
||||
std::string result = "Vect( ";
|
||||
for (std::size_t i = 0; i < vect.GetCardinal(); i++) {
|
||||
Matrix vector = vect.GetVector(i);
|
||||
result += " (";
|
||||
for (std::size_t j = 0; j < vect.GetDimension(); j++) {
|
||||
result += std::to_string(static_cast<int>((vector.at(j, 0)))) + ", ";
|
||||
}
|
||||
result += " ), ";
|
||||
}
|
||||
result += " )";
|
||||
return result;
|
||||
}
|
||||
|
||||
void PivotGui::Init() {}
|
||||
|
||||
void PivotGui::Render() {
|
||||
@@ -84,6 +98,10 @@ void PivotGui::Render() {
|
||||
|
||||
// rajouter le code pour la partie top right
|
||||
|
||||
static std::string result = "RIEN";
|
||||
|
||||
ImGui::Text(result.c_str());
|
||||
|
||||
ImGui::End(); // End fenetre top right
|
||||
|
||||
// Begin fenetre bas
|
||||
@@ -96,6 +114,8 @@ void PivotGui::Render() {
|
||||
if (ImGui::Button("Calcul noyau")) {
|
||||
// Code de calcul
|
||||
Vect kernel = solver.Kernel(LoadMatrixFromStdVect(matrixValues));
|
||||
|
||||
result = PrintVect(kernel);
|
||||
}
|
||||
ImGui::SameLine(); // Align buttons horizontally
|
||||
if (ImGui::Button("Calcul rang")) {
|
||||
|
||||
Reference in New Issue
Block a user