From e617ccd5f276b66a17df53dbfd1ca611764e3044 Mon Sep 17 00:00:00 2001 From: Mat Date: Mon, 19 May 2025 12:14:18 +0200 Subject: [PATCH] avancement problemeOuvert --- ...blemeOuvert.java => DijkstraProblemeOuvert.java} | 13 +++++++++++-- .../algorithm/shortestpath/LabelProblemeOuvert | 5 ++--- .../graphs/algorithm/shortestpath/LabelStar.java | 8 ++++---- 3 files changed, 17 insertions(+), 9 deletions(-) rename be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/{problemeOuvert.java => DijkstraProblemeOuvert.java} (95%) diff --git a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/problemeOuvert.java b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/DijkstraProblemeOuvert.java similarity index 95% rename from be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/problemeOuvert.java rename to be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/DijkstraProblemeOuvert.java index 752db69..0658cce 100644 --- a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/problemeOuvert.java +++ b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/DijkstraProblemeOuvert.java @@ -1,4 +1,4 @@ -// ce fichier n'est qu'en pseudo code + /* je considère que les 200km d'autonomie atteint (200km avec le 22 kWh - Q90 Renault ZOE chargé à 90%) @@ -95,5 +95,14 @@ Autres types de voies } return false; } + +normalement juste faut faire le verif de newcost avec l'autonomie + +avoir une option chemin impossible (trop éloigné des stations de recharges) + -*/ \ No newline at end of file +gérer le problème de la recharge, quand la faire ? + +*/ + + diff --git a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/LabelProblemeOuvert b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/LabelProblemeOuvert index 38fae38..3478429 100644 --- a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/LabelProblemeOuvert +++ b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/LabelProblemeOuvert @@ -1,8 +1,7 @@ -/* -public class LabelBattery extends Label { +/*public class LabelProblemeOuvert extends Label { private double autonomieRestante; - public LabelBattery(Node sommet, boolean marque, double cout, Arc pere, double autonomieRestante) { + public LabelProblemeOuvert(Node sommet, boolean marque, double cout, Arc pere, double autonomieRestante) { super(sommet, marque, cout, pere); this.autonomieRestante = autonomieRestante; } diff --git a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/LabelStar.java b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/LabelStar.java index 2107f1c..f5722ab 100644 --- a/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/LabelStar.java +++ b/be-graphes-algos/src/main/java/org/insa/graphs/algorithm/shortestpath/LabelStar.java @@ -1,4 +1,4 @@ -/* package org.insa.graphs.algorithm.shortestpath; +/*package org.insa.graphs.algorithm.shortestpath; import org.insa.graphs.model.Arc; import org.insa.graphs.model.Node; @@ -9,7 +9,7 @@ public class LabelStar extends Label { private Node destination; public LabelStar(Node sommetCourant, Boolean marque, double coutRealise, Arc pere,Node destination) { super(sommetCourant, marque, coutRealise, pere); - this.destination=destination; + this.destination=destination; //ou alors on le met juste en paramètre } @Override @@ -17,5 +17,5 @@ public class LabelStar extends Label { return (getCoutRealise()+distance(getSommetCourant().getPoint(),this.destination.getPoint())); } -} - */ \ No newline at end of file +}*/ + \ No newline at end of file