From dbc092764e62aacfe4b3f0d03b55fa835e1490bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gonzalo=20Men=C3=A9ndez?= <gonchimenendez@gmail.com> Date: Wed, 5 Dec 2018 15:52:05 -0300 Subject: [PATCH] huh --- .../malva/rep/GA/newGA.req.cc | 20 +++++++++---------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/ProyectoFinal/AlgoritmoGenetico/malva/rep/GA/newGA.req.cc b/ProyectoFinal/AlgoritmoGenetico/malva/rep/GA/newGA.req.cc index e2a7a7f..556e92b 100644 --- a/ProyectoFinal/AlgoritmoGenetico/malva/rep/GA/newGA.req.cc +++ b/ProyectoFinal/AlgoritmoGenetico/malva/rep/GA/newGA.req.cc @@ -907,15 +907,8 @@ skeleton newGA } std::vector<std::vector<int>> _grupos = sol.pbm().datosColumnas(); - Rarray<Rarray<int>> tempVar = sol.array_var(); - for (int col = 0; col < tempVar.size(); col++) - { - for(int fil = 0; fil < tempVar[col].size(); fil++) - { - cout << tempVar[col][fil] << " "; - } - cout << endl; - } + //Rarray<Rarray<int>> tempVar = sol.array_var(); + bool didit = false; cout << "printed sol" << endl; @@ -939,6 +932,7 @@ skeleton newGA cout << "here?" << endl; if (rand01()<=probability[1]) { + didit = true; cout << "selectedForMutation" << endl; int selector = rand_int(0, 1); @@ -982,7 +976,7 @@ skeleton newGA j = j + _grupos[i][g]; } - cout << "forColumnasEnd" << endl; + cout << "forGruposEnd" << endl; } cout << "forColumnasEnd" << endl; @@ -1001,7 +995,11 @@ skeleton newGA } cout << endl; } - exit(EXIT_FAILURE); + if (didit) + { + exit(EXIT_FAILURE); + } + cout << "ESTOY SALIENDO DE MUTATION" << endl; } -- GitLab