Skip to content
Snippets Groups Projects
Commit f1e279bd authored by juliano.souzaluz's avatar juliano.souzaluz
Browse files

push epsilon

parent d7055b26
Branches
No related tags found
No related merge requests found
......@@ -43,7 +43,7 @@ public class Main {
Scanner readFile = new Scanner(System.in);
System.out.println("Entrez le nom du fichier à tester, il doit se situer dans le dossier src.");
//String nameFile = readFile.nextLine();
String nameFile = "inputNonAdmissible.txt";
String nameFile = "network1.txt";
//String nameFile = "inputNonAdmissible.txt";
File f = new File("src/" + nameFile);
Scanner sc = new Scanner(f);
......
......@@ -104,7 +104,7 @@ public class Simplex {
if (solutionOptimale > 0 + EPSILON) {
System.out.println("Il n'y a pas de solutions admissibles pour ce problème.");
}
if (solutionOptimale == 0) {
if (Math.abs(solutionOptimale) < EPSILON || solutionOptimale == 0) {
// Il y a une solution optimale
// Il faut enlever les variables auxilaires
Matrix res = new Matrix(matEcart.getX(), matEcart.getY());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment