From a0275cab5aea8accaa68c89341c44f15da867dc1 Mon Sep 17 00:00:00 2001 From: "Francois Berube\\frabe" Date: Mon, 16 Apr 2018 17:47:05 -0400 Subject: [PATCH] Modification de la demande de travail fonctionnelle. Correction de quelques bugs. --- Rapport_de_session/Figures/Résultats.xlsx | Bin 32828 -> 34255 bytes ...odelFullTimeEmployeesInitialSchedules.java | 4 +- ...odelPartTimeEmployeesInitialSchedules.java | 4 +- ...chedules.java => ParametersSchedules.java} | 38 ++++-- Travail_de_session/MainClass.java | 116 +++++++++--------- .../AbsencesVector.java | 12 +- .../BankModifiedSchedules.java} | 14 +-- .../ModifiedSchedulesArray.java} | 36 +++--- .../ParametersAbsencesSimulator.java | 6 +- .../ParametersVariableDemandSimulator.java | 8 ++ .../VariableDemandVector.java | 33 +++++ .../ScheduleUtil/EmployeeCostCalculator.java | 49 ++++---- .../FullTimeEmployeeScheduleArray.java | 4 +- .../PartTimeEmployeeScheduleArray.java | 4 +- .../ScheduleUtil/PrintSchedules.java | 12 +- .../ScheduleUtil/SchedulesArray.java | 26 ++-- .../BankRecoveredSchedules.java | 14 ++- .../RecoveredSchedulesArray.java | 72 +++++------ .../RecoveringActionFullTimeEmployee.java | 10 +- .../RecoveringActionPartTimeEmployee.java | 4 +- .../ValidationRecoveringAction.java | 32 ++--- .../ShowSolutionResultsFrame.form | 3 - .../ShowSolutionResultsFrame.java | 3 +- .../BankVariableDemandSchedules.java | 20 --- .../ParametersVariableDemandSimulator.java | 5 - .../VariableDemandSchedulesArray.java | 40 ------ .../VariableDemandVector.java | 21 ---- 27 files changed, 272 insertions(+), 318 deletions(-) rename Travail_de_session/InitialSchedules/{ParametersInitialSchedules.java => ParametersSchedules.java} (85%) rename Travail_de_session/{AbsenceSchedules => ModifiedSchedules}/AbsencesVector.java (74%) rename Travail_de_session/{AbsenceSchedules/BankAbsenceSchedules.java => ModifiedSchedules/BankModifiedSchedules.java} (51%) rename Travail_de_session/{AbsenceSchedules/AbsenceSchedulesArray.java => ModifiedSchedules/ModifiedSchedulesArray.java} (55%) rename Travail_de_session/{AbsenceSchedules => ModifiedSchedules}/ParametersAbsencesSimulator.java (68%) create mode 100644 Travail_de_session/ModifiedSchedules/ParametersVariableDemandSimulator.java create mode 100644 Travail_de_session/ModifiedSchedules/VariableDemandVector.java delete mode 100644 Travail_de_session/VariableDemandSchedules/BankVariableDemandSchedules.java delete mode 100644 Travail_de_session/VariableDemandSchedules/ParametersVariableDemandSimulator.java delete mode 100644 Travail_de_session/VariableDemandSchedules/VariableDemandSchedulesArray.java delete mode 100644 Travail_de_session/VariableDemandSchedules/VariableDemandVector.java diff --git a/Rapport_de_session/Figures/Résultats.xlsx b/Rapport_de_session/Figures/Résultats.xlsx index 32a27166164369af6c2e3c08c07b6f9b9bb21e11..d8e908b024289e8ceeb9739024f55d040776a3e6 100644 GIT binary patch delta 15670 zcmeIZWmG0x&nSp%BaOSeyEN|Z4vo9J%Y#GX@X*k>ySuwXV64#PR$oq4}|XJ*a( zowcTZ)XL7@JC&rWQb{Ul_XnGd1gq|b1p`_XYEcD2KLsb(b(B@zzG$UrUO3C5_;>z`QA@e(Oy-X=*I7fCbmK) z<=#sv>GQ3{C8qCMtoe5@)%2{(vlKfK6{7jzVAori2{j6~F9rfZwB#i`-ldin^mey#lMA|Q@eN(~PIW^e24>Vvm!=S{;66z5t=~UF&JI0kzBIyF6E`=YyxRffm=R_D4X|OCe?#j-xNeQ~{3wqwW{CvyToZK0sgre>UQ-Tl%N( zg*@+Kq?~O0XAFE2905I-o6%T)X%qb z`_V?oseuJiHMI!{2(f#$r+nfB>A3y~n?f8>m^c8GrE>AMY$Unp}qlYxuAK zhGh1;89X=QdR}+WHv@=Po2-e}V~a0j&MJuHa)Re;OL4szOWUkOAlJ|%LPw$S=!IP? zHO(}|wor&ioKvOmt|?!8;&1&HnKEZlB{f~4)n8g{%P2n=c5HvfK-@E%ee*_ckx2Zpn zqOk|j84jgCn{6GL8MU>t!qWNfEG6-~8zCoU^-Do$;qV-PIy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3#cLI4K@0|V$66AoxI0G05c!iK27i@?(Vrv_$K{&$q}KhQ)HAl)Ed2rXHVkOCH{`Y-Q)eDeRs-c|Y6j2A)75bZi3;$UHja6^z` zFg4-7+u#4MI&DUO)xiR_2Qx$5n}AOKiX2#iltU>%iXm7aln{J~UF&~ei$kyo|FcYj zfua6K!@p14wxFdD0f<3+5Jo83zhdi7f5mwJoq(XYP;7`57f@*^IgGLUKXU&MT_qcF diff --git a/Travail_de_session/InitialSchedules/ModelFullTimeEmployeesInitialSchedules.java b/Travail_de_session/InitialSchedules/ModelFullTimeEmployeesInitialSchedules.java index 004a8f6..97532cf 100644 --- a/Travail_de_session/InitialSchedules/ModelFullTimeEmployeesInitialSchedules.java +++ b/Travail_de_session/InitialSchedules/ModelFullTimeEmployeesInitialSchedules.java @@ -14,7 +14,7 @@ import org.chocosolver.solver.variables.IntVar; * @author frabe */ public class ModelFullTimeEmployeesInitialSchedules { - public final ParametersInitialSchedules myScheduleParameters; + public final ParametersSchedules myScheduleParameters; public final int numberOfFullTimeEmployees; @@ -25,7 +25,7 @@ public class ModelFullTimeEmployeesInitialSchedules { public final Model chocoModelInitialSchedules; - public ModelFullTimeEmployeesInitialSchedules(ParametersInitialSchedules myScheduleParameters, int numberOfFullTimeEmployees) { + public ModelFullTimeEmployeesInitialSchedules(ParametersSchedules myScheduleParameters, int numberOfFullTimeEmployees) { this.myScheduleParameters = myScheduleParameters; this.chocoModelInitialSchedules = new Model("Model Full Time Employees Initial Schedules"); diff --git a/Travail_de_session/InitialSchedules/ModelPartTimeEmployeesInitialSchedules.java b/Travail_de_session/InitialSchedules/ModelPartTimeEmployeesInitialSchedules.java index 8d5713f..f48329f 100644 --- a/Travail_de_session/InitialSchedules/ModelPartTimeEmployeesInitialSchedules.java +++ b/Travail_de_session/InitialSchedules/ModelPartTimeEmployeesInitialSchedules.java @@ -6,7 +6,7 @@ import org.chocosolver.solver.variables.IntVar; public class ModelPartTimeEmployeesInitialSchedules { - public final ParametersInitialSchedules myScheduleParameters; + public final ParametersSchedules myScheduleParameters; public final int maxPartTimeEmployee; @@ -17,7 +17,7 @@ public class ModelPartTimeEmployeesInitialSchedules { public final Model chocoModelInitialSchedules; - public ModelPartTimeEmployeesInitialSchedules(ParametersInitialSchedules myScheduleParameters) { + public ModelPartTimeEmployeesInitialSchedules(ParametersSchedules myScheduleParameters) { this.myScheduleParameters = myScheduleParameters; diff --git a/Travail_de_session/InitialSchedules/ParametersInitialSchedules.java b/Travail_de_session/InitialSchedules/ParametersSchedules.java similarity index 85% rename from Travail_de_session/InitialSchedules/ParametersInitialSchedules.java rename to Travail_de_session/InitialSchedules/ParametersSchedules.java index 704753f..fe819c7 100644 --- a/Travail_de_session/InitialSchedules/ParametersInitialSchedules.java +++ b/Travail_de_session/InitialSchedules/ParametersSchedules.java @@ -3,7 +3,7 @@ package InitialSchedules; import ScheduleUtil.FullTimeEmployeeScheduleArray; import org.chocosolver.solver.constraints.extension.Tuples; -public class ParametersInitialSchedules { +public class ParametersSchedules { //General Parameters private final int shiftWorkPerDay = 3; @@ -15,10 +15,10 @@ public class ParametersInitialSchedules { //PartTime Employees Parameters private final int fixedCostOfPartTimeEmployeesPerSchedule = 50; - private final int regularHourlyRateOfPartTimeEmployees = 12; - private final int overtimeHourlyRateOfPartTimeEmployees = 17; + private final int regularHourlyRateOfPartTimeEmployees = 11; + private final int overtimeHourlyRateOfPartTimeEmployees = 16; private final int minWorkingHoursOfPartTimeEmployeesPerSchedule = 32; - private final int maxWorkingHoursOfPartTimeEmployeesPerSchedule = 64; + private final int maxWorkingHoursOfPartTimeEmployeesPerSchedule = 80; private final int maxConsecutiveWorkingHoursOfPartTimeEmployeesPerShiftWork = 12; private final int minConsecutiveNonWorkingHoursBetweenShiftWorksOfPartTimeEmployees = 12; @@ -32,21 +32,27 @@ public class ParametersInitialSchedules { private final int minConsecutiveNonWorkingHoursBetweenShiftWorksOfFullTimeEmployees = 12; private int[] requiredWorkforce; - int NbFullTimeSolutions; - int NbPartTimeSolutions; Tuples enumerationWorkPeriodsSchedulesOfFullTimeEmployees; Tuples enumerationWorkPeriodsSchedulesOfPartTimeEmployees; - private Tuples ValidPartTimeEmployeeShiftTuples; - public ParametersInitialSchedules() { + public ParametersSchedules(ParametersSchedules myScheduleParameters) { + + this.requiredWorkforce = new int[this.getWorkPeriodsPerSchedule()]; + for (int workPeriod = 0 ; workPeriod < getWorkPeriodsPerSchedule() ; workPeriod++) { + this.requiredWorkforce[workPeriod] = myScheduleParameters.getRequiredWorkForce(workPeriod); + } + + this.enumerationWorkPeriodsSchedulesOfFullTimeEmployees = myScheduleParameters.enumerationWorkPeriodsSchedulesOfFullTimeEmployees; + this.enumerationWorkPeriodsSchedulesOfPartTimeEmployees = myScheduleParameters.enumerationWorkPeriodsSchedulesOfPartTimeEmployees; + } + + public ParametersSchedules() { this.setRequiredWorkforce(); this.enumerationWorkPeriodsSchedulesOfFullTimeEmployees = GenerationPossibleEmployeeSchedules.setWorkPeriodsSchedulesOfFullTimeEmployees( shiftWorkPerDay, getWorkPeriodsPerSchedule(), getWorkPeriodPerDay(), daysPerSchedule); this.enumerationWorkPeriodsSchedulesOfPartTimeEmployees = GenerationPossibleEmployeeSchedules.setWorkPeriodsSchedulesOfPartTimeEmployees( getWorkPeriodsPerSchedule(), getWorkPeriodPerDay(), daysPerSchedule); - this.ValidPartTimeEmployeeShiftTuples = new ValidPartTimeEmployeeShift().makeTuples(); - } private void setRequiredWorkforce() { @@ -56,6 +62,15 @@ public class ParametersInitialSchedules { for (int day = 0; day < this.daysPerSchedule; day++) { System.arraycopy(dailyRequiredWorkforce, 0, this.requiredWorkforce, day * this.getWorkPeriodPerDay(), this.getWorkPeriodPerDay()); } + + } + + public void modifyRequiredWorkForce(int[] variableDemandVector) { + + for (int workPeriod = 0 ; workPeriod < this.getWorkPeriodsPerSchedule() ; workPeriod++) { + this.requiredWorkforce[workPeriod] += variableDemandVector[workPeriod]; + } + } public void adjustRequiredWorkforce( FullTimeEmployeeScheduleArray fullTimeSchedule) { @@ -165,7 +180,4 @@ public class ParametersInitialSchedules { return this.workingHoursOfFullTimeEmployeesPerSchedule / this.hoursPerWorkPeriod; } - // A implementer plus tard si l'on veut travailler avec des fichiers texte - public ParametersInitialSchedules(String fileName) {} - } diff --git a/Travail_de_session/MainClass.java b/Travail_de_session/MainClass.java index b4e0a63..f16f703 100644 --- a/Travail_de_session/MainClass.java +++ b/Travail_de_session/MainClass.java @@ -1,10 +1,7 @@ -import AbsenceSchedules.*; import InitialSchedules.*; import ScheduleUtil.*; import SchedulesRecovery.*; -import VariableDemandSchedules.BankVariableDemandSchedules; -import VariableDemandSchedules.ParametersVariableDemandSimulator; -import VariableDemandSchedules.VariableDemandSchedulesArray; +import ModifiedSchedules.*; import jdistlib.rng.MersenneTwister; import jdistlib.rng.RandomEngine; import org.chocosolver.solver.Solution; @@ -18,37 +15,37 @@ public class MainClass { public static void main(String[] args) { + ParametersSchedules myScheduleParameters = new InitialSchedules.ParametersSchedules(); // for (int i = 0 ; i <= 10 ; i++) { -// ParametersAbsencesSimulator.probPresence = (double) i * 0.01 + 0.9; // Pour de 0.9 a 1.0 par increment de 0.01 +// ParametersAbsencesSimulator.probPresence = 1 - (double) i * 0.01; // Pour de 0.90 a 1.0 par increment de 0.01 -// System.out.print("Probabilité absence = " + (1-ParametersAbsencesSimulator.probPresence)); +// for (int j = 0 ; j <= 10 ; j++) { + +// ParametersVariableDemandSimulator.probIncreasedDemandbyOne = (double) j * 0.1; // Pour de 0 a 1 par increment de 0.1 +// ParametersVariableDemandSimulator.probIncreasedDemandbyTwo = ParametersVariableDemandSimulator.probIncreasedDemandbyOne/5; // Pour de 0 a 0.25 par increment de 0.05 +// ParametersVariableDemandSimulator.probIncreasedDemandbyThree = ParametersVariableDemandSimulator.probIncreasedDemandbyOne/25; // Pour de 0 a 0.25 par increment de 0.05 + List initialSchedulesArrayList = generateInitialSchedules(myScheduleParameters); - // Placer une sous-boucle pour faire varier la probabilite d'augmentation de la demande. - - List initialSchedulesArrayList = generateInitialSchedules(); + List listBankModifiedSchedules = GenerateModifiedSchedules(initialSchedulesArrayList, myScheduleParameters); - //List listBankVariableDemandSchedules = GenerateModifiedDemandSchedules(initialSchedulesArrayList); + List bankRecoveredSchedulesOrderedByMeanCost = GenerateOptimalRecoveredSchedules(listBankModifiedSchedules); - List listBankAbsenceSchedules = GenerateAbsencesSchedules(initialSchedulesArrayList); - - List bankRecoveredSchedulesOrderedByMeanCost = GenerateOptimalRecoveredSchedules(listBankAbsenceSchedules); - - @SuppressWarnings("unused") SchedulesWindows.ShowSolutionResultsFrame initialSchedulesViewer = new SchedulesWindows.ShowSolutionResultsFrame(bankRecoveredSchedulesOrderedByMeanCost); + SchedulesWindows.ShowSolutionResultsFrame initialSchedulesViewer = new SchedulesWindows.ShowSolutionResultsFrame(bankRecoveredSchedulesOrderedByMeanCost); // int optimalFullTimeEmployee = bankRecoveredSchedulesOrderedByMeanCost.get(0).initialSchedulesArray.getNumberFullTimeEmployee(); -// System.out.println(optimalFullTimeEmployee + " "); +// System.out.print(optimalFullTimeEmployee + " "); +// } +// System.out.println(" "); // } } @SuppressWarnings("unused") - private static List generateInitialSchedules() { + private static List generateInitialSchedules(ParametersSchedules myScheduleParameters) { // Trouver les horaires des employes a temps plein possibles pour different ratio templein/temps partiel List initialSchedulesArrayList = new ArrayList<>(); - InitialSchedules.ParametersInitialSchedules myScheduleParameters = new InitialSchedules.ParametersInitialSchedules(); - int minFullTimeEmployee = 2; //La solution avec 1 employes est trop lente int maxFullTimeEmployee = 9; //9 est le max d'employes a temps plein pour la presente requiredWorkforce @@ -69,7 +66,7 @@ public class MainClass { for (Solution CurrentFullTimeEmployeesSolution : myInitialFullTimeEmployeesSchedulesSolutions) { FullTimeEmployeeScheduleArray fullTimeSchedulesArray = new FullTimeEmployeeScheduleArray(myModelFullTimeEmployeesInitialSchedules, CurrentFullTimeEmployeesSolution); - InitialSchedules.ParametersInitialSchedules myPartTimeScheduleParameters = new InitialSchedules.ParametersInitialSchedules(); + InitialSchedules.ParametersSchedules myPartTimeScheduleParameters = new InitialSchedules.ParametersSchedules(); myPartTimeScheduleParameters.adjustRequiredWorkforce(fullTimeSchedulesArray); InitialSchedules.ModelPartTimeEmployeesInitialSchedules myModelPartTimeEmployeesInitialSchedules @@ -81,7 +78,7 @@ public class MainClass { for (Solution CurrentPartTimeEmployeesSolution : myInitialPartTimeEmployeesSchedulesSolutions) { PartTimeEmployeeScheduleArray partTimeSchedulesArray = new PartTimeEmployeeScheduleArray(myModelPartTimeEmployeesInitialSchedules, CurrentPartTimeEmployeesSolution); - SchedulesArray initialSchedulesArray = new SchedulesArray(fullTimeSchedulesArray, partTimeSchedulesArray, simulationNumber); + SchedulesArray initialSchedulesArray = new SchedulesArray(fullTimeSchedulesArray, partTimeSchedulesArray, myScheduleParameters, simulationNumber); initialSchedulesArrayList.add(initialSchedulesArray); simulationNumber++; } @@ -97,65 +94,62 @@ public class MainClass { } - private static List GenerateModifiedDemandSchedules(List initialSchedulesArrayList) { - RandomEngine r = new MersenneTwister(987654321); - List listBankVariableDemandSchedules = new ArrayList<>(); - List listVariableDemandSchedules = new ArrayList<>(); // to be removed - for (SchedulesArray initialSchedule : initialSchedulesArrayList) { - BankVariableDemandSchedules bankVariableDemandSimulations = new BankVariableDemandSchedules(initialSchedule); - for (int simNum = 0; simNum < ParametersVariableDemandSimulator.numberVariableDemandSimulation ; simNum++){ - VariableDemandSchedulesArray variableDemandSchedule = new VariableDemandSchedulesArray(initialSchedule,r); - listVariableDemandSchedules.add(variableDemandSchedule); - bankVariableDemandSimulations.addVariableDemandSchedules(variableDemandSchedule); - } - listBankVariableDemandSchedules.add(bankVariableDemandSimulations); - } - // Pour afficher les horaires avec demande modifiée - SchedulesWindows.ShowSchedulesFrame variableDemandSchedulesViewer = new SchedulesWindows.ShowSchedulesFrame(listVariableDemandSchedules,"Variable Demand Schedules"); - - return listBankVariableDemandSchedules; - } - - private static List GenerateAbsencesSchedules(List initialSchedulesArrayList) { + private static List GenerateModifiedSchedules(List initialSchedulesArrayList, ParametersSchedules myScheduleParameters) { - RandomEngine r = new MersenneTwister(123456789); - List listBankAbsenceSchedules = new ArrayList<>(); - List listAbsenceSchedules = new ArrayList<>(); // to be removed - for (SchedulesArray initialSchedule : initialSchedulesArrayList) { - BankAbsenceSchedules bankAbsenceSimulations = new BankAbsenceSchedules(initialSchedule); - for (int simNum = 0 ; simNum < ParametersAbsencesSimulator.numberAbsenceSimulations ; simNum++) { - AbsenceSchedulesArray absenceSchedule = new AbsenceSchedulesArray(initialSchedule, r); - listAbsenceSchedules.add(absenceSchedule); // to be removed - bankAbsenceSimulations.addAbsenceSchedules(absenceSchedule); - } - listBankAbsenceSchedules.add(bankAbsenceSimulations); + RandomEngine randAbsence = new MersenneTwister(123456789); + + // generation de nouveaux vecteurs de demande de travail + RandomEngine randVariableDemand = new MersenneTwister(987654321); + int[][] matrixVariableDemandVector = new int[ParametersVariableDemandSimulator.numberVariableDemandSimulations][myScheduleParameters.getWorkPeriodsPerSchedule()]; + for (int varDemSimNum = 0 ; varDemSimNum < ParametersVariableDemandSimulator.numberVariableDemandSimulations ; varDemSimNum++) { + matrixVariableDemandVector[varDemSimNum] = new ModifiedSchedules.VariableDemandVector(myScheduleParameters.getWorkPeriodsPerSchedule(), randVariableDemand).getVariableDemandVector(); } - // Pour afficher les horaires avec absence - SchedulesWindows.ShowSchedulesFrame absenceSchedulesViewer = new SchedulesWindows.ShowSchedulesFrame(listAbsenceSchedules, "Absence Schedules"); // to be removed + List listBankModifiedSchedules = new ArrayList<>(); + List listModifiedSchedules = new ArrayList<>(); // to be removed + for (SchedulesArray initialSchedule : initialSchedulesArrayList) { + BankModifiedSchedules bankModificationSimulations = new BankModifiedSchedules(initialSchedule); + for (int varDemSimNum = 0 ; varDemSimNum < ParametersVariableDemandSimulator.numberVariableDemandSimulations ; varDemSimNum++) { + int[] variableDemandVector = matrixVariableDemandVector[varDemSimNum]; + ParametersSchedules myModifiedScheduleParameters = new InitialSchedules.ParametersSchedules(myScheduleParameters); + myModifiedScheduleParameters.modifyRequiredWorkForce(variableDemandVector); + for (int absSimNum = 0 ; absSimNum < ParametersAbsencesSimulator.numberAbsenceSimulations ; absSimNum++) { + ModifiedSchedulesArray modifiedSchedule = new ModifiedSchedulesArray(initialSchedule, myModifiedScheduleParameters, randAbsence); + listModifiedSchedules.add(modifiedSchedule); // to be removed + bankModificationSimulations.addModifiedSchedules(modifiedSchedule); + } + } + listBankModifiedSchedules.add(bankModificationSimulations); + } - return listBankAbsenceSchedules; + // Pour afficher les horaires modifies + SchedulesWindows.ShowSchedulesFrame modifiedSchedulesViewer = new SchedulesWindows.ShowSchedulesFrame(listModifiedSchedules, "Modified Schedules"); // to be removed + + return listBankModifiedSchedules; } - private static List GenerateOptimalRecoveredSchedules(List listBankAbsenceSchedules) { + private static List GenerateOptimalRecoveredSchedules(List listBankModifiedSchedules) { BankRecoveredSchedulesComparator meanCostComparator = new BankRecoveredSchedulesComparator(); PriorityQueue< BankRecoveredSchedules > bankRecoveredSchedulesOrderedByMeanCost = new PriorityQueue<>(meanCostComparator); List listRecoveredSchedules = new ArrayList<>(); // to be removed - for (BankAbsenceSchedules bankAbsenceSchedule : listBankAbsenceSchedules) { - SchedulesArray initialSchedulesArray = bankAbsenceSchedule.initialSchedulesArray; - BankRecoveredSchedules bankRecoveredSimulations = new BankRecoveredSchedules(initialSchedulesArray, bankAbsenceSchedule.bankAbsenceSimulation); + for (BankModifiedSchedules bankModifiedSchedule : listBankModifiedSchedules) { + SchedulesArray initialSchedulesArray = bankModifiedSchedule.initialSchedulesArray; + BankRecoveredSchedules bankRecoveredSimulations = new BankRecoveredSchedules(initialSchedulesArray, bankModifiedSchedule.bankModifiedSimulation); int totalCostRecoveredSimulations = 0; - for (AbsenceSchedulesArray absenceSchedule : bankAbsenceSchedule.bankAbsenceSimulation) { - RecoveredSchedulesArray recoveredSchedule = new RecoveredSchedulesArray(absenceSchedule); + for (ModifiedSchedulesArray modifiedSchedule : bankModifiedSchedule.bankModifiedSimulation) { + RecoveredSchedulesArray recoveredSchedule = new RecoveredSchedulesArray(modifiedSchedule); listRecoveredSchedules.add(recoveredSchedule); // to be removed bankRecoveredSimulations.addRecoveredSchedules(recoveredSchedule); if (recoveredSchedule.totalScheduleCost != Integer.MAX_VALUE){ totalCostRecoveredSimulations += recoveredSchedule.totalScheduleCost; + } else { + bankRecoveredSimulations.numberUnResolvedSimulations += 1; } } bankRecoveredSimulations.meanCostRecoveredSimulations = totalCostRecoveredSimulations / bankRecoveredSimulations.bankRecoveredSimulation.size(); +// System.out.print(bankRecoveredSimulations.meanCostRecoveredSimulations + " "); bankRecoveredSchedulesOrderedByMeanCost.add(bankRecoveredSimulations); } // Pour afficher les horaires de recouvrement diff --git a/Travail_de_session/AbsenceSchedules/AbsencesVector.java b/Travail_de_session/ModifiedSchedules/AbsencesVector.java similarity index 74% rename from Travail_de_session/AbsenceSchedules/AbsencesVector.java rename to Travail_de_session/ModifiedSchedules/AbsencesVector.java index 9a29ffb..02389af 100644 --- a/Travail_de_session/AbsenceSchedules/AbsencesVector.java +++ b/Travail_de_session/ModifiedSchedules/AbsencesVector.java @@ -1,19 +1,19 @@ -package AbsenceSchedules; +package ModifiedSchedules; import jdistlib.Binomial; import jdistlib.rng.RandomEngine; -class AbsencesVector { - private final boolean[] AbsencesVector; +public class AbsencesVector { + public boolean[] AbsencesVector; - public AbsencesVector(int length, RandomEngine r) { + public AbsencesVector(int length, RandomEngine randAbsence) { int current = 1; AbsencesVector = new boolean[length]; Binomial b1 = new Binomial(1, ParametersAbsencesSimulator.probPresence); - b1.setRandomEngine(r); + b1.setRandomEngine(randAbsence); Binomial b2 = new Binomial(1, ParametersAbsencesSimulator.probReturn); - b2.setRandomEngine(r); + b2.setRandomEngine(randAbsence); for (int i = 0; i < length; i++) { if (current == 1) { current = (int) b1.random(); diff --git a/Travail_de_session/AbsenceSchedules/BankAbsenceSchedules.java b/Travail_de_session/ModifiedSchedules/BankModifiedSchedules.java similarity index 51% rename from Travail_de_session/AbsenceSchedules/BankAbsenceSchedules.java rename to Travail_de_session/ModifiedSchedules/BankModifiedSchedules.java index 907c454..1aba902 100644 --- a/Travail_de_session/AbsenceSchedules/BankAbsenceSchedules.java +++ b/Travail_de_session/ModifiedSchedules/BankModifiedSchedules.java @@ -3,7 +3,7 @@ * To change this template file, choose Tools | Templates * and open the template in the editor. */ -package AbsenceSchedules; +package ModifiedSchedules; import ScheduleUtil.SchedulesArray; @@ -14,16 +14,16 @@ import java.util.List; * * @author frabe */ -public class BankAbsenceSchedules { +public class BankModifiedSchedules { public final SchedulesArray initialSchedulesArray; - public final List bankAbsenceSimulation; + public final List bankModifiedSimulation; - public BankAbsenceSchedules(SchedulesArray initialSchedulesArray) { + public BankModifiedSchedules(SchedulesArray initialSchedulesArray) { this.initialSchedulesArray = initialSchedulesArray; - this.bankAbsenceSimulation = new ArrayList<>(); + this.bankModifiedSimulation = new ArrayList<>(); } - public void addAbsenceSchedules(AbsenceSchedulesArray absenceSchedulesArray) { - this.bankAbsenceSimulation.add(absenceSchedulesArray); + public void addModifiedSchedules(ModifiedSchedulesArray modifiedSchedulesArray) { + this.bankModifiedSimulation.add(modifiedSchedulesArray); } } diff --git a/Travail_de_session/AbsenceSchedules/AbsenceSchedulesArray.java b/Travail_de_session/ModifiedSchedules/ModifiedSchedulesArray.java similarity index 55% rename from Travail_de_session/AbsenceSchedules/AbsenceSchedulesArray.java rename to Travail_de_session/ModifiedSchedules/ModifiedSchedulesArray.java index c0f216e..b42b601 100644 --- a/Travail_de_session/AbsenceSchedules/AbsenceSchedulesArray.java +++ b/Travail_de_session/ModifiedSchedules/ModifiedSchedulesArray.java @@ -1,44 +1,44 @@ -package AbsenceSchedules; +package ModifiedSchedules; -import ScheduleUtil.EmployeeCostCalculator; -import ScheduleUtil.SchedulesArray; +import InitialSchedules.*; +import ScheduleUtil.*; import jdistlib.rng.RandomEngine; -public class AbsenceSchedulesArray extends SchedulesArray{ +public class ModifiedSchedulesArray extends SchedulesArray{ private final SchedulesArray initialSchedulesArray; public int numberOfRecoveringActionsToPerform; - public AbsenceSchedulesArray(SchedulesArray initialSchedulesArray, RandomEngine r) { + public ModifiedSchedulesArray(SchedulesArray initialSchedulesArray, ParametersSchedules myModifiedScheduleParameters, RandomEngine randAbsence) { super(initialSchedulesArray); + this.myScheduleParameters = myModifiedScheduleParameters; this.initialSchedulesArray = initialSchedulesArray; - generateAbsenceSimulation(r); - this.totalScheduleCost = EmployeeCostCalculator.getFullAbsenceScheduleCost(this, myParametersInitialSchedules); + generateAbsenceSimulation(randAbsence); + calculateNumberOfRecoveringActionsToPerform(); + this.totalScheduleCost = EmployeeCostCalculator.getFullModifiedScheduleCost(this, myScheduleParameters); } - private void generateAbsenceSimulation(RandomEngine r) { + private void generateAbsenceSimulation(RandomEngine randAbsence) { for (int i = 0; i < getNumberPartTimeEmployee(); i++) { - boolean[] a = new AbsencesVector(myParametersInitialSchedules.getWorkPeriodsPerSchedule(), r).getAbsencesVector(); - for (int j = 0; j < myParametersInitialSchedules.getWorkPeriodsPerSchedule(); j++) { + boolean[] a = new AbsencesVector(myScheduleParameters.getWorkPeriodsPerSchedule(), randAbsence).getAbsencesVector(); + for (int j = 0; j < myScheduleParameters.getWorkPeriodsPerSchedule(); j++) { this.partTimeSchedules[i][j] = this.initialSchedulesArray.isPartTimeEmployeeWorking(i, j) && a[j]; } } for (int i = 0; i < getNumberFullTimeEmployee(); i++) { - boolean[] a = new AbsencesVector(myParametersInitialSchedules.getWorkPeriodsPerSchedule(), r).getAbsencesVector(); - for (int j = 0; j < myParametersInitialSchedules.getWorkPeriodsPerSchedule(); j++) { + boolean[] a = new AbsencesVector(myScheduleParameters.getWorkPeriodsPerSchedule(), randAbsence).getAbsencesVector(); + for (int j = 0; j < myScheduleParameters.getWorkPeriodsPerSchedule(); j++) { this.fullTimeSchedules[i][j] = this.initialSchedulesArray.isFullTimeEmployeeWorking(i, j) && a[j]; } } - calculateNumberOfRecoveringActionsToPerform(); - } public int getAbsencePeriodsPerPartTimeEmployees(int employee) { int absencePeriodsPerPartTimeEmployees = 0; - for (int workPeriod = 0; workPeriod < myParametersInitialSchedules.getWorkPeriodsPerSchedule(); workPeriod++) { + for (int workPeriod = 0; workPeriod < myScheduleParameters.getWorkPeriodsPerSchedule(); workPeriod++) { if (this.isPartTimeEmployeeAbsent(employee, workPeriod)) {absencePeriodsPerPartTimeEmployees += 1;} } return absencePeriodsPerPartTimeEmployees; @@ -46,7 +46,7 @@ public class AbsenceSchedulesArray extends SchedulesArray{ public int getAbsencePeriodsPerFullTimeEmployees(int employee) { int absencePeriodsPerFullTimeEmployees = 0; - for (int workPeriod = 0; workPeriod < myParametersInitialSchedules.getWorkPeriodsPerSchedule(); workPeriod++) { + for (int workPeriod = 0; workPeriod < myScheduleParameters.getWorkPeriodsPerSchedule(); workPeriod++) { if (this.isFullTimeEmployeeAbsent(employee, workPeriod)) {absencePeriodsPerFullTimeEmployees += 1;} } return absencePeriodsPerFullTimeEmployees; @@ -62,8 +62,8 @@ public class AbsenceSchedulesArray extends SchedulesArray{ private void calculateNumberOfRecoveringActionsToPerform() { this.numberOfRecoveringActionsToPerform = 0; - for (int workPeriod = 0; workPeriod < myParametersInitialSchedules.getWorkPeriodsPerSchedule(); workPeriod++) { - this.numberOfRecoveringActionsToPerform += this.myParametersInitialSchedules.getRequiredWorkForce(workPeriod) - this.getEmployeesWorkingPerWorkPeriod(workPeriod); + for (int workPeriod = 0; workPeriod < myScheduleParameters.getWorkPeriodsPerSchedule(); workPeriod++) { + this.numberOfRecoveringActionsToPerform += this.myScheduleParameters.getRequiredWorkForce(workPeriod) - this.getEmployeesWorkingPerWorkPeriod(workPeriod); } } diff --git a/Travail_de_session/AbsenceSchedules/ParametersAbsencesSimulator.java b/Travail_de_session/ModifiedSchedules/ParametersAbsencesSimulator.java similarity index 68% rename from Travail_de_session/AbsenceSchedules/ParametersAbsencesSimulator.java rename to Travail_de_session/ModifiedSchedules/ParametersAbsencesSimulator.java index e0ae85c..879a0e0 100644 --- a/Travail_de_session/AbsenceSchedules/ParametersAbsencesSimulator.java +++ b/Travail_de_session/ModifiedSchedules/ParametersAbsencesSimulator.java @@ -3,14 +3,14 @@ * To change this template file, choose Tools | Templates * and open the template in the editor. */ -package AbsenceSchedules; +package ModifiedSchedules; /** * * @author frabe */ public class ParametersAbsencesSimulator { - public static final double probPresence = 0.99; + public static double probPresence = 0.92; public static final double probReturn = 0.50; - public static final int numberAbsenceSimulations = 1000; + public static final int numberAbsenceSimulations = 100; } diff --git a/Travail_de_session/ModifiedSchedules/ParametersVariableDemandSimulator.java b/Travail_de_session/ModifiedSchedules/ParametersVariableDemandSimulator.java new file mode 100644 index 0000000..05835ec --- /dev/null +++ b/Travail_de_session/ModifiedSchedules/ParametersVariableDemandSimulator.java @@ -0,0 +1,8 @@ +package ModifiedSchedules; + +public class ParametersVariableDemandSimulator { + public static double probIncreasedDemandbyOne = 0; + public static double probIncreasedDemandbyTwo = probIncreasedDemandbyOne / 5; + public static double probIncreasedDemandbyThree = probIncreasedDemandbyOne / 25; + public static final int numberVariableDemandSimulations = 10; +} diff --git a/Travail_de_session/ModifiedSchedules/VariableDemandVector.java b/Travail_de_session/ModifiedSchedules/VariableDemandVector.java new file mode 100644 index 0000000..21a7a1a --- /dev/null +++ b/Travail_de_session/ModifiedSchedules/VariableDemandVector.java @@ -0,0 +1,33 @@ +package ModifiedSchedules; + +import jdistlib.Binomial; +import jdistlib.rng.RandomEngine; + +public class VariableDemandVector { + public int[] variableDemandVector; + + public VariableDemandVector(int length, RandomEngine randVariableDemand) { + variableDemandVector = new int[length]; + Binomial p1 = new Binomial(1,ParametersVariableDemandSimulator.probIncreasedDemandbyOne); + p1.setRandomEngine(randVariableDemand); + Binomial p2 = new Binomial(1,ParametersVariableDemandSimulator.probIncreasedDemandbyTwo); + p2.setRandomEngine(randVariableDemand); + Binomial p3 = new Binomial(1,ParametersVariableDemandSimulator.probIncreasedDemandbyThree); + p3.setRandomEngine(randVariableDemand); + for (int i = 0; i < length; i++) { + if ((int) p3.random() == 1){ + variableDemandVector[i] = 3; + } else if ((int) p2.random() == 1){ + variableDemandVector[i] = 2; + } else if ((int) p1.random() == 1){ + variableDemandVector[i] = 1; + } else { + variableDemandVector[i] = 0; + } + } + } + + public int[] getVariableDemandVector() { + return variableDemandVector; + } +} diff --git a/Travail_de_session/ScheduleUtil/EmployeeCostCalculator.java b/Travail_de_session/ScheduleUtil/EmployeeCostCalculator.java index f8b34c5..66be29e 100644 --- a/Travail_de_session/ScheduleUtil/EmployeeCostCalculator.java +++ b/Travail_de_session/ScheduleUtil/EmployeeCostCalculator.java @@ -5,10 +5,9 @@ */ package ScheduleUtil; -import AbsenceSchedules.AbsenceSchedulesArray; -import InitialSchedules.ParametersInitialSchedules; +import ModifiedSchedules.ModifiedSchedulesArray; +import InitialSchedules.ParametersSchedules; import SchedulesRecovery.RecoveredSchedulesArray; -import VariableDemandSchedules.VariableDemandSchedulesArray; /** * @@ -16,7 +15,7 @@ import VariableDemandSchedules.VariableDemandSchedulesArray; */ public class EmployeeCostCalculator { - public static int getFullInitialScheduleCost( SchedulesArray myInitialSchedule, ParametersInitialSchedules myScheduleParameters) { + public static int getFullInitialScheduleCost( SchedulesArray myInitialSchedule, ParametersSchedules myScheduleParameters) { int totalCost = 0; for (int partTimeEmployee = 0 ; partTimeEmployee < myInitialSchedule.getNumberPartTimeEmployee() ; partTimeEmployee++) { int numberWorkingPeriod = myInitialSchedule.getWorkingPeriodsPerPartTimeEmployees(partTimeEmployee); @@ -30,64 +29,58 @@ public class EmployeeCostCalculator { } return totalCost; } - - public static int getFullVariableDemandScheduleCost( VariableDemandSchedulesArray myVariableDemandSchedule, ParametersInitialSchedules myScheduleParameters) { - int totalCost = 0; - - /* Coût spécifique à une augmentation de la demande */ - for(int p=0;p bankRecoveredSimulation; - private final List bankAbsenceSimulation; + private final List bankModifiedSimulation; public double meanCostRecoveredSimulations; + public int numberUnResolvedSimulations; - public BankRecoveredSchedules(SchedulesArray initialSchedulesArray, List bankAbsenceSimulation) { + public BankRecoveredSchedules(SchedulesArray initialSchedulesArray, List bankModifiedSimulation) { this.initialSchedulesArray = initialSchedulesArray; - this.bankAbsenceSimulation = bankAbsenceSimulation; + this.bankModifiedSimulation = bankModifiedSimulation; this.bankRecoveredSimulation = new ArrayList<>(); + this.numberUnResolvedSimulations = 0; } - public void addRecoveredSchedules(SchedulesArray absenceSchedulesArray) { - this.bankRecoveredSimulation.add(absenceSchedulesArray); + public void addRecoveredSchedules(SchedulesArray recoveredSchedulesArray) { + this.bankRecoveredSimulation.add(recoveredSchedulesArray); } } diff --git a/Travail_de_session/SchedulesRecovery/RecoveredSchedulesArray.java b/Travail_de_session/SchedulesRecovery/RecoveredSchedulesArray.java index 459d96a..1170b89 100644 --- a/Travail_de_session/SchedulesRecovery/RecoveredSchedulesArray.java +++ b/Travail_de_session/SchedulesRecovery/RecoveredSchedulesArray.java @@ -5,7 +5,7 @@ */ package SchedulesRecovery; -import AbsenceSchedules.AbsenceSchedulesArray; +import ModifiedSchedules.ModifiedSchedulesArray; import ScheduleUtil.EmployeeCostCalculator; import ScheduleUtil.SchedulesArray; @@ -18,22 +18,23 @@ import java.util.*; @SuppressWarnings("unchecked") public class RecoveredSchedulesArray extends SchedulesArray{ - public final AbsenceSchedulesArray absenceSchedulesArray; + public final ModifiedSchedulesArray modifiedSchedulesArray; - public RecoveredSchedulesArray(AbsenceSchedulesArray absenceSchedulesArray){ - super(absenceSchedulesArray); - this.absenceSchedulesArray = absenceSchedulesArray; - recoverAbsenceScheduleOptimally(); + public RecoveredSchedulesArray(ModifiedSchedulesArray modifiedSchedulesArray){ + super(modifiedSchedulesArray); + this.myScheduleParameters = modifiedSchedulesArray.myScheduleParameters; + this.modifiedSchedulesArray = modifiedSchedulesArray; + recoverModifiedScheduleOptimally(); } - private void recoverAbsenceScheduleOptimally() { - boolean[][] initialRecoveredScheduleOfPartTimeEmployees = this.getDeepCopyEmployeesSchedules(this.absenceSchedulesArray.partTimeSchedules); - boolean[][] initialRecoveredScheduleOfFullTimeEmployees = this.getDeepCopyEmployeesSchedules(this.absenceSchedulesArray.fullTimeSchedules); - boolean[][] currentRecoveredScheduleOfPartTimeEmployees = this.getDeepCopyEmployeesSchedules(this.absenceSchedulesArray.partTimeSchedules); - boolean[][] currentRecoveredScheduleOfFullTimeEmployees = this.getDeepCopyEmployeesSchedules(this.absenceSchedulesArray.fullTimeSchedules); + private void recoverModifiedScheduleOptimally() { + boolean[][] initialRecoveredScheduleOfPartTimeEmployees = this.getDeepCopyEmployeesSchedules(this.modifiedSchedulesArray.partTimeSchedules); + boolean[][] initialRecoveredScheduleOfFullTimeEmployees = this.getDeepCopyEmployeesSchedules(this.modifiedSchedulesArray.fullTimeSchedules); + boolean[][] currentRecoveredScheduleOfPartTimeEmployees = this.getDeepCopyEmployeesSchedules(this.modifiedSchedulesArray.partTimeSchedules); + boolean[][] currentRecoveredScheduleOfFullTimeEmployees = this.getDeepCopyEmployeesSchedules(this.modifiedSchedulesArray.fullTimeSchedules); - int initialRemainingRecoveringAction = this.absenceSchedulesArray.numberOfRecoveringActionsToPerform; - int currentRemainingRecoveringAction = this.absenceSchedulesArray.numberOfRecoveringActionsToPerform; + int initialRemainingRecoveringAction = this.modifiedSchedulesArray.numberOfRecoveringActionsToPerform; + int currentRemainingRecoveringAction = this.modifiedSchedulesArray.numberOfRecoveringActionsToPerform; boolean[][] alreadyRecoveredWorkPeriodByPartTimeEmployees = new boolean[this.getNumberPartTimeEmployee()][initialRemainingRecoveringAction]; boolean[][] alreadyRecoveredWorkPeriodByFullTimeEmployees = new boolean[this.getNumberFullTimeEmployee()][initialRemainingRecoveringAction]; @@ -42,11 +43,11 @@ public class RecoveredSchedulesArray extends SchedulesArray{ RecoveringActionComparator recoveringActionCostComparator = new RecoveringActionComparator(); boolean isSolutionFound = false; - boolean isAbsenceFound = initialRemainingRecoveringAction != 0; + boolean isModificationFound = initialRemainingRecoveringAction != 0; int numberBackTrack = 1; // Fouilles en profondeur en privilegiant les actions avec cout minimum. On marque les noeuds dejà visites pour avoir des fouilles differentes - while ( !isSolutionFound && isAbsenceFound ) { + while ( !isSolutionFound && isModificationFound ) { PriorityQueue recoveringActionsOrderedByCost = getPossibleRecoveringActions(currentRecoveredScheduleOfPartTimeEmployees, currentRecoveredScheduleOfFullTimeEmployees, alreadyRecoveredWorkPeriodByPartTimeEmployees, alreadyRecoveredWorkPeriodByFullTimeEmployees, currentRemainingRecoveringAction, recoveringActionCostComparator); @@ -69,13 +70,6 @@ public class RecoveredSchedulesArray extends SchedulesArray{ currentRemainingRecoveringAction--; - } else if (numberBackTrack % (this.getNumberFullTimeEmployee() + this.getNumberPartTimeEmployee()) == 0) { - //Si le nombre de retour au sommet atteint le nombre total d'employes, on reinitialize les matrices de noeuds visites. - initializeRecoveredWorkPeriodMatrix (alreadyRecoveredWorkPeriodByPartTimeEmployees, alreadyRecoveredWorkPeriodByFullTimeEmployees); - } else if (numberBackTrack > 10000) { - isSolutionFound = false; - System.out.println("No solution Found"); - break; } else{ // Lorsqu'on est bloque dans l'arbre de recherche, on revient au sommet de l'arbre et on recommence une nouvelle fouille. currentRemainingRecoveringAction = initialRemainingRecoveringAction; @@ -86,14 +80,22 @@ public class RecoveredSchedulesArray extends SchedulesArray{ if (currentRemainingRecoveringAction == 0){ isSolutionFound = true; + } else if (numberBackTrack % (this.getNumberFullTimeEmployee() + this.getNumberPartTimeEmployee()) == 0) { + //Si le nombre de retour au sommet atteint le nombre total d'employes, on reinitialize les matrices de noeuds visites. + initializeRecoveredWorkPeriodMatrix (alreadyRecoveredWorkPeriodByPartTimeEmployees, alreadyRecoveredWorkPeriodByFullTimeEmployees); + } else if (numberBackTrack > 100000) { + isSolutionFound = false; + System.out.println("No solution Found"); + break; } - + } - if (isSolutionFound || !isAbsenceFound) { + if (isSolutionFound || !isModificationFound) { this.fullTimeSchedules = currentRecoveredScheduleOfFullTimeEmployees; this.partTimeSchedules = currentRecoveredScheduleOfPartTimeEmployees; - this.totalScheduleCost = EmployeeCostCalculator.getFullRecoveredScheduleCost(this, myParametersInitialSchedules); + this.totalScheduleCost = EmployeeCostCalculator.getFullRecoveredScheduleCost(this, myScheduleParameters); + } else { this.totalScheduleCost = Integer.MAX_VALUE; } @@ -136,24 +138,24 @@ public class RecoveredSchedulesArray extends SchedulesArray{ PriorityQueue recoveringActionsOrderedByCost = new PriorityQueue<>(recoveringActionCostComparator); int workPeriod = findWorkPeriodToRecover(currentPartTimeSchedule, currentFullTimeSchedule); - if (workPeriod < myParametersInitialSchedules.getWorkPeriodsPerSchedule()) { + if (workPeriod < myScheduleParameters.getWorkPeriodsPerSchedule()) { for (int partTimeEmployee = 0 ; partTimeEmployee < this.getNumberPartTimeEmployee() ; partTimeEmployee++ ) { - if ( ValidationRecoveringAction.isPartTimeEmployeeAvailableForAbsenceRecovering(currentPartTimeSchedule, myParametersInitialSchedules, - absenceSchedulesArray, partTimeEmployee, workPeriod) + if ( ValidationRecoveringAction.isPartTimeEmployeeAvailableForRecovering(currentPartTimeSchedule, myScheduleParameters, + modifiedSchedulesArray, partTimeEmployee, workPeriod) && !alreadyRecoveredWorkPeriodByPartTimeEmployees[partTimeEmployee][remainingRecoveringAction-1]){ RecoveringActionPartTimeEmployee recoveringAction = new RecoveringActionPartTimeEmployee(partTimeEmployee, workPeriod); - recoveringAction.calculateRecoveringActionCost(currentPartTimeSchedule, myParametersInitialSchedules); + recoveringAction.calculateRecoveringActionCost(currentPartTimeSchedule, myScheduleParameters); recoveringActionsOrderedByCost.add(recoveringAction); } } for (int fullTimeEmployee = 0 ; fullTimeEmployee < this.getNumberFullTimeEmployee() ; fullTimeEmployee++ ) { - if ( ValidationRecoveringAction.isFullTimeEmployeeAvailableForAbsenceRecovering(currentFullTimeSchedule, myParametersInitialSchedules, - absenceSchedulesArray, fullTimeEmployee, workPeriod) + if ( ValidationRecoveringAction.isFullTimeEmployeeAvailableForRecovering(currentFullTimeSchedule, myScheduleParameters, + modifiedSchedulesArray, fullTimeEmployee, workPeriod) && !alreadyRecoveredWorkPeriodByFullTimeEmployees[fullTimeEmployee][remainingRecoveringAction-1] ){ RecoveringActionFullTimeEmployee recoveringAction = new RecoveringActionFullTimeEmployee(fullTimeEmployee, workPeriod); - recoveringAction.calculateRecoveringActionCost (currentFullTimeSchedule, absenceSchedulesArray, myParametersInitialSchedules); + recoveringAction.calculateRecoveringActionCost (currentFullTimeSchedule, modifiedSchedulesArray, myScheduleParameters); recoveringActionsOrderedByCost.add(recoveringAction); } } @@ -163,7 +165,7 @@ public class RecoveredSchedulesArray extends SchedulesArray{ private int findWorkPeriodToRecover(boolean[][] currentPartTimeSchedule, boolean[][] currentFullTimeSchedule){ int workingEmployees; - for (int workPeriod = 0 ; workPeriod < myParametersInitialSchedules.getWorkPeriodsPerSchedule() ; workPeriod++) { + for (int workPeriod = 0 ; workPeriod < myScheduleParameters.getWorkPeriodsPerSchedule() ; workPeriod++) { workingEmployees = 0; for (boolean[] aCurrentPartTimeSchedule : currentPartTimeSchedule) { if (aCurrentPartTimeSchedule[workPeriod]) { @@ -175,10 +177,10 @@ public class RecoveredSchedulesArray extends SchedulesArray{ workingEmployees++; } } - if (workingEmployees < this.myParametersInitialSchedules.getRequiredWorkForce(workPeriod) ) { + if (workingEmployees < this.myScheduleParameters.getRequiredWorkForce(workPeriod) ) { return workPeriod; } } - return myParametersInitialSchedules.getWorkPeriodsPerSchedule(); + return myScheduleParameters.getWorkPeriodsPerSchedule(); } } diff --git a/Travail_de_session/SchedulesRecovery/RecoveringActionFullTimeEmployee.java b/Travail_de_session/SchedulesRecovery/RecoveringActionFullTimeEmployee.java index 8011852..fad11cc 100644 --- a/Travail_de_session/SchedulesRecovery/RecoveringActionFullTimeEmployee.java +++ b/Travail_de_session/SchedulesRecovery/RecoveringActionFullTimeEmployee.java @@ -5,8 +5,8 @@ */ package SchedulesRecovery; -import AbsenceSchedules.AbsenceSchedulesArray; -import InitialSchedules.ParametersInitialSchedules; +import ModifiedSchedules.ModifiedSchedulesArray; +import InitialSchedules.ParametersSchedules; import ScheduleUtil.EmployeeCostCalculator; /** @@ -19,10 +19,10 @@ class RecoveringActionFullTimeEmployee extends RecoveringAction { super(employee, workPeriod); } - public void calculateRecoveringActionCost (boolean[][] currentEmployeesSchedule, AbsenceSchedulesArray absenceSchedulesArray, ParametersInitialSchedules myScheduleParameters) { - int costBeforeAction = EmployeeCostCalculator.getFullTimeEmployeeCost(currentEmployeesSchedule, absenceSchedulesArray, this.employee, myScheduleParameters); + public void calculateRecoveringActionCost (boolean[][] currentEmployeesSchedule, ModifiedSchedulesArray modifiedSchedulesArray, ParametersSchedules myScheduleParameters) { + int costBeforeAction = EmployeeCostCalculator.getFullTimeEmployeeCost(currentEmployeesSchedule, modifiedSchedulesArray, this.employee, myScheduleParameters); currentEmployeesSchedule[this.employee][this.workPeriod] = true; - int costAfterAction = EmployeeCostCalculator.getFullTimeEmployeeCost(currentEmployeesSchedule, absenceSchedulesArray, this.employee, myScheduleParameters); + int costAfterAction = EmployeeCostCalculator.getFullTimeEmployeeCost(currentEmployeesSchedule, modifiedSchedulesArray, this.employee, myScheduleParameters); currentEmployeesSchedule[this.employee][this.workPeriod] = false; this.recoveringActionCost = costAfterAction-costBeforeAction; } diff --git a/Travail_de_session/SchedulesRecovery/RecoveringActionPartTimeEmployee.java b/Travail_de_session/SchedulesRecovery/RecoveringActionPartTimeEmployee.java index 3c3ea0e..9102f3e 100644 --- a/Travail_de_session/SchedulesRecovery/RecoveringActionPartTimeEmployee.java +++ b/Travail_de_session/SchedulesRecovery/RecoveringActionPartTimeEmployee.java @@ -5,7 +5,7 @@ */ package SchedulesRecovery; -import InitialSchedules.ParametersInitialSchedules; +import InitialSchedules.ParametersSchedules; import ScheduleUtil.EmployeeCostCalculator; /** @@ -18,7 +18,7 @@ class RecoveringActionPartTimeEmployee extends RecoveringAction { super(employee, workPeriod); } - public void calculateRecoveringActionCost(boolean[][] currentEmployeesSchedule, ParametersInitialSchedules myScheduleParameters) { + public void calculateRecoveringActionCost(boolean[][] currentEmployeesSchedule, ParametersSchedules myScheduleParameters) { int costBeforeAction = EmployeeCostCalculator.getPartTimeEmployeeCost(currentEmployeesSchedule, this.employee, myScheduleParameters); currentEmployeesSchedule[this.employee][this.workPeriod] = true; int costAfterAction = EmployeeCostCalculator.getPartTimeEmployeeCost(currentEmployeesSchedule, this.employee, myScheduleParameters); diff --git a/Travail_de_session/SchedulesRecovery/ValidationRecoveringAction.java b/Travail_de_session/SchedulesRecovery/ValidationRecoveringAction.java index 48b668d..424912b 100644 --- a/Travail_de_session/SchedulesRecovery/ValidationRecoveringAction.java +++ b/Travail_de_session/SchedulesRecovery/ValidationRecoveringAction.java @@ -5,8 +5,8 @@ */ package SchedulesRecovery; -import AbsenceSchedules.AbsenceSchedulesArray; -import InitialSchedules.ParametersInitialSchedules; +import ModifiedSchedules.ModifiedSchedulesArray; +import InitialSchedules.ParametersSchedules; /** * @@ -17,19 +17,19 @@ import InitialSchedules.ParametersInitialSchedules; class ValidationRecoveringAction { //Toutes les fonctions sont dedoublees. On devrait faire du polymorphisme. - static boolean isPartTimeEmployeeAvailableForAbsenceRecovering(boolean[][] currentPartTimeSchedule, ParametersInitialSchedules myScheduleParameters, - AbsenceSchedulesArray myabsenceSchedule, int employee, int workPeriod){ - return !currentPartTimeSchedule[employee][workPeriod] && !myabsenceSchedule.isPartTimeEmployeeAbsent(employee, workPeriod) + static boolean isPartTimeEmployeeAvailableForRecovering(boolean[][] currentPartTimeSchedule, ParametersSchedules myScheduleParameters, + ModifiedSchedulesArray myModifiedSchedule, int employee, int workPeriod){ + return !currentPartTimeSchedule[employee][workPeriod] && !myModifiedSchedule.isPartTimeEmployeeAbsent(employee, workPeriod) && isValidPartTimeEmployeeWorkPeriod(currentPartTimeSchedule[employee], workPeriod, myScheduleParameters); } - private static boolean isValidPartTimeEmployeeWorkPeriod(boolean[] currentPartTimeEmployeeSchedule, int workPeriod, ParametersInitialSchedules myScheduleParameters){ + private static boolean isValidPartTimeEmployeeWorkPeriod(boolean[] currentPartTimeEmployeeSchedule, int workPeriod, ParametersSchedules myScheduleParameters){ return isValidWorkingPeriodsOfPartTimeEmployeePerSchedule(currentPartTimeEmployeeSchedule, myScheduleParameters) && isValidConsecutiveWorkingPeriodsOfPartTimeEmployee(currentPartTimeEmployeeSchedule, workPeriod, myScheduleParameters) && isValidConsecutiveNonWorkingPeriodsBetweenShiftWorksOfPartTimeEmployee(currentPartTimeEmployeeSchedule, workPeriod, myScheduleParameters); } - private static boolean isValidWorkingPeriodsOfPartTimeEmployeePerSchedule(boolean[] currentPartTimeEmployeeSchedule, ParametersInitialSchedules myScheduleParameters){ + private static boolean isValidWorkingPeriodsOfPartTimeEmployeePerSchedule(boolean[] currentPartTimeEmployeeSchedule, ParametersSchedules myScheduleParameters){ int employeeWorkingPeriods = 0; for ( int workPeriod = 0 ; workPeriod < myScheduleParameters.getWorkPeriodsPerSchedule() ; workPeriod++ ) { if (currentPartTimeEmployeeSchedule[workPeriod]){ @@ -39,7 +39,7 @@ class ValidationRecoveringAction { return employeeWorkingPeriods < myScheduleParameters.getMaxWorkingPeriodsOfPartTimeEmployeesPerSchedule(); } - private static boolean isValidConsecutiveWorkingPeriodsOfPartTimeEmployee(boolean[] currentPartTimeEmployeeSchedule, int workPeriod, ParametersInitialSchedules myScheduleParameters){ + private static boolean isValidConsecutiveWorkingPeriodsOfPartTimeEmployee(boolean[] currentPartTimeEmployeeSchedule, int workPeriod, ParametersSchedules myScheduleParameters){ int consecutiveWorkingPeriods = 1; int compteurWorkPeriod = workPeriod - 1; while ( compteurWorkPeriod >= 0 && currentPartTimeEmployeeSchedule[compteurWorkPeriod] ){ @@ -54,7 +54,7 @@ class ValidationRecoveringAction { return consecutiveWorkingPeriods <= myScheduleParameters.getMaxConsecutiveWorkingPeriodsOfPartTimeEmployeesPerShiftWork(); } - private static boolean isValidConsecutiveNonWorkingPeriodsBetweenShiftWorksOfPartTimeEmployee(boolean[] currentPartTimeEmployeeSchedule, int workPeriod, ParametersInitialSchedules myScheduleParameters){ + private static boolean isValidConsecutiveNonWorkingPeriodsBetweenShiftWorksOfPartTimeEmployee(boolean[] currentPartTimeEmployeeSchedule, int workPeriod, ParametersSchedules myScheduleParameters){ int consecutivePreviousNonWorkingPeriods = 0; int compteurWorkPeriod = workPeriod - 1; while ( compteurWorkPeriod >= 0 && !currentPartTimeEmployeeSchedule[compteurWorkPeriod] ){ @@ -86,20 +86,20 @@ class ValidationRecoveringAction { return validConsecutivePreviousNonWorkingPeriods && validConsecutiveNextNonWorkingPeriods; } - public static boolean isFullTimeEmployeeAvailableForAbsenceRecovering(boolean[][] currentFullTimeSchedule, ParametersInitialSchedules myScheduleParameters, - AbsenceSchedulesArray myabsenceSchedule, int employee, int workPeriod){ + public static boolean isFullTimeEmployeeAvailableForRecovering(boolean[][] currentFullTimeSchedule, ParametersSchedules myScheduleParameters, + ModifiedSchedulesArray myModifiedSchedule, int employee, int workPeriod){ - return !currentFullTimeSchedule[employee][workPeriod] && !myabsenceSchedule.isFullTimeEmployeeAbsent(employee, workPeriod) + return !currentFullTimeSchedule[employee][workPeriod] && !myModifiedSchedule.isFullTimeEmployeeAbsent(employee, workPeriod) && isValidFullTimeEmployeeWorkPeriod(currentFullTimeSchedule[employee], workPeriod, myScheduleParameters); } - private static boolean isValidFullTimeEmployeeWorkPeriod(boolean[] currentFullTimeEmployeeSchedule, int workPeriod, ParametersInitialSchedules myScheduleParameters){ + private static boolean isValidFullTimeEmployeeWorkPeriod(boolean[] currentFullTimeEmployeeSchedule, int workPeriod, ParametersSchedules myScheduleParameters){ return isValidWorkingPeriodsOfFullTimeEmployeePerSchedule(currentFullTimeEmployeeSchedule, myScheduleParameters) && isValidConsecutiveWorkingPeriodsOfFullTimeEmployee(currentFullTimeEmployeeSchedule, workPeriod, myScheduleParameters) && isValidConsecutiveNonWorkingPeriodsBetweenShiftWorksOfFullTimeEmployee(currentFullTimeEmployeeSchedule, workPeriod, myScheduleParameters); } - private static boolean isValidWorkingPeriodsOfFullTimeEmployeePerSchedule(boolean[] currentFullTimeEmployeeSchedule, ParametersInitialSchedules myScheduleParameters){ + private static boolean isValidWorkingPeriodsOfFullTimeEmployeePerSchedule(boolean[] currentFullTimeEmployeeSchedule, ParametersSchedules myScheduleParameters){ int employeeWorkingPeriods = 0; for ( int workPeriod = 0 ; workPeriod < myScheduleParameters.getWorkPeriodsPerSchedule() ; workPeriod++ ) { if (currentFullTimeEmployeeSchedule[workPeriod]){ @@ -110,7 +110,7 @@ class ValidationRecoveringAction { } - private static boolean isValidConsecutiveWorkingPeriodsOfFullTimeEmployee(boolean[] currentFullTimeEmployeeSchedule, int workPeriod, ParametersInitialSchedules myScheduleParameters){ + private static boolean isValidConsecutiveWorkingPeriodsOfFullTimeEmployee(boolean[] currentFullTimeEmployeeSchedule, int workPeriod, ParametersSchedules myScheduleParameters){ int consecutiveWorkingPeriods = 1; int compteurWorkPeriod = workPeriod - 1; while ( compteurWorkPeriod >= 0 && currentFullTimeEmployeeSchedule[compteurWorkPeriod] ){ @@ -125,7 +125,7 @@ class ValidationRecoveringAction { return consecutiveWorkingPeriods <= myScheduleParameters.getMaxConsecutiveWorkingPeriodsOfFullTimeEmployeesPerShiftWork(); } - private static boolean isValidConsecutiveNonWorkingPeriodsBetweenShiftWorksOfFullTimeEmployee(boolean[] currentFullTimeEmployeeSchedule, int workPeriod, ParametersInitialSchedules myScheduleParameters){ + private static boolean isValidConsecutiveNonWorkingPeriodsBetweenShiftWorksOfFullTimeEmployee(boolean[] currentFullTimeEmployeeSchedule, int workPeriod, ParametersSchedules myScheduleParameters){ int consecutivePreviousNonWorkingPeriods = 0; int compteurWorkPeriod = workPeriod - 1; while ( compteurWorkPeriod >= 0 && !currentFullTimeEmployeeSchedule[compteurWorkPeriod] ){ diff --git a/Travail_de_session/SchedulesWindows/ShowSolutionResultsFrame.form b/Travail_de_session/SchedulesWindows/ShowSolutionResultsFrame.form index 42748e9..51a1612 100644 --- a/Travail_de_session/SchedulesWindows/ShowSolutionResultsFrame.form +++ b/Travail_de_session/SchedulesWindows/ShowSolutionResultsFrame.form @@ -3,9 +3,6 @@
- - - diff --git a/Travail_de_session/SchedulesWindows/ShowSolutionResultsFrame.java b/Travail_de_session/SchedulesWindows/ShowSolutionResultsFrame.java index c500b04..6d1c726 100644 --- a/Travail_de_session/SchedulesWindows/ShowSolutionResultsFrame.java +++ b/Travail_de_session/SchedulesWindows/ShowSolutionResultsFrame.java @@ -121,7 +121,8 @@ public class ShowSolutionResultsFrame extends javax.swing.JFrame { StringBuilder sbuf = new StringBuilder(); String formattedInitialScedulesArray = ScheduleUtil.PrintSchedules.getFormattedSchedule(bankRecoveredSchedulesOrderedByMeanCost.get(scrollBarValue-1).initialSchedulesArray); sbuf.append(formattedInitialScedulesArray); - sbuf.append(String.format("%s" + "%.2f","Mean Cost of Recovered Schedules : $", bankRecoveredSchedulesOrderedByMeanCost.get(scrollBarValue-1).meanCostRecoveredSimulations)); + sbuf.append(String.format("%s" + "%.2f" + "%s","Mean Cost of Recovered Schedules : $", bankRecoveredSchedulesOrderedByMeanCost.get(scrollBarValue-1).meanCostRecoveredSimulations, "\n")); + sbuf.append(String.format("%s" + "%d","Number Unresolved Schedules : ", bankRecoveredSchedulesOrderedByMeanCost.get(scrollBarValue-1).numberUnResolvedSimulations)); scheduleViewerArea.setText(sbuf.toString()); } diff --git a/Travail_de_session/VariableDemandSchedules/BankVariableDemandSchedules.java b/Travail_de_session/VariableDemandSchedules/BankVariableDemandSchedules.java deleted file mode 100644 index ce808c5..0000000 --- a/Travail_de_session/VariableDemandSchedules/BankVariableDemandSchedules.java +++ /dev/null @@ -1,20 +0,0 @@ -package VariableDemandSchedules; - -import ScheduleUtil.SchedulesArray; - -import java.util.ArrayList; -import java.util.List; - -public class BankVariableDemandSchedules { - public final SchedulesArray initialSchedulesArray; - public final List bankVariableDemandSimulation; - - public BankVariableDemandSchedules(SchedulesArray initialSchedulesArray) { - this.initialSchedulesArray = initialSchedulesArray; - this.bankVariableDemandSimulation = new ArrayList<>(); - } - - public void addVariableDemandSchedules(VariableDemandSchedulesArray variableDemandSchedulesArray) { - this.bankVariableDemandSimulation.add(variableDemandSchedulesArray); - } -} diff --git a/Travail_de_session/VariableDemandSchedules/ParametersVariableDemandSimulator.java b/Travail_de_session/VariableDemandSchedules/ParametersVariableDemandSimulator.java deleted file mode 100644 index 549e4d6..0000000 --- a/Travail_de_session/VariableDemandSchedules/ParametersVariableDemandSimulator.java +++ /dev/null @@ -1,5 +0,0 @@ -package VariableDemandSchedules; - -public class ParametersVariableDemandSimulator { - public static final int numberVariableDemandSimulation = 1; -} diff --git a/Travail_de_session/VariableDemandSchedules/VariableDemandSchedulesArray.java b/Travail_de_session/VariableDemandSchedules/VariableDemandSchedulesArray.java deleted file mode 100644 index 65dc3f9..0000000 --- a/Travail_de_session/VariableDemandSchedules/VariableDemandSchedulesArray.java +++ /dev/null @@ -1,40 +0,0 @@ -package VariableDemandSchedules; - -import ScheduleUtil.EmployeeCostCalculator; -import ScheduleUtil.SchedulesArray; -import jdistlib.rng.RandomEngine; - -public class VariableDemandSchedulesArray extends SchedulesArray { - private final SchedulesArray initialSchedulesArray; - private SchedulesArray initialSchedulesArrayVariableDemand; - - public VariableDemandSchedulesArray(SchedulesArray initialSchedulesArray, RandomEngine r) { - super(initialSchedulesArray); - this.initialSchedulesArray = initialSchedulesArray; - generateDemandSimulation(r); - this.totalScheduleCost = EmployeeCostCalculator.getFullVariableDemandScheduleCost(this, myParametersInitialSchedules); - } - - private void generateDemandSimulation(RandomEngine r) { - int[] vd = new VariableDemandVector(this.myParametersInitialSchedules.getWorkPeriodsPerSchedule(), r).getVariableDemandVector(); - int[] adjd = new int[this.myParametersInitialSchedules.getWorkPeriodsPerSchedule()]; - for (int p = 0; p < this.myParametersInitialSchedules.getWorkPeriodsPerSchedule(); p++) { - adjd[p] = /*this.myParametersInitialSchedules.getRequiredWorkForce(p) + */vd[p]; - } - - this.initialSchedulesArrayVariableDemand = new SchedulesArray( - myParametersInitialSchedules, - initialSchedulesArray.fullTimeSchedules, - initialSchedulesArray.partTimeSchedules, - initialSchedulesArray.initialScheduleSolutionNumber, - adjd); - } - - public SchedulesArray getInitialSchedulesArrayVariableDemand() { - return initialSchedulesArrayVariableDemand; - } - - public SchedulesArray getInitialSchedulesArray() { - return initialSchedulesArray; - } -} diff --git a/Travail_de_session/VariableDemandSchedules/VariableDemandVector.java b/Travail_de_session/VariableDemandSchedules/VariableDemandVector.java deleted file mode 100644 index f1d9a55..0000000 --- a/Travail_de_session/VariableDemandSchedules/VariableDemandVector.java +++ /dev/null @@ -1,21 +0,0 @@ -package VariableDemandSchedules; - -import jdistlib.Binomial; -import jdistlib.rng.RandomEngine; - -public class VariableDemandVector { - private int[] VariableDemandVector; - - VariableDemandVector(int length, RandomEngine r) { - VariableDemandVector = new int[length]; - Binomial p1 = new Binomial(1,0.5); - p1.setRandomEngine(r); - for (int i = 0; i < length; i++) { - VariableDemandVector[i] = (int) p1.random(); - } - } - - public int[] getVariableDemandVector() { - return VariableDemandVector; - } -}